configure revision 1.1.1.4.2.1 1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for unbound 1.9.6.
4 #
5 # Report bugs to <unbound-bugs (at] nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>.
6 #
7 #
8 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9 #
10 #
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
90
91 # Find who we are. Look in the path if we contain no directory separator.
92 as_myself=
93 case $0 in #((
94 *[\\/]* ) as_myself=$0 ;;
95 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96 for as_dir in $PATH
97 do
98 IFS=$as_save_IFS
99 test -z "$as_dir" && as_dir=.
100 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101 done
102 IFS=$as_save_IFS
103
104 ;;
105 esac
106 # We did not find ourselves, most probably we were run as `sh COMMAND'
107 # in which case we are not to be found in the path.
108 if test "x$as_myself" = x; then
109 as_myself=$0
110 fi
111 if test ! -f "$as_myself"; then
112 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113 exit 1
114 fi
115
116 # Unset variables that we do not need and which cause bugs (e.g. in
117 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
118 # suppresses any "Segmentation fault" message there. '((' could
119 # trigger a bug in pdksh 5.2.14.
120 for as_var in BASH_ENV ENV MAIL MAILPATH
121 do eval test x\${$as_var+set} = xset \
122 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123 done
124 PS1='$ '
125 PS2='> '
126 PS4='+ '
127
128 # NLS nuisances.
129 LC_ALL=C
130 export LC_ALL
131 LANGUAGE=C
132 export LANGUAGE
133
134 # CDPATH.
135 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137 # Use a proper internal environment variable to ensure we don't fall
138 # into an infinite loop, continuously re-executing ourselves.
139 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140 _as_can_reexec=no; export _as_can_reexec;
141 # We cannot yet assume a decent shell, so we have to provide a
142 # neutralization value for shells without unset; and this also
143 # works around shells that cannot unset nonexistent variables.
144 # Preserve -v and -x to the replacement shell.
145 BASH_ENV=/dev/null
146 ENV=/dev/null
147 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148 case $- in # ((((
149 *v*x* | *x*v* ) as_opts=-vx ;;
150 *v* ) as_opts=-v ;;
151 *x* ) as_opts=-x ;;
152 * ) as_opts= ;;
153 esac
154 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155 # Admittedly, this is quite paranoid, since all the known shells bail
156 # out after a failed `exec'.
157 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158 as_fn_exit 255
159 fi
160 # We don't want this to propagate to other subprocesses.
161 { _as_can_reexec=; unset _as_can_reexec;}
162 if test "x$CONFIG_SHELL" = x; then
163 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164 emulate sh
165 NULLCMD=:
166 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167 # is contrary to our usage. Disable this feature.
168 alias -g '\${1+\"\$@\"}'='\"\$@\"'
169 setopt NO_GLOB_SUBST
170 else
171 case \`(set -o) 2>/dev/null\` in #(
172 *posix*) :
173 set -o posix ;; #(
174 *) :
175 ;;
176 esac
177 fi
178 "
179 as_required="as_fn_return () { (exit \$1); }
180 as_fn_success () { as_fn_return 0; }
181 as_fn_failure () { as_fn_return 1; }
182 as_fn_ret_success () { return 0; }
183 as_fn_ret_failure () { return 1; }
184
185 exitcode=0
186 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192 else
193 exitcode=1; echo positional parameters were not saved.
194 fi
195 test x\$exitcode = x0 || exit 1
196 test -x / || exit 1"
197 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201 test \$(( 1 + 1 )) = 2 || exit 1
202
203 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
204 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
205 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
206 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
207 PATH=/empty FPATH=/empty; export PATH FPATH
208 test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
209 || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
210 if (eval "$as_required") 2>/dev/null; then :
211 as_have_required=yes
212 else
213 as_have_required=no
214 fi
215 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
216
217 else
218 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
219 as_found=false
220 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
221 do
222 IFS=$as_save_IFS
223 test -z "$as_dir" && as_dir=.
224 as_found=:
225 case $as_dir in #(
226 /*)
227 for as_base in sh bash ksh sh5; do
228 # Try only shells that exist, to save several forks.
229 as_shell=$as_dir/$as_base
230 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
231 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
232 CONFIG_SHELL=$as_shell as_have_required=yes
233 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
234 break 2
235 fi
236 fi
237 done;;
238 esac
239 as_found=false
240 done
241 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
242 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
243 CONFIG_SHELL=$SHELL as_have_required=yes
244 fi; }
245 IFS=$as_save_IFS
246
247
248 if test "x$CONFIG_SHELL" != x; then :
249 export CONFIG_SHELL
250 # We cannot yet assume a decent shell, so we have to provide a
251 # neutralization value for shells without unset; and this also
252 # works around shells that cannot unset nonexistent variables.
253 # Preserve -v and -x to the replacement shell.
254 BASH_ENV=/dev/null
255 ENV=/dev/null
256 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
257 case $- in # ((((
258 *v*x* | *x*v* ) as_opts=-vx ;;
259 *v* ) as_opts=-v ;;
260 *x* ) as_opts=-x ;;
261 * ) as_opts= ;;
262 esac
263 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
264 # Admittedly, this is quite paranoid, since all the known shells bail
265 # out after a failed `exec'.
266 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
267 exit 255
268 fi
269
270 if test x$as_have_required = xno; then :
271 $as_echo "$0: This script requires a shell more modern than all"
272 $as_echo "$0: the shells that I found on your system."
273 if test x${ZSH_VERSION+set} = xset ; then
274 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
275 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
276 else
277 $as_echo "$0: Please tell bug-autoconf (at] gnu.org and
278 $0: unbound-bugs (at] nlnetlabs.nl or
279 $0: https://github.com/NLnetLabs/unbound/issues about your
280 $0: system, including any error possibly output before this
281 $0: message. Then install a modern shell, or manually run
282 $0: the script under such a shell if you do have one."
283 fi
284 exit 1
285 fi
286 fi
287 fi
288 SHELL=${CONFIG_SHELL-/bin/sh}
289 export SHELL
290 # Unset more variables known to interfere with behavior of common tools.
291 CLICOLOR_FORCE= GREP_OPTIONS=
292 unset CLICOLOR_FORCE GREP_OPTIONS
293
294 ## --------------------- ##
295 ## M4sh Shell Functions. ##
296 ## --------------------- ##
297 # as_fn_unset VAR
298 # ---------------
299 # Portably unset VAR.
300 as_fn_unset ()
301 {
302 { eval $1=; unset $1;}
303 }
304 as_unset=as_fn_unset
305
306 # as_fn_set_status STATUS
307 # -----------------------
308 # Set $? to STATUS, without forking.
309 as_fn_set_status ()
310 {
311 return $1
312 } # as_fn_set_status
313
314 # as_fn_exit STATUS
315 # -----------------
316 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
317 as_fn_exit ()
318 {
319 set +e
320 as_fn_set_status $1
321 exit $1
322 } # as_fn_exit
323
324 # as_fn_mkdir_p
325 # -------------
326 # Create "$as_dir" as a directory, including parents if necessary.
327 as_fn_mkdir_p ()
328 {
329
330 case $as_dir in #(
331 -*) as_dir=./$as_dir;;
332 esac
333 test -d "$as_dir" || eval $as_mkdir_p || {
334 as_dirs=
335 while :; do
336 case $as_dir in #(
337 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
338 *) as_qdir=$as_dir;;
339 esac
340 as_dirs="'$as_qdir' $as_dirs"
341 as_dir=`$as_dirname -- "$as_dir" ||
342 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
343 X"$as_dir" : 'X\(//\)[^/]' \| \
344 X"$as_dir" : 'X\(//\)$' \| \
345 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
346 $as_echo X"$as_dir" |
347 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
348 s//\1/
349 q
350 }
351 /^X\(\/\/\)[^/].*/{
352 s//\1/
353 q
354 }
355 /^X\(\/\/\)$/{
356 s//\1/
357 q
358 }
359 /^X\(\/\).*/{
360 s//\1/
361 q
362 }
363 s/.*/./; q'`
364 test -d "$as_dir" && break
365 done
366 test -z "$as_dirs" || eval "mkdir $as_dirs"
367 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
368
369
370 } # as_fn_mkdir_p
371
372 # as_fn_executable_p FILE
373 # -----------------------
374 # Test if FILE is an executable regular file.
375 as_fn_executable_p ()
376 {
377 test -f "$1" && test -x "$1"
378 } # as_fn_executable_p
379 # as_fn_append VAR VALUE
380 # ----------------------
381 # Append the text in VALUE to the end of the definition contained in VAR. Take
382 # advantage of any shell optimizations that allow amortized linear growth over
383 # repeated appends, instead of the typical quadratic growth present in naive
384 # implementations.
385 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
386 eval 'as_fn_append ()
387 {
388 eval $1+=\$2
389 }'
390 else
391 as_fn_append ()
392 {
393 eval $1=\$$1\$2
394 }
395 fi # as_fn_append
396
397 # as_fn_arith ARG...
398 # ------------------
399 # Perform arithmetic evaluation on the ARGs, and store the result in the
400 # global $as_val. Take advantage of shells that can avoid forks. The arguments
401 # must be portable across $(()) and expr.
402 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
403 eval 'as_fn_arith ()
404 {
405 as_val=$(( $* ))
406 }'
407 else
408 as_fn_arith ()
409 {
410 as_val=`expr "$@" || test $? -eq 1`
411 }
412 fi # as_fn_arith
413
414
415 # as_fn_error STATUS ERROR [LINENO LOG_FD]
416 # ----------------------------------------
417 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
418 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
419 # script with STATUS, using 1 if that was 0.
420 as_fn_error ()
421 {
422 as_status=$1; test $as_status -eq 0 && as_status=1
423 if test "$4"; then
424 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
425 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
426 fi
427 $as_echo "$as_me: error: $2" >&2
428 as_fn_exit $as_status
429 } # as_fn_error
430
431 if expr a : '\(a\)' >/dev/null 2>&1 &&
432 test "X`expr 00001 : '.*\(...\)'`" = X001; then
433 as_expr=expr
434 else
435 as_expr=false
436 fi
437
438 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
439 as_basename=basename
440 else
441 as_basename=false
442 fi
443
444 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
445 as_dirname=dirname
446 else
447 as_dirname=false
448 fi
449
450 as_me=`$as_basename -- "$0" ||
451 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
452 X"$0" : 'X\(//\)$' \| \
453 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
454 $as_echo X/"$0" |
455 sed '/^.*\/\([^/][^/]*\)\/*$/{
456 s//\1/
457 q
458 }
459 /^X\/\(\/\/\)$/{
460 s//\1/
461 q
462 }
463 /^X\/\(\/\).*/{
464 s//\1/
465 q
466 }
467 s/.*/./; q'`
468
469 # Avoid depending upon Character Ranges.
470 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
471 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
472 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
473 as_cr_digits='0123456789'
474 as_cr_alnum=$as_cr_Letters$as_cr_digits
475
476
477 as_lineno_1=$LINENO as_lineno_1a=$LINENO
478 as_lineno_2=$LINENO as_lineno_2a=$LINENO
479 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
480 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
481 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
482 sed -n '
483 p
484 /[$]LINENO/=
485 ' <$as_myself |
486 sed '
487 s/[$]LINENO.*/&-/
488 t lineno
489 b
490 :lineno
491 N
492 :loop
493 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
494 t loop
495 s/-\n.*//
496 ' >$as_me.lineno &&
497 chmod +x "$as_me.lineno" ||
498 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
499
500 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
501 # already done that, so ensure we don't try to do so again and fall
502 # in an infinite loop. This has already happened in practice.
503 _as_can_reexec=no; export _as_can_reexec
504 # Don't try to exec as it changes $[0], causing all sort of problems
505 # (the dirname of $[0] is not the place where we might find the
506 # original and so on. Autoconf is especially sensitive to this).
507 . "./$as_me.lineno"
508 # Exit status is that of the last command.
509 exit
510 }
511
512 ECHO_C= ECHO_N= ECHO_T=
513 case `echo -n x` in #(((((
514 -n*)
515 case `echo 'xy\c'` in
516 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
517 xy) ECHO_C='\c';;
518 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
519 ECHO_T=' ';;
520 esac;;
521 *)
522 ECHO_N='-n';;
523 esac
524
525 rm -f conf$$ conf$$.exe conf$$.file
526 if test -d conf$$.dir; then
527 rm -f conf$$.dir/conf$$.file
528 else
529 rm -f conf$$.dir
530 mkdir conf$$.dir 2>/dev/null
531 fi
532 if (echo >conf$$.file) 2>/dev/null; then
533 if ln -s conf$$.file conf$$ 2>/dev/null; then
534 as_ln_s='ln -s'
535 # ... but there are two gotchas:
536 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
537 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
538 # In both cases, we have to default to `cp -pR'.
539 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
540 as_ln_s='cp -pR'
541 elif ln conf$$.file conf$$ 2>/dev/null; then
542 as_ln_s=ln
543 else
544 as_ln_s='cp -pR'
545 fi
546 else
547 as_ln_s='cp -pR'
548 fi
549 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
550 rmdir conf$$.dir 2>/dev/null
551
552 if mkdir -p . 2>/dev/null; then
553 as_mkdir_p='mkdir -p "$as_dir"'
554 else
555 test -d ./-p && rmdir ./-p
556 as_mkdir_p=false
557 fi
558
559 as_test_x='test -x'
560 as_executable_p=as_fn_executable_p
561
562 # Sed expression to map a string onto a valid CPP name.
563 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
564
565 # Sed expression to map a string onto a valid variable name.
566 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
567
568 SHELL=${CONFIG_SHELL-/bin/sh}
569
570
571 test -n "$DJDIR" || exec 7<&0 </dev/null
572 exec 6>&1
573
574 # Name of the host.
575 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
576 # so uname gets run too.
577 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
578
579 #
580 # Initializations.
581 #
582 ac_default_prefix=/usr/local
583 ac_clean_files=
584 ac_config_libobj_dir=.
585 LIBOBJS=
586 cross_compiling=no
587 subdirs=
588 MFLAGS=
589 MAKEFLAGS=
590
591 # Identity of this package.
592 PACKAGE_NAME='unbound'
593 PACKAGE_TARNAME='unbound'
594 PACKAGE_VERSION='1.9.6'
595 PACKAGE_STRING='unbound 1.9.6'
596 PACKAGE_BUGREPORT='unbound-bugs (at] nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues'
597 PACKAGE_URL=''
598
599 # Factoring default headers for most tests.
600 ac_includes_default="\
601 #include <stdio.h>
602 #ifdef HAVE_SYS_TYPES_H
603 # include <sys/types.h>
604 #endif
605 #ifdef HAVE_SYS_STAT_H
606 # include <sys/stat.h>
607 #endif
608 #ifdef STDC_HEADERS
609 # include <stdlib.h>
610 # include <stddef.h>
611 #else
612 # ifdef HAVE_STDLIB_H
613 # include <stdlib.h>
614 # endif
615 #endif
616 #ifdef HAVE_STRING_H
617 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
618 # include <memory.h>
619 # endif
620 # include <string.h>
621 #endif
622 #ifdef HAVE_STRINGS_H
623 # include <strings.h>
624 #endif
625 #ifdef HAVE_INTTYPES_H
626 # include <inttypes.h>
627 #endif
628 #ifdef HAVE_STDINT_H
629 # include <stdint.h>
630 #endif
631 #ifdef HAVE_UNISTD_H
632 # include <unistd.h>
633 #endif"
634
635 ac_subst_vars='LTLIBOBJS
636 date
637 version
638 INSTALLTARGET
639 ALLTARGET
640 SOURCEFILE
641 SOURCEDETERMINE
642 IPSET_OBJ
643 IPSET_SRC
644 IPSECMOD_HEADER
645 IPSECMOD_OBJ
646 DNSCRYPT_OBJ
647 DNSCRYPT_SRC
648 ENABLE_DNSCRYPT
649 ENABLE_DNSCRYPT_XCHACHA20
650 DNSTAP_OBJ
651 DNSTAP_SRC
652 opt_dnstap_socket_path
653 ENABLE_DNSTAP
654 PROTOC_C
655 UBSYMS
656 EXTRALINK
657 COMMON_OBJ_ALL_SYMBOLS
658 LIBOBJ_WITHOUT_CTIME
659 LIBOBJ_WITHOUT_CTIMEARC4
660 WIN_CHECKCONF_OBJ_LINK
661 WIN_CONTROL_OBJ_LINK
662 WIN_UBANCHOR_OBJ_LINK
663 WIN_HOST_OBJ_LINK
664 WIN_DAEMON_OBJ_LINK
665 WIN_DAEMON_OBJ
666 WIN_DAEMON_SRC
667 WINAPPS
668 WINDRES
669 CHECKLOCK_OBJ
670 staticexe
671 PC_LIBEVENT_DEPENDENCY
672 UNBOUND_EVENT_UNINSTALL
673 UNBOUND_EVENT_INSTALL
674 SUBNET_HEADER
675 SUBNET_OBJ
676 SSLLIB
677 HAVE_SSL
678 CONFIG_DATE
679 NETBSD_LINTFLAGS
680 PYUNBOUND_UNINSTALL
681 PYUNBOUND_INSTALL
682 PYUNBOUND_TARGET
683 PYUNBOUND_OBJ
684 WITH_PYUNBOUND
685 PYTHONMOD_UNINSTALL
686 PYTHONMOD_INSTALL
687 PYTHONMOD_HEADER
688 PYTHONMOD_OBJ
689 WITH_PYTHONMODULE
690 swig
691 SWIG_LIB
692 SWIG
693 PC_PY_DEPENDENCY
694 PY_MAJOR_VERSION
695 PYTHON_SITE_PKG
696 PYTHON_LDFLAGS
697 PYTHON_CPPFLAGS
698 PYTHON
699 PYTHON_VERSION
700 PTHREAD_CFLAGS_ONLY
701 PTHREAD_CFLAGS
702 PTHREAD_LIBS
703 PTHREAD_CC
704 ax_pthread_config
705 ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ
706 SLDNS_ALLOCCHECK_EXTRA_OBJ
707 USE_SYSTEMD_FALSE
708 USE_SYSTEMD_TRUE
709 SYSTEMD_DAEMON_LIBS
710 SYSTEMD_DAEMON_CFLAGS
711 SYSTEMD_LIBS
712 SYSTEMD_CFLAGS
713 RUNTIME_PATH
714 LIBOBJS
715 PKG_CONFIG_LIBDIR
716 PKG_CONFIG_PATH
717 PKG_CONFIG
718 LT_SYS_LIBRARY_PATH
719 OTOOL64
720 OTOOL
721 LIPO
722 NMEDIT
723 DSYMUTIL
724 MANIFEST_TOOL
725 AWK
726 RANLIB
727 ac_ct_AR
728 DLLTOOL
729 OBJDUMP
730 LN_S
731 NM
732 ac_ct_DUMPBIN
733 DUMPBIN
734 LD
735 FGREP
736 SED
737 LIBTOOL
738 AR
739 host_os
740 host_vendor
741 host_cpu
742 host
743 build_os
744 build_vendor
745 build_cpu
746 build
747 libtool
748 STRIP
749 doxygen
750 YFLAGS
751 YACC
752 LEXLIB
753 LEX_OUTPUT_ROOT
754 LEX
755 debug_enabled
756 DEPFLAG
757 UNBOUND_USERNAME
758 UNBOUND_ROOTCERT_FILE
759 UNBOUND_ROOTKEY_FILE
760 UNBOUND_PIDFILE
761 UNBOUND_SHARE_DIR
762 UNBOUND_CHROOT_DIR
763 UNBOUND_RUN_DIR
764 ub_conf_dir
765 ub_conf_file
766 UNBOUND_LOCALSTATE_DIR
767 UNBOUND_SYSCONF_DIR
768 UNBOUND_SBIN_DIR
769 EGREP
770 GREP
771 CPP
772 OBJEXT
773 EXEEXT
774 ac_ct_CC
775 CPPFLAGS
776 LDFLAGS
777 CFLAGS
778 CC
779 LIBUNBOUND_AGE
780 LIBUNBOUND_REVISION
781 LIBUNBOUND_CURRENT
782 UNBOUND_VERSION_MICRO
783 UNBOUND_VERSION_MINOR
784 UNBOUND_VERSION_MAJOR
785 target_alias
786 host_alias
787 build_alias
788 LIBS
789 ECHO_T
790 ECHO_N
791 ECHO_C
792 DEFS
793 mandir
794 localedir
795 libdir
796 psdir
797 pdfdir
798 dvidir
799 htmldir
800 infodir
801 docdir
802 oldincludedir
803 includedir
804 runstatedir
805 localstatedir
806 sharedstatedir
807 sysconfdir
808 datadir
809 datarootdir
810 libexecdir
811 sbindir
812 bindir
813 program_transform_name
814 prefix
815 exec_prefix
816 PACKAGE_URL
817 PACKAGE_BUGREPORT
818 PACKAGE_STRING
819 PACKAGE_VERSION
820 PACKAGE_TARNAME
821 PACKAGE_NAME
822 PATH_SEPARATOR
823 SHELL'
824 ac_subst_files=''
825 ac_user_opts='
826 enable_option_checking
827 with_conf_file
828 with_run_dir
829 with_chroot_dir
830 with_share_dir
831 with_pidfile
832 with_rootkey_file
833 with_rootcert_file
834 with_username
835 enable_checking
836 enable_debug
837 enable_flto
838 enable_pie
839 enable_relro_now
840 enable_shared
841 enable_static
842 with_pic
843 enable_fast_install
844 with_aix_soname
845 with_gnu_ld
846 with_sysroot
847 enable_libtool_lock
848 enable_rpath
849 enable_largefile
850 enable_systemd
851 enable_alloc_checks
852 enable_alloc_lite
853 enable_alloc_nonregional
854 with_pthreads
855 with_solaris_threads
856 with_syslog_facility
857 with_pyunbound
858 with_pythonmodule
859 enable_swig_version_check
860 with_nss
861 with_nettle
862 with_ssl
863 enable_sha1
864 enable_sha2
865 enable_subnet
866 enable_gost
867 enable_ecdsa
868 enable_dsa
869 enable_ed25519
870 enable_ed448
871 enable_event_api
872 enable_tfo_client
873 enable_tfo_server
874 with_libevent
875 with_libexpat
876 with_libhiredis
877 enable_static_exe
878 enable_fully_static
879 enable_lock_checks
880 enable_allsymbols
881 enable_dnstap
882 with_dnstap_socket_path
883 with_protobuf_c
884 with_libfstrm
885 enable_dnscrypt
886 with_libsodium
887 enable_cachedb
888 enable_ipsecmod
889 enable_ipset
890 with_libmnl
891 with_libunbound_only
892 '
893 ac_precious_vars='build_alias
894 host_alias
895 target_alias
896 CC
897 CFLAGS
898 LDFLAGS
899 LIBS
900 CPPFLAGS
901 CPP
902 YACC
903 YFLAGS
904 LT_SYS_LIBRARY_PATH
905 PKG_CONFIG
906 PKG_CONFIG_PATH
907 PKG_CONFIG_LIBDIR
908 SYSTEMD_CFLAGS
909 SYSTEMD_LIBS
910 SYSTEMD_DAEMON_CFLAGS
911 SYSTEMD_DAEMON_LIBS
912 PYTHON_VERSION'
913
914
915 # Initialize some variables set by options.
916 ac_init_help=
917 ac_init_version=false
918 ac_unrecognized_opts=
919 ac_unrecognized_sep=
920 # The variables have the same names as the options, with
921 # dashes changed to underlines.
922 cache_file=/dev/null
923 exec_prefix=NONE
924 no_create=
925 no_recursion=
926 prefix=NONE
927 program_prefix=NONE
928 program_suffix=NONE
929 program_transform_name=s,x,x,
930 silent=
931 site=
932 srcdir=
933 verbose=
934 x_includes=NONE
935 x_libraries=NONE
936
937 # Installation directory options.
938 # These are left unexpanded so users can "make install exec_prefix=/foo"
939 # and all the variables that are supposed to be based on exec_prefix
940 # by default will actually change.
941 # Use braces instead of parens because sh, perl, etc. also accept them.
942 # (The list follows the same order as the GNU Coding Standards.)
943 bindir='${exec_prefix}/bin'
944 sbindir='${exec_prefix}/sbin'
945 libexecdir='${exec_prefix}/libexec'
946 datarootdir='${prefix}/share'
947 datadir='${datarootdir}'
948 sysconfdir='${prefix}/etc'
949 sharedstatedir='${prefix}/com'
950 localstatedir='${prefix}/var'
951 runstatedir='${localstatedir}/run'
952 includedir='${prefix}/include'
953 oldincludedir='/usr/include'
954 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
955 infodir='${datarootdir}/info'
956 htmldir='${docdir}'
957 dvidir='${docdir}'
958 pdfdir='${docdir}'
959 psdir='${docdir}'
960 libdir='${exec_prefix}/lib'
961 localedir='${datarootdir}/locale'
962 mandir='${datarootdir}/man'
963
964 ac_prev=
965 ac_dashdash=
966 for ac_option
967 do
968 # If the previous option needs an argument, assign it.
969 if test -n "$ac_prev"; then
970 eval $ac_prev=\$ac_option
971 ac_prev=
972 continue
973 fi
974
975 case $ac_option in
976 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
977 *=) ac_optarg= ;;
978 *) ac_optarg=yes ;;
979 esac
980
981 # Accept the important Cygnus configure options, so we can diagnose typos.
982
983 case $ac_dashdash$ac_option in
984 --)
985 ac_dashdash=yes ;;
986
987 -bindir | --bindir | --bindi | --bind | --bin | --bi)
988 ac_prev=bindir ;;
989 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
990 bindir=$ac_optarg ;;
991
992 -build | --build | --buil | --bui | --bu)
993 ac_prev=build_alias ;;
994 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
995 build_alias=$ac_optarg ;;
996
997 -cache-file | --cache-file | --cache-fil | --cache-fi \
998 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
999 ac_prev=cache_file ;;
1000 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1001 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1002 cache_file=$ac_optarg ;;
1003
1004 --config-cache | -C)
1005 cache_file=config.cache ;;
1006
1007 -datadir | --datadir | --datadi | --datad)
1008 ac_prev=datadir ;;
1009 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1010 datadir=$ac_optarg ;;
1011
1012 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1013 | --dataroo | --dataro | --datar)
1014 ac_prev=datarootdir ;;
1015 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1016 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1017 datarootdir=$ac_optarg ;;
1018
1019 -disable-* | --disable-*)
1020 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1021 # Reject names that are not valid shell variable names.
1022 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1023 as_fn_error $? "invalid feature name: $ac_useropt"
1024 ac_useropt_orig=$ac_useropt
1025 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1026 case $ac_user_opts in
1027 *"
1028 "enable_$ac_useropt"
1029 "*) ;;
1030 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1031 ac_unrecognized_sep=', ';;
1032 esac
1033 eval enable_$ac_useropt=no ;;
1034
1035 -docdir | --docdir | --docdi | --doc | --do)
1036 ac_prev=docdir ;;
1037 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1038 docdir=$ac_optarg ;;
1039
1040 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1041 ac_prev=dvidir ;;
1042 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1043 dvidir=$ac_optarg ;;
1044
1045 -enable-* | --enable-*)
1046 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1047 # Reject names that are not valid shell variable names.
1048 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1049 as_fn_error $? "invalid feature name: $ac_useropt"
1050 ac_useropt_orig=$ac_useropt
1051 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1052 case $ac_user_opts in
1053 *"
1054 "enable_$ac_useropt"
1055 "*) ;;
1056 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1057 ac_unrecognized_sep=', ';;
1058 esac
1059 eval enable_$ac_useropt=\$ac_optarg ;;
1060
1061 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1062 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1063 | --exec | --exe | --ex)
1064 ac_prev=exec_prefix ;;
1065 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1066 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1067 | --exec=* | --exe=* | --ex=*)
1068 exec_prefix=$ac_optarg ;;
1069
1070 -gas | --gas | --ga | --g)
1071 # Obsolete; use --with-gas.
1072 with_gas=yes ;;
1073
1074 -help | --help | --hel | --he | -h)
1075 ac_init_help=long ;;
1076 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1077 ac_init_help=recursive ;;
1078 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1079 ac_init_help=short ;;
1080
1081 -host | --host | --hos | --ho)
1082 ac_prev=host_alias ;;
1083 -host=* | --host=* | --hos=* | --ho=*)
1084 host_alias=$ac_optarg ;;
1085
1086 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1087 ac_prev=htmldir ;;
1088 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1089 | --ht=*)
1090 htmldir=$ac_optarg ;;
1091
1092 -includedir | --includedir | --includedi | --included | --include \
1093 | --includ | --inclu | --incl | --inc)
1094 ac_prev=includedir ;;
1095 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1096 | --includ=* | --inclu=* | --incl=* | --inc=*)
1097 includedir=$ac_optarg ;;
1098
1099 -infodir | --infodir | --infodi | --infod | --info | --inf)
1100 ac_prev=infodir ;;
1101 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1102 infodir=$ac_optarg ;;
1103
1104 -libdir | --libdir | --libdi | --libd)
1105 ac_prev=libdir ;;
1106 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1107 libdir=$ac_optarg ;;
1108
1109 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1110 | --libexe | --libex | --libe)
1111 ac_prev=libexecdir ;;
1112 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1113 | --libexe=* | --libex=* | --libe=*)
1114 libexecdir=$ac_optarg ;;
1115
1116 -localedir | --localedir | --localedi | --localed | --locale)
1117 ac_prev=localedir ;;
1118 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1119 localedir=$ac_optarg ;;
1120
1121 -localstatedir | --localstatedir | --localstatedi | --localstated \
1122 | --localstate | --localstat | --localsta | --localst | --locals)
1123 ac_prev=localstatedir ;;
1124 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1125 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1126 localstatedir=$ac_optarg ;;
1127
1128 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1129 ac_prev=mandir ;;
1130 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1131 mandir=$ac_optarg ;;
1132
1133 -nfp | --nfp | --nf)
1134 # Obsolete; use --without-fp.
1135 with_fp=no ;;
1136
1137 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1138 | --no-cr | --no-c | -n)
1139 no_create=yes ;;
1140
1141 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1142 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1143 no_recursion=yes ;;
1144
1145 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1146 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1147 | --oldin | --oldi | --old | --ol | --o)
1148 ac_prev=oldincludedir ;;
1149 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1150 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1151 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1152 oldincludedir=$ac_optarg ;;
1153
1154 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1155 ac_prev=prefix ;;
1156 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1157 prefix=$ac_optarg ;;
1158
1159 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1160 | --program-pre | --program-pr | --program-p)
1161 ac_prev=program_prefix ;;
1162 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1163 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1164 program_prefix=$ac_optarg ;;
1165
1166 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1167 | --program-suf | --program-su | --program-s)
1168 ac_prev=program_suffix ;;
1169 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1170 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1171 program_suffix=$ac_optarg ;;
1172
1173 -program-transform-name | --program-transform-name \
1174 | --program-transform-nam | --program-transform-na \
1175 | --program-transform-n | --program-transform- \
1176 | --program-transform | --program-transfor \
1177 | --program-transfo | --program-transf \
1178 | --program-trans | --program-tran \
1179 | --progr-tra | --program-tr | --program-t)
1180 ac_prev=program_transform_name ;;
1181 -program-transform-name=* | --program-transform-name=* \
1182 | --program-transform-nam=* | --program-transform-na=* \
1183 | --program-transform-n=* | --program-transform-=* \
1184 | --program-transform=* | --program-transfor=* \
1185 | --program-transfo=* | --program-transf=* \
1186 | --program-trans=* | --program-tran=* \
1187 | --progr-tra=* | --program-tr=* | --program-t=*)
1188 program_transform_name=$ac_optarg ;;
1189
1190 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1191 ac_prev=pdfdir ;;
1192 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1193 pdfdir=$ac_optarg ;;
1194
1195 -psdir | --psdir | --psdi | --psd | --ps)
1196 ac_prev=psdir ;;
1197 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1198 psdir=$ac_optarg ;;
1199
1200 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1201 | -silent | --silent | --silen | --sile | --sil)
1202 silent=yes ;;
1203
1204 -runstatedir | --runstatedir | --runstatedi | --runstated \
1205 | --runstate | --runstat | --runsta | --runst | --runs \
1206 | --run | --ru | --r)
1207 ac_prev=runstatedir ;;
1208 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1209 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1210 | --run=* | --ru=* | --r=*)
1211 runstatedir=$ac_optarg ;;
1212
1213 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1214 ac_prev=sbindir ;;
1215 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1216 | --sbi=* | --sb=*)
1217 sbindir=$ac_optarg ;;
1218
1219 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1220 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1221 | --sharedst | --shareds | --shared | --share | --shar \
1222 | --sha | --sh)
1223 ac_prev=sharedstatedir ;;
1224 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1225 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1226 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1227 | --sha=* | --sh=*)
1228 sharedstatedir=$ac_optarg ;;
1229
1230 -site | --site | --sit)
1231 ac_prev=site ;;
1232 -site=* | --site=* | --sit=*)
1233 site=$ac_optarg ;;
1234
1235 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1236 ac_prev=srcdir ;;
1237 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1238 srcdir=$ac_optarg ;;
1239
1240 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1241 | --syscon | --sysco | --sysc | --sys | --sy)
1242 ac_prev=sysconfdir ;;
1243 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1244 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1245 sysconfdir=$ac_optarg ;;
1246
1247 -target | --target | --targe | --targ | --tar | --ta | --t)
1248 ac_prev=target_alias ;;
1249 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1250 target_alias=$ac_optarg ;;
1251
1252 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1253 verbose=yes ;;
1254
1255 -version | --version | --versio | --versi | --vers | -V)
1256 ac_init_version=: ;;
1257
1258 -with-* | --with-*)
1259 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1260 # Reject names that are not valid shell variable names.
1261 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1262 as_fn_error $? "invalid package name: $ac_useropt"
1263 ac_useropt_orig=$ac_useropt
1264 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1265 case $ac_user_opts in
1266 *"
1267 "with_$ac_useropt"
1268 "*) ;;
1269 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1270 ac_unrecognized_sep=', ';;
1271 esac
1272 eval with_$ac_useropt=\$ac_optarg ;;
1273
1274 -without-* | --without-*)
1275 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1276 # Reject names that are not valid shell variable names.
1277 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1278 as_fn_error $? "invalid package name: $ac_useropt"
1279 ac_useropt_orig=$ac_useropt
1280 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1281 case $ac_user_opts in
1282 *"
1283 "with_$ac_useropt"
1284 "*) ;;
1285 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1286 ac_unrecognized_sep=', ';;
1287 esac
1288 eval with_$ac_useropt=no ;;
1289
1290 --x)
1291 # Obsolete; use --with-x.
1292 with_x=yes ;;
1293
1294 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1295 | --x-incl | --x-inc | --x-in | --x-i)
1296 ac_prev=x_includes ;;
1297 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1298 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1299 x_includes=$ac_optarg ;;
1300
1301 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1302 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1303 ac_prev=x_libraries ;;
1304 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1305 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1306 x_libraries=$ac_optarg ;;
1307
1308 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1309 Try \`$0 --help' for more information"
1310 ;;
1311
1312 *=*)
1313 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1314 # Reject names that are not valid shell variable names.
1315 case $ac_envvar in #(
1316 '' | [0-9]* | *[!_$as_cr_alnum]* )
1317 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1318 esac
1319 eval $ac_envvar=\$ac_optarg
1320 export $ac_envvar ;;
1321
1322 *)
1323 # FIXME: should be removed in autoconf 3.0.
1324 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1325 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1326 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1327 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1328 ;;
1329
1330 esac
1331 done
1332
1333 if test -n "$ac_prev"; then
1334 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1335 as_fn_error $? "missing argument to $ac_option"
1336 fi
1337
1338 if test -n "$ac_unrecognized_opts"; then
1339 case $enable_option_checking in
1340 no) ;;
1341 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1342 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1343 esac
1344 fi
1345
1346 # Check all directory arguments for consistency.
1347 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1348 datadir sysconfdir sharedstatedir localstatedir includedir \
1349 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1350 libdir localedir mandir runstatedir
1351 do
1352 eval ac_val=\$$ac_var
1353 # Remove trailing slashes.
1354 case $ac_val in
1355 */ )
1356 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1357 eval $ac_var=\$ac_val;;
1358 esac
1359 # Be sure to have absolute directory names.
1360 case $ac_val in
1361 [\\/$]* | ?:[\\/]* ) continue;;
1362 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1363 esac
1364 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1365 done
1366
1367 # There might be people who depend on the old broken behavior: `$host'
1368 # used to hold the argument of --host etc.
1369 # FIXME: To remove some day.
1370 build=$build_alias
1371 host=$host_alias
1372 target=$target_alias
1373
1374 # FIXME: To remove some day.
1375 if test "x$host_alias" != x; then
1376 if test "x$build_alias" = x; then
1377 cross_compiling=maybe
1378 elif test "x$build_alias" != "x$host_alias"; then
1379 cross_compiling=yes
1380 fi
1381 fi
1382
1383 ac_tool_prefix=
1384 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1385
1386 test "$silent" = yes && exec 6>/dev/null
1387
1388
1389 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1390 ac_ls_di=`ls -di .` &&
1391 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1392 as_fn_error $? "working directory cannot be determined"
1393 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1394 as_fn_error $? "pwd does not report name of working directory"
1395
1396
1397 # Find the source files, if location was not specified.
1398 if test -z "$srcdir"; then
1399 ac_srcdir_defaulted=yes
1400 # Try the directory containing this script, then the parent directory.
1401 ac_confdir=`$as_dirname -- "$as_myself" ||
1402 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1403 X"$as_myself" : 'X\(//\)[^/]' \| \
1404 X"$as_myself" : 'X\(//\)$' \| \
1405 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1406 $as_echo X"$as_myself" |
1407 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1408 s//\1/
1409 q
1410 }
1411 /^X\(\/\/\)[^/].*/{
1412 s//\1/
1413 q
1414 }
1415 /^X\(\/\/\)$/{
1416 s//\1/
1417 q
1418 }
1419 /^X\(\/\).*/{
1420 s//\1/
1421 q
1422 }
1423 s/.*/./; q'`
1424 srcdir=$ac_confdir
1425 if test ! -r "$srcdir/$ac_unique_file"; then
1426 srcdir=..
1427 fi
1428 else
1429 ac_srcdir_defaulted=no
1430 fi
1431 if test ! -r "$srcdir/$ac_unique_file"; then
1432 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1433 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1434 fi
1435 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1436 ac_abs_confdir=`(
1437 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1438 pwd)`
1439 # When building in place, set srcdir=.
1440 if test "$ac_abs_confdir" = "$ac_pwd"; then
1441 srcdir=.
1442 fi
1443 # Remove unnecessary trailing slashes from srcdir.
1444 # Double slashes in file names in object file debugging info
1445 # mess up M-x gdb in Emacs.
1446 case $srcdir in
1447 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1448 esac
1449 for ac_var in $ac_precious_vars; do
1450 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1451 eval ac_env_${ac_var}_value=\$${ac_var}
1452 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1453 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1454 done
1455
1456 #
1457 # Report the --help message.
1458 #
1459 if test "$ac_init_help" = "long"; then
1460 # Omit some internal or obsolete options to make the list less imposing.
1461 # This message is too long to be a string in the A/UX 3.1 sh.
1462 cat <<_ACEOF
1463 \`configure' configures unbound 1.9.6 to adapt to many kinds of systems.
1464
1465 Usage: $0 [OPTION]... [VAR=VALUE]...
1466
1467 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1468 VAR=VALUE. See below for descriptions of some of the useful variables.
1469
1470 Defaults for the options are specified in brackets.
1471
1472 Configuration:
1473 -h, --help display this help and exit
1474 --help=short display options specific to this package
1475 --help=recursive display the short help of all the included packages
1476 -V, --version display version information and exit
1477 -q, --quiet, --silent do not print \`checking ...' messages
1478 --cache-file=FILE cache test results in FILE [disabled]
1479 -C, --config-cache alias for \`--cache-file=config.cache'
1480 -n, --no-create do not create output files
1481 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1482
1483 Installation directories:
1484 --prefix=PREFIX install architecture-independent files in PREFIX
1485 [$ac_default_prefix]
1486 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1487 [PREFIX]
1488
1489 By default, \`make install' will install all the files in
1490 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1491 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1492 for instance \`--prefix=\$HOME'.
1493
1494 For better control, use the options below.
1495
1496 Fine tuning of the installation directories:
1497 --bindir=DIR user executables [EPREFIX/bin]
1498 --sbindir=DIR system admin executables [EPREFIX/sbin]
1499 --libexecdir=DIR program executables [EPREFIX/libexec]
1500 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1501 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1502 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1503 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
1504 --libdir=DIR object code libraries [EPREFIX/lib]
1505 --includedir=DIR C header files [PREFIX/include]
1506 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1507 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1508 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1509 --infodir=DIR info documentation [DATAROOTDIR/info]
1510 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1511 --mandir=DIR man documentation [DATAROOTDIR/man]
1512 --docdir=DIR documentation root [DATAROOTDIR/doc/unbound]
1513 --htmldir=DIR html documentation [DOCDIR]
1514 --dvidir=DIR dvi documentation [DOCDIR]
1515 --pdfdir=DIR pdf documentation [DOCDIR]
1516 --psdir=DIR ps documentation [DOCDIR]
1517 _ACEOF
1518
1519 cat <<\_ACEOF
1520
1521 System types:
1522 --build=BUILD configure for building on BUILD [guessed]
1523 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1524 _ACEOF
1525 fi
1526
1527 if test -n "$ac_init_help"; then
1528 case $ac_init_help in
1529 short | recursive ) echo "Configuration of unbound 1.9.6:";;
1530 esac
1531 cat <<\_ACEOF
1532
1533 Optional Features:
1534 --disable-option-checking ignore unrecognized --enable/--with options
1535 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1536 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1537 --enable-checking Enable warnings, asserts, makefile-dependencies
1538 --enable-debug same as enable-checking
1539 --disable-flto Disable link-time optimization (gcc specific option)
1540 --enable-pie Enable Position-Independent Executable (eg. to fully
1541 benefit from ASLR, small performance penalty)
1542 --enable-relro-now Enable full relocation binding at load-time (RELRO
1543 NOW, to protect GOT and .dtor areas)
1544 --enable-shared[=PKGS] build shared libraries [default=yes]
1545 --enable-static[=PKGS] build static libraries [default=yes]
1546 --enable-fast-install[=PKGS]
1547 optimize for fast installation [default=yes]
1548 --disable-libtool-lock avoid locking (might break parallel builds)
1549 --disable-rpath disable hardcoded rpath (default=enabled)
1550 --disable-largefile omit support for large files
1551 --enable-systemd compile with systemd support
1552 --enable-alloc-checks enable to memory allocation statistics, for debug
1553 purposes
1554 --enable-alloc-lite enable for lightweight alloc assertions, for debug
1555 purposes
1556 --enable-alloc-nonregional
1557 enable nonregional allocs, slow but exposes regional
1558 allocations to other memory purifiers, for debug
1559 purposes
1560 --disable-swig-version-check
1561 Disable swig version check to build python modules
1562 with older swig even though that is unreliable
1563 --disable-sha1 Disable SHA1 RRSIG support, does not disable nsec3
1564 support
1565 --disable-sha2 Disable SHA256 and SHA512 RRSIG support
1566 --enable-subnet Enable client subnet
1567 --disable-gost Disable GOST support
1568 --disable-ecdsa Disable ECDSA support
1569 --disable-dsa Disable DSA support
1570 --disable-ed25519 Disable ED25519 support
1571 --disable-ed448 Disable ED448 support
1572 --enable-event-api Enable (experimental) pluggable event base
1573 libunbound API installed to unbound-event.h
1574 --enable-tfo-client Enable TCP Fast Open for client mode
1575 --enable-tfo-server Enable TCP Fast Open for server mode
1576 --enable-static-exe enable to compile executables statically against
1577 (event) uninstalled libs, for debug purposes
1578 --enable-fully-static enable to compile fully static
1579 --enable-lock-checks enable to check lock and unlock calls, for debug
1580 purposes
1581 --enable-allsymbols export all symbols from libunbound and link binaries
1582 to it, smaller install size but libunbound export
1583 table is polluted by internal symbols
1584 --enable-dnstap Enable dnstap support (requires fstrm, protobuf-c)
1585 --enable-dnscrypt Enable dnscrypt support (requires libsodium)
1586 --enable-cachedb enable cachedb module that can use external cache
1587 storage
1588 --enable-ipsecmod Enable ipsecmod module that facilitates
1589 opportunistic IPsec
1590 --enable-ipset enable ipset module
1591
1592 Optional Packages:
1593 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1594 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1595 --with-conf-file=path Pathname to the Unbound configuration file
1596 --with-run-dir=path set default directory to chdir to (by default dir
1597 part of cfg file)
1598 --with-chroot-dir=path set default directory to chroot to (by default same
1599 as run-dir)
1600 --with-share-dir=path set default directory with shared data (by default
1601 same as share/unbound)
1602 --with-pidfile=filename set default pathname to unbound pidfile (default
1603 run-dir/unbound.pid)
1604 --with-rootkey-file=filename
1605 set default pathname to root key file (default
1606 run-dir/root.key). This file is read and written.
1607 --with-rootcert-file=filename
1608 set default pathname to root update certificate file
1609 (default run-dir/icannbundle.pem). This file need
1610 not exist if you are content with the builtin.
1611 --with-username=user set default user that unbound changes to (default
1612 user is unbound)
1613 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
1614 both]
1615 --with-aix-soname=aix|svr4|both
1616 shared library versioning (aka "SONAME") variant to
1617 provide on AIX, [default=aix].
1618 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1619 --with-sysroot[=DIR] Search for dependent libraries within DIR (or the
1620 compiler's sysroot if not specified).
1621 --with-pthreads use pthreads library, or --without-pthreads to
1622 disable threading support.
1623 --with-solaris-threads use solaris native thread library.
1624 --with-syslog-facility=LOCAL0 - LOCAL7
1625 set SYSLOG_FACILITY, default DAEMON
1626 --with-pyunbound build PyUnbound, or --without-pyunbound to skip it.
1627 (default=no)
1628 --with-pythonmodule build Python module, or --without-pythonmodule to
1629 disable script engine. (default=no)
1630 --with-nss=path use libnss instead of openssl, installed at path.
1631 --with-nettle=path use libnettle as crypto library, installed at path.
1632 --with-ssl=pathname enable SSL (will check /usr/local/ssl /usr/lib/ssl
1633 /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw
1634 /usr)
1635 --with-libevent=pathname
1636 use libevent (will check /usr/local /opt/local
1637 /usr/lib /usr/pkg /usr/sfw /usr or you can specify
1638 an explicit path). Slower, but allows use of large
1639 outgoing port ranges.
1640 --with-libexpat=path specify explicit path for libexpat.
1641 --with-libhiredis=path specify explicit path for libhiredis.
1642 --with-dnstap-socket-path=pathname
1643 set default dnstap socket path
1644 --with-protobuf-c=path Path where protobuf-c is installed, for dnstap
1645 --with-libfstrm=path Path where libfstrm is installed, for dnstap
1646 --with-libsodium=path Path where libsodium is installed, for dnscrypt
1647 --with-libmnl=path specify explicit path for libmnl.
1648 --with-libunbound-only do not build daemon and tool programs
1649
1650 Some influential environment variables:
1651 CC C compiler command
1652 CFLAGS C compiler flags
1653 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1654 nonstandard directory <lib dir>
1655 LIBS libraries to pass to the linker, e.g. -l<library>
1656 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1657 you have headers in a nonstandard directory <include dir>
1658 CPP C preprocessor
1659 YACC The `Yet Another Compiler Compiler' implementation to use.
1660 Defaults to the first program found out of: `bison -y', `byacc',
1661 `yacc'.
1662 YFLAGS The list of arguments that will be passed by default to $YACC.
1663 This script will default YFLAGS to the empty string to avoid a
1664 default value of `-d' given by some make applications.
1665 LT_SYS_LIBRARY_PATH
1666 User-defined run-time library search path.
1667 PKG_CONFIG path to pkg-config utility
1668 PKG_CONFIG_PATH
1669 directories to add to pkg-config's search path
1670 PKG_CONFIG_LIBDIR
1671 path overriding pkg-config's built-in search path
1672 SYSTEMD_CFLAGS
1673 C compiler flags for SYSTEMD, overriding pkg-config
1674 SYSTEMD_LIBS
1675 linker flags for SYSTEMD, overriding pkg-config
1676 SYSTEMD_DAEMON_CFLAGS
1677 C compiler flags for SYSTEMD_DAEMON, overriding pkg-config
1678 SYSTEMD_DAEMON_LIBS
1679 linker flags for SYSTEMD_DAEMON, overriding pkg-config
1680 PYTHON_VERSION
1681 The installed Python version to use, for example '2.3'. This
1682 string will be appended to the Python interpreter canonical
1683 name.
1684
1685 Use these variables to override the choices made by `configure' or to help
1686 it to find libraries and programs with nonstandard names/locations.
1687
1688 Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>.
1689 _ACEOF
1690 ac_status=$?
1691 fi
1692
1693 if test "$ac_init_help" = "recursive"; then
1694 # If there are subdirs, report their specific --help.
1695 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1696 test -d "$ac_dir" ||
1697 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1698 continue
1699 ac_builddir=.
1700
1701 case "$ac_dir" in
1702 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1703 *)
1704 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1705 # A ".." for each directory in $ac_dir_suffix.
1706 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1707 case $ac_top_builddir_sub in
1708 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1709 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1710 esac ;;
1711 esac
1712 ac_abs_top_builddir=$ac_pwd
1713 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1714 # for backward compatibility:
1715 ac_top_builddir=$ac_top_build_prefix
1716
1717 case $srcdir in
1718 .) # We are building in place.
1719 ac_srcdir=.
1720 ac_top_srcdir=$ac_top_builddir_sub
1721 ac_abs_top_srcdir=$ac_pwd ;;
1722 [\\/]* | ?:[\\/]* ) # Absolute name.
1723 ac_srcdir=$srcdir$ac_dir_suffix;
1724 ac_top_srcdir=$srcdir
1725 ac_abs_top_srcdir=$srcdir ;;
1726 *) # Relative name.
1727 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1728 ac_top_srcdir=$ac_top_build_prefix$srcdir
1729 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1730 esac
1731 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1732
1733 cd "$ac_dir" || { ac_status=$?; continue; }
1734 # Check for guested configure.
1735 if test -f "$ac_srcdir/configure.gnu"; then
1736 echo &&
1737 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1738 elif test -f "$ac_srcdir/configure"; then
1739 echo &&
1740 $SHELL "$ac_srcdir/configure" --help=recursive
1741 else
1742 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1743 fi || ac_status=$?
1744 cd "$ac_pwd" || { ac_status=$?; break; }
1745 done
1746 fi
1747
1748 test -n "$ac_init_help" && exit $ac_status
1749 if $ac_init_version; then
1750 cat <<\_ACEOF
1751 unbound configure 1.9.6
1752 generated by GNU Autoconf 2.69
1753
1754 Copyright (C) 2012 Free Software Foundation, Inc.
1755 This configure script is free software; the Free Software Foundation
1756 gives unlimited permission to copy, distribute and modify it.
1757 _ACEOF
1758 exit
1759 fi
1760
1761 ## ------------------------ ##
1762 ## Autoconf initialization. ##
1763 ## ------------------------ ##
1764
1765 # ac_fn_c_try_compile LINENO
1766 # --------------------------
1767 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1768 ac_fn_c_try_compile ()
1769 {
1770 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1771 rm -f conftest.$ac_objext
1772 if { { ac_try="$ac_compile"
1773 case "(($ac_try" in
1774 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1775 *) ac_try_echo=$ac_try;;
1776 esac
1777 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1778 $as_echo "$ac_try_echo"; } >&5
1779 (eval "$ac_compile") 2>conftest.err
1780 ac_status=$?
1781 if test -s conftest.err; then
1782 grep -v '^ *+' conftest.err >conftest.er1
1783 cat conftest.er1 >&5
1784 mv -f conftest.er1 conftest.err
1785 fi
1786 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1787 test $ac_status = 0; } && {
1788 test -z "$ac_c_werror_flag" ||
1789 test ! -s conftest.err
1790 } && test -s conftest.$ac_objext; then :
1791 ac_retval=0
1792 else
1793 $as_echo "$as_me: failed program was:" >&5
1794 sed 's/^/| /' conftest.$ac_ext >&5
1795
1796 ac_retval=1
1797 fi
1798 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1799 as_fn_set_status $ac_retval
1800
1801 } # ac_fn_c_try_compile
1802
1803 # ac_fn_c_try_cpp LINENO
1804 # ----------------------
1805 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1806 ac_fn_c_try_cpp ()
1807 {
1808 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1809 if { { ac_try="$ac_cpp conftest.$ac_ext"
1810 case "(($ac_try" in
1811 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1812 *) ac_try_echo=$ac_try;;
1813 esac
1814 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1815 $as_echo "$ac_try_echo"; } >&5
1816 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1817 ac_status=$?
1818 if test -s conftest.err; then
1819 grep -v '^ *+' conftest.err >conftest.er1
1820 cat conftest.er1 >&5
1821 mv -f conftest.er1 conftest.err
1822 fi
1823 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1824 test $ac_status = 0; } > conftest.i && {
1825 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1826 test ! -s conftest.err
1827 }; then :
1828 ac_retval=0
1829 else
1830 $as_echo "$as_me: failed program was:" >&5
1831 sed 's/^/| /' conftest.$ac_ext >&5
1832
1833 ac_retval=1
1834 fi
1835 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1836 as_fn_set_status $ac_retval
1837
1838 } # ac_fn_c_try_cpp
1839
1840 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1841 # -------------------------------------------------------
1842 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1843 # the include files in INCLUDES and setting the cache variable VAR
1844 # accordingly.
1845 ac_fn_c_check_header_mongrel ()
1846 {
1847 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1848 if eval \${$3+:} false; then :
1849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1850 $as_echo_n "checking for $2... " >&6; }
1851 if eval \${$3+:} false; then :
1852 $as_echo_n "(cached) " >&6
1853 fi
1854 eval ac_res=\$$3
1855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1856 $as_echo "$ac_res" >&6; }
1857 else
1858 # Is the header compilable?
1859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1860 $as_echo_n "checking $2 usability... " >&6; }
1861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1862 /* end confdefs.h. */
1863 $4
1864 #include <$2>
1865 _ACEOF
1866 if ac_fn_c_try_compile "$LINENO"; then :
1867 ac_header_compiler=yes
1868 else
1869 ac_header_compiler=no
1870 fi
1871 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1873 $as_echo "$ac_header_compiler" >&6; }
1874
1875 # Is the header present?
1876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1877 $as_echo_n "checking $2 presence... " >&6; }
1878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1879 /* end confdefs.h. */
1880 #include <$2>
1881 _ACEOF
1882 if ac_fn_c_try_cpp "$LINENO"; then :
1883 ac_header_preproc=yes
1884 else
1885 ac_header_preproc=no
1886 fi
1887 rm -f conftest.err conftest.i conftest.$ac_ext
1888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1889 $as_echo "$ac_header_preproc" >&6; }
1890
1891 # So? What about this header?
1892 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1893 yes:no: )
1894 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1895 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1896 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1897 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1898 ;;
1899 no:yes:* )
1900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1901 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1902 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1903 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1904 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1905 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1906 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1907 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1908 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1909 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1910 ( $as_echo "## --------------------------------------------------------------------------------------- ##
1911 ## Report this to unbound-bugs (at] nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues ##
1912 ## --------------------------------------------------------------------------------------- ##"
1913 ) | sed "s/^/$as_me: WARNING: /" >&2
1914 ;;
1915 esac
1916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1917 $as_echo_n "checking for $2... " >&6; }
1918 if eval \${$3+:} false; then :
1919 $as_echo_n "(cached) " >&6
1920 else
1921 eval "$3=\$ac_header_compiler"
1922 fi
1923 eval ac_res=\$$3
1924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1925 $as_echo "$ac_res" >&6; }
1926 fi
1927 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1928
1929 } # ac_fn_c_check_header_mongrel
1930
1931 # ac_fn_c_try_run LINENO
1932 # ----------------------
1933 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1934 # that executables *can* be run.
1935 ac_fn_c_try_run ()
1936 {
1937 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1938 if { { ac_try="$ac_link"
1939 case "(($ac_try" in
1940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1941 *) ac_try_echo=$ac_try;;
1942 esac
1943 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1944 $as_echo "$ac_try_echo"; } >&5
1945 (eval "$ac_link") 2>&5
1946 ac_status=$?
1947 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1948 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1949 { { case "(($ac_try" in
1950 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1951 *) ac_try_echo=$ac_try;;
1952 esac
1953 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1954 $as_echo "$ac_try_echo"; } >&5
1955 (eval "$ac_try") 2>&5
1956 ac_status=$?
1957 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1958 test $ac_status = 0; }; }; then :
1959 ac_retval=0
1960 else
1961 $as_echo "$as_me: program exited with status $ac_status" >&5
1962 $as_echo "$as_me: failed program was:" >&5
1963 sed 's/^/| /' conftest.$ac_ext >&5
1964
1965 ac_retval=$ac_status
1966 fi
1967 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1968 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1969 as_fn_set_status $ac_retval
1970
1971 } # ac_fn_c_try_run
1972
1973 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1974 # -------------------------------------------------------
1975 # Tests whether HEADER exists and can be compiled using the include files in
1976 # INCLUDES, setting the cache variable VAR accordingly.
1977 ac_fn_c_check_header_compile ()
1978 {
1979 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1981 $as_echo_n "checking for $2... " >&6; }
1982 if eval \${$3+:} false; then :
1983 $as_echo_n "(cached) " >&6
1984 else
1985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1986 /* end confdefs.h. */
1987 $4
1988 #include <$2>
1989 _ACEOF
1990 if ac_fn_c_try_compile "$LINENO"; then :
1991 eval "$3=yes"
1992 else
1993 eval "$3=no"
1994 fi
1995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1996 fi
1997 eval ac_res=\$$3
1998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1999 $as_echo "$ac_res" >&6; }
2000 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2001
2002 } # ac_fn_c_check_header_compile
2003
2004 # ac_fn_c_try_link LINENO
2005 # -----------------------
2006 # Try to link conftest.$ac_ext, and return whether this succeeded.
2007 ac_fn_c_try_link ()
2008 {
2009 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2010 rm -f conftest.$ac_objext conftest$ac_exeext
2011 if { { ac_try="$ac_link"
2012 case "(($ac_try" in
2013 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2014 *) ac_try_echo=$ac_try;;
2015 esac
2016 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2017 $as_echo "$ac_try_echo"; } >&5
2018 (eval "$ac_link") 2>conftest.err
2019 ac_status=$?
2020 if test -s conftest.err; then
2021 grep -v '^ *+' conftest.err >conftest.er1
2022 cat conftest.er1 >&5
2023 mv -f conftest.er1 conftest.err
2024 fi
2025 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2026 test $ac_status = 0; } && {
2027 test -z "$ac_c_werror_flag" ||
2028 test ! -s conftest.err
2029 } && test -s conftest$ac_exeext && {
2030 test "$cross_compiling" = yes ||
2031 test -x conftest$ac_exeext
2032 }; then :
2033 ac_retval=0
2034 else
2035 $as_echo "$as_me: failed program was:" >&5
2036 sed 's/^/| /' conftest.$ac_ext >&5
2037
2038 ac_retval=1
2039 fi
2040 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2041 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2042 # interfere with the next link command; also delete a directory that is
2043 # left behind by Apple's compiler. We do this before executing the actions.
2044 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2045 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2046 as_fn_set_status $ac_retval
2047
2048 } # ac_fn_c_try_link
2049
2050 # ac_fn_c_check_func LINENO FUNC VAR
2051 # ----------------------------------
2052 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2053 ac_fn_c_check_func ()
2054 {
2055 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2057 $as_echo_n "checking for $2... " >&6; }
2058 if eval \${$3+:} false; then :
2059 $as_echo_n "(cached) " >&6
2060 else
2061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2062 /* end confdefs.h. */
2063 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2064 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2065 #define $2 innocuous_$2
2066
2067 /* System header to define __stub macros and hopefully few prototypes,
2068 which can conflict with char $2 (); below.
2069 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2070 <limits.h> exists even on freestanding compilers. */
2071
2072 #ifdef __STDC__
2073 # include <limits.h>
2074 #else
2075 # include <assert.h>
2076 #endif
2077
2078 #undef $2
2079
2080 /* Override any GCC internal prototype to avoid an error.
2081 Use char because int might match the return type of a GCC
2082 builtin and then its argument prototype would still apply. */
2083 #ifdef __cplusplus
2084 extern "C"
2085 #endif
2086 char $2 ();
2087 /* The GNU C library defines this for functions which it implements
2088 to always fail with ENOSYS. Some functions are actually named
2089 something starting with __ and the normal name is an alias. */
2090 #if defined __stub_$2 || defined __stub___$2
2091 choke me
2092 #endif
2093
2094 int
2095 main ()
2096 {
2097 return $2 ();
2098 ;
2099 return 0;
2100 }
2101 _ACEOF
2102 if ac_fn_c_try_link "$LINENO"; then :
2103 eval "$3=yes"
2104 else
2105 eval "$3=no"
2106 fi
2107 rm -f core conftest.err conftest.$ac_objext \
2108 conftest$ac_exeext conftest.$ac_ext
2109 fi
2110 eval ac_res=\$$3
2111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2112 $as_echo "$ac_res" >&6; }
2113 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2114
2115 } # ac_fn_c_check_func
2116
2117 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2118 # -------------------------------------------
2119 # Tests whether TYPE exists after having included INCLUDES, setting cache
2120 # variable VAR accordingly.
2121 ac_fn_c_check_type ()
2122 {
2123 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2125 $as_echo_n "checking for $2... " >&6; }
2126 if eval \${$3+:} false; then :
2127 $as_echo_n "(cached) " >&6
2128 else
2129 eval "$3=no"
2130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2131 /* end confdefs.h. */
2132 $4
2133 int
2134 main ()
2135 {
2136 if (sizeof ($2))
2137 return 0;
2138 ;
2139 return 0;
2140 }
2141 _ACEOF
2142 if ac_fn_c_try_compile "$LINENO"; then :
2143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2144 /* end confdefs.h. */
2145 $4
2146 int
2147 main ()
2148 {
2149 if (sizeof (($2)))
2150 return 0;
2151 ;
2152 return 0;
2153 }
2154 _ACEOF
2155 if ac_fn_c_try_compile "$LINENO"; then :
2156
2157 else
2158 eval "$3=yes"
2159 fi
2160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2161 fi
2162 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2163 fi
2164 eval ac_res=\$$3
2165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2166 $as_echo "$ac_res" >&6; }
2167 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2168
2169 } # ac_fn_c_check_type
2170
2171 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2172 # --------------------------------------------
2173 # Tries to find the compile-time value of EXPR in a program that includes
2174 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2175 # computed
2176 ac_fn_c_compute_int ()
2177 {
2178 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2179 if test "$cross_compiling" = yes; then
2180 # Depending upon the size, compute the lo and hi bounds.
2181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2182 /* end confdefs.h. */
2183 $4
2184 int
2185 main ()
2186 {
2187 static int test_array [1 - 2 * !(($2) >= 0)];
2188 test_array [0] = 0;
2189 return test_array [0];
2190
2191 ;
2192 return 0;
2193 }
2194 _ACEOF
2195 if ac_fn_c_try_compile "$LINENO"; then :
2196 ac_lo=0 ac_mid=0
2197 while :; do
2198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2199 /* end confdefs.h. */
2200 $4
2201 int
2202 main ()
2203 {
2204 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2205 test_array [0] = 0;
2206 return test_array [0];
2207
2208 ;
2209 return 0;
2210 }
2211 _ACEOF
2212 if ac_fn_c_try_compile "$LINENO"; then :
2213 ac_hi=$ac_mid; break
2214 else
2215 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2216 if test $ac_lo -le $ac_mid; then
2217 ac_lo= ac_hi=
2218 break
2219 fi
2220 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2221 fi
2222 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2223 done
2224 else
2225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2226 /* end confdefs.h. */
2227 $4
2228 int
2229 main ()
2230 {
2231 static int test_array [1 - 2 * !(($2) < 0)];
2232 test_array [0] = 0;
2233 return test_array [0];
2234
2235 ;
2236 return 0;
2237 }
2238 _ACEOF
2239 if ac_fn_c_try_compile "$LINENO"; then :
2240 ac_hi=-1 ac_mid=-1
2241 while :; do
2242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2243 /* end confdefs.h. */
2244 $4
2245 int
2246 main ()
2247 {
2248 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2249 test_array [0] = 0;
2250 return test_array [0];
2251
2252 ;
2253 return 0;
2254 }
2255 _ACEOF
2256 if ac_fn_c_try_compile "$LINENO"; then :
2257 ac_lo=$ac_mid; break
2258 else
2259 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2260 if test $ac_mid -le $ac_hi; then
2261 ac_lo= ac_hi=
2262 break
2263 fi
2264 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2265 fi
2266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2267 done
2268 else
2269 ac_lo= ac_hi=
2270 fi
2271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2272 fi
2273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2274 # Binary search between lo and hi bounds.
2275 while test "x$ac_lo" != "x$ac_hi"; do
2276 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2278 /* end confdefs.h. */
2279 $4
2280 int
2281 main ()
2282 {
2283 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2284 test_array [0] = 0;
2285 return test_array [0];
2286
2287 ;
2288 return 0;
2289 }
2290 _ACEOF
2291 if ac_fn_c_try_compile "$LINENO"; then :
2292 ac_hi=$ac_mid
2293 else
2294 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2295 fi
2296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2297 done
2298 case $ac_lo in #((
2299 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2300 '') ac_retval=1 ;;
2301 esac
2302 else
2303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2304 /* end confdefs.h. */
2305 $4
2306 static long int longval () { return $2; }
2307 static unsigned long int ulongval () { return $2; }
2308 #include <stdio.h>
2309 #include <stdlib.h>
2310 int
2311 main ()
2312 {
2313
2314 FILE *f = fopen ("conftest.val", "w");
2315 if (! f)
2316 return 1;
2317 if (($2) < 0)
2318 {
2319 long int i = longval ();
2320 if (i != ($2))
2321 return 1;
2322 fprintf (f, "%ld", i);
2323 }
2324 else
2325 {
2326 unsigned long int i = ulongval ();
2327 if (i != ($2))
2328 return 1;
2329 fprintf (f, "%lu", i);
2330 }
2331 /* Do not output a trailing newline, as this causes \r\n confusion
2332 on some platforms. */
2333 return ferror (f) || fclose (f) != 0;
2334
2335 ;
2336 return 0;
2337 }
2338 _ACEOF
2339 if ac_fn_c_try_run "$LINENO"; then :
2340 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2341 else
2342 ac_retval=1
2343 fi
2344 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2345 conftest.$ac_objext conftest.beam conftest.$ac_ext
2346 rm -f conftest.val
2347
2348 fi
2349 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2350 as_fn_set_status $ac_retval
2351
2352 } # ac_fn_c_compute_int
2353
2354 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2355 # ---------------------------------------------
2356 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2357 # accordingly.
2358 ac_fn_c_check_decl ()
2359 {
2360 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2361 as_decl_name=`echo $2|sed 's/ *(.*//'`
2362 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2364 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2365 if eval \${$3+:} false; then :
2366 $as_echo_n "(cached) " >&6
2367 else
2368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2369 /* end confdefs.h. */
2370 $4
2371 int
2372 main ()
2373 {
2374 #ifndef $as_decl_name
2375 #ifdef __cplusplus
2376 (void) $as_decl_use;
2377 #else
2378 (void) $as_decl_name;
2379 #endif
2380 #endif
2381
2382 ;
2383 return 0;
2384 }
2385 _ACEOF
2386 if ac_fn_c_try_compile "$LINENO"; then :
2387 eval "$3=yes"
2388 else
2389 eval "$3=no"
2390 fi
2391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2392 fi
2393 eval ac_res=\$$3
2394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2395 $as_echo "$ac_res" >&6; }
2396 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2397
2398 } # ac_fn_c_check_decl
2399
2400 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2401 # ----------------------------------------------------
2402 # Tries to find if the field MEMBER exists in type AGGR, after including
2403 # INCLUDES, setting cache variable VAR accordingly.
2404 ac_fn_c_check_member ()
2405 {
2406 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2408 $as_echo_n "checking for $2.$3... " >&6; }
2409 if eval \${$4+:} false; then :
2410 $as_echo_n "(cached) " >&6
2411 else
2412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2413 /* end confdefs.h. */
2414 $5
2415 int
2416 main ()
2417 {
2418 static $2 ac_aggr;
2419 if (ac_aggr.$3)
2420 return 0;
2421 ;
2422 return 0;
2423 }
2424 _ACEOF
2425 if ac_fn_c_try_compile "$LINENO"; then :
2426 eval "$4=yes"
2427 else
2428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2429 /* end confdefs.h. */
2430 $5
2431 int
2432 main ()
2433 {
2434 static $2 ac_aggr;
2435 if (sizeof ac_aggr.$3)
2436 return 0;
2437 ;
2438 return 0;
2439 }
2440 _ACEOF
2441 if ac_fn_c_try_compile "$LINENO"; then :
2442 eval "$4=yes"
2443 else
2444 eval "$4=no"
2445 fi
2446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2447 fi
2448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2449 fi
2450 eval ac_res=\$$4
2451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2452 $as_echo "$ac_res" >&6; }
2453 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2454
2455 } # ac_fn_c_check_member
2456 cat >config.log <<_ACEOF
2457 This file contains any messages produced by compilers while
2458 running configure, to aid debugging if configure makes a mistake.
2459
2460 It was created by unbound $as_me 1.9.6, which was
2461 generated by GNU Autoconf 2.69. Invocation command line was
2462
2463 $ $0 $@
2464
2465 _ACEOF
2466 exec 5>>config.log
2467 {
2468 cat <<_ASUNAME
2469 ## --------- ##
2470 ## Platform. ##
2471 ## --------- ##
2472
2473 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2474 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2475 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2476 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2477 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2478
2479 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2480 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2481
2482 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2483 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2484 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2485 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2486 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2487 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2488 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2489
2490 _ASUNAME
2491
2492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2493 for as_dir in $PATH
2494 do
2495 IFS=$as_save_IFS
2496 test -z "$as_dir" && as_dir=.
2497 $as_echo "PATH: $as_dir"
2498 done
2499 IFS=$as_save_IFS
2500
2501 } >&5
2502
2503 cat >&5 <<_ACEOF
2504
2505
2506 ## ----------- ##
2507 ## Core tests. ##
2508 ## ----------- ##
2509
2510 _ACEOF
2511
2512
2513 # Keep a trace of the command line.
2514 # Strip out --no-create and --no-recursion so they do not pile up.
2515 # Strip out --silent because we don't want to record it for future runs.
2516 # Also quote any args containing shell meta-characters.
2517 # Make two passes to allow for proper duplicate-argument suppression.
2518 ac_configure_args=
2519 ac_configure_args0=
2520 ac_configure_args1=
2521 ac_must_keep_next=false
2522 for ac_pass in 1 2
2523 do
2524 for ac_arg
2525 do
2526 case $ac_arg in
2527 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2528 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2529 | -silent | --silent | --silen | --sile | --sil)
2530 continue ;;
2531 *\'*)
2532 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2533 esac
2534 case $ac_pass in
2535 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2536 2)
2537 as_fn_append ac_configure_args1 " '$ac_arg'"
2538 if test $ac_must_keep_next = true; then
2539 ac_must_keep_next=false # Got value, back to normal.
2540 else
2541 case $ac_arg in
2542 *=* | --config-cache | -C | -disable-* | --disable-* \
2543 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2544 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2545 | -with-* | --with-* | -without-* | --without-* | --x)
2546 case "$ac_configure_args0 " in
2547 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2548 esac
2549 ;;
2550 -* ) ac_must_keep_next=true ;;
2551 esac
2552 fi
2553 as_fn_append ac_configure_args " '$ac_arg'"
2554 ;;
2555 esac
2556 done
2557 done
2558 { ac_configure_args0=; unset ac_configure_args0;}
2559 { ac_configure_args1=; unset ac_configure_args1;}
2560
2561 # When interrupted or exit'd, cleanup temporary files, and complete
2562 # config.log. We remove comments because anyway the quotes in there
2563 # would cause problems or look ugly.
2564 # WARNING: Use '\'' to represent an apostrophe within the trap.
2565 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2566 trap 'exit_status=$?
2567 # Save into config.log some information that might help in debugging.
2568 {
2569 echo
2570
2571 $as_echo "## ---------------- ##
2572 ## Cache variables. ##
2573 ## ---------------- ##"
2574 echo
2575 # The following way of writing the cache mishandles newlines in values,
2576 (
2577 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2578 eval ac_val=\$$ac_var
2579 case $ac_val in #(
2580 *${as_nl}*)
2581 case $ac_var in #(
2582 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2583 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2584 esac
2585 case $ac_var in #(
2586 _ | IFS | as_nl) ;; #(
2587 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2588 *) { eval $ac_var=; unset $ac_var;} ;;
2589 esac ;;
2590 esac
2591 done
2592 (set) 2>&1 |
2593 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2594 *${as_nl}ac_space=\ *)
2595 sed -n \
2596 "s/'\''/'\''\\\\'\'''\''/g;
2597 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2598 ;; #(
2599 *)
2600 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2601 ;;
2602 esac |
2603 sort
2604 )
2605 echo
2606
2607 $as_echo "## ----------------- ##
2608 ## Output variables. ##
2609 ## ----------------- ##"
2610 echo
2611 for ac_var in $ac_subst_vars
2612 do
2613 eval ac_val=\$$ac_var
2614 case $ac_val in
2615 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2616 esac
2617 $as_echo "$ac_var='\''$ac_val'\''"
2618 done | sort
2619 echo
2620
2621 if test -n "$ac_subst_files"; then
2622 $as_echo "## ------------------- ##
2623 ## File substitutions. ##
2624 ## ------------------- ##"
2625 echo
2626 for ac_var in $ac_subst_files
2627 do
2628 eval ac_val=\$$ac_var
2629 case $ac_val in
2630 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2631 esac
2632 $as_echo "$ac_var='\''$ac_val'\''"
2633 done | sort
2634 echo
2635 fi
2636
2637 if test -s confdefs.h; then
2638 $as_echo "## ----------- ##
2639 ## confdefs.h. ##
2640 ## ----------- ##"
2641 echo
2642 cat confdefs.h
2643 echo
2644 fi
2645 test "$ac_signal" != 0 &&
2646 $as_echo "$as_me: caught signal $ac_signal"
2647 $as_echo "$as_me: exit $exit_status"
2648 } >&5
2649 rm -f core *.core core.conftest.* &&
2650 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2651 exit $exit_status
2652 ' 0
2653 for ac_signal in 1 2 13 15; do
2654 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2655 done
2656 ac_signal=0
2657
2658 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2659 rm -f -r conftest* confdefs.h
2660
2661 $as_echo "/* confdefs.h */" > confdefs.h
2662
2663 # Predefined preprocessor variables.
2664
2665 cat >>confdefs.h <<_ACEOF
2666 #define PACKAGE_NAME "$PACKAGE_NAME"
2667 _ACEOF
2668
2669 cat >>confdefs.h <<_ACEOF
2670 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2671 _ACEOF
2672
2673 cat >>confdefs.h <<_ACEOF
2674 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2675 _ACEOF
2676
2677 cat >>confdefs.h <<_ACEOF
2678 #define PACKAGE_STRING "$PACKAGE_STRING"
2679 _ACEOF
2680
2681 cat >>confdefs.h <<_ACEOF
2682 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2683 _ACEOF
2684
2685 cat >>confdefs.h <<_ACEOF
2686 #define PACKAGE_URL "$PACKAGE_URL"
2687 _ACEOF
2688
2689
2690 # Let the site file select an alternate cache file if it wants to.
2691 # Prefer an explicitly selected file to automatically selected ones.
2692 ac_site_file1=NONE
2693 ac_site_file2=NONE
2694 if test -n "$CONFIG_SITE"; then
2695 # We do not want a PATH search for config.site.
2696 case $CONFIG_SITE in #((
2697 -*) ac_site_file1=./$CONFIG_SITE;;
2698 */*) ac_site_file1=$CONFIG_SITE;;
2699 *) ac_site_file1=./$CONFIG_SITE;;
2700 esac
2701 elif test "x$prefix" != xNONE; then
2702 ac_site_file1=$prefix/share/config.site
2703 ac_site_file2=$prefix/etc/config.site
2704 else
2705 ac_site_file1=$ac_default_prefix/share/config.site
2706 ac_site_file2=$ac_default_prefix/etc/config.site
2707 fi
2708 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2709 do
2710 test "x$ac_site_file" = xNONE && continue
2711 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2712 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2713 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2714 sed 's/^/| /' "$ac_site_file" >&5
2715 . "$ac_site_file" \
2716 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2717 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2718 as_fn_error $? "failed to load site script $ac_site_file
2719 See \`config.log' for more details" "$LINENO" 5; }
2720 fi
2721 done
2722
2723 if test -r "$cache_file"; then
2724 # Some versions of bash will fail to source /dev/null (special files
2725 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2726 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2727 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2728 $as_echo "$as_me: loading cache $cache_file" >&6;}
2729 case $cache_file in
2730 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2731 *) . "./$cache_file";;
2732 esac
2733 fi
2734 else
2735 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2736 $as_echo "$as_me: creating cache $cache_file" >&6;}
2737 >$cache_file
2738 fi
2739
2740 # Check that the precious variables saved in the cache have kept the same
2741 # value.
2742 ac_cache_corrupted=false
2743 for ac_var in $ac_precious_vars; do
2744 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2745 eval ac_new_set=\$ac_env_${ac_var}_set
2746 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2747 eval ac_new_val=\$ac_env_${ac_var}_value
2748 case $ac_old_set,$ac_new_set in
2749 set,)
2750 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2751 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2752 ac_cache_corrupted=: ;;
2753 ,set)
2754 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2755 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2756 ac_cache_corrupted=: ;;
2757 ,);;
2758 *)
2759 if test "x$ac_old_val" != "x$ac_new_val"; then
2760 # differences in whitespace do not lead to failure.
2761 ac_old_val_w=`echo x $ac_old_val`
2762 ac_new_val_w=`echo x $ac_new_val`
2763 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2764 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2765 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2766 ac_cache_corrupted=:
2767 else
2768 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2769 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2770 eval $ac_var=\$ac_old_val
2771 fi
2772 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2773 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2775 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2776 fi;;
2777 esac
2778 # Pass precious variables to config.status.
2779 if test "$ac_new_set" = set; then
2780 case $ac_new_val in
2781 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2782 *) ac_arg=$ac_var=$ac_new_val ;;
2783 esac
2784 case " $ac_configure_args " in
2785 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2786 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2787 esac
2788 fi
2789 done
2790 if $ac_cache_corrupted; then
2791 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2792 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2793 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2794 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2795 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2796 fi
2797 ## -------------------- ##
2798 ## Main body of script. ##
2799 ## -------------------- ##
2800
2801 ac_ext=c
2802 ac_cpp='$CPP $CPPFLAGS'
2803 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2804 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2805 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2806
2807
2808 UNBOUND_VERSION_MAJOR=1
2809
2810 UNBOUND_VERSION_MINOR=9
2811
2812 UNBOUND_VERSION_MICRO=6
2813
2814
2815 LIBUNBOUND_CURRENT=9
2816 LIBUNBOUND_REVISION=6
2817 LIBUNBOUND_AGE=1
2818 # 1.0.0 had 0:12:0
2819 # 1.0.1 had 0:13:0
2820 # 1.0.2 had 0:14:0
2821 # 1.1.0 had 0:15:0
2822 # 1.1.1 had 0:16:0
2823 # 1.2.0 had 0:17:0
2824 # 1.2.1 had 0:18:0
2825 # 1.3.0 had 1:0:0 # ub_cancel and -export-symbols.
2826 # 1.3.1 had 1:1:0
2827 # 1.3.2 had 1:2:0
2828 # 1.3.3 had 1:3:0
2829 # 1.3.4 had 1:4:0
2830 # 1.4.0-snapshots had 1:5:0
2831 # 1.4.0 had 1:5:0 (not 2:0:0) # ub_result.why_bogus
2832 # 1.4.1 had 2:1:0
2833 # 1.4.2 had 2:2:0
2834 # 1.4.3 had 2:3:0
2835 # 1.4.4 had 2:4:0
2836 # 1.4.5 had 2:5:0
2837 # 1.4.6 had 2:6:0
2838 # 1.4.7 had 2:7:0
2839 # 1.4.8 had 2:8:0
2840 # 1.4.9 had 2:9:0
2841 # 1.4.10 had 2:10:0
2842 # 1.4.11 had 2:11:0
2843 # 1.4.12 had 2:12:0
2844 # 1.4.13 had 2:13:0
2845 # and 1.4.13p1 and 1.4.13.p2
2846 # 1.4.14 had 2:14:0
2847 # 1.4.15 had 3:0:1 # adds ub_version()
2848 # 1.4.16 had 3:1:1
2849 # 1.4.17 had 3:2:1
2850 # 1.4.18 had 3:3:1
2851 # 1.4.19 had 3:4:1
2852 # 1.4.20 had 4:0:2 # adds libunbound.ttl # but shipped 3:5:1
2853 # 1.4.21 had 4:1:2
2854 # 1.4.22 had 4:1:2
2855 # 1.5.0 had 5:3:3 # adds ub_ctx_add_ta_autr
2856 # 1.5.1 had 5:3:3
2857 # 1.5.2 had 5:5:3
2858 # 1.5.3 had 5:6:3
2859 # 1.5.4 had 5:7:3
2860 # 1.5.5 had 5:8:3
2861 # 1.5.6 had 5:9:3
2862 # 1.5.7 had 5:10:3
2863 # 1.5.8 had 6:0:4 # adds ub_ctx_set_stub
2864 # 1.5.9 had 6:1:4
2865 # 1.5.10 had 6:2:4
2866 # 1.6.0 had 6:3:4
2867 # 1.6.1 had 7:0:5 # ub_callback_t typedef renamed to ub_callback_type
2868 # 1.6.2 had 7:1:5
2869 # 1.6.3 had 7:2:5
2870 # 1.6.4 had 7:3:5
2871 # 1.6.5 had 7:4:5
2872 # 1.6.6 had 7:5:5
2873 # 1.6.7 had 7:6:5
2874 # 1.6.8 had 7:7:5
2875 # 1.7.0 had 7:8:5
2876 # 1.7.1 had 7:9:5
2877 # 1.7.2 had 7:10:5
2878 # 1.7.3 had 7:11:5
2879 # 1.8.0 had 8:0:0 # changes the event callback function signature
2880 # 1.8.1 had 8:1:0
2881 # 1.8.2 had 8:2:0
2882 # 1.8.3 had 8:3:0
2883 # 1.9.0 had 9:0:1 # add ub_ctx_set_tls
2884 # 1.9.1 had 9:1:1
2885 # 1.9.2 had 9:2:1
2886 # 1.9.3 had 9:3:1
2887 # 1.9.4 had 9:4:1
2888 # 1.9.5 had 9:5:1
2889 # 1.9.6 had 9:6:1
2890
2891 # Current -- the number of the binary API that we're implementing
2892 # Revision -- which iteration of the implementation of the binary
2893 # API are we supplying?
2894 # Age -- How many previous binary API versions do we also
2895 # support?
2896 #
2897 # If we release a new version that does not change the binary API,
2898 # increment Revision.
2899 #
2900 # If we release a new version that changes the binary API, but does
2901 # not break programs compiled against the old binary API, increment
2902 # Current and Age. Set Revision to 0, since this is the first
2903 # implementation of the new API.
2904 #
2905 # Otherwise, we're changing the binary API and breaking backward
2906 # compatibility with old binaries. Increment Current. Set Age to 0,
2907 # since we're backward compatible with no previous APIs. Set Revision
2908 # to 0 too.
2909
2910
2911
2912
2913
2914 cmdln="`echo $@ | sed -e 's/\\\\/\\\\\\\\/g' | sed -e 's/"/\\\\"/'g`"
2915
2916 cat >>confdefs.h <<_ACEOF
2917 #define CONFCMDLINE "$cmdln"
2918 _ACEOF
2919
2920
2921 CFLAGS="$CFLAGS"
2922 ac_ext=c
2923 ac_cpp='$CPP $CPPFLAGS'
2924 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2925 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2926 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2927 if test -n "$ac_tool_prefix"; then
2928 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2929 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2931 $as_echo_n "checking for $ac_word... " >&6; }
2932 if ${ac_cv_prog_CC+:} false; then :
2933 $as_echo_n "(cached) " >&6
2934 else
2935 if test -n "$CC"; then
2936 ac_cv_prog_CC="$CC" # Let the user override the test.
2937 else
2938 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2939 for as_dir in $PATH
2940 do
2941 IFS=$as_save_IFS
2942 test -z "$as_dir" && as_dir=.
2943 for ac_exec_ext in '' $ac_executable_extensions; do
2944 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2945 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2946 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2947 break 2
2948 fi
2949 done
2950 done
2951 IFS=$as_save_IFS
2952
2953 fi
2954 fi
2955 CC=$ac_cv_prog_CC
2956 if test -n "$CC"; then
2957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2958 $as_echo "$CC" >&6; }
2959 else
2960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2961 $as_echo "no" >&6; }
2962 fi
2963
2964
2965 fi
2966 if test -z "$ac_cv_prog_CC"; then
2967 ac_ct_CC=$CC
2968 # Extract the first word of "gcc", so it can be a program name with args.
2969 set dummy gcc; ac_word=$2
2970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2971 $as_echo_n "checking for $ac_word... " >&6; }
2972 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2973 $as_echo_n "(cached) " >&6
2974 else
2975 if test -n "$ac_ct_CC"; then
2976 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2977 else
2978 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2979 for as_dir in $PATH
2980 do
2981 IFS=$as_save_IFS
2982 test -z "$as_dir" && as_dir=.
2983 for ac_exec_ext in '' $ac_executable_extensions; do
2984 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2985 ac_cv_prog_ac_ct_CC="gcc"
2986 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2987 break 2
2988 fi
2989 done
2990 done
2991 IFS=$as_save_IFS
2992
2993 fi
2994 fi
2995 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2996 if test -n "$ac_ct_CC"; then
2997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2998 $as_echo "$ac_ct_CC" >&6; }
2999 else
3000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3001 $as_echo "no" >&6; }
3002 fi
3003
3004 if test "x$ac_ct_CC" = x; then
3005 CC=""
3006 else
3007 case $cross_compiling:$ac_tool_warned in
3008 yes:)
3009 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3010 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3011 ac_tool_warned=yes ;;
3012 esac
3013 CC=$ac_ct_CC
3014 fi
3015 else
3016 CC="$ac_cv_prog_CC"
3017 fi
3018
3019 if test -z "$CC"; then
3020 if test -n "$ac_tool_prefix"; then
3021 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3022 set dummy ${ac_tool_prefix}cc; ac_word=$2
3023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3024 $as_echo_n "checking for $ac_word... " >&6; }
3025 if ${ac_cv_prog_CC+:} false; then :
3026 $as_echo_n "(cached) " >&6
3027 else
3028 if test -n "$CC"; then
3029 ac_cv_prog_CC="$CC" # Let the user override the test.
3030 else
3031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3032 for as_dir in $PATH
3033 do
3034 IFS=$as_save_IFS
3035 test -z "$as_dir" && as_dir=.
3036 for ac_exec_ext in '' $ac_executable_extensions; do
3037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3038 ac_cv_prog_CC="${ac_tool_prefix}cc"
3039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3040 break 2
3041 fi
3042 done
3043 done
3044 IFS=$as_save_IFS
3045
3046 fi
3047 fi
3048 CC=$ac_cv_prog_CC
3049 if test -n "$CC"; then
3050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3051 $as_echo "$CC" >&6; }
3052 else
3053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3054 $as_echo "no" >&6; }
3055 fi
3056
3057
3058 fi
3059 fi
3060 if test -z "$CC"; then
3061 # Extract the first word of "cc", so it can be a program name with args.
3062 set dummy cc; ac_word=$2
3063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3064 $as_echo_n "checking for $ac_word... " >&6; }
3065 if ${ac_cv_prog_CC+:} false; then :
3066 $as_echo_n "(cached) " >&6
3067 else
3068 if test -n "$CC"; then
3069 ac_cv_prog_CC="$CC" # Let the user override the test.
3070 else
3071 ac_prog_rejected=no
3072 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3073 for as_dir in $PATH
3074 do
3075 IFS=$as_save_IFS
3076 test -z "$as_dir" && as_dir=.
3077 for ac_exec_ext in '' $ac_executable_extensions; do
3078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3079 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3080 ac_prog_rejected=yes
3081 continue
3082 fi
3083 ac_cv_prog_CC="cc"
3084 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3085 break 2
3086 fi
3087 done
3088 done
3089 IFS=$as_save_IFS
3090
3091 if test $ac_prog_rejected = yes; then
3092 # We found a bogon in the path, so make sure we never use it.
3093 set dummy $ac_cv_prog_CC
3094 shift
3095 if test $# != 0; then
3096 # We chose a different compiler from the bogus one.
3097 # However, it has the same basename, so the bogon will be chosen
3098 # first if we set CC to just the basename; use the full file name.
3099 shift
3100 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3101 fi
3102 fi
3103 fi
3104 fi
3105 CC=$ac_cv_prog_CC
3106 if test -n "$CC"; then
3107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3108 $as_echo "$CC" >&6; }
3109 else
3110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3111 $as_echo "no" >&6; }
3112 fi
3113
3114
3115 fi
3116 if test -z "$CC"; then
3117 if test -n "$ac_tool_prefix"; then
3118 for ac_prog in cl.exe
3119 do
3120 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3121 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3123 $as_echo_n "checking for $ac_word... " >&6; }
3124 if ${ac_cv_prog_CC+:} false; then :
3125 $as_echo_n "(cached) " >&6
3126 else
3127 if test -n "$CC"; then
3128 ac_cv_prog_CC="$CC" # Let the user override the test.
3129 else
3130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3131 for as_dir in $PATH
3132 do
3133 IFS=$as_save_IFS
3134 test -z "$as_dir" && as_dir=.
3135 for ac_exec_ext in '' $ac_executable_extensions; do
3136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3137 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3139 break 2
3140 fi
3141 done
3142 done
3143 IFS=$as_save_IFS
3144
3145 fi
3146 fi
3147 CC=$ac_cv_prog_CC
3148 if test -n "$CC"; then
3149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3150 $as_echo "$CC" >&6; }
3151 else
3152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3153 $as_echo "no" >&6; }
3154 fi
3155
3156
3157 test -n "$CC" && break
3158 done
3159 fi
3160 if test -z "$CC"; then
3161 ac_ct_CC=$CC
3162 for ac_prog in cl.exe
3163 do
3164 # Extract the first word of "$ac_prog", so it can be a program name with args.
3165 set dummy $ac_prog; ac_word=$2
3166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3167 $as_echo_n "checking for $ac_word... " >&6; }
3168 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3169 $as_echo_n "(cached) " >&6
3170 else
3171 if test -n "$ac_ct_CC"; then
3172 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3173 else
3174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3175 for as_dir in $PATH
3176 do
3177 IFS=$as_save_IFS
3178 test -z "$as_dir" && as_dir=.
3179 for ac_exec_ext in '' $ac_executable_extensions; do
3180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3181 ac_cv_prog_ac_ct_CC="$ac_prog"
3182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3183 break 2
3184 fi
3185 done
3186 done
3187 IFS=$as_save_IFS
3188
3189 fi
3190 fi
3191 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3192 if test -n "$ac_ct_CC"; then
3193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3194 $as_echo "$ac_ct_CC" >&6; }
3195 else
3196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3197 $as_echo "no" >&6; }
3198 fi
3199
3200
3201 test -n "$ac_ct_CC" && break
3202 done
3203
3204 if test "x$ac_ct_CC" = x; then
3205 CC=""
3206 else
3207 case $cross_compiling:$ac_tool_warned in
3208 yes:)
3209 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3210 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3211 ac_tool_warned=yes ;;
3212 esac
3213 CC=$ac_ct_CC
3214 fi
3215 fi
3216
3217 fi
3218
3219
3220 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3221 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3222 as_fn_error $? "no acceptable C compiler found in \$PATH
3223 See \`config.log' for more details" "$LINENO" 5; }
3224
3225 # Provide some information about the compiler.
3226 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3227 set X $ac_compile
3228 ac_compiler=$2
3229 for ac_option in --version -v -V -qversion; do
3230 { { ac_try="$ac_compiler $ac_option >&5"
3231 case "(($ac_try" in
3232 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3233 *) ac_try_echo=$ac_try;;
3234 esac
3235 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3236 $as_echo "$ac_try_echo"; } >&5
3237 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3238 ac_status=$?
3239 if test -s conftest.err; then
3240 sed '10a\
3241 ... rest of stderr output deleted ...
3242 10q' conftest.err >conftest.er1
3243 cat conftest.er1 >&5
3244 fi
3245 rm -f conftest.er1 conftest.err
3246 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3247 test $ac_status = 0; }
3248 done
3249
3250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3251 /* end confdefs.h. */
3252
3253 int
3254 main ()
3255 {
3256
3257 ;
3258 return 0;
3259 }
3260 _ACEOF
3261 ac_clean_files_save=$ac_clean_files
3262 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3263 # Try to create an executable without -o first, disregard a.out.
3264 # It will help us diagnose broken compilers, and finding out an intuition
3265 # of exeext.
3266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3267 $as_echo_n "checking whether the C compiler works... " >&6; }
3268 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3269
3270 # The possible output files:
3271 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3272
3273 ac_rmfiles=
3274 for ac_file in $ac_files
3275 do
3276 case $ac_file in
3277 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3278 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3279 esac
3280 done
3281 rm -f $ac_rmfiles
3282
3283 if { { ac_try="$ac_link_default"
3284 case "(($ac_try" in
3285 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3286 *) ac_try_echo=$ac_try;;
3287 esac
3288 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3289 $as_echo "$ac_try_echo"; } >&5
3290 (eval "$ac_link_default") 2>&5
3291 ac_status=$?
3292 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3293 test $ac_status = 0; }; then :
3294 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3295 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3296 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3297 # so that the user can short-circuit this test for compilers unknown to
3298 # Autoconf.
3299 for ac_file in $ac_files ''
3300 do
3301 test -f "$ac_file" || continue
3302 case $ac_file in
3303 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3304 ;;
3305 [ab].out )
3306 # We found the default executable, but exeext='' is most
3307 # certainly right.
3308 break;;
3309 *.* )
3310 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3311 then :; else
3312 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3313 fi
3314 # We set ac_cv_exeext here because the later test for it is not
3315 # safe: cross compilers may not add the suffix if given an `-o'
3316 # argument, so we may need to know it at that point already.
3317 # Even if this section looks crufty: it has the advantage of
3318 # actually working.
3319 break;;
3320 * )
3321 break;;
3322 esac
3323 done
3324 test "$ac_cv_exeext" = no && ac_cv_exeext=
3325
3326 else
3327 ac_file=''
3328 fi
3329 if test -z "$ac_file"; then :
3330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3331 $as_echo "no" >&6; }
3332 $as_echo "$as_me: failed program was:" >&5
3333 sed 's/^/| /' conftest.$ac_ext >&5
3334
3335 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3336 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3337 as_fn_error 77 "C compiler cannot create executables
3338 See \`config.log' for more details" "$LINENO" 5; }
3339 else
3340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3341 $as_echo "yes" >&6; }
3342 fi
3343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3344 $as_echo_n "checking for C compiler default output file name... " >&6; }
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3346 $as_echo "$ac_file" >&6; }
3347 ac_exeext=$ac_cv_exeext
3348
3349 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3350 ac_clean_files=$ac_clean_files_save
3351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3352 $as_echo_n "checking for suffix of executables... " >&6; }
3353 if { { ac_try="$ac_link"
3354 case "(($ac_try" in
3355 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3356 *) ac_try_echo=$ac_try;;
3357 esac
3358 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3359 $as_echo "$ac_try_echo"; } >&5
3360 (eval "$ac_link") 2>&5
3361 ac_status=$?
3362 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3363 test $ac_status = 0; }; then :
3364 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3365 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3366 # work properly (i.e., refer to `conftest.exe'), while it won't with
3367 # `rm'.
3368 for ac_file in conftest.exe conftest conftest.*; do
3369 test -f "$ac_file" || continue
3370 case $ac_file in
3371 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3372 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3373 break;;
3374 * ) break;;
3375 esac
3376 done
3377 else
3378 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3379 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3380 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3381 See \`config.log' for more details" "$LINENO" 5; }
3382 fi
3383 rm -f conftest conftest$ac_cv_exeext
3384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3385 $as_echo "$ac_cv_exeext" >&6; }
3386
3387 rm -f conftest.$ac_ext
3388 EXEEXT=$ac_cv_exeext
3389 ac_exeext=$EXEEXT
3390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3391 /* end confdefs.h. */
3392 #include <stdio.h>
3393 int
3394 main ()
3395 {
3396 FILE *f = fopen ("conftest.out", "w");
3397 return ferror (f) || fclose (f) != 0;
3398
3399 ;
3400 return 0;
3401 }
3402 _ACEOF
3403 ac_clean_files="$ac_clean_files conftest.out"
3404 # Check that the compiler produces executables we can run. If not, either
3405 # the compiler is broken, or we cross compile.
3406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3407 $as_echo_n "checking whether we are cross compiling... " >&6; }
3408 if test "$cross_compiling" != yes; then
3409 { { ac_try="$ac_link"
3410 case "(($ac_try" in
3411 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3412 *) ac_try_echo=$ac_try;;
3413 esac
3414 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3415 $as_echo "$ac_try_echo"; } >&5
3416 (eval "$ac_link") 2>&5
3417 ac_status=$?
3418 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3419 test $ac_status = 0; }
3420 if { ac_try='./conftest$ac_cv_exeext'
3421 { { case "(($ac_try" in
3422 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3423 *) ac_try_echo=$ac_try;;
3424 esac
3425 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3426 $as_echo "$ac_try_echo"; } >&5
3427 (eval "$ac_try") 2>&5
3428 ac_status=$?
3429 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3430 test $ac_status = 0; }; }; then
3431 cross_compiling=no
3432 else
3433 if test "$cross_compiling" = maybe; then
3434 cross_compiling=yes
3435 else
3436 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3437 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3438 as_fn_error $? "cannot run C compiled programs.
3439 If you meant to cross compile, use \`--host'.
3440 See \`config.log' for more details" "$LINENO" 5; }
3441 fi
3442 fi
3443 fi
3444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3445 $as_echo "$cross_compiling" >&6; }
3446
3447 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3448 ac_clean_files=$ac_clean_files_save
3449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3450 $as_echo_n "checking for suffix of object files... " >&6; }
3451 if ${ac_cv_objext+:} false; then :
3452 $as_echo_n "(cached) " >&6
3453 else
3454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3455 /* end confdefs.h. */
3456
3457 int
3458 main ()
3459 {
3460
3461 ;
3462 return 0;
3463 }
3464 _ACEOF
3465 rm -f conftest.o conftest.obj
3466 if { { ac_try="$ac_compile"
3467 case "(($ac_try" in
3468 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3469 *) ac_try_echo=$ac_try;;
3470 esac
3471 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3472 $as_echo "$ac_try_echo"; } >&5
3473 (eval "$ac_compile") 2>&5
3474 ac_status=$?
3475 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3476 test $ac_status = 0; }; then :
3477 for ac_file in conftest.o conftest.obj conftest.*; do
3478 test -f "$ac_file" || continue;
3479 case $ac_file in
3480 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3481 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3482 break;;
3483 esac
3484 done
3485 else
3486 $as_echo "$as_me: failed program was:" >&5
3487 sed 's/^/| /' conftest.$ac_ext >&5
3488
3489 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3490 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3491 as_fn_error $? "cannot compute suffix of object files: cannot compile
3492 See \`config.log' for more details" "$LINENO" 5; }
3493 fi
3494 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3495 fi
3496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3497 $as_echo "$ac_cv_objext" >&6; }
3498 OBJEXT=$ac_cv_objext
3499 ac_objext=$OBJEXT
3500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3501 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3502 if ${ac_cv_c_compiler_gnu+:} false; then :
3503 $as_echo_n "(cached) " >&6
3504 else
3505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3506 /* end confdefs.h. */
3507
3508 int
3509 main ()
3510 {
3511 #ifndef __GNUC__
3512 choke me
3513 #endif
3514
3515 ;
3516 return 0;
3517 }
3518 _ACEOF
3519 if ac_fn_c_try_compile "$LINENO"; then :
3520 ac_compiler_gnu=yes
3521 else
3522 ac_compiler_gnu=no
3523 fi
3524 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3525 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3526
3527 fi
3528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3529 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3530 if test $ac_compiler_gnu = yes; then
3531 GCC=yes
3532 else
3533 GCC=
3534 fi
3535 ac_test_CFLAGS=${CFLAGS+set}
3536 ac_save_CFLAGS=$CFLAGS
3537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3538 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3539 if ${ac_cv_prog_cc_g+:} false; then :
3540 $as_echo_n "(cached) " >&6
3541 else
3542 ac_save_c_werror_flag=$ac_c_werror_flag
3543 ac_c_werror_flag=yes
3544 ac_cv_prog_cc_g=no
3545 CFLAGS="-g"
3546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3547 /* end confdefs.h. */
3548
3549 int
3550 main ()
3551 {
3552
3553 ;
3554 return 0;
3555 }
3556 _ACEOF
3557 if ac_fn_c_try_compile "$LINENO"; then :
3558 ac_cv_prog_cc_g=yes
3559 else
3560 CFLAGS=""
3561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3562 /* end confdefs.h. */
3563
3564 int
3565 main ()
3566 {
3567
3568 ;
3569 return 0;
3570 }
3571 _ACEOF
3572 if ac_fn_c_try_compile "$LINENO"; then :
3573
3574 else
3575 ac_c_werror_flag=$ac_save_c_werror_flag
3576 CFLAGS="-g"
3577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3578 /* end confdefs.h. */
3579
3580 int
3581 main ()
3582 {
3583
3584 ;
3585 return 0;
3586 }
3587 _ACEOF
3588 if ac_fn_c_try_compile "$LINENO"; then :
3589 ac_cv_prog_cc_g=yes
3590 fi
3591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3592 fi
3593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3594 fi
3595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3596 ac_c_werror_flag=$ac_save_c_werror_flag
3597 fi
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3599 $as_echo "$ac_cv_prog_cc_g" >&6; }
3600 if test "$ac_test_CFLAGS" = set; then
3601 CFLAGS=$ac_save_CFLAGS
3602 elif test $ac_cv_prog_cc_g = yes; then
3603 if test "$GCC" = yes; then
3604 CFLAGS="-g -O2"
3605 else
3606 CFLAGS="-g"
3607 fi
3608 else
3609 if test "$GCC" = yes; then
3610 CFLAGS="-O2"
3611 else
3612 CFLAGS=
3613 fi
3614 fi
3615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3616 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3617 if ${ac_cv_prog_cc_c89+:} false; then :
3618 $as_echo_n "(cached) " >&6
3619 else
3620 ac_cv_prog_cc_c89=no
3621 ac_save_CC=$CC
3622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3623 /* end confdefs.h. */
3624 #include <stdarg.h>
3625 #include <stdio.h>
3626 struct stat;
3627 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3628 struct buf { int x; };
3629 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3630 static char *e (p, i)
3631 char **p;
3632 int i;
3633 {
3634 return p[i];
3635 }
3636 static char *f (char * (*g) (char **, int), char **p, ...)
3637 {
3638 char *s;
3639 va_list v;
3640 va_start (v,p);
3641 s = g (p, va_arg (v,int));
3642 va_end (v);
3643 return s;
3644 }
3645
3646 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3647 function prototypes and stuff, but not '\xHH' hex character constants.
3648 These don't provoke an error unfortunately, instead are silently treated
3649 as 'x'. The following induces an error, until -std is added to get
3650 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3651 array size at least. It's necessary to write '\x00'==0 to get something
3652 that's true only with -std. */
3653 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3654
3655 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3656 inside strings and character constants. */
3657 #define FOO(x) 'x'
3658 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3659
3660 int test (int i, double x);
3661 struct s1 {int (*f) (int a);};
3662 struct s2 {int (*f) (double a);};
3663 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3664 int argc;
3665 char **argv;
3666 int
3667 main ()
3668 {
3669 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3670 ;
3671 return 0;
3672 }
3673 _ACEOF
3674 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3675 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3676 do
3677 CC="$ac_save_CC $ac_arg"
3678 if ac_fn_c_try_compile "$LINENO"; then :
3679 ac_cv_prog_cc_c89=$ac_arg
3680 fi
3681 rm -f core conftest.err conftest.$ac_objext
3682 test "x$ac_cv_prog_cc_c89" != "xno" && break
3683 done
3684 rm -f conftest.$ac_ext
3685 CC=$ac_save_CC
3686
3687 fi
3688 # AC_CACHE_VAL
3689 case "x$ac_cv_prog_cc_c89" in
3690 x)
3691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3692 $as_echo "none needed" >&6; } ;;
3693 xno)
3694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3695 $as_echo "unsupported" >&6; } ;;
3696 *)
3697 CC="$CC $ac_cv_prog_cc_c89"
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3699 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3700 esac
3701 if test "x$ac_cv_prog_cc_c89" != xno; then :
3702
3703 fi
3704
3705 ac_ext=c
3706 ac_cpp='$CPP $CPPFLAGS'
3707 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3708 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3709 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3710
3711
3712 ac_ext=c
3713 ac_cpp='$CPP $CPPFLAGS'
3714 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3715 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3716 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3718 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3719 # On Suns, sometimes $CPP names a directory.
3720 if test -n "$CPP" && test -d "$CPP"; then
3721 CPP=
3722 fi
3723 if test -z "$CPP"; then
3724 if ${ac_cv_prog_CPP+:} false; then :
3725 $as_echo_n "(cached) " >&6
3726 else
3727 # Double quotes because CPP needs to be expanded
3728 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3729 do
3730 ac_preproc_ok=false
3731 for ac_c_preproc_warn_flag in '' yes
3732 do
3733 # Use a header file that comes with gcc, so configuring glibc
3734 # with a fresh cross-compiler works.
3735 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3736 # <limits.h> exists even on freestanding compilers.
3737 # On the NeXT, cc -E runs the code through the compiler's parser,
3738 # not just through cpp. "Syntax error" is here to catch this case.
3739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3740 /* end confdefs.h. */
3741 #ifdef __STDC__
3742 # include <limits.h>
3743 #else
3744 # include <assert.h>
3745 #endif
3746 Syntax error
3747 _ACEOF
3748 if ac_fn_c_try_cpp "$LINENO"; then :
3749
3750 else
3751 # Broken: fails on valid input.
3752 continue
3753 fi
3754 rm -f conftest.err conftest.i conftest.$ac_ext
3755
3756 # OK, works on sane cases. Now check whether nonexistent headers
3757 # can be detected and how.
3758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3759 /* end confdefs.h. */
3760 #include <ac_nonexistent.h>
3761 _ACEOF
3762 if ac_fn_c_try_cpp "$LINENO"; then :
3763 # Broken: success on invalid input.
3764 continue
3765 else
3766 # Passes both tests.
3767 ac_preproc_ok=:
3768 break
3769 fi
3770 rm -f conftest.err conftest.i conftest.$ac_ext
3771
3772 done
3773 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3774 rm -f conftest.i conftest.err conftest.$ac_ext
3775 if $ac_preproc_ok; then :
3776 break
3777 fi
3778
3779 done
3780 ac_cv_prog_CPP=$CPP
3781
3782 fi
3783 CPP=$ac_cv_prog_CPP
3784 else
3785 ac_cv_prog_CPP=$CPP
3786 fi
3787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3788 $as_echo "$CPP" >&6; }
3789 ac_preproc_ok=false
3790 for ac_c_preproc_warn_flag in '' yes
3791 do
3792 # Use a header file that comes with gcc, so configuring glibc
3793 # with a fresh cross-compiler works.
3794 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3795 # <limits.h> exists even on freestanding compilers.
3796 # On the NeXT, cc -E runs the code through the compiler's parser,
3797 # not just through cpp. "Syntax error" is here to catch this case.
3798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3799 /* end confdefs.h. */
3800 #ifdef __STDC__
3801 # include <limits.h>
3802 #else
3803 # include <assert.h>
3804 #endif
3805 Syntax error
3806 _ACEOF
3807 if ac_fn_c_try_cpp "$LINENO"; then :
3808
3809 else
3810 # Broken: fails on valid input.
3811 continue
3812 fi
3813 rm -f conftest.err conftest.i conftest.$ac_ext
3814
3815 # OK, works on sane cases. Now check whether nonexistent headers
3816 # can be detected and how.
3817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3818 /* end confdefs.h. */
3819 #include <ac_nonexistent.h>
3820 _ACEOF
3821 if ac_fn_c_try_cpp "$LINENO"; then :
3822 # Broken: success on invalid input.
3823 continue
3824 else
3825 # Passes both tests.
3826 ac_preproc_ok=:
3827 break
3828 fi
3829 rm -f conftest.err conftest.i conftest.$ac_ext
3830
3831 done
3832 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3833 rm -f conftest.i conftest.err conftest.$ac_ext
3834 if $ac_preproc_ok; then :
3835
3836 else
3837 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3838 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3839 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3840 See \`config.log' for more details" "$LINENO" 5; }
3841 fi
3842
3843 ac_ext=c
3844 ac_cpp='$CPP $CPPFLAGS'
3845 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3846 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3847 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3848
3849
3850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3851 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3852 if ${ac_cv_path_GREP+:} false; then :
3853 $as_echo_n "(cached) " >&6
3854 else
3855 if test -z "$GREP"; then
3856 ac_path_GREP_found=false
3857 # Loop through the user's path and test for each of PROGNAME-LIST
3858 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3859 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3860 do
3861 IFS=$as_save_IFS
3862 test -z "$as_dir" && as_dir=.
3863 for ac_prog in grep ggrep; do
3864 for ac_exec_ext in '' $ac_executable_extensions; do
3865 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3866 as_fn_executable_p "$ac_path_GREP" || continue
3867 # Check for GNU ac_path_GREP and select it if it is found.
3868 # Check for GNU $ac_path_GREP
3869 case `"$ac_path_GREP" --version 2>&1` in
3870 *GNU*)
3871 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3872 *)
3873 ac_count=0
3874 $as_echo_n 0123456789 >"conftest.in"
3875 while :
3876 do
3877 cat "conftest.in" "conftest.in" >"conftest.tmp"
3878 mv "conftest.tmp" "conftest.in"
3879 cp "conftest.in" "conftest.nl"
3880 $as_echo 'GREP' >> "conftest.nl"
3881 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3882 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3883 as_fn_arith $ac_count + 1 && ac_count=$as_val
3884 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3885 # Best one so far, save it but keep looking for a better one
3886 ac_cv_path_GREP="$ac_path_GREP"
3887 ac_path_GREP_max=$ac_count
3888 fi
3889 # 10*(2^10) chars as input seems more than enough
3890 test $ac_count -gt 10 && break
3891 done
3892 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3893 esac
3894
3895 $ac_path_GREP_found && break 3
3896 done
3897 done
3898 done
3899 IFS=$as_save_IFS
3900 if test -z "$ac_cv_path_GREP"; then
3901 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3902 fi
3903 else
3904 ac_cv_path_GREP=$GREP
3905 fi
3906
3907 fi
3908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3909 $as_echo "$ac_cv_path_GREP" >&6; }
3910 GREP="$ac_cv_path_GREP"
3911
3912
3913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3914 $as_echo_n "checking for egrep... " >&6; }
3915 if ${ac_cv_path_EGREP+:} false; then :
3916 $as_echo_n "(cached) " >&6
3917 else
3918 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3919 then ac_cv_path_EGREP="$GREP -E"
3920 else
3921 if test -z "$EGREP"; then
3922 ac_path_EGREP_found=false
3923 # Loop through the user's path and test for each of PROGNAME-LIST
3924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3925 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3926 do
3927 IFS=$as_save_IFS
3928 test -z "$as_dir" && as_dir=.
3929 for ac_prog in egrep; do
3930 for ac_exec_ext in '' $ac_executable_extensions; do
3931 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3932 as_fn_executable_p "$ac_path_EGREP" || continue
3933 # Check for GNU ac_path_EGREP and select it if it is found.
3934 # Check for GNU $ac_path_EGREP
3935 case `"$ac_path_EGREP" --version 2>&1` in
3936 *GNU*)
3937 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3938 *)
3939 ac_count=0
3940 $as_echo_n 0123456789 >"conftest.in"
3941 while :
3942 do
3943 cat "conftest.in" "conftest.in" >"conftest.tmp"
3944 mv "conftest.tmp" "conftest.in"
3945 cp "conftest.in" "conftest.nl"
3946 $as_echo 'EGREP' >> "conftest.nl"
3947 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3948 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3949 as_fn_arith $ac_count + 1 && ac_count=$as_val
3950 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3951 # Best one so far, save it but keep looking for a better one
3952 ac_cv_path_EGREP="$ac_path_EGREP"
3953 ac_path_EGREP_max=$ac_count
3954 fi
3955 # 10*(2^10) chars as input seems more than enough
3956 test $ac_count -gt 10 && break
3957 done
3958 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3959 esac
3960
3961 $ac_path_EGREP_found && break 3
3962 done
3963 done
3964 done
3965 IFS=$as_save_IFS
3966 if test -z "$ac_cv_path_EGREP"; then
3967 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3968 fi
3969 else
3970 ac_cv_path_EGREP=$EGREP
3971 fi
3972
3973 fi
3974 fi
3975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3976 $as_echo "$ac_cv_path_EGREP" >&6; }
3977 EGREP="$ac_cv_path_EGREP"
3978
3979
3980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3981 $as_echo_n "checking for ANSI C header files... " >&6; }
3982 if ${ac_cv_header_stdc+:} false; then :
3983 $as_echo_n "(cached) " >&6
3984 else
3985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3986 /* end confdefs.h. */
3987 #include <stdlib.h>
3988 #include <stdarg.h>
3989 #include <string.h>
3990 #include <float.h>
3991
3992 int
3993 main ()
3994 {
3995
3996 ;
3997 return 0;
3998 }
3999 _ACEOF
4000 if ac_fn_c_try_compile "$LINENO"; then :
4001 ac_cv_header_stdc=yes
4002 else
4003 ac_cv_header_stdc=no
4004 fi
4005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4006
4007 if test $ac_cv_header_stdc = yes; then
4008 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4010 /* end confdefs.h. */
4011 #include <string.h>
4012
4013 _ACEOF
4014 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4015 $EGREP "memchr" >/dev/null 2>&1; then :
4016
4017 else
4018 ac_cv_header_stdc=no
4019 fi
4020 rm -f conftest*
4021
4022 fi
4023
4024 if test $ac_cv_header_stdc = yes; then
4025 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4027 /* end confdefs.h. */
4028 #include <stdlib.h>
4029
4030 _ACEOF
4031 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4032 $EGREP "free" >/dev/null 2>&1; then :
4033
4034 else
4035 ac_cv_header_stdc=no
4036 fi
4037 rm -f conftest*
4038
4039 fi
4040
4041 if test $ac_cv_header_stdc = yes; then
4042 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4043 if test "$cross_compiling" = yes; then :
4044 :
4045 else
4046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4047 /* end confdefs.h. */
4048 #include <ctype.h>
4049 #include <stdlib.h>
4050 #if ((' ' & 0x0FF) == 0x020)
4051 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4052 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4053 #else
4054 # define ISLOWER(c) \
4055 (('a' <= (c) && (c) <= 'i') \
4056 || ('j' <= (c) && (c) <= 'r') \
4057 || ('s' <= (c) && (c) <= 'z'))
4058 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4059 #endif
4060
4061 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4062 int
4063 main ()
4064 {
4065 int i;
4066 for (i = 0; i < 256; i++)
4067 if (XOR (islower (i), ISLOWER (i))
4068 || toupper (i) != TOUPPER (i))
4069 return 2;
4070 return 0;
4071 }
4072 _ACEOF
4073 if ac_fn_c_try_run "$LINENO"; then :
4074
4075 else
4076 ac_cv_header_stdc=no
4077 fi
4078 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4079 conftest.$ac_objext conftest.beam conftest.$ac_ext
4080 fi
4081
4082 fi
4083 fi
4084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4085 $as_echo "$ac_cv_header_stdc" >&6; }
4086 if test $ac_cv_header_stdc = yes; then
4087
4088 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4089
4090 fi
4091
4092 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4093 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4094 inttypes.h stdint.h unistd.h
4095 do :
4096 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4097 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4098 "
4099 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4100 cat >>confdefs.h <<_ACEOF
4101 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4102 _ACEOF
4103
4104 fi
4105
4106 done
4107
4108
4109
4110 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4111 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4112 MINIX=yes
4113 else
4114 MINIX=
4115 fi
4116
4117
4118 if test "$MINIX" = yes; then
4119
4120 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4121
4122
4123 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4124
4125
4126 $as_echo "#define _MINIX 1" >>confdefs.h
4127
4128 fi
4129
4130
4131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4132 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4133 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4134 $as_echo_n "(cached) " >&6
4135 else
4136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4137 /* end confdefs.h. */
4138
4139 # define __EXTENSIONS__ 1
4140 $ac_includes_default
4141 int
4142 main ()
4143 {
4144
4145 ;
4146 return 0;
4147 }
4148 _ACEOF
4149 if ac_fn_c_try_compile "$LINENO"; then :
4150 ac_cv_safe_to_define___extensions__=yes
4151 else
4152 ac_cv_safe_to_define___extensions__=no
4153 fi
4154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4155 fi
4156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4157 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4158 test $ac_cv_safe_to_define___extensions__ = yes &&
4159 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4160
4161 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4162
4163 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4164
4165 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4166
4167 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4168
4169
4170
4171 if test "$ac_cv_header_minix_config_h" = "yes"; then
4172
4173 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
4174
4175 fi
4176
4177 case "$prefix" in
4178 NONE)
4179 prefix="/usr/local"
4180 ;;
4181 esac
4182 case "$exec_prefix" in
4183 NONE)
4184 exec_prefix="$prefix"
4185 ;;
4186 esac
4187
4188 # are we on MinGW?
4189 if uname -s 2>&1 | grep MINGW32 >/dev/null; then on_mingw="yes"
4190 else
4191 if echo $host $target | grep mingw32 >/dev/null; then on_mingw="yes"
4192 else on_mingw="no"; fi
4193 fi
4194
4195 #
4196 # Determine configuration file
4197 # the eval is to evaluate shell expansion twice
4198 UNBOUND_SBIN_DIR=`eval echo "${sbindir}"`
4199
4200 UNBOUND_SYSCONF_DIR=`eval echo "${sysconfdir}"`
4201
4202 UNBOUND_LOCALSTATE_DIR=`eval echo "${localstatedir}"`
4203
4204 if test $on_mingw = "no"; then
4205 ub_conf_file=`eval echo "${sysconfdir}/unbound/unbound.conf"`
4206 else
4207 ub_conf_file="C:\\Program Files\\Unbound\\service.conf"
4208 fi
4209
4210 # Check whether --with-conf_file was given.
4211 if test "${with_conf_file+set}" = set; then :
4212 withval=$with_conf_file; ub_conf_file="$withval"
4213 fi
4214
4215
4216 hdr_config="`echo $ub_conf_file | sed -e 's/\\\\/\\\\\\\\/g'`"
4217
4218
4219 cat >>confdefs.h <<_ACEOF
4220 #define CONFIGFILE "$hdr_config"
4221 _ACEOF
4222
4223 ub_conf_dir=`$as_dirname -- "$ub_conf_file" ||
4224 $as_expr X"$ub_conf_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
4225 X"$ub_conf_file" : 'X\(//\)[^/]' \| \
4226 X"$ub_conf_file" : 'X\(//\)$' \| \
4227 X"$ub_conf_file" : 'X\(/\)' \| . 2>/dev/null ||
4228 $as_echo X"$ub_conf_file" |
4229 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
4230 s//\1/
4231 q
4232 }
4233 /^X\(\/\/\)[^/].*/{
4234 s//\1/
4235 q
4236 }
4237 /^X\(\/\/\)$/{
4238 s//\1/
4239 q
4240 }
4241 /^X\(\/\).*/{
4242 s//\1/
4243 q
4244 }
4245 s/.*/./; q'`
4246
4247
4248 # Determine run, chroot directory and pidfile locations
4249
4250 # Check whether --with-run-dir was given.
4251 if test "${with_run_dir+set}" = set; then :
4252 withval=$with_run_dir; UNBOUND_RUN_DIR="$withval"
4253 else
4254 if test $on_mingw = no; then
4255 UNBOUND_RUN_DIR=`dirname "$ub_conf_file"`
4256 else
4257 UNBOUND_RUN_DIR=""
4258 fi
4259
4260 fi
4261
4262
4263 hdr_run="`echo $UNBOUND_RUN_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4264
4265
4266 cat >>confdefs.h <<_ACEOF
4267 #define RUN_DIR "$hdr_run"
4268 _ACEOF
4269
4270
4271
4272 # Check whether --with-chroot-dir was given.
4273 if test "${with_chroot_dir+set}" = set; then :
4274 withval=$with_chroot_dir; UNBOUND_CHROOT_DIR="$withval"
4275 else
4276 if test $on_mingw = no; then
4277 UNBOUND_CHROOT_DIR="$UNBOUND_RUN_DIR"
4278 else
4279 UNBOUND_CHROOT_DIR=""
4280 fi
4281
4282 fi
4283
4284
4285 hdr_chroot="`echo $UNBOUND_CHROOT_DIR | sed -e 's/\\\\/\\\\\\\\/g'`"
4286
4287
4288 cat >>confdefs.h <<_ACEOF
4289 #define CHROOT_DIR "$hdr_chroot"
4290 _ACEOF
4291
4292
4293
4294 # Check whether --with-share-dir was given.
4295 if test "${with_share_dir+set}" = set; then :
4296 withval=$with_share_dir; UNBOUND_SHARE_DIR="$withval"
4297 else
4298 UNBOUND_SHARE_DIR="$UNBOUND_RUN_DIR"
4299 fi
4300
4301
4302
4303 cat >>confdefs.h <<_ACEOF
4304 #define SHARE_DIR "$UNBOUND_SHARE_DIR"
4305 _ACEOF
4306
4307
4308
4309 # Check whether --with-pidfile was given.
4310 if test "${with_pidfile+set}" = set; then :
4311 withval=$with_pidfile; UNBOUND_PIDFILE="$withval"
4312 else
4313 if test $on_mingw = no; then
4314 UNBOUND_PIDFILE="$UNBOUND_RUN_DIR/unbound.pid"
4315 else
4316 UNBOUND_PIDFILE=""
4317 fi
4318
4319 fi
4320
4321
4322 hdr_pid="`echo $UNBOUND_PIDFILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4323
4324
4325 cat >>confdefs.h <<_ACEOF
4326 #define PIDFILE "$hdr_pid"
4327 _ACEOF
4328
4329
4330
4331 # Check whether --with-rootkey-file was given.
4332 if test "${with_rootkey_file+set}" = set; then :
4333 withval=$with_rootkey_file; UNBOUND_ROOTKEY_FILE="$withval"
4334 else
4335 if test $on_mingw = no; then
4336 UNBOUND_ROOTKEY_FILE="$UNBOUND_RUN_DIR/root.key"
4337 else
4338 UNBOUND_ROOTKEY_FILE="C:\\Program Files\\Unbound\\root.key"
4339 fi
4340
4341 fi
4342
4343
4344 hdr_rkey="`echo $UNBOUND_ROOTKEY_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4345
4346
4347 cat >>confdefs.h <<_ACEOF
4348 #define ROOT_ANCHOR_FILE "$hdr_rkey"
4349 _ACEOF
4350
4351
4352
4353 # Check whether --with-rootcert-file was given.
4354 if test "${with_rootcert_file+set}" = set; then :
4355 withval=$with_rootcert_file; UNBOUND_ROOTCERT_FILE="$withval"
4356 else
4357 if test $on_mingw = no; then
4358 UNBOUND_ROOTCERT_FILE="$UNBOUND_RUN_DIR/icannbundle.pem"
4359 else
4360 UNBOUND_ROOTCERT_FILE="C:\\Program Files\\Unbound\\icannbundle.pem"
4361 fi
4362
4363 fi
4364
4365
4366 hdr_rpem="`echo $UNBOUND_ROOTCERT_FILE | sed -e 's/\\\\/\\\\\\\\/g'`"
4367
4368
4369 cat >>confdefs.h <<_ACEOF
4370 #define ROOT_CERT_FILE "$hdr_rpem"
4371 _ACEOF
4372
4373
4374
4375 # Check whether --with-username was given.
4376 if test "${with_username+set}" = set; then :
4377 withval=$with_username; UNBOUND_USERNAME="$withval"
4378 else
4379 UNBOUND_USERNAME="unbound"
4380 fi
4381
4382
4383
4384 cat >>confdefs.h <<_ACEOF
4385 #define UB_USERNAME "$UNBOUND_USERNAME"
4386 _ACEOF
4387
4388
4389
4390 $as_echo "#define WINVER 0x0502" >>confdefs.h
4391
4392 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/' `
4393
4394
4395 cat >>confdefs.h <<_ACEOF
4396 #define RSRC_PACKAGE_VERSION $wnvs
4397 _ACEOF
4398
4399
4400 # Checks for typedefs, structures, and compiler characteristics.
4401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
4402 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
4403 if ${ac_cv_c_const+:} false; then :
4404 $as_echo_n "(cached) " >&6
4405 else
4406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4407 /* end confdefs.h. */
4408
4409 int
4410 main ()
4411 {
4412
4413 #ifndef __cplusplus
4414 /* Ultrix mips cc rejects this sort of thing. */
4415 typedef int charset[2];
4416 const charset cs = { 0, 0 };
4417 /* SunOS 4.1.1 cc rejects this. */
4418 char const *const *pcpcc;
4419 char **ppc;
4420 /* NEC SVR4.0.2 mips cc rejects this. */
4421 struct point {int x, y;};
4422 static struct point const zero = {0,0};
4423 /* AIX XL C 1.02.0.0 rejects this.
4424 It does not let you subtract one const X* pointer from another in
4425 an arm of an if-expression whose if-part is not a constant
4426 expression */
4427 const char *g = "string";
4428 pcpcc = &g + (g ? g-g : 0);
4429 /* HPUX 7.0 cc rejects these. */
4430 ++pcpcc;
4431 ppc = (char**) pcpcc;
4432 pcpcc = (char const *const *) ppc;
4433 { /* SCO 3.2v4 cc rejects this sort of thing. */
4434 char tx;
4435 char *t = &tx;
4436 char const *s = 0 ? (char *) 0 : (char const *) 0;
4437
4438 *t++ = 0;
4439 if (s) return 0;
4440 }
4441 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
4442 int x[] = {25, 17};
4443 const int *foo = &x[0];
4444 ++foo;
4445 }
4446 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4447 typedef const int *iptr;
4448 iptr p = 0;
4449 ++p;
4450 }
4451 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
4452 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4453 struct s { int j; const int *ap[3]; } bx;
4454 struct s *b = &bx; b->j = 5;
4455 }
4456 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4457 const int foo = 10;
4458 if (!foo) return 0;
4459 }
4460 return !cs[0] && !zero.x;
4461 #endif
4462
4463 ;
4464 return 0;
4465 }
4466 _ACEOF
4467 if ac_fn_c_try_compile "$LINENO"; then :
4468 ac_cv_c_const=yes
4469 else
4470 ac_cv_c_const=no
4471 fi
4472 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4473 fi
4474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
4475 $as_echo "$ac_cv_c_const" >&6; }
4476 if test $ac_cv_c_const = no; then
4477
4478 $as_echo "#define const /**/" >>confdefs.h
4479
4480 fi
4481
4482 ac_ext=c
4483 ac_cpp='$CPP $CPPFLAGS'
4484 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4485 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4486 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4487
4488 # allow user to override the -g -O2 flags.
4489 default_cflags=no
4490 if test "x$CFLAGS" = "x" ; then
4491
4492
4493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -g" >&5
4494 $as_echo_n "checking whether $CC supports -g... " >&6; }
4495 cache=`echo g | sed 'y%.=/+-%___p_%'`
4496 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4497 $as_echo_n "(cached) " >&6
4498 else
4499
4500 echo 'void f(void){}' >conftest.c
4501 if test -z "`$CC $CPPFLAGS $CFLAGS -g -c conftest.c 2>&1`"; then
4502 eval "cv_prog_cc_flag_$cache=yes"
4503 else
4504 eval "cv_prog_cc_flag_$cache=no"
4505 fi
4506 rm -f conftest conftest.o conftest.c
4507
4508 fi
4509
4510 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4512 $as_echo "yes" >&6; }
4513 :
4514 CFLAGS="$CFLAGS -g"
4515 else
4516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4517 $as_echo "no" >&6; }
4518 :
4519
4520 fi
4521
4522
4523
4524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -O2" >&5
4525 $as_echo_n "checking whether $CC supports -O2... " >&6; }
4526 cache=`echo O2 | sed 'y%.=/+-%___p_%'`
4527 if eval \${cv_prog_cc_flag_$cache+:} false; then :
4528 $as_echo_n "(cached) " >&6
4529 else
4530
4531 echo 'void f(void){}' >conftest.c
4532 if test -z "`$CC $CPPFLAGS $CFLAGS -O2 -c conftest.c 2>&1`"; then
4533 eval "cv_prog_cc_flag_$cache=yes"
4534 else
4535 eval "cv_prog_cc_flag_$cache=no"
4536 fi
4537 rm -f conftest conftest.o conftest.c
4538
4539 fi
4540
4541 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
4542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4543 $as_echo "yes" >&6; }
4544 :
4545 CFLAGS="$CFLAGS -O2"
4546 else
4547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4548 $as_echo "no" >&6; }
4549 :
4550
4551 fi
4552
4553 default_cflags=yes
4554 fi
4555 ac_ext=c
4556 ac_cpp='$CPP $CPPFLAGS'
4557 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4558 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4559 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4560 if test -n "$ac_tool_prefix"; then
4561 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4562 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4564 $as_echo_n "checking for $ac_word... " >&6; }
4565 if ${ac_cv_prog_CC+:} false; then :
4566 $as_echo_n "(cached) " >&6
4567 else
4568 if test -n "$CC"; then
4569 ac_cv_prog_CC="$CC" # Let the user override the test.
4570 else
4571 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4572 for as_dir in $PATH
4573 do
4574 IFS=$as_save_IFS
4575 test -z "$as_dir" && as_dir=.
4576 for ac_exec_ext in '' $ac_executable_extensions; do
4577 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4578 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4579 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4580 break 2
4581 fi
4582 done
4583 done
4584 IFS=$as_save_IFS
4585
4586 fi
4587 fi
4588 CC=$ac_cv_prog_CC
4589 if test -n "$CC"; then
4590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4591 $as_echo "$CC" >&6; }
4592 else
4593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4594 $as_echo "no" >&6; }
4595 fi
4596
4597
4598 fi
4599 if test -z "$ac_cv_prog_CC"; then
4600 ac_ct_CC=$CC
4601 # Extract the first word of "gcc", so it can be a program name with args.
4602 set dummy gcc; ac_word=$2
4603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4604 $as_echo_n "checking for $ac_word... " >&6; }
4605 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4606 $as_echo_n "(cached) " >&6
4607 else
4608 if test -n "$ac_ct_CC"; then
4609 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4610 else
4611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4612 for as_dir in $PATH
4613 do
4614 IFS=$as_save_IFS
4615 test -z "$as_dir" && as_dir=.
4616 for ac_exec_ext in '' $ac_executable_extensions; do
4617 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4618 ac_cv_prog_ac_ct_CC="gcc"
4619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4620 break 2
4621 fi
4622 done
4623 done
4624 IFS=$as_save_IFS
4625
4626 fi
4627 fi
4628 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4629 if test -n "$ac_ct_CC"; then
4630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4631 $as_echo "$ac_ct_CC" >&6; }
4632 else
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4634 $as_echo "no" >&6; }
4635 fi
4636
4637 if test "x$ac_ct_CC" = x; then
4638 CC=""
4639 else
4640 case $cross_compiling:$ac_tool_warned in
4641 yes:)
4642 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4643 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4644 ac_tool_warned=yes ;;
4645 esac
4646 CC=$ac_ct_CC
4647 fi
4648 else
4649 CC="$ac_cv_prog_CC"
4650 fi
4651
4652 if test -z "$CC"; then
4653 if test -n "$ac_tool_prefix"; then
4654 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4655 set dummy ${ac_tool_prefix}cc; ac_word=$2
4656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4657 $as_echo_n "checking for $ac_word... " >&6; }
4658 if ${ac_cv_prog_CC+:} false; then :
4659 $as_echo_n "(cached) " >&6
4660 else
4661 if test -n "$CC"; then
4662 ac_cv_prog_CC="$CC" # Let the user override the test.
4663 else
4664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4665 for as_dir in $PATH
4666 do
4667 IFS=$as_save_IFS
4668 test -z "$as_dir" && as_dir=.
4669 for ac_exec_ext in '' $ac_executable_extensions; do
4670 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4671 ac_cv_prog_CC="${ac_tool_prefix}cc"
4672 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4673 break 2
4674 fi
4675 done
4676 done
4677 IFS=$as_save_IFS
4678
4679 fi
4680 fi
4681 CC=$ac_cv_prog_CC
4682 if test -n "$CC"; then
4683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4684 $as_echo "$CC" >&6; }
4685 else
4686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4687 $as_echo "no" >&6; }
4688 fi
4689
4690
4691 fi
4692 fi
4693 if test -z "$CC"; then
4694 # Extract the first word of "cc", so it can be a program name with args.
4695 set dummy cc; ac_word=$2
4696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4697 $as_echo_n "checking for $ac_word... " >&6; }
4698 if ${ac_cv_prog_CC+:} false; then :
4699 $as_echo_n "(cached) " >&6
4700 else
4701 if test -n "$CC"; then
4702 ac_cv_prog_CC="$CC" # Let the user override the test.
4703 else
4704 ac_prog_rejected=no
4705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4706 for as_dir in $PATH
4707 do
4708 IFS=$as_save_IFS
4709 test -z "$as_dir" && as_dir=.
4710 for ac_exec_ext in '' $ac_executable_extensions; do
4711 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4712 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4713 ac_prog_rejected=yes
4714 continue
4715 fi
4716 ac_cv_prog_CC="cc"
4717 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4718 break 2
4719 fi
4720 done
4721 done
4722 IFS=$as_save_IFS
4723
4724 if test $ac_prog_rejected = yes; then
4725 # We found a bogon in the path, so make sure we never use it.
4726 set dummy $ac_cv_prog_CC
4727 shift
4728 if test $# != 0; then
4729 # We chose a different compiler from the bogus one.
4730 # However, it has the same basename, so the bogon will be chosen
4731 # first if we set CC to just the basename; use the full file name.
4732 shift
4733 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4734 fi
4735 fi
4736 fi
4737 fi
4738 CC=$ac_cv_prog_CC
4739 if test -n "$CC"; then
4740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4741 $as_echo "$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 fi
4749 if test -z "$CC"; then
4750 if test -n "$ac_tool_prefix"; then
4751 for ac_prog in cl.exe
4752 do
4753 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4754 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4756 $as_echo_n "checking for $ac_word... " >&6; }
4757 if ${ac_cv_prog_CC+:} false; then :
4758 $as_echo_n "(cached) " >&6
4759 else
4760 if test -n "$CC"; then
4761 ac_cv_prog_CC="$CC" # Let the user override the test.
4762 else
4763 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4764 for as_dir in $PATH
4765 do
4766 IFS=$as_save_IFS
4767 test -z "$as_dir" && as_dir=.
4768 for ac_exec_ext in '' $ac_executable_extensions; do
4769 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4770 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4771 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4772 break 2
4773 fi
4774 done
4775 done
4776 IFS=$as_save_IFS
4777
4778 fi
4779 fi
4780 CC=$ac_cv_prog_CC
4781 if test -n "$CC"; then
4782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4783 $as_echo "$CC" >&6; }
4784 else
4785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4786 $as_echo "no" >&6; }
4787 fi
4788
4789
4790 test -n "$CC" && break
4791 done
4792 fi
4793 if test -z "$CC"; then
4794 ac_ct_CC=$CC
4795 for ac_prog in cl.exe
4796 do
4797 # Extract the first word of "$ac_prog", so it can be a program name with args.
4798 set dummy $ac_prog; ac_word=$2
4799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4800 $as_echo_n "checking for $ac_word... " >&6; }
4801 if ${ac_cv_prog_ac_ct_CC+:} false; then :
4802 $as_echo_n "(cached) " >&6
4803 else
4804 if test -n "$ac_ct_CC"; then
4805 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4806 else
4807 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4808 for as_dir in $PATH
4809 do
4810 IFS=$as_save_IFS
4811 test -z "$as_dir" && as_dir=.
4812 for ac_exec_ext in '' $ac_executable_extensions; do
4813 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4814 ac_cv_prog_ac_ct_CC="$ac_prog"
4815 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4816 break 2
4817 fi
4818 done
4819 done
4820 IFS=$as_save_IFS
4821
4822 fi
4823 fi
4824 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4825 if test -n "$ac_ct_CC"; then
4826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4827 $as_echo "$ac_ct_CC" >&6; }
4828 else
4829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4830 $as_echo "no" >&6; }
4831 fi
4832
4833
4834 test -n "$ac_ct_CC" && break
4835 done
4836
4837 if test "x$ac_ct_CC" = x; then
4838 CC=""
4839 else
4840 case $cross_compiling:$ac_tool_warned in
4841 yes:)
4842 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4843 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4844 ac_tool_warned=yes ;;
4845 esac
4846 CC=$ac_ct_CC
4847 fi
4848 fi
4849
4850 fi
4851
4852
4853 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4854 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4855 as_fn_error $? "no acceptable C compiler found in \$PATH
4856 See \`config.log' for more details" "$LINENO" 5; }
4857
4858 # Provide some information about the compiler.
4859 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4860 set X $ac_compile
4861 ac_compiler=$2
4862 for ac_option in --version -v -V -qversion; do
4863 { { ac_try="$ac_compiler $ac_option >&5"
4864 case "(($ac_try" in
4865 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4866 *) ac_try_echo=$ac_try;;
4867 esac
4868 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4869 $as_echo "$ac_try_echo"; } >&5
4870 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4871 ac_status=$?
4872 if test -s conftest.err; then
4873 sed '10a\
4874 ... rest of stderr output deleted ...
4875 10q' conftest.err >conftest.er1
4876 cat conftest.er1 >&5
4877 fi
4878 rm -f conftest.er1 conftest.err
4879 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4880 test $ac_status = 0; }
4881 done
4882
4883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4884 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4885 if ${ac_cv_c_compiler_gnu+:} false; then :
4886 $as_echo_n "(cached) " >&6
4887 else
4888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4889 /* end confdefs.h. */
4890
4891 int
4892 main ()
4893 {
4894 #ifndef __GNUC__
4895 choke me
4896 #endif
4897
4898 ;
4899 return 0;
4900 }
4901 _ACEOF
4902 if ac_fn_c_try_compile "$LINENO"; then :
4903 ac_compiler_gnu=yes
4904 else
4905 ac_compiler_gnu=no
4906 fi
4907 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4908 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4909
4910 fi
4911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4912 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4913 if test $ac_compiler_gnu = yes; then
4914 GCC=yes
4915 else
4916 GCC=
4917 fi
4918 ac_test_CFLAGS=${CFLAGS+set}
4919 ac_save_CFLAGS=$CFLAGS
4920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4921 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4922 if ${ac_cv_prog_cc_g+:} false; then :
4923 $as_echo_n "(cached) " >&6
4924 else
4925 ac_save_c_werror_flag=$ac_c_werror_flag
4926 ac_c_werror_flag=yes
4927 ac_cv_prog_cc_g=no
4928 CFLAGS="-g"
4929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4930 /* end confdefs.h. */
4931
4932 int
4933 main ()
4934 {
4935
4936 ;
4937 return 0;
4938 }
4939 _ACEOF
4940 if ac_fn_c_try_compile "$LINENO"; then :
4941 ac_cv_prog_cc_g=yes
4942 else
4943 CFLAGS=""
4944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4945 /* end confdefs.h. */
4946
4947 int
4948 main ()
4949 {
4950
4951 ;
4952 return 0;
4953 }
4954 _ACEOF
4955 if ac_fn_c_try_compile "$LINENO"; then :
4956
4957 else
4958 ac_c_werror_flag=$ac_save_c_werror_flag
4959 CFLAGS="-g"
4960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4961 /* end confdefs.h. */
4962
4963 int
4964 main ()
4965 {
4966
4967 ;
4968 return 0;
4969 }
4970 _ACEOF
4971 if ac_fn_c_try_compile "$LINENO"; then :
4972 ac_cv_prog_cc_g=yes
4973 fi
4974 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4975 fi
4976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4977 fi
4978 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4979 ac_c_werror_flag=$ac_save_c_werror_flag
4980 fi
4981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4982 $as_echo "$ac_cv_prog_cc_g" >&6; }
4983 if test "$ac_test_CFLAGS" = set; then
4984 CFLAGS=$ac_save_CFLAGS
4985 elif test $ac_cv_prog_cc_g = yes; then
4986 if test "$GCC" = yes; then
4987 CFLAGS="-g -O2"
4988 else
4989 CFLAGS="-g"
4990 fi
4991 else
4992 if test "$GCC" = yes; then
4993 CFLAGS="-O2"
4994 else
4995 CFLAGS=
4996 fi
4997 fi
4998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4999 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5000 if ${ac_cv_prog_cc_c89+:} false; then :
5001 $as_echo_n "(cached) " >&6
5002 else
5003 ac_cv_prog_cc_c89=no
5004 ac_save_CC=$CC
5005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5006 /* end confdefs.h. */
5007 #include <stdarg.h>
5008 #include <stdio.h>
5009 struct stat;
5010 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5011 struct buf { int x; };
5012 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5013 static char *e (p, i)
5014 char **p;
5015 int i;
5016 {
5017 return p[i];
5018 }
5019 static char *f (char * (*g) (char **, int), char **p, ...)
5020 {
5021 char *s;
5022 va_list v;
5023 va_start (v,p);
5024 s = g (p, va_arg (v,int));
5025 va_end (v);
5026 return s;
5027 }
5028
5029 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5030 function prototypes and stuff, but not '\xHH' hex character constants.
5031 These don't provoke an error unfortunately, instead are silently treated
5032 as 'x'. The following induces an error, until -std is added to get
5033 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5034 array size at least. It's necessary to write '\x00'==0 to get something
5035 that's true only with -std. */
5036 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5037
5038 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5039 inside strings and character constants. */
5040 #define FOO(x) 'x'
5041 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5042
5043 int test (int i, double x);
5044 struct s1 {int (*f) (int a);};
5045 struct s2 {int (*f) (double a);};
5046 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5047 int argc;
5048 char **argv;
5049 int
5050 main ()
5051 {
5052 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5053 ;
5054 return 0;
5055 }
5056 _ACEOF
5057 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5058 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5059 do
5060 CC="$ac_save_CC $ac_arg"
5061 if ac_fn_c_try_compile "$LINENO"; then :
5062 ac_cv_prog_cc_c89=$ac_arg
5063 fi
5064 rm -f core conftest.err conftest.$ac_objext
5065 test "x$ac_cv_prog_cc_c89" != "xno" && break
5066 done
5067 rm -f conftest.$ac_ext
5068 CC=$ac_save_CC
5069
5070 fi
5071 # AC_CACHE_VAL
5072 case "x$ac_cv_prog_cc_c89" in
5073 x)
5074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5075 $as_echo "none needed" >&6; } ;;
5076 xno)
5077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5078 $as_echo "unsupported" >&6; } ;;
5079 *)
5080 CC="$CC $ac_cv_prog_cc_c89"
5081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5082 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5083 esac
5084 if test "x$ac_cv_prog_cc_c89" != xno; then :
5085
5086 fi
5087
5088 ac_ext=c
5089 ac_cpp='$CPP $CPPFLAGS'
5090 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5091 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5092 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5093
5094
5095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $CC dependency flag" >&5
5096 $as_echo_n "checking $CC dependency flag... " >&6; }
5097 echo 'void f(){}' >conftest.c
5098 if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5099 DEPFLAG="-MM"
5100 else
5101 if test "`$CC -xM1 conftest.c 2>&1`" = "conftest.o: conftest.c"; then
5102 DEPFLAG="-xM1"
5103 else
5104 DEPFLAG="-MM" # dunno do something
5105 fi
5106 fi
5107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEPFLAG" >&5
5108 $as_echo "$DEPFLAG" >&6; }
5109 rm -f conftest.c
5110
5111
5112
5113
5114
5115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Werror" >&5
5116 $as_echo_n "checking whether $CC supports -Werror... " >&6; }
5117 cache=`echo Werror | sed 'y%.=/+-%___p_%'`
5118 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5119 $as_echo_n "(cached) " >&6
5120 else
5121
5122 echo 'void f(void){}' >conftest.c
5123 if test -z "`$CC $CPPFLAGS $CFLAGS -Werror -c conftest.c 2>&1`"; then
5124 eval "cv_prog_cc_flag_$cache=yes"
5125 else
5126 eval "cv_prog_cc_flag_$cache=no"
5127 fi
5128 rm -f conftest conftest.o conftest.c
5129
5130 fi
5131
5132 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5134 $as_echo "yes" >&6; }
5135 :
5136 ERRFLAG="-Werror"
5137 else
5138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5139 $as_echo "no" >&6; }
5140 :
5141 ERRFLAG="-errwarn"
5142 fi
5143
5144
5145
5146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5147 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5148 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5149 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5150 $as_echo_n "(cached) " >&6
5151 else
5152
5153 echo 'void f(void){}' >conftest.c
5154 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5155 eval "cv_prog_cc_flag_$cache=yes"
5156 else
5157 eval "cv_prog_cc_flag_$cache=no"
5158 fi
5159 rm -f conftest conftest.o conftest.c
5160
5161 fi
5162
5163 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5165 $as_echo "yes" >&6; }
5166 :
5167 ERRFLAG="$ERRFLAG -Wall"
5168 else
5169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5170 $as_echo "no" >&6; }
5171 :
5172 ERRFLAG="$ERRFLAG -errfmt"
5173 fi
5174
5175
5176
5177
5178
5179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -std=c99" >&5
5180 $as_echo_n "checking whether $CC supports -std=c99... " >&6; }
5181 cache=`echo std=c99 | sed 'y%.=/+-%___p_%'`
5182 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5183 $as_echo_n "(cached) " >&6
5184 else
5185
5186 echo 'void f(void){}' >conftest.c
5187 if test -z "`$CC $CPPFLAGS $CFLAGS -std=c99 -c conftest.c 2>&1`"; then
5188 eval "cv_prog_cc_flag_$cache=yes"
5189 else
5190 eval "cv_prog_cc_flag_$cache=no"
5191 fi
5192 rm -f conftest conftest.o conftest.c
5193
5194 fi
5195
5196 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5198 $as_echo "yes" >&6; }
5199 :
5200 C99FLAG="-std=c99"
5201 else
5202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5203 $as_echo "no" >&6; }
5204 :
5205
5206 fi
5207
5208
5209
5210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -xc99" >&5
5211 $as_echo_n "checking whether $CC supports -xc99... " >&6; }
5212 cache=`echo xc99 | sed 'y%.=/+-%___p_%'`
5213 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5214 $as_echo_n "(cached) " >&6
5215 else
5216
5217 echo 'void f(void){}' >conftest.c
5218 if test -z "`$CC $CPPFLAGS $CFLAGS -xc99 -c conftest.c 2>&1`"; then
5219 eval "cv_prog_cc_flag_$cache=yes"
5220 else
5221 eval "cv_prog_cc_flag_$cache=no"
5222 fi
5223 rm -f conftest conftest.o conftest.c
5224
5225 fi
5226
5227 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5229 $as_echo "yes" >&6; }
5230 :
5231 C99FLAG="-xc99"
5232 else
5233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5234 $as_echo "no" >&6; }
5235 :
5236
5237 fi
5238
5239
5240 for ac_header in getopt.h time.h
5241 do :
5242 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5243 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5244 "
5245 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5246 cat >>confdefs.h <<_ACEOF
5247 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5248 _ACEOF
5249
5250 fi
5251
5252 done
5253
5254
5255
5256
5257
5258 { $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
5259 $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; }
5260 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`
5261 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5262 $as_echo_n "(cached) " >&6
5263 else
5264
5265 echo '
5266 #include "confdefs.h"
5267 #include <stdlib.h>
5268 #include <ctype.h>
5269 #include <sys/time.h>
5270 #ifdef HAVE_TIME_H
5271 #include <time.h>
5272 #endif
5273 #include <unistd.h>
5274 #include <netdb.h>
5275 #ifdef HAVE_GETOPT_H
5276 #include <getopt.h>
5277 #endif
5278
5279 int test() {
5280 int a;
5281 char **opts = NULL;
5282 struct timeval tv;
5283 char *t;
5284 time_t time = 0;
5285 char *buf = NULL;
5286 const char* str = NULL;
5287 struct msghdr msg;
5288 msg.msg_control = 0;
5289 t = ctime_r(&time, buf);
5290 tv.tv_usec = 10;
5291 srandom(32);
5292 a = getopt(2, opts, "a");
5293 a = isascii(32);
5294 str = gai_strerror(0);
5295 if(str && t && tv.tv_usec && msg.msg_control)
5296 a = 0;
5297 return a;
5298 }
5299 ' > conftest.c
5300 echo 'void f(){}' >>conftest.c
5301 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5302 eval "cv_prog_cc_flag_needed_$cache=no"
5303 else
5304
5305 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
5306 eval "cv_prog_cc_flag_needed_$cache=yes"
5307 else
5308 eval "cv_prog_cc_flag_needed_$cache=fail"
5309 #echo 'Test with flag fails too!'
5310 #cat conftest.c
5311 #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"
5312 #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`
5313 #exit 1
5314 fi
5315
5316 fi
5317 rm -f conftest conftest.c conftest.o
5318
5319 fi
5320
5321 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5323 $as_echo "yes" >&6; }
5324 :
5325 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"
5326 else
5327 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5329 $as_echo "no" >&6; }
5330 #echo 'Test with flag is no!'
5331 #cat conftest.c
5332 #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"
5333 #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`
5334 #exit 1
5335 :
5336
5337 else
5338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5339 $as_echo "failed" >&6; }
5340 :
5341
5342 fi
5343 fi
5344
5345
5346
5347
5348
5349 { $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
5350 $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; }
5351 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`
5352 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5353 $as_echo_n "(cached) " >&6
5354 else
5355
5356 echo '
5357 #include "confdefs.h"
5358 #include <stdlib.h>
5359 #include <ctype.h>
5360 #include <sys/time.h>
5361 #ifdef HAVE_TIME_H
5362 #include <time.h>
5363 #endif
5364 #include <unistd.h>
5365 #include <netdb.h>
5366 #ifdef HAVE_GETOPT_H
5367 #include <getopt.h>
5368 #endif
5369
5370 int test() {
5371 int a;
5372 char **opts = NULL;
5373 struct timeval tv;
5374 char *t;
5375 time_t time = 0;
5376 char *buf = NULL;
5377 const char* str = NULL;
5378 struct msghdr msg;
5379 msg.msg_control = 0;
5380 t = ctime_r(&time, buf);
5381 tv.tv_usec = 10;
5382 srandom(32);
5383 a = getopt(2, opts, "a");
5384 a = isascii(32);
5385 str = gai_strerror(0);
5386 if(str && t && tv.tv_usec && msg.msg_control)
5387 a = 0;
5388 return a;
5389 }
5390 ' > conftest.c
5391 echo 'void f(){}' >>conftest.c
5392 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5393 eval "cv_prog_cc_flag_needed_$cache=no"
5394 else
5395
5396 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
5397 eval "cv_prog_cc_flag_needed_$cache=yes"
5398 else
5399 eval "cv_prog_cc_flag_needed_$cache=fail"
5400 #echo 'Test with flag fails too!'
5401 #cat conftest.c
5402 #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"
5403 #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`
5404 #exit 1
5405 fi
5406
5407 fi
5408 rm -f conftest conftest.c conftest.o
5409
5410 fi
5411
5412 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5414 $as_echo "yes" >&6; }
5415 :
5416 CFLAGS="$CFLAGS $C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ALL_SOURCE"
5417 else
5418 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5420 $as_echo "no" >&6; }
5421 #echo 'Test with flag is no!'
5422 #cat conftest.c
5423 #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"
5424 #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`
5425 #exit 1
5426 :
5427
5428 else
5429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5430 $as_echo "failed" >&6; }
5431 :
5432
5433 fi
5434 fi
5435
5436
5437
5438
5439
5440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need $C99FLAG as a flag for $CC" >&5
5441 $as_echo_n "checking whether we need $C99FLAG as a flag for $CC... " >&6; }
5442 cache=`$as_echo "$C99FLAG" | $as_tr_sh`
5443 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5444 $as_echo_n "(cached) " >&6
5445 else
5446
5447 echo '
5448 #include <stdbool.h>
5449 #include <ctype.h>
5450 int test() {
5451 int a = 0;
5452 return a;
5453 }
5454 ' > conftest.c
5455 echo 'void f(){}' >>conftest.c
5456 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5457 eval "cv_prog_cc_flag_needed_$cache=no"
5458 else
5459
5460 if test -z "`$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`"; then
5461 eval "cv_prog_cc_flag_needed_$cache=yes"
5462 else
5463 eval "cv_prog_cc_flag_needed_$cache=fail"
5464 #echo 'Test with flag fails too!'
5465 #cat conftest.c
5466 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5467 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5468 #exit 1
5469 fi
5470
5471 fi
5472 rm -f conftest conftest.c conftest.o
5473
5474 fi
5475
5476 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5478 $as_echo "yes" >&6; }
5479 :
5480 CFLAGS="$CFLAGS $C99FLAG"
5481 else
5482 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5484 $as_echo "no" >&6; }
5485 #echo 'Test with flag is no!'
5486 #cat conftest.c
5487 #echo "$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1"
5488 #echo `$CC $CPPFLAGS $CFLAGS $C99FLAG $ERRFLAG -c conftest.c 2>&1`
5489 #exit 1
5490 :
5491
5492 else
5493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5494 $as_echo "failed" >&6; }
5495 :
5496
5497 fi
5498 fi
5499
5500
5501
5502
5503
5504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC" >&5
5505 $as_echo_n "checking whether we need -D_BSD_SOURCE -D_DEFAULT_SOURCE as a flag for $CC... " >&6; }
5506 cache=_D_BSD_SOURCE__D_DEFAULT_SOURCE
5507 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5508 $as_echo_n "(cached) " >&6
5509 else
5510
5511 echo '
5512 #include <ctype.h>
5513
5514 int test() {
5515 int a;
5516 a = isascii(32);
5517 return a;
5518 }
5519 ' > conftest.c
5520 echo 'void f(){}' >>conftest.c
5521 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5522 eval "cv_prog_cc_flag_needed_$cache=no"
5523 else
5524
5525 if test -z "`$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5526 eval "cv_prog_cc_flag_needed_$cache=yes"
5527 else
5528 eval "cv_prog_cc_flag_needed_$cache=fail"
5529 #echo 'Test with flag fails too!'
5530 #cat conftest.c
5531 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5532 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5533 #exit 1
5534 fi
5535
5536 fi
5537 rm -f conftest conftest.c conftest.o
5538
5539 fi
5540
5541 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5543 $as_echo "yes" >&6; }
5544 :
5545 CFLAGS="$CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE"
5546 else
5547 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5549 $as_echo "no" >&6; }
5550 #echo 'Test with flag is no!'
5551 #cat conftest.c
5552 #echo "$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1"
5553 #echo `$CC $CPPFLAGS $CFLAGS -D_BSD_SOURCE -D_DEFAULT_SOURCE $ERRFLAG -c conftest.c 2>&1`
5554 #exit 1
5555 :
5556
5557 else
5558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5559 $as_echo "failed" >&6; }
5560 :
5561
5562 fi
5563 fi
5564
5565
5566
5567
5568
5569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE as a flag for $CC" >&5
5570 $as_echo_n "checking whether we need -D_GNU_SOURCE as a flag for $CC... " >&6; }
5571 cache=_D_GNU_SOURCE
5572 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5573 $as_echo_n "(cached) " >&6
5574 else
5575
5576 echo '
5577 #include <netinet/in.h>
5578
5579 int test() {
5580 struct in6_pktinfo inf;
5581 int a = (int)sizeof(inf);
5582 return a;
5583 }
5584 ' > conftest.c
5585 echo 'void f(){}' >>conftest.c
5586 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5587 eval "cv_prog_cc_flag_needed_$cache=no"
5588 else
5589
5590 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`"; then
5591 eval "cv_prog_cc_flag_needed_$cache=yes"
5592 else
5593 eval "cv_prog_cc_flag_needed_$cache=fail"
5594 #echo 'Test with flag fails too!'
5595 #cat conftest.c
5596 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5597 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5598 #exit 1
5599 fi
5600
5601 fi
5602 rm -f conftest conftest.c conftest.o
5603
5604 fi
5605
5606 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5608 $as_echo "yes" >&6; }
5609 :
5610 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5611 else
5612 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5614 $as_echo "no" >&6; }
5615 #echo 'Test with flag is no!'
5616 #cat conftest.c
5617 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1"
5618 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE $ERRFLAG -c conftest.c 2>&1`
5619 #exit 1
5620 :
5621
5622 else
5623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5624 $as_echo "failed" >&6; }
5625 :
5626
5627 fi
5628 fi
5629
5630
5631 # check again for GNU_SOURCE for setresgid. May fail if setresgid
5632 # is not available at all. -D_FRSRESGID is to make this check unique.
5633 # otherwise we would get the previous cached result.
5634
5635
5636
5637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC" >&5
5638 $as_echo_n "checking whether we need -D_GNU_SOURCE -D_FRSRESGID as a flag for $CC... " >&6; }
5639 cache=_D_GNU_SOURCE__D_FRSRESGID
5640 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5641 $as_echo_n "(cached) " >&6
5642 else
5643
5644 echo '
5645 #include <unistd.h>
5646
5647 int test() {
5648 int a = setresgid(0,0,0);
5649 a = setresuid(0,0,0);
5650 return a;
5651 }
5652 ' > conftest.c
5653 echo 'void f(){}' >>conftest.c
5654 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5655 eval "cv_prog_cc_flag_needed_$cache=no"
5656 else
5657
5658 if test -z "`$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`"; then
5659 eval "cv_prog_cc_flag_needed_$cache=yes"
5660 else
5661 eval "cv_prog_cc_flag_needed_$cache=fail"
5662 #echo 'Test with flag fails too!'
5663 #cat conftest.c
5664 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5665 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5666 #exit 1
5667 fi
5668
5669 fi
5670 rm -f conftest conftest.c conftest.o
5671
5672 fi
5673
5674 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5676 $as_echo "yes" >&6; }
5677 :
5678 CFLAGS="$CFLAGS -D_GNU_SOURCE"
5679 else
5680 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5682 $as_echo "no" >&6; }
5683 #echo 'Test with flag is no!'
5684 #cat conftest.c
5685 #echo "$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1"
5686 #echo `$CC $CPPFLAGS $CFLAGS -D_GNU_SOURCE -D_FRSRESGID $ERRFLAG -c conftest.c 2>&1`
5687 #exit 1
5688 :
5689
5690 else
5691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5692 $as_echo "failed" >&6; }
5693 :
5694
5695 fi
5696 fi
5697
5698
5699
5700
5701
5702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC" >&5
5703 $as_echo_n "checking whether we need -D_POSIX_C_SOURCE=200112 as a flag for $CC... " >&6; }
5704 cache=_D_POSIX_C_SOURCE_200112
5705 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5706 $as_echo_n "(cached) " >&6
5707 else
5708
5709 echo '
5710 #include "confdefs.h"
5711 #ifdef HAVE_TIME_H
5712 #include <time.h>
5713 #endif
5714 #include <netdb.h>
5715
5716 int test() {
5717 int a = 0;
5718 char *t;
5719 time_t time = 0;
5720 char *buf = NULL;
5721 const char* str = NULL;
5722 t = ctime_r(&time, buf);
5723 str = gai_strerror(0);
5724 if(t && str)
5725 a = 0;
5726 return a;
5727 }
5728 ' > conftest.c
5729 echo 'void f(){}' >>conftest.c
5730 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5731 eval "cv_prog_cc_flag_needed_$cache=no"
5732 else
5733
5734 if test -z "`$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`"; then
5735 eval "cv_prog_cc_flag_needed_$cache=yes"
5736 else
5737 eval "cv_prog_cc_flag_needed_$cache=fail"
5738 #echo 'Test with flag fails too!'
5739 #cat conftest.c
5740 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5741 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5742 #exit 1
5743 fi
5744
5745 fi
5746 rm -f conftest conftest.c conftest.o
5747
5748 fi
5749
5750 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5752 $as_echo "yes" >&6; }
5753 :
5754 CFLAGS="$CFLAGS -D_POSIX_C_SOURCE=200112"
5755 else
5756 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5758 $as_echo "no" >&6; }
5759 #echo 'Test with flag is no!'
5760 #cat conftest.c
5761 #echo "$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1"
5762 #echo `$CC $CPPFLAGS $CFLAGS -D_POSIX_C_SOURCE=200112 $ERRFLAG -c conftest.c 2>&1`
5763 #exit 1
5764 :
5765
5766 else
5767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5768 $as_echo "failed" >&6; }
5769 :
5770
5771 fi
5772 fi
5773
5774
5775
5776
5777
5778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D__EXTENSIONS__ as a flag for $CC" >&5
5779 $as_echo_n "checking whether we need -D__EXTENSIONS__ as a flag for $CC... " >&6; }
5780 cache=_D__EXTENSIONS__
5781 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
5782 $as_echo_n "(cached) " >&6
5783 else
5784
5785 echo '
5786 #include "confdefs.h"
5787 #include <stdlib.h>
5788 #include <ctype.h>
5789 #include <sys/time.h>
5790 #ifdef HAVE_TIME_H
5791 #include <time.h>
5792 #endif
5793 #include <unistd.h>
5794 #ifdef HAVE_GETOPT_H
5795 #include <getopt.h>
5796 #endif
5797
5798 int test() {
5799 int a;
5800 char **opts = NULL;
5801 struct timeval tv;
5802 tv.tv_usec = 10;
5803 srandom(32);
5804 a = getopt(2, opts, "a");
5805 a = isascii(32);
5806 if(tv.tv_usec)
5807 a = 0;
5808 return a;
5809 }
5810 ' > conftest.c
5811 echo 'void f(){}' >>conftest.c
5812 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
5813 eval "cv_prog_cc_flag_needed_$cache=no"
5814 else
5815
5816 if test -z "`$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`"; then
5817 eval "cv_prog_cc_flag_needed_$cache=yes"
5818 else
5819 eval "cv_prog_cc_flag_needed_$cache=fail"
5820 #echo 'Test with flag fails too!'
5821 #cat conftest.c
5822 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5823 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5824 #exit 1
5825 fi
5826
5827 fi
5828 rm -f conftest conftest.c conftest.o
5829
5830 fi
5831
5832 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
5833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5834 $as_echo "yes" >&6; }
5835 :
5836 CFLAGS="$CFLAGS -D__EXTENSIONS__"
5837 else
5838 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
5839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5840 $as_echo "no" >&6; }
5841 #echo 'Test with flag is no!'
5842 #cat conftest.c
5843 #echo "$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1"
5844 #echo `$CC $CPPFLAGS $CFLAGS -D__EXTENSIONS__ $ERRFLAG -c conftest.c 2>&1`
5845 #exit 1
5846 :
5847
5848 else
5849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
5850 $as_echo "failed" >&6; }
5851 :
5852
5853 fi
5854 fi
5855
5856
5857
5858
5859 # debug mode flags warnings
5860 # Check whether --enable-checking was given.
5861 if test "${enable_checking+set}" = set; then :
5862 enableval=$enable_checking;
5863 fi
5864
5865 # Check whether --enable-debug was given.
5866 if test "${enable_debug+set}" = set; then :
5867 enableval=$enable_debug;
5868 fi
5869
5870 if test "$enable_debug" = "yes"; then debug_enabled="$enable_debug";
5871 else debug_enabled="$enable_checking"; fi
5872
5873 case "$debug_enabled" in
5874 yes)
5875
5876
5877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -W" >&5
5878 $as_echo_n "checking whether $CC supports -W... " >&6; }
5879 cache=`echo W | sed 'y%.=/+-%___p_%'`
5880 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5881 $as_echo_n "(cached) " >&6
5882 else
5883
5884 echo 'void f(void){}' >conftest.c
5885 if test -z "`$CC $CPPFLAGS $CFLAGS -W -c conftest.c 2>&1`"; then
5886 eval "cv_prog_cc_flag_$cache=yes"
5887 else
5888 eval "cv_prog_cc_flag_$cache=no"
5889 fi
5890 rm -f conftest conftest.o conftest.c
5891
5892 fi
5893
5894 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5896 $as_echo "yes" >&6; }
5897 :
5898 CFLAGS="$CFLAGS -W"
5899 else
5900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5901 $as_echo "no" >&6; }
5902 :
5903
5904 fi
5905
5906
5907
5908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5
5909 $as_echo_n "checking whether $CC supports -Wall... " >&6; }
5910 cache=`echo Wall | sed 'y%.=/+-%___p_%'`
5911 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5912 $as_echo_n "(cached) " >&6
5913 else
5914
5915 echo 'void f(void){}' >conftest.c
5916 if test -z "`$CC $CPPFLAGS $CFLAGS -Wall -c conftest.c 2>&1`"; then
5917 eval "cv_prog_cc_flag_$cache=yes"
5918 else
5919 eval "cv_prog_cc_flag_$cache=no"
5920 fi
5921 rm -f conftest conftest.o conftest.c
5922
5923 fi
5924
5925 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5927 $as_echo "yes" >&6; }
5928 :
5929 CFLAGS="$CFLAGS -Wall"
5930 else
5931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5932 $as_echo "no" >&6; }
5933 :
5934
5935 fi
5936
5937
5938
5939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wextra" >&5
5940 $as_echo_n "checking whether $CC supports -Wextra... " >&6; }
5941 cache=`echo Wextra | sed 'y%.=/+-%___p_%'`
5942 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5943 $as_echo_n "(cached) " >&6
5944 else
5945
5946 echo 'void f(void){}' >conftest.c
5947 if test -z "`$CC $CPPFLAGS $CFLAGS -Wextra -c conftest.c 2>&1`"; then
5948 eval "cv_prog_cc_flag_$cache=yes"
5949 else
5950 eval "cv_prog_cc_flag_$cache=no"
5951 fi
5952 rm -f conftest conftest.o conftest.c
5953
5954 fi
5955
5956 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5958 $as_echo "yes" >&6; }
5959 :
5960 CFLAGS="$CFLAGS -Wextra"
5961 else
5962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5963 $as_echo "no" >&6; }
5964 :
5965
5966 fi
5967
5968
5969
5970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wdeclaration-after-statement" >&5
5971 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
5972 cache=`echo Wdeclaration-after-statement | sed 'y%.=/+-%___p_%'`
5973 if eval \${cv_prog_cc_flag_$cache+:} false; then :
5974 $as_echo_n "(cached) " >&6
5975 else
5976
5977 echo 'void f(void){}' >conftest.c
5978 if test -z "`$CC $CPPFLAGS $CFLAGS -Wdeclaration-after-statement -c conftest.c 2>&1`"; then
5979 eval "cv_prog_cc_flag_$cache=yes"
5980 else
5981 eval "cv_prog_cc_flag_$cache=no"
5982 fi
5983 rm -f conftest conftest.o conftest.c
5984
5985 fi
5986
5987 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
5988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5989 $as_echo "yes" >&6; }
5990 :
5991 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
5992 else
5993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5994 $as_echo "no" >&6; }
5995 :
5996
5997 fi
5998
5999
6000 $as_echo "#define UNBOUND_DEBUG /**/" >>confdefs.h
6001
6002 ;;
6003 no|*)
6004 # nothing to do.
6005 ;;
6006 esac
6007 if test "$default_cflags" = "yes"; then
6008 # only when CFLAGS was "" at the start, if the users wants to
6009 # override we shouldn't add default cflags, because they wouldn't
6010 # be able to turn off these options and set the CFLAGS wanted.
6011
6012 # Check whether --enable-flto was given.
6013 if test "${enable_flto+set}" = set; then :
6014 enableval=$enable_flto;
6015 fi
6016
6017 if test "x$enable_flto" != "xno"; then :
6018
6019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -flto" >&5
6020 $as_echo_n "checking if $CC supports -flto... " >&6; }
6021 BAKCFLAGS="$CFLAGS"
6022 CFLAGS="$CFLAGS -flto"
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 -o conftest conftest.c 2>&1 | $GREP -e "warning: no debug symbols in executable" -e "warning: object" >/dev/null; then
6037 CFLAGS="$BAKCFLAGS"
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 CFLAGS="$BAKCFLAGS" ; { $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 # Check whether --enable-pie was given.
6057 if test "${enable_pie+set}" = set; then :
6058 enableval=$enable_pie;
6059 fi
6060
6061 if test "x$enable_pie" = "xyes"; then :
6062
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports PIE" >&5
6064 $as_echo_n "checking if $CC supports PIE... " >&6; }
6065 BAKLDFLAGS="$LDFLAGS"
6066 BAKCFLAGS="$CFLAGS"
6067 LDFLAGS="$LDFLAGS -pie"
6068 CFLAGS="$CFLAGS -fPIE"
6069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6070 /* end confdefs.h. */
6071
6072 int
6073 main ()
6074 {
6075
6076 ;
6077 return 0;
6078 }
6079 _ACEOF
6080 if ac_fn_c_try_link "$LINENO"; then :
6081
6082 if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6083 LDFLAGS="$BAKLDFLAGS"
6084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6085 $as_echo "no" >&6; }
6086 else
6087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6088 $as_echo "yes" >&6; }
6089 fi
6090 rm -f conftest conftest.c conftest.o
6091
6092 else
6093 LDFLAGS="$BAKLDFLAGS" ; CFLAGS="$BAKCFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6094 $as_echo "no" >&6; }
6095 fi
6096 rm -f core conftest.err conftest.$ac_objext \
6097 conftest$ac_exeext conftest.$ac_ext
6098
6099 fi
6100
6101
6102 # Check whether --enable-relro_now was given.
6103 if test "${enable_relro_now+set}" = set; then :
6104 enableval=$enable_relro_now;
6105 fi
6106
6107 if test "x$enable_relro_now" = "xyes"; then :
6108
6109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wl,-z,relro,-z,now" >&5
6110 $as_echo_n "checking if $CC supports -Wl,-z,relro,-z,now... " >&6; }
6111 BAKLDFLAGS="$LDFLAGS"
6112 LDFLAGS="$LDFLAGS -Wl,-z,relro,-z,now"
6113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6114 /* end confdefs.h. */
6115
6116 int
6117 main ()
6118 {
6119
6120 ;
6121 return 0;
6122 }
6123 _ACEOF
6124 if ac_fn_c_try_link "$LINENO"; then :
6125
6126 if $CC $CFLAGS $LDFLAGS -o conftest conftest.c 2>&1 | grep "warning: no debug symbols in executable" >/dev/null; then
6127 LDFLAGS="$BAKLDFLAGS"
6128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6129 $as_echo "no" >&6; }
6130 else
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6132 $as_echo "yes" >&6; }
6133 fi
6134 rm -f conftest conftest.c conftest.o
6135
6136 else
6137 LDFLAGS="$BAKLDFLAGS" ; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6138 $as_echo "no" >&6; }
6139 fi
6140 rm -f core conftest.err conftest.$ac_objext \
6141 conftest$ac_exeext conftest.$ac_ext
6142
6143 fi
6144
6145 fi
6146
6147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
6148 $as_echo_n "checking for inline... " >&6; }
6149 if ${ac_cv_c_inline+:} false; then :
6150 $as_echo_n "(cached) " >&6
6151 else
6152 ac_cv_c_inline=no
6153 for ac_kw in inline __inline__ __inline; do
6154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6155 /* end confdefs.h. */
6156 #ifndef __cplusplus
6157 typedef int foo_t;
6158 static $ac_kw foo_t static_foo () {return 0; }
6159 $ac_kw foo_t foo () {return 0; }
6160 #endif
6161
6162 _ACEOF
6163 if ac_fn_c_try_compile "$LINENO"; then :
6164 ac_cv_c_inline=$ac_kw
6165 fi
6166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6167 test "$ac_cv_c_inline" != no && break
6168 done
6169
6170 fi
6171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
6172 $as_echo "$ac_cv_c_inline" >&6; }
6173
6174 case $ac_cv_c_inline in
6175 inline | yes) ;;
6176 *)
6177 case $ac_cv_c_inline in
6178 no) ac_val=;;
6179 *) ac_val=$ac_cv_c_inline;;
6180 esac
6181 cat >>confdefs.h <<_ACEOF
6182 #ifndef __cplusplus
6183 #define inline $ac_val
6184 #endif
6185 _ACEOF
6186 ;;
6187 esac
6188
6189
6190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute" >&5
6191 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"format\" attribute... " >&6; }
6192 if ${ac_cv_c_format_attribute+:} false; then :
6193 $as_echo_n "(cached) " >&6
6194 else
6195 ac_cv_c_format_attribute=no
6196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6197 /* end confdefs.h. */
6198 #include <stdio.h>
6199 void f (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6200 void (*pf) (char *format, ...) __attribute__ ((format (printf, 1, 2)));
6201
6202 int
6203 main ()
6204 {
6205
6206 f ("%s", "str");
6207
6208 ;
6209 return 0;
6210 }
6211 _ACEOF
6212 if ac_fn_c_try_compile "$LINENO"; then :
6213 ac_cv_c_format_attribute="yes"
6214 else
6215 ac_cv_c_format_attribute="no"
6216 fi
6217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6218
6219 fi
6220
6221
6222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_format_attribute" >&5
6223 $as_echo "$ac_cv_c_format_attribute" >&6; }
6224 if test $ac_cv_c_format_attribute = yes; then
6225
6226 $as_echo "#define HAVE_ATTR_FORMAT 1" >>confdefs.h
6227
6228 fi
6229
6230
6231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute" >&5
6232 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"unused\" attribute... " >&6; }
6233 if ${ac_cv_c_unused_attribute+:} false; then :
6234 $as_echo_n "(cached) " >&6
6235 else
6236 ac_cv_c_unused_attribute=no
6237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6238 /* end confdefs.h. */
6239 #include <stdio.h>
6240 void f (char *u __attribute__((unused)));
6241
6242 int
6243 main ()
6244 {
6245
6246 f ("x");
6247
6248 ;
6249 return 0;
6250 }
6251 _ACEOF
6252 if ac_fn_c_try_compile "$LINENO"; then :
6253 ac_cv_c_unused_attribute="yes"
6254 else
6255 ac_cv_c_unused_attribute="no"
6256 fi
6257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6258
6259 fi
6260
6261
6262
6263
6264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_unused_attribute" >&5
6265 $as_echo "$ac_cv_c_unused_attribute" >&6; }
6266 if test $ac_cv_c_unused_attribute = yes; then
6267
6268 $as_echo "#define HAVE_ATTR_UNUSED 1" >>confdefs.h
6269
6270 fi
6271
6272
6273
6274
6275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute" >&5
6276 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"weak\" attribute... " >&6; }
6277 if ${ac_cv_c_weak_attribute+:} false; then :
6278 $as_echo_n "(cached) " >&6
6279 else
6280 ac_cv_c_weak_attribute=no
6281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6282 /* end confdefs.h. */
6283 #include <stdio.h>
6284 __attribute__((weak)) void f(int x) { printf("%d", x); }
6285
6286 int
6287 main ()
6288 {
6289
6290 f(1);
6291
6292 ;
6293 return 0;
6294 }
6295 _ACEOF
6296 if ac_fn_c_try_compile "$LINENO"; then :
6297 ac_cv_c_weak_attribute="yes"
6298 else
6299 ac_cv_c_weak_attribute="no"
6300 fi
6301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6302
6303 fi
6304
6305
6306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_weak_attribute" >&5
6307 $as_echo "$ac_cv_c_weak_attribute" >&6; }
6308 if test $ac_cv_c_weak_attribute = yes; then
6309
6310 $as_echo "#define HAVE_ATTR_WEAK 1" >>confdefs.h
6311
6312
6313 $as_echo "#define ATTR_WEAK __attribute__((weak))" >>confdefs.h
6314
6315 fi
6316
6317
6318
6319
6320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute" >&5
6321 $as_echo_n "checking whether the C compiler (${CC-cc}) accepts the \"noreturn\" attribute... " >&6; }
6322 if ${ac_cv_c_noreturn_attribute+:} false; then :
6323 $as_echo_n "(cached) " >&6
6324 else
6325 ac_cv_c_noreturn_attribute=no
6326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6327 /* end confdefs.h. */
6328 #include <stdio.h>
6329 __attribute__((noreturn)) void f(int x) { printf("%d", x); }
6330
6331 int
6332 main ()
6333 {
6334
6335 f(1);
6336
6337 ;
6338 return 0;
6339 }
6340 _ACEOF
6341 if ac_fn_c_try_compile "$LINENO"; then :
6342 ac_cv_c_noreturn_attribute="yes"
6343 else
6344 ac_cv_c_noreturn_attribute="no"
6345 fi
6346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6347
6348 fi
6349
6350
6351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_noreturn_attribute" >&5
6352 $as_echo "$ac_cv_c_noreturn_attribute" >&6; }
6353 if test $ac_cv_c_noreturn_attribute = yes; then
6354
6355 $as_echo "#define HAVE_ATTR_NORETURN 1" >>confdefs.h
6356
6357
6358 $as_echo "#define ATTR_NORETURN __attribute__((__noreturn__))" >>confdefs.h
6359
6360 fi
6361
6362
6363 if test "$srcdir" != "."; then
6364 CPPFLAGS="$CPPFLAGS -I$srcdir"
6365 fi
6366
6367
6368
6369
6370
6371 for ac_prog in flex lex
6372 do
6373 # Extract the first word of "$ac_prog", so it can be a program name with args.
6374 set dummy $ac_prog; ac_word=$2
6375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6376 $as_echo_n "checking for $ac_word... " >&6; }
6377 if ${ac_cv_prog_LEX+:} false; then :
6378 $as_echo_n "(cached) " >&6
6379 else
6380 if test -n "$LEX"; then
6381 ac_cv_prog_LEX="$LEX" # Let the user override the test.
6382 else
6383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6384 for as_dir in $PATH
6385 do
6386 IFS=$as_save_IFS
6387 test -z "$as_dir" && as_dir=.
6388 for ac_exec_ext in '' $ac_executable_extensions; do
6389 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6390 ac_cv_prog_LEX="$ac_prog"
6391 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6392 break 2
6393 fi
6394 done
6395 done
6396 IFS=$as_save_IFS
6397
6398 fi
6399 fi
6400 LEX=$ac_cv_prog_LEX
6401 if test -n "$LEX"; then
6402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
6403 $as_echo "$LEX" >&6; }
6404 else
6405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6406 $as_echo "no" >&6; }
6407 fi
6408
6409
6410 test -n "$LEX" && break
6411 done
6412 test -n "$LEX" || LEX=":"
6413
6414 if test "x$LEX" != "x:"; then
6415 cat >conftest.l <<_ACEOF
6416 %%
6417 a { ECHO; }
6418 b { REJECT; }
6419 c { yymore (); }
6420 d { yyless (1); }
6421 e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */
6422 yyless ((input () != 0)); }
6423 f { unput (yytext[0]); }
6424 . { BEGIN INITIAL; }
6425 %%
6426 #ifdef YYTEXT_POINTER
6427 extern char *yytext;
6428 #endif
6429 int
6430 main (void)
6431 {
6432 return ! yylex () + ! yywrap ();
6433 }
6434 _ACEOF
6435 { { ac_try="$LEX conftest.l"
6436 case "(($ac_try" in
6437 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6438 *) ac_try_echo=$ac_try;;
6439 esac
6440 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6441 $as_echo "$ac_try_echo"; } >&5
6442 (eval "$LEX conftest.l") 2>&5
6443 ac_status=$?
6444 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6445 test $ac_status = 0; }
6446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
6447 $as_echo_n "checking lex output file root... " >&6; }
6448 if ${ac_cv_prog_lex_root+:} false; then :
6449 $as_echo_n "(cached) " >&6
6450 else
6451
6452 if test -f lex.yy.c; then
6453 ac_cv_prog_lex_root=lex.yy
6454 elif test -f lexyy.c; then
6455 ac_cv_prog_lex_root=lexyy
6456 else
6457 as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
6458 fi
6459 fi
6460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
6461 $as_echo "$ac_cv_prog_lex_root" >&6; }
6462 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
6463
6464 if test -z "${LEXLIB+set}"; then
6465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
6466 $as_echo_n "checking lex library... " >&6; }
6467 if ${ac_cv_lib_lex+:} false; then :
6468 $as_echo_n "(cached) " >&6
6469 else
6470
6471 ac_save_LIBS=$LIBS
6472 ac_cv_lib_lex='none needed'
6473 for ac_lib in '' -lfl -ll; do
6474 LIBS="$ac_lib $ac_save_LIBS"
6475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6476 /* end confdefs.h. */
6477 `cat $LEX_OUTPUT_ROOT.c`
6478 _ACEOF
6479 if ac_fn_c_try_link "$LINENO"; then :
6480 ac_cv_lib_lex=$ac_lib
6481 fi
6482 rm -f core conftest.err conftest.$ac_objext \
6483 conftest$ac_exeext conftest.$ac_ext
6484 test "$ac_cv_lib_lex" != 'none needed' && break
6485 done
6486 LIBS=$ac_save_LIBS
6487
6488 fi
6489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
6490 $as_echo "$ac_cv_lib_lex" >&6; }
6491 test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
6492 fi
6493
6494
6495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
6496 $as_echo_n "checking whether yytext is a pointer... " >&6; }
6497 if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
6498 $as_echo_n "(cached) " >&6
6499 else
6500 # POSIX says lex can declare yytext either as a pointer or an array; the
6501 # default is implementation-dependent. Figure out which it is, since
6502 # not all implementations provide the %pointer and %array declarations.
6503 ac_cv_prog_lex_yytext_pointer=no
6504 ac_save_LIBS=$LIBS
6505 LIBS="$LEXLIB $ac_save_LIBS"
6506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6507 /* end confdefs.h. */
6508
6509 #define YYTEXT_POINTER 1
6510 `cat $LEX_OUTPUT_ROOT.c`
6511 _ACEOF
6512 if ac_fn_c_try_link "$LINENO"; then :
6513 ac_cv_prog_lex_yytext_pointer=yes
6514 fi
6515 rm -f core conftest.err conftest.$ac_objext \
6516 conftest$ac_exeext conftest.$ac_ext
6517 LIBS=$ac_save_LIBS
6518
6519 fi
6520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
6521 $as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
6522 if test $ac_cv_prog_lex_yytext_pointer = yes; then
6523
6524 $as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
6525
6526 fi
6527 rm -f conftest.l $LEX_OUTPUT_ROOT.c
6528
6529 fi
6530 if test "$LEX" != "" -a "$LEX" != ":"; then
6531
6532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yylex_destroy" >&5
6533 $as_echo_n "checking for yylex_destroy... " >&6; }
6534 if echo %% | $LEX -t 2>&1 | grep yylex_destroy >/dev/null 2>&1; then
6535
6536 $as_echo "#define LEX_HAS_YYLEX_DESTROY 1" >>confdefs.h
6537
6538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6539 $as_echo "yes" >&6; }
6540 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6541 $as_echo "no" >&6; };
6542 LEX=":"
6543 fi
6544
6545 fi
6546 if test "$LEX" != "" -a "$LEX" != ":"; then
6547
6548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lex %option" >&5
6549 $as_echo_n "checking for lex %option... " >&6; }
6550 if cat <<EOF | $LEX -t 2>&1 | grep yy_delete_buffer >/dev/null 2>&1; then
6551 %option nounput
6552 %%
6553 EOF
6554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6555 $as_echo "yes" >&6; }
6556 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6557 $as_echo "no" >&6; };
6558 LEX=":"
6559 fi
6560
6561 fi
6562 for ac_prog in 'bison -y' byacc
6563 do
6564 # Extract the first word of "$ac_prog", so it can be a program name with args.
6565 set dummy $ac_prog; ac_word=$2
6566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6567 $as_echo_n "checking for $ac_word... " >&6; }
6568 if ${ac_cv_prog_YACC+:} false; then :
6569 $as_echo_n "(cached) " >&6
6570 else
6571 if test -n "$YACC"; then
6572 ac_cv_prog_YACC="$YACC" # Let the user override the test.
6573 else
6574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6575 for as_dir in $PATH
6576 do
6577 IFS=$as_save_IFS
6578 test -z "$as_dir" && as_dir=.
6579 for ac_exec_ext in '' $ac_executable_extensions; do
6580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6581 ac_cv_prog_YACC="$ac_prog"
6582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6583 break 2
6584 fi
6585 done
6586 done
6587 IFS=$as_save_IFS
6588
6589 fi
6590 fi
6591 YACC=$ac_cv_prog_YACC
6592 if test -n "$YACC"; then
6593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6594 $as_echo "$YACC" >&6; }
6595 else
6596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6597 $as_echo "no" >&6; }
6598 fi
6599
6600
6601 test -n "$YACC" && break
6602 done
6603 test -n "$YACC" || YACC="yacc"
6604
6605 # Extract the first word of "doxygen", so it can be a program name with args.
6606 set dummy doxygen; ac_word=$2
6607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6608 $as_echo_n "checking for $ac_word... " >&6; }
6609 if ${ac_cv_prog_doxygen+:} false; then :
6610 $as_echo_n "(cached) " >&6
6611 else
6612 if test -n "$doxygen"; then
6613 ac_cv_prog_doxygen="$doxygen" # Let the user override the test.
6614 else
6615 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6616 for as_dir in $PATH
6617 do
6618 IFS=$as_save_IFS
6619 test -z "$as_dir" && as_dir=.
6620 for ac_exec_ext in '' $ac_executable_extensions; do
6621 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6622 ac_cv_prog_doxygen="doxygen"
6623 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6624 break 2
6625 fi
6626 done
6627 done
6628 IFS=$as_save_IFS
6629
6630 fi
6631 fi
6632 doxygen=$ac_cv_prog_doxygen
6633 if test -n "$doxygen"; then
6634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $doxygen" >&5
6635 $as_echo "$doxygen" >&6; }
6636 else
6637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6638 $as_echo "no" >&6; }
6639 fi
6640
6641
6642 if test -n "$ac_tool_prefix"; then
6643 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6644 set dummy ${ac_tool_prefix}strip; ac_word=$2
6645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6646 $as_echo_n "checking for $ac_word... " >&6; }
6647 if ${ac_cv_prog_STRIP+:} false; then :
6648 $as_echo_n "(cached) " >&6
6649 else
6650 if test -n "$STRIP"; then
6651 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6652 else
6653 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6654 for as_dir in $PATH
6655 do
6656 IFS=$as_save_IFS
6657 test -z "$as_dir" && as_dir=.
6658 for ac_exec_ext in '' $ac_executable_extensions; do
6659 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6660 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6662 break 2
6663 fi
6664 done
6665 done
6666 IFS=$as_save_IFS
6667
6668 fi
6669 fi
6670 STRIP=$ac_cv_prog_STRIP
6671 if test -n "$STRIP"; then
6672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6673 $as_echo "$STRIP" >&6; }
6674 else
6675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6676 $as_echo "no" >&6; }
6677 fi
6678
6679
6680 fi
6681 if test -z "$ac_cv_prog_STRIP"; then
6682 ac_ct_STRIP=$STRIP
6683 # Extract the first word of "strip", so it can be a program name with args.
6684 set dummy strip; ac_word=$2
6685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6686 $as_echo_n "checking for $ac_word... " >&6; }
6687 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6688 $as_echo_n "(cached) " >&6
6689 else
6690 if test -n "$ac_ct_STRIP"; then
6691 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6692 else
6693 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6694 for as_dir in $PATH
6695 do
6696 IFS=$as_save_IFS
6697 test -z "$as_dir" && as_dir=.
6698 for ac_exec_ext in '' $ac_executable_extensions; do
6699 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6700 ac_cv_prog_ac_ct_STRIP="strip"
6701 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6702 break 2
6703 fi
6704 done
6705 done
6706 IFS=$as_save_IFS
6707
6708 fi
6709 fi
6710 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6711 if test -n "$ac_ct_STRIP"; then
6712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6713 $as_echo "$ac_ct_STRIP" >&6; }
6714 else
6715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6716 $as_echo "no" >&6; }
6717 fi
6718
6719 if test "x$ac_ct_STRIP" = x; then
6720 STRIP=""
6721 else
6722 case $cross_compiling:$ac_tool_warned in
6723 yes:)
6724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6725 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6726 ac_tool_warned=yes ;;
6727 esac
6728 STRIP=$ac_ct_STRIP
6729 fi
6730 else
6731 STRIP="$ac_cv_prog_STRIP"
6732 fi
6733
6734 ac_aux_dir=
6735 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
6736 if test -f "$ac_dir/install-sh"; then
6737 ac_aux_dir=$ac_dir
6738 ac_install_sh="$ac_aux_dir/install-sh -c"
6739 break
6740 elif test -f "$ac_dir/install.sh"; then
6741 ac_aux_dir=$ac_dir
6742 ac_install_sh="$ac_aux_dir/install.sh -c"
6743 break
6744 elif test -f "$ac_dir/shtool"; then
6745 ac_aux_dir=$ac_dir
6746 ac_install_sh="$ac_aux_dir/shtool install -c"
6747 break
6748 fi
6749 done
6750 if test -z "$ac_aux_dir"; then
6751 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
6752 fi
6753
6754 # These three variables are undocumented and unsupported,
6755 # and are intended to be withdrawn in a future Autoconf release.
6756 # They can cause serious problems if a builder's source tree is in a directory
6757 # whose full name contains unusual characters.
6758 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
6759 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
6760 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
6761
6762
6763 # Make sure we can run config.sub.
6764 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
6765 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
6766
6767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
6768 $as_echo_n "checking build system type... " >&6; }
6769 if ${ac_cv_build+:} false; then :
6770 $as_echo_n "(cached) " >&6
6771 else
6772 ac_build_alias=$build_alias
6773 test "x$ac_build_alias" = x &&
6774 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
6775 test "x$ac_build_alias" = x &&
6776 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
6777 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
6778 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
6779
6780 fi
6781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
6782 $as_echo "$ac_cv_build" >&6; }
6783 case $ac_cv_build in
6784 *-*-*) ;;
6785 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
6786 esac
6787 build=$ac_cv_build
6788 ac_save_IFS=$IFS; IFS='-'
6789 set x $ac_cv_build
6790 shift
6791 build_cpu=$1
6792 build_vendor=$2
6793 shift; shift
6794 # Remember, the first character of IFS is used to create $*,
6795 # except with old shells:
6796 build_os=$*
6797 IFS=$ac_save_IFS
6798 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
6799
6800
6801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
6802 $as_echo_n "checking host system type... " >&6; }
6803 if ${ac_cv_host+:} false; then :
6804 $as_echo_n "(cached) " >&6
6805 else
6806 if test "x$host_alias" = x; then
6807 ac_cv_host=$ac_cv_build
6808 else
6809 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
6810 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
6811 fi
6812
6813 fi
6814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
6815 $as_echo "$ac_cv_host" >&6; }
6816 case $ac_cv_host in
6817 *-*-*) ;;
6818 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
6819 esac
6820 host=$ac_cv_host
6821 ac_save_IFS=$IFS; IFS='-'
6822 set x $ac_cv_host
6823 shift
6824 host_cpu=$1
6825 host_vendor=$2
6826 shift; shift
6827 # Remember, the first character of IFS is used to create $*,
6828 # except with old shells:
6829 host_os=$*
6830 IFS=$ac_save_IFS
6831 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
6832
6833
6834
6835 # skip these tests, we do not need them.
6836
6837
6838
6839
6840
6841
6842
6843
6844 # always use ./libtool unless override from commandline (libtool=mylibtool)
6845 if test -z "$libtool"; then
6846 libtool="./libtool"
6847 fi
6848
6849 # avoid libtool max commandline length test on systems that fork slowly.
6850
6851 if echo "$host_os" | grep "sunos4" >/dev/null; then
6852 lt_cv_sys_max_cmd_len=32750;
6853 fi
6854 if test -n "$ac_tool_prefix"; then
6855 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6856 set dummy ${ac_tool_prefix}ar; ac_word=$2
6857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6858 $as_echo_n "checking for $ac_word... " >&6; }
6859 if ${ac_cv_path_AR+:} false; then :
6860 $as_echo_n "(cached) " >&6
6861 else
6862 case $AR in
6863 [\\/]* | ?:[\\/]*)
6864 ac_cv_path_AR="$AR" # Let the user override the test with a path.
6865 ;;
6866 *)
6867 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6868 for as_dir in $PATH
6869 do
6870 IFS=$as_save_IFS
6871 test -z "$as_dir" && as_dir=.
6872 for ac_exec_ext in '' $ac_executable_extensions; do
6873 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6874 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
6875 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6876 break 2
6877 fi
6878 done
6879 done
6880 IFS=$as_save_IFS
6881
6882 ;;
6883 esac
6884 fi
6885 AR=$ac_cv_path_AR
6886 if test -n "$AR"; then
6887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6888 $as_echo "$AR" >&6; }
6889 else
6890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6891 $as_echo "no" >&6; }
6892 fi
6893
6894
6895 fi
6896 if test -z "$ac_cv_path_AR"; then
6897 ac_pt_AR=$AR
6898 # Extract the first word of "ar", so it can be a program name with args.
6899 set dummy ar; ac_word=$2
6900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6901 $as_echo_n "checking for $ac_word... " >&6; }
6902 if ${ac_cv_path_ac_pt_AR+:} false; then :
6903 $as_echo_n "(cached) " >&6
6904 else
6905 case $ac_pt_AR in
6906 [\\/]* | ?:[\\/]*)
6907 ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
6908 ;;
6909 *)
6910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6911 for as_dir in $PATH
6912 do
6913 IFS=$as_save_IFS
6914 test -z "$as_dir" && as_dir=.
6915 for ac_exec_ext in '' $ac_executable_extensions; do
6916 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6917 ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
6918 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6919 break 2
6920 fi
6921 done
6922 done
6923 IFS=$as_save_IFS
6924
6925 ;;
6926 esac
6927 fi
6928 ac_pt_AR=$ac_cv_path_ac_pt_AR
6929 if test -n "$ac_pt_AR"; then
6930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
6931 $as_echo "$ac_pt_AR" >&6; }
6932 else
6933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6934 $as_echo "no" >&6; }
6935 fi
6936
6937 if test "x$ac_pt_AR" = x; then
6938 AR="false"
6939 else
6940 case $cross_compiling:$ac_tool_warned in
6941 yes:)
6942 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6943 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6944 ac_tool_warned=yes ;;
6945 esac
6946 AR=$ac_pt_AR
6947 fi
6948 else
6949 AR="$ac_cv_path_AR"
6950 fi
6951
6952 if test $AR = false; then
6953 as_fn_error $? "Cannot find 'ar', please extend PATH to include it" "$LINENO" 5
6954 fi
6955
6956 case `pwd` in
6957 *\ * | *\ *)
6958 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
6959 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
6960 esac
6961
6962
6963
6964 macro_version='2.4.6'
6965 macro_revision='2.4.6'
6966
6967
6968
6969
6970
6971
6972
6973
6974
6975
6976
6977
6978
6979 ltmain=$ac_aux_dir/ltmain.sh
6980
6981 # Backslashify metacharacters that are still active within
6982 # double-quoted strings.
6983 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
6984
6985 # Same as above, but do not quote variable references.
6986 double_quote_subst='s/\(["`\\]\)/\\\1/g'
6987
6988 # Sed substitution to delay expansion of an escaped shell variable in a
6989 # double_quote_subst'ed string.
6990 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
6991
6992 # Sed substitution to delay expansion of an escaped single quote.
6993 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
6994
6995 # Sed substitution to avoid accidental globbing in evaled expressions
6996 no_glob_subst='s/\*/\\\*/g'
6997
6998 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
6999 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7000 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7001
7002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7003 $as_echo_n "checking how to print strings... " >&6; }
7004 # Test print first, because it will be a builtin if present.
7005 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7006 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7007 ECHO='print -r --'
7008 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7009 ECHO='printf %s\n'
7010 else
7011 # Use this function as a fallback that always works.
7012 func_fallback_echo ()
7013 {
7014 eval 'cat <<_LTECHO_EOF
7015 $1
7016 _LTECHO_EOF'
7017 }
7018 ECHO='func_fallback_echo'
7019 fi
7020
7021 # func_echo_all arg...
7022 # Invoke $ECHO with all args, space-separated.
7023 func_echo_all ()
7024 {
7025 $ECHO ""
7026 }
7027
7028 case $ECHO in
7029 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7030 $as_echo "printf" >&6; } ;;
7031 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7032 $as_echo "print -r" >&6; } ;;
7033 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7034 $as_echo "cat" >&6; } ;;
7035 esac
7036
7037
7038
7039
7040
7041
7042
7043
7044
7045
7046
7047
7048
7049
7050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7051 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7052 if ${ac_cv_path_SED+:} false; then :
7053 $as_echo_n "(cached) " >&6
7054 else
7055 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7056 for ac_i in 1 2 3 4 5 6 7; do
7057 ac_script="$ac_script$as_nl$ac_script"
7058 done
7059 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7060 { ac_script=; unset ac_script;}
7061 if test -z "$SED"; then
7062 ac_path_SED_found=false
7063 # Loop through the user's path and test for each of PROGNAME-LIST
7064 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7065 for as_dir in $PATH
7066 do
7067 IFS=$as_save_IFS
7068 test -z "$as_dir" && as_dir=.
7069 for ac_prog in sed gsed; do
7070 for ac_exec_ext in '' $ac_executable_extensions; do
7071 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7072 as_fn_executable_p "$ac_path_SED" || continue
7073 # Check for GNU ac_path_SED and select it if it is found.
7074 # Check for GNU $ac_path_SED
7075 case `"$ac_path_SED" --version 2>&1` in
7076 *GNU*)
7077 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7078 *)
7079 ac_count=0
7080 $as_echo_n 0123456789 >"conftest.in"
7081 while :
7082 do
7083 cat "conftest.in" "conftest.in" >"conftest.tmp"
7084 mv "conftest.tmp" "conftest.in"
7085 cp "conftest.in" "conftest.nl"
7086 $as_echo '' >> "conftest.nl"
7087 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7088 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7089 as_fn_arith $ac_count + 1 && ac_count=$as_val
7090 if test $ac_count -gt ${ac_path_SED_max-0}; then
7091 # Best one so far, save it but keep looking for a better one
7092 ac_cv_path_SED="$ac_path_SED"
7093 ac_path_SED_max=$ac_count
7094 fi
7095 # 10*(2^10) chars as input seems more than enough
7096 test $ac_count -gt 10 && break
7097 done
7098 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7099 esac
7100
7101 $ac_path_SED_found && break 3
7102 done
7103 done
7104 done
7105 IFS=$as_save_IFS
7106 if test -z "$ac_cv_path_SED"; then
7107 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7108 fi
7109 else
7110 ac_cv_path_SED=$SED
7111 fi
7112
7113 fi
7114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7115 $as_echo "$ac_cv_path_SED" >&6; }
7116 SED="$ac_cv_path_SED"
7117 rm -f conftest.sed
7118
7119 test -z "$SED" && SED=sed
7120 Xsed="$SED -e 1s/^X//"
7121
7122
7123
7124
7125
7126
7127
7128
7129
7130
7131
7132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7133 $as_echo_n "checking for fgrep... " >&6; }
7134 if ${ac_cv_path_FGREP+:} false; then :
7135 $as_echo_n "(cached) " >&6
7136 else
7137 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7138 then ac_cv_path_FGREP="$GREP -F"
7139 else
7140 if test -z "$FGREP"; then
7141 ac_path_FGREP_found=false
7142 # Loop through the user's path and test for each of PROGNAME-LIST
7143 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7144 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7145 do
7146 IFS=$as_save_IFS
7147 test -z "$as_dir" && as_dir=.
7148 for ac_prog in fgrep; do
7149 for ac_exec_ext in '' $ac_executable_extensions; do
7150 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7151 as_fn_executable_p "$ac_path_FGREP" || continue
7152 # Check for GNU ac_path_FGREP and select it if it is found.
7153 # Check for GNU $ac_path_FGREP
7154 case `"$ac_path_FGREP" --version 2>&1` in
7155 *GNU*)
7156 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7157 *)
7158 ac_count=0
7159 $as_echo_n 0123456789 >"conftest.in"
7160 while :
7161 do
7162 cat "conftest.in" "conftest.in" >"conftest.tmp"
7163 mv "conftest.tmp" "conftest.in"
7164 cp "conftest.in" "conftest.nl"
7165 $as_echo 'FGREP' >> "conftest.nl"
7166 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7167 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7168 as_fn_arith $ac_count + 1 && ac_count=$as_val
7169 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7170 # Best one so far, save it but keep looking for a better one
7171 ac_cv_path_FGREP="$ac_path_FGREP"
7172 ac_path_FGREP_max=$ac_count
7173 fi
7174 # 10*(2^10) chars as input seems more than enough
7175 test $ac_count -gt 10 && break
7176 done
7177 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7178 esac
7179
7180 $ac_path_FGREP_found && break 3
7181 done
7182 done
7183 done
7184 IFS=$as_save_IFS
7185 if test -z "$ac_cv_path_FGREP"; then
7186 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7187 fi
7188 else
7189 ac_cv_path_FGREP=$FGREP
7190 fi
7191
7192 fi
7193 fi
7194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7195 $as_echo "$ac_cv_path_FGREP" >&6; }
7196 FGREP="$ac_cv_path_FGREP"
7197
7198
7199 test -z "$GREP" && GREP=grep
7200
7201
7202
7203
7204
7205
7206
7207
7208
7209
7210
7211
7212
7213
7214
7215
7216
7217
7218
7219 # Check whether --with-gnu-ld was given.
7220 if test "${with_gnu_ld+set}" = set; then :
7221 withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7222 else
7223 with_gnu_ld=no
7224 fi
7225
7226 ac_prog=ld
7227 if test yes = "$GCC"; then
7228 # Check if gcc -print-prog-name=ld gives a path.
7229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7230 $as_echo_n "checking for ld used by $CC... " >&6; }
7231 case $host in
7232 *-*-mingw*)
7233 # gcc leaves a trailing carriage return, which upsets mingw
7234 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7235 *)
7236 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7237 esac
7238 case $ac_prog in
7239 # Accept absolute paths.
7240 [\\/]* | ?:[\\/]*)
7241 re_direlt='/[^/][^/]*/\.\./'
7242 # Canonicalize the pathname of ld
7243 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7244 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7245 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7246 done
7247 test -z "$LD" && LD=$ac_prog
7248 ;;
7249 "")
7250 # If it fails, then pretend we aren't using GCC.
7251 ac_prog=ld
7252 ;;
7253 *)
7254 # If it is relative, then search for the first ld in PATH.
7255 with_gnu_ld=unknown
7256 ;;
7257 esac
7258 elif test yes = "$with_gnu_ld"; then
7259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7260 $as_echo_n "checking for GNU ld... " >&6; }
7261 else
7262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7263 $as_echo_n "checking for non-GNU ld... " >&6; }
7264 fi
7265 if ${lt_cv_path_LD+:} false; then :
7266 $as_echo_n "(cached) " >&6
7267 else
7268 if test -z "$LD"; then
7269 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7270 for ac_dir in $PATH; do
7271 IFS=$lt_save_ifs
7272 test -z "$ac_dir" && ac_dir=.
7273 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7274 lt_cv_path_LD=$ac_dir/$ac_prog
7275 # Check to see if the program is GNU ld. I'd rather use --version,
7276 # but apparently some variants of GNU ld only accept -v.
7277 # Break only if it was the GNU/non-GNU ld that we prefer.
7278 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7279 *GNU* | *'with BFD'*)
7280 test no != "$with_gnu_ld" && break
7281 ;;
7282 *)
7283 test yes != "$with_gnu_ld" && break
7284 ;;
7285 esac
7286 fi
7287 done
7288 IFS=$lt_save_ifs
7289 else
7290 lt_cv_path_LD=$LD # Let the user override the test with a path.
7291 fi
7292 fi
7293
7294 LD=$lt_cv_path_LD
7295 if test -n "$LD"; then
7296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7297 $as_echo "$LD" >&6; }
7298 else
7299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7300 $as_echo "no" >&6; }
7301 fi
7302 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7304 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7305 if ${lt_cv_prog_gnu_ld+:} false; then :
7306 $as_echo_n "(cached) " >&6
7307 else
7308 # I'd rather use --version here, but apparently some GNU lds only accept -v.
7309 case `$LD -v 2>&1 </dev/null` in
7310 *GNU* | *'with BFD'*)
7311 lt_cv_prog_gnu_ld=yes
7312 ;;
7313 *)
7314 lt_cv_prog_gnu_ld=no
7315 ;;
7316 esac
7317 fi
7318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7319 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
7320 with_gnu_ld=$lt_cv_prog_gnu_ld
7321
7322
7323
7324
7325
7326
7327
7328
7329
7330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7331 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7332 if ${lt_cv_path_NM+:} false; then :
7333 $as_echo_n "(cached) " >&6
7334 else
7335 if test -n "$NM"; then
7336 # Let the user override the test.
7337 lt_cv_path_NM=$NM
7338 else
7339 lt_nm_to_check=${ac_tool_prefix}nm
7340 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7341 lt_nm_to_check="$lt_nm_to_check nm"
7342 fi
7343 for lt_tmp_nm in $lt_nm_to_check; do
7344 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7345 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7346 IFS=$lt_save_ifs
7347 test -z "$ac_dir" && ac_dir=.
7348 tmp_nm=$ac_dir/$lt_tmp_nm
7349 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7350 # Check to see if the nm accepts a BSD-compat flag.
7351 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7352 # nm: unknown option "B" ignored
7353 # Tru64's nm complains that /dev/null is an invalid object file
7354 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7355 case $build_os in
7356 mingw*) lt_bad_file=conftest.nm/nofile ;;
7357 *) lt_bad_file=/dev/null ;;
7358 esac
7359 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7360 *$lt_bad_file* | *'Invalid file or object type'*)
7361 lt_cv_path_NM="$tmp_nm -B"
7362 break 2
7363 ;;
7364 *)
7365 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7366 */dev/null*)
7367 lt_cv_path_NM="$tmp_nm -p"
7368 break 2
7369 ;;
7370 *)
7371 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7372 continue # so that we can try to find one that supports BSD flags
7373 ;;
7374 esac
7375 ;;
7376 esac
7377 fi
7378 done
7379 IFS=$lt_save_ifs
7380 done
7381 : ${lt_cv_path_NM=no}
7382 fi
7383 fi
7384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7385 $as_echo "$lt_cv_path_NM" >&6; }
7386 if test no != "$lt_cv_path_NM"; then
7387 NM=$lt_cv_path_NM
7388 else
7389 # Didn't find any BSD compatible name lister, look for dumpbin.
7390 if test -n "$DUMPBIN"; then :
7391 # Let the user override the test.
7392 else
7393 if test -n "$ac_tool_prefix"; then
7394 for ac_prog in dumpbin "link -dump"
7395 do
7396 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7397 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7399 $as_echo_n "checking for $ac_word... " >&6; }
7400 if ${ac_cv_prog_DUMPBIN+:} false; then :
7401 $as_echo_n "(cached) " >&6
7402 else
7403 if test -n "$DUMPBIN"; then
7404 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7405 else
7406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7407 for as_dir in $PATH
7408 do
7409 IFS=$as_save_IFS
7410 test -z "$as_dir" && as_dir=.
7411 for ac_exec_ext in '' $ac_executable_extensions; do
7412 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7413 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7415 break 2
7416 fi
7417 done
7418 done
7419 IFS=$as_save_IFS
7420
7421 fi
7422 fi
7423 DUMPBIN=$ac_cv_prog_DUMPBIN
7424 if test -n "$DUMPBIN"; then
7425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7426 $as_echo "$DUMPBIN" >&6; }
7427 else
7428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7429 $as_echo "no" >&6; }
7430 fi
7431
7432
7433 test -n "$DUMPBIN" && break
7434 done
7435 fi
7436 if test -z "$DUMPBIN"; then
7437 ac_ct_DUMPBIN=$DUMPBIN
7438 for ac_prog in dumpbin "link -dump"
7439 do
7440 # Extract the first word of "$ac_prog", so it can be a program name with args.
7441 set dummy $ac_prog; ac_word=$2
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7443 $as_echo_n "checking for $ac_word... " >&6; }
7444 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7445 $as_echo_n "(cached) " >&6
7446 else
7447 if test -n "$ac_ct_DUMPBIN"; then
7448 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7449 else
7450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7451 for as_dir in $PATH
7452 do
7453 IFS=$as_save_IFS
7454 test -z "$as_dir" && as_dir=.
7455 for ac_exec_ext in '' $ac_executable_extensions; do
7456 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7457 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7458 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7459 break 2
7460 fi
7461 done
7462 done
7463 IFS=$as_save_IFS
7464
7465 fi
7466 fi
7467 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7468 if test -n "$ac_ct_DUMPBIN"; then
7469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7470 $as_echo "$ac_ct_DUMPBIN" >&6; }
7471 else
7472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7473 $as_echo "no" >&6; }
7474 fi
7475
7476
7477 test -n "$ac_ct_DUMPBIN" && break
7478 done
7479
7480 if test "x$ac_ct_DUMPBIN" = x; then
7481 DUMPBIN=":"
7482 else
7483 case $cross_compiling:$ac_tool_warned in
7484 yes:)
7485 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7486 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7487 ac_tool_warned=yes ;;
7488 esac
7489 DUMPBIN=$ac_ct_DUMPBIN
7490 fi
7491 fi
7492
7493 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7494 *COFF*)
7495 DUMPBIN="$DUMPBIN -symbols -headers"
7496 ;;
7497 *)
7498 DUMPBIN=:
7499 ;;
7500 esac
7501 fi
7502
7503 if test : != "$DUMPBIN"; then
7504 NM=$DUMPBIN
7505 fi
7506 fi
7507 test -z "$NM" && NM=nm
7508
7509
7510
7511
7512
7513
7514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7515 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
7516 if ${lt_cv_nm_interface+:} false; then :
7517 $as_echo_n "(cached) " >&6
7518 else
7519 lt_cv_nm_interface="BSD nm"
7520 echo "int some_variable = 0;" > conftest.$ac_ext
7521 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7522 (eval "$ac_compile" 2>conftest.err)
7523 cat conftest.err >&5
7524 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7525 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7526 cat conftest.err >&5
7527 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7528 cat conftest.out >&5
7529 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7530 lt_cv_nm_interface="MS dumpbin"
7531 fi
7532 rm -f conftest*
7533 fi
7534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7535 $as_echo "$lt_cv_nm_interface" >&6; }
7536
7537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7538 $as_echo_n "checking whether ln -s works... " >&6; }
7539 LN_S=$as_ln_s
7540 if test "$LN_S" = "ln -s"; then
7541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7542 $as_echo "yes" >&6; }
7543 else
7544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7545 $as_echo "no, using $LN_S" >&6; }
7546 fi
7547
7548 # find the maximum length of command line arguments
7549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7550 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
7551 if ${lt_cv_sys_max_cmd_len+:} false; then :
7552 $as_echo_n "(cached) " >&6
7553 else
7554 i=0
7555 teststring=ABCD
7556
7557 case $build_os in
7558 msdosdjgpp*)
7559 # On DJGPP, this test can blow up pretty badly due to problems in libc
7560 # (any single argument exceeding 2000 bytes causes a buffer overrun
7561 # during glob expansion). Even if it were fixed, the result of this
7562 # check would be larger than it should be.
7563 lt_cv_sys_max_cmd_len=12288; # 12K is about right
7564 ;;
7565
7566 gnu*)
7567 # Under GNU Hurd, this test is not required because there is
7568 # no limit to the length of command line arguments.
7569 # Libtool will interpret -1 as no limit whatsoever
7570 lt_cv_sys_max_cmd_len=-1;
7571 ;;
7572
7573 cygwin* | mingw* | cegcc*)
7574 # On Win9x/ME, this test blows up -- it succeeds, but takes
7575 # about 5 minutes as the teststring grows exponentially.
7576 # Worse, since 9x/ME are not pre-emptively multitasking,
7577 # you end up with a "frozen" computer, even though with patience
7578 # the test eventually succeeds (with a max line length of 256k).
7579 # Instead, let's just punt: use the minimum linelength reported by
7580 # all of the supported platforms: 8192 (on NT/2K/XP).
7581 lt_cv_sys_max_cmd_len=8192;
7582 ;;
7583
7584 mint*)
7585 # On MiNT this can take a long time and run out of memory.
7586 lt_cv_sys_max_cmd_len=8192;
7587 ;;
7588
7589 amigaos*)
7590 # On AmigaOS with pdksh, this test takes hours, literally.
7591 # So we just punt and use a minimum line length of 8192.
7592 lt_cv_sys_max_cmd_len=8192;
7593 ;;
7594
7595 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7596 # This has been around since 386BSD, at least. Likely further.
7597 if test -x /sbin/sysctl; then
7598 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7599 elif test -x /usr/sbin/sysctl; then
7600 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7601 else
7602 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
7603 fi
7604 # And add a safety zone
7605 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7606 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7607 ;;
7608
7609 interix*)
7610 # We know the value 262144 and hardcode it with a safety zone (like BSD)
7611 lt_cv_sys_max_cmd_len=196608
7612 ;;
7613
7614 os2*)
7615 # The test takes a long time on OS/2.
7616 lt_cv_sys_max_cmd_len=8192
7617 ;;
7618
7619 osf*)
7620 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7621 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7622 # nice to cause kernel panics so lets avoid the loop below.
7623 # First set a reasonable default.
7624 lt_cv_sys_max_cmd_len=16384
7625 #
7626 if test -x /sbin/sysconfig; then
7627 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7628 *1*) lt_cv_sys_max_cmd_len=-1 ;;
7629 esac
7630 fi
7631 ;;
7632 sco3.2v5*)
7633 lt_cv_sys_max_cmd_len=102400
7634 ;;
7635 sysv5* | sco5v6* | sysv4.2uw2*)
7636 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7637 if test -n "$kargmax"; then
7638 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
7639 else
7640 lt_cv_sys_max_cmd_len=32768
7641 fi
7642 ;;
7643 *)
7644 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7645 if test -n "$lt_cv_sys_max_cmd_len" && \
7646 test undefined != "$lt_cv_sys_max_cmd_len"; then
7647 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7648 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7649 else
7650 # Make teststring a little bigger before we do anything with it.
7651 # a 1K string should be a reasonable start.
7652 for i in 1 2 3 4 5 6 7 8; do
7653 teststring=$teststring$teststring
7654 done
7655 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7656 # If test is not a shell built-in, we'll probably end up computing a
7657 # maximum length that is only half of the actual maximum length, but
7658 # we can't tell.
7659 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7660 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7661 test 17 != "$i" # 1/2 MB should be enough
7662 do
7663 i=`expr $i + 1`
7664 teststring=$teststring$teststring
7665 done
7666 # Only check the string length outside the loop.
7667 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7668 teststring=
7669 # Add a significant safety factor because C++ compilers can tack on
7670 # massive amounts of additional arguments before passing them to the
7671 # linker. It appears as though 1/2 is a usable value.
7672 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7673 fi
7674 ;;
7675 esac
7676
7677 fi
7678
7679 if test -n "$lt_cv_sys_max_cmd_len"; then
7680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7681 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7682 else
7683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7684 $as_echo "none" >&6; }
7685 fi
7686 max_cmd_len=$lt_cv_sys_max_cmd_len
7687
7688
7689
7690
7691
7692
7693 : ${CP="cp -f"}
7694 : ${MV="mv -f"}
7695 : ${RM="rm -f"}
7696
7697 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
7698 lt_unset=unset
7699 else
7700 lt_unset=false
7701 fi
7702
7703
7704
7705
7706
7707 # test EBCDIC or ASCII
7708 case `echo X|tr X '\101'` in
7709 A) # ASCII based system
7710 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
7711 lt_SP2NL='tr \040 \012'
7712 lt_NL2SP='tr \015\012 \040\040'
7713 ;;
7714 *) # EBCDIC based system
7715 lt_SP2NL='tr \100 \n'
7716 lt_NL2SP='tr \r\n \100\100'
7717 ;;
7718 esac
7719
7720
7721
7722
7723
7724
7725
7726
7727
7728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
7729 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
7730 if ${lt_cv_to_host_file_cmd+:} false; then :
7731 $as_echo_n "(cached) " >&6
7732 else
7733 case $host in
7734 *-*-mingw* )
7735 case $build in
7736 *-*-mingw* ) # actually msys
7737 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
7738 ;;
7739 *-*-cygwin* )
7740 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
7741 ;;
7742 * ) # otherwise, assume *nix
7743 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
7744 ;;
7745 esac
7746 ;;
7747 *-*-cygwin* )
7748 case $build in
7749 *-*-mingw* ) # actually msys
7750 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
7751 ;;
7752 *-*-cygwin* )
7753 lt_cv_to_host_file_cmd=func_convert_file_noop
7754 ;;
7755 * ) # otherwise, assume *nix
7756 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
7757 ;;
7758 esac
7759 ;;
7760 * ) # unhandled hosts (and "normal" native builds)
7761 lt_cv_to_host_file_cmd=func_convert_file_noop
7762 ;;
7763 esac
7764
7765 fi
7766
7767 to_host_file_cmd=$lt_cv_to_host_file_cmd
7768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
7769 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
7770
7771
7772
7773
7774
7775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
7776 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
7777 if ${lt_cv_to_tool_file_cmd+:} false; then :
7778 $as_echo_n "(cached) " >&6
7779 else
7780 #assume ordinary cross tools, or native build.
7781 lt_cv_to_tool_file_cmd=func_convert_file_noop
7782 case $host in
7783 *-*-mingw* )
7784 case $build in
7785 *-*-mingw* ) # actually msys
7786 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
7787 ;;
7788 esac
7789 ;;
7790 esac
7791
7792 fi
7793
7794 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
7795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
7796 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
7797
7798
7799
7800
7801
7802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
7803 $as_echo_n "checking for $LD option to reload object files... " >&6; }
7804 if ${lt_cv_ld_reload_flag+:} false; then :
7805 $as_echo_n "(cached) " >&6
7806 else
7807 lt_cv_ld_reload_flag='-r'
7808 fi
7809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
7810 $as_echo "$lt_cv_ld_reload_flag" >&6; }
7811 reload_flag=$lt_cv_ld_reload_flag
7812 case $reload_flag in
7813 "" | " "*) ;;
7814 *) reload_flag=" $reload_flag" ;;
7815 esac
7816 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7817 case $host_os in
7818 cygwin* | mingw* | pw32* | cegcc*)
7819 if test yes != "$GCC"; then
7820 reload_cmds=false
7821 fi
7822 ;;
7823 darwin*)
7824 if test yes = "$GCC"; then
7825 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
7826 else
7827 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7828 fi
7829 ;;
7830 esac
7831
7832
7833
7834
7835
7836
7837
7838
7839
7840 if test -n "$ac_tool_prefix"; then
7841 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
7842 set dummy ${ac_tool_prefix}objdump; ac_word=$2
7843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7844 $as_echo_n "checking for $ac_word... " >&6; }
7845 if ${ac_cv_prog_OBJDUMP+:} false; then :
7846 $as_echo_n "(cached) " >&6
7847 else
7848 if test -n "$OBJDUMP"; then
7849 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
7850 else
7851 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7852 for as_dir in $PATH
7853 do
7854 IFS=$as_save_IFS
7855 test -z "$as_dir" && as_dir=.
7856 for ac_exec_ext in '' $ac_executable_extensions; do
7857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7858 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
7859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7860 break 2
7861 fi
7862 done
7863 done
7864 IFS=$as_save_IFS
7865
7866 fi
7867 fi
7868 OBJDUMP=$ac_cv_prog_OBJDUMP
7869 if test -n "$OBJDUMP"; then
7870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
7871 $as_echo "$OBJDUMP" >&6; }
7872 else
7873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7874 $as_echo "no" >&6; }
7875 fi
7876
7877
7878 fi
7879 if test -z "$ac_cv_prog_OBJDUMP"; then
7880 ac_ct_OBJDUMP=$OBJDUMP
7881 # Extract the first word of "objdump", so it can be a program name with args.
7882 set dummy objdump; ac_word=$2
7883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7884 $as_echo_n "checking for $ac_word... " >&6; }
7885 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
7886 $as_echo_n "(cached) " >&6
7887 else
7888 if test -n "$ac_ct_OBJDUMP"; then
7889 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
7890 else
7891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7892 for as_dir in $PATH
7893 do
7894 IFS=$as_save_IFS
7895 test -z "$as_dir" && as_dir=.
7896 for ac_exec_ext in '' $ac_executable_extensions; do
7897 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7898 ac_cv_prog_ac_ct_OBJDUMP="objdump"
7899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7900 break 2
7901 fi
7902 done
7903 done
7904 IFS=$as_save_IFS
7905
7906 fi
7907 fi
7908 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
7909 if test -n "$ac_ct_OBJDUMP"; then
7910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
7911 $as_echo "$ac_ct_OBJDUMP" >&6; }
7912 else
7913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7914 $as_echo "no" >&6; }
7915 fi
7916
7917 if test "x$ac_ct_OBJDUMP" = x; then
7918 OBJDUMP="false"
7919 else
7920 case $cross_compiling:$ac_tool_warned in
7921 yes:)
7922 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7923 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7924 ac_tool_warned=yes ;;
7925 esac
7926 OBJDUMP=$ac_ct_OBJDUMP
7927 fi
7928 else
7929 OBJDUMP="$ac_cv_prog_OBJDUMP"
7930 fi
7931
7932 test -z "$OBJDUMP" && OBJDUMP=objdump
7933
7934
7935
7936
7937
7938
7939
7940
7941
7942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
7943 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
7944 if ${lt_cv_deplibs_check_method+:} false; then :
7945 $as_echo_n "(cached) " >&6
7946 else
7947 lt_cv_file_magic_cmd='$MAGIC_CMD'
7948 lt_cv_file_magic_test_file=
7949 lt_cv_deplibs_check_method='unknown'
7950 # Need to set the preceding variable on all platforms that support
7951 # interlibrary dependencies.
7952 # 'none' -- dependencies not supported.
7953 # 'unknown' -- same as none, but documents that we really don't know.
7954 # 'pass_all' -- all dependencies passed with no checks.
7955 # 'test_compile' -- check by making test program.
7956 # 'file_magic [[regex]]' -- check by looking for files in library path
7957 # that responds to the $file_magic_cmd with a given extended regex.
7958 # If you have 'file' or equivalent on your system and you're not sure
7959 # whether 'pass_all' will *always* work, you probably want this one.
7960
7961 case $host_os in
7962 aix[4-9]*)
7963 lt_cv_deplibs_check_method=pass_all
7964 ;;
7965
7966 beos*)
7967 lt_cv_deplibs_check_method=pass_all
7968 ;;
7969
7970 bsdi[45]*)
7971 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
7972 lt_cv_file_magic_cmd='/usr/bin/file -L'
7973 lt_cv_file_magic_test_file=/shlib/libc.so
7974 ;;
7975
7976 cygwin*)
7977 # func_win32_libid is a shell function defined in ltmain.sh
7978 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7979 lt_cv_file_magic_cmd='func_win32_libid'
7980 ;;
7981
7982 mingw* | pw32*)
7983 # Base MSYS/MinGW do not provide the 'file' command needed by
7984 # func_win32_libid shell function, so use a weaker test based on 'objdump',
7985 # unless we find 'file', for example because we are cross-compiling.
7986 if ( file / ) >/dev/null 2>&1; then
7987 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
7988 lt_cv_file_magic_cmd='func_win32_libid'
7989 else
7990 # Keep this pattern in sync with the one in func_win32_libid.
7991 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
7992 lt_cv_file_magic_cmd='$OBJDUMP -f'
7993 fi
7994 ;;
7995
7996 cegcc*)
7997 # use the weaker test based on 'objdump'. See mingw*.
7998 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
7999 lt_cv_file_magic_cmd='$OBJDUMP -f'
8000 ;;
8001
8002 darwin* | rhapsody*)
8003 lt_cv_deplibs_check_method=pass_all
8004 ;;
8005
8006 freebsd* | dragonfly*)
8007 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8008 case $host_cpu in
8009 i*86 )
8010 # Not sure whether the presence of OpenBSD here was a mistake.
8011 # Let's accept both of them until this is cleared up.
8012 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8013 lt_cv_file_magic_cmd=/usr/bin/file
8014 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8015 ;;
8016 esac
8017 else
8018 lt_cv_deplibs_check_method=pass_all
8019 fi
8020 ;;
8021
8022 haiku*)
8023 lt_cv_deplibs_check_method=pass_all
8024 ;;
8025
8026 hpux10.20* | hpux11*)
8027 lt_cv_file_magic_cmd=/usr/bin/file
8028 case $host_cpu in
8029 ia64*)
8030 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8031 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8032 ;;
8033 hppa*64*)
8034 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]'
8035 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8036 ;;
8037 *)
8038 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8039 lt_cv_file_magic_test_file=/usr/lib/libc.sl
8040 ;;
8041 esac
8042 ;;
8043
8044 interix[3-9]*)
8045 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8046 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8047 ;;
8048
8049 irix5* | irix6* | nonstopux*)
8050 case $LD in
8051 *-32|*"-32 ") libmagic=32-bit;;
8052 *-n32|*"-n32 ") libmagic=N32;;
8053 *-64|*"-64 ") libmagic=64-bit;;
8054 *) libmagic=never-match;;
8055 esac
8056 lt_cv_deplibs_check_method=pass_all
8057 ;;
8058
8059 # This must be glibc/ELF.
8060 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8061 lt_cv_deplibs_check_method=pass_all
8062 ;;
8063
8064 netbsd* | netbsdelf*-gnu)
8065 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8066 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8067 else
8068 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8069 fi
8070 ;;
8071
8072 newos6*)
8073 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8074 lt_cv_file_magic_cmd=/usr/bin/file
8075 lt_cv_file_magic_test_file=/usr/lib/libnls.so
8076 ;;
8077
8078 *nto* | *qnx*)
8079 lt_cv_deplibs_check_method=pass_all
8080 ;;
8081
8082 openbsd* | bitrig*)
8083 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8084 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8085 else
8086 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8087 fi
8088 ;;
8089
8090 osf3* | osf4* | osf5*)
8091 lt_cv_deplibs_check_method=pass_all
8092 ;;
8093
8094 rdos*)
8095 lt_cv_deplibs_check_method=pass_all
8096 ;;
8097
8098 solaris*)
8099 lt_cv_deplibs_check_method=pass_all
8100 ;;
8101
8102 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8103 lt_cv_deplibs_check_method=pass_all
8104 ;;
8105
8106 sysv4 | sysv4.3*)
8107 case $host_vendor in
8108 motorola)
8109 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]'
8110 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8111 ;;
8112 ncr)
8113 lt_cv_deplibs_check_method=pass_all
8114 ;;
8115 sequent)
8116 lt_cv_file_magic_cmd='/bin/file'
8117 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8118 ;;
8119 sni)
8120 lt_cv_file_magic_cmd='/bin/file'
8121 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8122 lt_cv_file_magic_test_file=/lib/libc.so
8123 ;;
8124 siemens)
8125 lt_cv_deplibs_check_method=pass_all
8126 ;;
8127 pc)
8128 lt_cv_deplibs_check_method=pass_all
8129 ;;
8130 esac
8131 ;;
8132
8133 tpf*)
8134 lt_cv_deplibs_check_method=pass_all
8135 ;;
8136 os2*)
8137 lt_cv_deplibs_check_method=pass_all
8138 ;;
8139 esac
8140
8141 fi
8142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8143 $as_echo "$lt_cv_deplibs_check_method" >&6; }
8144
8145 file_magic_glob=
8146 want_nocaseglob=no
8147 if test "$build" = "$host"; then
8148 case $host_os in
8149 mingw* | pw32*)
8150 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8151 want_nocaseglob=yes
8152 else
8153 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8154 fi
8155 ;;
8156 esac
8157 fi
8158
8159 file_magic_cmd=$lt_cv_file_magic_cmd
8160 deplibs_check_method=$lt_cv_deplibs_check_method
8161 test -z "$deplibs_check_method" && deplibs_check_method=unknown
8162
8163
8164
8165
8166
8167
8168
8169
8170
8171
8172
8173
8174
8175
8176
8177
8178
8179
8180
8181
8182
8183
8184 if test -n "$ac_tool_prefix"; then
8185 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8186 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8188 $as_echo_n "checking for $ac_word... " >&6; }
8189 if ${ac_cv_prog_DLLTOOL+:} false; then :
8190 $as_echo_n "(cached) " >&6
8191 else
8192 if test -n "$DLLTOOL"; then
8193 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8194 else
8195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8196 for as_dir in $PATH
8197 do
8198 IFS=$as_save_IFS
8199 test -z "$as_dir" && as_dir=.
8200 for ac_exec_ext in '' $ac_executable_extensions; do
8201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8202 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8204 break 2
8205 fi
8206 done
8207 done
8208 IFS=$as_save_IFS
8209
8210 fi
8211 fi
8212 DLLTOOL=$ac_cv_prog_DLLTOOL
8213 if test -n "$DLLTOOL"; then
8214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8215 $as_echo "$DLLTOOL" >&6; }
8216 else
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8218 $as_echo "no" >&6; }
8219 fi
8220
8221
8222 fi
8223 if test -z "$ac_cv_prog_DLLTOOL"; then
8224 ac_ct_DLLTOOL=$DLLTOOL
8225 # Extract the first word of "dlltool", so it can be a program name with args.
8226 set dummy dlltool; ac_word=$2
8227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8228 $as_echo_n "checking for $ac_word... " >&6; }
8229 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8230 $as_echo_n "(cached) " >&6
8231 else
8232 if test -n "$ac_ct_DLLTOOL"; then
8233 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8234 else
8235 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8236 for as_dir in $PATH
8237 do
8238 IFS=$as_save_IFS
8239 test -z "$as_dir" && as_dir=.
8240 for ac_exec_ext in '' $ac_executable_extensions; do
8241 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8242 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8243 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8244 break 2
8245 fi
8246 done
8247 done
8248 IFS=$as_save_IFS
8249
8250 fi
8251 fi
8252 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8253 if test -n "$ac_ct_DLLTOOL"; then
8254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8255 $as_echo "$ac_ct_DLLTOOL" >&6; }
8256 else
8257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8258 $as_echo "no" >&6; }
8259 fi
8260
8261 if test "x$ac_ct_DLLTOOL" = x; then
8262 DLLTOOL="false"
8263 else
8264 case $cross_compiling:$ac_tool_warned in
8265 yes:)
8266 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8267 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8268 ac_tool_warned=yes ;;
8269 esac
8270 DLLTOOL=$ac_ct_DLLTOOL
8271 fi
8272 else
8273 DLLTOOL="$ac_cv_prog_DLLTOOL"
8274 fi
8275
8276 test -z "$DLLTOOL" && DLLTOOL=dlltool
8277
8278
8279
8280
8281
8282
8283
8284
8285
8286
8287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8288 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8289 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8290 $as_echo_n "(cached) " >&6
8291 else
8292 lt_cv_sharedlib_from_linklib_cmd='unknown'
8293
8294 case $host_os in
8295 cygwin* | mingw* | pw32* | cegcc*)
8296 # two different shell functions defined in ltmain.sh;
8297 # decide which one to use based on capabilities of $DLLTOOL
8298 case `$DLLTOOL --help 2>&1` in
8299 *--identify-strict*)
8300 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8301 ;;
8302 *)
8303 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8304 ;;
8305 esac
8306 ;;
8307 *)
8308 # fallback: assume linklib IS sharedlib
8309 lt_cv_sharedlib_from_linklib_cmd=$ECHO
8310 ;;
8311 esac
8312
8313 fi
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8315 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8316 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8317 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8318
8319
8320
8321
8322
8323
8324
8325 if test -n "$ac_tool_prefix"; then
8326 for ac_prog in ar
8327 do
8328 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8329 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8331 $as_echo_n "checking for $ac_word... " >&6; }
8332 if ${ac_cv_prog_AR+:} false; then :
8333 $as_echo_n "(cached) " >&6
8334 else
8335 if test -n "$AR"; then
8336 ac_cv_prog_AR="$AR" # Let the user override the test.
8337 else
8338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8339 for as_dir in $PATH
8340 do
8341 IFS=$as_save_IFS
8342 test -z "$as_dir" && as_dir=.
8343 for ac_exec_ext in '' $ac_executable_extensions; do
8344 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8345 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8347 break 2
8348 fi
8349 done
8350 done
8351 IFS=$as_save_IFS
8352
8353 fi
8354 fi
8355 AR=$ac_cv_prog_AR
8356 if test -n "$AR"; then
8357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8358 $as_echo "$AR" >&6; }
8359 else
8360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8361 $as_echo "no" >&6; }
8362 fi
8363
8364
8365 test -n "$AR" && break
8366 done
8367 fi
8368 if test -z "$AR"; then
8369 ac_ct_AR=$AR
8370 for ac_prog in ar
8371 do
8372 # Extract the first word of "$ac_prog", so it can be a program name with args.
8373 set dummy $ac_prog; ac_word=$2
8374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8375 $as_echo_n "checking for $ac_word... " >&6; }
8376 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8377 $as_echo_n "(cached) " >&6
8378 else
8379 if test -n "$ac_ct_AR"; then
8380 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8381 else
8382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8383 for as_dir in $PATH
8384 do
8385 IFS=$as_save_IFS
8386 test -z "$as_dir" && as_dir=.
8387 for ac_exec_ext in '' $ac_executable_extensions; do
8388 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8389 ac_cv_prog_ac_ct_AR="$ac_prog"
8390 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8391 break 2
8392 fi
8393 done
8394 done
8395 IFS=$as_save_IFS
8396
8397 fi
8398 fi
8399 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8400 if test -n "$ac_ct_AR"; then
8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8402 $as_echo "$ac_ct_AR" >&6; }
8403 else
8404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8405 $as_echo "no" >&6; }
8406 fi
8407
8408
8409 test -n "$ac_ct_AR" && break
8410 done
8411
8412 if test "x$ac_ct_AR" = x; then
8413 AR="false"
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 AR=$ac_ct_AR
8422 fi
8423 fi
8424
8425 : ${AR=ar}
8426 : ${AR_FLAGS=cru}
8427
8428
8429
8430
8431
8432
8433
8434
8435
8436
8437
8438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8439 $as_echo_n "checking for archiver @FILE support... " >&6; }
8440 if ${lt_cv_ar_at_file+:} false; then :
8441 $as_echo_n "(cached) " >&6
8442 else
8443 lt_cv_ar_at_file=no
8444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8445 /* end confdefs.h. */
8446
8447 int
8448 main ()
8449 {
8450
8451 ;
8452 return 0;
8453 }
8454 _ACEOF
8455 if ac_fn_c_try_compile "$LINENO"; then :
8456 echo conftest.$ac_objext > conftest.lst
8457 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8458 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8459 (eval $lt_ar_try) 2>&5
8460 ac_status=$?
8461 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8462 test $ac_status = 0; }
8463 if test 0 -eq "$ac_status"; then
8464 # Ensure the archiver fails upon bogus file names.
8465 rm -f conftest.$ac_objext libconftest.a
8466 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8467 (eval $lt_ar_try) 2>&5
8468 ac_status=$?
8469 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8470 test $ac_status = 0; }
8471 if test 0 -ne "$ac_status"; then
8472 lt_cv_ar_at_file=@
8473 fi
8474 fi
8475 rm -f conftest.* libconftest.a
8476
8477 fi
8478 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8479
8480 fi
8481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8482 $as_echo "$lt_cv_ar_at_file" >&6; }
8483
8484 if test no = "$lt_cv_ar_at_file"; then
8485 archiver_list_spec=
8486 else
8487 archiver_list_spec=$lt_cv_ar_at_file
8488 fi
8489
8490
8491
8492
8493
8494
8495
8496 if test -n "$ac_tool_prefix"; then
8497 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8498 set dummy ${ac_tool_prefix}strip; ac_word=$2
8499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8500 $as_echo_n "checking for $ac_word... " >&6; }
8501 if ${ac_cv_prog_STRIP+:} false; then :
8502 $as_echo_n "(cached) " >&6
8503 else
8504 if test -n "$STRIP"; then
8505 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8506 else
8507 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8508 for as_dir in $PATH
8509 do
8510 IFS=$as_save_IFS
8511 test -z "$as_dir" && as_dir=.
8512 for ac_exec_ext in '' $ac_executable_extensions; do
8513 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8514 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8515 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8516 break 2
8517 fi
8518 done
8519 done
8520 IFS=$as_save_IFS
8521
8522 fi
8523 fi
8524 STRIP=$ac_cv_prog_STRIP
8525 if test -n "$STRIP"; then
8526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8527 $as_echo "$STRIP" >&6; }
8528 else
8529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8530 $as_echo "no" >&6; }
8531 fi
8532
8533
8534 fi
8535 if test -z "$ac_cv_prog_STRIP"; then
8536 ac_ct_STRIP=$STRIP
8537 # Extract the first word of "strip", so it can be a program name with args.
8538 set dummy strip; ac_word=$2
8539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8540 $as_echo_n "checking for $ac_word... " >&6; }
8541 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8542 $as_echo_n "(cached) " >&6
8543 else
8544 if test -n "$ac_ct_STRIP"; then
8545 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8546 else
8547 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8548 for as_dir in $PATH
8549 do
8550 IFS=$as_save_IFS
8551 test -z "$as_dir" && as_dir=.
8552 for ac_exec_ext in '' $ac_executable_extensions; do
8553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8554 ac_cv_prog_ac_ct_STRIP="strip"
8555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8556 break 2
8557 fi
8558 done
8559 done
8560 IFS=$as_save_IFS
8561
8562 fi
8563 fi
8564 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8565 if test -n "$ac_ct_STRIP"; then
8566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8567 $as_echo "$ac_ct_STRIP" >&6; }
8568 else
8569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8570 $as_echo "no" >&6; }
8571 fi
8572
8573 if test "x$ac_ct_STRIP" = x; then
8574 STRIP=":"
8575 else
8576 case $cross_compiling:$ac_tool_warned in
8577 yes:)
8578 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8579 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8580 ac_tool_warned=yes ;;
8581 esac
8582 STRIP=$ac_ct_STRIP
8583 fi
8584 else
8585 STRIP="$ac_cv_prog_STRIP"
8586 fi
8587
8588 test -z "$STRIP" && STRIP=:
8589
8590
8591
8592
8593
8594
8595 if test -n "$ac_tool_prefix"; then
8596 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8597 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8599 $as_echo_n "checking for $ac_word... " >&6; }
8600 if ${ac_cv_prog_RANLIB+:} false; then :
8601 $as_echo_n "(cached) " >&6
8602 else
8603 if test -n "$RANLIB"; then
8604 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8605 else
8606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8607 for as_dir in $PATH
8608 do
8609 IFS=$as_save_IFS
8610 test -z "$as_dir" && as_dir=.
8611 for ac_exec_ext in '' $ac_executable_extensions; do
8612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8613 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8615 break 2
8616 fi
8617 done
8618 done
8619 IFS=$as_save_IFS
8620
8621 fi
8622 fi
8623 RANLIB=$ac_cv_prog_RANLIB
8624 if test -n "$RANLIB"; then
8625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8626 $as_echo "$RANLIB" >&6; }
8627 else
8628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8629 $as_echo "no" >&6; }
8630 fi
8631
8632
8633 fi
8634 if test -z "$ac_cv_prog_RANLIB"; then
8635 ac_ct_RANLIB=$RANLIB
8636 # Extract the first word of "ranlib", so it can be a program name with args.
8637 set dummy ranlib; ac_word=$2
8638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8639 $as_echo_n "checking for $ac_word... " >&6; }
8640 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8641 $as_echo_n "(cached) " >&6
8642 else
8643 if test -n "$ac_ct_RANLIB"; then
8644 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8645 else
8646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8647 for as_dir in $PATH
8648 do
8649 IFS=$as_save_IFS
8650 test -z "$as_dir" && as_dir=.
8651 for ac_exec_ext in '' $ac_executable_extensions; do
8652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8653 ac_cv_prog_ac_ct_RANLIB="ranlib"
8654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8655 break 2
8656 fi
8657 done
8658 done
8659 IFS=$as_save_IFS
8660
8661 fi
8662 fi
8663 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8664 if test -n "$ac_ct_RANLIB"; then
8665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8666 $as_echo "$ac_ct_RANLIB" >&6; }
8667 else
8668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8669 $as_echo "no" >&6; }
8670 fi
8671
8672 if test "x$ac_ct_RANLIB" = x; then
8673 RANLIB=":"
8674 else
8675 case $cross_compiling:$ac_tool_warned in
8676 yes:)
8677 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8678 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8679 ac_tool_warned=yes ;;
8680 esac
8681 RANLIB=$ac_ct_RANLIB
8682 fi
8683 else
8684 RANLIB="$ac_cv_prog_RANLIB"
8685 fi
8686
8687 test -z "$RANLIB" && RANLIB=:
8688
8689
8690
8691
8692
8693
8694 # Determine commands to create old-style static archives.
8695 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8696 old_postinstall_cmds='chmod 644 $oldlib'
8697 old_postuninstall_cmds=
8698
8699 if test -n "$RANLIB"; then
8700 case $host_os in
8701 bitrig* | openbsd*)
8702 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
8703 ;;
8704 *)
8705 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
8706 ;;
8707 esac
8708 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
8709 fi
8710
8711 case $host_os in
8712 darwin*)
8713 lock_old_archive_extraction=yes ;;
8714 *)
8715 lock_old_archive_extraction=no ;;
8716 esac
8717
8718
8719
8720
8721
8722
8723
8724
8725
8726
8727
8728
8729
8730
8731
8732
8733
8734
8735
8736
8737
8738 for ac_prog in gawk mawk nawk awk
8739 do
8740 # Extract the first word of "$ac_prog", so it can be a program name with args.
8741 set dummy $ac_prog; ac_word=$2
8742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8743 $as_echo_n "checking for $ac_word... " >&6; }
8744 if ${ac_cv_prog_AWK+:} false; then :
8745 $as_echo_n "(cached) " >&6
8746 else
8747 if test -n "$AWK"; then
8748 ac_cv_prog_AWK="$AWK" # Let the user override the test.
8749 else
8750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8751 for as_dir in $PATH
8752 do
8753 IFS=$as_save_IFS
8754 test -z "$as_dir" && as_dir=.
8755 for ac_exec_ext in '' $ac_executable_extensions; do
8756 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8757 ac_cv_prog_AWK="$ac_prog"
8758 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8759 break 2
8760 fi
8761 done
8762 done
8763 IFS=$as_save_IFS
8764
8765 fi
8766 fi
8767 AWK=$ac_cv_prog_AWK
8768 if test -n "$AWK"; then
8769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
8770 $as_echo "$AWK" >&6; }
8771 else
8772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8773 $as_echo "no" >&6; }
8774 fi
8775
8776
8777 test -n "$AWK" && break
8778 done
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798 # If no C compiler was specified, use CC.
8799 LTCC=${LTCC-"$CC"}
8800
8801 # If no C compiler flags were specified, use CFLAGS.
8802 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8803
8804 # Allow CC to be a program name with arguments.
8805 compiler=$CC
8806
8807
8808 # Check for command to grab the raw symbol name followed by C symbol from nm.
8809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
8810 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
8811 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
8812 $as_echo_n "(cached) " >&6
8813 else
8814
8815 # These are sane defaults that work on at least a few old systems.
8816 # [They come from Ultrix. What could be older than Ultrix?!! ;)]
8817
8818 # Character class describing NM global symbol codes.
8819 symcode='[BCDEGRST]'
8820
8821 # Regexp to match symbols that can be accessed directly from C.
8822 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
8823
8824 # Define system-specific variables.
8825 case $host_os in
8826 aix*)
8827 symcode='[BCDT]'
8828 ;;
8829 cygwin* | mingw* | pw32* | cegcc*)
8830 symcode='[ABCDGISTW]'
8831 ;;
8832 hpux*)
8833 if test ia64 = "$host_cpu"; then
8834 symcode='[ABCDEGRST]'
8835 fi
8836 ;;
8837 irix* | nonstopux*)
8838 symcode='[BCDEGRST]'
8839 ;;
8840 osf*)
8841 symcode='[BCDEGQRST]'
8842 ;;
8843 solaris*)
8844 symcode='[BDRT]'
8845 ;;
8846 sco3.2v5*)
8847 symcode='[DT]'
8848 ;;
8849 sysv4.2uw2*)
8850 symcode='[DT]'
8851 ;;
8852 sysv5* | sco5v6* | unixware* | OpenUNIX*)
8853 symcode='[ABDT]'
8854 ;;
8855 sysv4)
8856 symcode='[DFNSTU]'
8857 ;;
8858 esac
8859
8860 # If we're using GNU nm, then use its standard symbol codes.
8861 case `$NM -V 2>&1` in
8862 *GNU* | *'with BFD'*)
8863 symcode='[ABCDGIRSTW]' ;;
8864 esac
8865
8866 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8867 # Gets list of data symbols to import.
8868 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
8869 # Adjust the below global symbol transforms to fixup imported variables.
8870 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
8871 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
8872 lt_c_name_lib_hook="\
8873 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
8874 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
8875 else
8876 # Disable hooks by default.
8877 lt_cv_sys_global_symbol_to_import=
8878 lt_cdecl_hook=
8879 lt_c_name_hook=
8880 lt_c_name_lib_hook=
8881 fi
8882
8883 # Transform an extracted symbol line into a proper C declaration.
8884 # Some systems (esp. on ia64) link data and code symbols differently,
8885 # so use this general approach.
8886 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
8887 $lt_cdecl_hook\
8888 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
8889 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
8890
8891 # Transform an extracted symbol line into symbol name and symbol address
8892 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
8893 $lt_c_name_hook\
8894 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
8895 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
8896
8897 # Transform an extracted symbol line into symbol name with lib prefix and
8898 # symbol address.
8899 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
8900 $lt_c_name_lib_hook\
8901 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
8902 " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
8903 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
8904
8905 # Handle CRLF in mingw tool chain
8906 opt_cr=
8907 case $build_os in
8908 mingw*)
8909 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
8910 ;;
8911 esac
8912
8913 # Try without a prefix underscore, then with it.
8914 for ac_symprfx in "" "_"; do
8915
8916 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
8917 symxfrm="\\1 $ac_symprfx\\2 \\2"
8918
8919 # Write the raw and C identifiers.
8920 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
8921 # Fake it for dumpbin and say T for any non-static function,
8922 # D for any global variable and I for any imported variable.
8923 # Also find C++ and __fastcall symbols from MSVC++,
8924 # which start with @ or ?.
8925 lt_cv_sys_global_symbol_pipe="$AWK '"\
8926 " {last_section=section; section=\$ 3};"\
8927 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
8928 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
8929 " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
8930 " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
8931 " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
8932 " \$ 0!~/External *\|/{next};"\
8933 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
8934 " {if(hide[section]) next};"\
8935 " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
8936 " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
8937 " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
8938 " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
8939 " ' prfx=^$ac_symprfx"
8940 else
8941 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
8942 fi
8943 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
8944
8945 # Check to see that the pipe works correctly.
8946 pipe_works=no
8947
8948 rm -f conftest*
8949 cat > conftest.$ac_ext <<_LT_EOF
8950 #ifdef __cplusplus
8951 extern "C" {
8952 #endif
8953 char nm_test_var;
8954 void nm_test_func(void);
8955 void nm_test_func(void){}
8956 #ifdef __cplusplus
8957 }
8958 #endif
8959 int main(){nm_test_var='a';nm_test_func();return(0);}
8960 _LT_EOF
8961
8962 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
8963 (eval $ac_compile) 2>&5
8964 ac_status=$?
8965 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8966 test $ac_status = 0; }; then
8967 # Now try to grab the symbols.
8968 nlist=conftest.nm
8969 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
8970 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
8971 ac_status=$?
8972 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8973 test $ac_status = 0; } && test -s "$nlist"; then
8974 # Try sorting and uniquifying the output.
8975 if sort "$nlist" | uniq > "$nlist"T; then
8976 mv -f "$nlist"T "$nlist"
8977 else
8978 rm -f "$nlist"T
8979 fi
8980
8981 # Make sure that we snagged all the symbols we need.
8982 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
8983 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
8984 cat <<_LT_EOF > conftest.$ac_ext
8985 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
8986 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
8987 /* DATA imports from DLLs on WIN32 can't be const, because runtime
8988 relocations are performed -- see ld's documentation on pseudo-relocs. */
8989 # define LT_DLSYM_CONST
8990 #elif defined __osf__
8991 /* This system does not cope well with relocations in const data. */
8992 # define LT_DLSYM_CONST
8993 #else
8994 # define LT_DLSYM_CONST const
8995 #endif
8996
8997 #ifdef __cplusplus
8998 extern "C" {
8999 #endif
9000
9001 _LT_EOF
9002 # Now generate the symbol file.
9003 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9004
9005 cat <<_LT_EOF >> conftest.$ac_ext
9006
9007 /* The mapping between symbol names and symbols. */
9008 LT_DLSYM_CONST struct {
9009 const char *name;
9010 void *address;
9011 }
9012 lt__PROGRAM__LTX_preloaded_symbols[] =
9013 {
9014 { "@PROGRAM@", (void *) 0 },
9015 _LT_EOF
9016 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9017 cat <<\_LT_EOF >> conftest.$ac_ext
9018 {0, (void *) 0}
9019 };
9020
9021 /* This works around a problem in FreeBSD linker */
9022 #ifdef FREEBSD_WORKAROUND
9023 static const void *lt_preloaded_setup() {
9024 return lt__PROGRAM__LTX_preloaded_symbols;
9025 }
9026 #endif
9027
9028 #ifdef __cplusplus
9029 }
9030 #endif
9031 _LT_EOF
9032 # Now try linking the two files.
9033 mv conftest.$ac_objext conftstm.$ac_objext
9034 lt_globsym_save_LIBS=$LIBS
9035 lt_globsym_save_CFLAGS=$CFLAGS
9036 LIBS=conftstm.$ac_objext
9037 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9038 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9039 (eval $ac_link) 2>&5
9040 ac_status=$?
9041 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9042 test $ac_status = 0; } && test -s conftest$ac_exeext; then
9043 pipe_works=yes
9044 fi
9045 LIBS=$lt_globsym_save_LIBS
9046 CFLAGS=$lt_globsym_save_CFLAGS
9047 else
9048 echo "cannot find nm_test_func in $nlist" >&5
9049 fi
9050 else
9051 echo "cannot find nm_test_var in $nlist" >&5
9052 fi
9053 else
9054 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9055 fi
9056 else
9057 echo "$progname: failed program was:" >&5
9058 cat conftest.$ac_ext >&5
9059 fi
9060 rm -rf conftest* conftst*
9061
9062 # Do not use the global_symbol_pipe unless it works.
9063 if test yes = "$pipe_works"; then
9064 break
9065 else
9066 lt_cv_sys_global_symbol_pipe=
9067 fi
9068 done
9069
9070 fi
9071
9072 if test -z "$lt_cv_sys_global_symbol_pipe"; then
9073 lt_cv_sys_global_symbol_to_cdecl=
9074 fi
9075 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9077 $as_echo "failed" >&6; }
9078 else
9079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9080 $as_echo "ok" >&6; }
9081 fi
9082
9083 # Response file support.
9084 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9085 nm_file_list_spec='@'
9086 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9087 nm_file_list_spec='@'
9088 fi
9089
9090
9091
9092
9093
9094
9095
9096
9097
9098
9099
9100
9101
9102
9103
9104
9105
9106
9107
9108
9109
9110
9111
9112
9113
9114
9115
9116
9117
9118
9119
9120
9121
9122
9123
9124
9125
9126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9127 $as_echo_n "checking for sysroot... " >&6; }
9128
9129 # Check whether --with-sysroot was given.
9130 if test "${with_sysroot+set}" = set; then :
9131 withval=$with_sysroot;
9132 else
9133 with_sysroot=no
9134 fi
9135
9136
9137 lt_sysroot=
9138 case $with_sysroot in #(
9139 yes)
9140 if test yes = "$GCC"; then
9141 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9142 fi
9143 ;; #(
9144 /*)
9145 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9146 ;; #(
9147 no|'')
9148 ;; #(
9149 *)
9150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9151 $as_echo "$with_sysroot" >&6; }
9152 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9153 ;;
9154 esac
9155
9156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9157 $as_echo "${lt_sysroot:-no}" >&6; }
9158
9159
9160
9161
9162
9163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9164 $as_echo_n "checking for a working dd... " >&6; }
9165 if ${ac_cv_path_lt_DD+:} false; then :
9166 $as_echo_n "(cached) " >&6
9167 else
9168 printf 0123456789abcdef0123456789abcdef >conftest.i
9169 cat conftest.i conftest.i >conftest2.i
9170 : ${lt_DD:=$DD}
9171 if test -z "$lt_DD"; then
9172 ac_path_lt_DD_found=false
9173 # Loop through the user's path and test for each of PROGNAME-LIST
9174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9175 for as_dir in $PATH
9176 do
9177 IFS=$as_save_IFS
9178 test -z "$as_dir" && as_dir=.
9179 for ac_prog in dd; do
9180 for ac_exec_ext in '' $ac_executable_extensions; do
9181 ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9182 as_fn_executable_p "$ac_path_lt_DD" || continue
9183 if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9184 cmp -s conftest.i conftest.out \
9185 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9186 fi
9187 $ac_path_lt_DD_found && break 3
9188 done
9189 done
9190 done
9191 IFS=$as_save_IFS
9192 if test -z "$ac_cv_path_lt_DD"; then
9193 :
9194 fi
9195 else
9196 ac_cv_path_lt_DD=$lt_DD
9197 fi
9198
9199 rm -f conftest.i conftest2.i conftest.out
9200 fi
9201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9202 $as_echo "$ac_cv_path_lt_DD" >&6; }
9203
9204
9205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9206 $as_echo_n "checking how to truncate binary pipes... " >&6; }
9207 if ${lt_cv_truncate_bin+:} false; then :
9208 $as_echo_n "(cached) " >&6
9209 else
9210 printf 0123456789abcdef0123456789abcdef >conftest.i
9211 cat conftest.i conftest.i >conftest2.i
9212 lt_cv_truncate_bin=
9213 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9214 cmp -s conftest.i conftest.out \
9215 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9216 fi
9217 rm -f conftest.i conftest2.i conftest.out
9218 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9219 fi
9220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9221 $as_echo "$lt_cv_truncate_bin" >&6; }
9222
9223
9224
9225
9226
9227
9228
9229 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
9230 func_cc_basename ()
9231 {
9232 for cc_temp in $*""; do
9233 case $cc_temp in
9234 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9235 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9236 \-*) ;;
9237 *) break;;
9238 esac
9239 done
9240 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9241 }
9242
9243 # Check whether --enable-libtool-lock was given.
9244 if test "${enable_libtool_lock+set}" = set; then :
9245 enableval=$enable_libtool_lock;
9246 fi
9247
9248 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9249
9250 # Some flags need to be propagated to the compiler or linker for good
9251 # libtool support.
9252 case $host in
9253 ia64-*-hpux*)
9254 # Find out what ABI is being produced by ac_compile, and set mode
9255 # options accordingly.
9256 echo 'int i;' > conftest.$ac_ext
9257 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9258 (eval $ac_compile) 2>&5
9259 ac_status=$?
9260 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9261 test $ac_status = 0; }; then
9262 case `/usr/bin/file conftest.$ac_objext` in
9263 *ELF-32*)
9264 HPUX_IA64_MODE=32
9265 ;;
9266 *ELF-64*)
9267 HPUX_IA64_MODE=64
9268 ;;
9269 esac
9270 fi
9271 rm -rf conftest*
9272 ;;
9273 *-*-irix6*)
9274 # Find out what ABI is being produced by ac_compile, and set linker
9275 # options accordingly.
9276 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9277 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9278 (eval $ac_compile) 2>&5
9279 ac_status=$?
9280 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9281 test $ac_status = 0; }; then
9282 if test yes = "$lt_cv_prog_gnu_ld"; then
9283 case `/usr/bin/file conftest.$ac_objext` in
9284 *32-bit*)
9285 LD="${LD-ld} -melf32bsmip"
9286 ;;
9287 *N32*)
9288 LD="${LD-ld} -melf32bmipn32"
9289 ;;
9290 *64-bit*)
9291 LD="${LD-ld} -melf64bmip"
9292 ;;
9293 esac
9294 else
9295 case `/usr/bin/file conftest.$ac_objext` in
9296 *32-bit*)
9297 LD="${LD-ld} -32"
9298 ;;
9299 *N32*)
9300 LD="${LD-ld} -n32"
9301 ;;
9302 *64-bit*)
9303 LD="${LD-ld} -64"
9304 ;;
9305 esac
9306 fi
9307 fi
9308 rm -rf conftest*
9309 ;;
9310
9311 mips64*-*linux*)
9312 # Find out what ABI is being produced by ac_compile, and set linker
9313 # options accordingly.
9314 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9315 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9316 (eval $ac_compile) 2>&5
9317 ac_status=$?
9318 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9319 test $ac_status = 0; }; then
9320 emul=elf
9321 case `/usr/bin/file conftest.$ac_objext` in
9322 *32-bit*)
9323 emul="${emul}32"
9324 ;;
9325 *64-bit*)
9326 emul="${emul}64"
9327 ;;
9328 esac
9329 case `/usr/bin/file conftest.$ac_objext` in
9330 *MSB*)
9331 emul="${emul}btsmip"
9332 ;;
9333 *LSB*)
9334 emul="${emul}ltsmip"
9335 ;;
9336 esac
9337 case `/usr/bin/file conftest.$ac_objext` in
9338 *N32*)
9339 emul="${emul}n32"
9340 ;;
9341 esac
9342 LD="${LD-ld} -m $emul"
9343 fi
9344 rm -rf conftest*
9345 ;;
9346
9347 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9348 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9349 # Find out what ABI is being produced by ac_compile, and set linker
9350 # options accordingly. Note that the listed cases only cover the
9351 # situations where additional linker options are needed (such as when
9352 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9353 # vice versa); the common cases where no linker options are needed do
9354 # not appear in the list.
9355 echo 'int i;' > conftest.$ac_ext
9356 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9357 (eval $ac_compile) 2>&5
9358 ac_status=$?
9359 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9360 test $ac_status = 0; }; then
9361 case `/usr/bin/file conftest.o` in
9362 *32-bit*)
9363 case $host in
9364 x86_64-*kfreebsd*-gnu)
9365 LD="${LD-ld} -m elf_i386_fbsd"
9366 ;;
9367 x86_64-*linux*)
9368 case `/usr/bin/file conftest.o` in
9369 *x86-64*)
9370 LD="${LD-ld} -m elf32_x86_64"
9371 ;;
9372 *)
9373 LD="${LD-ld} -m elf_i386"
9374 ;;
9375 esac
9376 ;;
9377 powerpc64le-*linux*)
9378 LD="${LD-ld} -m elf32lppclinux"
9379 ;;
9380 powerpc64-*linux*)
9381 LD="${LD-ld} -m elf32ppclinux"
9382 ;;
9383 s390x-*linux*)
9384 LD="${LD-ld} -m elf_s390"
9385 ;;
9386 sparc64-*linux*)
9387 LD="${LD-ld} -m elf32_sparc"
9388 ;;
9389 esac
9390 ;;
9391 *64-bit*)
9392 case $host in
9393 x86_64-*kfreebsd*-gnu)
9394 LD="${LD-ld} -m elf_x86_64_fbsd"
9395 ;;
9396 x86_64-*linux*)
9397 LD="${LD-ld} -m elf_x86_64"
9398 ;;
9399 powerpcle-*linux*)
9400 LD="${LD-ld} -m elf64lppc"
9401 ;;
9402 powerpc-*linux*)
9403 LD="${LD-ld} -m elf64ppc"
9404 ;;
9405 s390*-*linux*|s390*-*tpf*)
9406 LD="${LD-ld} -m elf64_s390"
9407 ;;
9408 sparc*-*linux*)
9409 LD="${LD-ld} -m elf64_sparc"
9410 ;;
9411 esac
9412 ;;
9413 esac
9414 fi
9415 rm -rf conftest*
9416 ;;
9417
9418 *-*-sco3.2v5*)
9419 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9420 SAVE_CFLAGS=$CFLAGS
9421 CFLAGS="$CFLAGS -belf"
9422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9423 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9424 if ${lt_cv_cc_needs_belf+:} false; then :
9425 $as_echo_n "(cached) " >&6
9426 else
9427 ac_ext=c
9428 ac_cpp='$CPP $CPPFLAGS'
9429 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9430 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9431 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9432
9433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9434 /* end confdefs.h. */
9435
9436 int
9437 main ()
9438 {
9439
9440 ;
9441 return 0;
9442 }
9443 _ACEOF
9444 if ac_fn_c_try_link "$LINENO"; then :
9445 lt_cv_cc_needs_belf=yes
9446 else
9447 lt_cv_cc_needs_belf=no
9448 fi
9449 rm -f core conftest.err conftest.$ac_objext \
9450 conftest$ac_exeext conftest.$ac_ext
9451 ac_ext=c
9452 ac_cpp='$CPP $CPPFLAGS'
9453 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9454 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9455 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9456
9457 fi
9458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9459 $as_echo "$lt_cv_cc_needs_belf" >&6; }
9460 if test yes != "$lt_cv_cc_needs_belf"; then
9461 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9462 CFLAGS=$SAVE_CFLAGS
9463 fi
9464 ;;
9465 *-*solaris*)
9466 # Find out what ABI is being produced by ac_compile, and set linker
9467 # options accordingly.
9468 echo 'int i;' > conftest.$ac_ext
9469 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9470 (eval $ac_compile) 2>&5
9471 ac_status=$?
9472 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9473 test $ac_status = 0; }; then
9474 case `/usr/bin/file conftest.o` in
9475 *64-bit*)
9476 case $lt_cv_prog_gnu_ld in
9477 yes*)
9478 case $host in
9479 i?86-*-solaris*|x86_64-*-solaris*)
9480 LD="${LD-ld} -m elf_x86_64"
9481 ;;
9482 sparc*-*-solaris*)
9483 LD="${LD-ld} -m elf64_sparc"
9484 ;;
9485 esac
9486 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
9487 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9488 LD=${LD-ld}_sol2
9489 fi
9490 ;;
9491 *)
9492 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9493 LD="${LD-ld} -64"
9494 fi
9495 ;;
9496 esac
9497 ;;
9498 esac
9499 fi
9500 rm -rf conftest*
9501 ;;
9502 esac
9503
9504 need_locks=$enable_libtool_lock
9505
9506 if test -n "$ac_tool_prefix"; then
9507 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9508 set dummy ${ac_tool_prefix}mt; ac_word=$2
9509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9510 $as_echo_n "checking for $ac_word... " >&6; }
9511 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9512 $as_echo_n "(cached) " >&6
9513 else
9514 if test -n "$MANIFEST_TOOL"; then
9515 ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9516 else
9517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9518 for as_dir in $PATH
9519 do
9520 IFS=$as_save_IFS
9521 test -z "$as_dir" && as_dir=.
9522 for ac_exec_ext in '' $ac_executable_extensions; do
9523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9524 ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9526 break 2
9527 fi
9528 done
9529 done
9530 IFS=$as_save_IFS
9531
9532 fi
9533 fi
9534 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9535 if test -n "$MANIFEST_TOOL"; then
9536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9537 $as_echo "$MANIFEST_TOOL" >&6; }
9538 else
9539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9540 $as_echo "no" >&6; }
9541 fi
9542
9543
9544 fi
9545 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9546 ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9547 # Extract the first word of "mt", so it can be a program name with args.
9548 set dummy mt; ac_word=$2
9549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9550 $as_echo_n "checking for $ac_word... " >&6; }
9551 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9552 $as_echo_n "(cached) " >&6
9553 else
9554 if test -n "$ac_ct_MANIFEST_TOOL"; then
9555 ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9556 else
9557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9558 for as_dir in $PATH
9559 do
9560 IFS=$as_save_IFS
9561 test -z "$as_dir" && as_dir=.
9562 for ac_exec_ext in '' $ac_executable_extensions; do
9563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9564 ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9566 break 2
9567 fi
9568 done
9569 done
9570 IFS=$as_save_IFS
9571
9572 fi
9573 fi
9574 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9575 if test -n "$ac_ct_MANIFEST_TOOL"; then
9576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9577 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9578 else
9579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9580 $as_echo "no" >&6; }
9581 fi
9582
9583 if test "x$ac_ct_MANIFEST_TOOL" = x; then
9584 MANIFEST_TOOL=":"
9585 else
9586 case $cross_compiling:$ac_tool_warned in
9587 yes:)
9588 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9589 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9590 ac_tool_warned=yes ;;
9591 esac
9592 MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9593 fi
9594 else
9595 MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9596 fi
9597
9598 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9600 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9601 if ${lt_cv_path_mainfest_tool+:} false; then :
9602 $as_echo_n "(cached) " >&6
9603 else
9604 lt_cv_path_mainfest_tool=no
9605 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9606 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9607 cat conftest.err >&5
9608 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9609 lt_cv_path_mainfest_tool=yes
9610 fi
9611 rm -f conftest*
9612 fi
9613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9614 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
9615 if test yes != "$lt_cv_path_mainfest_tool"; then
9616 MANIFEST_TOOL=:
9617 fi
9618
9619
9620
9621
9622
9623
9624 case $host_os in
9625 rhapsody* | darwin*)
9626 if test -n "$ac_tool_prefix"; then
9627 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9628 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9630 $as_echo_n "checking for $ac_word... " >&6; }
9631 if ${ac_cv_prog_DSYMUTIL+:} false; then :
9632 $as_echo_n "(cached) " >&6
9633 else
9634 if test -n "$DSYMUTIL"; then
9635 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9636 else
9637 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9638 for as_dir in $PATH
9639 do
9640 IFS=$as_save_IFS
9641 test -z "$as_dir" && as_dir=.
9642 for ac_exec_ext in '' $ac_executable_extensions; do
9643 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9644 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9645 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9646 break 2
9647 fi
9648 done
9649 done
9650 IFS=$as_save_IFS
9651
9652 fi
9653 fi
9654 DSYMUTIL=$ac_cv_prog_DSYMUTIL
9655 if test -n "$DSYMUTIL"; then
9656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9657 $as_echo "$DSYMUTIL" >&6; }
9658 else
9659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9660 $as_echo "no" >&6; }
9661 fi
9662
9663
9664 fi
9665 if test -z "$ac_cv_prog_DSYMUTIL"; then
9666 ac_ct_DSYMUTIL=$DSYMUTIL
9667 # Extract the first word of "dsymutil", so it can be a program name with args.
9668 set dummy dsymutil; ac_word=$2
9669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9670 $as_echo_n "checking for $ac_word... " >&6; }
9671 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9672 $as_echo_n "(cached) " >&6
9673 else
9674 if test -n "$ac_ct_DSYMUTIL"; then
9675 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9676 else
9677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9678 for as_dir in $PATH
9679 do
9680 IFS=$as_save_IFS
9681 test -z "$as_dir" && as_dir=.
9682 for ac_exec_ext in '' $ac_executable_extensions; do
9683 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9684 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9685 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9686 break 2
9687 fi
9688 done
9689 done
9690 IFS=$as_save_IFS
9691
9692 fi
9693 fi
9694 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9695 if test -n "$ac_ct_DSYMUTIL"; then
9696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9697 $as_echo "$ac_ct_DSYMUTIL" >&6; }
9698 else
9699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9700 $as_echo "no" >&6; }
9701 fi
9702
9703 if test "x$ac_ct_DSYMUTIL" = x; then
9704 DSYMUTIL=":"
9705 else
9706 case $cross_compiling:$ac_tool_warned in
9707 yes:)
9708 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9709 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9710 ac_tool_warned=yes ;;
9711 esac
9712 DSYMUTIL=$ac_ct_DSYMUTIL
9713 fi
9714 else
9715 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9716 fi
9717
9718 if test -n "$ac_tool_prefix"; then
9719 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9720 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9722 $as_echo_n "checking for $ac_word... " >&6; }
9723 if ${ac_cv_prog_NMEDIT+:} false; then :
9724 $as_echo_n "(cached) " >&6
9725 else
9726 if test -n "$NMEDIT"; then
9727 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9728 else
9729 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9730 for as_dir in $PATH
9731 do
9732 IFS=$as_save_IFS
9733 test -z "$as_dir" && as_dir=.
9734 for ac_exec_ext in '' $ac_executable_extensions; do
9735 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9736 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9737 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9738 break 2
9739 fi
9740 done
9741 done
9742 IFS=$as_save_IFS
9743
9744 fi
9745 fi
9746 NMEDIT=$ac_cv_prog_NMEDIT
9747 if test -n "$NMEDIT"; then
9748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
9749 $as_echo "$NMEDIT" >&6; }
9750 else
9751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9752 $as_echo "no" >&6; }
9753 fi
9754
9755
9756 fi
9757 if test -z "$ac_cv_prog_NMEDIT"; then
9758 ac_ct_NMEDIT=$NMEDIT
9759 # Extract the first word of "nmedit", so it can be a program name with args.
9760 set dummy nmedit; ac_word=$2
9761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9762 $as_echo_n "checking for $ac_word... " >&6; }
9763 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
9764 $as_echo_n "(cached) " >&6
9765 else
9766 if test -n "$ac_ct_NMEDIT"; then
9767 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
9768 else
9769 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9770 for as_dir in $PATH
9771 do
9772 IFS=$as_save_IFS
9773 test -z "$as_dir" && as_dir=.
9774 for ac_exec_ext in '' $ac_executable_extensions; do
9775 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9776 ac_cv_prog_ac_ct_NMEDIT="nmedit"
9777 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9778 break 2
9779 fi
9780 done
9781 done
9782 IFS=$as_save_IFS
9783
9784 fi
9785 fi
9786 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
9787 if test -n "$ac_ct_NMEDIT"; then
9788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
9789 $as_echo "$ac_ct_NMEDIT" >&6; }
9790 else
9791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9792 $as_echo "no" >&6; }
9793 fi
9794
9795 if test "x$ac_ct_NMEDIT" = x; then
9796 NMEDIT=":"
9797 else
9798 case $cross_compiling:$ac_tool_warned in
9799 yes:)
9800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9801 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9802 ac_tool_warned=yes ;;
9803 esac
9804 NMEDIT=$ac_ct_NMEDIT
9805 fi
9806 else
9807 NMEDIT="$ac_cv_prog_NMEDIT"
9808 fi
9809
9810 if test -n "$ac_tool_prefix"; then
9811 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
9812 set dummy ${ac_tool_prefix}lipo; ac_word=$2
9813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9814 $as_echo_n "checking for $ac_word... " >&6; }
9815 if ${ac_cv_prog_LIPO+:} false; then :
9816 $as_echo_n "(cached) " >&6
9817 else
9818 if test -n "$LIPO"; then
9819 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
9820 else
9821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9822 for as_dir in $PATH
9823 do
9824 IFS=$as_save_IFS
9825 test -z "$as_dir" && as_dir=.
9826 for ac_exec_ext in '' $ac_executable_extensions; do
9827 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9828 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
9829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9830 break 2
9831 fi
9832 done
9833 done
9834 IFS=$as_save_IFS
9835
9836 fi
9837 fi
9838 LIPO=$ac_cv_prog_LIPO
9839 if test -n "$LIPO"; then
9840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
9841 $as_echo "$LIPO" >&6; }
9842 else
9843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9844 $as_echo "no" >&6; }
9845 fi
9846
9847
9848 fi
9849 if test -z "$ac_cv_prog_LIPO"; then
9850 ac_ct_LIPO=$LIPO
9851 # Extract the first word of "lipo", so it can be a program name with args.
9852 set dummy lipo; ac_word=$2
9853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9854 $as_echo_n "checking for $ac_word... " >&6; }
9855 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
9856 $as_echo_n "(cached) " >&6
9857 else
9858 if test -n "$ac_ct_LIPO"; then
9859 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
9860 else
9861 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9862 for as_dir in $PATH
9863 do
9864 IFS=$as_save_IFS
9865 test -z "$as_dir" && as_dir=.
9866 for ac_exec_ext in '' $ac_executable_extensions; do
9867 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9868 ac_cv_prog_ac_ct_LIPO="lipo"
9869 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9870 break 2
9871 fi
9872 done
9873 done
9874 IFS=$as_save_IFS
9875
9876 fi
9877 fi
9878 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
9879 if test -n "$ac_ct_LIPO"; then
9880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
9881 $as_echo "$ac_ct_LIPO" >&6; }
9882 else
9883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9884 $as_echo "no" >&6; }
9885 fi
9886
9887 if test "x$ac_ct_LIPO" = x; then
9888 LIPO=":"
9889 else
9890 case $cross_compiling:$ac_tool_warned in
9891 yes:)
9892 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9893 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9894 ac_tool_warned=yes ;;
9895 esac
9896 LIPO=$ac_ct_LIPO
9897 fi
9898 else
9899 LIPO="$ac_cv_prog_LIPO"
9900 fi
9901
9902 if test -n "$ac_tool_prefix"; then
9903 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
9904 set dummy ${ac_tool_prefix}otool; ac_word=$2
9905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9906 $as_echo_n "checking for $ac_word... " >&6; }
9907 if ${ac_cv_prog_OTOOL+:} false; then :
9908 $as_echo_n "(cached) " >&6
9909 else
9910 if test -n "$OTOOL"; then
9911 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
9912 else
9913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9914 for as_dir in $PATH
9915 do
9916 IFS=$as_save_IFS
9917 test -z "$as_dir" && as_dir=.
9918 for ac_exec_ext in '' $ac_executable_extensions; do
9919 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9920 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
9921 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9922 break 2
9923 fi
9924 done
9925 done
9926 IFS=$as_save_IFS
9927
9928 fi
9929 fi
9930 OTOOL=$ac_cv_prog_OTOOL
9931 if test -n "$OTOOL"; then
9932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
9933 $as_echo "$OTOOL" >&6; }
9934 else
9935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9936 $as_echo "no" >&6; }
9937 fi
9938
9939
9940 fi
9941 if test -z "$ac_cv_prog_OTOOL"; then
9942 ac_ct_OTOOL=$OTOOL
9943 # Extract the first word of "otool", so it can be a program name with args.
9944 set dummy otool; ac_word=$2
9945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9946 $as_echo_n "checking for $ac_word... " >&6; }
9947 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
9948 $as_echo_n "(cached) " >&6
9949 else
9950 if test -n "$ac_ct_OTOOL"; then
9951 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
9952 else
9953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9954 for as_dir in $PATH
9955 do
9956 IFS=$as_save_IFS
9957 test -z "$as_dir" && as_dir=.
9958 for ac_exec_ext in '' $ac_executable_extensions; do
9959 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9960 ac_cv_prog_ac_ct_OTOOL="otool"
9961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9962 break 2
9963 fi
9964 done
9965 done
9966 IFS=$as_save_IFS
9967
9968 fi
9969 fi
9970 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
9971 if test -n "$ac_ct_OTOOL"; then
9972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
9973 $as_echo "$ac_ct_OTOOL" >&6; }
9974 else
9975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9976 $as_echo "no" >&6; }
9977 fi
9978
9979 if test "x$ac_ct_OTOOL" = x; then
9980 OTOOL=":"
9981 else
9982 case $cross_compiling:$ac_tool_warned in
9983 yes:)
9984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9985 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9986 ac_tool_warned=yes ;;
9987 esac
9988 OTOOL=$ac_ct_OTOOL
9989 fi
9990 else
9991 OTOOL="$ac_cv_prog_OTOOL"
9992 fi
9993
9994 if test -n "$ac_tool_prefix"; then
9995 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
9996 set dummy ${ac_tool_prefix}otool64; ac_word=$2
9997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9998 $as_echo_n "checking for $ac_word... " >&6; }
9999 if ${ac_cv_prog_OTOOL64+:} false; then :
10000 $as_echo_n "(cached) " >&6
10001 else
10002 if test -n "$OTOOL64"; then
10003 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10004 else
10005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10006 for as_dir in $PATH
10007 do
10008 IFS=$as_save_IFS
10009 test -z "$as_dir" && as_dir=.
10010 for ac_exec_ext in '' $ac_executable_extensions; do
10011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10012 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10014 break 2
10015 fi
10016 done
10017 done
10018 IFS=$as_save_IFS
10019
10020 fi
10021 fi
10022 OTOOL64=$ac_cv_prog_OTOOL64
10023 if test -n "$OTOOL64"; then
10024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10025 $as_echo "$OTOOL64" >&6; }
10026 else
10027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10028 $as_echo "no" >&6; }
10029 fi
10030
10031
10032 fi
10033 if test -z "$ac_cv_prog_OTOOL64"; then
10034 ac_ct_OTOOL64=$OTOOL64
10035 # Extract the first word of "otool64", so it can be a program name with args.
10036 set dummy otool64; ac_word=$2
10037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10038 $as_echo_n "checking for $ac_word... " >&6; }
10039 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10040 $as_echo_n "(cached) " >&6
10041 else
10042 if test -n "$ac_ct_OTOOL64"; then
10043 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10044 else
10045 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10046 for as_dir in $PATH
10047 do
10048 IFS=$as_save_IFS
10049 test -z "$as_dir" && as_dir=.
10050 for ac_exec_ext in '' $ac_executable_extensions; do
10051 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10052 ac_cv_prog_ac_ct_OTOOL64="otool64"
10053 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10054 break 2
10055 fi
10056 done
10057 done
10058 IFS=$as_save_IFS
10059
10060 fi
10061 fi
10062 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10063 if test -n "$ac_ct_OTOOL64"; then
10064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10065 $as_echo "$ac_ct_OTOOL64" >&6; }
10066 else
10067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10068 $as_echo "no" >&6; }
10069 fi
10070
10071 if test "x$ac_ct_OTOOL64" = x; then
10072 OTOOL64=":"
10073 else
10074 case $cross_compiling:$ac_tool_warned in
10075 yes:)
10076 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10077 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10078 ac_tool_warned=yes ;;
10079 esac
10080 OTOOL64=$ac_ct_OTOOL64
10081 fi
10082 else
10083 OTOOL64="$ac_cv_prog_OTOOL64"
10084 fi
10085
10086
10087
10088
10089
10090
10091
10092
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
10111
10112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10113 $as_echo_n "checking for -single_module linker flag... " >&6; }
10114 if ${lt_cv_apple_cc_single_mod+:} false; then :
10115 $as_echo_n "(cached) " >&6
10116 else
10117 lt_cv_apple_cc_single_mod=no
10118 if test -z "$LT_MULTI_MODULE"; then
10119 # By default we will add the -single_module flag. You can override
10120 # by either setting the environment variable LT_MULTI_MODULE
10121 # non-empty at configure time, or by adding -multi_module to the
10122 # link flags.
10123 rm -rf libconftest.dylib*
10124 echo "int foo(void){return 1;}" > conftest.c
10125 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10126 -dynamiclib -Wl,-single_module conftest.c" >&5
10127 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10128 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10129 _lt_result=$?
10130 # If there is a non-empty error log, and "single_module"
10131 # appears in it, assume the flag caused a linker warning
10132 if test -s conftest.err && $GREP single_module conftest.err; then
10133 cat conftest.err >&5
10134 # Otherwise, if the output was created with a 0 exit code from
10135 # the compiler, it worked.
10136 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10137 lt_cv_apple_cc_single_mod=yes
10138 else
10139 cat conftest.err >&5
10140 fi
10141 rm -rf libconftest.dylib*
10142 rm -f conftest.*
10143 fi
10144 fi
10145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10146 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10147
10148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10149 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10150 if ${lt_cv_ld_exported_symbols_list+:} false; then :
10151 $as_echo_n "(cached) " >&6
10152 else
10153 lt_cv_ld_exported_symbols_list=no
10154 save_LDFLAGS=$LDFLAGS
10155 echo "_main" > conftest.sym
10156 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10158 /* end confdefs.h. */
10159
10160 int
10161 main ()
10162 {
10163
10164 ;
10165 return 0;
10166 }
10167 _ACEOF
10168 if ac_fn_c_try_link "$LINENO"; then :
10169 lt_cv_ld_exported_symbols_list=yes
10170 else
10171 lt_cv_ld_exported_symbols_list=no
10172 fi
10173 rm -f core conftest.err conftest.$ac_objext \
10174 conftest$ac_exeext conftest.$ac_ext
10175 LDFLAGS=$save_LDFLAGS
10176
10177 fi
10178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10179 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10180
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10182 $as_echo_n "checking for -force_load linker flag... " >&6; }
10183 if ${lt_cv_ld_force_load+:} false; then :
10184 $as_echo_n "(cached) " >&6
10185 else
10186 lt_cv_ld_force_load=no
10187 cat > conftest.c << _LT_EOF
10188 int forced_loaded() { return 2;}
10189 _LT_EOF
10190 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10191 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10192 echo "$AR cru libconftest.a conftest.o" >&5
10193 $AR cru libconftest.a conftest.o 2>&5
10194 echo "$RANLIB libconftest.a" >&5
10195 $RANLIB libconftest.a 2>&5
10196 cat > conftest.c << _LT_EOF
10197 int main() { return 0;}
10198 _LT_EOF
10199 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10200 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10201 _lt_result=$?
10202 if test -s conftest.err && $GREP force_load conftest.err; then
10203 cat conftest.err >&5
10204 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10205 lt_cv_ld_force_load=yes
10206 else
10207 cat conftest.err >&5
10208 fi
10209 rm -f conftest.err libconftest.a conftest conftest.c
10210 rm -rf conftest.dSYM
10211
10212 fi
10213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10214 $as_echo "$lt_cv_ld_force_load" >&6; }
10215 case $host_os in
10216 rhapsody* | darwin1.[012])
10217 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10218 darwin1.*)
10219 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10220 darwin*) # darwin 5.x on
10221 # if running on 10.5 or later, the deployment target defaults
10222 # to the OS version, if on x86, and 10.4, the deployment
10223 # target defaults to 10.4. Don't you love it?
10224 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10225 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10226 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10227 10.[012][,.]*)
10228 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10229 10.*)
10230 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10231 esac
10232 ;;
10233 esac
10234 if test yes = "$lt_cv_apple_cc_single_mod"; then
10235 _lt_dar_single_mod='$single_module'
10236 fi
10237 if test yes = "$lt_cv_ld_exported_symbols_list"; then
10238 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10239 else
10240 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10241 fi
10242 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10243 _lt_dsymutil='~$DSYMUTIL $lib || :'
10244 else
10245 _lt_dsymutil=
10246 fi
10247 ;;
10248 esac
10249
10250 # func_munge_path_list VARIABLE PATH
10251 # -----------------------------------
10252 # VARIABLE is name of variable containing _space_ separated list of
10253 # directories to be munged by the contents of PATH, which is string
10254 # having a format:
10255 # "DIR[:DIR]:"
10256 # string "DIR[ DIR]" will be prepended to VARIABLE
10257 # ":DIR[:DIR]"
10258 # string "DIR[ DIR]" will be appended to VARIABLE
10259 # "DIRP[:DIRP]::[DIRA:]DIRA"
10260 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10261 # "DIRA[ DIRA]" will be appended to VARIABLE
10262 # "DIR[:DIR]"
10263 # VARIABLE will be replaced by "DIR[ DIR]"
10264 func_munge_path_list ()
10265 {
10266 case x$2 in
10267 x)
10268 ;;
10269 *:)
10270 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10271 ;;
10272 x:*)
10273 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10274 ;;
10275 *::*)
10276 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10277 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10278 ;;
10279 *)
10280 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10281 ;;
10282 esac
10283 }
10284
10285 for ac_header in dlfcn.h
10286 do :
10287 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10288 "
10289 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10290 cat >>confdefs.h <<_ACEOF
10291 #define HAVE_DLFCN_H 1
10292 _ACEOF
10293
10294 fi
10295
10296 done
10297
10298
10299
10300
10301
10302
10303
10304 # Set options
10305
10306
10307
10308 enable_dlopen=no
10309
10310
10311 enable_win32_dll=no
10312
10313
10314 # Check whether --enable-shared was given.
10315 if test "${enable_shared+set}" = set; then :
10316 enableval=$enable_shared; p=${PACKAGE-default}
10317 case $enableval in
10318 yes) enable_shared=yes ;;
10319 no) enable_shared=no ;;
10320 *)
10321 enable_shared=no
10322 # Look at the argument we got. We use all the common list separators.
10323 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10324 for pkg in $enableval; do
10325 IFS=$lt_save_ifs
10326 if test "X$pkg" = "X$p"; then
10327 enable_shared=yes
10328 fi
10329 done
10330 IFS=$lt_save_ifs
10331 ;;
10332 esac
10333 else
10334 enable_shared=yes
10335 fi
10336
10337
10338
10339
10340
10341
10342
10343
10344
10345 # Check whether --enable-static was given.
10346 if test "${enable_static+set}" = set; then :
10347 enableval=$enable_static; p=${PACKAGE-default}
10348 case $enableval in
10349 yes) enable_static=yes ;;
10350 no) enable_static=no ;;
10351 *)
10352 enable_static=no
10353 # Look at the argument we got. We use all the common list separators.
10354 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10355 for pkg in $enableval; do
10356 IFS=$lt_save_ifs
10357 if test "X$pkg" = "X$p"; then
10358 enable_static=yes
10359 fi
10360 done
10361 IFS=$lt_save_ifs
10362 ;;
10363 esac
10364 else
10365 enable_static=yes
10366 fi
10367
10368
10369
10370
10371
10372
10373
10374
10375
10376
10377 # Check whether --with-pic was given.
10378 if test "${with_pic+set}" = set; then :
10379 withval=$with_pic; lt_p=${PACKAGE-default}
10380 case $withval in
10381 yes|no) pic_mode=$withval ;;
10382 *)
10383 pic_mode=default
10384 # Look at the argument we got. We use all the common list separators.
10385 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10386 for lt_pkg in $withval; do
10387 IFS=$lt_save_ifs
10388 if test "X$lt_pkg" = "X$lt_p"; then
10389 pic_mode=yes
10390 fi
10391 done
10392 IFS=$lt_save_ifs
10393 ;;
10394 esac
10395 else
10396 pic_mode=default
10397 fi
10398
10399
10400
10401
10402
10403
10404
10405
10406 # Check whether --enable-fast-install was given.
10407 if test "${enable_fast_install+set}" = set; then :
10408 enableval=$enable_fast_install; p=${PACKAGE-default}
10409 case $enableval in
10410 yes) enable_fast_install=yes ;;
10411 no) enable_fast_install=no ;;
10412 *)
10413 enable_fast_install=no
10414 # Look at the argument we got. We use all the common list separators.
10415 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
10416 for pkg in $enableval; do
10417 IFS=$lt_save_ifs
10418 if test "X$pkg" = "X$p"; then
10419 enable_fast_install=yes
10420 fi
10421 done
10422 IFS=$lt_save_ifs
10423 ;;
10424 esac
10425 else
10426 enable_fast_install=yes
10427 fi
10428
10429
10430
10431
10432
10433
10434
10435
10436 shared_archive_member_spec=
10437 case $host,$enable_shared in
10438 power*-*-aix[5-9]*,yes)
10439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
10440 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
10441
10442 # Check whether --with-aix-soname was given.
10443 if test "${with_aix_soname+set}" = set; then :
10444 withval=$with_aix_soname; case $withval in
10445 aix|svr4|both)
10446 ;;
10447 *)
10448 as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
10449 ;;
10450 esac
10451 lt_cv_with_aix_soname=$with_aix_soname
10452 else
10453 if ${lt_cv_with_aix_soname+:} false; then :
10454 $as_echo_n "(cached) " >&6
10455 else
10456 lt_cv_with_aix_soname=aix
10457 fi
10458
10459 with_aix_soname=$lt_cv_with_aix_soname
10460 fi
10461
10462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
10463 $as_echo "$with_aix_soname" >&6; }
10464 if test aix != "$with_aix_soname"; then
10465 # For the AIX way of multilib, we name the shared archive member
10466 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
10467 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
10468 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
10469 # the AIX toolchain works better with OBJECT_MODE set (default 32).
10470 if test 64 = "${OBJECT_MODE-32}"; then
10471 shared_archive_member_spec=shr_64
10472 else
10473 shared_archive_member_spec=shr
10474 fi
10475 fi
10476 ;;
10477 *)
10478 with_aix_soname=aix
10479 ;;
10480 esac
10481
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491 # This can be used to rebuild libtool when needed
10492 LIBTOOL_DEPS=$ltmain
10493
10494 # Always use our own libtool.
10495 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
10496
10497
10498
10499
10500
10501
10502
10503
10504
10505
10506
10507
10508
10509
10510
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521
10522
10523
10524
10525
10526 test -z "$LN_S" && LN_S="ln -s"
10527
10528
10529
10530
10531
10532
10533
10534
10535
10536
10537
10538
10539
10540
10541 if test -n "${ZSH_VERSION+set}"; then
10542 setopt NO_GLOB_SUBST
10543 fi
10544
10545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
10546 $as_echo_n "checking for objdir... " >&6; }
10547 if ${lt_cv_objdir+:} false; then :
10548 $as_echo_n "(cached) " >&6
10549 else
10550 rm -f .libs 2>/dev/null
10551 mkdir .libs 2>/dev/null
10552 if test -d .libs; then
10553 lt_cv_objdir=.libs
10554 else
10555 # MS-DOS does not allow filenames that begin with a dot.
10556 lt_cv_objdir=_libs
10557 fi
10558 rmdir .libs 2>/dev/null
10559 fi
10560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
10561 $as_echo "$lt_cv_objdir" >&6; }
10562 objdir=$lt_cv_objdir
10563
10564
10565
10566
10567
10568 cat >>confdefs.h <<_ACEOF
10569 #define LT_OBJDIR "$lt_cv_objdir/"
10570 _ACEOF
10571
10572
10573
10574
10575 case $host_os in
10576 aix3*)
10577 # AIX sometimes has problems with the GCC collect2 program. For some
10578 # reason, if we set the COLLECT_NAMES environment variable, the problems
10579 # vanish in a puff of smoke.
10580 if test set != "${COLLECT_NAMES+set}"; then
10581 COLLECT_NAMES=
10582 export COLLECT_NAMES
10583 fi
10584 ;;
10585 esac
10586
10587 # Global variables:
10588 ofile=libtool
10589 can_build_shared=yes
10590
10591 # All known linkers require a '.a' archive for static linking (except MSVC,
10592 # which needs '.lib').
10593 libext=a
10594
10595 with_gnu_ld=$lt_cv_prog_gnu_ld
10596
10597 old_CC=$CC
10598 old_CFLAGS=$CFLAGS
10599
10600 # Set sane defaults for various variables
10601 test -z "$CC" && CC=cc
10602 test -z "$LTCC" && LTCC=$CC
10603 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
10604 test -z "$LD" && LD=ld
10605 test -z "$ac_objext" && ac_objext=o
10606
10607 func_cc_basename $compiler
10608 cc_basename=$func_cc_basename_result
10609
10610
10611 # Only perform the check for file, if the check method requires it
10612 test -z "$MAGIC_CMD" && MAGIC_CMD=file
10613 case $deplibs_check_method in
10614 file_magic*)
10615 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
10616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
10617 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
10618 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10619 $as_echo_n "(cached) " >&6
10620 else
10621 case $MAGIC_CMD in
10622 [\\/*] | ?:[\\/]*)
10623 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10624 ;;
10625 *)
10626 lt_save_MAGIC_CMD=$MAGIC_CMD
10627 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10628 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10629 for ac_dir in $ac_dummy; do
10630 IFS=$lt_save_ifs
10631 test -z "$ac_dir" && ac_dir=.
10632 if test -f "$ac_dir/${ac_tool_prefix}file"; then
10633 lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
10634 if test -n "$file_magic_test_file"; then
10635 case $deplibs_check_method in
10636 "file_magic "*)
10637 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10638 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10639 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10640 $EGREP "$file_magic_regex" > /dev/null; then
10641 :
10642 else
10643 cat <<_LT_EOF 1>&2
10644
10645 *** Warning: the command libtool uses to detect shared libraries,
10646 *** $file_magic_cmd, produces output that libtool cannot recognize.
10647 *** The result is that libtool may fail to recognize shared libraries
10648 *** as such. This will affect the creation of libtool libraries that
10649 *** depend on shared libraries, but programs linked with such libtool
10650 *** libraries will work regardless of this problem. Nevertheless, you
10651 *** may want to report the problem to your system manager and/or to
10652 *** bug-libtool (at] gnu.org
10653
10654 _LT_EOF
10655 fi ;;
10656 esac
10657 fi
10658 break
10659 fi
10660 done
10661 IFS=$lt_save_ifs
10662 MAGIC_CMD=$lt_save_MAGIC_CMD
10663 ;;
10664 esac
10665 fi
10666
10667 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10668 if test -n "$MAGIC_CMD"; then
10669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10670 $as_echo "$MAGIC_CMD" >&6; }
10671 else
10672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10673 $as_echo "no" >&6; }
10674 fi
10675
10676
10677
10678
10679
10680 if test -z "$lt_cv_path_MAGIC_CMD"; then
10681 if test -n "$ac_tool_prefix"; then
10682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
10683 $as_echo_n "checking for file... " >&6; }
10684 if ${lt_cv_path_MAGIC_CMD+:} false; then :
10685 $as_echo_n "(cached) " >&6
10686 else
10687 case $MAGIC_CMD in
10688 [\\/*] | ?:[\\/]*)
10689 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
10690 ;;
10691 *)
10692 lt_save_MAGIC_CMD=$MAGIC_CMD
10693 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
10694 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
10695 for ac_dir in $ac_dummy; do
10696 IFS=$lt_save_ifs
10697 test -z "$ac_dir" && ac_dir=.
10698 if test -f "$ac_dir/file"; then
10699 lt_cv_path_MAGIC_CMD=$ac_dir/"file"
10700 if test -n "$file_magic_test_file"; then
10701 case $deplibs_check_method in
10702 "file_magic "*)
10703 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
10704 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10705 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
10706 $EGREP "$file_magic_regex" > /dev/null; then
10707 :
10708 else
10709 cat <<_LT_EOF 1>&2
10710
10711 *** Warning: the command libtool uses to detect shared libraries,
10712 *** $file_magic_cmd, produces output that libtool cannot recognize.
10713 *** The result is that libtool may fail to recognize shared libraries
10714 *** as such. This will affect the creation of libtool libraries that
10715 *** depend on shared libraries, but programs linked with such libtool
10716 *** libraries will work regardless of this problem. Nevertheless, you
10717 *** may want to report the problem to your system manager and/or to
10718 *** bug-libtool (at] gnu.org
10719
10720 _LT_EOF
10721 fi ;;
10722 esac
10723 fi
10724 break
10725 fi
10726 done
10727 IFS=$lt_save_ifs
10728 MAGIC_CMD=$lt_save_MAGIC_CMD
10729 ;;
10730 esac
10731 fi
10732
10733 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
10734 if test -n "$MAGIC_CMD"; then
10735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
10736 $as_echo "$MAGIC_CMD" >&6; }
10737 else
10738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10739 $as_echo "no" >&6; }
10740 fi
10741
10742
10743 else
10744 MAGIC_CMD=:
10745 fi
10746 fi
10747
10748 fi
10749 ;;
10750 esac
10751
10752 # Use C for the default configuration in the libtool script
10753
10754 lt_save_CC=$CC
10755 ac_ext=c
10756 ac_cpp='$CPP $CPPFLAGS'
10757 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10758 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10759 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10760
10761
10762 # Source file extension for C test sources.
10763 ac_ext=c
10764
10765 # Object file extension for compiled C test sources.
10766 objext=o
10767 objext=$objext
10768
10769 # Code to be used in simple compile tests
10770 lt_simple_compile_test_code="int some_variable = 0;"
10771
10772 # Code to be used in simple link tests
10773 lt_simple_link_test_code='int main(){return(0);}'
10774
10775
10776
10777
10778
10779
10780
10781 # If no C compiler was specified, use CC.
10782 LTCC=${LTCC-"$CC"}
10783
10784 # If no C compiler flags were specified, use CFLAGS.
10785 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
10786
10787 # Allow CC to be a program name with arguments.
10788 compiler=$CC
10789
10790 # Save the default compiler, since it gets overwritten when the other
10791 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
10792 compiler_DEFAULT=$CC
10793
10794 # save warnings/boilerplate of simple test code
10795 ac_outfile=conftest.$ac_objext
10796 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
10797 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10798 _lt_compiler_boilerplate=`cat conftest.err`
10799 $RM conftest*
10800
10801 ac_outfile=conftest.$ac_objext
10802 echo "$lt_simple_link_test_code" >conftest.$ac_ext
10803 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
10804 _lt_linker_boilerplate=`cat conftest.err`
10805 $RM -r conftest*
10806
10807
10808 if test -n "$compiler"; then
10809
10810 lt_prog_compiler_no_builtin_flag=
10811
10812 if test yes = "$GCC"; then
10813 case $cc_basename in
10814 nvcc*)
10815 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
10816 *)
10817 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
10818 esac
10819
10820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
10821 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
10822 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
10823 $as_echo_n "(cached) " >&6
10824 else
10825 lt_cv_prog_compiler_rtti_exceptions=no
10826 ac_outfile=conftest.$ac_objext
10827 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10828 lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment
10829 # Insert the option either (1) after the last *FLAGS variable, or
10830 # (2) before a word containing "conftest.", or (3) at the end.
10831 # Note that $ac_compile itself does not contain backslashes and begins
10832 # with a dollar sign (not a hyphen), so the echo should work correctly.
10833 # The option is referenced via a variable to avoid confusing sed.
10834 lt_compile=`echo "$ac_compile" | $SED \
10835 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
10836 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
10837 -e 's:$: $lt_compiler_flag:'`
10838 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
10839 (eval "$lt_compile" 2>conftest.err)
10840 ac_status=$?
10841 cat conftest.err >&5
10842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10843 if (exit $ac_status) && test -s "$ac_outfile"; then
10844 # The compiler can only warn and ignore the option if not recognized
10845 # So say no if there are warnings other than the usual output.
10846 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
10847 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
10848 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
10849 lt_cv_prog_compiler_rtti_exceptions=yes
10850 fi
10851 fi
10852 $RM conftest*
10853
10854 fi
10855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
10856 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
10857
10858 if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
10859 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
10860 else
10861 :
10862 fi
10863
10864 fi
10865
10866
10867
10868
10869
10870
10871 lt_prog_compiler_wl=
10872 lt_prog_compiler_pic=
10873 lt_prog_compiler_static=
10874
10875
10876 if test yes = "$GCC"; then
10877 lt_prog_compiler_wl='-Wl,'
10878 lt_prog_compiler_static='-static'
10879
10880 case $host_os in
10881 aix*)
10882 # All AIX code is PIC.
10883 if test ia64 = "$host_cpu"; then
10884 # AIX 5 now supports IA64 processor
10885 lt_prog_compiler_static='-Bstatic'
10886 fi
10887 lt_prog_compiler_pic='-fPIC'
10888 ;;
10889
10890 amigaos*)
10891 case $host_cpu in
10892 powerpc)
10893 # see comment about AmigaOS4 .so support
10894 lt_prog_compiler_pic='-fPIC'
10895 ;;
10896 m68k)
10897 # FIXME: we need at least 68020 code to build shared libraries, but
10898 # adding the '-m68020' flag to GCC prevents building anything better,
10899 # like '-m68040'.
10900 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
10901 ;;
10902 esac
10903 ;;
10904
10905 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
10906 # PIC is the default for these OSes.
10907 ;;
10908
10909 mingw* | cygwin* | pw32* | os2* | cegcc*)
10910 # This hack is so that the source file can tell whether it is being
10911 # built for inclusion in a dll (and should export symbols for example).
10912 # Although the cygwin gcc ignores -fPIC, still need this for old-style
10913 # (--disable-auto-import) libraries
10914 lt_prog_compiler_pic='-DDLL_EXPORT'
10915 case $host_os in
10916 os2*)
10917 lt_prog_compiler_static='$wl-static'
10918 ;;
10919 esac
10920 ;;
10921
10922 darwin* | rhapsody*)
10923 # PIC is the default on this platform
10924 # Common symbols not allowed in MH_DYLIB files
10925 lt_prog_compiler_pic='-fno-common'
10926 ;;
10927
10928 haiku*)
10929 # PIC is the default for Haiku.
10930 # The "-static" flag exists, but is broken.
10931 lt_prog_compiler_static=
10932 ;;
10933
10934 hpux*)
10935 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
10936 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
10937 # sets the default TLS model and affects inlining.
10938 case $host_cpu in
10939 hppa*64*)
10940 # +Z the default
10941 ;;
10942 *)
10943 lt_prog_compiler_pic='-fPIC'
10944 ;;
10945 esac
10946 ;;
10947
10948 interix[3-9]*)
10949 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
10950 # Instead, we relocate shared libraries at runtime.
10951 ;;
10952
10953 msdosdjgpp*)
10954 # Just because we use GCC doesn't mean we suddenly get shared libraries
10955 # on systems that don't support them.
10956 lt_prog_compiler_can_build_shared=no
10957 enable_shared=no
10958 ;;
10959
10960 *nto* | *qnx*)
10961 # QNX uses GNU C++, but need to define -shared option too, otherwise
10962 # it will coredump.
10963 lt_prog_compiler_pic='-fPIC -shared'
10964 ;;
10965
10966 sysv4*MP*)
10967 if test -d /usr/nec; then
10968 lt_prog_compiler_pic=-Kconform_pic
10969 fi
10970 ;;
10971
10972 *)
10973 lt_prog_compiler_pic='-fPIC'
10974 ;;
10975 esac
10976
10977 case $cc_basename in
10978 nvcc*) # Cuda Compiler Driver 2.2
10979 lt_prog_compiler_wl='-Xlinker '
10980 if test -n "$lt_prog_compiler_pic"; then
10981 lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
10982 fi
10983 ;;
10984 esac
10985 else
10986 # PORTME Check for flag to pass linker flags through the system compiler.
10987 case $host_os in
10988 aix*)
10989 lt_prog_compiler_wl='-Wl,'
10990 if test ia64 = "$host_cpu"; then
10991 # AIX 5 now supports IA64 processor
10992 lt_prog_compiler_static='-Bstatic'
10993 else
10994 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
10995 fi
10996 ;;
10997
10998 darwin* | rhapsody*)
10999 # PIC is the default on this platform
11000 # Common symbols not allowed in MH_DYLIB files
11001 lt_prog_compiler_pic='-fno-common'
11002 case $cc_basename in
11003 nagfor*)
11004 # NAG Fortran compiler
11005 lt_prog_compiler_wl='-Wl,-Wl,,'
11006 lt_prog_compiler_pic='-PIC'
11007 lt_prog_compiler_static='-Bstatic'
11008 ;;
11009 esac
11010 ;;
11011
11012 mingw* | cygwin* | pw32* | os2* | cegcc*)
11013 # This hack is so that the source file can tell whether it is being
11014 # built for inclusion in a dll (and should export symbols for example).
11015 lt_prog_compiler_pic='-DDLL_EXPORT'
11016 case $host_os in
11017 os2*)
11018 lt_prog_compiler_static='$wl-static'
11019 ;;
11020 esac
11021 ;;
11022
11023 hpux9* | hpux10* | hpux11*)
11024 lt_prog_compiler_wl='-Wl,'
11025 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11026 # not for PA HP-UX.
11027 case $host_cpu in
11028 hppa*64*|ia64*)
11029 # +Z the default
11030 ;;
11031 *)
11032 lt_prog_compiler_pic='+Z'
11033 ;;
11034 esac
11035 # Is there a better lt_prog_compiler_static that works with the bundled CC?
11036 lt_prog_compiler_static='$wl-a ${wl}archive'
11037 ;;
11038
11039 irix5* | irix6* | nonstopux*)
11040 lt_prog_compiler_wl='-Wl,'
11041 # PIC (with -KPIC) is the default.
11042 lt_prog_compiler_static='-non_shared'
11043 ;;
11044
11045 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11046 case $cc_basename in
11047 # old Intel for x86_64, which still supported -KPIC.
11048 ecc*)
11049 lt_prog_compiler_wl='-Wl,'
11050 lt_prog_compiler_pic='-KPIC'
11051 lt_prog_compiler_static='-static'
11052 ;;
11053 # icc used to be incompatible with GCC.
11054 # ICC 10 doesn't accept -KPIC any more.
11055 icc* | ifort*)
11056 lt_prog_compiler_wl='-Wl,'
11057 lt_prog_compiler_pic='-fPIC'
11058 lt_prog_compiler_static='-static'
11059 ;;
11060 # Lahey Fortran 8.1.
11061 lf95*)
11062 lt_prog_compiler_wl='-Wl,'
11063 lt_prog_compiler_pic='--shared'
11064 lt_prog_compiler_static='--static'
11065 ;;
11066 nagfor*)
11067 # NAG Fortran compiler
11068 lt_prog_compiler_wl='-Wl,-Wl,,'
11069 lt_prog_compiler_pic='-PIC'
11070 lt_prog_compiler_static='-Bstatic'
11071 ;;
11072 tcc*)
11073 # Fabrice Bellard et al's Tiny C Compiler
11074 lt_prog_compiler_wl='-Wl,'
11075 lt_prog_compiler_pic='-fPIC'
11076 lt_prog_compiler_static='-static'
11077 ;;
11078 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11079 # Portland Group compilers (*not* the Pentium gcc compiler,
11080 # which looks to be a dead project)
11081 lt_prog_compiler_wl='-Wl,'
11082 lt_prog_compiler_pic='-fpic'
11083 lt_prog_compiler_static='-Bstatic'
11084 ;;
11085 ccc*)
11086 lt_prog_compiler_wl='-Wl,'
11087 # All Alpha code is PIC.
11088 lt_prog_compiler_static='-non_shared'
11089 ;;
11090 xl* | bgxl* | bgf* | mpixl*)
11091 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11092 lt_prog_compiler_wl='-Wl,'
11093 lt_prog_compiler_pic='-qpic'
11094 lt_prog_compiler_static='-qstaticlink'
11095 ;;
11096 *)
11097 case `$CC -V 2>&1 | sed 5q` in
11098 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11099 # Sun Fortran 8.3 passes all unrecognized flags to the linker
11100 lt_prog_compiler_pic='-KPIC'
11101 lt_prog_compiler_static='-Bstatic'
11102 lt_prog_compiler_wl=''
11103 ;;
11104 *Sun\ F* | *Sun*Fortran*)
11105 lt_prog_compiler_pic='-KPIC'
11106 lt_prog_compiler_static='-Bstatic'
11107 lt_prog_compiler_wl='-Qoption ld '
11108 ;;
11109 *Sun\ C*)
11110 # Sun C 5.9
11111 lt_prog_compiler_pic='-KPIC'
11112 lt_prog_compiler_static='-Bstatic'
11113 lt_prog_compiler_wl='-Wl,'
11114 ;;
11115 *Intel*\ [CF]*Compiler*)
11116 lt_prog_compiler_wl='-Wl,'
11117 lt_prog_compiler_pic='-fPIC'
11118 lt_prog_compiler_static='-static'
11119 ;;
11120 *Portland\ Group*)
11121 lt_prog_compiler_wl='-Wl,'
11122 lt_prog_compiler_pic='-fpic'
11123 lt_prog_compiler_static='-Bstatic'
11124 ;;
11125 esac
11126 ;;
11127 esac
11128 ;;
11129
11130 newsos6)
11131 lt_prog_compiler_pic='-KPIC'
11132 lt_prog_compiler_static='-Bstatic'
11133 ;;
11134
11135 *nto* | *qnx*)
11136 # QNX uses GNU C++, but need to define -shared option too, otherwise
11137 # it will coredump.
11138 lt_prog_compiler_pic='-fPIC -shared'
11139 ;;
11140
11141 osf3* | osf4* | osf5*)
11142 lt_prog_compiler_wl='-Wl,'
11143 # All OSF/1 code is PIC.
11144 lt_prog_compiler_static='-non_shared'
11145 ;;
11146
11147 rdos*)
11148 lt_prog_compiler_static='-non_shared'
11149 ;;
11150
11151 solaris*)
11152 lt_prog_compiler_pic='-KPIC'
11153 lt_prog_compiler_static='-Bstatic'
11154 case $cc_basename in
11155 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11156 lt_prog_compiler_wl='-Qoption ld ';;
11157 *)
11158 lt_prog_compiler_wl='-Wl,';;
11159 esac
11160 ;;
11161
11162 sunos4*)
11163 lt_prog_compiler_wl='-Qoption ld '
11164 lt_prog_compiler_pic='-PIC'
11165 lt_prog_compiler_static='-Bstatic'
11166 ;;
11167
11168 sysv4 | sysv4.2uw2* | sysv4.3*)
11169 lt_prog_compiler_wl='-Wl,'
11170 lt_prog_compiler_pic='-KPIC'
11171 lt_prog_compiler_static='-Bstatic'
11172 ;;
11173
11174 sysv4*MP*)
11175 if test -d /usr/nec; then
11176 lt_prog_compiler_pic='-Kconform_pic'
11177 lt_prog_compiler_static='-Bstatic'
11178 fi
11179 ;;
11180
11181 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11182 lt_prog_compiler_wl='-Wl,'
11183 lt_prog_compiler_pic='-KPIC'
11184 lt_prog_compiler_static='-Bstatic'
11185 ;;
11186
11187 unicos*)
11188 lt_prog_compiler_wl='-Wl,'
11189 lt_prog_compiler_can_build_shared=no
11190 ;;
11191
11192 uts4*)
11193 lt_prog_compiler_pic='-pic'
11194 lt_prog_compiler_static='-Bstatic'
11195 ;;
11196
11197 *)
11198 lt_prog_compiler_can_build_shared=no
11199 ;;
11200 esac
11201 fi
11202
11203 case $host_os in
11204 # For platforms that do not support PIC, -DPIC is meaningless:
11205 *djgpp*)
11206 lt_prog_compiler_pic=
11207 ;;
11208 *)
11209 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
11210 ;;
11211 esac
11212
11213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
11214 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
11215 if ${lt_cv_prog_compiler_pic+:} false; then :
11216 $as_echo_n "(cached) " >&6
11217 else
11218 lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
11219 fi
11220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
11221 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
11222 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
11223
11224 #
11225 # Check to make sure the PIC flag actually works.
11226 #
11227 if test -n "$lt_prog_compiler_pic"; then
11228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
11229 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
11230 if ${lt_cv_prog_compiler_pic_works+:} false; then :
11231 $as_echo_n "(cached) " >&6
11232 else
11233 lt_cv_prog_compiler_pic_works=no
11234 ac_outfile=conftest.$ac_objext
11235 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11236 lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment
11237 # Insert the option either (1) after the last *FLAGS variable, or
11238 # (2) before a word containing "conftest.", or (3) at the end.
11239 # Note that $ac_compile itself does not contain backslashes and begins
11240 # with a dollar sign (not a hyphen), so the echo should work correctly.
11241 # The option is referenced via a variable to avoid confusing sed.
11242 lt_compile=`echo "$ac_compile" | $SED \
11243 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11244 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11245 -e 's:$: $lt_compiler_flag:'`
11246 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11247 (eval "$lt_compile" 2>conftest.err)
11248 ac_status=$?
11249 cat conftest.err >&5
11250 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11251 if (exit $ac_status) && test -s "$ac_outfile"; then
11252 # The compiler can only warn and ignore the option if not recognized
11253 # So say no if there are warnings other than the usual output.
11254 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11255 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11256 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11257 lt_cv_prog_compiler_pic_works=yes
11258 fi
11259 fi
11260 $RM conftest*
11261
11262 fi
11263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
11264 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
11265
11266 if test yes = "$lt_cv_prog_compiler_pic_works"; then
11267 case $lt_prog_compiler_pic in
11268 "" | " "*) ;;
11269 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
11270 esac
11271 else
11272 lt_prog_compiler_pic=
11273 lt_prog_compiler_can_build_shared=no
11274 fi
11275
11276 fi
11277
11278
11279
11280
11281
11282
11283
11284
11285
11286
11287
11288 #
11289 # Check to make sure the static flag actually works.
11290 #
11291 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
11292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
11293 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
11294 if ${lt_cv_prog_compiler_static_works+:} false; then :
11295 $as_echo_n "(cached) " >&6
11296 else
11297 lt_cv_prog_compiler_static_works=no
11298 save_LDFLAGS=$LDFLAGS
11299 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
11300 echo "$lt_simple_link_test_code" > conftest.$ac_ext
11301 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
11302 # The linker can only warn and ignore the option if not recognized
11303 # So say no if there are warnings
11304 if test -s conftest.err; then
11305 # Append any errors to the config.log.
11306 cat conftest.err 1>&5
11307 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
11308 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11309 if diff conftest.exp conftest.er2 >/dev/null; then
11310 lt_cv_prog_compiler_static_works=yes
11311 fi
11312 else
11313 lt_cv_prog_compiler_static_works=yes
11314 fi
11315 fi
11316 $RM -r conftest*
11317 LDFLAGS=$save_LDFLAGS
11318
11319 fi
11320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
11321 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
11322
11323 if test yes = "$lt_cv_prog_compiler_static_works"; then
11324 :
11325 else
11326 lt_prog_compiler_static=
11327 fi
11328
11329
11330
11331
11332
11333
11334
11335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11336 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11337 if ${lt_cv_prog_compiler_c_o+:} false; then :
11338 $as_echo_n "(cached) " >&6
11339 else
11340 lt_cv_prog_compiler_c_o=no
11341 $RM -r conftest 2>/dev/null
11342 mkdir conftest
11343 cd conftest
11344 mkdir out
11345 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11346
11347 lt_compiler_flag="-o out/conftest2.$ac_objext"
11348 # Insert the option either (1) after the last *FLAGS variable, or
11349 # (2) before a word containing "conftest.", or (3) at the end.
11350 # Note that $ac_compile itself does not contain backslashes and begins
11351 # with a dollar sign (not a hyphen), so the echo should work correctly.
11352 lt_compile=`echo "$ac_compile" | $SED \
11353 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11354 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11355 -e 's:$: $lt_compiler_flag:'`
11356 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11357 (eval "$lt_compile" 2>out/conftest.err)
11358 ac_status=$?
11359 cat out/conftest.err >&5
11360 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11361 if (exit $ac_status) && test -s out/conftest2.$ac_objext
11362 then
11363 # The compiler can only warn and ignore the option if not recognized
11364 # So say no if there are warnings
11365 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11366 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11367 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11368 lt_cv_prog_compiler_c_o=yes
11369 fi
11370 fi
11371 chmod u+w . 2>&5
11372 $RM conftest*
11373 # SGI C++ compiler will create directory out/ii_files/ for
11374 # template instantiation
11375 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11376 $RM out/* && rmdir out
11377 cd ..
11378 $RM -r conftest
11379 $RM conftest*
11380
11381 fi
11382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11383 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11384
11385
11386
11387
11388
11389
11390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
11391 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
11392 if ${lt_cv_prog_compiler_c_o+:} false; then :
11393 $as_echo_n "(cached) " >&6
11394 else
11395 lt_cv_prog_compiler_c_o=no
11396 $RM -r conftest 2>/dev/null
11397 mkdir conftest
11398 cd conftest
11399 mkdir out
11400 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11401
11402 lt_compiler_flag="-o out/conftest2.$ac_objext"
11403 # Insert the option either (1) after the last *FLAGS variable, or
11404 # (2) before a word containing "conftest.", or (3) at the end.
11405 # Note that $ac_compile itself does not contain backslashes and begins
11406 # with a dollar sign (not a hyphen), so the echo should work correctly.
11407 lt_compile=`echo "$ac_compile" | $SED \
11408 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11409 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11410 -e 's:$: $lt_compiler_flag:'`
11411 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11412 (eval "$lt_compile" 2>out/conftest.err)
11413 ac_status=$?
11414 cat out/conftest.err >&5
11415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11416 if (exit $ac_status) && test -s out/conftest2.$ac_objext
11417 then
11418 # The compiler can only warn and ignore the option if not recognized
11419 # So say no if there are warnings
11420 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
11421 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
11422 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
11423 lt_cv_prog_compiler_c_o=yes
11424 fi
11425 fi
11426 chmod u+w . 2>&5
11427 $RM conftest*
11428 # SGI C++ compiler will create directory out/ii_files/ for
11429 # template instantiation
11430 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
11431 $RM out/* && rmdir out
11432 cd ..
11433 $RM -r conftest
11434 $RM conftest*
11435
11436 fi
11437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
11438 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
11439
11440
11441
11442
11443 hard_links=nottested
11444 if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
11445 # do not overwrite the value of need_locks provided by the user
11446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
11447 $as_echo_n "checking if we can lock with hard links... " >&6; }
11448 hard_links=yes
11449 $RM conftest*
11450 ln conftest.a conftest.b 2>/dev/null && hard_links=no
11451 touch conftest.a
11452 ln conftest.a conftest.b 2>&5 || hard_links=no
11453 ln conftest.a conftest.b 2>/dev/null && hard_links=no
11454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
11455 $as_echo "$hard_links" >&6; }
11456 if test no = "$hard_links"; then
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
11458 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
11459 need_locks=warn
11460 fi
11461 else
11462 need_locks=no
11463 fi
11464
11465
11466
11467
11468
11469
11470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
11471 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
11472
11473 runpath_var=
11474 allow_undefined_flag=
11475 always_export_symbols=no
11476 archive_cmds=
11477 archive_expsym_cmds=
11478 compiler_needs_object=no
11479 enable_shared_with_static_runtimes=no
11480 export_dynamic_flag_spec=
11481 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
11482 hardcode_automatic=no
11483 hardcode_direct=no
11484 hardcode_direct_absolute=no
11485 hardcode_libdir_flag_spec=
11486 hardcode_libdir_separator=
11487 hardcode_minus_L=no
11488 hardcode_shlibpath_var=unsupported
11489 inherit_rpath=no
11490 link_all_deplibs=unknown
11491 module_cmds=
11492 module_expsym_cmds=
11493 old_archive_from_new_cmds=
11494 old_archive_from_expsyms_cmds=
11495 thread_safe_flag_spec=
11496 whole_archive_flag_spec=
11497 # include_expsyms should be a list of space-separated symbols to be *always*
11498 # included in the symbol list
11499 include_expsyms=
11500 # exclude_expsyms can be an extended regexp of symbols to exclude
11501 # it will be wrapped by ' (' and ')$', so one must not match beginning or
11502 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
11503 # as well as any symbol that contains 'd'.
11504 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
11505 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
11506 # platforms (ab)use it in PIC code, but their linkers get confused if
11507 # the symbol is explicitly referenced. Since portable code cannot
11508 # rely on this symbol name, it's probably fine to never include it in
11509 # preloaded symbol tables.
11510 # Exclude shared library initialization/finalization symbols.
11511 extract_expsyms_cmds=
11512
11513 case $host_os in
11514 cygwin* | mingw* | pw32* | cegcc*)
11515 # FIXME: the MSVC++ port hasn't been tested in a loooong time
11516 # When not using gcc, we currently assume that we are using
11517 # Microsoft Visual C++.
11518 if test yes != "$GCC"; then
11519 with_gnu_ld=no
11520 fi
11521 ;;
11522 interix*)
11523 # we just hope/assume this is gcc and not c89 (= MSVC++)
11524 with_gnu_ld=yes
11525 ;;
11526 openbsd* | bitrig*)
11527 with_gnu_ld=no
11528 ;;
11529 linux* | k*bsd*-gnu | gnu*)
11530 link_all_deplibs=no
11531 ;;
11532 esac
11533
11534 ld_shlibs=yes
11535
11536 # On some targets, GNU ld is compatible enough with the native linker
11537 # that we're better off using the native interface for both.
11538 lt_use_gnu_ld_interface=no
11539 if test yes = "$with_gnu_ld"; then
11540 case $host_os in
11541 aix*)
11542 # The AIX port of GNU ld has always aspired to compatibility
11543 # with the native linker. However, as the warning in the GNU ld
11544 # block says, versions before 2.19.5* couldn't really create working
11545 # shared libraries, regardless of the interface used.
11546 case `$LD -v 2>&1` in
11547 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
11548 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
11549 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
11550 *)
11551 lt_use_gnu_ld_interface=yes
11552 ;;
11553 esac
11554 ;;
11555 *)
11556 lt_use_gnu_ld_interface=yes
11557 ;;
11558 esac
11559 fi
11560
11561 if test yes = "$lt_use_gnu_ld_interface"; then
11562 # If archive_cmds runs LD, not CC, wlarc should be empty
11563 wlarc='$wl'
11564
11565 # Set some defaults for GNU ld with shared library support. These
11566 # are reset later if shared libraries are not supported. Putting them
11567 # here allows them to be overridden if necessary.
11568 runpath_var=LD_RUN_PATH
11569 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11570 export_dynamic_flag_spec='$wl--export-dynamic'
11571 # ancient GNU ld didn't support --whole-archive et. al.
11572 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
11573 whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
11574 else
11575 whole_archive_flag_spec=
11576 fi
11577 supports_anon_versioning=no
11578 case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
11579 *GNU\ gold*) supports_anon_versioning=yes ;;
11580 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
11581 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
11582 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
11583 *\ 2.11.*) ;; # other 2.11 versions
11584 *) supports_anon_versioning=yes ;;
11585 esac
11586
11587 # See if GNU ld supports shared libraries.
11588 case $host_os in
11589 aix[3-9]*)
11590 # On AIX/PPC, the GNU linker is very broken
11591 if test ia64 != "$host_cpu"; then
11592 ld_shlibs=no
11593 cat <<_LT_EOF 1>&2
11594
11595 *** Warning: the GNU linker, at least up to release 2.19, is reported
11596 *** to be unable to reliably create shared libraries on AIX.
11597 *** Therefore, libtool is disabling shared libraries support. If you
11598 *** really care for shared libraries, you may want to install binutils
11599 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
11600 *** You will then need to restart the configuration process.
11601
11602 _LT_EOF
11603 fi
11604 ;;
11605
11606 amigaos*)
11607 case $host_cpu in
11608 powerpc)
11609 # see comment about AmigaOS4 .so support
11610 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11611 archive_expsym_cmds=''
11612 ;;
11613 m68k)
11614 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)'
11615 hardcode_libdir_flag_spec='-L$libdir'
11616 hardcode_minus_L=yes
11617 ;;
11618 esac
11619 ;;
11620
11621 beos*)
11622 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11623 allow_undefined_flag=unsupported
11624 # Joseph Beckenbach <jrb3 (at] best.com> says some releases of gcc
11625 # support --undefined. This deserves some investigation. FIXME
11626 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11627 else
11628 ld_shlibs=no
11629 fi
11630 ;;
11631
11632 cygwin* | mingw* | pw32* | cegcc*)
11633 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
11634 # as there is no search path for DLLs.
11635 hardcode_libdir_flag_spec='-L$libdir'
11636 export_dynamic_flag_spec='$wl--export-all-symbols'
11637 allow_undefined_flag=unsupported
11638 always_export_symbols=no
11639 enable_shared_with_static_runtimes=yes
11640 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'
11641 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
11642
11643 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
11644 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11645 # If the export-symbols file already is a .def file, use it as
11646 # is; otherwise, prepend EXPORTS...
11647 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
11648 cp $export_symbols $output_objdir/$soname.def;
11649 else
11650 echo EXPORTS > $output_objdir/$soname.def;
11651 cat $export_symbols >> $output_objdir/$soname.def;
11652 fi~
11653 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
11654 else
11655 ld_shlibs=no
11656 fi
11657 ;;
11658
11659 haiku*)
11660 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11661 link_all_deplibs=yes
11662 ;;
11663
11664 os2*)
11665 hardcode_libdir_flag_spec='-L$libdir'
11666 hardcode_minus_L=yes
11667 allow_undefined_flag=unsupported
11668 shrext_cmds=.dll
11669 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11670 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11671 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11672 $ECHO EXPORTS >> $output_objdir/$libname.def~
11673 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
11674 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11675 emximp -o $lib $output_objdir/$libname.def'
11676 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
11677 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
11678 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
11679 $ECHO EXPORTS >> $output_objdir/$libname.def~
11680 prefix_cmds="$SED"~
11681 if test EXPORTS = "`$SED 1q $export_symbols`"; then
11682 prefix_cmds="$prefix_cmds -e 1d";
11683 fi~
11684 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
11685 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
11686 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
11687 emximp -o $lib $output_objdir/$libname.def'
11688 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
11689 enable_shared_with_static_runtimes=yes
11690 ;;
11691
11692 interix[3-9]*)
11693 hardcode_direct=no
11694 hardcode_shlibpath_var=no
11695 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
11696 export_dynamic_flag_spec='$wl-E'
11697 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
11698 # Instead, shared libraries are loaded at an image base (0x10000000 by
11699 # default) and relocated if they conflict, which is a slow very memory
11700 # consuming and fragmenting process. To avoid this, we pick a random,
11701 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
11702 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
11703 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
11704 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'
11705 ;;
11706
11707 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
11708 tmp_diet=no
11709 if test linux-dietlibc = "$host_os"; then
11710 case $cc_basename in
11711 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
11712 esac
11713 fi
11714 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
11715 && test no = "$tmp_diet"
11716 then
11717 tmp_addflag=' $pic_flag'
11718 tmp_sharedflag='-shared'
11719 case $cc_basename,$host_cpu in
11720 pgcc*) # Portland Group C compiler
11721 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'
11722 tmp_addflag=' $pic_flag'
11723 ;;
11724 pgf77* | pgf90* | pgf95* | pgfortran*)
11725 # Portland Group f77 and f90 compilers
11726 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'
11727 tmp_addflag=' $pic_flag -Mnomain' ;;
11728 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
11729 tmp_addflag=' -i_dynamic' ;;
11730 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
11731 tmp_addflag=' -i_dynamic -nofor_main' ;;
11732 ifc* | ifort*) # Intel Fortran compiler
11733 tmp_addflag=' -nofor_main' ;;
11734 lf95*) # Lahey Fortran 8.1
11735 whole_archive_flag_spec=
11736 tmp_sharedflag='--shared' ;;
11737 nagfor*) # NAGFOR 5.3
11738 tmp_sharedflag='-Wl,-shared' ;;
11739 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
11740 tmp_sharedflag='-qmkshrobj'
11741 tmp_addflag= ;;
11742 nvcc*) # Cuda Compiler Driver 2.2
11743 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'
11744 compiler_needs_object=yes
11745 ;;
11746 esac
11747 case `$CC -V 2>&1 | sed 5q` in
11748 *Sun\ C*) # Sun C 5.9
11749 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'
11750 compiler_needs_object=yes
11751 tmp_sharedflag='-G' ;;
11752 *Sun\ F*) # Sun Fortran 8.3
11753 tmp_sharedflag='-G' ;;
11754 esac
11755 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11756
11757 if test yes = "$supports_anon_versioning"; then
11758 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11759 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11760 echo "local: *; };" >> $output_objdir/$libname.ver~
11761 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
11762 fi
11763
11764 case $cc_basename in
11765 tcc*)
11766 export_dynamic_flag_spec='-rdynamic'
11767 ;;
11768 xlf* | bgf* | bgxlf* | mpixlf*)
11769 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
11770 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
11771 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11772 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
11773 if test yes = "$supports_anon_versioning"; then
11774 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
11775 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
11776 echo "local: *; };" >> $output_objdir/$libname.ver~
11777 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
11778 fi
11779 ;;
11780 esac
11781 else
11782 ld_shlibs=no
11783 fi
11784 ;;
11785
11786 netbsd* | netbsdelf*-gnu)
11787 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11788 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
11789 wlarc=
11790 else
11791 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11792 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11793 fi
11794 ;;
11795
11796 solaris*)
11797 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
11798 ld_shlibs=no
11799 cat <<_LT_EOF 1>&2
11800
11801 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
11802 *** create shared libraries on Solaris systems. Therefore, libtool
11803 *** is disabling shared libraries support. We urge you to upgrade GNU
11804 *** binutils to release 2.9.1 or newer. Another option is to modify
11805 *** your PATH or compiler configuration so that the native linker is
11806 *** used, and then restart.
11807
11808 _LT_EOF
11809 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11810 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11811 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11812 else
11813 ld_shlibs=no
11814 fi
11815 ;;
11816
11817 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
11818 case `$LD -v 2>&1` in
11819 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
11820 ld_shlibs=no
11821 cat <<_LT_EOF 1>&2
11822
11823 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
11824 *** reliably create shared libraries on SCO systems. Therefore, libtool
11825 *** is disabling shared libraries support. We urge you to upgrade GNU
11826 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
11827 *** your PATH or compiler configuration so that the native linker is
11828 *** used, and then restart.
11829
11830 _LT_EOF
11831 ;;
11832 *)
11833 # For security reasons, it is highly recommended that you always
11834 # use absolute paths for naming shared libraries, and exclude the
11835 # DT_RUNPATH tag from executables and libraries. But doing so
11836 # requires that you compile everything twice, which is a pain.
11837 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11838 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
11839 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11840 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11841 else
11842 ld_shlibs=no
11843 fi
11844 ;;
11845 esac
11846 ;;
11847
11848 sunos4*)
11849 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
11850 wlarc=
11851 hardcode_direct=yes
11852 hardcode_shlibpath_var=no
11853 ;;
11854
11855 *)
11856 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
11857 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
11858 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
11859 else
11860 ld_shlibs=no
11861 fi
11862 ;;
11863 esac
11864
11865 if test no = "$ld_shlibs"; then
11866 runpath_var=
11867 hardcode_libdir_flag_spec=
11868 export_dynamic_flag_spec=
11869 whole_archive_flag_spec=
11870 fi
11871 else
11872 # PORTME fill in a description of your system's linker (not GNU ld)
11873 case $host_os in
11874 aix3*)
11875 allow_undefined_flag=unsupported
11876 always_export_symbols=yes
11877 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'
11878 # Note: this linker hardcodes the directories in LIBPATH if there
11879 # are no directories specified by -L.
11880 hardcode_minus_L=yes
11881 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
11882 # Neither direct hardcoding nor static linking is supported with a
11883 # broken collect2.
11884 hardcode_direct=unsupported
11885 fi
11886 ;;
11887
11888 aix[4-9]*)
11889 if test ia64 = "$host_cpu"; then
11890 # On IA64, the linker does run time linking by default, so we don't
11891 # have to do anything special.
11892 aix_use_runtimelinking=no
11893 exp_sym_flag='-Bexport'
11894 no_entry_flag=
11895 else
11896 # If we're using GNU nm, then we don't want the "-C" option.
11897 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
11898 # Without the "-l" option, or with the "-B" option, AIX nm treats
11899 # weak defined symbols like other global defined symbols, whereas
11900 # GNU nm marks them as "W".
11901 # While the 'weak' keyword is ignored in the Export File, we need
11902 # it in the Import File for the 'aix-soname' feature, so we have
11903 # to replace the "-B" option with "-P" for AIX nm.
11904 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
11905 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'
11906 else
11907 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'
11908 fi
11909 aix_use_runtimelinking=no
11910
11911 # Test if we are trying to use run time linking or normal
11912 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
11913 # have runtime linking enabled, and use it for executables.
11914 # For shared libraries, we enable/disable runtime linking
11915 # depending on the kind of the shared library created -
11916 # when "with_aix_soname,aix_use_runtimelinking" is:
11917 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
11918 # "aix,yes" lib.so shared, rtl:yes, for executables
11919 # lib.a static archive
11920 # "both,no" lib.so.V(shr.o) shared, rtl:yes
11921 # lib.a(lib.so.V) shared, rtl:no, for executables
11922 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
11923 # lib.a(lib.so.V) shared, rtl:no
11924 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
11925 # lib.a static archive
11926 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
11927 for ld_flag in $LDFLAGS; do
11928 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
11929 aix_use_runtimelinking=yes
11930 break
11931 fi
11932 done
11933 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
11934 # With aix-soname=svr4, we create the lib.so.V shared archives only,
11935 # so we don't have lib.a shared libs to link our executables.
11936 # We have to force runtime linking in this case.
11937 aix_use_runtimelinking=yes
11938 LDFLAGS="$LDFLAGS -Wl,-brtl"
11939 fi
11940 ;;
11941 esac
11942
11943 exp_sym_flag='-bexport'
11944 no_entry_flag='-bnoentry'
11945 fi
11946
11947 # When large executables or shared objects are built, AIX ld can
11948 # have problems creating the table of contents. If linking a library
11949 # or program results in "error TOC overflow" add -mminimal-toc to
11950 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
11951 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
11952
11953 archive_cmds=''
11954 hardcode_direct=yes
11955 hardcode_direct_absolute=yes
11956 hardcode_libdir_separator=':'
11957 link_all_deplibs=yes
11958 file_list_spec='$wl-f,'
11959 case $with_aix_soname,$aix_use_runtimelinking in
11960 aix,*) ;; # traditional, no import file
11961 svr4,* | *,yes) # use import file
11962 # The Import File defines what to hardcode.
11963 hardcode_direct=no
11964 hardcode_direct_absolute=no
11965 ;;
11966 esac
11967
11968 if test yes = "$GCC"; then
11969 case $host_os in aix4.[012]|aix4.[012].*)
11970 # We only want to do this on AIX 4.2 and lower, the check
11971 # below for broken collect2 doesn't work under 4.3+
11972 collect2name=`$CC -print-prog-name=collect2`
11973 if test -f "$collect2name" &&
11974 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
11975 then
11976 # We have reworked collect2
11977 :
11978 else
11979 # We have old collect2
11980 hardcode_direct=unsupported
11981 # It fails to find uninstalled libraries when the uninstalled
11982 # path is not listed in the libpath. Setting hardcode_minus_L
11983 # to unsupported forces relinking
11984 hardcode_minus_L=yes
11985 hardcode_libdir_flag_spec='-L$libdir'
11986 hardcode_libdir_separator=
11987 fi
11988 ;;
11989 esac
11990 shared_flag='-shared'
11991 if test yes = "$aix_use_runtimelinking"; then
11992 shared_flag="$shared_flag "'$wl-G'
11993 fi
11994 # Need to ensure runtime linking is disabled for the traditional
11995 # shared library, or the linker may eventually find shared libraries
11996 # /with/ Import File - we do not want to mix them.
11997 shared_flag_aix='-shared'
11998 shared_flag_svr4='-shared $wl-G'
11999 else
12000 # not using gcc
12001 if test ia64 = "$host_cpu"; then
12002 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12003 # chokes on -Wl,-G. The following line is correct:
12004 shared_flag='-G'
12005 else
12006 if test yes = "$aix_use_runtimelinking"; then
12007 shared_flag='$wl-G'
12008 else
12009 shared_flag='$wl-bM:SRE'
12010 fi
12011 shared_flag_aix='$wl-bM:SRE'
12012 shared_flag_svr4='$wl-G'
12013 fi
12014 fi
12015
12016 export_dynamic_flag_spec='$wl-bexpall'
12017 # It seems that -bexpall does not export symbols beginning with
12018 # underscore (_), so it is better to generate a list of symbols to export.
12019 always_export_symbols=yes
12020 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12021 # Warning - without using the other runtime loading flags (-brtl),
12022 # -berok will link without error, but may produce a broken library.
12023 allow_undefined_flag='-berok'
12024 # Determine the default libpath from the value encoded in an
12025 # empty executable.
12026 if test set = "${lt_cv_aix_libpath+set}"; then
12027 aix_libpath=$lt_cv_aix_libpath
12028 else
12029 if ${lt_cv_aix_libpath_+:} false; then :
12030 $as_echo_n "(cached) " >&6
12031 else
12032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12033 /* end confdefs.h. */
12034
12035 int
12036 main ()
12037 {
12038
12039 ;
12040 return 0;
12041 }
12042 _ACEOF
12043 if ac_fn_c_try_link "$LINENO"; then :
12044
12045 lt_aix_libpath_sed='
12046 /Import File Strings/,/^$/ {
12047 /^0/ {
12048 s/^0 *\([^ ]*\) *$/\1/
12049 p
12050 }
12051 }'
12052 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12053 # Check for a 64-bit object if we didn't find anything.
12054 if test -z "$lt_cv_aix_libpath_"; then
12055 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12056 fi
12057 fi
12058 rm -f core conftest.err conftest.$ac_objext \
12059 conftest$ac_exeext conftest.$ac_ext
12060 if test -z "$lt_cv_aix_libpath_"; then
12061 lt_cv_aix_libpath_=/usr/lib:/lib
12062 fi
12063
12064 fi
12065
12066 aix_libpath=$lt_cv_aix_libpath_
12067 fi
12068
12069 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12070 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
12071 else
12072 if test ia64 = "$host_cpu"; then
12073 hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12074 allow_undefined_flag="-z nodefs"
12075 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"
12076 else
12077 # Determine the default libpath from the value encoded in an
12078 # empty executable.
12079 if test set = "${lt_cv_aix_libpath+set}"; then
12080 aix_libpath=$lt_cv_aix_libpath
12081 else
12082 if ${lt_cv_aix_libpath_+:} false; then :
12083 $as_echo_n "(cached) " >&6
12084 else
12085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12086 /* end confdefs.h. */
12087
12088 int
12089 main ()
12090 {
12091
12092 ;
12093 return 0;
12094 }
12095 _ACEOF
12096 if ac_fn_c_try_link "$LINENO"; then :
12097
12098 lt_aix_libpath_sed='
12099 /Import File Strings/,/^$/ {
12100 /^0/ {
12101 s/^0 *\([^ ]*\) *$/\1/
12102 p
12103 }
12104 }'
12105 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12106 # Check for a 64-bit object if we didn't find anything.
12107 if test -z "$lt_cv_aix_libpath_"; then
12108 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12109 fi
12110 fi
12111 rm -f core conftest.err conftest.$ac_objext \
12112 conftest$ac_exeext conftest.$ac_ext
12113 if test -z "$lt_cv_aix_libpath_"; then
12114 lt_cv_aix_libpath_=/usr/lib:/lib
12115 fi
12116
12117 fi
12118
12119 aix_libpath=$lt_cv_aix_libpath_
12120 fi
12121
12122 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12123 # Warning - without using the other run time loading flags,
12124 # -berok will link without error, but may produce a broken library.
12125 no_undefined_flag=' $wl-bernotok'
12126 allow_undefined_flag=' $wl-berok'
12127 if test yes = "$with_gnu_ld"; then
12128 # We only use this code for GNU lds that support --whole-archive.
12129 whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12130 else
12131 # Exported symbols can be pulled into shared objects from archives
12132 whole_archive_flag_spec='$convenience'
12133 fi
12134 archive_cmds_need_lc=yes
12135 archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12136 # -brtl affects multiple linker settings, -berok does not and is overridden later
12137 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12138 if test svr4 != "$with_aix_soname"; then
12139 # This is similar to how AIX traditionally builds its shared libraries.
12140 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'
12141 fi
12142 if test aix != "$with_aix_soname"; then
12143 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'
12144 else
12145 # used by -dlpreopen to get the symbols
12146 archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
12147 fi
12148 archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12149 fi
12150 fi
12151 ;;
12152
12153 amigaos*)
12154 case $host_cpu in
12155 powerpc)
12156 # see comment about AmigaOS4 .so support
12157 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12158 archive_expsym_cmds=''
12159 ;;
12160 m68k)
12161 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)'
12162 hardcode_libdir_flag_spec='-L$libdir'
12163 hardcode_minus_L=yes
12164 ;;
12165 esac
12166 ;;
12167
12168 bsdi[45]*)
12169 export_dynamic_flag_spec=-rdynamic
12170 ;;
12171
12172 cygwin* | mingw* | pw32* | cegcc*)
12173 # When not using gcc, we currently assume that we are using
12174 # Microsoft Visual C++.
12175 # hardcode_libdir_flag_spec is actually meaningless, as there is
12176 # no search path for DLLs.
12177 case $cc_basename in
12178 cl*)
12179 # Native MSVC
12180 hardcode_libdir_flag_spec=' '
12181 allow_undefined_flag=unsupported
12182 always_export_symbols=yes
12183 file_list_spec='@'
12184 # Tell ltmain to make .lib files, not .a files.
12185 libext=lib
12186 # Tell ltmain to make .dll files, not .so files.
12187 shrext_cmds=.dll
12188 # FIXME: Setting linknames here is a bad hack.
12189 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12190 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
12191 cp "$export_symbols" "$output_objdir/$soname.def";
12192 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12193 else
12194 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12195 fi~
12196 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12197 linknames='
12198 # The linker will not automatically build a static lib if we build a DLL.
12199 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12200 enable_shared_with_static_runtimes=yes
12201 exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12202 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12203 # Don't use ranlib
12204 old_postinstall_cmds='chmod 644 $oldlib'
12205 postlink_cmds='lt_outputfile="@OUTPUT@"~
12206 lt_tool_outputfile="@TOOL_OUTPUT@"~
12207 case $lt_outputfile in
12208 *.exe|*.EXE) ;;
12209 *)
12210 lt_outputfile=$lt_outputfile.exe
12211 lt_tool_outputfile=$lt_tool_outputfile.exe
12212 ;;
12213 esac~
12214 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
12215 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12216 $RM "$lt_outputfile.manifest";
12217 fi'
12218 ;;
12219 *)
12220 # Assume MSVC wrapper
12221 hardcode_libdir_flag_spec=' '
12222 allow_undefined_flag=unsupported
12223 # Tell ltmain to make .lib files, not .a files.
12224 libext=lib
12225 # Tell ltmain to make .dll files, not .so files.
12226 shrext_cmds=.dll
12227 # FIXME: Setting linknames here is a bad hack.
12228 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
12229 # The linker will automatically build a .lib file if we build a DLL.
12230 old_archive_from_new_cmds='true'
12231 # FIXME: Should let the user specify the lib program.
12232 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
12233 enable_shared_with_static_runtimes=yes
12234 ;;
12235 esac
12236 ;;
12237
12238 darwin* | rhapsody*)
12239
12240
12241 archive_cmds_need_lc=no
12242 hardcode_direct=no
12243 hardcode_automatic=yes
12244 hardcode_shlibpath_var=unsupported
12245 if test yes = "$lt_cv_ld_force_load"; then
12246 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\"`'
12247
12248 else
12249 whole_archive_flag_spec=''
12250 fi
12251 link_all_deplibs=yes
12252 allow_undefined_flag=$_lt_dar_allow_undefined
12253 case $cc_basename in
12254 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
12255 *) _lt_dar_can_shared=$GCC ;;
12256 esac
12257 if test yes = "$_lt_dar_can_shared"; then
12258 output_verbose_link_cmd=func_echo_all
12259 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
12260 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
12261 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"
12262 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"
12263
12264 else
12265 ld_shlibs=no
12266 fi
12267
12268 ;;
12269
12270 dgux*)
12271 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12272 hardcode_libdir_flag_spec='-L$libdir'
12273 hardcode_shlibpath_var=no
12274 ;;
12275
12276 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
12277 # support. Future versions do this automatically, but an explicit c++rt0.o
12278 # does not break anything, and helps significantly (at the cost of a little
12279 # extra space).
12280 freebsd2.2*)
12281 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
12282 hardcode_libdir_flag_spec='-R$libdir'
12283 hardcode_direct=yes
12284 hardcode_shlibpath_var=no
12285 ;;
12286
12287 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
12288 freebsd2.*)
12289 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12290 hardcode_direct=yes
12291 hardcode_minus_L=yes
12292 hardcode_shlibpath_var=no
12293 ;;
12294
12295 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
12296 freebsd* | dragonfly*)
12297 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12298 hardcode_libdir_flag_spec='-R$libdir'
12299 hardcode_direct=yes
12300 hardcode_shlibpath_var=no
12301 ;;
12302
12303 hpux9*)
12304 if test yes = "$GCC"; then
12305 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'
12306 else
12307 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'
12308 fi
12309 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12310 hardcode_libdir_separator=:
12311 hardcode_direct=yes
12312
12313 # hardcode_minus_L: Not really in the search PATH,
12314 # but as the default location of the library.
12315 hardcode_minus_L=yes
12316 export_dynamic_flag_spec='$wl-E'
12317 ;;
12318
12319 hpux10*)
12320 if test yes,no = "$GCC,$with_gnu_ld"; then
12321 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12322 else
12323 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12324 fi
12325 if test no = "$with_gnu_ld"; then
12326 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12327 hardcode_libdir_separator=:
12328 hardcode_direct=yes
12329 hardcode_direct_absolute=yes
12330 export_dynamic_flag_spec='$wl-E'
12331 # hardcode_minus_L: Not really in the search PATH,
12332 # but as the default location of the library.
12333 hardcode_minus_L=yes
12334 fi
12335 ;;
12336
12337 hpux11*)
12338 if test yes,no = "$GCC,$with_gnu_ld"; then
12339 case $host_cpu in
12340 hppa*64*)
12341 archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12342 ;;
12343 ia64*)
12344 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12345 ;;
12346 *)
12347 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12348 ;;
12349 esac
12350 else
12351 case $host_cpu in
12352 hppa*64*)
12353 archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12354 ;;
12355 ia64*)
12356 archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
12357 ;;
12358 *)
12359
12360 # Older versions of the 11.00 compiler do not understand -b yet
12361 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
12362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
12363 $as_echo_n "checking if $CC understands -b... " >&6; }
12364 if ${lt_cv_prog_compiler__b+:} false; then :
12365 $as_echo_n "(cached) " >&6
12366 else
12367 lt_cv_prog_compiler__b=no
12368 save_LDFLAGS=$LDFLAGS
12369 LDFLAGS="$LDFLAGS -b"
12370 echo "$lt_simple_link_test_code" > conftest.$ac_ext
12371 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12372 # The linker can only warn and ignore the option if not recognized
12373 # So say no if there are warnings
12374 if test -s conftest.err; then
12375 # Append any errors to the config.log.
12376 cat conftest.err 1>&5
12377 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12378 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12379 if diff conftest.exp conftest.er2 >/dev/null; then
12380 lt_cv_prog_compiler__b=yes
12381 fi
12382 else
12383 lt_cv_prog_compiler__b=yes
12384 fi
12385 fi
12386 $RM -r conftest*
12387 LDFLAGS=$save_LDFLAGS
12388
12389 fi
12390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
12391 $as_echo "$lt_cv_prog_compiler__b" >&6; }
12392
12393 if test yes = "$lt_cv_prog_compiler__b"; then
12394 archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
12395 else
12396 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
12397 fi
12398
12399 ;;
12400 esac
12401 fi
12402 if test no = "$with_gnu_ld"; then
12403 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
12404 hardcode_libdir_separator=:
12405
12406 case $host_cpu in
12407 hppa*64*|ia64*)
12408 hardcode_direct=no
12409 hardcode_shlibpath_var=no
12410 ;;
12411 *)
12412 hardcode_direct=yes
12413 hardcode_direct_absolute=yes
12414 export_dynamic_flag_spec='$wl-E'
12415
12416 # hardcode_minus_L: Not really in the search PATH,
12417 # but as the default location of the library.
12418 hardcode_minus_L=yes
12419 ;;
12420 esac
12421 fi
12422 ;;
12423
12424 irix5* | irix6* | nonstopux*)
12425 if test yes = "$GCC"; then
12426 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'
12427 # Try to use the -exported_symbol ld option, if it does not
12428 # work, assume that -exports_file does not work either and
12429 # implicitly export all symbols.
12430 # This should be the same for all languages, so no per-tag cache variable.
12431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
12432 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
12433 if ${lt_cv_irix_exported_symbol+:} false; then :
12434 $as_echo_n "(cached) " >&6
12435 else
12436 save_LDFLAGS=$LDFLAGS
12437 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
12438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12439 /* end confdefs.h. */
12440 int foo (void) { return 0; }
12441 _ACEOF
12442 if ac_fn_c_try_link "$LINENO"; then :
12443 lt_cv_irix_exported_symbol=yes
12444 else
12445 lt_cv_irix_exported_symbol=no
12446 fi
12447 rm -f core conftest.err conftest.$ac_objext \
12448 conftest$ac_exeext conftest.$ac_ext
12449 LDFLAGS=$save_LDFLAGS
12450 fi
12451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
12452 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
12453 if test yes = "$lt_cv_irix_exported_symbol"; then
12454 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'
12455 fi
12456 link_all_deplibs=no
12457 else
12458 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'
12459 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'
12460 fi
12461 archive_cmds_need_lc='no'
12462 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12463 hardcode_libdir_separator=:
12464 inherit_rpath=yes
12465 link_all_deplibs=yes
12466 ;;
12467
12468 linux*)
12469 case $cc_basename in
12470 tcc*)
12471 # Fabrice Bellard et al's Tiny C Compiler
12472 ld_shlibs=yes
12473 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12474 ;;
12475 esac
12476 ;;
12477
12478 netbsd* | netbsdelf*-gnu)
12479 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12480 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
12481 else
12482 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
12483 fi
12484 hardcode_libdir_flag_spec='-R$libdir'
12485 hardcode_direct=yes
12486 hardcode_shlibpath_var=no
12487 ;;
12488
12489 newsos6)
12490 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12491 hardcode_direct=yes
12492 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12493 hardcode_libdir_separator=:
12494 hardcode_shlibpath_var=no
12495 ;;
12496
12497 *nto* | *qnx*)
12498 ;;
12499
12500 openbsd* | bitrig*)
12501 if test -f /usr/libexec/ld.so; then
12502 hardcode_direct=yes
12503 hardcode_shlibpath_var=no
12504 hardcode_direct_absolute=yes
12505 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
12506 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12507 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
12508 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12509 export_dynamic_flag_spec='$wl-E'
12510 else
12511 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
12512 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12513 fi
12514 else
12515 ld_shlibs=no
12516 fi
12517 ;;
12518
12519 os2*)
12520 hardcode_libdir_flag_spec='-L$libdir'
12521 hardcode_minus_L=yes
12522 allow_undefined_flag=unsupported
12523 shrext_cmds=.dll
12524 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12525 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12526 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12527 $ECHO EXPORTS >> $output_objdir/$libname.def~
12528 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12529 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12530 emximp -o $lib $output_objdir/$libname.def'
12531 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12532 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12533 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12534 $ECHO EXPORTS >> $output_objdir/$libname.def~
12535 prefix_cmds="$SED"~
12536 if test EXPORTS = "`$SED 1q $export_symbols`"; then
12537 prefix_cmds="$prefix_cmds -e 1d";
12538 fi~
12539 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12540 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12541 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12542 emximp -o $lib $output_objdir/$libname.def'
12543 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12544 enable_shared_with_static_runtimes=yes
12545 ;;
12546
12547 osf3*)
12548 if test yes = "$GCC"; then
12549 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12550 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'
12551 else
12552 allow_undefined_flag=' -expect_unresolved \*'
12553 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'
12554 fi
12555 archive_cmds_need_lc='no'
12556 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12557 hardcode_libdir_separator=:
12558 ;;
12559
12560 osf4* | osf5*) # as osf3* with the addition of -msym flag
12561 if test yes = "$GCC"; then
12562 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
12563 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'
12564 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12565 else
12566 allow_undefined_flag=' -expect_unresolved \*'
12567 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'
12568 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~
12569 $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'
12570
12571 # Both c and cxx compiler support -rpath directly
12572 hardcode_libdir_flag_spec='-rpath $libdir'
12573 fi
12574 archive_cmds_need_lc='no'
12575 hardcode_libdir_separator=:
12576 ;;
12577
12578 solaris*)
12579 no_undefined_flag=' -z defs'
12580 if test yes = "$GCC"; then
12581 wlarc='$wl'
12582 archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
12583 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12584 $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'
12585 else
12586 case `$CC -V 2>&1` in
12587 *"Compilers 5.0"*)
12588 wlarc=''
12589 archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
12590 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12591 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
12592 ;;
12593 *)
12594 wlarc='$wl'
12595 archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
12596 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
12597 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
12598 ;;
12599 esac
12600 fi
12601 hardcode_libdir_flag_spec='-R$libdir'
12602 hardcode_shlibpath_var=no
12603 case $host_os in
12604 solaris2.[0-5] | solaris2.[0-5].*) ;;
12605 *)
12606 # The compiler driver will combine and reorder linker options,
12607 # but understands '-z linker_flag'. GCC discards it without '$wl',
12608 # but is careful enough not to reorder.
12609 # Supported since Solaris 2.6 (maybe 2.5.1?)
12610 if test yes = "$GCC"; then
12611 whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
12612 else
12613 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
12614 fi
12615 ;;
12616 esac
12617 link_all_deplibs=yes
12618 ;;
12619
12620 sunos4*)
12621 if test sequent = "$host_vendor"; then
12622 # Use $CC to link under sequent, because it throws in some extra .o
12623 # files that make .init and .fini sections work.
12624 archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
12625 else
12626 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
12627 fi
12628 hardcode_libdir_flag_spec='-L$libdir'
12629 hardcode_direct=yes
12630 hardcode_minus_L=yes
12631 hardcode_shlibpath_var=no
12632 ;;
12633
12634 sysv4)
12635 case $host_vendor in
12636 sni)
12637 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12638 hardcode_direct=yes # is this really true???
12639 ;;
12640 siemens)
12641 ## LD is ld it makes a PLAMLIB
12642 ## CC just makes a GrossModule.
12643 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
12644 reload_cmds='$CC -r -o $output$reload_objs'
12645 hardcode_direct=no
12646 ;;
12647 motorola)
12648 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12649 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
12650 ;;
12651 esac
12652 runpath_var='LD_RUN_PATH'
12653 hardcode_shlibpath_var=no
12654 ;;
12655
12656 sysv4.3*)
12657 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12658 hardcode_shlibpath_var=no
12659 export_dynamic_flag_spec='-Bexport'
12660 ;;
12661
12662 sysv4*MP*)
12663 if test -d /usr/nec; then
12664 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12665 hardcode_shlibpath_var=no
12666 runpath_var=LD_RUN_PATH
12667 hardcode_runpath_var=yes
12668 ld_shlibs=yes
12669 fi
12670 ;;
12671
12672 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
12673 no_undefined_flag='$wl-z,text'
12674 archive_cmds_need_lc=no
12675 hardcode_shlibpath_var=no
12676 runpath_var='LD_RUN_PATH'
12677
12678 if test yes = "$GCC"; then
12679 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12680 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12681 else
12682 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12683 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12684 fi
12685 ;;
12686
12687 sysv5* | sco3.2v5* | sco5v6*)
12688 # Note: We CANNOT use -z defs as we might desire, because we do not
12689 # link with -lc, and that would cause any symbols used from libc to
12690 # always be unresolved, which means just about no library would
12691 # ever link correctly. If we're not using GNU ld we use -z text
12692 # though, which does catch some bad symbols but isn't as heavy-handed
12693 # as -z defs.
12694 no_undefined_flag='$wl-z,text'
12695 allow_undefined_flag='$wl-z,nodefs'
12696 archive_cmds_need_lc=no
12697 hardcode_shlibpath_var=no
12698 hardcode_libdir_flag_spec='$wl-R,$libdir'
12699 hardcode_libdir_separator=':'
12700 link_all_deplibs=yes
12701 export_dynamic_flag_spec='$wl-Bexport'
12702 runpath_var='LD_RUN_PATH'
12703
12704 if test yes = "$GCC"; then
12705 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12706 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12707 else
12708 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12709 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
12710 fi
12711 ;;
12712
12713 uts4*)
12714 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
12715 hardcode_libdir_flag_spec='-L$libdir'
12716 hardcode_shlibpath_var=no
12717 ;;
12718
12719 *)
12720 ld_shlibs=no
12721 ;;
12722 esac
12723
12724 if test sni = "$host_vendor"; then
12725 case $host in
12726 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
12727 export_dynamic_flag_spec='$wl-Blargedynsym'
12728 ;;
12729 esac
12730 fi
12731 fi
12732
12733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
12734 $as_echo "$ld_shlibs" >&6; }
12735 test no = "$ld_shlibs" && can_build_shared=no
12736
12737 with_gnu_ld=$with_gnu_ld
12738
12739
12740
12741
12742
12743
12744
12745
12746
12747
12748
12749
12750
12751
12752
12753 #
12754 # Do we need to explicitly link libc?
12755 #
12756 case "x$archive_cmds_need_lc" in
12757 x|xyes)
12758 # Assume -lc should be added
12759 archive_cmds_need_lc=yes
12760
12761 if test yes,yes = "$GCC,$enable_shared"; then
12762 case $archive_cmds in
12763 *'~'*)
12764 # FIXME: we may have to deal with multi-command sequences.
12765 ;;
12766 '$CC '*)
12767 # Test whether the compiler implicitly links with -lc since on some
12768 # systems, -lgcc has to come before -lc. If gcc already passes -lc
12769 # to ld, don't add -lc before -lgcc.
12770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
12771 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
12772 if ${lt_cv_archive_cmds_need_lc+:} false; then :
12773 $as_echo_n "(cached) " >&6
12774 else
12775 $RM conftest*
12776 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12777
12778 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
12779 (eval $ac_compile) 2>&5
12780 ac_status=$?
12781 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12782 test $ac_status = 0; } 2>conftest.err; then
12783 soname=conftest
12784 lib=conftest
12785 libobjs=conftest.$ac_objext
12786 deplibs=
12787 wl=$lt_prog_compiler_wl
12788 pic_flag=$lt_prog_compiler_pic
12789 compiler_flags=-v
12790 linker_flags=-v
12791 verstring=
12792 output_objdir=.
12793 libname=conftest
12794 lt_save_allow_undefined_flag=$allow_undefined_flag
12795 allow_undefined_flag=
12796 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
12797 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
12798 ac_status=$?
12799 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
12800 test $ac_status = 0; }
12801 then
12802 lt_cv_archive_cmds_need_lc=no
12803 else
12804 lt_cv_archive_cmds_need_lc=yes
12805 fi
12806 allow_undefined_flag=$lt_save_allow_undefined_flag
12807 else
12808 cat conftest.err 1>&5
12809 fi
12810 $RM conftest*
12811
12812 fi
12813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
12814 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
12815 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
12816 ;;
12817 esac
12818 fi
12819 ;;
12820 esac
12821
12822
12823
12824
12825
12826
12827
12828
12829
12830
12831
12832
12833
12834
12835
12836
12837
12838
12839
12840
12841
12842
12843
12844
12845
12846
12847
12848
12849
12850
12851
12852
12853
12854
12855
12856
12857
12858
12859
12860
12861
12862
12863
12864
12865
12866
12867
12868
12869
12870
12871
12872
12873
12874
12875
12876
12877
12878
12879
12880
12881
12882
12883
12884
12885
12886
12887
12888
12889
12890
12891
12892
12893
12894
12895
12896
12897
12898
12899
12900
12901
12902
12903
12904
12905
12906
12907
12908
12909
12910
12911
12912
12913
12914
12915
12916
12917
12918
12919
12920
12921
12922
12923
12924
12925
12926
12927
12928
12929
12930
12931
12932
12933
12934
12935
12936
12937
12938
12939
12940
12941
12942
12943
12944
12945
12946
12947
12948
12949
12950
12951
12952
12953
12954
12955
12956
12957
12958
12959
12960
12961
12962
12963
12964
12965
12966
12967
12968
12969
12970
12971
12972
12973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
12974 $as_echo_n "checking dynamic linker characteristics... " >&6; }
12975
12976 if test yes = "$GCC"; then
12977 case $host_os in
12978 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
12979 *) lt_awk_arg='/^libraries:/' ;;
12980 esac
12981 case $host_os in
12982 mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
12983 *) lt_sed_strip_eq='s|=/|/|g' ;;
12984 esac
12985 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
12986 case $lt_search_path_spec in
12987 *\;*)
12988 # if the path contains ";" then we assume it to be the separator
12989 # otherwise default to the standard path separator (i.e. ":") - it is
12990 # assumed that no part of a normal pathname contains ";" but that should
12991 # okay in the real world where ";" in dirpaths is itself problematic.
12992 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
12993 ;;
12994 *)
12995 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
12996 ;;
12997 esac
12998 # Ok, now we have the path, separated by spaces, we can step through it
12999 # and add multilib dir if necessary...
13000 lt_tmp_lt_search_path_spec=
13001 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
13002 # ...but if some path component already ends with the multilib dir we assume
13003 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
13004 case "$lt_multi_os_dir; $lt_search_path_spec " in
13005 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
13006 lt_multi_os_dir=
13007 ;;
13008 esac
13009 for lt_sys_path in $lt_search_path_spec; do
13010 if test -d "$lt_sys_path$lt_multi_os_dir"; then
13011 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
13012 elif test -n "$lt_multi_os_dir"; then
13013 test -d "$lt_sys_path" && \
13014 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
13015 fi
13016 done
13017 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13018 BEGIN {RS = " "; FS = "/|\n";} {
13019 lt_foo = "";
13020 lt_count = 0;
13021 for (lt_i = NF; lt_i > 0; lt_i--) {
13022 if ($lt_i != "" && $lt_i != ".") {
13023 if ($lt_i == "..") {
13024 lt_count++;
13025 } else {
13026 if (lt_count == 0) {
13027 lt_foo = "/" $lt_i lt_foo;
13028 } else {
13029 lt_count--;
13030 }
13031 }
13032 }
13033 }
13034 if (lt_foo != "") { lt_freq[lt_foo]++; }
13035 if (lt_freq[lt_foo] == 1) { print lt_foo; }
13036 }'`
13037 # AWK program above erroneously prepends '/' to C:/dos/paths
13038 # for these hosts.
13039 case $host_os in
13040 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13041 $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13042 esac
13043 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13044 else
13045 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13046 fi
13047 library_names_spec=
13048 libname_spec='lib$name'
13049 soname_spec=
13050 shrext_cmds=.so
13051 postinstall_cmds=
13052 postuninstall_cmds=
13053 finish_cmds=
13054 finish_eval=
13055 shlibpath_var=
13056 shlibpath_overrides_runpath=unknown
13057 version_type=none
13058 dynamic_linker="$host_os ld.so"
13059 sys_lib_dlsearch_path_spec="/lib /usr/lib"
13060 need_lib_prefix=unknown
13061 hardcode_into_libs=no
13062
13063 # when you set need_version to no, make sure it does not cause -set_version
13064 # flags to be left without arguments
13065 need_version=unknown
13066
13067
13068
13069 case $host_os in
13070 aix3*)
13071 version_type=linux # correct to gnu/linux during the next big refactor
13072 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13073 shlibpath_var=LIBPATH
13074
13075 # AIX 3 has no versioning support, so we append a major version to the name.
13076 soname_spec='$libname$release$shared_ext$major'
13077 ;;
13078
13079 aix[4-9]*)
13080 version_type=linux # correct to gnu/linux during the next big refactor
13081 need_lib_prefix=no
13082 need_version=no
13083 hardcode_into_libs=yes
13084 if test ia64 = "$host_cpu"; then
13085 # AIX 5 supports IA64
13086 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13087 shlibpath_var=LD_LIBRARY_PATH
13088 else
13089 # With GCC up to 2.95.x, collect2 would create an import file
13090 # for dependence libraries. The import file would start with
13091 # the line '#! .'. This would cause the generated library to
13092 # depend on '.', always an invalid library. This was fixed in
13093 # development snapshots of GCC prior to 3.0.
13094 case $host_os in
13095 aix4 | aix4.[01] | aix4.[01].*)
13096 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13097 echo ' yes '
13098 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13099 :
13100 else
13101 can_build_shared=no
13102 fi
13103 ;;
13104 esac
13105 # Using Import Files as archive members, it is possible to support
13106 # filename-based versioning of shared library archives on AIX. While
13107 # this would work for both with and without runtime linking, it will
13108 # prevent static linking of such archives. So we do filename-based
13109 # shared library versioning with .so extension only, which is used
13110 # when both runtime linking and shared linking is enabled.
13111 # Unfortunately, runtime linking may impact performance, so we do
13112 # not want this to be the default eventually. Also, we use the
13113 # versioned .so libs for executables only if there is the -brtl
13114 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13115 # To allow for filename-based versioning support, we need to create
13116 # libNAME.so.V as an archive file, containing:
13117 # *) an Import File, referring to the versioned filename of the
13118 # archive as well as the shared archive member, telling the
13119 # bitwidth (32 or 64) of that shared object, and providing the
13120 # list of exported symbols of that shared object, eventually
13121 # decorated with the 'weak' keyword
13122 # *) the shared object with the F_LOADONLY flag set, to really avoid
13123 # it being seen by the linker.
13124 # At run time we better use the real file rather than another symlink,
13125 # but for link time we create the symlink libNAME.so -> libNAME.so.V
13126
13127 case $with_aix_soname,$aix_use_runtimelinking in
13128 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13129 # soname into executable. Probably we can add versioning support to
13130 # collect2, so additional links can be useful in future.
13131 aix,yes) # traditional libtool
13132 dynamic_linker='AIX unversionable lib.so'
13133 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13134 # instead of lib<name>.a to let people know that these are not
13135 # typical AIX shared libraries.
13136 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13137 ;;
13138 aix,no) # traditional AIX only
13139 dynamic_linker='AIX lib.a(lib.so.V)'
13140 # We preserve .a as extension for shared libraries through AIX4.2
13141 # and later when we are not doing run time linking.
13142 library_names_spec='$libname$release.a $libname.a'
13143 soname_spec='$libname$release$shared_ext$major'
13144 ;;
13145 svr4,*) # full svr4 only
13146 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13147 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13148 # We do not specify a path in Import Files, so LIBPATH fires.
13149 shlibpath_overrides_runpath=yes
13150 ;;
13151 *,yes) # both, prefer svr4
13152 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13153 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13154 # unpreferred sharedlib libNAME.a needs extra handling
13155 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"'
13156 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"'
13157 # We do not specify a path in Import Files, so LIBPATH fires.
13158 shlibpath_overrides_runpath=yes
13159 ;;
13160 *,no) # both, prefer aix
13161 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13162 library_names_spec='$libname$release.a $libname.a'
13163 soname_spec='$libname$release$shared_ext$major'
13164 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13165 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)'
13166 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"'
13167 ;;
13168 esac
13169 shlibpath_var=LIBPATH
13170 fi
13171 ;;
13172
13173 amigaos*)
13174 case $host_cpu in
13175 powerpc)
13176 # Since July 2007 AmigaOS4 officially supports .so libraries.
13177 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13178 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13179 ;;
13180 m68k)
13181 library_names_spec='$libname.ixlibrary $libname.a'
13182 # Create ${libname}_ixlibrary.a entries in /sys/libs.
13183 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'
13184 ;;
13185 esac
13186 ;;
13187
13188 beos*)
13189 library_names_spec='$libname$shared_ext'
13190 dynamic_linker="$host_os ld.so"
13191 shlibpath_var=LIBRARY_PATH
13192 ;;
13193
13194 bsdi[45]*)
13195 version_type=linux # correct to gnu/linux during the next big refactor
13196 need_version=no
13197 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13198 soname_spec='$libname$release$shared_ext$major'
13199 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13200 shlibpath_var=LD_LIBRARY_PATH
13201 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13202 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13203 # the default ld.so.conf also contains /usr/contrib/lib and
13204 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13205 # libtool to hard-code these into programs
13206 ;;
13207
13208 cygwin* | mingw* | pw32* | cegcc*)
13209 version_type=windows
13210 shrext_cmds=.dll
13211 need_version=no
13212 need_lib_prefix=no
13213
13214 case $GCC,$cc_basename in
13215 yes,*)
13216 # gcc
13217 library_names_spec='$libname.dll.a'
13218 # DLL is installed to $(libdir)/../bin by postinstall_cmds
13219 postinstall_cmds='base_file=`basename \$file`~
13220 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13221 dldir=$destdir/`dirname \$dlpath`~
13222 test -d \$dldir || mkdir -p \$dldir~
13223 $install_prog $dir/$dlname \$dldir/$dlname~
13224 chmod a+x \$dldir/$dlname~
13225 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13226 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13227 fi'
13228 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13229 dlpath=$dir/\$dldll~
13230 $RM \$dlpath'
13231 shlibpath_overrides_runpath=yes
13232
13233 case $host_os in
13234 cygwin*)
13235 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
13236 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13237
13238 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
13239 ;;
13240 mingw* | cegcc*)
13241 # MinGW DLLs use traditional 'lib' prefix
13242 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13243 ;;
13244 pw32*)
13245 # pw32 DLLs use 'pw' prefix rather than 'lib'
13246 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13247 ;;
13248 esac
13249 dynamic_linker='Win32 ld.exe'
13250 ;;
13251
13252 *,cl*)
13253 # Native MSVC
13254 libname_spec='$name'
13255 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
13256 library_names_spec='$libname.dll.lib'
13257
13258 case $build_os in
13259 mingw*)
13260 sys_lib_search_path_spec=
13261 lt_save_ifs=$IFS
13262 IFS=';'
13263 for lt_path in $LIB
13264 do
13265 IFS=$lt_save_ifs
13266 # Let DOS variable expansion print the short 8.3 style file name.
13267 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
13268 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
13269 done
13270 IFS=$lt_save_ifs
13271 # Convert to MSYS style.
13272 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
13273 ;;
13274 cygwin*)
13275 # Convert to unix form, then to dos form, then back to unix form
13276 # but this time dos style (no spaces!) so that the unix form looks
13277 # like /cygdrive/c/PROGRA~1:/cygdr...
13278 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
13279 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
13280 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13281 ;;
13282 *)
13283 sys_lib_search_path_spec=$LIB
13284 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
13285 # It is most probably a Windows format PATH.
13286 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
13287 else
13288 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
13289 fi
13290 # FIXME: find the short name or the path components, as spaces are
13291 # common. (e.g. "Program Files" -> "PROGRA~1")
13292 ;;
13293 esac
13294
13295 # DLL is installed to $(libdir)/../bin by postinstall_cmds
13296 postinstall_cmds='base_file=`basename \$file`~
13297 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
13298 dldir=$destdir/`dirname \$dlpath`~
13299 test -d \$dldir || mkdir -p \$dldir~
13300 $install_prog $dir/$dlname \$dldir/$dlname'
13301 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
13302 dlpath=$dir/\$dldll~
13303 $RM \$dlpath'
13304 shlibpath_overrides_runpath=yes
13305 dynamic_linker='Win32 link.exe'
13306 ;;
13307
13308 *)
13309 # Assume MSVC wrapper
13310 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
13311 dynamic_linker='Win32 ld.exe'
13312 ;;
13313 esac
13314 # FIXME: first we should search . and the directory the executable is in
13315 shlibpath_var=PATH
13316 ;;
13317
13318 darwin* | rhapsody*)
13319 dynamic_linker="$host_os dyld"
13320 version_type=darwin
13321 need_lib_prefix=no
13322 need_version=no
13323 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
13324 soname_spec='$libname$release$major$shared_ext'
13325 shlibpath_overrides_runpath=yes
13326 shlibpath_var=DYLD_LIBRARY_PATH
13327 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
13328
13329 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
13330 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
13331 ;;
13332
13333 dgux*)
13334 version_type=linux # correct to gnu/linux during the next big refactor
13335 need_lib_prefix=no
13336 need_version=no
13337 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13338 soname_spec='$libname$release$shared_ext$major'
13339 shlibpath_var=LD_LIBRARY_PATH
13340 ;;
13341
13342 freebsd* | dragonfly*)
13343 # DragonFly does not have aout. When/if they implement a new
13344 # versioning mechanism, adjust this.
13345 if test -x /usr/bin/objformat; then
13346 objformat=`/usr/bin/objformat`
13347 else
13348 case $host_os in
13349 freebsd[23].*) objformat=aout ;;
13350 *) objformat=elf ;;
13351 esac
13352 fi
13353 version_type=freebsd-$objformat
13354 case $version_type in
13355 freebsd-elf*)
13356 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13357 soname_spec='$libname$release$shared_ext$major'
13358 need_version=no
13359 need_lib_prefix=no
13360 ;;
13361 freebsd-*)
13362 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13363 need_version=yes
13364 ;;
13365 esac
13366 shlibpath_var=LD_LIBRARY_PATH
13367 case $host_os in
13368 freebsd2.*)
13369 shlibpath_overrides_runpath=yes
13370 ;;
13371 freebsd3.[01]* | freebsdelf3.[01]*)
13372 shlibpath_overrides_runpath=yes
13373 hardcode_into_libs=yes
13374 ;;
13375 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
13376 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
13377 shlibpath_overrides_runpath=no
13378 hardcode_into_libs=yes
13379 ;;
13380 *) # from 4.6 on, and DragonFly
13381 shlibpath_overrides_runpath=yes
13382 hardcode_into_libs=yes
13383 ;;
13384 esac
13385 ;;
13386
13387 haiku*)
13388 version_type=linux # correct to gnu/linux during the next big refactor
13389 need_lib_prefix=no
13390 need_version=no
13391 dynamic_linker="$host_os runtime_loader"
13392 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13393 soname_spec='$libname$release$shared_ext$major'
13394 shlibpath_var=LIBRARY_PATH
13395 shlibpath_overrides_runpath=no
13396 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
13397 hardcode_into_libs=yes
13398 ;;
13399
13400 hpux9* | hpux10* | hpux11*)
13401 # Give a soname corresponding to the major version so that dld.sl refuses to
13402 # link against other versions.
13403 version_type=sunos
13404 need_lib_prefix=no
13405 need_version=no
13406 case $host_cpu in
13407 ia64*)
13408 shrext_cmds='.so'
13409 hardcode_into_libs=yes
13410 dynamic_linker="$host_os dld.so"
13411 shlibpath_var=LD_LIBRARY_PATH
13412 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13413 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13414 soname_spec='$libname$release$shared_ext$major'
13415 if test 32 = "$HPUX_IA64_MODE"; then
13416 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
13417 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
13418 else
13419 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
13420 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
13421 fi
13422 ;;
13423 hppa*64*)
13424 shrext_cmds='.sl'
13425 hardcode_into_libs=yes
13426 dynamic_linker="$host_os dld.sl"
13427 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
13428 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
13429 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13430 soname_spec='$libname$release$shared_ext$major'
13431 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
13432 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13433 ;;
13434 *)
13435 shrext_cmds='.sl'
13436 dynamic_linker="$host_os dld.sl"
13437 shlibpath_var=SHLIB_PATH
13438 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
13439 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13440 soname_spec='$libname$release$shared_ext$major'
13441 ;;
13442 esac
13443 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
13444 postinstall_cmds='chmod 555 $lib'
13445 # or fails outright, so override atomically:
13446 install_override_mode=555
13447 ;;
13448
13449 interix[3-9]*)
13450 version_type=linux # correct to gnu/linux during the next big refactor
13451 need_lib_prefix=no
13452 need_version=no
13453 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13454 soname_spec='$libname$release$shared_ext$major'
13455 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
13456 shlibpath_var=LD_LIBRARY_PATH
13457 shlibpath_overrides_runpath=no
13458 hardcode_into_libs=yes
13459 ;;
13460
13461 irix5* | irix6* | nonstopux*)
13462 case $host_os in
13463 nonstopux*) version_type=nonstopux ;;
13464 *)
13465 if test yes = "$lt_cv_prog_gnu_ld"; then
13466 version_type=linux # correct to gnu/linux during the next big refactor
13467 else
13468 version_type=irix
13469 fi ;;
13470 esac
13471 need_lib_prefix=no
13472 need_version=no
13473 soname_spec='$libname$release$shared_ext$major'
13474 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
13475 case $host_os in
13476 irix5* | nonstopux*)
13477 libsuff= shlibsuff=
13478 ;;
13479 *)
13480 case $LD in # libtool.m4 will add one of these switches to LD
13481 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
13482 libsuff= shlibsuff= libmagic=32-bit;;
13483 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
13484 libsuff=32 shlibsuff=N32 libmagic=N32;;
13485 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
13486 libsuff=64 shlibsuff=64 libmagic=64-bit;;
13487 *) libsuff= shlibsuff= libmagic=never-match;;
13488 esac
13489 ;;
13490 esac
13491 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
13492 shlibpath_overrides_runpath=no
13493 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
13494 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
13495 hardcode_into_libs=yes
13496 ;;
13497
13498 # No shared lib support for Linux oldld, aout, or coff.
13499 linux*oldld* | linux*aout* | linux*coff*)
13500 dynamic_linker=no
13501 ;;
13502
13503 linux*android*)
13504 version_type=none # Android doesn't support versioned libraries.
13505 need_lib_prefix=no
13506 need_version=no
13507 library_names_spec='$libname$release$shared_ext'
13508 soname_spec='$libname$release$shared_ext'
13509 finish_cmds=
13510 shlibpath_var=LD_LIBRARY_PATH
13511 shlibpath_overrides_runpath=yes
13512
13513 # This implies no fast_install, which is unacceptable.
13514 # Some rework will be needed to allow for fast_install
13515 # before this can be enabled.
13516 hardcode_into_libs=yes
13517
13518 dynamic_linker='Android linker'
13519 # Don't embed -rpath directories since the linker doesn't support them.
13520 hardcode_libdir_flag_spec='-L$libdir'
13521 ;;
13522
13523 # This must be glibc/ELF.
13524 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
13525 version_type=linux # correct to gnu/linux during the next big refactor
13526 need_lib_prefix=no
13527 need_version=no
13528 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13529 soname_spec='$libname$release$shared_ext$major'
13530 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
13531 shlibpath_var=LD_LIBRARY_PATH
13532 shlibpath_overrides_runpath=no
13533
13534 # Some binutils ld are patched to set DT_RUNPATH
13535 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
13536 $as_echo_n "(cached) " >&6
13537 else
13538 lt_cv_shlibpath_overrides_runpath=no
13539 save_LDFLAGS=$LDFLAGS
13540 save_libdir=$libdir
13541 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
13542 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
13543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13544 /* end confdefs.h. */
13545
13546 int
13547 main ()
13548 {
13549
13550 ;
13551 return 0;
13552 }
13553 _ACEOF
13554 if ac_fn_c_try_link "$LINENO"; then :
13555 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
13556 lt_cv_shlibpath_overrides_runpath=yes
13557 fi
13558 fi
13559 rm -f core conftest.err conftest.$ac_objext \
13560 conftest$ac_exeext conftest.$ac_ext
13561 LDFLAGS=$save_LDFLAGS
13562 libdir=$save_libdir
13563
13564 fi
13565
13566 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
13567
13568 # This implies no fast_install, which is unacceptable.
13569 # Some rework will be needed to allow for fast_install
13570 # before this can be enabled.
13571 hardcode_into_libs=yes
13572
13573 # Ideally, we could use ldconfig to report *all* directores which are
13574 # searched for libraries, however this is still not possible. Aside from not
13575 # being certain /sbin/ldconfig is available, command
13576 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
13577 # even though it is searched at run-time. Try to do the best guess by
13578 # appending ld.so.conf contents (and includes) to the search path.
13579 if test -f /etc/ld.so.conf; then
13580 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' ' '`
13581 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
13582 fi
13583
13584 # We used to test for /lib/ld.so.1 and disable shared libraries on
13585 # powerpc, because MkLinux only supported shared libraries with the
13586 # GNU dynamic linker. Since this was broken with cross compilers,
13587 # most powerpc-linux boxes support dynamic linking these days and
13588 # people can always --disable-shared, the test was removed, and we
13589 # assume the GNU/Linux dynamic linker is in use.
13590 dynamic_linker='GNU/Linux ld.so'
13591 ;;
13592
13593 netbsdelf*-gnu)
13594 version_type=linux
13595 need_lib_prefix=no
13596 need_version=no
13597 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
13598 soname_spec='${libname}${release}${shared_ext}$major'
13599 shlibpath_var=LD_LIBRARY_PATH
13600 shlibpath_overrides_runpath=no
13601 hardcode_into_libs=yes
13602 dynamic_linker='NetBSD ld.elf_so'
13603 ;;
13604
13605 netbsd*)
13606 version_type=sunos
13607 need_lib_prefix=no
13608 need_version=no
13609 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13610 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13611 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13612 dynamic_linker='NetBSD (a.out) ld.so'
13613 else
13614 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13615 soname_spec='$libname$release$shared_ext$major'
13616 dynamic_linker='NetBSD ld.elf_so'
13617 fi
13618 shlibpath_var=LD_LIBRARY_PATH
13619 shlibpath_overrides_runpath=yes
13620 hardcode_into_libs=yes
13621 ;;
13622
13623 newsos6)
13624 version_type=linux # correct to gnu/linux during the next big refactor
13625 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13626 shlibpath_var=LD_LIBRARY_PATH
13627 shlibpath_overrides_runpath=yes
13628 ;;
13629
13630 *nto* | *qnx*)
13631 version_type=qnx
13632 need_lib_prefix=no
13633 need_version=no
13634 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13635 soname_spec='$libname$release$shared_ext$major'
13636 shlibpath_var=LD_LIBRARY_PATH
13637 shlibpath_overrides_runpath=no
13638 hardcode_into_libs=yes
13639 dynamic_linker='ldqnx.so'
13640 ;;
13641
13642 openbsd* | bitrig*)
13643 version_type=sunos
13644 sys_lib_dlsearch_path_spec=/usr/lib
13645 need_lib_prefix=no
13646 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13647 need_version=no
13648 else
13649 need_version=yes
13650 fi
13651 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13652 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
13653 shlibpath_var=LD_LIBRARY_PATH
13654 shlibpath_overrides_runpath=yes
13655 ;;
13656
13657 os2*)
13658 libname_spec='$name'
13659 version_type=windows
13660 shrext_cmds=.dll
13661 need_version=no
13662 need_lib_prefix=no
13663 # OS/2 can only load a DLL with a base name of 8 characters or less.
13664 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
13665 v=$($ECHO $release$versuffix | tr -d .-);
13666 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
13667 $ECHO $n$v`$shared_ext'
13668 library_names_spec='${libname}_dll.$libext'
13669 dynamic_linker='OS/2 ld.exe'
13670 shlibpath_var=BEGINLIBPATH
13671 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13672 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13673 postinstall_cmds='base_file=`basename \$file`~
13674 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
13675 dldir=$destdir/`dirname \$dlpath`~
13676 test -d \$dldir || mkdir -p \$dldir~
13677 $install_prog $dir/$dlname \$dldir/$dlname~
13678 chmod a+x \$dldir/$dlname~
13679 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
13680 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
13681 fi'
13682 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
13683 dlpath=$dir/\$dldll~
13684 $RM \$dlpath'
13685 ;;
13686
13687 osf3* | osf4* | osf5*)
13688 version_type=osf
13689 need_lib_prefix=no
13690 need_version=no
13691 soname_spec='$libname$release$shared_ext$major'
13692 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13693 shlibpath_var=LD_LIBRARY_PATH
13694 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
13695 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
13696 ;;
13697
13698 rdos*)
13699 dynamic_linker=no
13700 ;;
13701
13702 solaris*)
13703 version_type=linux # correct to gnu/linux during the next big refactor
13704 need_lib_prefix=no
13705 need_version=no
13706 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13707 soname_spec='$libname$release$shared_ext$major'
13708 shlibpath_var=LD_LIBRARY_PATH
13709 shlibpath_overrides_runpath=yes
13710 hardcode_into_libs=yes
13711 # ldd complains unless libraries are executable
13712 postinstall_cmds='chmod +x $lib'
13713 ;;
13714
13715 sunos4*)
13716 version_type=sunos
13717 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
13718 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
13719 shlibpath_var=LD_LIBRARY_PATH
13720 shlibpath_overrides_runpath=yes
13721 if test yes = "$with_gnu_ld"; then
13722 need_lib_prefix=no
13723 fi
13724 need_version=yes
13725 ;;
13726
13727 sysv4 | sysv4.3*)
13728 version_type=linux # correct to gnu/linux during the next big refactor
13729 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13730 soname_spec='$libname$release$shared_ext$major'
13731 shlibpath_var=LD_LIBRARY_PATH
13732 case $host_vendor in
13733 sni)
13734 shlibpath_overrides_runpath=no
13735 need_lib_prefix=no
13736 runpath_var=LD_RUN_PATH
13737 ;;
13738 siemens)
13739 need_lib_prefix=no
13740 ;;
13741 motorola)
13742 need_lib_prefix=no
13743 need_version=no
13744 shlibpath_overrides_runpath=no
13745 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
13746 ;;
13747 esac
13748 ;;
13749
13750 sysv4*MP*)
13751 if test -d /usr/nec; then
13752 version_type=linux # correct to gnu/linux during the next big refactor
13753 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
13754 soname_spec='$libname$shared_ext.$major'
13755 shlibpath_var=LD_LIBRARY_PATH
13756 fi
13757 ;;
13758
13759 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
13760 version_type=sco
13761 need_lib_prefix=no
13762 need_version=no
13763 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
13764 soname_spec='$libname$release$shared_ext$major'
13765 shlibpath_var=LD_LIBRARY_PATH
13766 shlibpath_overrides_runpath=yes
13767 hardcode_into_libs=yes
13768 if test yes = "$with_gnu_ld"; then
13769 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
13770 else
13771 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
13772 case $host_os in
13773 sco3.2v5*)
13774 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
13775 ;;
13776 esac
13777 fi
13778 sys_lib_dlsearch_path_spec='/usr/lib'
13779 ;;
13780
13781 tpf*)
13782 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
13783 version_type=linux # correct to gnu/linux during the next big refactor
13784 need_lib_prefix=no
13785 need_version=no
13786 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13787 shlibpath_var=LD_LIBRARY_PATH
13788 shlibpath_overrides_runpath=no
13789 hardcode_into_libs=yes
13790 ;;
13791
13792 uts4*)
13793 version_type=linux # correct to gnu/linux during the next big refactor
13794 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13795 soname_spec='$libname$release$shared_ext$major'
13796 shlibpath_var=LD_LIBRARY_PATH
13797 ;;
13798
13799 *)
13800 dynamic_linker=no
13801 ;;
13802 esac
13803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
13804 $as_echo "$dynamic_linker" >&6; }
13805 test no = "$dynamic_linker" && can_build_shared=no
13806
13807 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
13808 if test yes = "$GCC"; then
13809 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
13810 fi
13811
13812 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
13813 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
13814 fi
13815
13816 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
13817 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
13818 fi
13819
13820 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
13821 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
13822
13823 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
13824 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
13825
13826 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
13827 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
13828
13829
13830
13831
13832
13833
13834
13835
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905
13906
13907
13908
13909
13910
13911
13912
13913
13914
13915
13916
13917
13918
13919
13920
13921
13922
13923
13924
13925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
13926 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
13927 hardcode_action=
13928 if test -n "$hardcode_libdir_flag_spec" ||
13929 test -n "$runpath_var" ||
13930 test yes = "$hardcode_automatic"; then
13931
13932 # We can hardcode non-existent directories.
13933 if test no != "$hardcode_direct" &&
13934 # If the only mechanism to avoid hardcoding is shlibpath_var, we
13935 # have to relink, otherwise we might link with an installed library
13936 # when we should be linking with a yet-to-be-installed one
13937 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
13938 test no != "$hardcode_minus_L"; then
13939 # Linking always hardcodes the temporary library directory.
13940 hardcode_action=relink
13941 else
13942 # We can link without hardcoding, and we can hardcode nonexisting dirs.
13943 hardcode_action=immediate
13944 fi
13945 else
13946 # We cannot hardcode anything, or else we can only hardcode existing
13947 # directories.
13948 hardcode_action=unsupported
13949 fi
13950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
13951 $as_echo "$hardcode_action" >&6; }
13952
13953 if test relink = "$hardcode_action" ||
13954 test yes = "$inherit_rpath"; then
13955 # Fast installation is not supported
13956 enable_fast_install=no
13957 elif test yes = "$shlibpath_overrides_runpath" ||
13958 test no = "$enable_shared"; then
13959 # Fast installation is not necessary
13960 enable_fast_install=needless
13961 fi
13962
13963
13964
13965
13966
13967
13968 if test yes != "$enable_dlopen"; then
13969 enable_dlopen=unknown
13970 enable_dlopen_self=unknown
13971 enable_dlopen_self_static=unknown
13972 else
13973 lt_cv_dlopen=no
13974 lt_cv_dlopen_libs=
13975
13976 case $host_os in
13977 beos*)
13978 lt_cv_dlopen=load_add_on
13979 lt_cv_dlopen_libs=
13980 lt_cv_dlopen_self=yes
13981 ;;
13982
13983 mingw* | pw32* | cegcc*)
13984 lt_cv_dlopen=LoadLibrary
13985 lt_cv_dlopen_libs=
13986 ;;
13987
13988 cygwin*)
13989 lt_cv_dlopen=dlopen
13990 lt_cv_dlopen_libs=
13991 ;;
13992
13993 darwin*)
13994 # if libdl is installed we need to link against it
13995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13996 $as_echo_n "checking for dlopen in -ldl... " >&6; }
13997 if ${ac_cv_lib_dl_dlopen+:} false; then :
13998 $as_echo_n "(cached) " >&6
13999 else
14000 ac_check_lib_save_LIBS=$LIBS
14001 LIBS="-ldl $LIBS"
14002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14003 /* end confdefs.h. */
14004
14005 /* Override any GCC internal prototype to avoid an error.
14006 Use char because int might match the return type of a GCC
14007 builtin and then its argument prototype would still apply. */
14008 #ifdef __cplusplus
14009 extern "C"
14010 #endif
14011 char dlopen ();
14012 int
14013 main ()
14014 {
14015 return dlopen ();
14016 ;
14017 return 0;
14018 }
14019 _ACEOF
14020 if ac_fn_c_try_link "$LINENO"; then :
14021 ac_cv_lib_dl_dlopen=yes
14022 else
14023 ac_cv_lib_dl_dlopen=no
14024 fi
14025 rm -f core conftest.err conftest.$ac_objext \
14026 conftest$ac_exeext conftest.$ac_ext
14027 LIBS=$ac_check_lib_save_LIBS
14028 fi
14029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14030 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14031 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14032 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14033 else
14034
14035 lt_cv_dlopen=dyld
14036 lt_cv_dlopen_libs=
14037 lt_cv_dlopen_self=yes
14038
14039 fi
14040
14041 ;;
14042
14043 tpf*)
14044 # Don't try to run any link tests for TPF. We know it's impossible
14045 # because TPF is a cross-compiler, and we know how we open DSOs.
14046 lt_cv_dlopen=dlopen
14047 lt_cv_dlopen_libs=
14048 lt_cv_dlopen_self=no
14049 ;;
14050
14051 *)
14052 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14053 if test "x$ac_cv_func_shl_load" = xyes; then :
14054 lt_cv_dlopen=shl_load
14055 else
14056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14057 $as_echo_n "checking for shl_load in -ldld... " >&6; }
14058 if ${ac_cv_lib_dld_shl_load+:} false; then :
14059 $as_echo_n "(cached) " >&6
14060 else
14061 ac_check_lib_save_LIBS=$LIBS
14062 LIBS="-ldld $LIBS"
14063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14064 /* end confdefs.h. */
14065
14066 /* Override any GCC internal prototype to avoid an error.
14067 Use char because int might match the return type of a GCC
14068 builtin and then its argument prototype would still apply. */
14069 #ifdef __cplusplus
14070 extern "C"
14071 #endif
14072 char shl_load ();
14073 int
14074 main ()
14075 {
14076 return shl_load ();
14077 ;
14078 return 0;
14079 }
14080 _ACEOF
14081 if ac_fn_c_try_link "$LINENO"; then :
14082 ac_cv_lib_dld_shl_load=yes
14083 else
14084 ac_cv_lib_dld_shl_load=no
14085 fi
14086 rm -f core conftest.err conftest.$ac_objext \
14087 conftest$ac_exeext conftest.$ac_ext
14088 LIBS=$ac_check_lib_save_LIBS
14089 fi
14090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14091 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14092 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14093 lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14094 else
14095 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14096 if test "x$ac_cv_func_dlopen" = xyes; then :
14097 lt_cv_dlopen=dlopen
14098 else
14099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14100 $as_echo_n "checking for dlopen in -ldl... " >&6; }
14101 if ${ac_cv_lib_dl_dlopen+:} false; then :
14102 $as_echo_n "(cached) " >&6
14103 else
14104 ac_check_lib_save_LIBS=$LIBS
14105 LIBS="-ldl $LIBS"
14106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14107 /* end confdefs.h. */
14108
14109 /* Override any GCC internal prototype to avoid an error.
14110 Use char because int might match the return type of a GCC
14111 builtin and then its argument prototype would still apply. */
14112 #ifdef __cplusplus
14113 extern "C"
14114 #endif
14115 char dlopen ();
14116 int
14117 main ()
14118 {
14119 return dlopen ();
14120 ;
14121 return 0;
14122 }
14123 _ACEOF
14124 if ac_fn_c_try_link "$LINENO"; then :
14125 ac_cv_lib_dl_dlopen=yes
14126 else
14127 ac_cv_lib_dl_dlopen=no
14128 fi
14129 rm -f core conftest.err conftest.$ac_objext \
14130 conftest$ac_exeext conftest.$ac_ext
14131 LIBS=$ac_check_lib_save_LIBS
14132 fi
14133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14134 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14135 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14136 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14137 else
14138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14139 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
14140 if ${ac_cv_lib_svld_dlopen+:} false; then :
14141 $as_echo_n "(cached) " >&6
14142 else
14143 ac_check_lib_save_LIBS=$LIBS
14144 LIBS="-lsvld $LIBS"
14145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14146 /* end confdefs.h. */
14147
14148 /* Override any GCC internal prototype to avoid an error.
14149 Use char because int might match the return type of a GCC
14150 builtin and then its argument prototype would still apply. */
14151 #ifdef __cplusplus
14152 extern "C"
14153 #endif
14154 char dlopen ();
14155 int
14156 main ()
14157 {
14158 return dlopen ();
14159 ;
14160 return 0;
14161 }
14162 _ACEOF
14163 if ac_fn_c_try_link "$LINENO"; then :
14164 ac_cv_lib_svld_dlopen=yes
14165 else
14166 ac_cv_lib_svld_dlopen=no
14167 fi
14168 rm -f core conftest.err conftest.$ac_objext \
14169 conftest$ac_exeext conftest.$ac_ext
14170 LIBS=$ac_check_lib_save_LIBS
14171 fi
14172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14173 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14174 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14175 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14176 else
14177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14178 $as_echo_n "checking for dld_link in -ldld... " >&6; }
14179 if ${ac_cv_lib_dld_dld_link+:} false; then :
14180 $as_echo_n "(cached) " >&6
14181 else
14182 ac_check_lib_save_LIBS=$LIBS
14183 LIBS="-ldld $LIBS"
14184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14185 /* end confdefs.h. */
14186
14187 /* Override any GCC internal prototype to avoid an error.
14188 Use char because int might match the return type of a GCC
14189 builtin and then its argument prototype would still apply. */
14190 #ifdef __cplusplus
14191 extern "C"
14192 #endif
14193 char dld_link ();
14194 int
14195 main ()
14196 {
14197 return dld_link ();
14198 ;
14199 return 0;
14200 }
14201 _ACEOF
14202 if ac_fn_c_try_link "$LINENO"; then :
14203 ac_cv_lib_dld_dld_link=yes
14204 else
14205 ac_cv_lib_dld_dld_link=no
14206 fi
14207 rm -f core conftest.err conftest.$ac_objext \
14208 conftest$ac_exeext conftest.$ac_ext
14209 LIBS=$ac_check_lib_save_LIBS
14210 fi
14211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14212 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14213 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14214 lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14215 fi
14216
14217
14218 fi
14219
14220
14221 fi
14222
14223
14224 fi
14225
14226
14227 fi
14228
14229
14230 fi
14231
14232 ;;
14233 esac
14234
14235 if test no = "$lt_cv_dlopen"; then
14236 enable_dlopen=no
14237 else
14238 enable_dlopen=yes
14239 fi
14240
14241 case $lt_cv_dlopen in
14242 dlopen)
14243 save_CPPFLAGS=$CPPFLAGS
14244 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
14245
14246 save_LDFLAGS=$LDFLAGS
14247 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
14248
14249 save_LIBS=$LIBS
14250 LIBS="$lt_cv_dlopen_libs $LIBS"
14251
14252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
14253 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
14254 if ${lt_cv_dlopen_self+:} false; then :
14255 $as_echo_n "(cached) " >&6
14256 else
14257 if test yes = "$cross_compiling"; then :
14258 lt_cv_dlopen_self=cross
14259 else
14260 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14261 lt_status=$lt_dlunknown
14262 cat > conftest.$ac_ext <<_LT_EOF
14263 #line $LINENO "configure"
14264 #include "confdefs.h"
14265
14266 #if HAVE_DLFCN_H
14267 #include <dlfcn.h>
14268 #endif
14269
14270 #include <stdio.h>
14271
14272 #ifdef RTLD_GLOBAL
14273 # define LT_DLGLOBAL RTLD_GLOBAL
14274 #else
14275 # ifdef DL_GLOBAL
14276 # define LT_DLGLOBAL DL_GLOBAL
14277 # else
14278 # define LT_DLGLOBAL 0
14279 # endif
14280 #endif
14281
14282 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14283 find out it does not work in some platform. */
14284 #ifndef LT_DLLAZY_OR_NOW
14285 # ifdef RTLD_LAZY
14286 # define LT_DLLAZY_OR_NOW RTLD_LAZY
14287 # else
14288 # ifdef DL_LAZY
14289 # define LT_DLLAZY_OR_NOW DL_LAZY
14290 # else
14291 # ifdef RTLD_NOW
14292 # define LT_DLLAZY_OR_NOW RTLD_NOW
14293 # else
14294 # ifdef DL_NOW
14295 # define LT_DLLAZY_OR_NOW DL_NOW
14296 # else
14297 # define LT_DLLAZY_OR_NOW 0
14298 # endif
14299 # endif
14300 # endif
14301 # endif
14302 #endif
14303
14304 /* When -fvisibility=hidden is used, assume the code has been annotated
14305 correspondingly for the symbols needed. */
14306 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14307 int fnord () __attribute__((visibility("default")));
14308 #endif
14309
14310 int fnord () { return 42; }
14311 int main ()
14312 {
14313 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14314 int status = $lt_dlunknown;
14315
14316 if (self)
14317 {
14318 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
14319 else
14320 {
14321 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
14322 else puts (dlerror ());
14323 }
14324 /* dlclose (self); */
14325 }
14326 else
14327 puts (dlerror ());
14328
14329 return status;
14330 }
14331 _LT_EOF
14332 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14333 (eval $ac_link) 2>&5
14334 ac_status=$?
14335 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14336 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14337 (./conftest; exit; ) >&5 2>/dev/null
14338 lt_status=$?
14339 case x$lt_status in
14340 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
14341 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
14342 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
14343 esac
14344 else :
14345 # compilation failed
14346 lt_cv_dlopen_self=no
14347 fi
14348 fi
14349 rm -fr conftest*
14350
14351
14352 fi
14353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
14354 $as_echo "$lt_cv_dlopen_self" >&6; }
14355
14356 if test yes = "$lt_cv_dlopen_self"; then
14357 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
14358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
14359 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
14360 if ${lt_cv_dlopen_self_static+:} false; then :
14361 $as_echo_n "(cached) " >&6
14362 else
14363 if test yes = "$cross_compiling"; then :
14364 lt_cv_dlopen_self_static=cross
14365 else
14366 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
14367 lt_status=$lt_dlunknown
14368 cat > conftest.$ac_ext <<_LT_EOF
14369 #line $LINENO "configure"
14370 #include "confdefs.h"
14371
14372 #if HAVE_DLFCN_H
14373 #include <dlfcn.h>
14374 #endif
14375
14376 #include <stdio.h>
14377
14378 #ifdef RTLD_GLOBAL
14379 # define LT_DLGLOBAL RTLD_GLOBAL
14380 #else
14381 # ifdef DL_GLOBAL
14382 # define LT_DLGLOBAL DL_GLOBAL
14383 # else
14384 # define LT_DLGLOBAL 0
14385 # endif
14386 #endif
14387
14388 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
14389 find out it does not work in some platform. */
14390 #ifndef LT_DLLAZY_OR_NOW
14391 # ifdef RTLD_LAZY
14392 # define LT_DLLAZY_OR_NOW RTLD_LAZY
14393 # else
14394 # ifdef DL_LAZY
14395 # define LT_DLLAZY_OR_NOW DL_LAZY
14396 # else
14397 # ifdef RTLD_NOW
14398 # define LT_DLLAZY_OR_NOW RTLD_NOW
14399 # else
14400 # ifdef DL_NOW
14401 # define LT_DLLAZY_OR_NOW DL_NOW
14402 # else
14403 # define LT_DLLAZY_OR_NOW 0
14404 # endif
14405 # endif
14406 # endif
14407 # endif
14408 #endif
14409
14410 /* When -fvisibility=hidden is used, assume the code has been annotated
14411 correspondingly for the symbols needed. */
14412 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
14413 int fnord () __attribute__((visibility("default")));
14414 #endif
14415
14416 int fnord () { return 42; }
14417 int main ()
14418 {
14419 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
14420 int status = $lt_dlunknown;
14421
14422 if (self)
14423 {
14424 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
14425 else
14426 {
14427 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
14428 else puts (dlerror ());
14429 }
14430 /* dlclose (self); */
14431 }
14432 else
14433 puts (dlerror ());
14434
14435 return status;
14436 }
14437 _LT_EOF
14438 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
14439 (eval $ac_link) 2>&5
14440 ac_status=$?
14441 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14442 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
14443 (./conftest; exit; ) >&5 2>/dev/null
14444 lt_status=$?
14445 case x$lt_status in
14446 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
14447 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
14448 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
14449 esac
14450 else :
14451 # compilation failed
14452 lt_cv_dlopen_self_static=no
14453 fi
14454 fi
14455 rm -fr conftest*
14456
14457
14458 fi
14459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
14460 $as_echo "$lt_cv_dlopen_self_static" >&6; }
14461 fi
14462
14463 CPPFLAGS=$save_CPPFLAGS
14464 LDFLAGS=$save_LDFLAGS
14465 LIBS=$save_LIBS
14466 ;;
14467 esac
14468
14469 case $lt_cv_dlopen_self in
14470 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
14471 *) enable_dlopen_self=unknown ;;
14472 esac
14473
14474 case $lt_cv_dlopen_self_static in
14475 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
14476 *) enable_dlopen_self_static=unknown ;;
14477 esac
14478 fi
14479
14480
14481
14482
14483
14484
14485
14486
14487
14488
14489
14490
14491
14492
14493
14494
14495
14496 striplib=
14497 old_striplib=
14498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
14499 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
14500 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
14501 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
14502 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
14503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14504 $as_echo "yes" >&6; }
14505 else
14506 # FIXME - insert some real tests, host_os isn't really good enough
14507 case $host_os in
14508 darwin*)
14509 if test -n "$STRIP"; then
14510 striplib="$STRIP -x"
14511 old_striplib="$STRIP -S"
14512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14513 $as_echo "yes" >&6; }
14514 else
14515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14516 $as_echo "no" >&6; }
14517 fi
14518 ;;
14519 *)
14520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14521 $as_echo "no" >&6; }
14522 ;;
14523 esac
14524 fi
14525
14526
14527
14528
14529
14530
14531
14532
14533
14534
14535
14536
14537 # Report what library types will actually be built
14538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
14539 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
14540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
14541 $as_echo "$can_build_shared" >&6; }
14542
14543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
14544 $as_echo_n "checking whether to build shared libraries... " >&6; }
14545 test no = "$can_build_shared" && enable_shared=no
14546
14547 # On AIX, shared libraries and static libraries use the same namespace, and
14548 # are all built from PIC.
14549 case $host_os in
14550 aix3*)
14551 test yes = "$enable_shared" && enable_static=no
14552 if test -n "$RANLIB"; then
14553 archive_cmds="$archive_cmds~\$RANLIB \$lib"
14554 postinstall_cmds='$RANLIB $lib'
14555 fi
14556 ;;
14557
14558 aix[4-9]*)
14559 if test ia64 != "$host_cpu"; then
14560 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
14561 yes,aix,yes) ;; # shared object as lib.so file only
14562 yes,svr4,*) ;; # shared object as lib.so archive member only
14563 yes,*) enable_static=no ;; # shared object in lib.a archive as well
14564 esac
14565 fi
14566 ;;
14567 esac
14568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
14569 $as_echo "$enable_shared" >&6; }
14570
14571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
14572 $as_echo_n "checking whether to build static libraries... " >&6; }
14573 # Make sure either enable_shared or enable_static is yes.
14574 test yes = "$enable_shared" || enable_static=yes
14575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
14576 $as_echo "$enable_static" >&6; }
14577
14578
14579
14580
14581 fi
14582 ac_ext=c
14583 ac_cpp='$CPP $CPPFLAGS'
14584 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14585 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14586 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14587
14588 CC=$lt_save_CC
14589
14590
14591
14592
14593
14594
14595
14596
14597
14598
14599
14600
14601
14602
14603
14604 ac_config_commands="$ac_config_commands libtool"
14605
14606
14607
14608
14609 # Only expand once:
14610
14611
14612
14613
14614
14615
14616
14617
14618
14619
14620
14621 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
14622 if test -n "$ac_tool_prefix"; then
14623 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
14624 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
14625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14626 $as_echo_n "checking for $ac_word... " >&6; }
14627 if ${ac_cv_path_PKG_CONFIG+:} false; then :
14628 $as_echo_n "(cached) " >&6
14629 else
14630 case $PKG_CONFIG in
14631 [\\/]* | ?:[\\/]*)
14632 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
14633 ;;
14634 *)
14635 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14636 for as_dir in $PATH
14637 do
14638 IFS=$as_save_IFS
14639 test -z "$as_dir" && as_dir=.
14640 for ac_exec_ext in '' $ac_executable_extensions; do
14641 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14642 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14643 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14644 break 2
14645 fi
14646 done
14647 done
14648 IFS=$as_save_IFS
14649
14650 ;;
14651 esac
14652 fi
14653 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
14654 if test -n "$PKG_CONFIG"; then
14655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
14656 $as_echo "$PKG_CONFIG" >&6; }
14657 else
14658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14659 $as_echo "no" >&6; }
14660 fi
14661
14662
14663 fi
14664 if test -z "$ac_cv_path_PKG_CONFIG"; then
14665 ac_pt_PKG_CONFIG=$PKG_CONFIG
14666 # Extract the first word of "pkg-config", so it can be a program name with args.
14667 set dummy pkg-config; ac_word=$2
14668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14669 $as_echo_n "checking for $ac_word... " >&6; }
14670 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
14671 $as_echo_n "(cached) " >&6
14672 else
14673 case $ac_pt_PKG_CONFIG in
14674 [\\/]* | ?:[\\/]*)
14675 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
14676 ;;
14677 *)
14678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14679 for as_dir in $PATH
14680 do
14681 IFS=$as_save_IFS
14682 test -z "$as_dir" && as_dir=.
14683 for ac_exec_ext in '' $ac_executable_extensions; do
14684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14685 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
14686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14687 break 2
14688 fi
14689 done
14690 done
14691 IFS=$as_save_IFS
14692
14693 ;;
14694 esac
14695 fi
14696 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
14697 if test -n "$ac_pt_PKG_CONFIG"; then
14698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
14699 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
14700 else
14701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14702 $as_echo "no" >&6; }
14703 fi
14704
14705 if test "x$ac_pt_PKG_CONFIG" = x; then
14706 PKG_CONFIG=""
14707 else
14708 case $cross_compiling:$ac_tool_warned in
14709 yes:)
14710 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
14711 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
14712 ac_tool_warned=yes ;;
14713 esac
14714 PKG_CONFIG=$ac_pt_PKG_CONFIG
14715 fi
14716 else
14717 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
14718 fi
14719
14720 fi
14721 if test -n "$PKG_CONFIG"; then
14722 _pkg_min_version=0.9.0
14723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
14724 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
14725 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
14726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14727 $as_echo "yes" >&6; }
14728 else
14729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14730 $as_echo "no" >&6; }
14731 PKG_CONFIG=""
14732 fi
14733 fi
14734
14735 # Checks for header files.
14736 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/endian.h libkern/OSByteOrder.h sys/ipc.h sys/shm.h
14737 do :
14738 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14739 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
14740 "
14741 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14742 cat >>confdefs.h <<_ACEOF
14743 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14744 _ACEOF
14745
14746 fi
14747
14748 done
14749
14750
14751 # check for types.
14752 # Using own tests for int64* because autoconf builtin only give 32bit.
14753 ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
14754 if test "x$ac_cv_type_int8_t" = xyes; then :
14755
14756 else
14757
14758 cat >>confdefs.h <<_ACEOF
14759 #define int8_t signed char
14760 _ACEOF
14761
14762 fi
14763
14764 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
14765 if test "x$ac_cv_type_int16_t" = xyes; then :
14766
14767 else
14768
14769 cat >>confdefs.h <<_ACEOF
14770 #define int16_t short
14771 _ACEOF
14772
14773 fi
14774
14775 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
14776 if test "x$ac_cv_type_int32_t" = xyes; then :
14777
14778 else
14779
14780 cat >>confdefs.h <<_ACEOF
14781 #define int32_t int
14782 _ACEOF
14783
14784 fi
14785
14786 ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
14787 if test "x$ac_cv_type_int64_t" = xyes; then :
14788
14789 else
14790
14791 cat >>confdefs.h <<_ACEOF
14792 #define int64_t long long
14793 _ACEOF
14794
14795 fi
14796
14797 ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
14798 if test "x$ac_cv_type_uint8_t" = xyes; then :
14799
14800 else
14801
14802 cat >>confdefs.h <<_ACEOF
14803 #define uint8_t unsigned char
14804 _ACEOF
14805
14806 fi
14807
14808 ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
14809 if test "x$ac_cv_type_uint16_t" = xyes; then :
14810
14811 else
14812
14813 cat >>confdefs.h <<_ACEOF
14814 #define uint16_t unsigned short
14815 _ACEOF
14816
14817 fi
14818
14819 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
14820 if test "x$ac_cv_type_uint32_t" = xyes; then :
14821
14822 else
14823
14824 cat >>confdefs.h <<_ACEOF
14825 #define uint32_t unsigned int
14826 _ACEOF
14827
14828 fi
14829
14830 ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
14831 if test "x$ac_cv_type_uint64_t" = xyes; then :
14832
14833 else
14834
14835 cat >>confdefs.h <<_ACEOF
14836 #define uint64_t unsigned long long
14837 _ACEOF
14838
14839 fi
14840
14841 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
14842 if test "x$ac_cv_type_size_t" = xyes; then :
14843
14844 else
14845
14846 cat >>confdefs.h <<_ACEOF
14847 #define size_t unsigned int
14848 _ACEOF
14849
14850 fi
14851
14852 ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
14853 if test "x$ac_cv_type_ssize_t" = xyes; then :
14854
14855 else
14856
14857 cat >>confdefs.h <<_ACEOF
14858 #define ssize_t int
14859 _ACEOF
14860
14861 fi
14862
14863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
14864 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
14865 if ${ac_cv_type_uid_t+:} false; then :
14866 $as_echo_n "(cached) " >&6
14867 else
14868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14869 /* end confdefs.h. */
14870 #include <sys/types.h>
14871
14872 _ACEOF
14873 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14874 $EGREP "uid_t" >/dev/null 2>&1; then :
14875 ac_cv_type_uid_t=yes
14876 else
14877 ac_cv_type_uid_t=no
14878 fi
14879 rm -f conftest*
14880
14881 fi
14882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
14883 $as_echo "$ac_cv_type_uid_t" >&6; }
14884 if test $ac_cv_type_uid_t = no; then
14885
14886 $as_echo "#define uid_t int" >>confdefs.h
14887
14888
14889 $as_echo "#define gid_t int" >>confdefs.h
14890
14891 fi
14892
14893 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14894 if test "x$ac_cv_type_pid_t" = xyes; then :
14895
14896 else
14897
14898 cat >>confdefs.h <<_ACEOF
14899 #define pid_t int
14900 _ACEOF
14901
14902 fi
14903
14904 ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
14905 if test "x$ac_cv_type_off_t" = xyes; then :
14906
14907 else
14908
14909 cat >>confdefs.h <<_ACEOF
14910 #define off_t long int
14911 _ACEOF
14912
14913 fi
14914
14915 ac_fn_c_check_type "$LINENO" "u_char" "ac_cv_type_u_char" "
14916 $ac_includes_default
14917 #ifdef HAVE_WINSOCK2_H
14918 # include <winsock2.h>
14919 #endif
14920
14921 "
14922 if test "x$ac_cv_type_u_char" = xyes; then :
14923
14924 else
14925
14926 $as_echo "#define u_char unsigned char" >>confdefs.h
14927
14928 fi
14929
14930 ac_fn_c_check_type "$LINENO" "rlim_t" "ac_cv_type_rlim_t" "
14931 $ac_includes_default
14932 #ifdef HAVE_SYS_RESOURCE_H
14933 # include <sys/resource.h>
14934 #endif
14935
14936 "
14937 if test "x$ac_cv_type_rlim_t" = xyes; then :
14938
14939 else
14940
14941 $as_echo "#define rlim_t unsigned long" >>confdefs.h
14942
14943 fi
14944
14945
14946 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
14947 $ac_includes_default
14948 #ifdef HAVE_SYS_SOCKET_H
14949 # include <sys/socket.h>
14950 #endif
14951 #ifdef HAVE_WS2TCPIP_H
14952 # include <ws2tcpip.h>
14953 #endif
14954
14955 "
14956 if test "x$ac_cv_type_socklen_t" = xyes; then :
14957
14958 else
14959
14960 $as_echo "#define socklen_t int" >>confdefs.h
14961
14962 fi
14963
14964 ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
14965 $ac_includes_default
14966 #ifdef HAVE_SYS_TYPES_H
14967 # include <sys/types.h>
14968 #endif
14969 #ifdef HAVE_NETINET_IN_H
14970 # include <netinet/in.h>
14971 #endif
14972
14973 "
14974 if test "x$ac_cv_type_in_addr_t" = xyes; then :
14975
14976 else
14977
14978 $as_echo "#define in_addr_t uint32_t" >>confdefs.h
14979
14980 fi
14981
14982 ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "
14983 $ac_includes_default
14984 #ifdef HAVE_SYS_TYPES_H
14985 # include <sys/types.h>
14986 #endif
14987 #ifdef HAVE_NETINET_IN_H
14988 # include <netinet/in.h>
14989 #endif
14990
14991 "
14992 if test "x$ac_cv_type_in_port_t" = xyes; then :
14993
14994 else
14995
14996 $as_echo "#define in_port_t uint16_t" >>confdefs.h
14997
14998 fi
14999
15000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memcmp compares unsigned" >&5
15001 $as_echo_n "checking if memcmp compares unsigned... " >&6; }
15002 if test "$cross_compiling" = yes; then :
15003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile no" >&5
15004 $as_echo "cross-compile no" >&6; }
15005
15006 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15007
15008 case " $LIBOBJS " in
15009 *" memcmp.$ac_objext "* ) ;;
15010 *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15011 ;;
15012 esac
15013
15014
15015 else
15016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15017 /* end confdefs.h. */
15018
15019 #include <stdio.h>
15020 #include <stdlib.h>
15021 #include <string.h>
15022 int main(void)
15023 {
15024 char a = 255, b = 0;
15025 if(memcmp(&a, &b, 1) < 0)
15026 return 1;
15027 return 0;
15028 }
15029
15030 _ACEOF
15031 if ac_fn_c_try_run "$LINENO"; then :
15032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15033 $as_echo "yes" >&6; }
15034 else
15035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15036 $as_echo "no" >&6; }
15037
15038 $as_echo "#define MEMCMP_IS_BROKEN 1" >>confdefs.h
15039
15040 case " $LIBOBJS " in
15041 *" memcmp.$ac_objext "* ) ;;
15042 *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
15043 ;;
15044 esac
15045
15046
15047 fi
15048 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15049 conftest.$ac_objext conftest.beam conftest.$ac_ext
15050 fi
15051
15052
15053 # The cast to long int works around a bug in the HP C Compiler
15054 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15055 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15056 # This bug is HP SR number 8606223364.
15057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
15058 $as_echo_n "checking size of time_t... " >&6; }
15059 if ${ac_cv_sizeof_time_t+:} false; then :
15060 $as_echo_n "(cached) " >&6
15061 else
15062 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "
15063 $ac_includes_default
15064 #ifdef TIME_WITH_SYS_TIME
15065 # include <sys/time.h>
15066 # include <time.h>
15067 #else
15068 # ifdef HAVE_SYS_TIME_H
15069 # include <sys/time.h>
15070 # else
15071 # include <time.h>
15072 # endif
15073 #endif
15074
15075 "; then :
15076
15077 else
15078 if test "$ac_cv_type_time_t" = yes; then
15079 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15080 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15081 as_fn_error 77 "cannot compute sizeof (time_t)
15082 See \`config.log' for more details" "$LINENO" 5; }
15083 else
15084 ac_cv_sizeof_time_t=0
15085 fi
15086 fi
15087
15088 fi
15089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
15090 $as_echo "$ac_cv_sizeof_time_t" >&6; }
15091
15092
15093
15094 cat >>confdefs.h <<_ACEOF
15095 #define SIZEOF_TIME_T $ac_cv_sizeof_time_t
15096 _ACEOF
15097
15098
15099 # The cast to long int works around a bug in the HP C Compiler
15100 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15101 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15102 # This bug is HP SR number 8606223364.
15103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
15104 $as_echo_n "checking size of size_t... " >&6; }
15105 if ${ac_cv_sizeof_size_t+:} false; then :
15106 $as_echo_n "(cached) " >&6
15107 else
15108 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then :
15109
15110 else
15111 if test "$ac_cv_type_size_t" = yes; then
15112 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15113 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15114 as_fn_error 77 "cannot compute sizeof (size_t)
15115 See \`config.log' for more details" "$LINENO" 5; }
15116 else
15117 ac_cv_sizeof_size_t=0
15118 fi
15119 fi
15120
15121 fi
15122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
15123 $as_echo "$ac_cv_sizeof_size_t" >&6; }
15124
15125
15126
15127 cat >>confdefs.h <<_ACEOF
15128 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
15129 _ACEOF
15130
15131
15132
15133 # add option to disable the evil rpath
15134
15135 # Check whether --enable-rpath was given.
15136 if test "${enable_rpath+set}" = set; then :
15137 enableval=$enable_rpath; enable_rpath=$enableval
15138 else
15139 enable_rpath=yes
15140 fi
15141
15142 if test "x$enable_rpath" = xno; then
15143 ac_config_commands="$ac_config_commands disable-rpath"
15144
15145 fi
15146
15147
15148
15149 # check to see if libraries are needed for these functions.
15150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
15151 $as_echo_n "checking for library containing inet_pton... " >&6; }
15152 if ${ac_cv_search_inet_pton+:} false; then :
15153 $as_echo_n "(cached) " >&6
15154 else
15155 ac_func_search_save_LIBS=$LIBS
15156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15157 /* end confdefs.h. */
15158
15159 /* Override any GCC internal prototype to avoid an error.
15160 Use char because int might match the return type of a GCC
15161 builtin and then its argument prototype would still apply. */
15162 #ifdef __cplusplus
15163 extern "C"
15164 #endif
15165 char inet_pton ();
15166 int
15167 main ()
15168 {
15169 return inet_pton ();
15170 ;
15171 return 0;
15172 }
15173 _ACEOF
15174 for ac_lib in '' nsl; do
15175 if test -z "$ac_lib"; then
15176 ac_res="none required"
15177 else
15178 ac_res=-l$ac_lib
15179 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15180 fi
15181 if ac_fn_c_try_link "$LINENO"; then :
15182 ac_cv_search_inet_pton=$ac_res
15183 fi
15184 rm -f core conftest.err conftest.$ac_objext \
15185 conftest$ac_exeext
15186 if ${ac_cv_search_inet_pton+:} false; then :
15187 break
15188 fi
15189 done
15190 if ${ac_cv_search_inet_pton+:} false; then :
15191
15192 else
15193 ac_cv_search_inet_pton=no
15194 fi
15195 rm conftest.$ac_ext
15196 LIBS=$ac_func_search_save_LIBS
15197 fi
15198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
15199 $as_echo "$ac_cv_search_inet_pton" >&6; }
15200 ac_res=$ac_cv_search_inet_pton
15201 if test "$ac_res" != no; then :
15202 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15203
15204 fi
15205
15206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
15207 $as_echo_n "checking for library containing socket... " >&6; }
15208 if ${ac_cv_search_socket+:} false; then :
15209 $as_echo_n "(cached) " >&6
15210 else
15211 ac_func_search_save_LIBS=$LIBS
15212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15213 /* end confdefs.h. */
15214
15215 /* Override any GCC internal prototype to avoid an error.
15216 Use char because int might match the return type of a GCC
15217 builtin and then its argument prototype would still apply. */
15218 #ifdef __cplusplus
15219 extern "C"
15220 #endif
15221 char socket ();
15222 int
15223 main ()
15224 {
15225 return socket ();
15226 ;
15227 return 0;
15228 }
15229 _ACEOF
15230 for ac_lib in '' socket; do
15231 if test -z "$ac_lib"; then
15232 ac_res="none required"
15233 else
15234 ac_res=-l$ac_lib
15235 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15236 fi
15237 if ac_fn_c_try_link "$LINENO"; then :
15238 ac_cv_search_socket=$ac_res
15239 fi
15240 rm -f core conftest.err conftest.$ac_objext \
15241 conftest$ac_exeext
15242 if ${ac_cv_search_socket+:} false; then :
15243 break
15244 fi
15245 done
15246 if ${ac_cv_search_socket+:} false; then :
15247
15248 else
15249 ac_cv_search_socket=no
15250 fi
15251 rm conftest.$ac_ext
15252 LIBS=$ac_func_search_save_LIBS
15253 fi
15254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
15255 $as_echo "$ac_cv_search_socket" >&6; }
15256 ac_res=$ac_cv_search_socket
15257 if test "$ac_res" != no; then :
15258 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15259
15260 fi
15261
15262
15263 # check wether strptime also works
15264
15265 # check some functions of the OS before linking libs (while still runnable).
15266 for ac_header in unistd.h
15267 do :
15268 ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
15269 if test "x$ac_cv_header_unistd_h" = xyes; then :
15270 cat >>confdefs.h <<_ACEOF
15271 #define HAVE_UNISTD_H 1
15272 _ACEOF
15273
15274 fi
15275
15276 done
15277
15278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
15279 $as_echo_n "checking for working chown... " >&6; }
15280 if ${ac_cv_func_chown_works+:} false; then :
15281 $as_echo_n "(cached) " >&6
15282 else
15283 if test "$cross_compiling" = yes; then :
15284 ac_cv_func_chown_works=no
15285 else
15286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15287 /* end confdefs.h. */
15288 $ac_includes_default
15289 #include <fcntl.h>
15290
15291 int
15292 main ()
15293 {
15294 char *f = "conftest.chown";
15295 struct stat before, after;
15296
15297 if (creat (f, 0600) < 0)
15298 return 1;
15299 if (stat (f, &before) < 0)
15300 return 1;
15301 if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
15302 return 1;
15303 if (stat (f, &after) < 0)
15304 return 1;
15305 return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
15306
15307 ;
15308 return 0;
15309 }
15310 _ACEOF
15311 if ac_fn_c_try_run "$LINENO"; then :
15312 ac_cv_func_chown_works=yes
15313 else
15314 ac_cv_func_chown_works=no
15315 fi
15316 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15317 conftest.$ac_objext conftest.beam conftest.$ac_ext
15318 fi
15319
15320 rm -f conftest.chown
15321
15322 fi
15323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
15324 $as_echo "$ac_cv_func_chown_works" >&6; }
15325 if test $ac_cv_func_chown_works = yes; then
15326
15327 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
15328
15329 fi
15330
15331 for ac_header in vfork.h
15332 do :
15333 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15334 if test "x$ac_cv_header_vfork_h" = xyes; then :
15335 cat >>confdefs.h <<_ACEOF
15336 #define HAVE_VFORK_H 1
15337 _ACEOF
15338
15339 fi
15340
15341 done
15342
15343 for ac_func in fork vfork
15344 do :
15345 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15346 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15347 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15348 cat >>confdefs.h <<_ACEOF
15349 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15350 _ACEOF
15351
15352 fi
15353 done
15354
15355 if test "x$ac_cv_func_fork" = xyes; then
15356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15357 $as_echo_n "checking for working fork... " >&6; }
15358 if ${ac_cv_func_fork_works+:} false; then :
15359 $as_echo_n "(cached) " >&6
15360 else
15361 if test "$cross_compiling" = yes; then :
15362 ac_cv_func_fork_works=cross
15363 else
15364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15365 /* end confdefs.h. */
15366 $ac_includes_default
15367 int
15368 main ()
15369 {
15370
15371 /* By Ruediger Kuhlmann. */
15372 return fork () < 0;
15373
15374 ;
15375 return 0;
15376 }
15377 _ACEOF
15378 if ac_fn_c_try_run "$LINENO"; then :
15379 ac_cv_func_fork_works=yes
15380 else
15381 ac_cv_func_fork_works=no
15382 fi
15383 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15384 conftest.$ac_objext conftest.beam conftest.$ac_ext
15385 fi
15386
15387 fi
15388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15389 $as_echo "$ac_cv_func_fork_works" >&6; }
15390
15391 else
15392 ac_cv_func_fork_works=$ac_cv_func_fork
15393 fi
15394 if test "x$ac_cv_func_fork_works" = xcross; then
15395 case $host in
15396 *-*-amigaos* | *-*-msdosdjgpp*)
15397 # Override, as these systems have only a dummy fork() stub
15398 ac_cv_func_fork_works=no
15399 ;;
15400 *)
15401 ac_cv_func_fork_works=yes
15402 ;;
15403 esac
15404 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15405 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15406 fi
15407 ac_cv_func_vfork_works=$ac_cv_func_vfork
15408 if test "x$ac_cv_func_vfork" = xyes; then
15409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15410 $as_echo_n "checking for working vfork... " >&6; }
15411 if ${ac_cv_func_vfork_works+:} false; then :
15412 $as_echo_n "(cached) " >&6
15413 else
15414 if test "$cross_compiling" = yes; then :
15415 ac_cv_func_vfork_works=cross
15416 else
15417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15418 /* end confdefs.h. */
15419 /* Thanks to Paul Eggert for this test. */
15420 $ac_includes_default
15421 #include <sys/wait.h>
15422 #ifdef HAVE_VFORK_H
15423 # include <vfork.h>
15424 #endif
15425 /* On some sparc systems, changes by the child to local and incoming
15426 argument registers are propagated back to the parent. The compiler
15427 is told about this with #include <vfork.h>, but some compilers
15428 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15429 static variable whose address is put into a register that is
15430 clobbered by the vfork. */
15431 static void
15432 #ifdef __cplusplus
15433 sparc_address_test (int arg)
15434 # else
15435 sparc_address_test (arg) int arg;
15436 #endif
15437 {
15438 static pid_t child;
15439 if (!child) {
15440 child = vfork ();
15441 if (child < 0) {
15442 perror ("vfork");
15443 _exit(2);
15444 }
15445 if (!child) {
15446 arg = getpid();
15447 write(-1, "", 0);
15448 _exit (arg);
15449 }
15450 }
15451 }
15452
15453 int
15454 main ()
15455 {
15456 pid_t parent = getpid ();
15457 pid_t child;
15458
15459 sparc_address_test (0);
15460
15461 child = vfork ();
15462
15463 if (child == 0) {
15464 /* Here is another test for sparc vfork register problems. This
15465 test uses lots of local variables, at least as many local
15466 variables as main has allocated so far including compiler
15467 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
15468 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
15469 reuse the register of parent for one of the local variables,
15470 since it will think that parent can't possibly be used any more
15471 in this routine. Assigning to the local variable will thus
15472 munge parent in the parent process. */
15473 pid_t
15474 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15475 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15476 /* Convince the compiler that p..p7 are live; otherwise, it might
15477 use the same hardware register for all 8 local variables. */
15478 if (p != p1 || p != p2 || p != p3 || p != p4
15479 || p != p5 || p != p6 || p != p7)
15480 _exit(1);
15481
15482 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15483 from child file descriptors. If the child closes a descriptor
15484 before it execs or exits, this munges the parent's descriptor
15485 as well. Test for this by closing stdout in the child. */
15486 _exit(close(fileno(stdout)) != 0);
15487 } else {
15488 int status;
15489 struct stat st;
15490
15491 while (wait(&status) != child)
15492 ;
15493 return (
15494 /* Was there some problem with vforking? */
15495 child < 0
15496
15497 /* Did the child fail? (This shouldn't happen.) */
15498 || status
15499
15500 /* Did the vfork/compiler bug occur? */
15501 || parent != getpid()
15502
15503 /* Did the file descriptor bug occur? */
15504 || fstat(fileno(stdout), &st) != 0
15505 );
15506 }
15507 }
15508 _ACEOF
15509 if ac_fn_c_try_run "$LINENO"; then :
15510 ac_cv_func_vfork_works=yes
15511 else
15512 ac_cv_func_vfork_works=no
15513 fi
15514 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15515 conftest.$ac_objext conftest.beam conftest.$ac_ext
15516 fi
15517
15518 fi
15519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15520 $as_echo "$ac_cv_func_vfork_works" >&6; }
15521
15522 fi;
15523 if test "x$ac_cv_func_fork_works" = xcross; then
15524 ac_cv_func_vfork_works=$ac_cv_func_vfork
15525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15526 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15527 fi
15528
15529 if test "x$ac_cv_func_vfork_works" = xyes; then
15530
15531 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15532
15533 else
15534
15535 $as_echo "#define vfork fork" >>confdefs.h
15536
15537 fi
15538 if test "x$ac_cv_func_fork_works" = xyes; then
15539
15540 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15541
15542 fi
15543
15544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
15545 $as_echo_n "checking return type of signal handlers... " >&6; }
15546 if ${ac_cv_type_signal+:} false; then :
15547 $as_echo_n "(cached) " >&6
15548 else
15549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15550 /* end confdefs.h. */
15551 #include <sys/types.h>
15552 #include <signal.h>
15553
15554 int
15555 main ()
15556 {
15557 return *(signal (0, 0)) (0) == 1;
15558 ;
15559 return 0;
15560 }
15561 _ACEOF
15562 if ac_fn_c_try_compile "$LINENO"; then :
15563 ac_cv_type_signal=int
15564 else
15565 ac_cv_type_signal=void
15566 fi
15567 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15568 fi
15569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
15570 $as_echo "$ac_cv_type_signal" >&6; }
15571
15572 cat >>confdefs.h <<_ACEOF
15573 #define RETSIGTYPE $ac_cv_type_signal
15574 _ACEOF
15575
15576
15577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15578 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15579 if ${ac_cv_sys_largefile_source+:} false; then :
15580 $as_echo_n "(cached) " >&6
15581 else
15582 while :; do
15583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15584 /* end confdefs.h. */
15585 #include <sys/types.h> /* for off_t */
15586 #include <stdio.h>
15587 int
15588 main ()
15589 {
15590 int (*fp) (FILE *, off_t, int) = fseeko;
15591 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15592 ;
15593 return 0;
15594 }
15595 _ACEOF
15596 if ac_fn_c_try_link "$LINENO"; then :
15597 ac_cv_sys_largefile_source=no; break
15598 fi
15599 rm -f core conftest.err conftest.$ac_objext \
15600 conftest$ac_exeext conftest.$ac_ext
15601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15602 /* end confdefs.h. */
15603 #define _LARGEFILE_SOURCE 1
15604 #include <sys/types.h> /* for off_t */
15605 #include <stdio.h>
15606 int
15607 main ()
15608 {
15609 int (*fp) (FILE *, off_t, int) = fseeko;
15610 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15611 ;
15612 return 0;
15613 }
15614 _ACEOF
15615 if ac_fn_c_try_link "$LINENO"; then :
15616 ac_cv_sys_largefile_source=1; break
15617 fi
15618 rm -f core conftest.err conftest.$ac_objext \
15619 conftest$ac_exeext conftest.$ac_ext
15620 ac_cv_sys_largefile_source=unknown
15621 break
15622 done
15623 fi
15624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15625 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15626 case $ac_cv_sys_largefile_source in #(
15627 no | unknown) ;;
15628 *)
15629 cat >>confdefs.h <<_ACEOF
15630 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15631 _ACEOF
15632 ;;
15633 esac
15634 rm -rf conftest*
15635
15636 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15637 # in glibc 2.1.3, but that breaks too many other things.
15638 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15639 if test $ac_cv_sys_largefile_source != unknown; then
15640
15641 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15642
15643 fi
15644
15645
15646 # Check whether --enable-largefile was given.
15647 if test "${enable_largefile+set}" = set; then :
15648 enableval=$enable_largefile;
15649 fi
15650
15651 if test "$enable_largefile" != no; then
15652
15653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15654 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
15655 if ${ac_cv_sys_largefile_CC+:} false; then :
15656 $as_echo_n "(cached) " >&6
15657 else
15658 ac_cv_sys_largefile_CC=no
15659 if test "$GCC" != yes; then
15660 ac_save_CC=$CC
15661 while :; do
15662 # IRIX 6.2 and later do not support large files by default,
15663 # so use the C compiler's -n32 option if that helps.
15664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15665 /* end confdefs.h. */
15666 #include <sys/types.h>
15667 /* Check that off_t can represent 2**63 - 1 correctly.
15668 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15669 since some C++ compilers masquerading as C compilers
15670 incorrectly reject 9223372036854775807. */
15671 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
15672 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15673 && LARGE_OFF_T % 2147483647 == 1)
15674 ? 1 : -1];
15675 int
15676 main ()
15677 {
15678
15679 ;
15680 return 0;
15681 }
15682 _ACEOF
15683 if ac_fn_c_try_compile "$LINENO"; then :
15684 break
15685 fi
15686 rm -f core conftest.err conftest.$ac_objext
15687 CC="$CC -n32"
15688 if ac_fn_c_try_compile "$LINENO"; then :
15689 ac_cv_sys_largefile_CC=' -n32'; break
15690 fi
15691 rm -f core conftest.err conftest.$ac_objext
15692 break
15693 done
15694 CC=$ac_save_CC
15695 rm -f conftest.$ac_ext
15696 fi
15697 fi
15698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15699 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
15700 if test "$ac_cv_sys_largefile_CC" != no; then
15701 CC=$CC$ac_cv_sys_largefile_CC
15702 fi
15703
15704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15705 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15706 if ${ac_cv_sys_file_offset_bits+:} false; then :
15707 $as_echo_n "(cached) " >&6
15708 else
15709 while :; do
15710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15711 /* end confdefs.h. */
15712 #include <sys/types.h>
15713 /* Check that off_t can represent 2**63 - 1 correctly.
15714 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15715 since some C++ compilers masquerading as C compilers
15716 incorrectly reject 9223372036854775807. */
15717 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
15718 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15719 && LARGE_OFF_T % 2147483647 == 1)
15720 ? 1 : -1];
15721 int
15722 main ()
15723 {
15724
15725 ;
15726 return 0;
15727 }
15728 _ACEOF
15729 if ac_fn_c_try_compile "$LINENO"; then :
15730 ac_cv_sys_file_offset_bits=no; break
15731 fi
15732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15734 /* end confdefs.h. */
15735 #define _FILE_OFFSET_BITS 64
15736 #include <sys/types.h>
15737 /* Check that off_t can represent 2**63 - 1 correctly.
15738 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15739 since some C++ compilers masquerading as C compilers
15740 incorrectly reject 9223372036854775807. */
15741 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
15742 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15743 && LARGE_OFF_T % 2147483647 == 1)
15744 ? 1 : -1];
15745 int
15746 main ()
15747 {
15748
15749 ;
15750 return 0;
15751 }
15752 _ACEOF
15753 if ac_fn_c_try_compile "$LINENO"; then :
15754 ac_cv_sys_file_offset_bits=64; break
15755 fi
15756 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15757 ac_cv_sys_file_offset_bits=unknown
15758 break
15759 done
15760 fi
15761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15762 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
15763 case $ac_cv_sys_file_offset_bits in #(
15764 no | unknown) ;;
15765 *)
15766 cat >>confdefs.h <<_ACEOF
15767 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
15768 _ACEOF
15769 ;;
15770 esac
15771 rm -rf conftest*
15772 if test $ac_cv_sys_file_offset_bits = unknown; then
15773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15774 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
15775 if ${ac_cv_sys_large_files+:} false; then :
15776 $as_echo_n "(cached) " >&6
15777 else
15778 while :; do
15779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15780 /* end confdefs.h. */
15781 #include <sys/types.h>
15782 /* Check that off_t can represent 2**63 - 1 correctly.
15783 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15784 since some C++ compilers masquerading as C compilers
15785 incorrectly reject 9223372036854775807. */
15786 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
15787 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15788 && LARGE_OFF_T % 2147483647 == 1)
15789 ? 1 : -1];
15790 int
15791 main ()
15792 {
15793
15794 ;
15795 return 0;
15796 }
15797 _ACEOF
15798 if ac_fn_c_try_compile "$LINENO"; then :
15799 ac_cv_sys_large_files=no; break
15800 fi
15801 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15803 /* end confdefs.h. */
15804 #define _LARGE_FILES 1
15805 #include <sys/types.h>
15806 /* Check that off_t can represent 2**63 - 1 correctly.
15807 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15808 since some C++ compilers masquerading as C compilers
15809 incorrectly reject 9223372036854775807. */
15810 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
15811 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15812 && LARGE_OFF_T % 2147483647 == 1)
15813 ? 1 : -1];
15814 int
15815 main ()
15816 {
15817
15818 ;
15819 return 0;
15820 }
15821 _ACEOF
15822 if ac_fn_c_try_compile "$LINENO"; then :
15823 ac_cv_sys_large_files=1; break
15824 fi
15825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15826 ac_cv_sys_large_files=unknown
15827 break
15828 done
15829 fi
15830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15831 $as_echo "$ac_cv_sys_large_files" >&6; }
15832 case $ac_cv_sys_large_files in #(
15833 no | unknown) ;;
15834 *)
15835 cat >>confdefs.h <<_ACEOF
15836 #define _LARGE_FILES $ac_cv_sys_large_files
15837 _ACEOF
15838 ;;
15839 esac
15840 rm -rf conftest*
15841 fi
15842
15843
15844 fi
15845
15846
15847
15848
15849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC" >&5
15850 $as_echo_n "checking whether we need -D_LARGEFILE_SOURCE=1 as a flag for $CC... " >&6; }
15851 cache=_D_LARGEFILE_SOURCE_1
15852 if eval \${cv_prog_cc_flag_needed_$cache+:} false; then :
15853 $as_echo_n "(cached) " >&6
15854 else
15855
15856 echo '
15857 #include <stdio.h>
15858 int test() {
15859 int a = fseeko(stdin, 0, 0);
15860 return a;
15861 }
15862 ' > conftest.c
15863 echo 'void f(){}' >>conftest.c
15864 if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then
15865 eval "cv_prog_cc_flag_needed_$cache=no"
15866 else
15867
15868 if test -z "`$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`"; then
15869 eval "cv_prog_cc_flag_needed_$cache=yes"
15870 else
15871 eval "cv_prog_cc_flag_needed_$cache=fail"
15872 #echo 'Test with flag fails too!'
15873 #cat conftest.c
15874 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15875 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15876 #exit 1
15877 fi
15878
15879 fi
15880 rm -f conftest conftest.c conftest.o
15881
15882 fi
15883
15884 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = yes"; then
15885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15886 $as_echo "yes" >&6; }
15887 :
15888 CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE=1"
15889 else
15890 if eval "test \"`echo '$cv_prog_cc_flag_needed_'$cache`\" = no"; then
15891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15892 $as_echo "no" >&6; }
15893 #echo 'Test with flag is no!'
15894 #cat conftest.c
15895 #echo "$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1"
15896 #echo `$CC $CPPFLAGS $CFLAGS -D_LARGEFILE_SOURCE=1 $ERRFLAG -c conftest.c 2>&1`
15897 #exit 1
15898 :
15899
15900 else
15901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
15902 $as_echo "failed" >&6; }
15903 :
15904
15905 fi
15906 fi
15907
15908
15909
15910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nonblocking sockets work" >&5
15911 $as_echo_n "checking if nonblocking sockets work... " >&6; }
15912 if echo $target | grep mingw32 >/dev/null; then
15913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (windows)" >&5
15914 $as_echo "no (windows)" >&6; }
15915
15916 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
15917
15918 else
15919 if test "$cross_compiling" = yes; then :
15920
15921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: crosscompile(yes)" >&5
15922 $as_echo "crosscompile(yes)" >&6; }
15923
15924 else
15925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15926 /* end confdefs.h. */
15927
15928
15929 #include <stdio.h>
15930 #include <string.h>
15931 #include <stdlib.h>
15932 #include <fcntl.h>
15933 #include <errno.h>
15934 #ifdef HAVE_SYS_TYPES_H
15935 #include <sys/types.h>
15936 #endif
15937 #ifdef HAVE_SYS_SOCKET_H
15938 #include <sys/socket.h>
15939 #endif
15940 #ifdef HAVE_NETINET_IN_H
15941 #include <netinet/in.h>
15942 #endif
15943 #ifdef HAVE_ARPA_INET_H
15944 #include <arpa/inet.h>
15945 #endif
15946 #ifdef HAVE_UNISTD_H
15947 #include <unistd.h>
15948 #endif
15949 #ifdef HAVE_TIME_H
15950 #include <time.h>
15951 #endif
15952
15953 int main(void)
15954 {
15955 int port;
15956 int sfd, cfd;
15957 int num = 10;
15958 int i, p;
15959 struct sockaddr_in a;
15960 /* test if select and nonblocking reads work well together */
15961 /* open port.
15962 fork child to send 10 messages.
15963 select to read.
15964 then try to nonblocking read the 10 messages
15965 then, nonblocking read must give EAGAIN
15966 */
15967
15968 port = 12345 + (time(0)%32);
15969 sfd = socket(PF_INET, SOCK_DGRAM, 0);
15970 if(sfd == -1) {
15971 perror("socket");
15972 return 1;
15973 }
15974 memset(&a, 0, sizeof(a));
15975 a.sin_family = AF_INET;
15976 a.sin_port = htons(port);
15977 a.sin_addr.s_addr = inet_addr("127.0.0.1");
15978 if(bind(sfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
15979 perror("bind");
15980 return 1;
15981 }
15982 if(fcntl(sfd, F_SETFL, O_NONBLOCK) == -1) {
15983 perror("fcntl");
15984 return 1;
15985 }
15986
15987 cfd = socket(PF_INET, SOCK_DGRAM, 0);
15988 if(cfd == -1) {
15989 perror("client socket");
15990 return 1;
15991 }
15992 a.sin_port = 0;
15993 if(bind(cfd, (struct sockaddr*)&a, sizeof(a)) < 0) {
15994 perror("client bind");
15995 return 1;
15996 }
15997 a.sin_port = htons(port);
15998
15999 /* no handler, causes exit in 10 seconds */
16000 alarm(10);
16001
16002 /* send and receive on the socket */
16003 if((p=fork()) == 0) {
16004 for(i=0; i<num; i++) {
16005 if(sendto(cfd, &i, sizeof(i), 0,
16006 (struct sockaddr*)&a, sizeof(a)) < 0) {
16007 perror("sendto");
16008 return 1;
16009 }
16010 }
16011 } else {
16012 /* parent */
16013 fd_set rset;
16014 int x;
16015 if(p == -1) {
16016 perror("fork");
16017 return 1;
16018 }
16019 FD_ZERO(&rset);
16020 FD_SET(sfd, &rset);
16021 if(select(sfd+1, &rset, NULL, NULL, NULL) < 1) {
16022 perror("select");
16023 return 1;
16024 }
16025 i = 0;
16026 while(i < num) {
16027 if(recv(sfd, &x, sizeof(x), 0) != sizeof(x)) {
16028 if(errno == EAGAIN)
16029 continue;
16030 perror("recv");
16031 return 1;
16032 }
16033 i++;
16034 }
16035 /* now we want to get EAGAIN: nonblocking goodness */
16036 errno = 0;
16037 recv(sfd, &x, sizeof(x), 0);
16038 if(errno != EAGAIN) {
16039 perror("trying to recv again");
16040 return 1;
16041 }
16042 /* EAGAIN encountered */
16043 }
16044
16045 close(sfd);
16046 close(cfd);
16047 return 0;
16048 }
16049
16050 _ACEOF
16051 if ac_fn_c_try_run "$LINENO"; then :
16052
16053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16054 $as_echo "yes" >&6; }
16055
16056 else
16057
16058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16059 $as_echo "no" >&6; }
16060
16061 $as_echo "#define NONBLOCKING_IS_BROKEN 1" >>confdefs.h
16062
16063
16064 fi
16065 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16066 conftest.$ac_objext conftest.beam conftest.$ac_ext
16067 fi
16068
16069 fi
16070
16071
16072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir has one arg" >&5
16073 $as_echo_n "checking whether mkdir has one arg... " >&6; }
16074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16075 /* end confdefs.h. */
16076
16077 #include <stdio.h>
16078 #include <unistd.h>
16079 #ifdef HAVE_WINSOCK2_H
16080 #include <winsock2.h>
16081 #endif
16082 #ifdef HAVE_SYS_STAT_H
16083 #include <sys/stat.h>
16084 #endif
16085
16086 int
16087 main ()
16088 {
16089
16090 (void)mkdir("directory");
16091
16092 ;
16093 return 0;
16094 }
16095 _ACEOF
16096 if ac_fn_c_try_compile "$LINENO"; then :
16097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16098 $as_echo "yes" >&6; }
16099
16100 $as_echo "#define MKDIR_HAS_ONE_ARG 1" >>confdefs.h
16101
16102
16103 else
16104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16105 $as_echo "no" >&6; }
16106
16107 fi
16108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16109
16110 for ac_func in strptime
16111 do :
16112 ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
16113 if test "x$ac_cv_func_strptime" = xyes; then :
16114 cat >>confdefs.h <<_ACEOF
16115 #define HAVE_STRPTIME 1
16116 _ACEOF
16117
16118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strptime works" >&5
16119 $as_echo_n "checking whether strptime works... " >&6; }
16120 if test c${cross_compiling} = cno; then
16121 if test "$cross_compiling" = yes; then :
16122 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16123 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16124 as_fn_error $? "cannot run test program while cross compiling
16125 See \`config.log' for more details" "$LINENO" 5; }
16126 else
16127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16128 /* end confdefs.h. */
16129
16130 #define _XOPEN_SOURCE 600
16131 #include <time.h>
16132 int main(void) { struct tm tm; char *res;
16133 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);
16134 if (!res) return 2;
16135 res = strptime("20070207111842", "%Y%m%d%H%M%S", &tm);
16136 if (!res) return 1; return 0; }
16137
16138 _ACEOF
16139 if ac_fn_c_try_run "$LINENO"; then :
16140 eval "ac_cv_c_strptime_works=yes"
16141 else
16142 eval "ac_cv_c_strptime_works=no"
16143 fi
16144 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16145 conftest.$ac_objext conftest.beam conftest.$ac_ext
16146 fi
16147
16148 else
16149 eval "ac_cv_c_strptime_works=maybe"
16150 fi
16151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_strptime_works" >&5
16152 $as_echo "$ac_cv_c_strptime_works" >&6; }
16153 if test $ac_cv_c_strptime_works = no; then
16154 case " $LIBOBJS " in
16155 *" strptime.$ac_objext "* ) ;;
16156 *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16157 ;;
16158 esac
16159
16160 else
16161
16162 cat >>confdefs.h <<_ACEOF
16163 #define STRPTIME_WORKS 1
16164 _ACEOF
16165
16166 fi
16167
16168 else
16169 case " $LIBOBJS " in
16170 *" strptime.$ac_objext "* ) ;;
16171 *) LIBOBJS="$LIBOBJS strptime.$ac_objext"
16172 ;;
16173 esac
16174
16175 fi
16176 done
16177
16178
16179 # check if we can use SO_REUSEPORT
16180 if echo "$host" | $GREP -i -e linux -e dragonfly >/dev/null; then
16181
16182 $as_echo "#define REUSEPORT_DEFAULT 1" >>confdefs.h
16183
16184 else
16185
16186 $as_echo "#define REUSEPORT_DEFAULT 0" >>confdefs.h
16187
16188 fi
16189
16190 # Include systemd.m4 - begin
16191 # macros for configuring systemd
16192 # Copyright 2015, Sami Kerola, CloudFlare.
16193 # BSD licensed.
16194 # Check whether --enable-systemd was given.
16195 if test "${enable_systemd+set}" = set; then :
16196 enableval=$enable_systemd;
16197 else
16198 enable_systemd=no
16199 fi
16200
16201 have_systemd=no
16202 if test "x$enable_systemd" != xno; then :
16203
16204
16205
16206 pkg_failed=no
16207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD" >&5
16208 $as_echo_n "checking for SYSTEMD... " >&6; }
16209
16210 if test -n "$SYSTEMD_CFLAGS"; then
16211 pkg_cv_SYSTEMD_CFLAGS="$SYSTEMD_CFLAGS"
16212 elif test -n "$PKG_CONFIG"; then
16213 if test -n "$PKG_CONFIG" && \
16214 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16215 ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16216 ac_status=$?
16217 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16218 test $ac_status = 0; }; then
16219 pkg_cv_SYSTEMD_CFLAGS=`$PKG_CONFIG --cflags "libsystemd" 2>/dev/null`
16220 test "x$?" != "x0" && pkg_failed=yes
16221 else
16222 pkg_failed=yes
16223 fi
16224 else
16225 pkg_failed=untried
16226 fi
16227 if test -n "$SYSTEMD_LIBS"; then
16228 pkg_cv_SYSTEMD_LIBS="$SYSTEMD_LIBS"
16229 elif test -n "$PKG_CONFIG"; then
16230 if test -n "$PKG_CONFIG" && \
16231 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd\""; } >&5
16232 ($PKG_CONFIG --exists --print-errors "libsystemd") 2>&5
16233 ac_status=$?
16234 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16235 test $ac_status = 0; }; then
16236 pkg_cv_SYSTEMD_LIBS=`$PKG_CONFIG --libs "libsystemd" 2>/dev/null`
16237 test "x$?" != "x0" && pkg_failed=yes
16238 else
16239 pkg_failed=yes
16240 fi
16241 else
16242 pkg_failed=untried
16243 fi
16244
16245
16246
16247 if test $pkg_failed = yes; then
16248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16249 $as_echo "no" >&6; }
16250
16251 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16252 _pkg_short_errors_supported=yes
16253 else
16254 _pkg_short_errors_supported=no
16255 fi
16256 if test $_pkg_short_errors_supported = yes; then
16257 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd" 2>&1`
16258 else
16259 SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd" 2>&1`
16260 fi
16261 # Put the nasty error message in config.log where it belongs
16262 echo "$SYSTEMD_PKG_ERRORS" >&5
16263
16264 have_systemd=no
16265 elif test $pkg_failed = untried; then
16266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16267 $as_echo "no" >&6; }
16268 have_systemd=no
16269 else
16270 SYSTEMD_CFLAGS=$pkg_cv_SYSTEMD_CFLAGS
16271 SYSTEMD_LIBS=$pkg_cv_SYSTEMD_LIBS
16272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16273 $as_echo "yes" >&6; }
16274 have_systemd=yes
16275 fi
16276 if test "x$have_systemd" != "xyes"; then :
16277
16278
16279 pkg_failed=no
16280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD_DAEMON" >&5
16281 $as_echo_n "checking for SYSTEMD_DAEMON... " >&6; }
16282
16283 if test -n "$SYSTEMD_DAEMON_CFLAGS"; then
16284 pkg_cv_SYSTEMD_DAEMON_CFLAGS="$SYSTEMD_DAEMON_CFLAGS"
16285 elif test -n "$PKG_CONFIG"; then
16286 if test -n "$PKG_CONFIG" && \
16287 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16288 ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16289 ac_status=$?
16290 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16291 test $ac_status = 0; }; then
16292 pkg_cv_SYSTEMD_DAEMON_CFLAGS=`$PKG_CONFIG --cflags "libsystemd-daemon" 2>/dev/null`
16293 test "x$?" != "x0" && pkg_failed=yes
16294 else
16295 pkg_failed=yes
16296 fi
16297 else
16298 pkg_failed=untried
16299 fi
16300 if test -n "$SYSTEMD_DAEMON_LIBS"; then
16301 pkg_cv_SYSTEMD_DAEMON_LIBS="$SYSTEMD_DAEMON_LIBS"
16302 elif test -n "$PKG_CONFIG"; then
16303 if test -n "$PKG_CONFIG" && \
16304 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon\""; } >&5
16305 ($PKG_CONFIG --exists --print-errors "libsystemd-daemon") 2>&5
16306 ac_status=$?
16307 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16308 test $ac_status = 0; }; then
16309 pkg_cv_SYSTEMD_DAEMON_LIBS=`$PKG_CONFIG --libs "libsystemd-daemon" 2>/dev/null`
16310 test "x$?" != "x0" && pkg_failed=yes
16311 else
16312 pkg_failed=yes
16313 fi
16314 else
16315 pkg_failed=untried
16316 fi
16317
16318
16319
16320 if test $pkg_failed = yes; then
16321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16322 $as_echo "no" >&6; }
16323
16324 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
16325 _pkg_short_errors_supported=yes
16326 else
16327 _pkg_short_errors_supported=no
16328 fi
16329 if test $_pkg_short_errors_supported = yes; then
16330 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16331 else
16332 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd-daemon" 2>&1`
16333 fi
16334 # Put the nasty error message in config.log where it belongs
16335 echo "$SYSTEMD_DAEMON_PKG_ERRORS" >&5
16336
16337 have_systemd_daemon=no
16338 elif test $pkg_failed = untried; then
16339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16340 $as_echo "no" >&6; }
16341 have_systemd_daemon=no
16342 else
16343 SYSTEMD_DAEMON_CFLAGS=$pkg_cv_SYSTEMD_DAEMON_CFLAGS
16344 SYSTEMD_DAEMON_LIBS=$pkg_cv_SYSTEMD_DAEMON_LIBS
16345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16346 $as_echo "yes" >&6; }
16347 have_systemd_daemon=yes
16348 fi
16349 if test "x$have_systemd_daemon" = "xyes"; then :
16350 have_systemd=yes
16351 fi
16352
16353 fi
16354 case $enable_systemd:$have_systemd in #(
16355 yes:no) :
16356 as_fn_error $? "systemd enabled but libsystemd not found" "$LINENO" 5 ;; #(
16357 *:yes) :
16358
16359 $as_echo "#define HAVE_SYSTEMD 1" >>confdefs.h
16360
16361 LIBS="$LIBS $SYSTEMD_LIBS"
16362
16363 ;; #(
16364 *) :
16365 ;;
16366 esac
16367
16368
16369 fi
16370 if test "x$have_systemd" = xyes; then
16371 USE_SYSTEMD_TRUE=
16372 USE_SYSTEMD_FALSE='#'
16373 else
16374 USE_SYSTEMD_TRUE='#'
16375 USE_SYSTEMD_FALSE=
16376 fi
16377
16378
16379 # Include systemd.m4 - end
16380
16381 # set memory allocation checking if requested
16382 # Check whether --enable-alloc-checks was given.
16383 if test "${enable_alloc_checks+set}" = set; then :
16384 enableval=$enable_alloc_checks;
16385 fi
16386
16387 # Check whether --enable-alloc-lite was given.
16388 if test "${enable_alloc_lite+set}" = set; then :
16389 enableval=$enable_alloc_lite;
16390 fi
16391
16392 # Check whether --enable-alloc-nonregional was given.
16393 if test "${enable_alloc_nonregional+set}" = set; then :
16394 enableval=$enable_alloc_nonregional;
16395 fi
16396
16397 if test x_$enable_alloc_nonregional = x_yes; then
16398
16399 $as_echo "#define UNBOUND_ALLOC_NONREGIONAL 1" >>confdefs.h
16400
16401 fi
16402 if test x_$enable_alloc_checks = x_yes; then
16403
16404 $as_echo "#define UNBOUND_ALLOC_STATS 1" >>confdefs.h
16405
16406 SLDNS_ALLOCCHECK_EXTRA_OBJ="alloc.lo log.lo"
16407
16408 ASYNCLOOK_ALLOCCHECK_EXTRA_OBJ="alloc.lo"
16409
16410 else
16411 if test x_$enable_alloc_lite = x_yes; then
16412
16413 $as_echo "#define UNBOUND_ALLOC_LITE 1" >>confdefs.h
16414
16415 else
16416
16417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
16418 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
16419 if test "$cross_compiling" = yes; then :
16420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (crosscompile)" >&5
16421 $as_echo "no (crosscompile)" >&6; }
16422 case " $LIBOBJS " in
16423 *" malloc.$ac_objext "* ) ;;
16424 *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
16425 ;;
16426 esac
16427
16428
16429 cat >>confdefs.h <<_ACEOF
16430 #define malloc rpl_malloc_unbound
16431 _ACEOF
16432
16433 else
16434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16435 /* end confdefs.h. */
16436 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
16437 #include <stdlib.h>
16438 #else
16439 char *malloc ();
16440 #endif
16441
16442 int
16443 main ()
16444 {
16445 if(malloc(0) != 0) return 1;
16446 ;
16447 return 0;
16448 }
16449
16450 _ACEOF
16451 if ac_fn_c_try_run "$LINENO"; then :
16452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16453 $as_echo "no" >&6; }
16454 case " $LIBOBJS " in
16455 *" malloc.$ac_objext "* ) ;;
16456 *) LIBOBJS="$LIBOBJS malloc.$ac_objext"
16457 ;;
16458 esac
16459
16460
16461 cat >>confdefs.h <<_ACEOF
16462 #define malloc rpl_malloc_unbound
16463 _ACEOF
16464
16465 else
16466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16467 $as_echo "yes" >&6; }
16468
16469 $as_echo "#define HAVE_MALLOC 1" >>confdefs.h
16470
16471 fi
16472 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16473 conftest.$ac_objext conftest.beam conftest.$ac_ext
16474 fi
16475
16476
16477 fi
16478 fi
16479
16480 # check windows threads (we use them, not pthreads, on windows).
16481 if test "$on_mingw" = "yes"; then
16482 # check windows threads
16483 for ac_header in windows.h
16484 do :
16485 ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
16486 "
16487 if test "x$ac_cv_header_windows_h" = xyes; then :
16488 cat >>confdefs.h <<_ACEOF
16489 #define HAVE_WINDOWS_H 1
16490 _ACEOF
16491
16492 fi
16493
16494 done
16495
16496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CreateThread" >&5
16497 $as_echo_n "checking for CreateThread... " >&6; }
16498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16499 /* end confdefs.h. */
16500
16501 #ifdef HAVE_WINDOWS_H
16502 #include <windows.h>
16503 #endif
16504
16505 int
16506 main ()
16507 {
16508
16509 HANDLE t = CreateThread(NULL, 0, NULL, NULL, 0, NULL);
16510
16511 ;
16512 return 0;
16513 }
16514 _ACEOF
16515 if ac_fn_c_try_compile "$LINENO"; then :
16516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16517 $as_echo "yes" >&6; }
16518
16519 $as_echo "#define HAVE_WINDOWS_THREADS 1" >>confdefs.h
16520
16521
16522 else
16523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16524 $as_echo "no" >&6; }
16525
16526 fi
16527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16528
16529 else
16530 # not on mingw, check thread libraries.
16531
16532 # check for thread library.
16533 # check this first, so that the pthread lib does not get linked in via
16534 # libssl or libpython, and thus distorts the tests, and we end up using
16535 # the non-threadsafe C libraries.
16536
16537 # Check whether --with-pthreads was given.
16538 if test "${with_pthreads+set}" = set; then :
16539 withval=$with_pthreads;
16540 else
16541 withval="yes"
16542 fi
16543
16544 ub_have_pthreads=no
16545 if test x_$withval != x_no; then
16546
16547
16548 ac_ext=c
16549 ac_cpp='$CPP $CPPFLAGS'
16550 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16551 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16552 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16553
16554 ax_pthread_ok=no
16555
16556 # We used to check for pthread.h first, but this fails if pthread.h
16557 # requires special compiler flags (e.g. on True64 or Sequent).
16558 # It gets checked for in the link test anyway.
16559
16560 # First of all, check if the user has set any of the PTHREAD_LIBS,
16561 # etcetera environment variables, and if threads linking works using
16562 # them:
16563 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16564 save_CFLAGS="$CFLAGS"
16565 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16566 save_LIBS="$LIBS"
16567 LIBS="$PTHREAD_LIBS $LIBS"
16568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16569 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
16570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16571 /* end confdefs.h. */
16572
16573 /* Override any GCC internal prototype to avoid an error.
16574 Use char because int might match the return type of a GCC
16575 builtin and then its argument prototype would still apply. */
16576 #ifdef __cplusplus
16577 extern "C"
16578 #endif
16579 char pthread_join ();
16580 int
16581 main ()
16582 {
16583 return pthread_join ();
16584 ;
16585 return 0;
16586 }
16587 _ACEOF
16588 if ac_fn_c_try_link "$LINENO"; then :
16589 ax_pthread_ok=yes
16590 fi
16591 rm -f core conftest.err conftest.$ac_objext \
16592 conftest$ac_exeext conftest.$ac_ext
16593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16594 $as_echo "$ax_pthread_ok" >&6; }
16595 if test x"$ax_pthread_ok" = xno; then
16596 PTHREAD_LIBS=""
16597 PTHREAD_CFLAGS=""
16598 fi
16599 LIBS="$save_LIBS"
16600 CFLAGS="$save_CFLAGS"
16601 fi
16602
16603 # We must check for the threads library under a number of different
16604 # names; the ordering is very important because some systems
16605 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16606 # libraries is broken (non-POSIX).
16607
16608 # Create a list of thread flags to try. Items starting with a "-" are
16609 # C compiler flags, and other items are library names, except for "none"
16610 # which indicates that we try without any flags at all, and "pthread-config"
16611 # which is a program returning the flags for the Pth emulation library.
16612
16613 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
16614
16615 # The ordering *is* (sometimes) important. Some notes on the
16616 # individual items follow:
16617
16618 # pthreads: AIX (must check this before -lpthread)
16619 # none: in case threads are in libc; should be tried before -Kthread and
16620 # other compiler flags to prevent continual compiler warnings
16621 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16622 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16623 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16624 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16625 # -pthreads: Solaris/gcc
16626 # -mthreads: Mingw32/gcc, Lynx/gcc
16627 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16628 # doesn't hurt to check since this sometimes defines pthreads too;
16629 # also defines -D_REENTRANT)
16630 # ... -mt is also the pthreads flag for HP/aCC
16631 # pthread: Linux, etcetera
16632 # --thread-safe: KAI C++
16633 # pthread-config: use pthread-config program (for GNU Pth library)
16634
16635 case ${host_os} in
16636 solaris*)
16637
16638 # On Solaris (at least, for some versions), libc contains stubbed
16639 # (non-functional) versions of the pthreads routines, so link-based
16640 # tests will erroneously succeed. (We need to link with -pthreads/-mt/
16641 # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
16642 # a function called by this macro, so we could check for that, but
16643 # who knows whether they'll stub that too in a future libc.) So,
16644 # we'll just look for -pthreads and -lpthread first:
16645
16646 ax_pthread_flags="-pthreads pthread -mt -pthread $ax_pthread_flags"
16647 ;;
16648
16649 darwin*)
16650 ax_pthread_flags="-pthread $ax_pthread_flags"
16651 ;;
16652 esac
16653
16654 # Clang doesn't consider unrecognized options an error unless we specify
16655 # -Werror. We throw in some extra Clang-specific options to ensure that
16656 # this doesn't happen for GCC, which also accepts -Werror.
16657
16658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs -Werror to reject unknown flags" >&5
16659 $as_echo_n "checking if compiler needs -Werror to reject unknown flags... " >&6; }
16660 save_CFLAGS="$CFLAGS"
16661 ax_pthread_extra_flags="-Werror"
16662 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wunknown-warning-option -Wsizeof-array-argument"
16663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16664 /* end confdefs.h. */
16665 int foo(void);
16666 int
16667 main ()
16668 {
16669 foo()
16670 ;
16671 return 0;
16672 }
16673 _ACEOF
16674 if ac_fn_c_try_compile "$LINENO"; then :
16675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16676 $as_echo "yes" >&6; }
16677 else
16678 ax_pthread_extra_flags=
16679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16680 $as_echo "no" >&6; }
16681 fi
16682 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16683 CFLAGS="$save_CFLAGS"
16684
16685 if test x"$ax_pthread_ok" = xno; then
16686 for flag in $ax_pthread_flags; do
16687
16688 case $flag in
16689 none)
16690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
16691 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
16692 ;;
16693
16694 -*)
16695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
16696 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
16697 PTHREAD_CFLAGS="$flag"
16698 ;;
16699
16700 pthread-config)
16701 # Extract the first word of "pthread-config", so it can be a program name with args.
16702 set dummy pthread-config; ac_word=$2
16703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16704 $as_echo_n "checking for $ac_word... " >&6; }
16705 if ${ac_cv_prog_ax_pthread_config+:} false; then :
16706 $as_echo_n "(cached) " >&6
16707 else
16708 if test -n "$ax_pthread_config"; then
16709 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
16710 else
16711 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16712 for as_dir in $PATH
16713 do
16714 IFS=$as_save_IFS
16715 test -z "$as_dir" && as_dir=.
16716 for ac_exec_ext in '' $ac_executable_extensions; do
16717 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16718 ac_cv_prog_ax_pthread_config="yes"
16719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16720 break 2
16721 fi
16722 done
16723 done
16724 IFS=$as_save_IFS
16725
16726 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
16727 fi
16728 fi
16729 ax_pthread_config=$ac_cv_prog_ax_pthread_config
16730 if test -n "$ax_pthread_config"; then
16731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
16732 $as_echo "$ax_pthread_config" >&6; }
16733 else
16734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16735 $as_echo "no" >&6; }
16736 fi
16737
16738
16739 if test x"$ax_pthread_config" = xno; then continue; fi
16740 PTHREAD_CFLAGS="`pthread-config --cflags`"
16741 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16742 ;;
16743
16744 *)
16745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
16746 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
16747 PTHREAD_LIBS="-l$flag"
16748 ;;
16749 esac
16750
16751 save_LIBS="$LIBS"
16752 save_CFLAGS="$CFLAGS"
16753 LIBS="$PTHREAD_LIBS $LIBS"
16754 CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
16755
16756 # Check for various functions. We must include pthread.h,
16757 # since some functions may be macros. (On the Sequent, we
16758 # need a special flag -Kthread to make this header compile.)
16759 # We check for pthread_join because it is in -lpthread on IRIX
16760 # while pthread_create is in libc. We check for pthread_attr_init
16761 # due to DEC craziness with -lpthreads. We check for
16762 # pthread_cleanup_push because it is one of the few pthread
16763 # functions on Solaris that doesn't have a non-functional libc stub.
16764 # We try pthread_create on general principles.
16765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16766 /* end confdefs.h. */
16767 #include <pthread.h>
16768 static void routine(void *a) { *((int*)a) = 0; }
16769 static void *start_routine(void *a) { return a; }
16770 int
16771 main ()
16772 {
16773 pthread_t th; pthread_attr_t attr;
16774 pthread_create(&th, 0, start_routine, 0);
16775 pthread_join(th, 0);
16776 pthread_attr_init(&attr);
16777 pthread_cleanup_push(routine, 0);
16778 pthread_cleanup_pop(0) /* ; */
16779 ;
16780 return 0;
16781 }
16782 _ACEOF
16783 if ac_fn_c_try_link "$LINENO"; then :
16784 ax_pthread_ok=yes
16785 fi
16786 rm -f core conftest.err conftest.$ac_objext \
16787 conftest$ac_exeext conftest.$ac_ext
16788
16789 LIBS="$save_LIBS"
16790 CFLAGS="$save_CFLAGS"
16791
16792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
16793 $as_echo "$ax_pthread_ok" >&6; }
16794 if test "x$ax_pthread_ok" = xyes; then
16795 break;
16796 fi
16797
16798 PTHREAD_LIBS=""
16799 PTHREAD_CFLAGS=""
16800 done
16801 fi
16802
16803 # Various other checks:
16804 if test "x$ax_pthread_ok" = xyes; then
16805 save_LIBS="$LIBS"
16806 LIBS="$PTHREAD_LIBS $LIBS"
16807 save_CFLAGS="$CFLAGS"
16808 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16809
16810 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
16811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
16812 $as_echo_n "checking for joinable pthread attribute... " >&6; }
16813 attr_name=unknown
16814 for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
16815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16816 /* end confdefs.h. */
16817 #include <pthread.h>
16818 int
16819 main ()
16820 {
16821 int attr = $attr; return attr /* ; */
16822 ;
16823 return 0;
16824 }
16825 _ACEOF
16826 if ac_fn_c_try_link "$LINENO"; then :
16827 attr_name=$attr; break
16828 fi
16829 rm -f core conftest.err conftest.$ac_objext \
16830 conftest$ac_exeext conftest.$ac_ext
16831 done
16832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
16833 $as_echo "$attr_name" >&6; }
16834 if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
16835
16836 cat >>confdefs.h <<_ACEOF
16837 #define PTHREAD_CREATE_JOINABLE $attr_name
16838 _ACEOF
16839
16840 fi
16841
16842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
16843 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
16844 flag=no
16845 case ${host_os} in
16846 aix* | freebsd* | darwin*) flag="-D_THREAD_SAFE";;
16847 osf* | hpux*) flag="-D_REENTRANT";;
16848 solaris*)
16849 if test "$GCC" = "yes"; then
16850 flag="-D_REENTRANT"
16851 else
16852 # TODO: What about Clang on Solaris?
16853 flag="-mt -D_REENTRANT"
16854 fi
16855 ;;
16856 esac
16857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $flag" >&5
16858 $as_echo "$flag" >&6; }
16859 if test "x$flag" != xno; then
16860 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16861 fi
16862
16863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
16864 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
16865 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
16866 $as_echo_n "(cached) " >&6
16867 else
16868
16869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16870 /* end confdefs.h. */
16871 #include <pthread.h>
16872 int
16873 main ()
16874 {
16875 int i = PTHREAD_PRIO_INHERIT;
16876 ;
16877 return 0;
16878 }
16879 _ACEOF
16880 if ac_fn_c_try_link "$LINENO"; then :
16881 ax_cv_PTHREAD_PRIO_INHERIT=yes
16882 else
16883 ax_cv_PTHREAD_PRIO_INHERIT=no
16884 fi
16885 rm -f core conftest.err conftest.$ac_objext \
16886 conftest$ac_exeext conftest.$ac_ext
16887
16888 fi
16889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
16890 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
16891 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
16892
16893 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
16894
16895 fi
16896
16897 LIBS="$save_LIBS"
16898 CFLAGS="$save_CFLAGS"
16899
16900 # More AIX lossage: compile with *_r variant
16901 if test "x$GCC" != xyes; then
16902 case $host_os in
16903 aix*)
16904 case "x/$CC" in #(
16905 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
16906 #handle absolute path differently from PATH based program lookup
16907 case "x$CC" in #(
16908 x/*) :
16909 if as_fn_executable_p ${CC}_r; then :
16910 PTHREAD_CC="${CC}_r"
16911 fi ;; #(
16912 *) :
16913 for ac_prog in ${CC}_r
16914 do
16915 # Extract the first word of "$ac_prog", so it can be a program name with args.
16916 set dummy $ac_prog; ac_word=$2
16917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16918 $as_echo_n "checking for $ac_word... " >&6; }
16919 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
16920 $as_echo_n "(cached) " >&6
16921 else
16922 if test -n "$PTHREAD_CC"; then
16923 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16924 else
16925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16926 for as_dir in $PATH
16927 do
16928 IFS=$as_save_IFS
16929 test -z "$as_dir" && as_dir=.
16930 for ac_exec_ext in '' $ac_executable_extensions; do
16931 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16932 ac_cv_prog_PTHREAD_CC="$ac_prog"
16933 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16934 break 2
16935 fi
16936 done
16937 done
16938 IFS=$as_save_IFS
16939
16940 fi
16941 fi
16942 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16943 if test -n "$PTHREAD_CC"; then
16944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
16945 $as_echo "$PTHREAD_CC" >&6; }
16946 else
16947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16948 $as_echo "no" >&6; }
16949 fi
16950
16951
16952 test -n "$PTHREAD_CC" && break
16953 done
16954 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
16955 ;;
16956 esac ;; #(
16957 *) :
16958 ;;
16959 esac
16960 ;;
16961 esac
16962 fi
16963 fi
16964
16965 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
16966
16967
16968
16969
16970
16971 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16972 if test x"$ax_pthread_ok" = xyes; then
16973
16974
16975 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
16976
16977 if test -n "$PTHREAD_LIBS"; then
16978 LIBS="$PTHREAD_LIBS $LIBS"
16979 fi
16980 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16981 CC="$PTHREAD_CC"
16982 ub_have_pthreads=yes
16983 ac_fn_c_check_type "$LINENO" "pthread_spinlock_t" "ac_cv_type_pthread_spinlock_t" "#include <pthread.h>
16984 "
16985 if test "x$ac_cv_type_pthread_spinlock_t" = xyes; then :
16986
16987 cat >>confdefs.h <<_ACEOF
16988 #define HAVE_PTHREAD_SPINLOCK_T 1
16989 _ACEOF
16990
16991
16992 fi
16993 ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
16994 "
16995 if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then :
16996
16997 cat >>confdefs.h <<_ACEOF
16998 #define HAVE_PTHREAD_RWLOCK_T 1
16999 _ACEOF
17000
17001
17002 fi
17003
17004
17005 if echo "$CFLAGS" | $GREP -e "-pthread" >/dev/null; then
17006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -pthread unused during linking" >&5
17007 $as_echo_n "checking if -pthread unused during linking... " >&6; }
17008 # catch clang warning 'argument unused during compilation'
17009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17010 /* end confdefs.h. */
17011 $ac_includes_default
17012
17013 int main(void) {return 0;}
17014
17015 _ACEOF
17016 pthread_unused="yes"
17017 # first compile
17018 echo "$CC $CFLAGS -c conftest.c -o conftest.o" >&5
17019 $CC $CFLAGS -c conftest.c -o conftest.o 2>&5 >&5
17020 if test $? = 0; then
17021 # then link
17022 echo "$CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest contest.o" >&5
17023 $CC $CFLAGS -Werror $LDFLAGS $LIBS -o conftest conftest.o 2>&5 >&5
17024 if test $? -ne 0; then
17025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17026 $as_echo "yes" >&6; }
17027 CFLAGS=`echo "$CFLAGS" | sed -e 's/-pthread//'`
17028 PTHREAD_CFLAGS_ONLY="-pthread"
17029
17030 else
17031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17032 $as_echo "no" >&6; }
17033 fi
17034 else
17035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17036 $as_echo "no" >&6; }
17037 fi # endif cc successful
17038 rm -f conftest conftest.c conftest.o
17039 fi # endif -pthread in CFLAGS
17040
17041
17042 :
17043 else
17044 ax_pthread_ok=no
17045
17046 fi
17047 ac_ext=c
17048 ac_cpp='$CPP $CPPFLAGS'
17049 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17050 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17051 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17052
17053
17054 fi
17055
17056 # check solaris thread library
17057
17058 # Check whether --with-solaris-threads was given.
17059 if test "${with_solaris_threads+set}" = set; then :
17060 withval=$with_solaris_threads;
17061 else
17062 withval="no"
17063 fi
17064
17065 ub_have_sol_threads=no
17066 if test x_$withval != x_no; then
17067 if test x_$ub_have_pthreads != x_no; then
17068 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&5
17069 $as_echo "$as_me: WARNING: Have pthreads already, ignoring --with-solaris-threads" >&2;}
17070 else
17071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing thr_create" >&5
17072 $as_echo_n "checking for library containing thr_create... " >&6; }
17073 if ${ac_cv_search_thr_create+:} false; then :
17074 $as_echo_n "(cached) " >&6
17075 else
17076 ac_func_search_save_LIBS=$LIBS
17077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17078 /* end confdefs.h. */
17079
17080 /* Override any GCC internal prototype to avoid an error.
17081 Use char because int might match the return type of a GCC
17082 builtin and then its argument prototype would still apply. */
17083 #ifdef __cplusplus
17084 extern "C"
17085 #endif
17086 char thr_create ();
17087 int
17088 main ()
17089 {
17090 return thr_create ();
17091 ;
17092 return 0;
17093 }
17094 _ACEOF
17095 for ac_lib in '' thread; do
17096 if test -z "$ac_lib"; then
17097 ac_res="none required"
17098 else
17099 ac_res=-l$ac_lib
17100 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17101 fi
17102 if ac_fn_c_try_link "$LINENO"; then :
17103 ac_cv_search_thr_create=$ac_res
17104 fi
17105 rm -f core conftest.err conftest.$ac_objext \
17106 conftest$ac_exeext
17107 if ${ac_cv_search_thr_create+:} false; then :
17108 break
17109 fi
17110 done
17111 if ${ac_cv_search_thr_create+:} false; then :
17112
17113 else
17114 ac_cv_search_thr_create=no
17115 fi
17116 rm conftest.$ac_ext
17117 LIBS=$ac_func_search_save_LIBS
17118 fi
17119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_thr_create" >&5
17120 $as_echo "$ac_cv_search_thr_create" >&6; }
17121 ac_res=$ac_cv_search_thr_create
17122 if test "$ac_res" != no; then :
17123 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17124
17125
17126 $as_echo "#define HAVE_SOLARIS_THREADS 1" >>confdefs.h
17127
17128
17129
17130
17131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -mt" >&5
17132 $as_echo_n "checking whether $CC supports -mt... " >&6; }
17133 cache=`echo mt | sed 'y%.=/+-%___p_%'`
17134 if eval \${cv_prog_cc_flag_$cache+:} false; then :
17135 $as_echo_n "(cached) " >&6
17136 else
17137
17138 echo 'void f(void){}' >conftest.c
17139 if test -z "`$CC $CPPFLAGS $CFLAGS -mt -c conftest.c 2>&1`"; then
17140 eval "cv_prog_cc_flag_$cache=yes"
17141 else
17142 eval "cv_prog_cc_flag_$cache=no"
17143 fi
17144 rm -f conftest conftest.o conftest.c
17145
17146 fi
17147
17148 if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then
17149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17150 $as_echo "yes" >&6; }
17151 :
17152 CFLAGS="$CFLAGS -mt"
17153 else
17154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17155 $as_echo "no" >&6; }
17156 :
17157 CFLAGS="$CFLAGS -D_REENTRANT"
17158 fi
17159
17160 ub_have_sol_threads=yes
17161
17162 else
17163
17164 as_fn_error $? "no solaris threads found." "$LINENO" 5
17165
17166 fi
17167
17168 fi
17169 fi
17170
17171 fi # end of non-mingw check of thread libraries
17172
17173 # Check for SYSLOG_FACILITY
17174
17175 # Check whether --with-syslog-facility was given.
17176 if test "${with_syslog_facility+set}" = set; then :
17177 withval=$with_syslog_facility; UNBOUND_SYSLOG_FACILITY="$withval"
17178 fi
17179
17180 case "${UNBOUND_SYSLOG_FACILITY}" in
17181
17182 LOCAL[0-7]) UNBOUND_SYSLOG_FACILITY="LOG_${UNBOUND_SYSLOG_FACILITY}" ;;
17183
17184 *) UNBOUND_SYSLOG_FACILITY="LOG_DAEMON" ;;
17185
17186 esac
17187
17188 cat >>confdefs.h <<_ACEOF
17189 #define UB_SYSLOG_FACILITY ${UNBOUND_SYSLOG_FACILITY}
17190 _ACEOF
17191
17192
17193 # Check for PyUnbound
17194
17195 # Check whether --with-pyunbound was given.
17196 if test "${with_pyunbound+set}" = set; then :
17197 withval=$with_pyunbound;
17198 else
17199 withval="no"
17200 fi
17201
17202
17203 ub_test_python=no
17204 ub_with_pyunbound=no
17205 if test x_$withval != x_no; then
17206 ub_with_pyunbound=yes
17207 ub_test_python=yes
17208 fi
17209
17210 # Check for Python module
17211
17212 # Check whether --with-pythonmodule was given.
17213 if test "${with_pythonmodule+set}" = set; then :
17214 withval=$with_pythonmodule;
17215 else
17216 withval="no"
17217 fi
17218
17219
17220 ub_with_pythonmod=no
17221 if test x_$withval != x_no; then
17222 ub_with_pythonmod=yes
17223 ub_test_python=yes
17224 fi
17225
17226 # Check for Python & SWIG only on PyUnbound or PyModule
17227 if test x_$ub_test_python != x_no; then
17228
17229 # Check for Python
17230 ub_have_python=no
17231 ac_save_LIBS="$LIBS"
17232 #
17233 # Allow the use of a (user set) custom python version
17234 #
17235
17236
17237 # Extract the first word of "python[$PYTHON_VERSION]", so it can be a program name with args.
17238 set dummy python$PYTHON_VERSION; ac_word=$2
17239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17240 $as_echo_n "checking for $ac_word... " >&6; }
17241 if ${ac_cv_path_PYTHON+:} false; then :
17242 $as_echo_n "(cached) " >&6
17243 else
17244 case $PYTHON in
17245 [\\/]* | ?:[\\/]*)
17246 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
17247 ;;
17248 *)
17249 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17250 for as_dir in $PATH
17251 do
17252 IFS=$as_save_IFS
17253 test -z "$as_dir" && as_dir=.
17254 for ac_exec_ext in '' $ac_executable_extensions; do
17255 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17256 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
17257 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17258 break 2
17259 fi
17260 done
17261 done
17262 IFS=$as_save_IFS
17263
17264 ;;
17265 esac
17266 fi
17267 PYTHON=$ac_cv_path_PYTHON
17268 if test -n "$PYTHON"; then
17269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
17270 $as_echo "$PYTHON" >&6; }
17271 else
17272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17273 $as_echo "no" >&6; }
17274 fi
17275
17276
17277 if test -z "$PYTHON"; then
17278 as_fn_error $? "Cannot find python$PYTHON_VERSION in your system path" "$LINENO" 5
17279 PYTHON_VERSION=""
17280 fi
17281
17282 if test -z "$PYTHON_VERSION"; then
17283 PYTHON_VERSION=`$PYTHON -c "import sys; \
17284 print(sys.version.split()[0])"`
17285 fi
17286
17287 #
17288 # Check if you have distutils, else fail
17289 #
17290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the distutils Python package" >&5
17291 $as_echo_n "checking for the distutils Python package... " >&6; }
17292 if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then
17293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17294 $as_echo "yes" >&6; }
17295 else
17296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17297 $as_echo "no" >&6; }
17298 as_fn_error $? "cannot import Python module \"distutils\".
17299 Please check your Python installation. The error was:
17300 $ac_distutils_result" "$LINENO" 5
17301 PYTHON_VERSION=""
17302 fi
17303
17304 #
17305 # Check for Python include path
17306 #
17307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python include path" >&5
17308 $as_echo_n "checking for Python include path... " >&6; }
17309 if test -z "$PYTHON_CPPFLAGS"; then
17310 python_path=`$PYTHON -c "import distutils.sysconfig; \
17311 print(distutils.sysconfig.get_python_inc());"`
17312 if test -n "${python_path}"; then
17313 python_path="-I$python_path"
17314 fi
17315 PYTHON_CPPFLAGS=$python_path
17316 fi
17317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CPPFLAGS" >&5
17318 $as_echo "$PYTHON_CPPFLAGS" >&6; }
17319
17320
17321 #
17322 # Check for Python library path
17323 #
17324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python library path" >&5
17325 $as_echo_n "checking for Python library path... " >&6; }
17326 if test -z "$PYTHON_LDFLAGS"; then
17327 PYTHON_LDFLAGS=`$PYTHON -c "from distutils.sysconfig import *; \
17328 print('-L'+get_config_var('LIBDIR')+' -L'+get_config_var('LIBDEST')+' '+get_config_var('BLDLIBRARY'));"`
17329 fi
17330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_LDFLAGS" >&5
17331 $as_echo "$PYTHON_LDFLAGS" >&6; }
17332
17333
17334 #
17335 # Check for site packages
17336 #
17337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python site-packages path" >&5
17338 $as_echo_n "checking for Python site-packages path... " >&6; }
17339 if test -z "$PYTHON_SITE_PKG"; then
17340 PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
17341 print(distutils.sysconfig.get_python_lib(1,0));"`
17342 fi
17343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_SITE_PKG" >&5
17344 $as_echo "$PYTHON_SITE_PKG" >&6; }
17345
17346
17347 #
17348 # final check to see if everything compiles alright
17349 #
17350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking consistency of all components of python development environment" >&5
17351 $as_echo_n "checking consistency of all components of python development environment... " >&6; }
17352 ac_ext=c
17353 ac_cpp='$CPP $CPPFLAGS'
17354 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17355 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17356 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17357
17358 # save current global flags
17359 ac_save_LIBS="$LIBS"
17360 ac_save_CPPFLAGS="$CPPFLAGS"
17361
17362 LIBS="$LIBS $PYTHON_LDFLAGS"
17363 CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17365 /* end confdefs.h. */
17366
17367 #include <Python.h>
17368
17369 int
17370 main ()
17371 {
17372
17373 Py_Initialize();
17374
17375 ;
17376 return 0;
17377 }
17378 _ACEOF
17379 if ac_fn_c_try_link "$LINENO"; then :
17380 pythonexists=yes
17381 else
17382 pythonexists=no
17383 fi
17384 rm -f core conftest.err conftest.$ac_objext \
17385 conftest$ac_exeext conftest.$ac_ext
17386
17387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pythonexists" >&5
17388 $as_echo "$pythonexists" >&6; }
17389
17390 if test ! "$pythonexists" = "yes"; then
17391 as_fn_error $? "
17392 Could not link test program to Python. Maybe the main Python library has been
17393 installed in some non-standard library path. If so, pass it to configure,
17394 via the LDFLAGS environment variable.
17395 Example: ./configure LDFLAGS=\"-L/usr/non-standard-path/python/lib\"
17396 ============================================================================
17397 ERROR!
17398 You probably have to install the development version of the Python package
17399 for your distribution. The exact name of this package varies among them.
17400 ============================================================================
17401 " "$LINENO" 5
17402 PYTHON_VERSION=""
17403 fi
17404 ac_ext=c
17405 ac_cpp='$CPP $CPPFLAGS'
17406 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17407 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17408 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17409
17410 # turn back to default flags
17411 CPPFLAGS="$ac_save_CPPFLAGS"
17412 LIBS="$ac_save_LIBS"
17413
17414 #
17415 # all done!
17416 #
17417
17418 if test ! -z "$PYTHON_VERSION"; then
17419 if test `$PYTHON -c "print('$PYTHON_VERSION' >= '2.4.0')"` = "False"; then
17420 as_fn_error $? "Python version >= 2.4.0 is required" "$LINENO" 5
17421 fi
17422
17423 PY_MAJOR_VERSION="`$PYTHON -c \"import sys; print(sys.version_info[0])\"`"
17424
17425 # Have Python
17426
17427 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
17428
17429 if test -n "$LIBS"; then
17430 LIBS="$PYTHON_LDFLAGS $LIBS"
17431 else
17432 LIBS="$PYTHON_LDFLAGS"
17433 fi
17434 if test -n "$CPPFLAGS"; then
17435 CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
17436 else
17437 CPPFLAGS="$PYTHON_CPPFLAGS"
17438 fi
17439 ub_have_python=yes
17440 if test -n "$PKG_CONFIG" && \
17441 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\"python\${PY_MAJOR_VERSION}\"\""; } >&5
17442 ($PKG_CONFIG --exists --print-errors ""python${PY_MAJOR_VERSION}"") 2>&5
17443 ac_status=$?
17444 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17445 test $ac_status = 0; }; then
17446 PC_PY_DEPENDENCY="python${PY_MAJOR_VERSION}"
17447 else
17448 PC_PY_DEPENDENCY="python"
17449 fi
17450
17451
17452 # Check for SWIG
17453 ub_have_swig=no
17454 # Check whether --enable-swig-version-check was given.
17455 if test "${enable_swig_version_check+set}" = set; then :
17456 enableval=$enable_swig_version_check;
17457 fi
17458
17459 if test "$enable_swig_version_check" = "yes"; then
17460
17461 # Extract the first word of "swig", so it can be a program name with args.
17462 set dummy swig; ac_word=$2
17463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17464 $as_echo_n "checking for $ac_word... " >&6; }
17465 if ${ac_cv_path_SWIG+:} false; then :
17466 $as_echo_n "(cached) " >&6
17467 else
17468 case $SWIG in
17469 [\\/]* | ?:[\\/]*)
17470 ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17471 ;;
17472 *)
17473 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17474 for as_dir in $PATH
17475 do
17476 IFS=$as_save_IFS
17477 test -z "$as_dir" && as_dir=.
17478 for ac_exec_ext in '' $ac_executable_extensions; do
17479 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17480 ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17481 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17482 break 2
17483 fi
17484 done
17485 done
17486 IFS=$as_save_IFS
17487
17488 ;;
17489 esac
17490 fi
17491 SWIG=$ac_cv_path_SWIG
17492 if test -n "$SWIG"; then
17493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17494 $as_echo "$SWIG" >&6; }
17495 else
17496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17497 $as_echo "no" >&6; }
17498 fi
17499
17500
17501 if test -z "$SWIG" ; then
17502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17503 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17504 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17505 elif test -n "2.0.1" ; then
17506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17507 $as_echo_n "checking for SWIG version... " >&6; }
17508 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'`
17509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17510 $as_echo "$swig_version" >&6; }
17511 if test -n "$swig_version" ; then
17512 # Calculate the required version number components
17513 required=2.0.1
17514 required_major=`echo $required | sed 's/[^0-9].*//'`
17515 if test -z "$required_major" ; then
17516 required_major=0
17517 fi
17518 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17519 required_minor=`echo $required | sed 's/[^0-9].*//'`
17520 if test -z "$required_minor" ; then
17521 required_minor=0
17522 fi
17523 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17524 required_patch=`echo $required | sed 's/[^0-9].*//'`
17525 if test -z "$required_patch" ; then
17526 required_patch=0
17527 fi
17528 # Calculate the available version number components
17529 available=$swig_version
17530 available_major=`echo $available | sed 's/[^0-9].*//'`
17531 if test -z "$available_major" ; then
17532 available_major=0
17533 fi
17534 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17535 available_minor=`echo $available | sed 's/[^0-9].*//'`
17536 if test -z "$available_minor" ; then
17537 available_minor=0
17538 fi
17539 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17540 available_patch=`echo $available | sed 's/[^0-9].*//'`
17541 if test -z "$available_patch" ; then
17542 available_patch=0
17543 fi
17544 badversion=0
17545 if test $available_major -lt $required_major ; then
17546 badversion=1
17547 fi
17548 if test $available_major -eq $required_major \
17549 -a $available_minor -lt $required_minor ; then
17550 badversion=1
17551 fi
17552 if test $available_major -eq $required_major \
17553 -a $available_minor -eq $required_minor \
17554 -a $available_patch -lt $required_patch ; then
17555 badversion=1
17556 fi
17557 if test $badversion -eq 1 ; then
17558 { $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
17559 $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;}
17560 SWIG='echo "Error: SWIG version >= 2.0.1 is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false'
17561 else
17562 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
17563 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
17564 SWIG_LIB=`$SWIG -swiglib`
17565 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
17566 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
17567 fi
17568 else
17569 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
17570 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
17571 SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false'
17572 fi
17573 fi
17574
17575
17576 else
17577
17578 # Extract the first word of "swig", so it can be a program name with args.
17579 set dummy swig; ac_word=$2
17580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17581 $as_echo_n "checking for $ac_word... " >&6; }
17582 if ${ac_cv_path_SWIG+:} false; then :
17583 $as_echo_n "(cached) " >&6
17584 else
17585 case $SWIG in
17586 [\\/]* | ?:[\\/]*)
17587 ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
17588 ;;
17589 *)
17590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17591 for as_dir in $PATH
17592 do
17593 IFS=$as_save_IFS
17594 test -z "$as_dir" && as_dir=.
17595 for ac_exec_ext in '' $ac_executable_extensions; do
17596 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17597 ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext"
17598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17599 break 2
17600 fi
17601 done
17602 done
17603 IFS=$as_save_IFS
17604
17605 ;;
17606 esac
17607 fi
17608 SWIG=$ac_cv_path_SWIG
17609 if test -n "$SWIG"; then
17610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5
17611 $as_echo "$SWIG" >&6; }
17612 else
17613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17614 $as_echo "no" >&6; }
17615 fi
17616
17617
17618 if test -z "$SWIG" ; then
17619 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&5
17620 $as_echo "$as_me: WARNING: cannot find 'swig' program. You should look at http://www.swig.org" >&2;}
17621 SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false'
17622 elif test -n "" ; then
17623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5
17624 $as_echo_n "checking for SWIG version... " >&6; }
17625 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'`
17626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5
17627 $as_echo "$swig_version" >&6; }
17628 if test -n "$swig_version" ; then
17629 # Calculate the required version number components
17630 required=
17631 required_major=`echo $required | sed 's/[^0-9].*//'`
17632 if test -z "$required_major" ; then
17633 required_major=0
17634 fi
17635 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17636 required_minor=`echo $required | sed 's/[^0-9].*//'`
17637 if test -z "$required_minor" ; then
17638 required_minor=0
17639 fi
17640 required=`echo $required | sed 's/[0-9]*[^0-9]//'`
17641 required_patch=`echo $required | sed 's/[^0-9].*//'`
17642 if test -z "$required_patch" ; then
17643 required_patch=0
17644 fi
17645 # Calculate the available version number components
17646 available=$swig_version
17647 available_major=`echo $available | sed 's/[^0-9].*//'`
17648 if test -z "$available_major" ; then
17649 available_major=0
17650 fi
17651 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17652 available_minor=`echo $available | sed 's/[^0-9].*//'`
17653 if test -z "$available_minor" ; then
17654 available_minor=0
17655 fi
17656 available=`echo $available | sed 's/[0-9]*[^0-9]//'`
17657 available_patch=`echo $available | sed 's/[^0-9].*//'`
17658 if test -z "$available_patch" ; then
17659 available_patch=0
17660 fi
17661 badversion=0
17662 if test $available_major -lt $required_major ; then
17663 badversion=1
17664 fi
17665 if test $available_major -eq $required_major \
17666 -a $available_minor -lt $required_minor ; then
17667 badversion=1
17668 fi
17669 if test $available_major -eq $required_major \
17670 -a $available_minor -eq $required_minor \
17671 -a $available_patch -lt $required_patch ; then
17672 badversion=1
17673 fi
17674 if test $badversion -eq 1 ; then
17675 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= is required. You have $swig_version. You should look at http://www.swig.org" >&5
17676 $as_echo "$as_me: WARNING: SWIG version >= is required. You have $swig_version. You should look at http://www.swig.org" >&2;}
17677 SWIG='echo "Error: SWIG version >= is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false'
17678 else
17679 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG executable is '$SWIG'" >&5
17680 $as_echo "$as_me: SWIG executable is '$SWIG'" >&6;}
17681 SWIG_LIB=`$SWIG -swiglib`
17682 { $as_echo "$as_me:${as_lineno-$LINENO}: SWIG library directory is '$SWIG_LIB'" >&5
17683 $as_echo "$as_me: SWIG library directory is '$SWIG_LIB'" >&6;}
17684 fi
17685 else
17686 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5
17687 $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;}
17688 SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false'
17689 fi
17690 fi
17691
17692
17693 fi
17694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG" >&5
17695 $as_echo_n "checking SWIG... " >&6; }
17696 if test ! -x "$SWIG"; then
17697 as_fn_error $? "failed to find swig tool, install it, or do not build Python module and PyUnbound" "$LINENO" 5
17698 else
17699
17700 $as_echo "#define HAVE_SWIG 1" >>confdefs.h
17701
17702 swig="$SWIG"
17703
17704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present" >&5
17705 $as_echo "present" >&6; }
17706
17707 # If have Python & SWIG
17708 # Declare PythonMod
17709 if test x_$ub_with_pythonmod != x_no; then
17710
17711 $as_echo "#define WITH_PYTHONMODULE 1" >>confdefs.h
17712
17713 WITH_PYTHONMODULE=yes
17714
17715 PYTHONMOD_OBJ="pythonmod.lo pythonmod_utils.lo"
17716
17717 PYTHONMOD_HEADER='$(srcdir)/pythonmod/pythonmod.h'
17718
17719 PYTHONMOD_INSTALL=pythonmod-install
17720
17721 PYTHONMOD_UNINSTALL=pythonmod-uninstall
17722
17723 fi
17724
17725 # Declare PyUnbound
17726 if test x_$ub_with_pyunbound != x_no; then
17727
17728 $as_echo "#define WITH_PYUNBOUND 1" >>confdefs.h
17729
17730 WITH_PYUNBOUND=yes
17731
17732 PYUNBOUND_OBJ="libunbound_wrap.lo"
17733
17734 PYUNBOUND_TARGET="_unbound.la"
17735
17736 PYUNBOUND_INSTALL=pyunbound-install
17737
17738 PYUNBOUND_UNINSTALL=pyunbound-uninstall
17739
17740 fi
17741 fi
17742 else
17743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: *** Python libraries not found, won't build PythonMod or PyUnbound ***" >&5
17744 $as_echo "*** Python libraries not found, won't build PythonMod or PyUnbound ***" >&6; }
17745 ub_with_pyunbound=no
17746 ub_with_pythonmod=no
17747 fi
17748 fi
17749
17750 if test "`uname`" = "NetBSD"; then
17751 NETBSD_LINTFLAGS='"-D__RENAME(x)=" -D_NETINET_IN_H_'
17752
17753 fi
17754 CONFIG_DATE=`date +%Y%m%d`
17755
17756
17757 # Checks for libraries.
17758
17759 # libnss
17760 USE_NSS="no"
17761
17762 # Check whether --with-nss was given.
17763 if test "${with_nss+set}" = set; then :
17764 withval=$with_nss;
17765 USE_NSS="yes"
17766
17767 $as_echo "#define HAVE_NSS 1" >>confdefs.h
17768
17769 if test "$withval" != "" -a "$withval" != "yes"; then
17770 CPPFLAGS="$CPPFLAGS -I$withval/include/nss3"
17771 LDFLAGS="$LDFLAGS -L$withval/lib"
17772
17773 if test "x$enable_rpath" = xyes; then
17774 if echo "$withval/lib" | grep "^/" >/dev/null; then
17775 RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
17776 fi
17777 fi
17778
17779 CPPFLAGS="-I$withval/include/nspr4 $CPPFLAGS"
17780 else
17781 CPPFLAGS="$CPPFLAGS -I/usr/include/nss3"
17782 CPPFLAGS="-I/usr/include/nspr4 $CPPFLAGS"
17783 fi
17784 LIBS="$LIBS -lnss3 -lnspr4"
17785 SSLLIB=""
17786
17787
17788 fi
17789
17790
17791 # libnettle
17792 USE_NETTLE="no"
17793
17794 # Check whether --with-nettle was given.
17795 if test "${with_nettle+set}" = set; then :
17796 withval=$with_nettle;
17797 USE_NETTLE="yes"
17798
17799 $as_echo "#define HAVE_NETTLE 1" >>confdefs.h
17800
17801 for ac_header in nettle/dsa-compat.h
17802 do :
17803 ac_fn_c_check_header_compile "$LINENO" "nettle/dsa-compat.h" "ac_cv_header_nettle_dsa_compat_h" "$ac_includes_default
17804 "
17805 if test "x$ac_cv_header_nettle_dsa_compat_h" = xyes; then :
17806 cat >>confdefs.h <<_ACEOF
17807 #define HAVE_NETTLE_DSA_COMPAT_H 1
17808 _ACEOF
17809
17810 fi
17811
17812 done
17813
17814 if test "$withval" != "" -a "$withval" != "yes"; then
17815 CPPFLAGS="$CPPFLAGS -I$withval/include/nettle"
17816 LDFLAGS="$LDFLAGS -L$withval/lib"
17817
17818 if test "x$enable_rpath" = xyes; then
17819 if echo "$withval/lib" | grep "^/" >/dev/null; then
17820 RUNTIME_PATH="$RUNTIME_PATH -R$withval/lib"
17821 fi
17822 fi
17823
17824 else
17825 CPPFLAGS="$CPPFLAGS -I/usr/include/nettle"
17826 fi
17827 LIBS="$LIBS -lhogweed -lnettle -lgmp"
17828 SSLLIB=""
17829
17830
17831 fi
17832
17833
17834 # openssl
17835 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
17836
17837
17838 # Check whether --with-ssl was given.
17839 if test "${with_ssl+set}" = set; then :
17840 withval=$with_ssl;
17841
17842 else
17843
17844 withval="yes"
17845
17846 fi
17847
17848 if test x_$withval = x_no; then
17849 as_fn_error $? "Need SSL library to do digital signature cryptography" "$LINENO" 5
17850 fi
17851
17852 withval=$withval
17853 if test x_$withval != x_no; then
17854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL" >&5
17855 $as_echo_n "checking for SSL... " >&6; }
17856 if test x_$withval = x_ -o x_$withval = x_yes; then
17857 withval="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /opt/local /usr/sfw /usr"
17858 fi
17859 for dir in $withval; do
17860 ssldir="$dir"
17861 if test -f "$dir/include/openssl/ssl.h"; then
17862 found_ssl="yes"
17863
17864 cat >>confdefs.h <<_ACEOF
17865 #define HAVE_SSL /**/
17866 _ACEOF
17867
17868 if test "$ssldir" != "/usr"; then
17869 CPPFLAGS="$CPPFLAGS -I$ssldir/include"
17870 LIBSSL_CPPFLAGS="$LIBSSL_CPPFLAGS -I$ssldir/include"
17871 fi
17872 break;
17873 fi
17874 done
17875 if test x_$found_ssl != x_yes; then
17876 as_fn_error $? "Cannot find the SSL libraries in $withval" "$LINENO" 5
17877 else
17878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $ssldir" >&5
17879 $as_echo "found in $ssldir" >&6; }
17880 HAVE_SSL=yes
17881 if test "$ssldir" != "/usr" -a "$ssldir" != ""; then
17882 LDFLAGS="$LDFLAGS -L$ssldir/lib"
17883 LIBSSL_LDFLAGS="$LIBSSL_LDFLAGS -L$ssldir/lib"
17884
17885 if test "x$enable_rpath" = xyes; then
17886 if echo "$ssldir/lib" | grep "^/" >/dev/null; then
17887 RUNTIME_PATH="$RUNTIME_PATH -R$ssldir/lib"
17888 fi
17889 fi
17890
17891 fi
17892
17893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Update in -lcrypto" >&5
17894 $as_echo_n "checking for HMAC_Update in -lcrypto... " >&6; }
17895 LIBS="$LIBS -lcrypto"
17896 LIBSSL_LIBS="$LIBSSL_LIBS -lcrypto"
17897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17898 /* end confdefs.h. */
17899
17900 int
17901 main ()
17902 {
17903
17904 int HMAC_Update(void);
17905 (void)HMAC_Update();
17906
17907 ;
17908 return 0;
17909 }
17910 _ACEOF
17911 if ac_fn_c_try_link "$LINENO"; then :
17912
17913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17914 $as_echo "yes" >&6; }
17915
17916 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17917
17918
17919 else
17920
17921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17922 $as_echo "no" >&6; }
17923 # check if -lwsock32 or -lgdi32 are needed.
17924 BAKLIBS="$LIBS"
17925 BAKSSLLIBS="$LIBSSL_LIBS"
17926 LIBS="$LIBS -lgdi32 -lws2_32"
17927 LIBSSL_LIBS="$LIBSSL_LIBS -lgdi32 -lws2_32"
17928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -lgdi32" >&5
17929 $as_echo_n "checking if -lcrypto needs -lgdi32... " >&6; }
17930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17931 /* end confdefs.h. */
17932
17933 int
17934 main ()
17935 {
17936
17937 int HMAC_Update(void);
17938 (void)HMAC_Update();
17939
17940 ;
17941 return 0;
17942 }
17943 _ACEOF
17944 if ac_fn_c_try_link "$LINENO"; then :
17945
17946
17947 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17948
17949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17950 $as_echo "yes" >&6; }
17951
17952 else
17953
17954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17955 $as_echo "no" >&6; }
17956 LIBS="$BAKLIBS"
17957 LIBSSL_LIBS="$BAKSSLLIBS"
17958 LIBS="$LIBS -ldl"
17959 LIBSSL_LIBS="$LIBSSL_LIBS -ldl"
17960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl" >&5
17961 $as_echo_n "checking if -lcrypto needs -ldl... " >&6; }
17962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17963 /* end confdefs.h. */
17964
17965 int
17966 main ()
17967 {
17968
17969 int HMAC_Update(void);
17970 (void)HMAC_Update();
17971
17972 ;
17973 return 0;
17974 }
17975 _ACEOF
17976 if ac_fn_c_try_link "$LINENO"; then :
17977
17978
17979 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
17980
17981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17982 $as_echo "yes" >&6; }
17983
17984 else
17985
17986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17987 $as_echo "no" >&6; }
17988 LIBS="$BAKLIBS"
17989 LIBSSL_LIBS="$BAKSSLLIBS"
17990 LIBS="$LIBS -ldl -pthread"
17991 LIBSSL_LIBS="$LIBSSL_LIBS -ldl -pthread"
17992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if -lcrypto needs -ldl -pthread" >&5
17993 $as_echo_n "checking if -lcrypto needs -ldl -pthread... " >&6; }
17994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17995 /* end confdefs.h. */
17996
17997 int
17998 main ()
17999 {
18000
18001 int HMAC_Update(void);
18002 (void)HMAC_Update();
18003
18004 ;
18005 return 0;
18006 }
18007 _ACEOF
18008 if ac_fn_c_try_link "$LINENO"; then :
18009
18010
18011 $as_echo "#define HAVE_HMAC_UPDATE 1" >>confdefs.h
18012
18013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18014 $as_echo "yes" >&6; }
18015
18016 else
18017
18018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18019 $as_echo "no" >&6; }
18020 as_fn_error $? "OpenSSL found in $ssldir, but version 0.9.7 or higher is required" "$LINENO" 5
18021
18022 fi
18023 rm -f core conftest.err conftest.$ac_objext \
18024 conftest$ac_exeext conftest.$ac_ext
18025
18026 fi
18027 rm -f core conftest.err conftest.$ac_objext \
18028 conftest$ac_exeext conftest.$ac_ext
18029
18030 fi
18031 rm -f core conftest.err conftest.$ac_objext \
18032 conftest$ac_exeext conftest.$ac_ext
18033
18034 fi
18035 rm -f core conftest.err conftest.$ac_objext \
18036 conftest$ac_exeext conftest.$ac_ext
18037 fi
18038
18039
18040 fi
18041 for ac_header in openssl/ssl.h
18042 do :
18043 ac_fn_c_check_header_compile "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default
18044 "
18045 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
18046 cat >>confdefs.h <<_ACEOF
18047 #define HAVE_OPENSSL_SSL_H 1
18048 _ACEOF
18049
18050 fi
18051
18052 done
18053
18054 for ac_header in openssl/err.h
18055 do :
18056 ac_fn_c_check_header_compile "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default
18057 "
18058 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
18059 cat >>confdefs.h <<_ACEOF
18060 #define HAVE_OPENSSL_ERR_H 1
18061 _ACEOF
18062
18063 fi
18064
18065 done
18066
18067 for ac_header in openssl/rand.h
18068 do :
18069 ac_fn_c_check_header_compile "$LINENO" "openssl/rand.h" "ac_cv_header_openssl_rand_h" "$ac_includes_default
18070 "
18071 if test "x$ac_cv_header_openssl_rand_h" = xyes; then :
18072 cat >>confdefs.h <<_ACEOF
18073 #define HAVE_OPENSSL_RAND_H 1
18074 _ACEOF
18075
18076 fi
18077
18078 done
18079
18080
18081
18082
18083 # check if libssl needs libdl
18084 BAKLIBS="$LIBS"
18085 LIBS="-lssl $LIBS"
18086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs libdl" >&5
18087 $as_echo_n "checking if libssl needs libdl... " >&6; }
18088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18089 /* end confdefs.h. */
18090
18091 /* Override any GCC internal prototype to avoid an error.
18092 Use char because int might match the return type of a GCC
18093 builtin and then its argument prototype would still apply. */
18094 #ifdef __cplusplus
18095 extern "C"
18096 #endif
18097 char SSL_CTX_new ();
18098 int
18099 main ()
18100 {
18101 return SSL_CTX_new ();
18102 ;
18103 return 0;
18104 }
18105 _ACEOF
18106 if ac_fn_c_try_link "$LINENO"; then :
18107
18108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18109 $as_echo "no" >&6; }
18110 LIBS="$BAKLIBS"
18111
18112 else
18113
18114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18115 $as_echo "yes" >&6; }
18116 LIBS="$BAKLIBS"
18117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
18118 $as_echo_n "checking for library containing dlopen... " >&6; }
18119 if ${ac_cv_search_dlopen+:} false; then :
18120 $as_echo_n "(cached) " >&6
18121 else
18122 ac_func_search_save_LIBS=$LIBS
18123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18124 /* end confdefs.h. */
18125
18126 /* Override any GCC internal prototype to avoid an error.
18127 Use char because int might match the return type of a GCC
18128 builtin and then its argument prototype would still apply. */
18129 #ifdef __cplusplus
18130 extern "C"
18131 #endif
18132 char dlopen ();
18133 int
18134 main ()
18135 {
18136 return dlopen ();
18137 ;
18138 return 0;
18139 }
18140 _ACEOF
18141 for ac_lib in '' dl; do
18142 if test -z "$ac_lib"; then
18143 ac_res="none required"
18144 else
18145 ac_res=-l$ac_lib
18146 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
18147 fi
18148 if ac_fn_c_try_link "$LINENO"; then :
18149 ac_cv_search_dlopen=$ac_res
18150 fi
18151 rm -f core conftest.err conftest.$ac_objext \
18152 conftest$ac_exeext
18153 if ${ac_cv_search_dlopen+:} false; then :
18154 break
18155 fi
18156 done
18157 if ${ac_cv_search_dlopen+:} false; then :
18158
18159 else
18160 ac_cv_search_dlopen=no
18161 fi
18162 rm conftest.$ac_ext
18163 LIBS=$ac_func_search_save_LIBS
18164 fi
18165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
18166 $as_echo "$ac_cv_search_dlopen" >&6; }
18167 ac_res=$ac_cv_search_dlopen
18168 if test "$ac_res" != no; then :
18169 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18170
18171 fi
18172
18173
18174 fi
18175 rm -f core conftest.err conftest.$ac_objext \
18176 conftest$ac_exeext conftest.$ac_ext
18177 SSLLIB="-lssl"
18178
18179 # check if -lcrypt32 is needed because CAPIENG needs that. (on windows)
18180 BAKLIBS="$LIBS"
18181 LIBS="-lssl $LIBS"
18182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libssl needs -lcrypt32" >&5
18183 $as_echo_n "checking if libssl needs -lcrypt32... " >&6; }
18184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18185 /* end confdefs.h. */
18186
18187 /* Override any GCC internal prototype to avoid an error.
18188 Use char because int might match the return type of a GCC
18189 builtin and then its argument prototype would still apply. */
18190 #ifdef __cplusplus
18191 extern "C"
18192 #endif
18193 char HMAC_Update ();
18194 int
18195 main ()
18196 {
18197 return HMAC_Update ();
18198 ;
18199 return 0;
18200 }
18201 _ACEOF
18202 if ac_fn_c_try_link "$LINENO"; then :
18203
18204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18205 $as_echo "no" >&6; }
18206 LIBS="$BAKLIBS"
18207
18208 else
18209
18210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18211 $as_echo "yes" >&6; }
18212 LIBS="$BAKLIBS"
18213 LIBS="$LIBS -lcrypt32"
18214
18215 fi
18216 rm -f core conftest.err conftest.$ac_objext \
18217 conftest$ac_exeext conftest.$ac_ext
18218
18219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LibreSSL" >&5
18220 $as_echo_n "checking for LibreSSL... " >&6; }
18221 if grep VERSION_TEXT $ssldir/include/openssl/opensslv.h | grep "LibreSSL" >/dev/null; then
18222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18223 $as_echo "yes" >&6; }
18224
18225 $as_echo "#define HAVE_LIBRESSL 1" >>confdefs.h
18226
18227 # libressl provides these compat functions, but they may also be
18228 # declared by the OS in libc. See if they have been declared.
18229 ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
18230 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
18231 ac_have_decl=1
18232 else
18233 ac_have_decl=0
18234 fi
18235
18236 cat >>confdefs.h <<_ACEOF
18237 #define HAVE_DECL_STRLCPY $ac_have_decl
18238 _ACEOF
18239 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
18240 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
18241 ac_have_decl=1
18242 else
18243 ac_have_decl=0
18244 fi
18245
18246 cat >>confdefs.h <<_ACEOF
18247 #define HAVE_DECL_STRLCAT $ac_have_decl
18248 _ACEOF
18249 ac_fn_c_check_decl "$LINENO" "arc4random" "ac_cv_have_decl_arc4random" "$ac_includes_default"
18250 if test "x$ac_cv_have_decl_arc4random" = xyes; then :
18251 ac_have_decl=1
18252 else
18253 ac_have_decl=0
18254 fi
18255
18256 cat >>confdefs.h <<_ACEOF
18257 #define HAVE_DECL_ARC4RANDOM $ac_have_decl
18258 _ACEOF
18259 ac_fn_c_check_decl "$LINENO" "arc4random_uniform" "ac_cv_have_decl_arc4random_uniform" "$ac_includes_default"
18260 if test "x$ac_cv_have_decl_arc4random_uniform" = xyes; then :
18261 ac_have_decl=1
18262 else
18263 ac_have_decl=0
18264 fi
18265
18266 cat >>confdefs.h <<_ACEOF
18267 #define HAVE_DECL_ARC4RANDOM_UNIFORM $ac_have_decl
18268 _ACEOF
18269
18270 else
18271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18272 $as_echo "no" >&6; }
18273 fi
18274 for ac_header in openssl/conf.h openssl/engine.h openssl/bn.h openssl/dh.h openssl/dsa.h openssl/rsa.h
18275 do :
18276 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18277 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
18278 "
18279 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18280 cat >>confdefs.h <<_ACEOF
18281 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18282 _ACEOF
18283
18284 fi
18285
18286 done
18287
18288 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 EVP_DigestVerify SSL_CTX_set_tlsext_ticket_key_cb EVP_aes_256_cbc EVP_EncryptInit_ex HMAC_Init_ex CRYPTO_THREADID_set_callback
18289 do :
18290 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18291 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18292 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18293 cat >>confdefs.h <<_ACEOF
18294 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18295 _ACEOF
18296
18297 fi
18298 done
18299
18300
18301 # these check_funcs need -lssl
18302 BAKLIBS="$LIBS"
18303 LIBS="-lssl $LIBS"
18304 for ac_func in OPENSSL_init_ssl SSL_CTX_set_security_level SSL_set1_host SSL_get0_peername X509_VERIFY_PARAM_set1_host SSL_CTX_set_ciphersuites
18305 do :
18306 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18307 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
18308 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
18309 cat >>confdefs.h <<_ACEOF
18310 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18311 _ACEOF
18312
18313 fi
18314 done
18315
18316 LIBS="$BAKLIBS"
18317
18318 ac_fn_c_check_decl "$LINENO" "SSL_COMP_get_compression_methods" "ac_cv_have_decl_SSL_COMP_get_compression_methods" "
18319 $ac_includes_default
18320 #ifdef HAVE_OPENSSL_ERR_H
18321 #include <openssl/err.h>
18322 #endif
18323
18324 #ifdef HAVE_OPENSSL_RAND_H
18325 #include <openssl/rand.h>
18326 #endif
18327
18328 #ifdef HAVE_OPENSSL_CONF_H
18329 #include <openssl/conf.h>
18330 #endif
18331
18332 #ifdef HAVE_OPENSSL_ENGINE_H
18333 #include <openssl/engine.h>
18334 #endif
18335 #include <openssl/ssl.h>
18336 #include <openssl/evp.h>
18337
18338 "
18339 if test "x$ac_cv_have_decl_SSL_COMP_get_compression_methods" = xyes; then :
18340 ac_have_decl=1
18341 else
18342 ac_have_decl=0
18343 fi
18344
18345 cat >>confdefs.h <<_ACEOF
18346 #define HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS $ac_have_decl
18347 _ACEOF
18348 ac_fn_c_check_decl "$LINENO" "sk_SSL_COMP_pop_free" "ac_cv_have_decl_sk_SSL_COMP_pop_free" "
18349 $ac_includes_default
18350 #ifdef HAVE_OPENSSL_ERR_H
18351 #include <openssl/err.h>
18352 #endif
18353
18354 #ifdef HAVE_OPENSSL_RAND_H
18355 #include <openssl/rand.h>
18356 #endif
18357
18358 #ifdef HAVE_OPENSSL_CONF_H
18359 #include <openssl/conf.h>
18360 #endif
18361
18362 #ifdef HAVE_OPENSSL_ENGINE_H
18363 #include <openssl/engine.h>
18364 #endif
18365 #include <openssl/ssl.h>
18366 #include <openssl/evp.h>
18367
18368 "
18369 if test "x$ac_cv_have_decl_sk_SSL_COMP_pop_free" = xyes; then :
18370 ac_have_decl=1
18371 else
18372 ac_have_decl=0
18373 fi
18374
18375 cat >>confdefs.h <<_ACEOF
18376 #define HAVE_DECL_SK_SSL_COMP_POP_FREE $ac_have_decl
18377 _ACEOF
18378 ac_fn_c_check_decl "$LINENO" "SSL_CTX_set_ecdh_auto" "ac_cv_have_decl_SSL_CTX_set_ecdh_auto" "
18379 $ac_includes_default
18380 #ifdef HAVE_OPENSSL_ERR_H
18381 #include <openssl/err.h>
18382 #endif
18383
18384 #ifdef HAVE_OPENSSL_RAND_H
18385 #include <openssl/rand.h>
18386 #endif
18387
18388 #ifdef HAVE_OPENSSL_CONF_H
18389 #include <openssl/conf.h>
18390 #endif
18391
18392 #ifdef HAVE_OPENSSL_ENGINE_H
18393 #include <openssl/engine.h>
18394 #endif
18395 #include <openssl/ssl.h>
18396 #include <openssl/evp.h>
18397
18398 "
18399 if test "x$ac_cv_have_decl_SSL_CTX_set_ecdh_auto" = xyes; then :
18400 ac_have_decl=1
18401 else
18402 ac_have_decl=0
18403 fi
18404
18405 cat >>confdefs.h <<_ACEOF
18406 #define HAVE_DECL_SSL_CTX_SET_ECDH_AUTO $ac_have_decl
18407 _ACEOF
18408
18409
18410 if test "$ac_cv_func_HMAC_Init_ex" = "yes"; then
18411 # check function return type.
18412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the return type of HMAC_Init_ex" >&5
18413 $as_echo_n "checking the return type of HMAC_Init_ex... " >&6; }
18414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18415 /* end confdefs.h. */
18416
18417 #ifdef HAVE_OPENSSL_ERR_H
18418 #include <openssl/err.h>
18419 #endif
18420
18421 #ifdef HAVE_OPENSSL_RAND_H
18422 #include <openssl/rand.h>
18423 #endif
18424
18425 #ifdef HAVE_OPENSSL_CONF_H
18426 #include <openssl/conf.h>
18427 #endif
18428
18429 #ifdef HAVE_OPENSSL_ENGINE_H
18430 #include <openssl/engine.h>
18431 #endif
18432 #include <openssl/ssl.h>
18433 #include <openssl/evp.h>
18434
18435 int
18436 main ()
18437 {
18438
18439 HMAC_CTX* hmac_ctx = NULL;
18440 void* hmac_key = NULL;
18441 const EVP_MD* digest = NULL;
18442 int x = HMAC_Init_ex(hmac_ctx, hmac_key, 32, digest, NULL);
18443 (void)x;
18444
18445 ;
18446 return 0;
18447 }
18448 _ACEOF
18449 if ac_fn_c_try_compile "$LINENO"; then :
18450
18451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: int" >&5
18452 $as_echo "int" >&6; }
18453
18454 else
18455
18456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: void" >&5
18457 $as_echo "void" >&6; }
18458
18459 $as_echo "#define HMAC_INIT_EX_RETURNS_VOID 1" >>confdefs.h
18460
18461
18462 fi
18463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18464 fi
18465
18466 fi
18467
18468
18469
18470 # Check whether --enable-sha1 was given.
18471 if test "${enable_sha1+set}" = set; then :
18472 enableval=$enable_sha1;
18473 fi
18474
18475 case "$enable_sha1" in
18476 no)
18477 ;;
18478 yes|*)
18479
18480 $as_echo "#define USE_SHA1 1" >>confdefs.h
18481
18482 ;;
18483 esac
18484
18485
18486 # Check whether --enable-sha2 was given.
18487 if test "${enable_sha2+set}" = set; then :
18488 enableval=$enable_sha2;
18489 fi
18490
18491 case "$enable_sha2" in
18492 no)
18493 ;;
18494 yes|*)
18495
18496 $as_echo "#define USE_SHA2 1" >>confdefs.h
18497
18498 ;;
18499 esac
18500
18501 # Check whether --enable-subnet was given.
18502 if test "${enable_subnet+set}" = set; then :
18503 enableval=$enable_subnet;
18504 fi
18505
18506 case "$enable_subnet" in
18507 yes)
18508
18509 $as_echo "#define CLIENT_SUBNET 1" >>confdefs.h
18510
18511 SUBNET_OBJ="edns-subnet.lo subnetmod.lo addrtree.lo subnet-whitelist.lo"
18512
18513 SUBNET_HEADER='$(srcdir)/edns-subnet/subnetmod.h $(srcdir)/edns-subnet/edns-subnet.h $(srcdir)/edns-subnet/subnet-whitelist.h $(srcdir)/edns-subnet/addrtree.h'
18514
18515 ;;
18516 no|*)
18517 ;;
18518 esac
18519
18520 # check wether gost also works
18521
18522 # Check whether --enable-gost was given.
18523 if test "${enable_gost+set}" = set; then :
18524 enableval=$enable_gost;
18525 fi
18526
18527 use_gost="no"
18528 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18529 case "$enable_gost" in
18530 no)
18531 ;;
18532 *)
18533 ac_fn_c_check_func "$LINENO" "EVP_PKEY_set_type_str" "ac_cv_func_EVP_PKEY_set_type_str"
18534 if test "x$ac_cv_func_EVP_PKEY_set_type_str" = xyes; then :
18535 :
18536 else
18537 as_fn_error $? "OpenSSL 1.0.0 is needed for GOST support" "$LINENO" 5
18538 fi
18539
18540 ac_fn_c_check_func "$LINENO" "EC_KEY_new" "ac_cv_func_EC_KEY_new"
18541 if test "x$ac_cv_func_EC_KEY_new" = xyes; then :
18542
18543 else
18544 as_fn_error $? "OpenSSL does not support ECC, needed for GOST support" "$LINENO" 5
18545 fi
18546
18547
18548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GOST works" >&5
18549 $as_echo_n "checking if GOST works... " >&6; }
18550 if test c${cross_compiling} = cno; then
18551 BAKCFLAGS="$CFLAGS"
18552 if test -n "$ssldir"; then
18553 CFLAGS="$CFLAGS -Wl,-rpath,$ssldir/lib"
18554 fi
18555 if test "$cross_compiling" = yes; then :
18556 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18557 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18558 as_fn_error $? "cannot run test program while cross compiling
18559 See \`config.log' for more details" "$LINENO" 5; }
18560 else
18561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18562 /* end confdefs.h. */
18563
18564 #include <string.h>
18565 #include <openssl/ssl.h>
18566 #include <openssl/evp.h>
18567 #include <openssl/engine.h>
18568 #include <openssl/conf.h>
18569 /* routine to load gost (from sldns) */
18570 int load_gost_id(void)
18571 {
18572 static int gost_id = 0;
18573 const EVP_PKEY_ASN1_METHOD* meth;
18574 ENGINE* e;
18575
18576 if(gost_id) return gost_id;
18577
18578 /* see if configuration loaded gost implementation from other engine*/
18579 meth = EVP_PKEY_asn1_find_str(NULL, "gost2001", -1);
18580 if(meth) {
18581 EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
18582 return gost_id;
18583 }
18584
18585 /* see if engine can be loaded already */
18586 e = ENGINE_by_id("gost");
18587 if(!e) {
18588 /* load it ourself, in case statically linked */
18589 ENGINE_load_builtin_engines();
18590 ENGINE_load_dynamic();
18591 e = ENGINE_by_id("gost");
18592 }
18593 if(!e) {
18594 /* no gost engine in openssl */
18595 return 0;
18596 }
18597 if(!ENGINE_set_default(e, ENGINE_METHOD_ALL)) {
18598 ENGINE_finish(e);
18599 ENGINE_free(e);
18600 return 0;
18601 }
18602
18603 meth = EVP_PKEY_asn1_find_str(&e, "gost2001", -1);
18604 if(!meth) {
18605 /* algo not found */
18606 ENGINE_finish(e);
18607 ENGINE_free(e);
18608 return 0;
18609 }
18610 EVP_PKEY_asn1_get0_info(&gost_id, NULL, NULL, NULL, NULL, meth);
18611 return gost_id;
18612 }
18613 int main(void) {
18614 EVP_MD_CTX* ctx;
18615 const EVP_MD* md;
18616 unsigned char digest[64]; /* its a 256-bit digest, so uses 32 bytes */
18617 const char* str = "Hello world";
18618 const unsigned char check[] = {
18619 0x40 , 0xed , 0xf8 , 0x56 , 0x5a , 0xc5 , 0x36 , 0xe1 ,
18620 0x33 , 0x7c , 0x7e , 0x87 , 0x62 , 0x1c , 0x42 , 0xe0 ,
18621 0x17 , 0x1b , 0x5e , 0xce , 0xa8 , 0x46 , 0x65 , 0x4d ,
18622 0x8d , 0x3e , 0x22 , 0x9b , 0xe1 , 0x30 , 0x19 , 0x9d
18623 };
18624 OPENSSL_config(NULL);
18625 (void)load_gost_id();
18626 md = EVP_get_digestbyname("md_gost94");
18627 if(!md) return 1;
18628 memset(digest, 0, sizeof(digest));
18629 ctx = EVP_MD_CTX_create();
18630 if(!ctx) return 2;
18631 if(!EVP_DigestInit_ex(ctx, md, NULL)) return 3;
18632 if(!EVP_DigestUpdate(ctx, str, 10)) return 4;
18633 if(!EVP_DigestFinal_ex(ctx, digest, NULL)) return 5;
18634 /* uncomment to see the hash calculated.
18635 {int i;
18636 for(i=0; i<32; i++)
18637 printf(" %2.2x", (int)digest[i]);
18638 printf("\n");}
18639 */
18640 if(memcmp(digest, check, sizeof(check)) != 0)
18641 return 6;
18642 return 0;
18643 }
18644
18645 _ACEOF
18646 if ac_fn_c_try_run "$LINENO"; then :
18647 eval "ac_cv_c_gost_works=yes"
18648 else
18649 eval "ac_cv_c_gost_works=no"
18650 fi
18651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18652 conftest.$ac_objext conftest.beam conftest.$ac_ext
18653 fi
18654
18655 CFLAGS="$BAKCFLAGS"
18656 else
18657 eval "ac_cv_c_gost_works=maybe"
18658 fi
18659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_gost_works" >&5
18660 $as_echo "$ac_cv_c_gost_works" >&6; }
18661
18662 if test "$ac_cv_c_gost_works" != no; then
18663 use_gost="yes"
18664
18665 $as_echo "#define USE_GOST 1" >>confdefs.h
18666
18667 fi
18668 ;;
18669 esac
18670 fi
18671 # Check whether --enable-ecdsa was given.
18672 if test "${enable_ecdsa+set}" = set; then :
18673 enableval=$enable_ecdsa;
18674 fi
18675
18676 use_ecdsa="no"
18677 case "$enable_ecdsa" in
18678 no)
18679 ;;
18680 *)
18681 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18682 ac_fn_c_check_func "$LINENO" "ECDSA_sign" "ac_cv_func_ECDSA_sign"
18683 if test "x$ac_cv_func_ECDSA_sign" = xyes; then :
18684
18685 else
18686 as_fn_error $? "OpenSSL does not support ECDSA: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
18687 fi
18688
18689 ac_fn_c_check_func "$LINENO" "SHA384_Init" "ac_cv_func_SHA384_Init"
18690 if test "x$ac_cv_func_SHA384_Init" = xyes; then :
18691
18692 else
18693 as_fn_error $? "OpenSSL does not support SHA384: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
18694 fi
18695
18696 ac_fn_c_check_decl "$LINENO" "NID_X9_62_prime256v1" "ac_cv_have_decl_NID_X9_62_prime256v1" "$ac_includes_default
18697 #include <openssl/evp.h>
18698
18699 "
18700 if test "x$ac_cv_have_decl_NID_X9_62_prime256v1" = xyes; then :
18701 ac_have_decl=1
18702 else
18703 ac_have_decl=0
18704 fi
18705
18706 cat >>confdefs.h <<_ACEOF
18707 #define HAVE_DECL_NID_X9_62_PRIME256V1 $ac_have_decl
18708 _ACEOF
18709 if test $ac_have_decl = 1; then :
18710
18711 else
18712 as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
18713 fi
18714 ac_fn_c_check_decl "$LINENO" "NID_secp384r1" "ac_cv_have_decl_NID_secp384r1" "$ac_includes_default
18715 #include <openssl/evp.h>
18716
18717 "
18718 if test "x$ac_cv_have_decl_NID_secp384r1" = xyes; then :
18719 ac_have_decl=1
18720 else
18721 ac_have_decl=0
18722 fi
18723
18724 cat >>confdefs.h <<_ACEOF
18725 #define HAVE_DECL_NID_SECP384R1 $ac_have_decl
18726 _ACEOF
18727 if test $ac_have_decl = 1; then :
18728
18729 else
18730 as_fn_error $? "OpenSSL does not support the ECDSA curves: please upgrade or rerun with --disable-ecdsa" "$LINENO" 5
18731 fi
18732
18733 # see if OPENSSL 1.0.0 or later (has EVP MD and Verify independency)
18734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openssl supports SHA2 and ECDSA with EVP" >&5
18735 $as_echo_n "checking if openssl supports SHA2 and ECDSA with EVP... " >&6; }
18736 if grep OPENSSL_VERSION_TEXT $ssldir/include/openssl/opensslv.h | grep "OpenSSL" >/dev/null; then
18737 if grep OPENSSL_VERSION_NUMBER $ssldir/include/openssl/opensslv.h | grep 0x0 >/dev/null; then
18738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18739 $as_echo "no" >&6; }
18740
18741 cat >>confdefs.h <<_ACEOF
18742 #define USE_ECDSA_EVP_WORKAROUND 1
18743 _ACEOF
18744
18745 else
18746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18747 $as_echo "yes" >&6; }
18748 fi
18749 else
18750 # not OpenSSL, thus likely LibreSSL, which supports it
18751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18752 $as_echo "yes" >&6; }
18753 fi
18754 fi
18755 # we now know we have ECDSA and the required curves.
18756
18757 cat >>confdefs.h <<_ACEOF
18758 #define USE_ECDSA 1
18759 _ACEOF
18760
18761 use_ecdsa="yes"
18762 ;;
18763 esac
18764
18765 # Check whether --enable-dsa was given.
18766 if test "${enable_dsa+set}" = set; then :
18767 enableval=$enable_dsa;
18768 fi
18769
18770 use_dsa="no"
18771 case "$enable_dsa" in
18772 no)
18773 ;;
18774 *)
18775 # detect if DSA is supported, and turn it off if not.
18776 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18777 ac_fn_c_check_func "$LINENO" "DSA_SIG_new" "ac_cv_func_DSA_SIG_new"
18778 if test "x$ac_cv_func_DSA_SIG_new" = xyes; then :
18779
18780 as_ac_Type=`$as_echo "ac_cv_type_DSA_SIG*" | $as_tr_sh`
18781 ac_fn_c_check_type "$LINENO" "DSA_SIG*" "$as_ac_Type" "
18782 $ac_includes_default
18783 #ifdef HAVE_OPENSSL_ERR_H
18784 #include <openssl/err.h>
18785 #endif
18786
18787 #ifdef HAVE_OPENSSL_RAND_H
18788 #include <openssl/rand.h>
18789 #endif
18790
18791 #ifdef HAVE_OPENSSL_CONF_H
18792 #include <openssl/conf.h>
18793 #endif
18794
18795 #ifdef HAVE_OPENSSL_ENGINE_H
18796 #include <openssl/engine.h>
18797 #endif
18798
18799 "
18800 if eval test \"x\$"$as_ac_Type"\" = x"yes"; then :
18801
18802
18803 cat >>confdefs.h <<_ACEOF
18804 #define USE_DSA 1
18805 _ACEOF
18806
18807
18808 else
18809 if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
18810 fi
18811 fi
18812
18813
18814 else
18815 if test "x$enable_dsa" = "xyes"; then as_fn_error $? "OpenSSL does not support DSA and you used --enable-dsa." "$LINENO" 5
18816 fi
18817 fi
18818
18819 else
18820
18821 cat >>confdefs.h <<_ACEOF
18822 #define USE_DSA 1
18823 _ACEOF
18824
18825 fi
18826 ;;
18827 esac
18828
18829 # Check whether --enable-ed25519 was given.
18830 if test "${enable_ed25519+set}" = set; then :
18831 enableval=$enable_ed25519;
18832 fi
18833
18834 use_ed25519="no"
18835 case "$enable_ed25519" in
18836 no)
18837 ;;
18838 *)
18839 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18840 ac_fn_c_check_decl "$LINENO" "NID_ED25519" "ac_cv_have_decl_NID_ED25519" "$ac_includes_default
18841 #include <openssl/evp.h>
18842
18843 "
18844 if test "x$ac_cv_have_decl_NID_ED25519" = xyes; then :
18845 ac_have_decl=1
18846 else
18847 ac_have_decl=0
18848 fi
18849
18850 cat >>confdefs.h <<_ACEOF
18851 #define HAVE_DECL_NID_ED25519 $ac_have_decl
18852 _ACEOF
18853 if test $ac_have_decl = 1; then :
18854
18855 use_ed25519="yes"
18856
18857 else
18858 if test "x$enable_ed25519" = "xyes"; then as_fn_error $? "OpenSSL does not support ED25519 and you used --enable-ed25519." "$LINENO" 5
18859 fi
18860 fi
18861
18862 fi
18863 if test $USE_NETTLE = "yes"; then
18864 for ac_header in nettle/eddsa.h
18865 do :
18866 ac_fn_c_check_header_compile "$LINENO" "nettle/eddsa.h" "ac_cv_header_nettle_eddsa_h" "$ac_includes_default
18867 "
18868 if test "x$ac_cv_header_nettle_eddsa_h" = xyes; then :
18869 cat >>confdefs.h <<_ACEOF
18870 #define HAVE_NETTLE_EDDSA_H 1
18871 _ACEOF
18872 use_ed25519="yes"
18873 fi
18874
18875 done
18876
18877 fi
18878 if test $use_ed25519 = "yes"; then
18879
18880 cat >>confdefs.h <<_ACEOF
18881 #define USE_ED25519 1
18882 _ACEOF
18883
18884 fi
18885 ;;
18886 esac
18887
18888 # Check whether --enable-ed448 was given.
18889 if test "${enable_ed448+set}" = set; then :
18890 enableval=$enable_ed448;
18891 fi
18892
18893 use_ed448="no"
18894 case "$enable_ed448" in
18895 no)
18896 ;;
18897 *)
18898 if test $USE_NSS = "no" -a $USE_NETTLE = "no"; then
18899 ac_fn_c_check_decl "$LINENO" "NID_ED448" "ac_cv_have_decl_NID_ED448" "$ac_includes_default
18900 #include <openssl/evp.h>
18901
18902 "
18903 if test "x$ac_cv_have_decl_NID_ED448" = xyes; then :
18904 ac_have_decl=1
18905 else
18906 ac_have_decl=0
18907 fi
18908
18909 cat >>confdefs.h <<_ACEOF
18910 #define HAVE_DECL_NID_ED448 $ac_have_decl
18911 _ACEOF
18912 if test $ac_have_decl = 1; then :
18913
18914 use_ed448="yes"
18915
18916 else
18917 if test "x$enable_ed448" = "xyes"; then as_fn_error $? "OpenSSL does not support ED448 and you used --enable-ed448." "$LINENO" 5
18918 fi
18919 fi
18920
18921 fi
18922 if test $use_ed448 = "yes"; then
18923
18924 cat >>confdefs.h <<_ACEOF
18925 #define USE_ED448 1
18926 _ACEOF
18927
18928 fi
18929 ;;
18930 esac
18931
18932 # Check whether --enable-event-api was given.
18933 if test "${enable_event_api+set}" = set; then :
18934 enableval=$enable_event_api;
18935 fi
18936
18937 case "$enable_event_api" in
18938 yes)
18939 UNBOUND_EVENT_INSTALL=unbound-event-install
18940
18941 UNBOUND_EVENT_UNINSTALL=unbound-event-uninstall
18942
18943 ;;
18944 *)
18945 ;;
18946 esac
18947
18948 # Check whether --enable-tfo-client was given.
18949 if test "${enable_tfo_client+set}" = set; then :
18950 enableval=$enable_tfo_client;
18951 fi
18952
18953 case "$enable_tfo_client" in
18954 yes)
18955 case `uname` in
18956 Linux) ac_fn_c_check_decl "$LINENO" "MSG_FASTOPEN" "ac_cv_have_decl_MSG_FASTOPEN" "$ac_includes_default
18957 #include <netinet/tcp.h>
18958
18959 "
18960 if test "x$ac_cv_have_decl_MSG_FASTOPEN" = xyes; then :
18961 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
18962 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
18963 else
18964 as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
18965 fi
18966
18967
18968 cat >>confdefs.h <<_ACEOF
18969 #define USE_MSG_FASTOPEN 1
18970 _ACEOF
18971
18972 ;;
18973 Darwin) ac_fn_c_check_decl "$LINENO" "CONNECT_RESUME_ON_READ_WRITE" "ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" "$ac_includes_default
18974 #include <sys/socket.h>
18975
18976 "
18977 if test "x$ac_cv_have_decl_CONNECT_RESUME_ON_READ_WRITE" = xyes; then :
18978 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&5
18979 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support client mode TFO" >&2;}
18980 else
18981 as_fn_error $? "TCP Fast Open is not available for client mode: please rerun without --enable-tfo-client" "$LINENO" 5
18982 fi
18983
18984
18985 cat >>confdefs.h <<_ACEOF
18986 #define USE_OSX_MSG_FASTOPEN 1
18987 _ACEOF
18988
18989 ;;
18990 esac
18991 ;;
18992 no|*)
18993 ;;
18994 esac
18995
18996 # Check whether --enable-tfo-server was given.
18997 if test "${enable_tfo_server+set}" = set; then :
18998 enableval=$enable_tfo_server;
18999 fi
19000
19001 case "$enable_tfo_server" in
19002 yes)
19003 ac_fn_c_check_decl "$LINENO" "TCP_FASTOPEN" "ac_cv_have_decl_TCP_FASTOPEN" "$ac_includes_default
19004 #include <netinet/tcp.h>
19005
19006 "
19007 if test "x$ac_cv_have_decl_TCP_FASTOPEN" = xyes; then :
19008 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&5
19009 $as_echo "$as_me: WARNING: Check the platform specific TFO kernel parameters are correctly configured to support server mode TFO" >&2;}
19010 else
19011 as_fn_error $? "TCP Fast Open is not available for server mode: please rerun without --enable-tfo-server" "$LINENO" 5
19012 fi
19013
19014
19015 cat >>confdefs.h <<_ACEOF
19016 #define USE_TCP_FASTOPEN 1
19017 _ACEOF
19018
19019 ;;
19020 no|*)
19021 ;;
19022 esac
19023
19024 # check for libevent
19025
19026 # Check whether --with-libevent was given.
19027 if test "${with_libevent+set}" = set; then :
19028 withval=$with_libevent;
19029 else
19030 withval="no"
19031 fi
19032
19033 if test x_$withval = x_yes -o x_$withval != x_no; then
19034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libevent" >&5
19035 $as_echo_n "checking for libevent... " >&6; }
19036 if test x_$withval = x_ -o x_$withval = x_yes; then
19037 withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19038 fi
19039 for dir in $withval; do
19040 thedir="$dir"
19041 if test -f "$dir/include/event.h" -o -f "$dir/include/event2/event.h"; then
19042 found_libevent="yes"
19043 if test "$thedir" != "/usr"; then
19044 CPPFLAGS="$CPPFLAGS -I$thedir/include"
19045 fi
19046 break;
19047 fi
19048 done
19049 if test x_$found_libevent != x_yes; then
19050 if test -f "$dir/event.h" -a \( -f "$dir/libevent.la" -o -f "$dir/libev.la" \) ; then
19051 # libevent source directory
19052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19053 $as_echo "found in $thedir" >&6; }
19054 CPPFLAGS="$CPPFLAGS -I$thedir -I$thedir/include"
19055 BAK_LDFLAGS_SET="1"
19056 BAK_LDFLAGS="$LDFLAGS"
19057 # remove evdns from linking
19058 mkdir build >/dev/null 2>&1
19059 mkdir build/libevent >/dev/null 2>&1
19060 mkdir build/libevent/.libs >/dev/null 2>&1
19061 ev_files_o=`ls $thedir/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19062 ev_files_lo=`ls $thedir/*.lo | grep -v evdns\.lo | grep -v bufferevent_openssl\.lo`
19063 ev_files_libso=`ls $thedir/.libs/*.o | grep -v evdns\.o | grep -v bufferevent_openssl\.o`
19064 cp $ev_files_o build/libevent
19065 cp $ev_files_lo build/libevent
19066 cp $ev_files_libso build/libevent/.libs
19067 LATE_LDFLAGS="build/libevent/*.lo -lm"
19068 LDFLAGS="build/libevent/*.o $LDFLAGS -lm"
19069 else
19070 as_fn_error $? "Cannot find the libevent library in $withval
19071 You can restart ./configure --with-libevent=no to use a builtin alternative.
19072 Please note that this alternative is not as capable as libevent when using
19073 large outgoing port ranges. " "$LINENO" 5
19074 fi
19075 else
19076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $thedir" >&5
19077 $as_echo "found in $thedir" >&6; }
19078 if test ! -f $thedir/lib/libevent.a -a ! -f $thedir/lib/libevent.so -a -d "$thedir/lib/event2"; then
19079 LDFLAGS="$LDFLAGS -L$thedir/lib/event2"
19080
19081 if test "x$enable_rpath" = xyes; then
19082 if echo "$thedir/lib/event2" | grep "^/" >/dev/null; then
19083 RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib/event2"
19084 fi
19085 fi
19086
19087 else
19088 if test "$thedir" != "/usr" -a "$thedir" != ""; then
19089 LDFLAGS="$LDFLAGS -L$thedir/lib"
19090
19091 if test "x$enable_rpath" = xyes; then
19092 if echo "$thedir/lib" | grep "^/" >/dev/null; then
19093 RUNTIME_PATH="$RUNTIME_PATH -R$thedir/lib"
19094 fi
19095 fi
19096
19097 fi
19098 fi
19099 fi
19100 # check for library used by libevent after 1.3c
19101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19102 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19103 if ${ac_cv_search_clock_gettime+:} false; then :
19104 $as_echo_n "(cached) " >&6
19105 else
19106 ac_func_search_save_LIBS=$LIBS
19107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19108 /* end confdefs.h. */
19109
19110 /* Override any GCC internal prototype to avoid an error.
19111 Use char because int might match the return type of a GCC
19112 builtin and then its argument prototype would still apply. */
19113 #ifdef __cplusplus
19114 extern "C"
19115 #endif
19116 char clock_gettime ();
19117 int
19118 main ()
19119 {
19120 return clock_gettime ();
19121 ;
19122 return 0;
19123 }
19124 _ACEOF
19125 for ac_lib in '' rt; do
19126 if test -z "$ac_lib"; then
19127 ac_res="none required"
19128 else
19129 ac_res=-l$ac_lib
19130 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19131 fi
19132 if ac_fn_c_try_link "$LINENO"; then :
19133 ac_cv_search_clock_gettime=$ac_res
19134 fi
19135 rm -f core conftest.err conftest.$ac_objext \
19136 conftest$ac_exeext
19137 if ${ac_cv_search_clock_gettime+:} false; then :
19138 break
19139 fi
19140 done
19141 if ${ac_cv_search_clock_gettime+:} false; then :
19142
19143 else
19144 ac_cv_search_clock_gettime=no
19145 fi
19146 rm conftest.$ac_ext
19147 LIBS=$ac_func_search_save_LIBS
19148 fi
19149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19150 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19151 ac_res=$ac_cv_search_clock_gettime
19152 if test "$ac_res" != no; then :
19153 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19154
19155 fi
19156
19157
19158 # is the event.h header libev or libevent?
19159 for ac_header in event.h
19160 do :
19161 ac_fn_c_check_header_compile "$LINENO" "event.h" "ac_cv_header_event_h" "$ac_includes_default
19162 "
19163 if test "x$ac_cv_header_event_h" = xyes; then :
19164 cat >>confdefs.h <<_ACEOF
19165 #define HAVE_EVENT_H 1
19166 _ACEOF
19167
19168 fi
19169
19170 done
19171
19172 ac_fn_c_check_decl "$LINENO" "EV_VERSION_MAJOR" "ac_cv_have_decl_EV_VERSION_MAJOR" "$ac_includes_default
19173 #include <event.h>
19174
19175 "
19176 if test "x$ac_cv_have_decl_EV_VERSION_MAJOR" = xyes; then :
19177
19178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19179 $as_echo_n "checking for library containing event_set... " >&6; }
19180 if ${ac_cv_search_event_set+:} false; then :
19181 $as_echo_n "(cached) " >&6
19182 else
19183 ac_func_search_save_LIBS=$LIBS
19184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19185 /* end confdefs.h. */
19186
19187 /* Override any GCC internal prototype to avoid an error.
19188 Use char because int might match the return type of a GCC
19189 builtin and then its argument prototype would still apply. */
19190 #ifdef __cplusplus
19191 extern "C"
19192 #endif
19193 char event_set ();
19194 int
19195 main ()
19196 {
19197 return event_set ();
19198 ;
19199 return 0;
19200 }
19201 _ACEOF
19202 for ac_lib in '' ev; do
19203 if test -z "$ac_lib"; then
19204 ac_res="none required"
19205 else
19206 ac_res=-l$ac_lib
19207 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19208 fi
19209 if ac_fn_c_try_link "$LINENO"; then :
19210 ac_cv_search_event_set=$ac_res
19211 fi
19212 rm -f core conftest.err conftest.$ac_objext \
19213 conftest$ac_exeext
19214 if ${ac_cv_search_event_set+:} false; then :
19215 break
19216 fi
19217 done
19218 if ${ac_cv_search_event_set+:} false; then :
19219
19220 else
19221 ac_cv_search_event_set=no
19222 fi
19223 rm conftest.$ac_ext
19224 LIBS=$ac_func_search_save_LIBS
19225 fi
19226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19227 $as_echo "$ac_cv_search_event_set" >&6; }
19228 ac_res=$ac_cv_search_event_set
19229 if test "$ac_res" != no; then :
19230 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19231
19232 fi
19233
19234
19235 else
19236
19237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing event_set" >&5
19238 $as_echo_n "checking for library containing event_set... " >&6; }
19239 if ${ac_cv_search_event_set+:} false; then :
19240 $as_echo_n "(cached) " >&6
19241 else
19242 ac_func_search_save_LIBS=$LIBS
19243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19244 /* end confdefs.h. */
19245
19246 /* Override any GCC internal prototype to avoid an error.
19247 Use char because int might match the return type of a GCC
19248 builtin and then its argument prototype would still apply. */
19249 #ifdef __cplusplus
19250 extern "C"
19251 #endif
19252 char event_set ();
19253 int
19254 main ()
19255 {
19256 return event_set ();
19257 ;
19258 return 0;
19259 }
19260 _ACEOF
19261 for ac_lib in '' event; do
19262 if test -z "$ac_lib"; then
19263 ac_res="none required"
19264 else
19265 ac_res=-l$ac_lib
19266 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19267 fi
19268 if ac_fn_c_try_link "$LINENO"; then :
19269 ac_cv_search_event_set=$ac_res
19270 fi
19271 rm -f core conftest.err conftest.$ac_objext \
19272 conftest$ac_exeext
19273 if ${ac_cv_search_event_set+:} false; then :
19274 break
19275 fi
19276 done
19277 if ${ac_cv_search_event_set+:} false; then :
19278
19279 else
19280 ac_cv_search_event_set=no
19281 fi
19282 rm conftest.$ac_ext
19283 LIBS=$ac_func_search_save_LIBS
19284 fi
19285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_event_set" >&5
19286 $as_echo "$ac_cv_search_event_set" >&6; }
19287 ac_res=$ac_cv_search_event_set
19288 if test "$ac_res" != no; then :
19289 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19290
19291 fi
19292
19293
19294 fi
19295
19296 for ac_func in event_base_free
19297 do :
19298 ac_fn_c_check_func "$LINENO" "event_base_free" "ac_cv_func_event_base_free"
19299 if test "x$ac_cv_func_event_base_free" = xyes; then :
19300 cat >>confdefs.h <<_ACEOF
19301 #define HAVE_EVENT_BASE_FREE 1
19302 _ACEOF
19303
19304 fi
19305 done
19306 # only in libevent 1.2 and later
19307 for ac_func in event_base_once
19308 do :
19309 ac_fn_c_check_func "$LINENO" "event_base_once" "ac_cv_func_event_base_once"
19310 if test "x$ac_cv_func_event_base_once" = xyes; then :
19311 cat >>confdefs.h <<_ACEOF
19312 #define HAVE_EVENT_BASE_ONCE 1
19313 _ACEOF
19314
19315 fi
19316 done
19317 # only in libevent 1.4.1 and later
19318 for ac_func in event_base_new
19319 do :
19320 ac_fn_c_check_func "$LINENO" "event_base_new" "ac_cv_func_event_base_new"
19321 if test "x$ac_cv_func_event_base_new" = xyes; then :
19322 cat >>confdefs.h <<_ACEOF
19323 #define HAVE_EVENT_BASE_NEW 1
19324 _ACEOF
19325
19326 fi
19327 done
19328 # only in libevent 1.4.1 and later
19329 for ac_func in event_base_get_method
19330 do :
19331 ac_fn_c_check_func "$LINENO" "event_base_get_method" "ac_cv_func_event_base_get_method"
19332 if test "x$ac_cv_func_event_base_get_method" = xyes; then :
19333 cat >>confdefs.h <<_ACEOF
19334 #define HAVE_EVENT_BASE_GET_METHOD 1
19335 _ACEOF
19336
19337 fi
19338 done
19339 # only in libevent 1.4.3 and later
19340 for ac_func in ev_loop
19341 do :
19342 ac_fn_c_check_func "$LINENO" "ev_loop" "ac_cv_func_ev_loop"
19343 if test "x$ac_cv_func_ev_loop" = xyes; then :
19344 cat >>confdefs.h <<_ACEOF
19345 #define HAVE_EV_LOOP 1
19346 _ACEOF
19347
19348 fi
19349 done
19350 # only in libev. (tested on 3.51)
19351 for ac_func in ev_default_loop
19352 do :
19353 ac_fn_c_check_func "$LINENO" "ev_default_loop" "ac_cv_func_ev_default_loop"
19354 if test "x$ac_cv_func_ev_default_loop" = xyes; then :
19355 cat >>confdefs.h <<_ACEOF
19356 #define HAVE_EV_DEFAULT_LOOP 1
19357 _ACEOF
19358
19359 fi
19360 done
19361 # only in libev. (tested on 4.00)
19362 for ac_func in event_assign
19363 do :
19364 ac_fn_c_check_func "$LINENO" "event_assign" "ac_cv_func_event_assign"
19365 if test "x$ac_cv_func_event_assign" = xyes; then :
19366 cat >>confdefs.h <<_ACEOF
19367 #define HAVE_EVENT_ASSIGN 1
19368 _ACEOF
19369
19370 fi
19371 done
19372 # in libevent, for thread-safety
19373 ac_fn_c_check_decl "$LINENO" "evsignal_assign" "ac_cv_have_decl_evsignal_assign" "$ac_includes_default
19374 #ifdef HAVE_EVENT_H
19375 # include <event.h>
19376 #else
19377 # include \"event2/event.h\"
19378 #endif
19379
19380 "
19381 if test "x$ac_cv_have_decl_evsignal_assign" = xyes; then :
19382 ac_have_decl=1
19383 else
19384 ac_have_decl=0
19385 fi
19386
19387 cat >>confdefs.h <<_ACEOF
19388 #define HAVE_DECL_EVSIGNAL_ASSIGN $ac_have_decl
19389 _ACEOF
19390
19391 PC_LIBEVENT_DEPENDENCY="libevent"
19392
19393 if test -n "$BAK_LDFLAGS_SET"; then
19394 LDFLAGS="$BAK_LDFLAGS"
19395 fi
19396 else
19397
19398 $as_echo "#define USE_MINI_EVENT 1" >>confdefs.h
19399
19400 fi
19401
19402 # check for libexpat
19403
19404 # Check whether --with-libexpat was given.
19405 if test "${with_libexpat+set}" = set; then :
19406 withval=$with_libexpat;
19407 else
19408 withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19409 fi
19410
19411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
19412 $as_echo_n "checking for libexpat... " >&6; }
19413 found_libexpat="no"
19414 for dir in $withval ; do
19415 if test -f "$dir/include/expat.h"; then
19416 found_libexpat="yes"
19417 if test "$dir" != "/usr"; then
19418 CPPFLAGS="$CPPFLAGS -I$dir/include"
19419 LDFLAGS="$LDFLAGS -L$dir/lib"
19420 fi
19421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19422 $as_echo "found in $dir" >&6; }
19423 break;
19424 fi
19425 done
19426 if test x_$found_libexpat != x_yes; then
19427 as_fn_error $? "Could not find libexpat, expat.h" "$LINENO" 5
19428 fi
19429 for ac_header in expat.h
19430 do :
19431 ac_fn_c_check_header_compile "$LINENO" "expat.h" "ac_cv_header_expat_h" "$ac_includes_default
19432 "
19433 if test "x$ac_cv_header_expat_h" = xyes; then :
19434 cat >>confdefs.h <<_ACEOF
19435 #define HAVE_EXPAT_H 1
19436 _ACEOF
19437
19438 fi
19439
19440 done
19441
19442 ac_fn_c_check_decl "$LINENO" "XML_StopParser" "ac_cv_have_decl_XML_StopParser" "$ac_includes_default
19443 #include <expat.h>
19444
19445 "
19446 if test "x$ac_cv_have_decl_XML_StopParser" = xyes; then :
19447 ac_have_decl=1
19448 else
19449 ac_have_decl=0
19450 fi
19451
19452 cat >>confdefs.h <<_ACEOF
19453 #define HAVE_DECL_XML_STOPPARSER $ac_have_decl
19454 _ACEOF
19455
19456
19457 # hiredis (redis C client for cachedb)
19458
19459 # Check whether --with-libhiredis was given.
19460 if test "${with_libhiredis+set}" = set; then :
19461 withval=$with_libhiredis;
19462 else
19463 withval="no"
19464 fi
19465
19466 found_libhiredis="no"
19467 if test x_$withval = x_yes -o x_$withval != x_no; then
19468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libhiredis" >&5
19469 $as_echo_n "checking for libhiredis... " >&6; }
19470 if test x_$withval = x_ -o x_$withval = x_yes; then
19471 withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
19472 fi
19473 for dir in $withval ; do
19474 if test -f "$dir/include/hiredis/hiredis.h"; then
19475 found_libhiredis="yes"
19476 if test "$dir" != "/usr"; then
19477 CPPFLAGS="$CPPFLAGS -I$dir/include"
19478 LDFLAGS="$LDFLAGS -L$dir/lib"
19479 fi
19480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
19481 $as_echo "found in $dir" >&6; }
19482
19483 $as_echo "#define USE_REDIS 1" >>confdefs.h
19484
19485 LIBS="$LIBS -lhiredis"
19486 break;
19487 fi
19488 done
19489 if test x_$found_libhiredis != x_yes; then
19490 as_fn_error $? "Could not find libhiredis, hiredis.h" "$LINENO" 5
19491 fi
19492 for ac_header in hiredis/hiredis.h
19493 do :
19494 ac_fn_c_check_header_compile "$LINENO" "hiredis/hiredis.h" "ac_cv_header_hiredis_hiredis_h" "$ac_includes_default
19495 "
19496 if test "x$ac_cv_header_hiredis_hiredis_h" = xyes; then :
19497 cat >>confdefs.h <<_ACEOF
19498 #define HAVE_HIREDIS_HIREDIS_H 1
19499 _ACEOF
19500
19501 fi
19502
19503 done
19504
19505 ac_fn_c_check_decl "$LINENO" "redisConnect" "ac_cv_have_decl_redisConnect" "$ac_includes_default
19506 #include <hiredis/hiredis.h>
19507
19508 "
19509 if test "x$ac_cv_have_decl_redisConnect" = xyes; then :
19510 ac_have_decl=1
19511 else
19512 ac_have_decl=0
19513 fi
19514
19515 cat >>confdefs.h <<_ACEOF
19516 #define HAVE_DECL_REDISCONNECT $ac_have_decl
19517 _ACEOF
19518
19519 fi
19520
19521 # set static linking for uninstalled libraries if requested
19522
19523 staticexe=""
19524 # Check whether --enable-static-exe was given.
19525 if test "${enable_static_exe+set}" = set; then :
19526 enableval=$enable_static_exe;
19527 fi
19528
19529 if test x_$enable_static_exe = x_yes; then
19530 staticexe="-static"
19531 if test "$on_mingw" = yes; then
19532 staticexe="-all-static"
19533 # for static compile, include gdi32 and zlib here.
19534 if echo $LIBS | grep 'lgdi32' >/dev/null; then
19535 :
19536 else
19537 LIBS="$LIBS -lgdi32"
19538 fi
19539 LIBS="$LIBS -lz"
19540 fi
19541 fi
19542
19543 # set full static linking if requested
19544 # Check whether --enable-fully-static was given.
19545 if test "${enable_fully_static+set}" = set; then :
19546 enableval=$enable_fully_static;
19547 fi
19548
19549 if test x_$enable_fully_static = x_yes; then
19550 staticexe="-all-static"
19551 if test "$on_mingw" = yes; then
19552 # for static compile, include gdi32 and zlib here.
19553 if echo $LIBS | grep 'lgdi32' >/dev/null; then
19554 :
19555 else
19556 LIBS="$LIBS -lgdi32"
19557 fi
19558 LIBS="$LIBS -lz"
19559 fi
19560 fi
19561
19562 # set lock checking if requested
19563 # Check whether --enable-lock_checks was given.
19564 if test "${enable_lock_checks+set}" = set; then :
19565 enableval=$enable_lock_checks;
19566 fi
19567
19568 if test x_$enable_lock_checks = x_yes; then
19569
19570 $as_echo "#define ENABLE_LOCK_CHECKS 1" >>confdefs.h
19571
19572 CHECKLOCK_OBJ="checklocks.lo"
19573
19574 fi
19575
19576
19577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
19578 $as_echo_n "checking for getaddrinfo... " >&6; }
19579 ac_cv_func_getaddrinfo=no
19580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19581 /* end confdefs.h. */
19582
19583 #ifdef __cplusplus
19584 extern "C"
19585 {
19586 #endif
19587 char* getaddrinfo();
19588 char* (*f) () = getaddrinfo;
19589 #ifdef __cplusplus
19590 }
19591 #endif
19592 int main() {
19593 ;
19594 return 0;
19595 }
19596
19597 _ACEOF
19598 if ac_fn_c_try_link "$LINENO"; then :
19599 ac_cv_func_getaddrinfo="yes"
19600 if test "$ac_cv_header_windows_h" = "yes"; then
19601
19602 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
19603
19604 USE_WINSOCK="1"
19605 if echo $LIBS | grep 'lws2_32' >/dev/null; then
19606 :
19607 else
19608 LIBS="$LIBS -lws2_32"
19609 fi
19610 fi
19611
19612 else
19613 ORIGLIBS="$LIBS"
19614 LIBS="$LIBS -lws2_32"
19615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19616 /* end confdefs.h. */
19617
19618 #ifdef HAVE_WS2TCPIP_H
19619 #include <ws2tcpip.h>
19620 #endif
19621
19622 int
19623 main ()
19624 {
19625
19626 (void)getaddrinfo(NULL, NULL, NULL, NULL);
19627
19628
19629 ;
19630 return 0;
19631 }
19632 _ACEOF
19633 if ac_fn_c_try_link "$LINENO"; then :
19634
19635 ac_cv_func_getaddrinfo="yes"
19636
19637 $as_echo "#define USE_WINSOCK 1" >>confdefs.h
19638
19639 USE_WINSOCK="1"
19640
19641 else
19642
19643 ac_cv_func_getaddrinfo="no"
19644 LIBS="$ORIGLIBS"
19645
19646 fi
19647 rm -f core conftest.err conftest.$ac_objext \
19648 conftest$ac_exeext conftest.$ac_ext
19649
19650 fi
19651 rm -f core conftest.err conftest.$ac_objext \
19652 conftest$ac_exeext conftest.$ac_ext
19653
19654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getaddrinfo" >&5
19655 $as_echo "$ac_cv_func_getaddrinfo" >&6; }
19656 if test $ac_cv_func_getaddrinfo = yes; then
19657
19658 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
19659
19660 fi
19661
19662 if test "$USE_WINSOCK" = 1; then
19663
19664 $as_echo "#define UB_ON_WINDOWS 1" >>confdefs.h
19665
19666 for ac_header in iphlpapi.h
19667 do :
19668 ac_fn_c_check_header_compile "$LINENO" "iphlpapi.h" "ac_cv_header_iphlpapi_h" "$ac_includes_default
19669 #include <windows.h>
19670
19671 "
19672 if test "x$ac_cv_header_iphlpapi_h" = xyes; then :
19673 cat >>confdefs.h <<_ACEOF
19674 #define HAVE_IPHLPAPI_H 1
19675 _ACEOF
19676
19677 fi
19678
19679 done
19680
19681 if test -n "$ac_tool_prefix"; then
19682 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
19683 set dummy ${ac_tool_prefix}windres; ac_word=$2
19684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19685 $as_echo_n "checking for $ac_word... " >&6; }
19686 if ${ac_cv_prog_WINDRES+:} false; then :
19687 $as_echo_n "(cached) " >&6
19688 else
19689 if test -n "$WINDRES"; then
19690 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
19691 else
19692 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19693 for as_dir in $PATH
19694 do
19695 IFS=$as_save_IFS
19696 test -z "$as_dir" && as_dir=.
19697 for ac_exec_ext in '' $ac_executable_extensions; do
19698 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19699 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
19700 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19701 break 2
19702 fi
19703 done
19704 done
19705 IFS=$as_save_IFS
19706
19707 fi
19708 fi
19709 WINDRES=$ac_cv_prog_WINDRES
19710 if test -n "$WINDRES"; then
19711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
19712 $as_echo "$WINDRES" >&6; }
19713 else
19714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19715 $as_echo "no" >&6; }
19716 fi
19717
19718
19719 fi
19720 if test -z "$ac_cv_prog_WINDRES"; then
19721 ac_ct_WINDRES=$WINDRES
19722 # Extract the first word of "windres", so it can be a program name with args.
19723 set dummy windres; ac_word=$2
19724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19725 $as_echo_n "checking for $ac_word... " >&6; }
19726 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
19727 $as_echo_n "(cached) " >&6
19728 else
19729 if test -n "$ac_ct_WINDRES"; then
19730 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
19731 else
19732 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19733 for as_dir in $PATH
19734 do
19735 IFS=$as_save_IFS
19736 test -z "$as_dir" && as_dir=.
19737 for ac_exec_ext in '' $ac_executable_extensions; do
19738 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19739 ac_cv_prog_ac_ct_WINDRES="windres"
19740 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19741 break 2
19742 fi
19743 done
19744 done
19745 IFS=$as_save_IFS
19746
19747 fi
19748 fi
19749 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
19750 if test -n "$ac_ct_WINDRES"; then
19751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
19752 $as_echo "$ac_ct_WINDRES" >&6; }
19753 else
19754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19755 $as_echo "no" >&6; }
19756 fi
19757
19758 if test "x$ac_ct_WINDRES" = x; then
19759 WINDRES=""
19760 else
19761 case $cross_compiling:$ac_tool_warned in
19762 yes:)
19763 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19764 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19765 ac_tool_warned=yes ;;
19766 esac
19767 WINDRES=$ac_ct_WINDRES
19768 fi
19769 else
19770 WINDRES="$ac_cv_prog_WINDRES"
19771 fi
19772
19773 LIBS="$LIBS -liphlpapi -lcrypt32"
19774 WINAPPS="unbound-service-install.exe unbound-service-remove.exe anchor-update.exe"
19775
19776 WIN_DAEMON_SRC="winrc/win_svc.c winrc/w_inst.c"
19777
19778 WIN_DAEMON_OBJ="win_svc.lo w_inst.lo"
19779
19780 WIN_DAEMON_OBJ_LINK="rsrc_unbound.o"
19781
19782 WIN_HOST_OBJ_LINK="rsrc_unbound_host.o"
19783
19784 WIN_UBANCHOR_OBJ_LINK="rsrc_unbound_anchor.o log.lo locks.lo"
19785
19786 WIN_CONTROL_OBJ_LINK="rsrc_unbound_control.o"
19787
19788 WIN_CHECKCONF_OBJ_LINK="rsrc_unbound_checkconf.o"
19789
19790 fi
19791 if test $ac_cv_func_getaddrinfo = no; then
19792 case " $LIBOBJS " in
19793 *" fake-rfc2553.$ac_objext "* ) ;;
19794 *) LIBOBJS="$LIBOBJS fake-rfc2553.$ac_objext"
19795 ;;
19796 esac
19797
19798 fi
19799 # check after getaddrinfo for its libraries
19800
19801 # check ioctlsocket
19802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctlsocket" >&5
19803 $as_echo_n "checking for ioctlsocket... " >&6; }
19804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19805 /* end confdefs.h. */
19806
19807 #ifdef HAVE_WINSOCK2_H
19808 #include <winsock2.h>
19809 #endif
19810
19811 int
19812 main ()
19813 {
19814
19815 (void)ioctlsocket(0, 0, NULL);
19816
19817 ;
19818 return 0;
19819 }
19820 _ACEOF
19821 if ac_fn_c_try_link "$LINENO"; then :
19822
19823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19824 $as_echo "yes" >&6; }
19825
19826 $as_echo "#define HAVE_IOCTLSOCKET 1" >>confdefs.h
19827
19828
19829 else
19830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19831 $as_echo "no" >&6; }
19832 fi
19833 rm -f core conftest.err conftest.$ac_objext \
19834 conftest$ac_exeext conftest.$ac_ext
19835
19836
19837 # see if daemon(3) exists, and if it is deprecated.
19838 for ac_func in daemon
19839 do :
19840 ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
19841 if test "x$ac_cv_func_daemon" = xyes; then :
19842 cat >>confdefs.h <<_ACEOF
19843 #define HAVE_DAEMON 1
19844 _ACEOF
19845
19846 fi
19847 done
19848
19849 if test $ac_cv_func_daemon = yes; then
19850
19851
19852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if daemon is deprecated" >&5
19853 $as_echo_n "checking if daemon is deprecated... " >&6; }
19854 cache=`echo daemon | sed 'y%.=/+-%___p_%'`
19855 if eval \${cv_cc_deprecated_$cache+:} false; then :
19856 $as_echo_n "(cached) " >&6
19857 else
19858
19859 echo '
19860 #include <stdlib.h>
19861 ' >conftest.c
19862 echo 'void f(){ (void)daemon(0, 0); }' >>conftest.c
19863 if test -z "`$CC -c conftest.c 2>&1 | grep deprecated`"; then
19864 eval "cv_cc_deprecated_$cache=no"
19865 else
19866 eval "cv_cc_deprecated_$cache=yes"
19867 fi
19868 rm -f conftest conftest.o conftest.c
19869
19870 fi
19871
19872 if eval "test \"`echo '$cv_cc_deprecated_'$cache`\" = yes"; then
19873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19874 $as_echo "yes" >&6; }
19875
19876 cat >>confdefs.h <<_ACEOF
19877 #define DEPRECATED_DAEMON 1
19878 _ACEOF
19879
19880 :
19881
19882 else
19883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19884 $as_echo "no" >&6; }
19885 :
19886
19887 fi
19888
19889 fi
19890
19891 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_len" "ac_cv_member_struct_sockaddr_un_sun_len" "
19892 $ac_includes_default
19893 #ifdef HAVE_SYS_UN_H
19894 #include <sys/un.h>
19895 #endif
19896
19897 "
19898 if test "x$ac_cv_member_struct_sockaddr_un_sun_len" = xyes; then :
19899
19900 cat >>confdefs.h <<_ACEOF
19901 #define HAVE_STRUCT_SOCKADDR_UN_SUN_LEN 1
19902 _ACEOF
19903
19904
19905 fi
19906
19907 ac_fn_c_check_member "$LINENO" "struct in_pktinfo" "ipi_spec_dst" "ac_cv_member_struct_in_pktinfo_ipi_spec_dst" "
19908 $ac_includes_default
19909 #if HAVE_SYS_PARAM_H
19910 #include <sys/param.h>
19911 #endif
19912
19913 #ifdef HAVE_SYS_SOCKET_H
19914 #include <sys/socket.h>
19915 #endif
19916
19917 #ifdef HAVE_SYS_UIO_H
19918 #include <sys/uio.h>
19919 #endif
19920
19921 #ifdef HAVE_NETINET_IN_H
19922 #include <netinet/in.h>
19923 #endif
19924
19925 #ifdef HAVE_NETINET_TCP_H
19926 #include <netinet/tcp.h>
19927 #endif
19928
19929 #ifdef HAVE_ARPA_INET_H
19930 #include <arpa/inet.h>
19931 #endif
19932
19933 #ifdef HAVE_WINSOCK2_H
19934 #include <winsock2.h>
19935 #endif
19936
19937 #ifdef HAVE_WS2TCPIP_H
19938 #include <ws2tcpip.h>
19939 #endif
19940
19941 "
19942 if test "x$ac_cv_member_struct_in_pktinfo_ipi_spec_dst" = xyes; then :
19943
19944 cat >>confdefs.h <<_ACEOF
19945 #define HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST 1
19946 _ACEOF
19947
19948
19949 fi
19950
19951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setusercontext" >&5
19952 $as_echo_n "checking for library containing setusercontext... " >&6; }
19953 if ${ac_cv_search_setusercontext+:} false; then :
19954 $as_echo_n "(cached) " >&6
19955 else
19956 ac_func_search_save_LIBS=$LIBS
19957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19958 /* end confdefs.h. */
19959
19960 /* Override any GCC internal prototype to avoid an error.
19961 Use char because int might match the return type of a GCC
19962 builtin and then its argument prototype would still apply. */
19963 #ifdef __cplusplus
19964 extern "C"
19965 #endif
19966 char setusercontext ();
19967 int
19968 main ()
19969 {
19970 return setusercontext ();
19971 ;
19972 return 0;
19973 }
19974 _ACEOF
19975 for ac_lib in '' util; do
19976 if test -z "$ac_lib"; then
19977 ac_res="none required"
19978 else
19979 ac_res=-l$ac_lib
19980 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19981 fi
19982 if ac_fn_c_try_link "$LINENO"; then :
19983 ac_cv_search_setusercontext=$ac_res
19984 fi
19985 rm -f core conftest.err conftest.$ac_objext \
19986 conftest$ac_exeext
19987 if ${ac_cv_search_setusercontext+:} false; then :
19988 break
19989 fi
19990 done
19991 if ${ac_cv_search_setusercontext+:} false; then :
19992
19993 else
19994 ac_cv_search_setusercontext=no
19995 fi
19996 rm conftest.$ac_ext
19997 LIBS=$ac_func_search_save_LIBS
19998 fi
19999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setusercontext" >&5
20000 $as_echo "$ac_cv_search_setusercontext" >&6; }
20001 ac_res=$ac_cv_search_setusercontext
20002 if test "$ac_res" != no; then :
20003 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20004
20005 fi
20006
20007 for ac_func in tzset sigprocmask fcntl getpwnam endpwent getrlimit setrlimit setsid chroot kill chown sleep usleep random srandom recvmsg sendmsg writev socketpair glob initgroups strftime localtime_r setusercontext _beginthreadex endservent endprotoent fsync shmget accept4
20008 do :
20009 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20010 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20011 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
20012 cat >>confdefs.h <<_ACEOF
20013 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20014 _ACEOF
20015
20016 fi
20017 done
20018
20019 for ac_func in setresuid
20020 do :
20021 ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
20022 if test "x$ac_cv_func_setresuid" = xyes; then :
20023 cat >>confdefs.h <<_ACEOF
20024 #define HAVE_SETRESUID 1
20025 _ACEOF
20026
20027 else
20028 for ac_func in setreuid
20029 do :
20030 ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid"
20031 if test "x$ac_cv_func_setreuid" = xyes; then :
20032 cat >>confdefs.h <<_ACEOF
20033 #define HAVE_SETREUID 1
20034 _ACEOF
20035
20036 fi
20037 done
20038
20039 fi
20040 done
20041
20042 for ac_func in setresgid
20043 do :
20044 ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
20045 if test "x$ac_cv_func_setresgid" = xyes; then :
20046 cat >>confdefs.h <<_ACEOF
20047 #define HAVE_SETRESGID 1
20048 _ACEOF
20049
20050 else
20051 for ac_func in setregid
20052 do :
20053 ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid"
20054 if test "x$ac_cv_func_setregid" = xyes; then :
20055 cat >>confdefs.h <<_ACEOF
20056 #define HAVE_SETREGID 1
20057 _ACEOF
20058
20059 fi
20060 done
20061
20062 fi
20063 done
20064
20065
20066 # check if setreuid en setregid fail, on MacOSX10.4(darwin8).
20067 if echo $target_os | grep darwin8 > /dev/null; then
20068
20069 $as_echo "#define DARWIN_BROKEN_SETREUID 1" >>confdefs.h
20070
20071 fi
20072 ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "
20073 $ac_includes_default
20074 #ifdef HAVE_NETINET_IN_H
20075 #include <netinet/in.h>
20076 #endif
20077
20078 #ifdef HAVE_NETINET_TCP_H
20079 #include <netinet/tcp.h>
20080 #endif
20081
20082 #ifdef HAVE_ARPA_INET_H
20083 #include <arpa/inet.h>
20084 #endif
20085
20086 #ifdef HAVE_WINSOCK2_H
20087 #include <winsock2.h>
20088 #endif
20089
20090 #ifdef HAVE_WS2TCPIP_H
20091 #include <ws2tcpip.h>
20092 #endif
20093
20094 "
20095 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
20096 ac_have_decl=1
20097 else
20098 ac_have_decl=0
20099 fi
20100
20101 cat >>confdefs.h <<_ACEOF
20102 #define HAVE_DECL_INET_PTON $ac_have_decl
20103 _ACEOF
20104 ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "
20105 $ac_includes_default
20106 #ifdef HAVE_NETINET_IN_H
20107 #include <netinet/in.h>
20108 #endif
20109
20110 #ifdef HAVE_NETINET_TCP_H
20111 #include <netinet/tcp.h>
20112 #endif
20113
20114 #ifdef HAVE_ARPA_INET_H
20115 #include <arpa/inet.h>
20116 #endif
20117
20118 #ifdef HAVE_WINSOCK2_H
20119 #include <winsock2.h>
20120 #endif
20121
20122 #ifdef HAVE_WS2TCPIP_H
20123 #include <ws2tcpip.h>
20124 #endif
20125
20126 "
20127 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
20128 ac_have_decl=1
20129 else
20130 ac_have_decl=0
20131 fi
20132
20133 cat >>confdefs.h <<_ACEOF
20134 #define HAVE_DECL_INET_NTOP $ac_have_decl
20135 _ACEOF
20136
20137 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
20138 if test "x$ac_cv_func_inet_aton" = xyes; then :
20139 $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
20140
20141 else
20142 case " $LIBOBJS " in
20143 *" inet_aton.$ac_objext "* ) ;;
20144 *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
20145 ;;
20146 esac
20147
20148 fi
20149
20150
20151 ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
20152 if test "x$ac_cv_func_inet_pton" = xyes; then :
20153 $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h
20154
20155 else
20156 case " $LIBOBJS " in
20157 *" inet_pton.$ac_objext "* ) ;;
20158 *) LIBOBJS="$LIBOBJS inet_pton.$ac_objext"
20159 ;;
20160 esac
20161
20162 fi
20163
20164
20165 ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
20166 if test "x$ac_cv_func_inet_ntop" = xyes; then :
20167 $as_echo "#define HAVE_INET_NTOP 1" >>confdefs.h
20168
20169 else
20170 case " $LIBOBJS " in
20171 *" inet_ntop.$ac_objext "* ) ;;
20172 *) LIBOBJS="$LIBOBJS inet_ntop.$ac_objext"
20173 ;;
20174 esac
20175
20176 fi
20177
20178
20179 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
20180 if test "x$ac_cv_func_snprintf" = xyes; then :
20181 $as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
20182
20183 else
20184 case " $LIBOBJS " in
20185 *" snprintf.$ac_objext "* ) ;;
20186 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20187 ;;
20188 esac
20189
20190 fi
20191
20192
20193 # test if snprintf return the proper length
20194 if test "x$ac_cv_func_snprintf" = xyes; then
20195 if test c${cross_compiling} = cno; then
20196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for correct snprintf return value" >&5
20197 $as_echo_n "checking for correct snprintf return value... " >&6; }
20198 if test "$cross_compiling" = yes; then :
20199 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20200 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20201 as_fn_error $? "cannot run test program while cross compiling
20202 See \`config.log' for more details" "$LINENO" 5; }
20203 else
20204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20205 /* end confdefs.h. */
20206 $ac_includes_default
20207
20208 int main(void) { return !(snprintf(NULL, 0, "test") == 4); }
20209
20210 _ACEOF
20211 if ac_fn_c_try_run "$LINENO"; then :
20212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20213 $as_echo "yes" >&6; }
20214 else
20215
20216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20217 $as_echo "no" >&6; }
20218
20219 $as_echo "#define SNPRINTF_RET_BROKEN /**/" >>confdefs.h
20220
20221 case " $LIBOBJS " in
20222 *" snprintf.$ac_objext "* ) ;;
20223 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20224 ;;
20225 esac
20226
20227
20228 fi
20229 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20230 conftest.$ac_objext conftest.beam conftest.$ac_ext
20231 fi
20232
20233 fi
20234 fi
20235 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
20236 if test "x$ac_cv_func_strlcat" = xyes; then :
20237 $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
20238
20239 else
20240 case " $LIBOBJS " in
20241 *" strlcat.$ac_objext "* ) ;;
20242 *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
20243 ;;
20244 esac
20245
20246 fi
20247
20248
20249 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
20250 if test "x$ac_cv_func_strlcpy" = xyes; then :
20251 $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
20252
20253 else
20254 case " $LIBOBJS " in
20255 *" strlcpy.$ac_objext "* ) ;;
20256 *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
20257 ;;
20258 esac
20259
20260 fi
20261
20262
20263 ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
20264 if test "x$ac_cv_func_memmove" = xyes; then :
20265 $as_echo "#define HAVE_MEMMOVE 1" >>confdefs.h
20266
20267 else
20268 case " $LIBOBJS " in
20269 *" memmove.$ac_objext "* ) ;;
20270 *) LIBOBJS="$LIBOBJS memmove.$ac_objext"
20271 ;;
20272 esac
20273
20274 fi
20275
20276
20277 ac_fn_c_check_func "$LINENO" "gmtime_r" "ac_cv_func_gmtime_r"
20278 if test "x$ac_cv_func_gmtime_r" = xyes; then :
20279 $as_echo "#define HAVE_GMTIME_R 1" >>confdefs.h
20280
20281 else
20282 case " $LIBOBJS " in
20283 *" gmtime_r.$ac_objext "* ) ;;
20284 *) LIBOBJS="$LIBOBJS gmtime_r.$ac_objext"
20285 ;;
20286 esac
20287
20288 fi
20289
20290
20291 ac_fn_c_check_func "$LINENO" "isblank" "ac_cv_func_isblank"
20292 if test "x$ac_cv_func_isblank" = xyes; then :
20293 $as_echo "#define HAVE_ISBLANK 1" >>confdefs.h
20294
20295 else
20296 case " $LIBOBJS " in
20297 *" isblank.$ac_objext "* ) ;;
20298 *) LIBOBJS="$LIBOBJS isblank.$ac_objext"
20299 ;;
20300 esac
20301
20302 fi
20303
20304
20305 ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero"
20306 if test "x$ac_cv_func_explicit_bzero" = xyes; then :
20307 $as_echo "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h
20308
20309 else
20310 case " $LIBOBJS " in
20311 *" explicit_bzero.$ac_objext "* ) ;;
20312 *) LIBOBJS="$LIBOBJS explicit_bzero.$ac_objext"
20313 ;;
20314 esac
20315
20316 fi
20317
20318
20319 LIBOBJ_WITHOUT_CTIMEARC4="$LIBOBJS"
20320
20321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for reallocarray" >&5
20322 $as_echo_n "checking for reallocarray... " >&6; }
20323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20324 /* end confdefs.h. */
20325 $ac_includes_default
20326
20327 #ifndef _OPENBSD_SOURCE
20328 #define _OPENBSD_SOURCE 1
20329 #endif
20330 #include <stdlib.h>
20331 int main(void) {
20332 void* p = reallocarray(NULL, 10, 100);
20333 free(p);
20334 return 0;
20335 }
20336
20337 _ACEOF
20338 if ac_fn_c_try_link "$LINENO"; then :
20339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20340 $as_echo "yes" >&6; }
20341
20342 $as_echo "#define HAVE_REALLOCARRAY 1" >>confdefs.h
20343
20344
20345 else
20346
20347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20348 $as_echo "no" >&6; }
20349 case " $LIBOBJS " in
20350 *" reallocarray.$ac_objext "* ) ;;
20351 *) LIBOBJS="$LIBOBJS reallocarray.$ac_objext"
20352 ;;
20353 esac
20354
20355
20356 fi
20357 rm -f core conftest.err conftest.$ac_objext \
20358 conftest$ac_exeext conftest.$ac_ext
20359 ac_fn_c_check_decl "$LINENO" "reallocarray" "ac_cv_have_decl_reallocarray" "$ac_includes_default"
20360 if test "x$ac_cv_have_decl_reallocarray" = xyes; then :
20361 ac_have_decl=1
20362 else
20363 ac_have_decl=0
20364 fi
20365
20366 cat >>confdefs.h <<_ACEOF
20367 #define HAVE_DECL_REALLOCARRAY $ac_have_decl
20368 _ACEOF
20369
20370 if test "$USE_NSS" = "no"; then
20371 ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
20372 if test "x$ac_cv_func_arc4random" = xyes; then :
20373 $as_echo "#define HAVE_ARC4RANDOM 1" >>confdefs.h
20374
20375 else
20376 case " $LIBOBJS " in
20377 *" arc4random.$ac_objext "* ) ;;
20378 *) LIBOBJS="$LIBOBJS arc4random.$ac_objext"
20379 ;;
20380 esac
20381
20382 fi
20383
20384
20385 ac_fn_c_check_func "$LINENO" "arc4random_uniform" "ac_cv_func_arc4random_uniform"
20386 if test "x$ac_cv_func_arc4random_uniform" = xyes; then :
20387 $as_echo "#define HAVE_ARC4RANDOM_UNIFORM 1" >>confdefs.h
20388
20389 else
20390 case " $LIBOBJS " in
20391 *" arc4random_uniform.$ac_objext "* ) ;;
20392 *) LIBOBJS="$LIBOBJS arc4random_uniform.$ac_objext"
20393 ;;
20394 esac
20395
20396 fi
20397
20398
20399 if test "$ac_cv_func_arc4random" = "no"; then
20400 case " $LIBOBJS " in
20401 *" arc4_lock.$ac_objext "* ) ;;
20402 *) LIBOBJS="$LIBOBJS arc4_lock.$ac_objext"
20403 ;;
20404 esac
20405
20406 for ac_func in getentropy
20407 do :
20408 ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
20409 if test "x$ac_cv_func_getentropy" = xyes; then :
20410 cat >>confdefs.h <<_ACEOF
20411 #define HAVE_GETENTROPY 1
20412 _ACEOF
20413
20414 else
20415
20416 if test "$USE_WINSOCK" = 1; then
20417 case " $LIBOBJS " in
20418 *" getentropy_win.$ac_objext "* ) ;;
20419 *) LIBOBJS="$LIBOBJS getentropy_win.$ac_objext"
20420 ;;
20421 esac
20422
20423 else
20424 case "$host" in
20425 Darwin|*darwin*)
20426 case " $LIBOBJS " in
20427 *" getentropy_osx.$ac_objext "* ) ;;
20428 *) LIBOBJS="$LIBOBJS getentropy_osx.$ac_objext"
20429 ;;
20430 esac
20431
20432 ;;
20433 *solaris*|*sunos*|SunOS)
20434 case " $LIBOBJS " in
20435 *" getentropy_solaris.$ac_objext "* ) ;;
20436 *) LIBOBJS="$LIBOBJS getentropy_solaris.$ac_objext"
20437 ;;
20438 esac
20439
20440 for ac_header in sys/sha2.h
20441 do :
20442 ac_fn_c_check_header_compile "$LINENO" "sys/sha2.h" "ac_cv_header_sys_sha2_h" "$ac_includes_default
20443 "
20444 if test "x$ac_cv_header_sys_sha2_h" = xyes; then :
20445 cat >>confdefs.h <<_ACEOF
20446 #define HAVE_SYS_SHA2_H 1
20447 _ACEOF
20448
20449 else
20450
20451 for ac_func in SHA512_Update
20452 do :
20453 ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
20454 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
20455 cat >>confdefs.h <<_ACEOF
20456 #define HAVE_SHA512_UPDATE 1
20457 _ACEOF
20458
20459 else
20460
20461 case " $LIBOBJS " in
20462 *" sha512.$ac_objext "* ) ;;
20463 *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
20464 ;;
20465 esac
20466
20467
20468 fi
20469 done
20470
20471
20472 fi
20473
20474 done
20475
20476 if test "$ac_cv_header_sys_sha2_h" = "yes"; then
20477 # this lib needed for sha2 on solaris
20478 LIBS="$LIBS -lmd"
20479 fi
20480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20481 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20482 if ${ac_cv_search_clock_gettime+:} false; then :
20483 $as_echo_n "(cached) " >&6
20484 else
20485 ac_func_search_save_LIBS=$LIBS
20486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20487 /* end confdefs.h. */
20488
20489 /* Override any GCC internal prototype to avoid an error.
20490 Use char because int might match the return type of a GCC
20491 builtin and then its argument prototype would still apply. */
20492 #ifdef __cplusplus
20493 extern "C"
20494 #endif
20495 char clock_gettime ();
20496 int
20497 main ()
20498 {
20499 return clock_gettime ();
20500 ;
20501 return 0;
20502 }
20503 _ACEOF
20504 for ac_lib in '' rt; do
20505 if test -z "$ac_lib"; then
20506 ac_res="none required"
20507 else
20508 ac_res=-l$ac_lib
20509 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20510 fi
20511 if ac_fn_c_try_link "$LINENO"; then :
20512 ac_cv_search_clock_gettime=$ac_res
20513 fi
20514 rm -f core conftest.err conftest.$ac_objext \
20515 conftest$ac_exeext
20516 if ${ac_cv_search_clock_gettime+:} false; then :
20517 break
20518 fi
20519 done
20520 if ${ac_cv_search_clock_gettime+:} false; then :
20521
20522 else
20523 ac_cv_search_clock_gettime=no
20524 fi
20525 rm conftest.$ac_ext
20526 LIBS=$ac_func_search_save_LIBS
20527 fi
20528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20529 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20530 ac_res=$ac_cv_search_clock_gettime
20531 if test "$ac_res" != no; then :
20532 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20533
20534 fi
20535
20536 ;;
20537 *freebsd*|*FreeBSD)
20538 case " $LIBOBJS " in
20539 *" getentropy_freebsd.$ac_objext "* ) ;;
20540 *) LIBOBJS="$LIBOBJS getentropy_freebsd.$ac_objext"
20541 ;;
20542 esac
20543
20544 ;;
20545 *linux*|Linux|*)
20546 case " $LIBOBJS " in
20547 *" getentropy_linux.$ac_objext "* ) ;;
20548 *) LIBOBJS="$LIBOBJS getentropy_linux.$ac_objext"
20549 ;;
20550 esac
20551
20552 for ac_func in SHA512_Update
20553 do :
20554 ac_fn_c_check_func "$LINENO" "SHA512_Update" "ac_cv_func_SHA512_Update"
20555 if test "x$ac_cv_func_SHA512_Update" = xyes; then :
20556 cat >>confdefs.h <<_ACEOF
20557 #define HAVE_SHA512_UPDATE 1
20558 _ACEOF
20559
20560 else
20561
20562
20563 $as_echo "#define COMPAT_SHA512 1" >>confdefs.h
20564
20565 case " $LIBOBJS " in
20566 *" sha512.$ac_objext "* ) ;;
20567 *) LIBOBJS="$LIBOBJS sha512.$ac_objext"
20568 ;;
20569 esac
20570
20571
20572 fi
20573 done
20574
20575 for ac_header in sys/sysctl.h
20576 do :
20577 ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default
20578 "
20579 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
20580 cat >>confdefs.h <<_ACEOF
20581 #define HAVE_SYS_SYSCTL_H 1
20582 _ACEOF
20583
20584 fi
20585
20586 done
20587
20588 for ac_func in getauxval
20589 do :
20590 ac_fn_c_check_func "$LINENO" "getauxval" "ac_cv_func_getauxval"
20591 if test "x$ac_cv_func_getauxval" = xyes; then :
20592 cat >>confdefs.h <<_ACEOF
20593 #define HAVE_GETAUXVAL 1
20594 _ACEOF
20595
20596 fi
20597 done
20598
20599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20600 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20601 if ${ac_cv_search_clock_gettime+:} false; then :
20602 $as_echo_n "(cached) " >&6
20603 else
20604 ac_func_search_save_LIBS=$LIBS
20605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20606 /* end confdefs.h. */
20607
20608 /* Override any GCC internal prototype to avoid an error.
20609 Use char because int might match the return type of a GCC
20610 builtin and then its argument prototype would still apply. */
20611 #ifdef __cplusplus
20612 extern "C"
20613 #endif
20614 char clock_gettime ();
20615 int
20616 main ()
20617 {
20618 return clock_gettime ();
20619 ;
20620 return 0;
20621 }
20622 _ACEOF
20623 for ac_lib in '' rt; do
20624 if test -z "$ac_lib"; then
20625 ac_res="none required"
20626 else
20627 ac_res=-l$ac_lib
20628 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20629 fi
20630 if ac_fn_c_try_link "$LINENO"; then :
20631 ac_cv_search_clock_gettime=$ac_res
20632 fi
20633 rm -f core conftest.err conftest.$ac_objext \
20634 conftest$ac_exeext
20635 if ${ac_cv_search_clock_gettime+:} false; then :
20636 break
20637 fi
20638 done
20639 if ${ac_cv_search_clock_gettime+:} false; then :
20640
20641 else
20642 ac_cv_search_clock_gettime=no
20643 fi
20644 rm conftest.$ac_ext
20645 LIBS=$ac_func_search_save_LIBS
20646 fi
20647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20648 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20649 ac_res=$ac_cv_search_clock_gettime
20650 if test "$ac_res" != no; then :
20651 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20652
20653 fi
20654
20655 ;;
20656 esac
20657 fi
20658
20659 fi
20660 done
20661
20662 fi
20663 fi
20664 LIBOBJ_WITHOUT_CTIME="$LIBOBJS"
20665
20666 ac_fn_c_check_func "$LINENO" "ctime_r" "ac_cv_func_ctime_r"
20667 if test "x$ac_cv_func_ctime_r" = xyes; then :
20668 $as_echo "#define HAVE_CTIME_R 1" >>confdefs.h
20669
20670 else
20671 case " $LIBOBJS " in
20672 *" ctime_r.$ac_objext "* ) ;;
20673 *) LIBOBJS="$LIBOBJS ctime_r.$ac_objext"
20674 ;;
20675 esac
20676
20677 fi
20678
20679
20680 ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
20681 if test "x$ac_cv_func_strsep" = xyes; then :
20682 $as_echo "#define HAVE_STRSEP 1" >>confdefs.h
20683
20684 else
20685 case " $LIBOBJS " in
20686 *" strsep.$ac_objext "* ) ;;
20687 *) LIBOBJS="$LIBOBJS strsep.$ac_objext"
20688 ;;
20689 esac
20690
20691 fi
20692
20693
20694
20695 # Check whether --enable-allsymbols was given.
20696 if test "${enable_allsymbols+set}" = set; then :
20697 enableval=$enable_allsymbols;
20698 fi
20699
20700 case "$enable_allsymbols" in
20701 yes)
20702 COMMON_OBJ_ALL_SYMBOLS=""
20703 UBSYMS=""
20704 EXTRALINK="-L. -L.libs -lunbound"
20705
20706 $as_echo "#define EXPORT_ALL_SYMBOLS 1" >>confdefs.h
20707
20708 ;;
20709 no|*)
20710 COMMON_OBJ_ALL_SYMBOLS='$(COMMON_OBJ)'
20711 UBSYMS='-export-symbols $(srcdir)/libunbound/ubsyms.def'
20712 EXTRALINK=""
20713 ;;
20714 esac
20715
20716
20717
20718 if test x_$enable_lock_checks = x_yes; then
20719 UBSYMS="-export-symbols clubsyms.def"
20720 cp ${srcdir}/libunbound/ubsyms.def clubsyms.def
20721 echo lock_protect >> clubsyms.def
20722 echo lock_unprotect >> clubsyms.def
20723 echo lock_get_mem >> clubsyms.def
20724 echo checklock_start >> clubsyms.def
20725 echo checklock_stop >> clubsyms.def
20726 echo checklock_lock >> clubsyms.def
20727 echo checklock_unlock >> clubsyms.def
20728 echo checklock_init >> clubsyms.def
20729 echo checklock_thrcreate >> clubsyms.def
20730 echo checklock_thrjoin >> clubsyms.def
20731 fi
20732
20733 # check for dnstap if requested
20734
20735 # Check whether --enable-dnstap was given.
20736 if test "${enable_dnstap+set}" = set; then :
20737 enableval=$enable_dnstap; opt_dnstap=$enableval
20738 else
20739 opt_dnstap=no
20740 fi
20741
20742
20743
20744 # Check whether --with-dnstap-socket-path was given.
20745 if test "${with_dnstap_socket_path+set}" = set; then :
20746 withval=$with_dnstap_socket_path; opt_dnstap_socket_path=$withval
20747 else
20748 opt_dnstap_socket_path="$UNBOUND_RUN_DIR/dnstap.sock"
20749 fi
20750
20751
20752 if test "x$opt_dnstap" != "xno"; then
20753 # Extract the first word of "protoc-c", so it can be a program name with args.
20754 set dummy protoc-c; ac_word=$2
20755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20756 $as_echo_n "checking for $ac_word... " >&6; }
20757 if ${ac_cv_path_PROTOC_C+:} false; then :
20758 $as_echo_n "(cached) " >&6
20759 else
20760 case $PROTOC_C in
20761 [\\/]* | ?:[\\/]*)
20762 ac_cv_path_PROTOC_C="$PROTOC_C" # Let the user override the test with a path.
20763 ;;
20764 *)
20765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20766 for as_dir in $PATH
20767 do
20768 IFS=$as_save_IFS
20769 test -z "$as_dir" && as_dir=.
20770 for ac_exec_ext in '' $ac_executable_extensions; do
20771 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20772 ac_cv_path_PROTOC_C="$as_dir/$ac_word$ac_exec_ext"
20773 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20774 break 2
20775 fi
20776 done
20777 done
20778 IFS=$as_save_IFS
20779
20780 ;;
20781 esac
20782 fi
20783 PROTOC_C=$ac_cv_path_PROTOC_C
20784 if test -n "$PROTOC_C"; then
20785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROTOC_C" >&5
20786 $as_echo "$PROTOC_C" >&6; }
20787 else
20788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20789 $as_echo "no" >&6; }
20790 fi
20791
20792
20793 if test -z "$PROTOC_C"; then
20794 as_fn_error $? "The protoc-c program was not found. Please install protobuf-c!" "$LINENO" 5
20795 fi
20796
20797 # Check whether --with-protobuf-c was given.
20798 if test "${with_protobuf_c+set}" = set; then :
20799 withval=$with_protobuf_c;
20800 # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
20801 if test -f $withval/include/google/protobuf-c/protobuf-c.h; then
20802 CFLAGS="$CFLAGS -I$withval/include/google"
20803 else
20804 CFLAGS="$CFLAGS -I$withval/include"
20805 fi
20806 LDFLAGS="$LDFLAGS -L$withval/lib"
20807
20808 else
20809
20810 # workaround for protobuf-c includes at old dir before protobuf-c-1.0.0
20811 if test -f /usr/include/google/protobuf-c/protobuf-c.h; then
20812 CFLAGS="$CFLAGS -I/usr/include/google"
20813 else
20814 if test -f /usr/local/include/google/protobuf-c/protobuf-c.h; then
20815 CFLAGS="$CFLAGS -I/usr/local/include/google"
20816 LDFLAGS="$LDFLAGS -L/usr/local/lib"
20817 fi
20818 fi
20819
20820 fi
20821
20822
20823 # Check whether --with-libfstrm was given.
20824 if test "${with_libfstrm+set}" = set; then :
20825 withval=$with_libfstrm;
20826 CFLAGS="$CFLAGS -I$withval/include"
20827 LDFLAGS="$LDFLAGS -L$withval/lib"
20828
20829 fi
20830
20831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fstrm_iothr_init" >&5
20832 $as_echo_n "checking for library containing fstrm_iothr_init... " >&6; }
20833 if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20834 $as_echo_n "(cached) " >&6
20835 else
20836 ac_func_search_save_LIBS=$LIBS
20837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20838 /* end confdefs.h. */
20839
20840 /* Override any GCC internal prototype to avoid an error.
20841 Use char because int might match the return type of a GCC
20842 builtin and then its argument prototype would still apply. */
20843 #ifdef __cplusplus
20844 extern "C"
20845 #endif
20846 char fstrm_iothr_init ();
20847 int
20848 main ()
20849 {
20850 return fstrm_iothr_init ();
20851 ;
20852 return 0;
20853 }
20854 _ACEOF
20855 for ac_lib in '' fstrm; do
20856 if test -z "$ac_lib"; then
20857 ac_res="none required"
20858 else
20859 ac_res=-l$ac_lib
20860 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20861 fi
20862 if ac_fn_c_try_link "$LINENO"; then :
20863 ac_cv_search_fstrm_iothr_init=$ac_res
20864 fi
20865 rm -f core conftest.err conftest.$ac_objext \
20866 conftest$ac_exeext
20867 if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20868 break
20869 fi
20870 done
20871 if ${ac_cv_search_fstrm_iothr_init+:} false; then :
20872
20873 else
20874 ac_cv_search_fstrm_iothr_init=no
20875 fi
20876 rm conftest.$ac_ext
20877 LIBS=$ac_func_search_save_LIBS
20878 fi
20879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fstrm_iothr_init" >&5
20880 $as_echo "$ac_cv_search_fstrm_iothr_init" >&6; }
20881 ac_res=$ac_cv_search_fstrm_iothr_init
20882 if test "$ac_res" != no; then :
20883 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20884
20885 else
20886 as_fn_error $? "The fstrm library was not found. Please install fstrm!" "$LINENO" 5
20887 fi
20888
20889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing protobuf_c_message_pack" >&5
20890 $as_echo_n "checking for library containing protobuf_c_message_pack... " >&6; }
20891 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20892 $as_echo_n "(cached) " >&6
20893 else
20894 ac_func_search_save_LIBS=$LIBS
20895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20896 /* end confdefs.h. */
20897
20898 /* Override any GCC internal prototype to avoid an error.
20899 Use char because int might match the return type of a GCC
20900 builtin and then its argument prototype would still apply. */
20901 #ifdef __cplusplus
20902 extern "C"
20903 #endif
20904 char protobuf_c_message_pack ();
20905 int
20906 main ()
20907 {
20908 return protobuf_c_message_pack ();
20909 ;
20910 return 0;
20911 }
20912 _ACEOF
20913 for ac_lib in '' protobuf-c; do
20914 if test -z "$ac_lib"; then
20915 ac_res="none required"
20916 else
20917 ac_res=-l$ac_lib
20918 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20919 fi
20920 if ac_fn_c_try_link "$LINENO"; then :
20921 ac_cv_search_protobuf_c_message_pack=$ac_res
20922 fi
20923 rm -f core conftest.err conftest.$ac_objext \
20924 conftest$ac_exeext
20925 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20926 break
20927 fi
20928 done
20929 if ${ac_cv_search_protobuf_c_message_pack+:} false; then :
20930
20931 else
20932 ac_cv_search_protobuf_c_message_pack=no
20933 fi
20934 rm conftest.$ac_ext
20935 LIBS=$ac_func_search_save_LIBS
20936 fi
20937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_protobuf_c_message_pack" >&5
20938 $as_echo "$ac_cv_search_protobuf_c_message_pack" >&6; }
20939 ac_res=$ac_cv_search_protobuf_c_message_pack
20940 if test "$ac_res" != no; then :
20941 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20942
20943 else
20944 as_fn_error $? "The protobuf-c library was not found. Please install protobuf-c!" "$LINENO" 5
20945 fi
20946
20947
20948
20949 $as_echo "#define USE_DNSTAP 1" >>confdefs.h
20950
20951 ENABLE_DNSTAP=1
20952
20953
20954
20955 hdr_dnstap_socket_path="`echo $opt_dnstap_socket_path | sed -e 's/\\\\/\\\\\\\\/g'`"
20956
20957
20958 cat >>confdefs.h <<_ACEOF
20959 #define DNSTAP_SOCKET_PATH "$hdr_dnstap_socket_path"
20960 _ACEOF
20961
20962
20963 DNSTAP_SRC="dnstap/dnstap.c dnstap/dnstap.pb-c.c"
20964
20965 DNSTAP_OBJ="dnstap.lo dnstap.pb-c.lo"
20966
20967
20968 else
20969
20970 ENABLE_DNSTAP=0
20971
20972
20973
20974 fi
20975
20976
20977 # check for dnscrypt if requested
20978
20979 # Check whether --enable-dnscrypt was given.
20980 if test "${enable_dnscrypt+set}" = set; then :
20981 enableval=$enable_dnscrypt; opt_dnscrypt=$enableval
20982 else
20983 opt_dnscrypt=no
20984 fi
20985
20986
20987 if test "x$opt_dnscrypt" != "xno"; then
20988
20989 # Check whether --with-libsodium was given.
20990 if test "${with_libsodium+set}" = set; then :
20991 withval=$with_libsodium;
20992 CFLAGS="$CFLAGS -I$withval/include"
20993 LDFLAGS="$LDFLAGS -L$withval/lib"
20994
20995 fi
20996
20997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_init" >&5
20998 $as_echo_n "checking for library containing sodium_init... " >&6; }
20999 if ${ac_cv_search_sodium_init+:} false; then :
21000 $as_echo_n "(cached) " >&6
21001 else
21002 ac_func_search_save_LIBS=$LIBS
21003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21004 /* end confdefs.h. */
21005
21006 /* Override any GCC internal prototype to avoid an error.
21007 Use char because int might match the return type of a GCC
21008 builtin and then its argument prototype would still apply. */
21009 #ifdef __cplusplus
21010 extern "C"
21011 #endif
21012 char sodium_init ();
21013 int
21014 main ()
21015 {
21016 return sodium_init ();
21017 ;
21018 return 0;
21019 }
21020 _ACEOF
21021 for ac_lib in '' sodium; do
21022 if test -z "$ac_lib"; then
21023 ac_res="none required"
21024 else
21025 ac_res=-l$ac_lib
21026 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
21027 fi
21028 if ac_fn_c_try_link "$LINENO"; then :
21029 ac_cv_search_sodium_init=$ac_res
21030 fi
21031 rm -f core conftest.err conftest.$ac_objext \
21032 conftest$ac_exeext
21033 if ${ac_cv_search_sodium_init+:} false; then :
21034 break
21035 fi
21036 done
21037 if ${ac_cv_search_sodium_init+:} false; then :
21038
21039 else
21040 ac_cv_search_sodium_init=no
21041 fi
21042 rm conftest.$ac_ext
21043 LIBS=$ac_func_search_save_LIBS
21044 fi
21045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_init" >&5
21046 $as_echo "$ac_cv_search_sodium_init" >&6; }
21047 ac_res=$ac_cv_search_sodium_init
21048 if test "$ac_res" != no; then :
21049 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21050
21051 else
21052 as_fn_error $? "The sodium library was not found. Please install sodium!" "$LINENO" 5
21053 fi
21054
21055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21056 $as_echo_n "checking for library containing crypto_box_curve25519xchacha20poly1305_beforenm... " >&6; }
21057 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21058 $as_echo_n "(cached) " >&6
21059 else
21060 ac_func_search_save_LIBS=$LIBS
21061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21062 /* end confdefs.h. */
21063
21064 /* Override any GCC internal prototype to avoid an error.
21065 Use char because int might match the return type of a GCC
21066 builtin and then its argument prototype would still apply. */
21067 #ifdef __cplusplus
21068 extern "C"
21069 #endif
21070 char crypto_box_curve25519xchacha20poly1305_beforenm ();
21071 int
21072 main ()
21073 {
21074 return crypto_box_curve25519xchacha20poly1305_beforenm ();
21075 ;
21076 return 0;
21077 }
21078 _ACEOF
21079 for ac_lib in '' sodium; do
21080 if test -z "$ac_lib"; then
21081 ac_res="none required"
21082 else
21083 ac_res=-l$ac_lib
21084 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
21085 fi
21086 if ac_fn_c_try_link "$LINENO"; then :
21087 ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=$ac_res
21088 fi
21089 rm -f core conftest.err conftest.$ac_objext \
21090 conftest$ac_exeext
21091 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21092 break
21093 fi
21094 done
21095 if ${ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm+:} false; then :
21096
21097 else
21098 ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm=no
21099 fi
21100 rm conftest.$ac_ext
21101 LIBS=$ac_func_search_save_LIBS
21102 fi
21103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&5
21104 $as_echo "$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm" >&6; }
21105 ac_res=$ac_cv_search_crypto_box_curve25519xchacha20poly1305_beforenm
21106 if test "$ac_res" != no; then :
21107 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21108
21109 ENABLE_DNSCRYPT_XCHACHA20=1
21110
21111
21112 $as_echo "#define USE_DNSCRYPT_XCHACHA20 1" >>confdefs.h
21113
21114
21115 else
21116
21117 ENABLE_DNSCRYPT_XCHACHA20=0
21118
21119
21120 fi
21121
21122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sodium_set_misuse_handler" >&5
21123 $as_echo_n "checking for library containing sodium_set_misuse_handler... " >&6; }
21124 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21125 $as_echo_n "(cached) " >&6
21126 else
21127 ac_func_search_save_LIBS=$LIBS
21128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21129 /* end confdefs.h. */
21130
21131 /* Override any GCC internal prototype to avoid an error.
21132 Use char because int might match the return type of a GCC
21133 builtin and then its argument prototype would still apply. */
21134 #ifdef __cplusplus
21135 extern "C"
21136 #endif
21137 char sodium_set_misuse_handler ();
21138 int
21139 main ()
21140 {
21141 return sodium_set_misuse_handler ();
21142 ;
21143 return 0;
21144 }
21145 _ACEOF
21146 for ac_lib in '' sodium; do
21147 if test -z "$ac_lib"; then
21148 ac_res="none required"
21149 else
21150 ac_res=-l$ac_lib
21151 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
21152 fi
21153 if ac_fn_c_try_link "$LINENO"; then :
21154 ac_cv_search_sodium_set_misuse_handler=$ac_res
21155 fi
21156 rm -f core conftest.err conftest.$ac_objext \
21157 conftest$ac_exeext
21158 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21159 break
21160 fi
21161 done
21162 if ${ac_cv_search_sodium_set_misuse_handler+:} false; then :
21163
21164 else
21165 ac_cv_search_sodium_set_misuse_handler=no
21166 fi
21167 rm conftest.$ac_ext
21168 LIBS=$ac_func_search_save_LIBS
21169 fi
21170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sodium_set_misuse_handler" >&5
21171 $as_echo "$ac_cv_search_sodium_set_misuse_handler" >&6; }
21172 ac_res=$ac_cv_search_sodium_set_misuse_handler
21173 if test "$ac_res" != no; then :
21174 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21175
21176
21177 $as_echo "#define SODIUM_MISUSE_HANDLER 1" >>confdefs.h
21178
21179
21180 fi
21181
21182
21183
21184 $as_echo "#define USE_DNSCRYPT 1" >>confdefs.h
21185
21186 ENABLE_DNSCRYPT=1
21187
21188
21189 DNSCRYPT_SRC="dnscrypt/dnscrypt.c"
21190
21191 DNSCRYPT_OBJ="dnscrypt.lo"
21192
21193
21194 else
21195 ENABLE_DNSCRYPT_XCHACHA20=0
21196
21197
21198 ENABLE_DNSCRYPT=0
21199
21200
21201
21202 fi
21203
21204
21205 # check for cachedb if requested
21206 # Check whether --enable-cachedb was given.
21207 if test "${enable_cachedb+set}" = set; then :
21208 enableval=$enable_cachedb;
21209 fi
21210
21211 # turn on cachedb when hiredis support is enabled.
21212 if test "$found_libhiredis" = "yes"; then enable_cachedb="yes"; fi
21213 case "$enable_cachedb" in
21214 yes)
21215
21216 $as_echo "#define USE_CACHEDB 1" >>confdefs.h
21217
21218 ;;
21219 no|*)
21220 # nothing
21221 ;;
21222 esac
21223
21224 # check for ipsecmod if requested
21225 # Check whether --enable-ipsecmod was given.
21226 if test "${enable_ipsecmod+set}" = set; then :
21227 enableval=$enable_ipsecmod;
21228 fi
21229
21230 case "$enable_ipsecmod" in
21231 yes)
21232
21233 $as_echo "#define USE_IPSECMOD 1" >>confdefs.h
21234
21235 IPSECMOD_OBJ="ipsecmod.lo ipsecmod-whitelist.lo"
21236
21237 IPSECMOD_HEADER='$(srcdir)/ipsecmod/ipsecmod.h $(srcdir)/ipsecmod/ipsecmod-whitelist.h'
21238
21239 ;;
21240 no|*)
21241 # nothing
21242 ;;
21243 esac
21244
21245 # check for ipset if requested
21246 # Check whether --enable-ipset was given.
21247 if test "${enable_ipset+set}" = set; then :
21248 enableval=$enable_ipset;
21249 fi
21250
21251 case "$enable_ipset" in
21252 yes)
21253
21254 $as_echo "#define USE_IPSET 1" >>confdefs.h
21255
21256 IPSET_SRC="ipset/ipset.c"
21257
21258 IPSET_OBJ="ipset.lo"
21259
21260
21261 # mnl
21262
21263 # Check whether --with-libmnl was given.
21264 if test "${with_libmnl+set}" = set; then :
21265 withval=$with_libmnl;
21266 else
21267 withval="yes"
21268 fi
21269
21270 found_libmnl="no"
21271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmnl" >&5
21272 $as_echo_n "checking for libmnl... " >&6; }
21273 if test x_$withval = x_ -o x_$withval = x_yes; then
21274 withval="/usr/local /opt/local /usr/lib /usr/pkg /usr/sfw /usr"
21275 fi
21276 for dir in $withval ; do
21277 if test -f "$dir/include/libmnl/libmnl.h"; then
21278 found_libmnl="yes"
21279 if test "$dir" != "/usr"; then
21280 CPPFLAGS="$CPPFLAGS -I$dir/include"
21281 LDFLAGS="$LDFLAGS -L$dir/lib"
21282 fi
21283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $dir" >&5
21284 $as_echo "found in $dir" >&6; }
21285 LIBS="$LIBS -lmnl"
21286 break;
21287 fi
21288 done
21289 if test x_$found_libmnl != x_yes; then
21290 as_fn_error $? "Could not find libmnl, libmnl.h" "$LINENO" 5
21291 fi
21292 ;;
21293 no|*)
21294 # nothing
21295 ;;
21296 esac
21297
21298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ${MAKE:-make} supports $< with implicit rule in scope" >&5
21299 $as_echo_n "checking if ${MAKE:-make} supports $< with implicit rule in scope... " >&6; }
21300 # on openBSD, the implicit rule make $< work.
21301 # on Solaris, it does not work ($? is changed sources, $^ lists dependencies).
21302 # gmake works.
21303 cat >conftest.make <<EOF
21304 all: conftest.lo
21305
21306 conftest.lo foo.lo bla.lo:
21307 if test -f "\$<"; then touch \$@; fi
21308
21309 .SUFFIXES: .lo
21310 .c.lo:
21311 if test -f "\$<"; then touch \$@; fi
21312
21313 conftest.lo: conftest.dir/conftest.c
21314 EOF
21315 mkdir conftest.dir
21316 touch conftest.dir/conftest.c
21317 rm -f conftest.lo conftest.c
21318 ${MAKE:-make} -f conftest.make >/dev/null
21319 rm -f conftest.make conftest.c conftest.dir/conftest.c
21320 rm -rf conftest.dir
21321 if test ! -f conftest.lo; then
21322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21323 $as_echo "no" >&6; }
21324 SOURCEDETERMINE='echo "$^" | awk "-F " "{print \$$1;}" > .source'
21325 SOURCEFILE='`cat .source`'
21326 else
21327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21328 $as_echo "yes" >&6; }
21329 SOURCEDETERMINE=':'
21330 SOURCEFILE='$<'
21331 fi
21332 rm -f conftest.lo
21333
21334
21335
21336 # see if we want to build the library or everything
21337 ALLTARGET="alltargets"
21338 INSTALLTARGET="install-all"
21339
21340 # Check whether --with-libunbound-only was given.
21341 if test "${with_libunbound_only+set}" = set; then :
21342 withval=$with_libunbound_only;
21343 if test "$withval" = "yes"; then
21344 ALLTARGET="lib"
21345 INSTALLTARGET="install-lib"
21346 fi
21347
21348 fi
21349
21350 if test $ALLTARGET = "alltargets"; then
21351 if test $USE_NSS = "yes"; then
21352 as_fn_error $? "--with-nss can only be used in combination with --with-libunbound-only." "$LINENO" 5
21353 fi
21354 if test $USE_NETTLE = "yes"; then
21355 as_fn_error $? "--with-nettle can only be used in combination with --with-libunbound-only." "$LINENO" 5
21356 fi
21357 fi
21358
21359
21360
21361
21362
21363 { $as_echo "$as_me:${as_lineno-$LINENO}: Stripping extension flags..." >&5
21364 $as_echo "$as_me: Stripping extension flags..." >&6;}
21365
21366 if echo $CFLAGS | grep " -D_GNU_SOURCE" >/dev/null 2>&1; then
21367 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_GNU_SOURCE//g'`"
21368
21369 $as_echo "#define OMITTED__D_GNU_SOURCE 1" >>confdefs.h
21370
21371 fi
21372
21373
21374 if echo $CFLAGS | grep " -D_BSD_SOURCE" >/dev/null 2>&1; then
21375 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_BSD_SOURCE//g'`"
21376
21377 $as_echo "#define OMITTED__D_BSD_SOURCE 1" >>confdefs.h
21378
21379 fi
21380
21381
21382 if echo $CFLAGS | grep " -D_DEFAULT_SOURCE" >/dev/null 2>&1; then
21383 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_DEFAULT_SOURCE//g'`"
21384
21385 $as_echo "#define OMITTED__D_DEFAULT_SOURCE 1" >>confdefs.h
21386
21387 fi
21388
21389
21390 if echo $CFLAGS | grep " -D__EXTENSIONS__" >/dev/null 2>&1; then
21391 CFLAGS="`echo $CFLAGS | sed -e 's/ -D__EXTENSIONS__//g'`"
21392
21393 $as_echo "#define OMITTED__D__EXTENSIONS__ 1" >>confdefs.h
21394
21395 fi
21396
21397
21398 if echo $CFLAGS | grep " -D_POSIX_C_SOURCE=200112" >/dev/null 2>&1; then
21399 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_POSIX_C_SOURCE=200112//g'`"
21400
21401 $as_echo "#define OMITTED__D_POSIX_C_SOURCE_200112 1" >>confdefs.h
21402
21403 fi
21404
21405
21406 if echo $CFLAGS | grep " -D_XOPEN_SOURCE=600" >/dev/null 2>&1; then
21407 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE=600//g'`"
21408
21409 $as_echo "#define OMITTED__D_XOPEN_SOURCE_600 1" >>confdefs.h
21410
21411 fi
21412
21413
21414 if echo $CFLAGS | grep " -D_XOPEN_SOURCE_EXTENDED=1" >/dev/null 2>&1; then
21415 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_XOPEN_SOURCE_EXTENDED=1//g'`"
21416
21417 $as_echo "#define OMITTED__D_XOPEN_SOURCE_EXTENDED_1 1" >>confdefs.h
21418
21419 fi
21420
21421
21422 if echo $CFLAGS | grep " -D_ALL_SOURCE" >/dev/null 2>&1; then
21423 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_ALL_SOURCE//g'`"
21424
21425 $as_echo "#define OMITTED__D_ALL_SOURCE 1" >>confdefs.h
21426
21427 fi
21428
21429
21430 if echo $CFLAGS | grep " -D_LARGEFILE_SOURCE=1" >/dev/null 2>&1; then
21431 CFLAGS="`echo $CFLAGS | sed -e 's/ -D_LARGEFILE_SOURCE=1//g'`"
21432
21433 $as_echo "#define OMITTED__D_LARGEFILE_SOURCE_1 1" >>confdefs.h
21434
21435 fi
21436
21437
21438 if test -n "$LATE_LDFLAGS"; then
21439 LDFLAGS="$LATE_LDFLAGS $LDFLAGS"
21440 fi
21441 # remove start spaces
21442 LDFLAGS=`echo "$LDFLAGS"|sed -e 's/^ *//'`
21443 LIBS=`echo "$LIBS"|sed -e 's/^ *//'`
21444
21445
21446 cat >>confdefs.h <<_ACEOF
21447 #define MAXSYSLOGMSGLEN 10240
21448 _ACEOF
21449
21450
21451
21452
21453 version=1.9.6
21454
21455 date=`date +'%b %e, %Y'`
21456
21457
21458 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"
21459
21460 ac_config_headers="$ac_config_headers config.h"
21461
21462 cat >confcache <<\_ACEOF
21463 # This file is a shell script that caches the results of configure
21464 # tests run on this system so they can be shared between configure
21465 # scripts and configure runs, see configure's option --config-cache.
21466 # It is not useful on other systems. If it contains results you don't
21467 # want to keep, you may remove or edit it.
21468 #
21469 # config.status only pays attention to the cache file if you give it
21470 # the --recheck option to rerun configure.
21471 #
21472 # `ac_cv_env_foo' variables (set or unset) will be overridden when
21473 # loading this file, other *unset* `ac_cv_foo' will be assigned the
21474 # following values.
21475
21476 _ACEOF
21477
21478 # The following way of writing the cache mishandles newlines in values,
21479 # but we know of no workaround that is simple, portable, and efficient.
21480 # So, we kill variables containing newlines.
21481 # Ultrix sh set writes to stderr and can't be redirected directly,
21482 # and sets the high bit in the cache file unless we assign to the vars.
21483 (
21484 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
21485 eval ac_val=\$$ac_var
21486 case $ac_val in #(
21487 *${as_nl}*)
21488 case $ac_var in #(
21489 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
21490 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
21491 esac
21492 case $ac_var in #(
21493 _ | IFS | as_nl) ;; #(
21494 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
21495 *) { eval $ac_var=; unset $ac_var;} ;;
21496 esac ;;
21497 esac
21498 done
21499
21500 (set) 2>&1 |
21501 case $as_nl`(ac_space=' '; set) 2>&1` in #(
21502 *${as_nl}ac_space=\ *)
21503 # `set' does not quote correctly, so add quotes: double-quote
21504 # substitution turns \\\\ into \\, and sed turns \\ into \.
21505 sed -n \
21506 "s/'/'\\\\''/g;
21507 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
21508 ;; #(
21509 *)
21510 # `set' quotes correctly as required by POSIX, so do not add quotes.
21511 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
21512 ;;
21513 esac |
21514 sort
21515 ) |
21516 sed '
21517 /^ac_cv_env_/b end
21518 t clear
21519 :clear
21520 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21521 t end
21522 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21523 :end' >>confcache
21524 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
21525 if test -w "$cache_file"; then
21526 if test "x$cache_file" != "x/dev/null"; then
21527 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
21528 $as_echo "$as_me: updating cache $cache_file" >&6;}
21529 if test ! -f "$cache_file" || test -h "$cache_file"; then
21530 cat confcache >"$cache_file"
21531 else
21532 case $cache_file in #(
21533 */* | ?:*)
21534 mv -f confcache "$cache_file"$$ &&
21535 mv -f "$cache_file"$$ "$cache_file" ;; #(
21536 *)
21537 mv -f confcache "$cache_file" ;;
21538 esac
21539 fi
21540 fi
21541 else
21542 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
21543 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
21544 fi
21545 fi
21546 rm -f confcache
21547
21548 test "x$prefix" = xNONE && prefix=$ac_default_prefix
21549 # Let make expand exec_prefix.
21550 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21551
21552 DEFS=-DHAVE_CONFIG_H
21553
21554 ac_libobjs=
21555 ac_ltlibobjs=
21556 U=
21557 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21558 # 1. Remove the extension, and $U if already installed.
21559 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
21560 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
21561 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
21562 # will be set to the directory where LIBOBJS objects are built.
21563 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
21564 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
21565 done
21566 LIBOBJS=$ac_libobjs
21567
21568 LTLIBOBJS=$ac_ltlibobjs
21569
21570
21571 if test -z "${USE_SYSTEMD_TRUE}" && test -z "${USE_SYSTEMD_FALSE}"; then
21572 as_fn_error $? "conditional \"USE_SYSTEMD\" was never defined.
21573 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21574 fi
21575
21576 : "${CONFIG_STATUS=./config.status}"
21577 ac_write_fail=0
21578 ac_clean_files_save=$ac_clean_files
21579 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
21580 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
21581 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
21582 as_write_fail=0
21583 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
21584 #! $SHELL
21585 # Generated by $as_me.
21586 # Run this file to recreate the current configuration.
21587 # Compiler output produced by configure, useful for debugging
21588 # configure, is in config.log if it exists.
21589
21590 debug=false
21591 ac_cs_recheck=false
21592 ac_cs_silent=false
21593
21594 SHELL=\${CONFIG_SHELL-$SHELL}
21595 export SHELL
21596 _ASEOF
21597 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
21598 ## -------------------- ##
21599 ## M4sh Initialization. ##
21600 ## -------------------- ##
21601
21602 # Be more Bourne compatible
21603 DUALCASE=1; export DUALCASE # for MKS sh
21604 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
21605 emulate sh
21606 NULLCMD=:
21607 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21608 # is contrary to our usage. Disable this feature.
21609 alias -g '${1+"$@"}'='"$@"'
21610 setopt NO_GLOB_SUBST
21611 else
21612 case `(set -o) 2>/dev/null` in #(
21613 *posix*) :
21614 set -o posix ;; #(
21615 *) :
21616 ;;
21617 esac
21618 fi
21619
21620
21621 as_nl='
21622 '
21623 export as_nl
21624 # Printing a long string crashes Solaris 7 /usr/bin/printf.
21625 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
21626 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
21627 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
21628 # Prefer a ksh shell builtin over an external printf program on Solaris,
21629 # but without wasting forks for bash or zsh.
21630 if test -z "$BASH_VERSION$ZSH_VERSION" \
21631 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
21632 as_echo='print -r --'
21633 as_echo_n='print -rn --'
21634 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
21635 as_echo='printf %s\n'
21636 as_echo_n='printf %s'
21637 else
21638 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
21639 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
21640 as_echo_n='/usr/ucb/echo -n'
21641 else
21642 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
21643 as_echo_n_body='eval
21644 arg=$1;
21645 case $arg in #(
21646 *"$as_nl"*)
21647 expr "X$arg" : "X\\(.*\\)$as_nl";
21648 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
21649 esac;
21650 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
21651 '
21652 export as_echo_n_body
21653 as_echo_n='sh -c $as_echo_n_body as_echo'
21654 fi
21655 export as_echo_body
21656 as_echo='sh -c $as_echo_body as_echo'
21657 fi
21658
21659 # The user is always right.
21660 if test "${PATH_SEPARATOR+set}" != set; then
21661 PATH_SEPARATOR=:
21662 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
21663 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
21664 PATH_SEPARATOR=';'
21665 }
21666 fi
21667
21668
21669 # IFS
21670 # We need space, tab and new line, in precisely that order. Quoting is
21671 # there to prevent editors from complaining about space-tab.
21672 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
21673 # splitting by setting IFS to empty value.)
21674 IFS=" "" $as_nl"
21675
21676 # Find who we are. Look in the path if we contain no directory separator.
21677 as_myself=
21678 case $0 in #((
21679 *[\\/]* ) as_myself=$0 ;;
21680 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21681 for as_dir in $PATH
21682 do
21683 IFS=$as_save_IFS
21684 test -z "$as_dir" && as_dir=.
21685 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21686 done
21687 IFS=$as_save_IFS
21688
21689 ;;
21690 esac
21691 # We did not find ourselves, most probably we were run as `sh COMMAND'
21692 # in which case we are not to be found in the path.
21693 if test "x$as_myself" = x; then
21694 as_myself=$0
21695 fi
21696 if test ! -f "$as_myself"; then
21697 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
21698 exit 1
21699 fi
21700
21701 # Unset variables that we do not need and which cause bugs (e.g. in
21702 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
21703 # suppresses any "Segmentation fault" message there. '((' could
21704 # trigger a bug in pdksh 5.2.14.
21705 for as_var in BASH_ENV ENV MAIL MAILPATH
21706 do eval test x\${$as_var+set} = xset \
21707 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
21708 done
21709 PS1='$ '
21710 PS2='> '
21711 PS4='+ '
21712
21713 # NLS nuisances.
21714 LC_ALL=C
21715 export LC_ALL
21716 LANGUAGE=C
21717 export LANGUAGE
21718
21719 # CDPATH.
21720 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
21721
21722
21723 # as_fn_error STATUS ERROR [LINENO LOG_FD]
21724 # ----------------------------------------
21725 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
21726 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
21727 # script with STATUS, using 1 if that was 0.
21728 as_fn_error ()
21729 {
21730 as_status=$1; test $as_status -eq 0 && as_status=1
21731 if test "$4"; then
21732 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
21733 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
21734 fi
21735 $as_echo "$as_me: error: $2" >&2
21736 as_fn_exit $as_status
21737 } # as_fn_error
21738
21739
21740 # as_fn_set_status STATUS
21741 # -----------------------
21742 # Set $? to STATUS, without forking.
21743 as_fn_set_status ()
21744 {
21745 return $1
21746 } # as_fn_set_status
21747
21748 # as_fn_exit STATUS
21749 # -----------------
21750 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
21751 as_fn_exit ()
21752 {
21753 set +e
21754 as_fn_set_status $1
21755 exit $1
21756 } # as_fn_exit
21757
21758 # as_fn_unset VAR
21759 # ---------------
21760 # Portably unset VAR.
21761 as_fn_unset ()
21762 {
21763 { eval $1=; unset $1;}
21764 }
21765 as_unset=as_fn_unset
21766 # as_fn_append VAR VALUE
21767 # ----------------------
21768 # Append the text in VALUE to the end of the definition contained in VAR. Take
21769 # advantage of any shell optimizations that allow amortized linear growth over
21770 # repeated appends, instead of the typical quadratic growth present in naive
21771 # implementations.
21772 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
21773 eval 'as_fn_append ()
21774 {
21775 eval $1+=\$2
21776 }'
21777 else
21778 as_fn_append ()
21779 {
21780 eval $1=\$$1\$2
21781 }
21782 fi # as_fn_append
21783
21784 # as_fn_arith ARG...
21785 # ------------------
21786 # Perform arithmetic evaluation on the ARGs, and store the result in the
21787 # global $as_val. Take advantage of shells that can avoid forks. The arguments
21788 # must be portable across $(()) and expr.
21789 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
21790 eval 'as_fn_arith ()
21791 {
21792 as_val=$(( $* ))
21793 }'
21794 else
21795 as_fn_arith ()
21796 {
21797 as_val=`expr "$@" || test $? -eq 1`
21798 }
21799 fi # as_fn_arith
21800
21801
21802 if expr a : '\(a\)' >/dev/null 2>&1 &&
21803 test "X`expr 00001 : '.*\(...\)'`" = X001; then
21804 as_expr=expr
21805 else
21806 as_expr=false
21807 fi
21808
21809 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
21810 as_basename=basename
21811 else
21812 as_basename=false
21813 fi
21814
21815 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
21816 as_dirname=dirname
21817 else
21818 as_dirname=false
21819 fi
21820
21821 as_me=`$as_basename -- "$0" ||
21822 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21823 X"$0" : 'X\(//\)$' \| \
21824 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
21825 $as_echo X/"$0" |
21826 sed '/^.*\/\([^/][^/]*\)\/*$/{
21827 s//\1/
21828 q
21829 }
21830 /^X\/\(\/\/\)$/{
21831 s//\1/
21832 q
21833 }
21834 /^X\/\(\/\).*/{
21835 s//\1/
21836 q
21837 }
21838 s/.*/./; q'`
21839
21840 # Avoid depending upon Character Ranges.
21841 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21842 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21843 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21844 as_cr_digits='0123456789'
21845 as_cr_alnum=$as_cr_Letters$as_cr_digits
21846
21847 ECHO_C= ECHO_N= ECHO_T=
21848 case `echo -n x` in #(((((
21849 -n*)
21850 case `echo 'xy\c'` in
21851 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
21852 xy) ECHO_C='\c';;
21853 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
21854 ECHO_T=' ';;
21855 esac;;
21856 *)
21857 ECHO_N='-n';;
21858 esac
21859
21860 rm -f conf$$ conf$$.exe conf$$.file
21861 if test -d conf$$.dir; then
21862 rm -f conf$$.dir/conf$$.file
21863 else
21864 rm -f conf$$.dir
21865 mkdir conf$$.dir 2>/dev/null
21866 fi
21867 if (echo >conf$$.file) 2>/dev/null; then
21868 if ln -s conf$$.file conf$$ 2>/dev/null; then
21869 as_ln_s='ln -s'
21870 # ... but there are two gotchas:
21871 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
21872 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
21873 # In both cases, we have to default to `cp -pR'.
21874 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
21875 as_ln_s='cp -pR'
21876 elif ln conf$$.file conf$$ 2>/dev/null; then
21877 as_ln_s=ln
21878 else
21879 as_ln_s='cp -pR'
21880 fi
21881 else
21882 as_ln_s='cp -pR'
21883 fi
21884 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
21885 rmdir conf$$.dir 2>/dev/null
21886
21887
21888 # as_fn_mkdir_p
21889 # -------------
21890 # Create "$as_dir" as a directory, including parents if necessary.
21891 as_fn_mkdir_p ()
21892 {
21893
21894 case $as_dir in #(
21895 -*) as_dir=./$as_dir;;
21896 esac
21897 test -d "$as_dir" || eval $as_mkdir_p || {
21898 as_dirs=
21899 while :; do
21900 case $as_dir in #(
21901 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
21902 *) as_qdir=$as_dir;;
21903 esac
21904 as_dirs="'$as_qdir' $as_dirs"
21905 as_dir=`$as_dirname -- "$as_dir" ||
21906 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21907 X"$as_dir" : 'X\(//\)[^/]' \| \
21908 X"$as_dir" : 'X\(//\)$' \| \
21909 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
21910 $as_echo X"$as_dir" |
21911 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21912 s//\1/
21913 q
21914 }
21915 /^X\(\/\/\)[^/].*/{
21916 s//\1/
21917 q
21918 }
21919 /^X\(\/\/\)$/{
21920 s//\1/
21921 q
21922 }
21923 /^X\(\/\).*/{
21924 s//\1/
21925 q
21926 }
21927 s/.*/./; q'`
21928 test -d "$as_dir" && break
21929 done
21930 test -z "$as_dirs" || eval "mkdir $as_dirs"
21931 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
21932
21933
21934 } # as_fn_mkdir_p
21935 if mkdir -p . 2>/dev/null; then
21936 as_mkdir_p='mkdir -p "$as_dir"'
21937 else
21938 test -d ./-p && rmdir ./-p
21939 as_mkdir_p=false
21940 fi
21941
21942
21943 # as_fn_executable_p FILE
21944 # -----------------------
21945 # Test if FILE is an executable regular file.
21946 as_fn_executable_p ()
21947 {
21948 test -f "$1" && test -x "$1"
21949 } # as_fn_executable_p
21950 as_test_x='test -x'
21951 as_executable_p=as_fn_executable_p
21952
21953 # Sed expression to map a string onto a valid CPP name.
21954 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
21955
21956 # Sed expression to map a string onto a valid variable name.
21957 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
21958
21959
21960 exec 6>&1
21961 ## ----------------------------------- ##
21962 ## Main body of $CONFIG_STATUS script. ##
21963 ## ----------------------------------- ##
21964 _ASEOF
21965 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
21966
21967 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21968 # Save the log message, to keep $0 and so on meaningful, and to
21969 # report actual input values of CONFIG_FILES etc. instead of their
21970 # values after options handling.
21971 ac_log="
21972 This file was extended by unbound $as_me 1.9.6, which was
21973 generated by GNU Autoconf 2.69. Invocation command line was
21974
21975 CONFIG_FILES = $CONFIG_FILES
21976 CONFIG_HEADERS = $CONFIG_HEADERS
21977 CONFIG_LINKS = $CONFIG_LINKS
21978 CONFIG_COMMANDS = $CONFIG_COMMANDS
21979 $ $0 $@
21980
21981 on `(hostname || uname -n) 2>/dev/null | sed 1q`
21982 "
21983
21984 _ACEOF
21985
21986 case $ac_config_files in *"
21987 "*) set x $ac_config_files; shift; ac_config_files=$*;;
21988 esac
21989
21990 case $ac_config_headers in *"
21991 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
21992 esac
21993
21994
21995 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21996 # Files that config.status was made for.
21997 config_files="$ac_config_files"
21998 config_headers="$ac_config_headers"
21999 config_commands="$ac_config_commands"
22000
22001 _ACEOF
22002
22003 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22004 ac_cs_usage="\
22005 \`$as_me' instantiates files and other configuration actions
22006 from templates according to the current configuration. Unless the files
22007 and actions are specified as TAGs, all are instantiated by default.
22008
22009 Usage: $0 [OPTION]... [TAG]...
22010
22011 -h, --help print this help, then exit
22012 -V, --version print version number and configuration settings, then exit
22013 --config print configuration, then exit
22014 -q, --quiet, --silent
22015 do not print progress messages
22016 -d, --debug don't remove temporary files
22017 --recheck update $as_me by reconfiguring in the same conditions
22018 --file=FILE[:TEMPLATE]
22019 instantiate the configuration file FILE
22020 --header=FILE[:TEMPLATE]
22021 instantiate the configuration header FILE
22022
22023 Configuration files:
22024 $config_files
22025
22026 Configuration headers:
22027 $config_headers
22028
22029 Configuration commands:
22030 $config_commands
22031
22032 Report bugs to <unbound-bugs@nlnetlabs.nl or https://github.com/NLnetLabs/unbound/issues>."
22033
22034 _ACEOF
22035 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22036 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
22037 ac_cs_version="\\
22038 unbound config.status 1.9.6
22039 configured by $0, generated by GNU Autoconf 2.69,
22040 with options \\"\$ac_cs_config\\"
22041
22042 Copyright (C) 2012 Free Software Foundation, Inc.
22043 This config.status script is free software; the Free Software Foundation
22044 gives unlimited permission to copy, distribute and modify it."
22045
22046 ac_pwd='$ac_pwd'
22047 srcdir='$srcdir'
22048 AWK='$AWK'
22049 test -n "\$AWK" || AWK=awk
22050 _ACEOF
22051
22052 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22053 # The default lists apply if the user does not specify any file.
22054 ac_need_defaults=:
22055 while test $# != 0
22056 do
22057 case $1 in
22058 --*=?*)
22059 ac_option=`expr "X$1" : 'X\([^=]*\)='`
22060 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
22061 ac_shift=:
22062 ;;
22063 --*=)
22064 ac_option=`expr "X$1" : 'X\([^=]*\)='`
22065 ac_optarg=
22066 ac_shift=:
22067 ;;
22068 *)
22069 ac_option=$1
22070 ac_optarg=$2
22071 ac_shift=shift
22072 ;;
22073 esac
22074
22075 case $ac_option in
22076 # Handling of the options.
22077 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22078 ac_cs_recheck=: ;;
22079 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
22080 $as_echo "$ac_cs_version"; exit ;;
22081 --config | --confi | --conf | --con | --co | --c )
22082 $as_echo "$ac_cs_config"; exit ;;
22083 --debug | --debu | --deb | --de | --d | -d )
22084 debug=: ;;
22085 --file | --fil | --fi | --f )
22086 $ac_shift
22087 case $ac_optarg in
22088 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22089 '') as_fn_error $? "missing file argument" ;;
22090 esac
22091 as_fn_append CONFIG_FILES " '$ac_optarg'"
22092 ac_need_defaults=false;;
22093 --header | --heade | --head | --hea )
22094 $ac_shift
22095 case $ac_optarg in
22096 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22097 esac
22098 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
22099 ac_need_defaults=false;;
22100 --he | --h)
22101 # Conflict between --help and --header
22102 as_fn_error $? "ambiguous option: \`$1'
22103 Try \`$0 --help' for more information.";;
22104 --help | --hel | -h )
22105 $as_echo "$ac_cs_usage"; exit ;;
22106 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22107 | -silent | --silent | --silen | --sile | --sil | --si | --s)
22108 ac_cs_silent=: ;;
22109
22110 # This is an error.
22111 -*) as_fn_error $? "unrecognized option: \`$1'
22112 Try \`$0 --help' for more information." ;;
22113
22114 *) as_fn_append ac_config_targets " $1"
22115 ac_need_defaults=false ;;
22116
22117 esac
22118 shift
22119 done
22120
22121 ac_configure_extra_args=
22122
22123 if $ac_cs_silent; then
22124 exec 6>/dev/null
22125 ac_configure_extra_args="$ac_configure_extra_args --silent"
22126 fi
22127
22128 _ACEOF
22129 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22130 if \$ac_cs_recheck; then
22131 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22132 shift
22133 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
22134 CONFIG_SHELL='$SHELL'
22135 export CONFIG_SHELL
22136 exec "\$@"
22137 fi
22138
22139 _ACEOF
22140 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22141 exec 5>>config.log
22142 {
22143 echo
22144 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22145 ## Running $as_me. ##
22146 _ASBOX
22147 $as_echo "$ac_log"
22148 } >&5
22149
22150 _ACEOF
22151 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22152 #
22153 # INIT-COMMANDS
22154 #
22155
22156
22157 # The HP-UX ksh and POSIX shell print the target directory to stdout
22158 # if CDPATH is set.
22159 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22160
22161 sed_quote_subst='$sed_quote_subst'
22162 double_quote_subst='$double_quote_subst'
22163 delay_variable_subst='$delay_variable_subst'
22164 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
22165 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
22166 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
22167 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
22168 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
22169 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
22170 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
22171 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
22172 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
22173 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
22174 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
22175 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
22176 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
22177 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
22178 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
22179 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
22180 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
22181 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
22182 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
22183 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
22184 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
22185 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
22186 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
22187 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
22188 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
22189 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
22190 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
22191 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
22192 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
22193 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
22194 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
22195 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
22196 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
22197 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
22198 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
22199 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
22200 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
22201 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
22202 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
22203 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
22204 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
22205 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
22206 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
22207 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
22208 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
22209 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
22210 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22211 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22212 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
22213 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
22214 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
22215 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
22216 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
22217 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
22218 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
22219 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
22220 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
22221 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
22222 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"`'
22223 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
22224 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
22225 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
22226 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
22227 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
22228 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
22229 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
22230 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
22231 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
22232 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
22233 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
22234 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
22235 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
22236 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
22237 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
22238 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
22239 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
22240 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
22241 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
22242 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
22243 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22244 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
22245 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
22246 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
22247 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
22248 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
22249 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
22250 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
22251 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
22252 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22253 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
22254 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
22255 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
22256 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
22257 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
22258 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
22259 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
22260 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
22261 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
22262 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
22263 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
22264 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
22265 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
22266 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
22267 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
22268 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
22269 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
22270 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
22271 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
22272 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
22273 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
22274 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
22275 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
22276 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
22277 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
22278 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
22279 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
22280 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
22281 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
22282 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
22283 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
22284 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
22285 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
22286 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
22287 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
22288 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
22289 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
22290 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
22291 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
22292 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
22293 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
22294 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
22295 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
22296 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
22297 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
22298 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
22299
22300 LTCC='$LTCC'
22301 LTCFLAGS='$LTCFLAGS'
22302 compiler='$compiler_DEFAULT'
22303
22304 # A function that is used when there is no print builtin or printf.
22305 func_fallback_echo ()
22306 {
22307 eval 'cat <<_LTECHO_EOF
22308 \$1
22309 _LTECHO_EOF'
22310 }
22311
22312 # Quote evaled strings.
22313 for var in SHELL \
22314 ECHO \
22315 PATH_SEPARATOR \
22316 SED \
22317 GREP \
22318 EGREP \
22319 FGREP \
22320 LD \
22321 NM \
22322 LN_S \
22323 lt_SP2NL \
22324 lt_NL2SP \
22325 reload_flag \
22326 OBJDUMP \
22327 deplibs_check_method \
22328 file_magic_cmd \
22329 file_magic_glob \
22330 want_nocaseglob \
22331 DLLTOOL \
22332 sharedlib_from_linklib_cmd \
22333 AR \
22334 AR_FLAGS \
22335 archiver_list_spec \
22336 STRIP \
22337 RANLIB \
22338 CC \
22339 CFLAGS \
22340 compiler \
22341 lt_cv_sys_global_symbol_pipe \
22342 lt_cv_sys_global_symbol_to_cdecl \
22343 lt_cv_sys_global_symbol_to_import \
22344 lt_cv_sys_global_symbol_to_c_name_address \
22345 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
22346 lt_cv_nm_interface \
22347 nm_file_list_spec \
22348 lt_cv_truncate_bin \
22349 lt_prog_compiler_no_builtin_flag \
22350 lt_prog_compiler_pic \
22351 lt_prog_compiler_wl \
22352 lt_prog_compiler_static \
22353 lt_cv_prog_compiler_c_o \
22354 need_locks \
22355 MANIFEST_TOOL \
22356 DSYMUTIL \
22357 NMEDIT \
22358 LIPO \
22359 OTOOL \
22360 OTOOL64 \
22361 shrext_cmds \
22362 export_dynamic_flag_spec \
22363 whole_archive_flag_spec \
22364 compiler_needs_object \
22365 with_gnu_ld \
22366 allow_undefined_flag \
22367 no_undefined_flag \
22368 hardcode_libdir_flag_spec \
22369 hardcode_libdir_separator \
22370 exclude_expsyms \
22371 include_expsyms \
22372 file_list_spec \
22373 variables_saved_for_relink \
22374 libname_spec \
22375 library_names_spec \
22376 soname_spec \
22377 install_override_mode \
22378 finish_eval \
22379 old_striplib \
22380 striplib; do
22381 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
22382 *[\\\\\\\`\\"\\\$]*)
22383 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
22384 ;;
22385 *)
22386 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
22387 ;;
22388 esac
22389 done
22390
22391 # Double-quote double-evaled strings.
22392 for var in reload_cmds \
22393 old_postinstall_cmds \
22394 old_postuninstall_cmds \
22395 old_archive_cmds \
22396 extract_expsyms_cmds \
22397 old_archive_from_new_cmds \
22398 old_archive_from_expsyms_cmds \
22399 archive_cmds \
22400 archive_expsym_cmds \
22401 module_cmds \
22402 module_expsym_cmds \
22403 export_symbols_cmds \
22404 prelink_cmds \
22405 postlink_cmds \
22406 postinstall_cmds \
22407 postuninstall_cmds \
22408 finish_cmds \
22409 sys_lib_search_path_spec \
22410 configure_time_dlsearch_path \
22411 configure_time_lt_sys_library_path; do
22412 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
22413 *[\\\\\\\`\\"\\\$]*)
22414 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
22415 ;;
22416 *)
22417 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
22418 ;;
22419 esac
22420 done
22421
22422 ac_aux_dir='$ac_aux_dir'
22423
22424 # See if we are running on zsh, and set the options that allow our
22425 # commands through without removal of \ escapes INIT.
22426 if test -n "\${ZSH_VERSION+set}"; then
22427 setopt NO_GLOB_SUBST
22428 fi
22429
22430
22431 PACKAGE='$PACKAGE'
22432 VERSION='$VERSION'
22433 RM='$RM'
22434 ofile='$ofile'
22435
22436
22437
22438
22439 _ACEOF
22440
22441 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22442
22443 # Handling of arguments.
22444 for ac_config_target in $ac_config_targets
22445 do
22446 case $ac_config_target in
22447 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
22448 "disable-rpath") CONFIG_COMMANDS="$CONFIG_COMMANDS disable-rpath" ;;
22449 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
22450 "doc/example.conf") CONFIG_FILES="$CONFIG_FILES doc/example.conf" ;;
22451 "doc/libunbound.3") CONFIG_FILES="$CONFIG_FILES doc/libunbound.3" ;;
22452 "doc/unbound.8") CONFIG_FILES="$CONFIG_FILES doc/unbound.8" ;;
22453 "doc/unbound-anchor.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-anchor.8" ;;
22454 "doc/unbound-checkconf.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-checkconf.8" ;;
22455 "doc/unbound.conf.5") CONFIG_FILES="$CONFIG_FILES doc/unbound.conf.5" ;;
22456 "doc/unbound-control.8") CONFIG_FILES="$CONFIG_FILES doc/unbound-control.8" ;;
22457 "doc/unbound-host.1") CONFIG_FILES="$CONFIG_FILES doc/unbound-host.1" ;;
22458 "smallapp/unbound-control-setup.sh") CONFIG_FILES="$CONFIG_FILES smallapp/unbound-control-setup.sh" ;;
22459 "dnstap/dnstap_config.h") CONFIG_FILES="$CONFIG_FILES dnstap/dnstap_config.h" ;;
22460 "dnscrypt/dnscrypt_config.h") CONFIG_FILES="$CONFIG_FILES dnscrypt/dnscrypt_config.h" ;;
22461 "contrib/libunbound.pc") CONFIG_FILES="$CONFIG_FILES contrib/libunbound.pc" ;;
22462 "contrib/unbound.socket") CONFIG_FILES="$CONFIG_FILES contrib/unbound.socket" ;;
22463 "contrib/unbound.service") CONFIG_FILES="$CONFIG_FILES contrib/unbound.service" ;;
22464 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
22465
22466 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
22467 esac
22468 done
22469
22470
22471 # If the user did not use the arguments to specify the items to instantiate,
22472 # then the envvar interface is used. Set only those that are not.
22473 # We use the long form for the default assignment because of an extremely
22474 # bizarre bug on SunOS 4.1.3.
22475 if $ac_need_defaults; then
22476 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22477 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22478 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
22479 fi
22480
22481 # Have a temporary directory for convenience. Make it in the build tree
22482 # simply because there is no reason against having it here, and in addition,
22483 # creating and moving files from /tmp can sometimes cause problems.
22484 # Hook for its removal unless debugging.
22485 # Note that there is a small window in which the directory will not be cleaned:
22486 # after its creation but before its name has been assigned to `$tmp'.
22487 $debug ||
22488 {
22489 tmp= ac_tmp=
22490 trap 'exit_status=$?
22491 : "${ac_tmp:=$tmp}"
22492 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
22493 ' 0
22494 trap 'as_fn_exit 1' 1 2 13 15
22495 }
22496 # Create a (secure) tmp directory for tmp files.
22497
22498 {
22499 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
22500 test -d "$tmp"
22501 } ||
22502 {
22503 tmp=./conf$$-$RANDOM
22504 (umask 077 && mkdir "$tmp")
22505 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
22506 ac_tmp=$tmp
22507
22508 # Set up the scripts for CONFIG_FILES section.
22509 # No need to generate them if there are no CONFIG_FILES.
22510 # This happens for instance with `./config.status config.h'.
22511 if test -n "$CONFIG_FILES"; then
22512
22513
22514 ac_cr=`echo X | tr X '\015'`
22515 # On cygwin, bash can eat \r inside `` if the user requested igncr.
22516 # But we know of no other shell where ac_cr would be empty at this
22517 # point, so we can use a bashism as a fallback.
22518 if test "x$ac_cr" = x; then
22519 eval ac_cr=\$\'\\r\'
22520 fi
22521 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
22522 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
22523 ac_cs_awk_cr='\\r'
22524 else
22525 ac_cs_awk_cr=$ac_cr
22526 fi
22527
22528 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
22529 _ACEOF
22530
22531
22532 {
22533 echo "cat >conf$$subs.awk <<_ACEOF" &&
22534 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
22535 echo "_ACEOF"
22536 } >conf$$subs.sh ||
22537 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
22538 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
22539 ac_delim='%!_!# '
22540 for ac_last_try in false false false false false :; do
22541 . ./conf$$subs.sh ||
22542 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
22543
22544 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
22545 if test $ac_delim_n = $ac_delim_num; then
22546 break
22547 elif $ac_last_try; then
22548 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
22549 else
22550 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
22551 fi
22552 done
22553 rm -f conf$$subs.sh
22554
22555 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22556 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
22557 _ACEOF
22558 sed -n '
22559 h
22560 s/^/S["/; s/!.*/"]=/
22561 p
22562 g
22563 s/^[^!]*!//
22564 :repl
22565 t repl
22566 s/'"$ac_delim"'$//
22567 t delim
22568 :nl
22569 h
22570 s/\(.\{148\}\)..*/\1/
22571 t more1
22572 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
22573 p
22574 n
22575 b repl
22576 :more1
22577 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
22578 p
22579 g
22580 s/.\{148\}//
22581 t nl
22582 :delim
22583 h
22584 s/\(.\{148\}\)..*/\1/
22585 t more2
22586 s/["\\]/\\&/g; s/^/"/; s/$/"/
22587 p
22588 b
22589 :more2
22590 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
22591 p
22592 g
22593 s/.\{148\}//
22594 t delim
22595 ' <conf$$subs.awk | sed '
22596 /^[^""]/{
22597 N
22598 s/\n//
22599 }
22600 ' >>$CONFIG_STATUS || ac_write_fail=1
22601 rm -f conf$$subs.awk
22602 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22603 _ACAWK
22604 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
22605 for (key in S) S_is_set[key] = 1
22606 FS = ""
22607
22608 }
22609 {
22610 line = $ 0
22611 nfields = split(line, field, "@")
22612 substed = 0
22613 len = length(field[1])
22614 for (i = 2; i < nfields; i++) {
22615 key = field[i]
22616 keylen = length(key)
22617 if (S_is_set[key]) {
22618 value = S[key]
22619 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
22620 len += length(value) + length(field[++i])
22621 substed = 1
22622 } else
22623 len += 1 + keylen
22624 }
22625
22626 print line
22627 }
22628
22629 _ACAWK
22630 _ACEOF
22631 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22632 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
22633 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
22634 else
22635 cat
22636 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
22637 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
22638 _ACEOF
22639
22640 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
22641 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
22642 # trailing colons and then remove the whole line if VPATH becomes empty
22643 # (actually we leave an empty line to preserve line numbers).
22644 if test "x$srcdir" = x.; then
22645 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
22646 h
22647 s///
22648 s/^/:/
22649 s/[ ]*$/:/
22650 s/:\$(srcdir):/:/g
22651 s/:\${srcdir}:/:/g
22652 s/:@srcdir@:/:/g
22653 s/^:*//
22654 s/:*$//
22655 x
22656 s/\(=[ ]*\).*/\1/
22657 G
22658 s/\n//
22659 s/^[^=]*=[ ]*$//
22660 }'
22661 fi
22662
22663 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22664 fi # test -n "$CONFIG_FILES"
22665
22666 # Set up the scripts for CONFIG_HEADERS section.
22667 # No need to generate them if there are no CONFIG_HEADERS.
22668 # This happens for instance with `./config.status Makefile'.
22669 if test -n "$CONFIG_HEADERS"; then
22670 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
22671 BEGIN {
22672 _ACEOF
22673
22674 # Transform confdefs.h into an awk script `defines.awk', embedded as
22675 # here-document in config.status, that substitutes the proper values into
22676 # config.h.in to produce config.h.
22677
22678 # Create a delimiter string that does not exist in confdefs.h, to ease
22679 # handling of long lines.
22680 ac_delim='%!_!# '
22681 for ac_last_try in false false :; do
22682 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
22683 if test -z "$ac_tt"; then
22684 break
22685 elif $ac_last_try; then
22686 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
22687 else
22688 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
22689 fi
22690 done
22691
22692 # For the awk script, D is an array of macro values keyed by name,
22693 # likewise P contains macro parameters if any. Preserve backslash
22694 # newline sequences.
22695
22696 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
22697 sed -n '
22698 s/.\{148\}/&'"$ac_delim"'/g
22699 t rset
22700 :rset
22701 s/^[ ]*#[ ]*define[ ][ ]*/ /
22702 t def
22703 d
22704 :def
22705 s/\\$//
22706 t bsnl
22707 s/["\\]/\\&/g
22708 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
22709 D["\1"]=" \3"/p
22710 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
22711 d
22712 :bsnl
22713 s/["\\]/\\&/g
22714 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
22715 D["\1"]=" \3\\\\\\n"\\/p
22716 t cont
22717 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
22718 t cont
22719 d
22720 :cont
22721 n
22722 s/.\{148\}/&'"$ac_delim"'/g
22723 t clear
22724 :clear
22725 s/\\$//
22726 t bsnlc
22727 s/["\\]/\\&/g; s/^/"/; s/$/"/p
22728 d
22729 :bsnlc
22730 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
22731 b cont
22732 ' <confdefs.h | sed '
22733 s/'"$ac_delim"'/"\\\
22734 "/g' >>$CONFIG_STATUS || ac_write_fail=1
22735
22736 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22737 for (key in D) D_is_set[key] = 1
22738 FS = ""
22739 }
22740 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
22741 line = \$ 0
22742 split(line, arg, " ")
22743 if (arg[1] == "#") {
22744 defundef = arg[2]
22745 mac1 = arg[3]
22746 } else {
22747 defundef = substr(arg[1], 2)
22748 mac1 = arg[2]
22749 }
22750 split(mac1, mac2, "(") #)
22751 macro = mac2[1]
22752 prefix = substr(line, 1, index(line, defundef) - 1)
22753 if (D_is_set[macro]) {
22754 # Preserve the white space surrounding the "#".
22755 print prefix "define", macro P[macro] D[macro]
22756 next
22757 } else {
22758 # Replace #undef with comments. This is necessary, for example,
22759 # in the case of _POSIX_SOURCE, which is predefined and required
22760 # on some systems where configure will not decide to define it.
22761 if (defundef == "undef") {
22762 print "/*", prefix defundef, macro, "*/"
22763 next
22764 }
22765 }
22766 }
22767 { print }
22768 _ACAWK
22769 _ACEOF
22770 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22771 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
22772 fi # test -n "$CONFIG_HEADERS"
22773
22774
22775 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
22776 shift
22777 for ac_tag
22778 do
22779 case $ac_tag in
22780 :[FHLC]) ac_mode=$ac_tag; continue;;
22781 esac
22782 case $ac_mode$ac_tag in
22783 :[FHL]*:*);;
22784 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
22785 :[FH]-) ac_tag=-:-;;
22786 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
22787 esac
22788 ac_save_IFS=$IFS
22789 IFS=:
22790 set x $ac_tag
22791 IFS=$ac_save_IFS
22792 shift
22793 ac_file=$1
22794 shift
22795
22796 case $ac_mode in
22797 :L) ac_source=$1;;
22798 :[FH])
22799 ac_file_inputs=
22800 for ac_f
22801 do
22802 case $ac_f in
22803 -) ac_f="$ac_tmp/stdin";;
22804 *) # Look for the file first in the build tree, then in the source tree
22805 # (if the path is not absolute). The absolute path cannot be DOS-style,
22806 # because $ac_f cannot contain `:'.
22807 test -f "$ac_f" ||
22808 case $ac_f in
22809 [\\/$]*) false;;
22810 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
22811 esac ||
22812 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
22813 esac
22814 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
22815 as_fn_append ac_file_inputs " '$ac_f'"
22816 done
22817
22818 # Let's still pretend it is `configure' which instantiates (i.e., don't
22819 # use $as_me), people would be surprised to read:
22820 # /* config.h. Generated by config.status. */
22821 configure_input='Generated from '`
22822 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
22823 `' by configure.'
22824 if test x"$ac_file" != x-; then
22825 configure_input="$ac_file. $configure_input"
22826 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
22827 $as_echo "$as_me: creating $ac_file" >&6;}
22828 fi
22829 # Neutralize special characters interpreted by sed in replacement strings.
22830 case $configure_input in #(
22831 *\&* | *\|* | *\\* )
22832 ac_sed_conf_input=`$as_echo "$configure_input" |
22833 sed 's/[\\\\&|]/\\\\&/g'`;; #(
22834 *) ac_sed_conf_input=$configure_input;;
22835 esac
22836
22837 case $ac_tag in
22838 *:-:* | *:-) cat >"$ac_tmp/stdin" \
22839 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
22840 esac
22841 ;;
22842 esac
22843
22844 ac_dir=`$as_dirname -- "$ac_file" ||
22845 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22846 X"$ac_file" : 'X\(//\)[^/]' \| \
22847 X"$ac_file" : 'X\(//\)$' \| \
22848 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
22849 $as_echo X"$ac_file" |
22850 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22851 s//\1/
22852 q
22853 }
22854 /^X\(\/\/\)[^/].*/{
22855 s//\1/
22856 q
22857 }
22858 /^X\(\/\/\)$/{
22859 s//\1/
22860 q
22861 }
22862 /^X\(\/\).*/{
22863 s//\1/
22864 q
22865 }
22866 s/.*/./; q'`
22867 as_dir="$ac_dir"; as_fn_mkdir_p
22868 ac_builddir=.
22869
22870 case "$ac_dir" in
22871 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
22872 *)
22873 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
22874 # A ".." for each directory in $ac_dir_suffix.
22875 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
22876 case $ac_top_builddir_sub in
22877 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
22878 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
22879 esac ;;
22880 esac
22881 ac_abs_top_builddir=$ac_pwd
22882 ac_abs_builddir=$ac_pwd$ac_dir_suffix
22883 # for backward compatibility:
22884 ac_top_builddir=$ac_top_build_prefix
22885
22886 case $srcdir in
22887 .) # We are building in place.
22888 ac_srcdir=.
22889 ac_top_srcdir=$ac_top_builddir_sub
22890 ac_abs_top_srcdir=$ac_pwd ;;
22891 [\\/]* | ?:[\\/]* ) # Absolute name.
22892 ac_srcdir=$srcdir$ac_dir_suffix;
22893 ac_top_srcdir=$srcdir
22894 ac_abs_top_srcdir=$srcdir ;;
22895 *) # Relative name.
22896 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
22897 ac_top_srcdir=$ac_top_build_prefix$srcdir
22898 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
22899 esac
22900 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
22901
22902
22903 case $ac_mode in
22904 :F)
22905 #
22906 # CONFIG_FILE
22907 #
22908
22909 _ACEOF
22910
22911 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22912 # If the template does not know about datarootdir, expand it.
22913 # FIXME: This hack should be removed a few years after 2.60.
22914 ac_datarootdir_hack=; ac_datarootdir_seen=
22915 ac_sed_dataroot='
22916 /datarootdir/ {
22917 p
22918 q
22919 }
22920 /@datadir@/p
22921 /@docdir@/p
22922 /@infodir@/p
22923 /@localedir@/p
22924 /@mandir@/p'
22925 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
22926 *datarootdir*) ac_datarootdir_seen=yes;;
22927 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
22928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
22929 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
22930 _ACEOF
22931 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22932 ac_datarootdir_hack='
22933 s&@datadir@&$datadir&g
22934 s&@docdir@&$docdir&g
22935 s&@infodir@&$infodir&g
22936 s&@localedir@&$localedir&g
22937 s&@mandir@&$mandir&g
22938 s&\\\${datarootdir}&$datarootdir&g' ;;
22939 esac
22940 _ACEOF
22941
22942 # Neutralize VPATH when `$srcdir' = `.'.
22943 # Shell code in configure.ac might set extrasub.
22944 # FIXME: do we really want to maintain this feature?
22945 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22946 ac_sed_extra="$ac_vpsub
22947 $extrasub
22948 _ACEOF
22949 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22950 :t
22951 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22952 s|@configure_input@|$ac_sed_conf_input|;t t
22953 s&@top_builddir@&$ac_top_builddir_sub&;t t
22954 s&@top_build_prefix@&$ac_top_build_prefix&;t t
22955 s&@srcdir@&$ac_srcdir&;t t
22956 s&@abs_srcdir@&$ac_abs_srcdir&;t t
22957 s&@top_srcdir@&$ac_top_srcdir&;t t
22958 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
22959 s&@builddir@&$ac_builddir&;t t
22960 s&@abs_builddir@&$ac_abs_builddir&;t t
22961 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
22962 $ac_datarootdir_hack
22963 "
22964 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
22965 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22966
22967 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
22968 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
22969 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
22970 "$ac_tmp/out"`; test -z "$ac_out"; } &&
22971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22972 which seems to be undefined. Please make sure it is defined" >&5
22973 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22974 which seems to be undefined. Please make sure it is defined" >&2;}
22975
22976 rm -f "$ac_tmp/stdin"
22977 case $ac_file in
22978 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
22979 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
22980 esac \
22981 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22982 ;;
22983 :H)
22984 #
22985 # CONFIG_HEADER
22986 #
22987 if test x"$ac_file" != x-; then
22988 {
22989 $as_echo "/* $configure_input */" \
22990 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
22991 } >"$ac_tmp/config.h" \
22992 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
22993 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
22994 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
22995 $as_echo "$as_me: $ac_file is unchanged" >&6;}
22996 else
22997 rm -f "$ac_file"
22998 mv "$ac_tmp/config.h" "$ac_file" \
22999 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
23000 fi
23001 else
23002 $as_echo "/* $configure_input */" \
23003 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
23004 || as_fn_error $? "could not create -" "$LINENO" 5
23005 fi
23006 ;;
23007
23008 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
23009 $as_echo "$as_me: executing $ac_file commands" >&6;}
23010 ;;
23011 esac
23012
23013
23014 case $ac_file$ac_mode in
23015 "libtool":C)
23016
23017 # See if we are running on zsh, and set the options that allow our
23018 # commands through without removal of \ escapes.
23019 if test -n "${ZSH_VERSION+set}"; then
23020 setopt NO_GLOB_SUBST
23021 fi
23022
23023 cfgfile=${ofile}T
23024 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
23025 $RM "$cfgfile"
23026
23027 cat <<_LT_EOF >> "$cfgfile"
23028 #! $SHELL
23029 # Generated automatically by $as_me ($PACKAGE) $VERSION
23030 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
23031
23032 # Provide generalized library-building support services.
23033 # Written by Gordon Matzigkeit, 1996
23034
23035 # Copyright (C) 2014 Free Software Foundation, Inc.
23036 # This is free software; see the source for copying conditions. There is NO
23037 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
23038
23039 # GNU Libtool is free software; you can redistribute it and/or modify
23040 # it under the terms of the GNU General Public License as published by
23041 # the Free Software Foundation; either version 2 of of the License, or
23042 # (at your option) any later version.
23043 #
23044 # As a special exception to the GNU General Public License, if you
23045 # distribute this file as part of a program or library that is built
23046 # using GNU Libtool, you may include this file under the same
23047 # distribution terms that you use for the rest of that program.
23048 #
23049 # GNU Libtool is distributed in the hope that it will be useful, but
23050 # WITHOUT ANY WARRANTY; without even the implied warranty of
23051 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23052 # GNU General Public License for more details.
23053 #
23054 # You should have received a copy of the GNU General Public License
23055 # along with this program. If not, see <http://www.gnu.org/licenses/>.
23056
23057
23058 # The names of the tagged configurations supported by this script.
23059 available_tags=''
23060
23061 # Configured defaults for sys_lib_dlsearch_path munging.
23062 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
23063
23064 # ### BEGIN LIBTOOL CONFIG
23065
23066 # Which release of libtool.m4 was used?
23067 macro_version=$macro_version
23068 macro_revision=$macro_revision
23069
23070 # Whether or not to build shared libraries.
23071 build_libtool_libs=$enable_shared
23072
23073 # Whether or not to build static libraries.
23074 build_old_libs=$enable_static
23075
23076 # What type of objects to build.
23077 pic_mode=$pic_mode
23078
23079 # Whether or not to optimize for fast installation.
23080 fast_install=$enable_fast_install
23081
23082 # Shared archive member basename,for filename based shared library versioning on AIX.
23083 shared_archive_member_spec=$shared_archive_member_spec
23084
23085 # Shell to use when invoking shell scripts.
23086 SHELL=$lt_SHELL
23087
23088 # An echo program that protects backslashes.
23089 ECHO=$lt_ECHO
23090
23091 # The PATH separator for the build system.
23092 PATH_SEPARATOR=$lt_PATH_SEPARATOR
23093
23094 # The host system.
23095 host_alias=$host_alias
23096 host=$host
23097 host_os=$host_os
23098
23099 # The build system.
23100 build_alias=$build_alias
23101 build=$build
23102 build_os=$build_os
23103
23104 # A sed program that does not truncate output.
23105 SED=$lt_SED
23106
23107 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
23108 Xsed="\$SED -e 1s/^X//"
23109
23110 # A grep program that handles long lines.
23111 GREP=$lt_GREP
23112
23113 # An ERE matcher.
23114 EGREP=$lt_EGREP
23115
23116 # A literal string matcher.
23117 FGREP=$lt_FGREP
23118
23119 # A BSD- or MS-compatible name lister.
23120 NM=$lt_NM
23121
23122 # Whether we need soft or hard links.
23123 LN_S=$lt_LN_S
23124
23125 # What is the maximum length of a command?
23126 max_cmd_len=$max_cmd_len
23127
23128 # Object file suffix (normally "o").
23129 objext=$ac_objext
23130
23131 # Executable file suffix (normally "").
23132 exeext=$exeext
23133
23134 # whether the shell understands "unset".
23135 lt_unset=$lt_unset
23136
23137 # turn spaces into newlines.
23138 SP2NL=$lt_lt_SP2NL
23139
23140 # turn newlines into spaces.
23141 NL2SP=$lt_lt_NL2SP
23142
23143 # convert \$build file names to \$host format.
23144 to_host_file_cmd=$lt_cv_to_host_file_cmd
23145
23146 # convert \$build files to toolchain format.
23147 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
23148
23149 # An object symbol dumper.
23150 OBJDUMP=$lt_OBJDUMP
23151
23152 # Method to check whether dependent libraries are shared objects.
23153 deplibs_check_method=$lt_deplibs_check_method
23154
23155 # Command to use when deplibs_check_method = "file_magic".
23156 file_magic_cmd=$lt_file_magic_cmd
23157
23158 # How to find potential files when deplibs_check_method = "file_magic".
23159 file_magic_glob=$lt_file_magic_glob
23160
23161 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
23162 want_nocaseglob=$lt_want_nocaseglob
23163
23164 # DLL creation program.
23165 DLLTOOL=$lt_DLLTOOL
23166
23167 # Command to associate shared and link libraries.
23168 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
23169
23170 # The archiver.
23171 AR=$lt_AR
23172
23173 # Flags to create an archive.
23174 AR_FLAGS=$lt_AR_FLAGS
23175
23176 # How to feed a file listing to the archiver.
23177 archiver_list_spec=$lt_archiver_list_spec
23178
23179 # A symbol stripping program.
23180 STRIP=$lt_STRIP
23181
23182 # Commands used to install an old-style archive.
23183 RANLIB=$lt_RANLIB
23184 old_postinstall_cmds=$lt_old_postinstall_cmds
23185 old_postuninstall_cmds=$lt_old_postuninstall_cmds
23186
23187 # Whether to use a lock for old archive extraction.
23188 lock_old_archive_extraction=$lock_old_archive_extraction
23189
23190 # A C compiler.
23191 LTCC=$lt_CC
23192
23193 # LTCC compiler flags.
23194 LTCFLAGS=$lt_CFLAGS
23195
23196 # Take the output of nm and produce a listing of raw symbols and C names.
23197 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
23198
23199 # Transform the output of nm in a proper C declaration.
23200 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
23201
23202 # Transform the output of nm into a list of symbols to manually relocate.
23203 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
23204
23205 # Transform the output of nm in a C name address pair.
23206 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
23207
23208 # Transform the output of nm in a C name address pair when lib prefix is needed.
23209 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
23210
23211 # The name lister interface.
23212 nm_interface=$lt_lt_cv_nm_interface
23213
23214 # Specify filename containing input files for \$NM.
23215 nm_file_list_spec=$lt_nm_file_list_spec
23216
23217 # The root where to search for dependent libraries,and where our libraries should be installed.
23218 lt_sysroot=$lt_sysroot
23219
23220 # Command to truncate a binary pipe.
23221 lt_truncate_bin=$lt_lt_cv_truncate_bin
23222
23223 # The name of the directory that contains temporary libtool files.
23224 objdir=$objdir
23225
23226 # Used to examine libraries when file_magic_cmd begins with "file".
23227 MAGIC_CMD=$MAGIC_CMD
23228
23229 # Must we lock files when doing compilation?
23230 need_locks=$lt_need_locks
23231
23232 # Manifest tool.
23233 MANIFEST_TOOL=$lt_MANIFEST_TOOL
23234
23235 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
23236 DSYMUTIL=$lt_DSYMUTIL
23237
23238 # Tool to change global to local symbols on Mac OS X.
23239 NMEDIT=$lt_NMEDIT
23240
23241 # Tool to manipulate fat objects and archives on Mac OS X.
23242 LIPO=$lt_LIPO
23243
23244 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
23245 OTOOL=$lt_OTOOL
23246
23247 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
23248 OTOOL64=$lt_OTOOL64
23249
23250 # Old archive suffix (normally "a").
23251 libext=$libext
23252
23253 # Shared library suffix (normally ".so").
23254 shrext_cmds=$lt_shrext_cmds
23255
23256 # The commands to extract the exported symbol list from a shared archive.
23257 extract_expsyms_cmds=$lt_extract_expsyms_cmds
23258
23259 # Variables whose values should be saved in libtool wrapper scripts and
23260 # restored at link time.
23261 variables_saved_for_relink=$lt_variables_saved_for_relink
23262
23263 # Do we need the "lib" prefix for modules?
23264 need_lib_prefix=$need_lib_prefix
23265
23266 # Do we need a version for libraries?
23267 need_version=$need_version
23268
23269 # Library versioning type.
23270 version_type=$version_type
23271
23272 # Shared library runtime path variable.
23273 runpath_var=$runpath_var
23274
23275 # Shared library path variable.
23276 shlibpath_var=$shlibpath_var
23277
23278 # Is shlibpath searched before the hard-coded library search path?
23279 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
23280
23281 # Format of library name prefix.
23282 libname_spec=$lt_libname_spec
23283
23284 # List of archive names. First name is the real one, the rest are links.
23285 # The last name is the one that the linker finds with -lNAME
23286 library_names_spec=$lt_library_names_spec
23287
23288 # The coded name of the library, if different from the real name.
23289 soname_spec=$lt_soname_spec
23290
23291 # Permission mode override for installation of shared libraries.
23292 install_override_mode=$lt_install_override_mode
23293
23294 # Command to use after installation of a shared archive.
23295 postinstall_cmds=$lt_postinstall_cmds
23296
23297 # Command to use after uninstallation of a shared archive.
23298 postuninstall_cmds=$lt_postuninstall_cmds
23299
23300 # Commands used to finish a libtool library installation in a directory.
23301 finish_cmds=$lt_finish_cmds
23302
23303 # As "finish_cmds", except a single script fragment to be evaled but
23304 # not shown.
23305 finish_eval=$lt_finish_eval
23306
23307 # Whether we should hardcode library paths into libraries.
23308 hardcode_into_libs=$hardcode_into_libs
23309
23310 # Compile-time system search path for libraries.
23311 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
23312
23313 # Detected run-time system search path for libraries.
23314 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
23315
23316 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
23317 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
23318
23319 # Whether dlopen is supported.
23320 dlopen_support=$enable_dlopen
23321
23322 # Whether dlopen of programs is supported.
23323 dlopen_self=$enable_dlopen_self
23324
23325 # Whether dlopen of statically linked programs is supported.
23326 dlopen_self_static=$enable_dlopen_self_static
23327
23328 # Commands to strip libraries.
23329 old_striplib=$lt_old_striplib
23330 striplib=$lt_striplib
23331
23332
23333 # The linker used to build libraries.
23334 LD=$lt_LD
23335
23336 # How to create reloadable object files.
23337 reload_flag=$lt_reload_flag
23338 reload_cmds=$lt_reload_cmds
23339
23340 # Commands used to build an old-style archive.
23341 old_archive_cmds=$lt_old_archive_cmds
23342
23343 # A language specific compiler.
23344 CC=$lt_compiler
23345
23346 # Is the compiler the GNU compiler?
23347 with_gcc=$GCC
23348
23349 # Compiler flag to turn off builtin functions.
23350 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
23351
23352 # Additional compiler flags for building library objects.
23353 pic_flag=$lt_lt_prog_compiler_pic
23354
23355 # How to pass a linker flag through the compiler.
23356 wl=$lt_lt_prog_compiler_wl
23357
23358 # Compiler flag to prevent dynamic linking.
23359 link_static_flag=$lt_lt_prog_compiler_static
23360
23361 # Does compiler simultaneously support -c and -o options?
23362 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
23363
23364 # Whether or not to add -lc for building shared libraries.
23365 build_libtool_need_lc=$archive_cmds_need_lc
23366
23367 # Whether or not to disallow shared libs when runtime libs are static.
23368 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
23369
23370 # Compiler flag to allow reflexive dlopens.
23371 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
23372
23373 # Compiler flag to generate shared objects directly from archives.
23374 whole_archive_flag_spec=$lt_whole_archive_flag_spec
23375
23376 # Whether the compiler copes with passing no objects directly.
23377 compiler_needs_object=$lt_compiler_needs_object
23378
23379 # Create an old-style archive from a shared archive.
23380 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
23381
23382 # Create a temporary old-style archive to link instead of a shared archive.
23383 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
23384
23385 # Commands used to build a shared archive.
23386 archive_cmds=$lt_archive_cmds
23387 archive_expsym_cmds=$lt_archive_expsym_cmds
23388
23389 # Commands used to build a loadable module if different from building
23390 # a shared archive.
23391 module_cmds=$lt_module_cmds
23392 module_expsym_cmds=$lt_module_expsym_cmds
23393
23394 # Whether we are building with GNU ld or not.
23395 with_gnu_ld=$lt_with_gnu_ld
23396
23397 # Flag that allows shared libraries with undefined symbols to be built.
23398 allow_undefined_flag=$lt_allow_undefined_flag
23399
23400 # Flag that enforces no undefined symbols.
23401 no_undefined_flag=$lt_no_undefined_flag
23402
23403 # Flag to hardcode \$libdir into a binary during linking.
23404 # This must work even if \$libdir does not exist
23405 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
23406
23407 # Whether we need a single "-rpath" flag with a separated argument.
23408 hardcode_libdir_separator=$lt_hardcode_libdir_separator
23409
23410 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
23411 # DIR into the resulting binary.
23412 hardcode_direct=$hardcode_direct
23413
23414 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
23415 # DIR into the resulting binary and the resulting library dependency is
23416 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
23417 # library is relocated.
23418 hardcode_direct_absolute=$hardcode_direct_absolute
23419
23420 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
23421 # into the resulting binary.
23422 hardcode_minus_L=$hardcode_minus_L
23423
23424 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
23425 # into the resulting binary.
23426 hardcode_shlibpath_var=$hardcode_shlibpath_var
23427
23428 # Set to "yes" if building a shared library automatically hardcodes DIR
23429 # into the library and all subsequent libraries and executables linked
23430 # against it.
23431 hardcode_automatic=$hardcode_automatic
23432
23433 # Set to yes if linker adds runtime paths of dependent libraries
23434 # to runtime path list.
23435 inherit_rpath=$inherit_rpath
23436
23437 # Whether libtool must link a program against all its dependency libraries.
23438 link_all_deplibs=$link_all_deplibs
23439
23440 # Set to "yes" if exported symbols are required.
23441 always_export_symbols=$always_export_symbols
23442
23443 # The commands to list exported symbols.
23444 export_symbols_cmds=$lt_export_symbols_cmds
23445
23446 # Symbols that should not be listed in the preloaded symbols.
23447 exclude_expsyms=$lt_exclude_expsyms
23448
23449 # Symbols that must always be exported.
23450 include_expsyms=$lt_include_expsyms
23451
23452 # Commands necessary for linking programs (against libraries) with templates.
23453 prelink_cmds=$lt_prelink_cmds
23454
23455 # Commands necessary for finishing linking programs.
23456 postlink_cmds=$lt_postlink_cmds
23457
23458 # Specify filename containing input files.
23459 file_list_spec=$lt_file_list_spec
23460
23461 # How to hardcode a shared library path into an executable.
23462 hardcode_action=$hardcode_action
23463
23464 # ### END LIBTOOL CONFIG
23465
23466 _LT_EOF
23467
23468 cat <<'_LT_EOF' >> "$cfgfile"
23469
23470 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
23471
23472 # func_munge_path_list VARIABLE PATH
23473 # -----------------------------------
23474 # VARIABLE is name of variable containing _space_ separated list of
23475 # directories to be munged by the contents of PATH, which is string
23476 # having a format:
23477 # "DIR[:DIR]:"
23478 # string "DIR[ DIR]" will be prepended to VARIABLE
23479 # ":DIR[:DIR]"
23480 # string "DIR[ DIR]" will be appended to VARIABLE
23481 # "DIRP[:DIRP]::[DIRA:]DIRA"
23482 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
23483 # "DIRA[ DIRA]" will be appended to VARIABLE
23484 # "DIR[:DIR]"
23485 # VARIABLE will be replaced by "DIR[ DIR]"
23486 func_munge_path_list ()
23487 {
23488 case x$2 in
23489 x)
23490 ;;
23491 *:)
23492 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
23493 ;;
23494 x:*)
23495 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
23496 ;;
23497 *::*)
23498 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
23499 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
23500 ;;
23501 *)
23502 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
23503 ;;
23504 esac
23505 }
23506
23507
23508 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
23509 func_cc_basename ()
23510 {
23511 for cc_temp in $*""; do
23512 case $cc_temp in
23513 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
23514 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
23515 \-*) ;;
23516 *) break;;
23517 esac
23518 done
23519 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
23520 }
23521
23522
23523 # ### END FUNCTIONS SHARED WITH CONFIGURE
23524
23525 _LT_EOF
23526
23527 case $host_os in
23528 aix3*)
23529 cat <<\_LT_EOF >> "$cfgfile"
23530 # AIX sometimes has problems with the GCC collect2 program. For some
23531 # reason, if we set the COLLECT_NAMES environment variable, the problems
23532 # vanish in a puff of smoke.
23533 if test set != "${COLLECT_NAMES+set}"; then
23534 COLLECT_NAMES=
23535 export COLLECT_NAMES
23536 fi
23537 _LT_EOF
23538 ;;
23539 esac
23540
23541
23542 ltmain=$ac_aux_dir/ltmain.sh
23543
23544
23545 # We use sed instead of cat because bash on DJGPP gets confused if
23546 # if finds mixed CR/LF and LF-only lines. Since sed operates in
23547 # text mode, it properly converts lines to CR/LF. This bash problem
23548 # is reportedly fixed, but why not run on old versions too?
23549 sed '$q' "$ltmain" >> "$cfgfile" \
23550 || (rm -f "$cfgfile"; exit 1)
23551
23552 mv -f "$cfgfile" "$ofile" ||
23553 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
23554 chmod +x "$ofile"
23555
23556 ;;
23557 "disable-rpath":C)
23558 sed < libtool > libtool-2 \
23559 's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_RPATH_SED__ "/'
23560 mv libtool-2 libtool
23561 chmod 755 libtool
23562 libtool="./libtool"
23563 ;;
23564
23565 esac
23566 done # for ac_tag
23567
23568
23569 as_fn_exit 0
23570 _ACEOF
23571 ac_clean_files=$ac_clean_files_save
23572
23573 test $ac_write_fail = 0 ||
23574 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
23575
23576
23577 # configure is writing to config.log, and then calls config.status.
23578 # config.status does its own redirection, appending to config.log.
23579 # Unfortunately, on DOS this fails, as config.log is still kept open
23580 # by configure, so config.status won't be able to write to it; its
23581 # output is simply discarded. So we exec the FD to /dev/null,
23582 # effectively closing config.log, so it can be properly (re)opened and
23583 # appended to by config.status. When coming back to configure, we
23584 # need to make the FD available again.
23585 if test "$no_create" != yes; then
23586 ac_cs_success=:
23587 ac_config_status_args=
23588 test "$silent" = yes &&
23589 ac_config_status_args="$ac_config_status_args --quiet"
23590 exec 5>/dev/null
23591 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
23592 exec 5>>config.log
23593 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23594 # would make configure fail if this is the last instruction.
23595 $ac_cs_success || as_fn_exit 1
23596 fi
23597 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
23598 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
23599 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
23600 fi
23601
23602