gdb/configure: Add --with-libgmp-prefix option
[binutils-gdb.git] / gdb / configure
blob2bf08569bf5733bcc36b3d9bb7bee741775c88ab
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 ## -------------------- ##
12 ## M4sh Initialization. ##
13 ## -------------------- ##
15 # Be more Bourne compatible
16 DUALCASE=1; export DUALCASE # for MKS sh
17 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18 emulate sh
19 NULLCMD=:
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
23 setopt NO_GLOB_SUBST
24 else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
30 esac
34 as_nl='
36 export as_nl
37 # Printing a long string crashes Solaris 7 /usr/bin/printf.
38 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41 # Prefer a ksh shell builtin over an external printf program on Solaris,
42 # but without wasting forks for bash or zsh.
43 if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50 else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
72 # The user is always right.
73 if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
82 # IFS
83 # We need space, tab and new line, in precisely that order. Quoting is
84 # there to prevent editors from complaining about space-tab.
85 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
86 # splitting by setting IFS to empty value.)
87 IFS=" "" $as_nl"
89 # Find who we are. Look in the path if we contain no directory separator.
90 as_myself=
91 case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94 for as_dir in $PATH
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100 IFS=$as_save_IFS
103 esac
104 # We did not find ourselves, most probably we were run as `sh COMMAND'
105 # in which case we are not to be found in the path.
106 if test "x$as_myself" = x; then
107 as_myself=$0
109 if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
114 # Unset variables that we do not need and which cause bugs (e.g. in
115 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116 # suppresses any "Segmentation fault" message there. '((' could
117 # trigger a bug in pdksh 5.2.14.
118 for as_var in BASH_ENV ENV MAIL MAILPATH
119 do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121 done
122 PS1='$ '
123 PS2='> '
124 PS4='+ '
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135 # Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140 # neutralization value for shells without unset; and this also
141 # works around shells that cannot unset nonexistent variables.
142 # Preserve -v and -x to the replacement shell.
143 BASH_ENV=/dev/null
144 ENV=/dev/null
145 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146 case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151 esac
152 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153 # Admittedly, this is quite paranoid, since all the known shells bail
154 # out after a failed `exec'.
155 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156 as_fn_exit 255
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
160 if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168 else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
174 esac
177 as_required="as_fn_return () { (exit \$1); }
178 as_fn_success () { as_fn_return 0; }
179 as_fn_failure () { as_fn_return 1; }
180 as_fn_ret_success () { return 0; }
181 as_fn_ret_failure () { return 1; }
183 exitcode=0
184 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
190 else
191 exitcode=1; echo positional parameters were not saved.
193 test x\$exitcode = x0 || exit 1
194 test -x / || exit 1"
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199 test \$(( 1 + 1 )) = 2 || exit 1"
200 if (eval "$as_required") 2>/dev/null; then :
201 as_have_required=yes
202 else
203 as_have_required=no
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
207 else
208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209 as_found=false
210 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
217 for as_base in sh bash ksh sh5; do
218 # Try only shells that exist, to save several forks.
219 as_shell=$as_dir/$as_base
220 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222 CONFIG_SHELL=$as_shell as_have_required=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 break 2
227 done;;
228 esac
229 as_found=false
230 done
231 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233 CONFIG_SHELL=$SHELL as_have_required=yes
234 fi; }
235 IFS=$as_save_IFS
238 if test "x$CONFIG_SHELL" != x; then :
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241 # neutralization value for shells without unset; and this also
242 # works around shells that cannot unset nonexistent variables.
243 # Preserve -v and -x to the replacement shell.
244 BASH_ENV=/dev/null
245 ENV=/dev/null
246 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247 case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252 esac
253 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254 # Admittedly, this is quite paranoid, since all the known shells bail
255 # out after a failed `exec'.
256 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257 exit 255
260 if test x$as_have_required = xno; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x${ZSH_VERSION+set} = xset ; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
266 else
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268 $0: including any error possibly output before this
269 $0: message. Then install a modern shell, or manually run
270 $0: the script under such a shell if you do have one."
272 exit 1
276 SHELL=${CONFIG_SHELL-/bin/sh}
277 export SHELL
278 # Unset more variables known to interfere with behavior of common tools.
279 CLICOLOR_FORCE= GREP_OPTIONS=
280 unset CLICOLOR_FORCE GREP_OPTIONS
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
290 { eval $1=; unset $1;}
292 as_unset=as_fn_unset
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
299 return $1
300 } # as_fn_set_status
302 # as_fn_exit STATUS
303 # -----------------
304 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305 as_fn_exit ()
307 set +e
308 as_fn_set_status $1
309 exit $1
310 } # as_fn_exit
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
318 case $as_dir in #(
319 -*) as_dir=./$as_dir;;
320 esac
321 test -d "$as_dir" || eval $as_mkdir_p || {
322 as_dirs=
323 while :; do
324 case $as_dir in #(
325 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326 *) as_qdir=$as_dir;;
327 esac
328 as_dirs="'$as_qdir' $as_dirs"
329 as_dir=`$as_dirname -- "$as_dir" ||
330 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334 $as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336 s//\1/
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
343 /^X\(\/\/\)$/{
344 s//\1/
347 /^X\(\/\).*/{
348 s//\1/
351 s/.*/./; q'`
352 test -d "$as_dir" && break
353 done
354 test -z "$as_dirs" || eval "mkdir $as_dirs"
355 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
358 } # as_fn_mkdir_p
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
365 test -f "$1" && test -x "$1"
366 } # as_fn_executable_p
367 # as_fn_append VAR VALUE
368 # ----------------------
369 # Append the text in VALUE to the end of the definition contained in VAR. Take
370 # advantage of any shell optimizations that allow amortized linear growth over
371 # repeated appends, instead of the typical quadratic growth present in naive
372 # implementations.
373 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374 eval 'as_fn_append ()
376 eval $1+=\$2
378 else
379 as_fn_append ()
381 eval $1=\$$1\$2
383 fi # as_fn_append
385 # as_fn_arith ARG...
386 # ------------------
387 # Perform arithmetic evaluation on the ARGs, and store the result in the
388 # global $as_val. Take advantage of shells that can avoid forks. The arguments
389 # must be portable across $(()) and expr.
390 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391 eval 'as_fn_arith ()
393 as_val=$(( $* ))
395 else
396 as_fn_arith ()
398 as_val=`expr "$@" || test $? -eq 1`
400 fi # as_fn_arith
403 # as_fn_error STATUS ERROR [LINENO LOG_FD]
404 # ----------------------------------------
405 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407 # script with STATUS, using 1 if that was 0.
408 as_fn_error ()
410 as_status=$1; test $as_status -eq 0 && as_status=1
411 if test "$4"; then
412 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417 } # as_fn_error
419 if expr a : '\(a\)' >/dev/null 2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001; then
421 as_expr=expr
422 else
423 as_expr=false
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428 else
429 as_basename=false
432 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433 as_dirname=dirname
434 else
435 as_dirname=false
438 as_me=`$as_basename -- "$0" ||
439 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442 $as_echo X/"$0" |
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
444 s//\1/
447 /^X\/\(\/\/\)$/{
448 s//\1/
451 /^X\/\(\/\).*/{
452 s//\1/
455 s/.*/./; q'`
457 # Avoid depending upon Character Ranges.
458 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461 as_cr_digits='0123456789'
462 as_cr_alnum=$as_cr_Letters$as_cr_digits
465 as_lineno_1=$LINENO as_lineno_1a=$LINENO
466 as_lineno_2=$LINENO as_lineno_2a=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
470 sed -n '
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
478 :lineno
480 :loop
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
482 t loop
483 s/-\n.*//
484 ' >$as_me.lineno &&
485 chmod +x "$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec=no; export _as_can_reexec
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
494 # original and so on. Autoconf is especially sensitive to this).
495 . "./$as_me.lineno"
496 # Exit status is that of the last command.
497 exit
500 ECHO_C= ECHO_N= ECHO_T=
501 case `echo -n x` in #(((((
502 -n*)
503 case `echo 'xy\c'` in
504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
505 xy) ECHO_C='\c';;
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
507 ECHO_T=' ';;
508 esac;;
510 ECHO_N='-n';;
511 esac
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515 rm -f conf$$.dir/conf$$.file
516 else
517 rm -f conf$$.dir
518 mkdir conf$$.dir 2>/dev/null
520 if (echo >conf$$.file) 2>/dev/null; then
521 if ln -s conf$$.file conf$$ 2>/dev/null; then
522 as_ln_s='ln -s'
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526 # In both cases, we have to default to `cp -pR'.
527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528 as_ln_s='cp -pR'
529 elif ln conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s=ln
531 else
532 as_ln_s='cp -pR'
534 else
535 as_ln_s='cp -pR'
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
540 if mkdir -p . 2>/dev/null; then
541 as_mkdir_p='mkdir -p "$as_dir"'
542 else
543 test -d ./-p && rmdir ./-p
544 as_mkdir_p=false
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
550 # Sed expression to map a string onto a valid CPP name.
551 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
553 # Sed expression to map a string onto a valid variable name.
554 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
560 # Name of the host.
561 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562 # so uname gets run too.
563 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
566 # Initializations.
568 ac_default_prefix=/usr/local
569 ac_clean_files=
570 ac_config_libobj_dir=.
571 LIBOBJS=
572 cross_compiling=no
573 subdirs=
574 MFLAGS=
575 MAKEFLAGS=
577 # Identity of this package.
578 PACKAGE_NAME=
579 PACKAGE_TARNAME=
580 PACKAGE_VERSION=
581 PACKAGE_STRING=
582 PACKAGE_BUGREPORT=
583 PACKAGE_URL=
585 ac_unique_file="main.c"
586 # Factoring default headers for most tests.
587 ac_includes_default="\
588 #include <stdio.h>
589 #ifdef HAVE_SYS_TYPES_H
590 # include <sys/types.h>
591 #endif
592 #ifdef HAVE_SYS_STAT_H
593 # include <sys/stat.h>
594 #endif
595 #ifdef STDC_HEADERS
596 # include <stdlib.h>
597 # include <stddef.h>
598 #else
599 # ifdef HAVE_STDLIB_H
600 # include <stdlib.h>
601 # endif
602 #endif
603 #ifdef HAVE_STRING_H
604 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
605 # include <memory.h>
606 # endif
607 # include <string.h>
608 #endif
609 #ifdef HAVE_STRINGS_H
610 # include <strings.h>
611 #endif
612 #ifdef HAVE_INTTYPES_H
613 # include <inttypes.h>
614 #endif
615 #ifdef HAVE_STDINT_H
616 # include <stdint.h>
617 #endif
618 #ifdef HAVE_UNISTD_H
619 # include <unistd.h>
620 #endif"
622 enable_option_checking=no
623 ac_header_list=
624 ac_subst_vars='LTLIBOBJS
625 LIBOBJS
626 GCORE_TRANSFORM_NAME
627 GDB_TRANSFORM_NAME
628 XSLTPROC
629 NM_H
630 GDB_NM_FILE
631 LTLIBXXHASH
632 LIBXXHASH
633 HAVE_LIBXXHASH
634 CTF_DEPS
635 LIBCTF
636 ENABLE_LIBCTF
637 LTLIBBABELTRACE
638 LIBBABELTRACE
639 HAVE_LIBBABELTRACE
640 HAVE_NATIVE_GCORE_HOST
641 NAT_GENERATED_FILES
642 XM_CLIBS
643 MH_CFLAGS
644 LOADLIBES
645 NAT_CDEPS
646 NATDEPFILES
647 NAT_FILE
648 target_subdir
649 CONFIG_UNINSTALL
650 CONFIG_INSTALL
651 CONFIG_CLEAN
652 CONFIG_ALL
653 CONFIG_SRCS
654 CONFIG_DEPS
655 CONFIG_OBS
656 PROFILE_CFLAGS
657 ENABLE_CFLAGS
658 SIM_OBS
660 XMKMF
661 GDBTK_SRC_DIR
662 GDBTK_CFLAGS
663 GDBTKLIBS
664 X_LIBS
665 X_LDFLAGS
666 X_CFLAGS
667 TK_XINCLUDES
668 TK_DEPS
669 TK_LIBRARY
670 TK_INCLUDE
671 TK_STUB_LIB_SPEC
672 TK_STUB_LIB_FLAG
673 TK_STUB_LIB_FILE
674 TK_LIB_SPEC
675 TK_LIB_FLAG
676 TK_LIB_FILE
677 TK_SRC_DIR
678 TK_BIN_DIR
679 TK_VERSION
680 TCL_DEPS
681 TCL_LIBRARY
682 TCL_INCLUDE
683 TCL_STUB_LIB_SPEC
684 TCL_STUB_LIB_FLAG
685 TCL_STUB_LIB_FILE
686 TCL_LIB_SPEC
687 TCL_LIB_FLAG
688 TCL_LIB_FILE
689 TCL_SRC_DIR
690 TCL_BIN_DIR
691 TCL_PATCH_LEVEL
692 TCL_VERSION
693 WIN32LDAPP
694 WIN32LIBS
695 GUI_CFLAGS_X
696 LIBGUI
697 LTLIBLZMA
698 LIBLZMA
699 HAVE_LIBLZMA
700 SER_HARDWIRE
701 WERROR_CFLAGS
702 WARN_CFLAGS
703 SYSTEM_GDBINIT_DIR
704 SYSTEM_GDBINIT
705 TARGET_SYSTEM_ROOT
706 CONFIG_LDFLAGS
707 RDYNAMIC
708 LTLIBIPT
709 LIBIPT
710 HAVE_LIBIPT
711 PTHREAD_CFLAGS
712 PTHREAD_LIBS
713 PTHREAD_CC
714 ax_pthread_config
716 ALLOCA
717 SRCHIGH_CFLAGS
718 SRCHIGH_LIBS
719 HAVE_GUILE_FALSE
720 HAVE_GUILE_TRUE
721 GUILE_LIBS
722 GUILE_CPPFLAGS
723 GUILD_TARGET_FLAG
724 GUILD
725 pkg_config_prog_path
726 HAVE_PYTHON_FALSE
727 HAVE_PYTHON_TRUE
728 PYTHON_LIBS
729 PYTHON_CPPFLAGS
730 PYTHON_CFLAGS
731 python_prog_path
732 LTLIBMPFR
733 LIBMPFR
734 HAVE_LIBMPFR
735 LTLIBGMP
736 LIBGMP
737 HAVE_LIBGMP
738 LTLIBEXPAT
739 LIBEXPAT
740 HAVE_LIBEXPAT
741 JIT_READER_DIR
742 TARGET_PTR
743 READLINE_TEXI_INCFLAG
744 READLINE_CFLAGS
745 READLINE_DEPS
746 READLINE
747 LTLIBICONV
748 LIBICONV
749 zlibinc
750 zlibdir
752 WINDRES
753 DLLTOOL
755 YFLAGS
756 YACC
757 RANLIB
758 LN_S
759 INSTALL_DATA
760 INSTALL_SCRIPT
761 INSTALL_PROGRAM
763 REPORT_BUGS_TEXI
764 REPORT_BUGS_TO
765 PKGVERSION
766 CODESIGN_CERT
767 DEBUGINFOD_LIBS
768 DEBUGINFOD_CFLAGS
769 PKG_CONFIG_LIBDIR
770 PKG_CONFIG_PATH
771 PKG_CONFIG
772 HAVE_NATIVE_GCORE_TARGET
773 TARGET_OBS
774 subdirs
775 GDB_DATADIR
776 DEBUGDIR
777 MAKEINFO_EXTRA_FLAGS
778 MAKEINFOFLAGS
779 MAKEINFO
780 PACKAGE
781 CATOBJEXT
782 GENCAT
783 INSTOBJEXT
784 DATADIRNAME
785 CATALOGS
786 POSUB
787 GMSGFMT
788 XGETTEXT
789 INCINTL
790 LIBINTL_DEP
791 LIBINTL
792 USE_NLS
793 CCDEPMODE
794 DEPDIR
795 am__leading_dot
796 CXX_DIALECT
797 HAVE_CXX11
798 INSTALL_STRIP_PROGRAM
799 STRIP
800 install_sh
801 LARGEFILE_CPPFLAGS
802 target_os
803 target_vendor
804 target_cpu
805 target
806 host_os
807 host_vendor
808 host_cpu
809 host
810 build_os
811 build_vendor
812 build_cpu
813 build
814 EGREP
815 GREP
817 ac_ct_CXX
818 CXXFLAGS
820 OBJEXT
821 EXEEXT
822 ac_ct_CC
823 CPPFLAGS
824 LDFLAGS
825 CFLAGS
827 MAINT
828 MAINTAINER_MODE_FALSE
829 MAINTAINER_MODE_TRUE
830 target_alias
831 host_alias
832 build_alias
833 LIBS
834 ECHO_T
835 ECHO_N
836 ECHO_C
837 DEFS
838 mandir
839 localedir
840 libdir
841 psdir
842 pdfdir
843 dvidir
844 htmldir
845 infodir
846 docdir
847 oldincludedir
848 includedir
849 localstatedir
850 sharedstatedir
851 sysconfdir
852 datadir
853 datarootdir
854 libexecdir
855 sbindir
856 bindir
857 program_transform_name
858 prefix
859 exec_prefix
860 PACKAGE_URL
861 PACKAGE_BUGREPORT
862 PACKAGE_STRING
863 PACKAGE_VERSION
864 PACKAGE_TARNAME
865 PACKAGE_NAME
866 PATH_SEPARATOR
867 SHELL'
868 ac_subst_files='nat_makefile_frag'
869 ac_user_opts='
870 enable_option_checking
871 enable_maintainer_mode
872 enable_plugins
873 enable_largefile
874 with_separate_debug_dir
875 with_gdb_datadir
876 with_relocated_sources
877 with_auto_load_dir
878 with_auto_load_safe_path
879 enable_targets
880 enable_64_bit_bfd
881 enable_gdbmi
882 enable_tui
883 enable_gdbtk
884 with_debuginfod
885 with_libunwind_ia64
886 with_curses
887 enable_profiling
888 enable_codesign
889 with_pkgversion
890 with_bugurl
891 with_system_zlib
892 with_gnu_ld
893 enable_rpath
894 with_libiconv_prefix
895 with_libiconv_type
896 with_iconv_bin
897 with_system_readline
898 with_jit_reader_dir
899 with_expat
900 with_libexpat_prefix
901 with_libexpat_type
902 with_libgmp_prefix
903 with_libgmp_type
904 with_mpfr
905 with_libmpfr_prefix
906 with_libmpfr_type
907 with_python
908 with_python_libdir
909 with_guile
910 enable_source_highlight
911 with_intel_pt
912 with_libipt_prefix
913 with_libipt_type
914 with_included_regex
915 with_sysroot
916 with_system_gdbinit
917 with_system_gdbinit_dir
918 enable_werror
919 enable_build_warnings
920 enable_gdb_build_warnings
921 enable_ubsan
922 with_lzma
923 with_liblzma_prefix
924 with_liblzma_type
925 with_tcl
926 with_tk
927 with_x
928 enable_sim
929 with_babeltrace
930 with_libbabeltrace_prefix
931 with_libbabeltrace_type
932 with_xxhash
933 enable_libctf
934 with_libxxhash_prefix
935 with_libxxhash_type
936 enable_unit_tests
938 ac_precious_vars='build_alias
939 host_alias
940 target_alias
942 CFLAGS
943 LDFLAGS
944 LIBS
945 CPPFLAGS
947 CXXFLAGS
950 MAKEINFO
951 MAKEINFOFLAGS
952 PKG_CONFIG
953 PKG_CONFIG_PATH
954 PKG_CONFIG_LIBDIR
955 DEBUGINFOD_CFLAGS
956 DEBUGINFOD_LIBS
957 YACC
958 YFLAGS
959 XMKMF'
960 ac_subdirs_all='testsuite
961 gdbtk'
963 # Initialize some variables set by options.
964 ac_init_help=
965 ac_init_version=false
966 ac_unrecognized_opts=
967 ac_unrecognized_sep=
968 # The variables have the same names as the options, with
969 # dashes changed to underlines.
970 cache_file=/dev/null
971 exec_prefix=NONE
972 no_create=
973 no_recursion=
974 prefix=NONE
975 program_prefix=NONE
976 program_suffix=NONE
977 program_transform_name=s,x,x,
978 silent=
979 site=
980 srcdir=
981 verbose=
982 x_includes=NONE
983 x_libraries=NONE
985 # Installation directory options.
986 # These are left unexpanded so users can "make install exec_prefix=/foo"
987 # and all the variables that are supposed to be based on exec_prefix
988 # by default will actually change.
989 # Use braces instead of parens because sh, perl, etc. also accept them.
990 # (The list follows the same order as the GNU Coding Standards.)
991 bindir='${exec_prefix}/bin'
992 sbindir='${exec_prefix}/sbin'
993 libexecdir='${exec_prefix}/libexec'
994 datarootdir='${prefix}/share'
995 datadir='${datarootdir}'
996 sysconfdir='${prefix}/etc'
997 sharedstatedir='${prefix}/com'
998 localstatedir='${prefix}/var'
999 includedir='${prefix}/include'
1000 oldincludedir='/usr/include'
1001 docdir='${datarootdir}/doc/${PACKAGE}'
1002 infodir='${datarootdir}/info'
1003 htmldir='${docdir}'
1004 dvidir='${docdir}'
1005 pdfdir='${docdir}'
1006 psdir='${docdir}'
1007 libdir='${exec_prefix}/lib'
1008 localedir='${datarootdir}/locale'
1009 mandir='${datarootdir}/man'
1011 ac_prev=
1012 ac_dashdash=
1013 for ac_option
1015 # If the previous option needs an argument, assign it.
1016 if test -n "$ac_prev"; then
1017 eval $ac_prev=\$ac_option
1018 ac_prev=
1019 continue
1022 case $ac_option in
1023 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1024 *=) ac_optarg= ;;
1025 *) ac_optarg=yes ;;
1026 esac
1028 # Accept the important Cygnus configure options, so we can diagnose typos.
1030 case $ac_dashdash$ac_option in
1032 ac_dashdash=yes ;;
1034 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1035 ac_prev=bindir ;;
1036 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1037 bindir=$ac_optarg ;;
1039 -build | --build | --buil | --bui | --bu)
1040 ac_prev=build_alias ;;
1041 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1042 build_alias=$ac_optarg ;;
1044 -cache-file | --cache-file | --cache-fil | --cache-fi \
1045 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1046 ac_prev=cache_file ;;
1047 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1048 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1049 cache_file=$ac_optarg ;;
1051 --config-cache | -C)
1052 cache_file=config.cache ;;
1054 -datadir | --datadir | --datadi | --datad)
1055 ac_prev=datadir ;;
1056 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1057 datadir=$ac_optarg ;;
1059 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1060 | --dataroo | --dataro | --datar)
1061 ac_prev=datarootdir ;;
1062 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1063 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1064 datarootdir=$ac_optarg ;;
1066 -disable-* | --disable-*)
1067 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1068 # Reject names that are not valid shell variable names.
1069 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1070 as_fn_error $? "invalid feature name: $ac_useropt"
1071 ac_useropt_orig=$ac_useropt
1072 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1073 case $ac_user_opts in
1075 "enable_$ac_useropt"
1076 "*) ;;
1077 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1078 ac_unrecognized_sep=', ';;
1079 esac
1080 eval enable_$ac_useropt=no ;;
1082 -docdir | --docdir | --docdi | --doc | --do)
1083 ac_prev=docdir ;;
1084 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1085 docdir=$ac_optarg ;;
1087 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1088 ac_prev=dvidir ;;
1089 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1090 dvidir=$ac_optarg ;;
1092 -enable-* | --enable-*)
1093 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1094 # Reject names that are not valid shell variable names.
1095 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1096 as_fn_error $? "invalid feature name: $ac_useropt"
1097 ac_useropt_orig=$ac_useropt
1098 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1099 case $ac_user_opts in
1101 "enable_$ac_useropt"
1102 "*) ;;
1103 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1104 ac_unrecognized_sep=', ';;
1105 esac
1106 eval enable_$ac_useropt=\$ac_optarg ;;
1108 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1109 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1110 | --exec | --exe | --ex)
1111 ac_prev=exec_prefix ;;
1112 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1113 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1114 | --exec=* | --exe=* | --ex=*)
1115 exec_prefix=$ac_optarg ;;
1117 -gas | --gas | --ga | --g)
1118 # Obsolete; use --with-gas.
1119 with_gas=yes ;;
1121 -help | --help | --hel | --he | -h)
1122 ac_init_help=long ;;
1123 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1124 ac_init_help=recursive ;;
1125 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1126 ac_init_help=short ;;
1128 -host | --host | --hos | --ho)
1129 ac_prev=host_alias ;;
1130 -host=* | --host=* | --hos=* | --ho=*)
1131 host_alias=$ac_optarg ;;
1133 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1134 ac_prev=htmldir ;;
1135 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1136 | --ht=*)
1137 htmldir=$ac_optarg ;;
1139 -includedir | --includedir | --includedi | --included | --include \
1140 | --includ | --inclu | --incl | --inc)
1141 ac_prev=includedir ;;
1142 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1143 | --includ=* | --inclu=* | --incl=* | --inc=*)
1144 includedir=$ac_optarg ;;
1146 -infodir | --infodir | --infodi | --infod | --info | --inf)
1147 ac_prev=infodir ;;
1148 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1149 infodir=$ac_optarg ;;
1151 -libdir | --libdir | --libdi | --libd)
1152 ac_prev=libdir ;;
1153 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1154 libdir=$ac_optarg ;;
1156 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1157 | --libexe | --libex | --libe)
1158 ac_prev=libexecdir ;;
1159 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1160 | --libexe=* | --libex=* | --libe=*)
1161 libexecdir=$ac_optarg ;;
1163 -localedir | --localedir | --localedi | --localed | --locale)
1164 ac_prev=localedir ;;
1165 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1166 localedir=$ac_optarg ;;
1168 -localstatedir | --localstatedir | --localstatedi | --localstated \
1169 | --localstate | --localstat | --localsta | --localst | --locals)
1170 ac_prev=localstatedir ;;
1171 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1172 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1173 localstatedir=$ac_optarg ;;
1175 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1176 ac_prev=mandir ;;
1177 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1178 mandir=$ac_optarg ;;
1180 -nfp | --nfp | --nf)
1181 # Obsolete; use --without-fp.
1182 with_fp=no ;;
1184 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1185 | --no-cr | --no-c | -n)
1186 no_create=yes ;;
1188 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1189 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1190 no_recursion=yes ;;
1192 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1193 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1194 | --oldin | --oldi | --old | --ol | --o)
1195 ac_prev=oldincludedir ;;
1196 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1197 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1198 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1199 oldincludedir=$ac_optarg ;;
1201 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1202 ac_prev=prefix ;;
1203 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1204 prefix=$ac_optarg ;;
1206 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1207 | --program-pre | --program-pr | --program-p)
1208 ac_prev=program_prefix ;;
1209 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1210 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1211 program_prefix=$ac_optarg ;;
1213 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1214 | --program-suf | --program-su | --program-s)
1215 ac_prev=program_suffix ;;
1216 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1217 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1218 program_suffix=$ac_optarg ;;
1220 -program-transform-name | --program-transform-name \
1221 | --program-transform-nam | --program-transform-na \
1222 | --program-transform-n | --program-transform- \
1223 | --program-transform | --program-transfor \
1224 | --program-transfo | --program-transf \
1225 | --program-trans | --program-tran \
1226 | --progr-tra | --program-tr | --program-t)
1227 ac_prev=program_transform_name ;;
1228 -program-transform-name=* | --program-transform-name=* \
1229 | --program-transform-nam=* | --program-transform-na=* \
1230 | --program-transform-n=* | --program-transform-=* \
1231 | --program-transform=* | --program-transfor=* \
1232 | --program-transfo=* | --program-transf=* \
1233 | --program-trans=* | --program-tran=* \
1234 | --progr-tra=* | --program-tr=* | --program-t=*)
1235 program_transform_name=$ac_optarg ;;
1237 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1238 ac_prev=pdfdir ;;
1239 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1240 pdfdir=$ac_optarg ;;
1242 -psdir | --psdir | --psdi | --psd | --ps)
1243 ac_prev=psdir ;;
1244 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1245 psdir=$ac_optarg ;;
1247 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1248 | -silent | --silent | --silen | --sile | --sil)
1249 silent=yes ;;
1251 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1252 ac_prev=sbindir ;;
1253 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1254 | --sbi=* | --sb=*)
1255 sbindir=$ac_optarg ;;
1257 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1258 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1259 | --sharedst | --shareds | --shared | --share | --shar \
1260 | --sha | --sh)
1261 ac_prev=sharedstatedir ;;
1262 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1263 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1264 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1265 | --sha=* | --sh=*)
1266 sharedstatedir=$ac_optarg ;;
1268 -site | --site | --sit)
1269 ac_prev=site ;;
1270 -site=* | --site=* | --sit=*)
1271 site=$ac_optarg ;;
1273 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1274 ac_prev=srcdir ;;
1275 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1276 srcdir=$ac_optarg ;;
1278 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1279 | --syscon | --sysco | --sysc | --sys | --sy)
1280 ac_prev=sysconfdir ;;
1281 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1282 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1283 sysconfdir=$ac_optarg ;;
1285 -target | --target | --targe | --targ | --tar | --ta | --t)
1286 ac_prev=target_alias ;;
1287 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1288 target_alias=$ac_optarg ;;
1290 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1291 verbose=yes ;;
1293 -version | --version | --versio | --versi | --vers | -V)
1294 ac_init_version=: ;;
1296 -with-* | --with-*)
1297 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1298 # Reject names that are not valid shell variable names.
1299 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1300 as_fn_error $? "invalid package name: $ac_useropt"
1301 ac_useropt_orig=$ac_useropt
1302 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1303 case $ac_user_opts in
1305 "with_$ac_useropt"
1306 "*) ;;
1307 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1308 ac_unrecognized_sep=', ';;
1309 esac
1310 eval with_$ac_useropt=\$ac_optarg ;;
1312 -without-* | --without-*)
1313 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1314 # Reject names that are not valid shell variable names.
1315 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1316 as_fn_error $? "invalid package name: $ac_useropt"
1317 ac_useropt_orig=$ac_useropt
1318 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1319 case $ac_user_opts in
1321 "with_$ac_useropt"
1322 "*) ;;
1323 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1324 ac_unrecognized_sep=', ';;
1325 esac
1326 eval with_$ac_useropt=no ;;
1328 --x)
1329 # Obsolete; use --with-x.
1330 with_x=yes ;;
1332 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1333 | --x-incl | --x-inc | --x-in | --x-i)
1334 ac_prev=x_includes ;;
1335 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1336 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1337 x_includes=$ac_optarg ;;
1339 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1340 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1341 ac_prev=x_libraries ;;
1342 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1343 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1344 x_libraries=$ac_optarg ;;
1346 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1347 Try \`$0 --help' for more information"
1350 *=*)
1351 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1352 # Reject names that are not valid shell variable names.
1353 case $ac_envvar in #(
1354 '' | [0-9]* | *[!_$as_cr_alnum]* )
1355 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1356 esac
1357 eval $ac_envvar=\$ac_optarg
1358 export $ac_envvar ;;
1361 # FIXME: should be removed in autoconf 3.0.
1362 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1363 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1364 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1365 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1368 esac
1369 done
1371 if test -n "$ac_prev"; then
1372 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1373 as_fn_error $? "missing argument to $ac_option"
1376 if test -n "$ac_unrecognized_opts"; then
1377 case $enable_option_checking in
1378 no) ;;
1379 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1380 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1381 esac
1384 # Check all directory arguments for consistency.
1385 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1386 datadir sysconfdir sharedstatedir localstatedir includedir \
1387 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1388 libdir localedir mandir
1390 eval ac_val=\$$ac_var
1391 # Remove trailing slashes.
1392 case $ac_val in
1393 */ )
1394 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1395 eval $ac_var=\$ac_val;;
1396 esac
1397 # Be sure to have absolute directory names.
1398 case $ac_val in
1399 [\\/$]* | ?:[\\/]* ) continue;;
1400 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1401 esac
1402 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1403 done
1405 # There might be people who depend on the old broken behavior: `$host'
1406 # used to hold the argument of --host etc.
1407 # FIXME: To remove some day.
1408 build=$build_alias
1409 host=$host_alias
1410 target=$target_alias
1412 # FIXME: To remove some day.
1413 if test "x$host_alias" != x; then
1414 if test "x$build_alias" = x; then
1415 cross_compiling=maybe
1416 elif test "x$build_alias" != "x$host_alias"; then
1417 cross_compiling=yes
1421 ac_tool_prefix=
1422 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1424 test "$silent" = yes && exec 6>/dev/null
1427 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1428 ac_ls_di=`ls -di .` &&
1429 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1430 as_fn_error $? "working directory cannot be determined"
1431 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1432 as_fn_error $? "pwd does not report name of working directory"
1435 # Find the source files, if location was not specified.
1436 if test -z "$srcdir"; then
1437 ac_srcdir_defaulted=yes
1438 # Try the directory containing this script, then the parent directory.
1439 ac_confdir=`$as_dirname -- "$as_myself" ||
1440 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1441 X"$as_myself" : 'X\(//\)[^/]' \| \
1442 X"$as_myself" : 'X\(//\)$' \| \
1443 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1444 $as_echo X"$as_myself" |
1445 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1446 s//\1/
1449 /^X\(\/\/\)[^/].*/{
1450 s//\1/
1453 /^X\(\/\/\)$/{
1454 s//\1/
1457 /^X\(\/\).*/{
1458 s//\1/
1461 s/.*/./; q'`
1462 srcdir=$ac_confdir
1463 if test ! -r "$srcdir/$ac_unique_file"; then
1464 srcdir=..
1466 else
1467 ac_srcdir_defaulted=no
1469 if test ! -r "$srcdir/$ac_unique_file"; then
1470 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1471 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1473 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1474 ac_abs_confdir=`(
1475 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1476 pwd)`
1477 # When building in place, set srcdir=.
1478 if test "$ac_abs_confdir" = "$ac_pwd"; then
1479 srcdir=.
1481 # Remove unnecessary trailing slashes from srcdir.
1482 # Double slashes in file names in object file debugging info
1483 # mess up M-x gdb in Emacs.
1484 case $srcdir in
1485 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1486 esac
1487 for ac_var in $ac_precious_vars; do
1488 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1489 eval ac_env_${ac_var}_value=\$${ac_var}
1490 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1491 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1492 done
1495 # Report the --help message.
1497 if test "$ac_init_help" = "long"; then
1498 # Omit some internal or obsolete options to make the list less imposing.
1499 # This message is too long to be a string in the A/UX 3.1 sh.
1500 cat <<_ACEOF
1501 \`configure' configures this package to adapt to many kinds of systems.
1503 Usage: $0 [OPTION]... [VAR=VALUE]...
1505 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1506 VAR=VALUE. See below for descriptions of some of the useful variables.
1508 Defaults for the options are specified in brackets.
1510 Configuration:
1511 -h, --help display this help and exit
1512 --help=short display options specific to this package
1513 --help=recursive display the short help of all the included packages
1514 -V, --version display version information and exit
1515 -q, --quiet, --silent do not print \`checking ...' messages
1516 --cache-file=FILE cache test results in FILE [disabled]
1517 -C, --config-cache alias for \`--cache-file=config.cache'
1518 -n, --no-create do not create output files
1519 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1521 Installation directories:
1522 --prefix=PREFIX install architecture-independent files in PREFIX
1523 [$ac_default_prefix]
1524 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1525 [PREFIX]
1527 By default, \`make install' will install all the files in
1528 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1529 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1530 for instance \`--prefix=\$HOME'.
1532 For better control, use the options below.
1534 Fine tuning of the installation directories:
1535 --bindir=DIR user executables [EPREFIX/bin]
1536 --sbindir=DIR system admin executables [EPREFIX/sbin]
1537 --libexecdir=DIR program executables [EPREFIX/libexec]
1538 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1539 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1540 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1541 --libdir=DIR object code libraries [EPREFIX/lib]
1542 --includedir=DIR C header files [PREFIX/include]
1543 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1544 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1545 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1546 --infodir=DIR info documentation [DATAROOTDIR/info]
1547 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1548 --mandir=DIR man documentation [DATAROOTDIR/man]
1549 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1550 --htmldir=DIR html documentation [DOCDIR]
1551 --dvidir=DIR dvi documentation [DOCDIR]
1552 --pdfdir=DIR pdf documentation [DOCDIR]
1553 --psdir=DIR ps documentation [DOCDIR]
1554 _ACEOF
1556 cat <<\_ACEOF
1558 Program names:
1559 --program-prefix=PREFIX prepend PREFIX to installed program names
1560 --program-suffix=SUFFIX append SUFFIX to installed program names
1561 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1563 X features:
1564 --x-includes=DIR X include files are in DIR
1565 --x-libraries=DIR X library files are in DIR
1567 System types:
1568 --build=BUILD configure for building on BUILD [guessed]
1569 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1570 --target=TARGET configure for building compilers for TARGET [HOST]
1571 _ACEOF
1574 if test -n "$ac_init_help"; then
1576 cat <<\_ACEOF
1578 Optional Features:
1579 --disable-option-checking ignore unrecognized --enable/--with options
1580 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1581 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1582 --enable-maintainer-mode
1583 enable make rules and dependencies not useful (and
1584 sometimes confusing) to the casual installer
1585 --enable-plugins Enable support for plugins
1586 --disable-largefile omit support for large files
1587 --enable-targets=TARGETS
1588 alternative target configurations
1589 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
1590 --disable-gdbmi disable machine-interface (MI)
1591 --enable-tui enable full-screen terminal user interface (TUI)
1592 --enable-gdbtk enable gdbtk graphical user interface (GUI)
1593 --enable-profiling enable profiling of GDB
1594 --enable-codesign=CERT sign gdb with 'codesign -s CERT'
1595 --disable-rpath do not hardcode runtime library paths
1596 --enable-source-highlight
1597 enable source-highlight for source listings
1598 --enable-werror treat compile warnings as errors
1599 --enable-build-warnings enable build-time compiler warnings if gcc is used
1600 --enable-gdb-build-warnings
1601 enable GDB specific build-time compiler warnings if
1602 gcc is used
1603 --enable-ubsan enable undefined behavior sanitizer (auto/yes/no)
1604 --enable-sim link gdb with simulator
1605 --enable-libctf Handle .ctf type-info sections [default=yes]
1606 --enable-unit-tests Enable the inclusion of unit tests when compiling
1609 Optional Packages:
1610 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1611 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1612 --with-separate-debug-dir=PATH
1613 look for global separate debug info in this path
1614 [LIBDIR/debug]
1615 --with-gdb-datadir=PATH look for global separate data files in this path
1616 [DATADIR/gdb]
1617 --with-relocated-sources=PATH
1618 automatically relocate this path for source files
1619 --with-auto-load-dir=PATH
1620 directories from which to load auto-loaded scripts
1621 [$debugdir:$datadir/auto-load]
1622 --with-auto-load-safe-path=PATH
1623 directories safe to hold auto-loaded files
1624 [--with-auto-load-dir]
1625 --without-auto-load-safe-path
1626 do not restrict auto-loaded files locations
1627 --with-debuginfod Enable debuginfo lookups with debuginfod
1628 (auto/yes/no)
1629 --with-libunwind-ia64 use libunwind frame unwinding for ia64 targets
1630 --with-curses use the curses library instead of the termcap
1631 library
1632 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1633 --with-bugurl=URL Direct users to URL to report a bug
1634 --with-system-zlib use installed libz
1635 --with-gnu-ld assume the C compiler uses GNU ld default=no
1636 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1637 --without-libiconv-prefix don't search for libiconv in includedir and libdir
1638 --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
1639 --with-iconv-bin=PATH specify where to find the iconv program
1640 --with-system-readline use installed readline library
1641 --with-jit-reader-dir=PATH
1642 directory to load the JIT readers from
1643 --with-expat include expat support (auto/yes/no)
1644 --with-libexpat-prefix[=DIR] search for libexpat in DIR/include and DIR/lib
1645 --without-libexpat-prefix don't search for libexpat in includedir and libdir
1646 --with-libexpat-type=TYPE type of library to search for (auto/static/shared)
1647 --with-libgmp-prefix[=DIR] search for libgmp in DIR/include and DIR/lib
1648 --without-libgmp-prefix don't search for libgmp in includedir and libdir
1649 --with-libgmp-type=TYPE type of library to search for (auto/static/shared)
1650 --with-mpfr include MPFR support (auto/yes/no)
1651 --with-libmpfr-prefix[=DIR] search for libmpfr in DIR/include and DIR/lib
1652 --without-libmpfr-prefix don't search for libmpfr in includedir and libdir
1653 --with-libmpfr-type=TYPE type of library to search for (auto/static/shared)
1654 --with-python[=PYTHON] include python support
1655 (auto/yes/no/<python-program>)
1656 --with-python-libdir[=DIR]
1657 search for python's libraries in DIR
1658 --with-guile[=GUILE] include guile support
1659 (auto/yes/no/<guile-version>/<pkg-config-program>)
1660 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
1661 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1662 --without-libipt-prefix don't search for libipt in includedir and libdir
1663 --with-libipt-type=TYPE type of library to search for (auto/static/shared)
1664 --without-included-regex
1665 don't use included regex; this is the default on
1666 systems with version 2 of the GNU C library (use
1667 with caution on other system)
1668 --with-sysroot[=DIR] search for usr/lib et al within DIR
1669 --with-system-gdbinit=PATH
1670 automatically load a system-wide gdbinit file
1671 --with-system-gdbinit-dir=PATH
1672 automatically load system-wide gdbinit files from
1673 this directory
1674 --with-lzma support lzma compression (auto/yes/no)
1675 --with-liblzma-prefix[=DIR] search for liblzma in DIR/include and DIR/lib
1676 --without-liblzma-prefix don't search for liblzma in includedir and libdir
1677 --with-liblzma-type=TYPE type of library to search for (auto/static/shared)
1678 --with-tcl directory containing tcl configuration (tclConfig.sh)
1679 --with-tk directory containing tk configuration (tkConfig.sh)
1680 --with-x use the X Window System
1681 --with-babeltrace include babeltrace support (auto/yes/no)
1682 --with-libbabeltrace-prefix[=DIR] search for libbabeltrace in DIR/include and DIR/lib
1683 --without-libbabeltrace-prefix don't search for libbabeltrace in includedir and libdir
1684 --with-libbabeltrace-type=TYPE type of library to search for (auto/static/shared)
1685 --with-xxhash use libxxhash for hashing (faster) (auto/yes/no)
1686 --with-libxxhash-prefix[=DIR] search for libxxhash in DIR/include and DIR/lib
1687 --without-libxxhash-prefix don't search for libxxhash in includedir and libdir
1688 --with-libxxhash-type=TYPE type of library to search for (auto/static/shared)
1690 Some influential environment variables:
1691 CC C compiler command
1692 CFLAGS C compiler flags
1693 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1694 nonstandard directory <lib dir>
1695 LIBS libraries to pass to the linker, e.g. -l<library>
1696 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1697 you have headers in a nonstandard directory <include dir>
1698 CXX C++ compiler command
1699 CXXFLAGS C++ compiler flags
1700 CPP C preprocessor
1701 MAKEINFO Parent configure detects if it is of sufficient version.
1702 MAKEINFOFLAGS
1703 Parameters for MAKEINFO.
1704 PKG_CONFIG path to pkg-config utility
1705 PKG_CONFIG_PATH
1706 directories to add to pkg-config's search path
1707 PKG_CONFIG_LIBDIR
1708 path overriding pkg-config's built-in search path
1709 DEBUGINFOD_CFLAGS
1710 C compiler flags for DEBUGINFOD, overriding pkg-config
1711 DEBUGINFOD_LIBS
1712 linker flags for DEBUGINFOD, overriding pkg-config
1713 YACC The `Yet Another Compiler Compiler' implementation to use.
1714 Defaults to the first program found out of: `bison -y', `byacc',
1715 `yacc'.
1716 YFLAGS The list of arguments that will be passed by default to $YACC.
1717 This script will default YFLAGS to the empty string to avoid a
1718 default value of `-d' given by some make applications.
1719 XMKMF Path to xmkmf, Makefile generator for X Window System
1721 Use these variables to override the choices made by `configure' or to help
1722 it to find libraries and programs with nonstandard names/locations.
1724 Report bugs to the package provider.
1725 _ACEOF
1726 ac_status=$?
1729 if test "$ac_init_help" = "recursive"; then
1730 # If there are subdirs, report their specific --help.
1731 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1732 test -d "$ac_dir" ||
1733 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1734 continue
1735 ac_builddir=.
1737 case "$ac_dir" in
1738 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1740 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1741 # A ".." for each directory in $ac_dir_suffix.
1742 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1743 case $ac_top_builddir_sub in
1744 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1745 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1746 esac ;;
1747 esac
1748 ac_abs_top_builddir=$ac_pwd
1749 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1750 # for backward compatibility:
1751 ac_top_builddir=$ac_top_build_prefix
1753 case $srcdir in
1754 .) # We are building in place.
1755 ac_srcdir=.
1756 ac_top_srcdir=$ac_top_builddir_sub
1757 ac_abs_top_srcdir=$ac_pwd ;;
1758 [\\/]* | ?:[\\/]* ) # Absolute name.
1759 ac_srcdir=$srcdir$ac_dir_suffix;
1760 ac_top_srcdir=$srcdir
1761 ac_abs_top_srcdir=$srcdir ;;
1762 *) # Relative name.
1763 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1764 ac_top_srcdir=$ac_top_build_prefix$srcdir
1765 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1766 esac
1767 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1769 cd "$ac_dir" || { ac_status=$?; continue; }
1770 # Check for guested configure.
1771 if test -f "$ac_srcdir/configure.gnu"; then
1772 echo &&
1773 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1774 elif test -f "$ac_srcdir/configure"; then
1775 echo &&
1776 $SHELL "$ac_srcdir/configure" --help=recursive
1777 else
1778 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1779 fi || ac_status=$?
1780 cd "$ac_pwd" || { ac_status=$?; break; }
1781 done
1784 test -n "$ac_init_help" && exit $ac_status
1785 if $ac_init_version; then
1786 cat <<\_ACEOF
1787 configure
1788 generated by GNU Autoconf 2.69
1790 Copyright (C) 2012 Free Software Foundation, Inc.
1791 This configure script is free software; the Free Software Foundation
1792 gives unlimited permission to copy, distribute and modify it.
1793 _ACEOF
1794 exit
1797 ## ------------------------ ##
1798 ## Autoconf initialization. ##
1799 ## ------------------------ ##
1801 # ac_fn_c_try_compile LINENO
1802 # --------------------------
1803 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1804 ac_fn_c_try_compile ()
1806 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1807 rm -f conftest.$ac_objext
1808 if { { ac_try="$ac_compile"
1809 case "(($ac_try" in
1810 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1811 *) ac_try_echo=$ac_try;;
1812 esac
1813 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1814 $as_echo "$ac_try_echo"; } >&5
1815 (eval "$ac_compile") 2>conftest.err
1816 ac_status=$?
1817 if test -s conftest.err; then
1818 grep -v '^ *+' conftest.err >conftest.er1
1819 cat conftest.er1 >&5
1820 mv -f conftest.er1 conftest.err
1822 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1823 test $ac_status = 0; } && {
1824 test -z "$ac_c_werror_flag" ||
1825 test ! -s conftest.err
1826 } && test -s conftest.$ac_objext; then :
1827 ac_retval=0
1828 else
1829 $as_echo "$as_me: failed program was:" >&5
1830 sed 's/^/| /' conftest.$ac_ext >&5
1832 ac_retval=1
1834 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1835 as_fn_set_status $ac_retval
1837 } # ac_fn_c_try_compile
1839 # ac_fn_cxx_try_compile LINENO
1840 # ----------------------------
1841 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1842 ac_fn_cxx_try_compile ()
1844 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1845 rm -f conftest.$ac_objext
1846 if { { ac_try="$ac_compile"
1847 case "(($ac_try" in
1848 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1849 *) ac_try_echo=$ac_try;;
1850 esac
1851 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1852 $as_echo "$ac_try_echo"; } >&5
1853 (eval "$ac_compile") 2>conftest.err
1854 ac_status=$?
1855 if test -s conftest.err; then
1856 grep -v '^ *+' conftest.err >conftest.er1
1857 cat conftest.er1 >&5
1858 mv -f conftest.er1 conftest.err
1860 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1861 test $ac_status = 0; } && {
1862 test -z "$ac_cxx_werror_flag" ||
1863 test ! -s conftest.err
1864 } && test -s conftest.$ac_objext; then :
1865 ac_retval=0
1866 else
1867 $as_echo "$as_me: failed program was:" >&5
1868 sed 's/^/| /' conftest.$ac_ext >&5
1870 ac_retval=1
1872 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1873 as_fn_set_status $ac_retval
1875 } # ac_fn_cxx_try_compile
1877 # ac_fn_c_try_cpp LINENO
1878 # ----------------------
1879 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1880 ac_fn_c_try_cpp ()
1882 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1883 if { { ac_try="$ac_cpp conftest.$ac_ext"
1884 case "(($ac_try" in
1885 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1886 *) ac_try_echo=$ac_try;;
1887 esac
1888 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1889 $as_echo "$ac_try_echo"; } >&5
1890 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1891 ac_status=$?
1892 if test -s conftest.err; then
1893 grep -v '^ *+' conftest.err >conftest.er1
1894 cat conftest.er1 >&5
1895 mv -f conftest.er1 conftest.err
1897 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1898 test $ac_status = 0; } > conftest.i && {
1899 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1900 test ! -s conftest.err
1901 }; then :
1902 ac_retval=0
1903 else
1904 $as_echo "$as_me: failed program was:" >&5
1905 sed 's/^/| /' conftest.$ac_ext >&5
1907 ac_retval=1
1909 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1910 as_fn_set_status $ac_retval
1912 } # ac_fn_c_try_cpp
1914 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1915 # -------------------------------------------------------
1916 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1917 # the include files in INCLUDES and setting the cache variable VAR
1918 # accordingly.
1919 ac_fn_c_check_header_mongrel ()
1921 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1922 if eval \${$3+:} false; then :
1923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1924 $as_echo_n "checking for $2... " >&6; }
1925 if eval \${$3+:} false; then :
1926 $as_echo_n "(cached) " >&6
1928 eval ac_res=\$$3
1929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1930 $as_echo "$ac_res" >&6; }
1931 else
1932 # Is the header compilable?
1933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1934 $as_echo_n "checking $2 usability... " >&6; }
1935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1936 /* end confdefs.h. */
1938 #include <$2>
1939 _ACEOF
1940 if ac_fn_c_try_compile "$LINENO"; then :
1941 ac_header_compiler=yes
1942 else
1943 ac_header_compiler=no
1945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1947 $as_echo "$ac_header_compiler" >&6; }
1949 # Is the header present?
1950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1951 $as_echo_n "checking $2 presence... " >&6; }
1952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1953 /* end confdefs.h. */
1954 #include <$2>
1955 _ACEOF
1956 if ac_fn_c_try_cpp "$LINENO"; then :
1957 ac_header_preproc=yes
1958 else
1959 ac_header_preproc=no
1961 rm -f conftest.err conftest.i conftest.$ac_ext
1962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1963 $as_echo "$ac_header_preproc" >&6; }
1965 # So? What about this header?
1966 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1967 yes:no: )
1968 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1969 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1970 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1971 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1973 no:yes:* )
1974 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1975 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1976 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1977 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1978 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1979 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1980 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1981 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1982 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1983 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1985 esac
1986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1987 $as_echo_n "checking for $2... " >&6; }
1988 if eval \${$3+:} false; then :
1989 $as_echo_n "(cached) " >&6
1990 else
1991 eval "$3=\$ac_header_compiler"
1993 eval ac_res=\$$3
1994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1995 $as_echo "$ac_res" >&6; }
1997 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1999 } # ac_fn_c_check_header_mongrel
2001 # ac_fn_c_try_run LINENO
2002 # ----------------------
2003 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2004 # that executables *can* be run.
2005 ac_fn_c_try_run ()
2007 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2008 if { { ac_try="$ac_link"
2009 case "(($ac_try" in
2010 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2011 *) ac_try_echo=$ac_try;;
2012 esac
2013 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2014 $as_echo "$ac_try_echo"; } >&5
2015 (eval "$ac_link") 2>&5
2016 ac_status=$?
2017 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2018 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2019 { { case "(($ac_try" in
2020 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2021 *) ac_try_echo=$ac_try;;
2022 esac
2023 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2024 $as_echo "$ac_try_echo"; } >&5
2025 (eval "$ac_try") 2>&5
2026 ac_status=$?
2027 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2028 test $ac_status = 0; }; }; then :
2029 ac_retval=0
2030 else
2031 $as_echo "$as_me: program exited with status $ac_status" >&5
2032 $as_echo "$as_me: failed program was:" >&5
2033 sed 's/^/| /' conftest.$ac_ext >&5
2035 ac_retval=$ac_status
2037 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2038 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2039 as_fn_set_status $ac_retval
2041 } # ac_fn_c_try_run
2043 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2044 # -------------------------------------------------------
2045 # Tests whether HEADER exists and can be compiled using the include files in
2046 # INCLUDES, setting the cache variable VAR accordingly.
2047 ac_fn_c_check_header_compile ()
2049 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2051 $as_echo_n "checking for $2... " >&6; }
2052 if eval \${$3+:} false; then :
2053 $as_echo_n "(cached) " >&6
2054 else
2055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2056 /* end confdefs.h. */
2058 #include <$2>
2059 _ACEOF
2060 if ac_fn_c_try_compile "$LINENO"; then :
2061 eval "$3=yes"
2062 else
2063 eval "$3=no"
2065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2067 eval ac_res=\$$3
2068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2069 $as_echo "$ac_res" >&6; }
2070 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2072 } # ac_fn_c_check_header_compile
2074 # ac_fn_c_try_link LINENO
2075 # -----------------------
2076 # Try to link conftest.$ac_ext, and return whether this succeeded.
2077 ac_fn_c_try_link ()
2079 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2080 rm -f conftest.$ac_objext conftest$ac_exeext
2081 if { { ac_try="$ac_link"
2082 case "(($ac_try" in
2083 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2084 *) ac_try_echo=$ac_try;;
2085 esac
2086 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2087 $as_echo "$ac_try_echo"; } >&5
2088 (eval "$ac_link") 2>conftest.err
2089 ac_status=$?
2090 if test -s conftest.err; then
2091 grep -v '^ *+' conftest.err >conftest.er1
2092 cat conftest.er1 >&5
2093 mv -f conftest.er1 conftest.err
2095 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2096 test $ac_status = 0; } && {
2097 test -z "$ac_c_werror_flag" ||
2098 test ! -s conftest.err
2099 } && test -s conftest$ac_exeext && {
2100 test "$cross_compiling" = yes ||
2101 test -x conftest$ac_exeext
2102 }; then :
2103 ac_retval=0
2104 else
2105 $as_echo "$as_me: failed program was:" >&5
2106 sed 's/^/| /' conftest.$ac_ext >&5
2108 ac_retval=1
2110 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2111 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2112 # interfere with the next link command; also delete a directory that is
2113 # left behind by Apple's compiler. We do this before executing the actions.
2114 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2115 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2116 as_fn_set_status $ac_retval
2118 } # ac_fn_c_try_link
2120 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2121 # --------------------------------------------
2122 # Tries to find the compile-time value of EXPR in a program that includes
2123 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2124 # computed
2125 ac_fn_c_compute_int ()
2127 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2128 if test "$cross_compiling" = yes; then
2129 # Depending upon the size, compute the lo and hi bounds.
2130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2131 /* end confdefs.h. */
2134 main ()
2136 static int test_array [1 - 2 * !(($2) >= 0)];
2137 test_array [0] = 0;
2138 return test_array [0];
2141 return 0;
2143 _ACEOF
2144 if ac_fn_c_try_compile "$LINENO"; then :
2145 ac_lo=0 ac_mid=0
2146 while :; do
2147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2148 /* end confdefs.h. */
2151 main ()
2153 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2154 test_array [0] = 0;
2155 return test_array [0];
2158 return 0;
2160 _ACEOF
2161 if ac_fn_c_try_compile "$LINENO"; then :
2162 ac_hi=$ac_mid; break
2163 else
2164 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2165 if test $ac_lo -le $ac_mid; then
2166 ac_lo= ac_hi=
2167 break
2169 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2172 done
2173 else
2174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2175 /* end confdefs.h. */
2178 main ()
2180 static int test_array [1 - 2 * !(($2) < 0)];
2181 test_array [0] = 0;
2182 return test_array [0];
2185 return 0;
2187 _ACEOF
2188 if ac_fn_c_try_compile "$LINENO"; then :
2189 ac_hi=-1 ac_mid=-1
2190 while :; do
2191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2192 /* end confdefs.h. */
2195 main ()
2197 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2198 test_array [0] = 0;
2199 return test_array [0];
2202 return 0;
2204 _ACEOF
2205 if ac_fn_c_try_compile "$LINENO"; then :
2206 ac_lo=$ac_mid; break
2207 else
2208 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2209 if test $ac_mid -le $ac_hi; then
2210 ac_lo= ac_hi=
2211 break
2213 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2215 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2216 done
2217 else
2218 ac_lo= ac_hi=
2220 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2222 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2223 # Binary search between lo and hi bounds.
2224 while test "x$ac_lo" != "x$ac_hi"; do
2225 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2227 /* end confdefs.h. */
2230 main ()
2232 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2233 test_array [0] = 0;
2234 return test_array [0];
2237 return 0;
2239 _ACEOF
2240 if ac_fn_c_try_compile "$LINENO"; then :
2241 ac_hi=$ac_mid
2242 else
2243 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2245 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2246 done
2247 case $ac_lo in #((
2248 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2249 '') ac_retval=1 ;;
2250 esac
2251 else
2252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2253 /* end confdefs.h. */
2255 static long int longval () { return $2; }
2256 static unsigned long int ulongval () { return $2; }
2257 #include <stdio.h>
2258 #include <stdlib.h>
2260 main ()
2263 FILE *f = fopen ("conftest.val", "w");
2264 if (! f)
2265 return 1;
2266 if (($2) < 0)
2268 long int i = longval ();
2269 if (i != ($2))
2270 return 1;
2271 fprintf (f, "%ld", i);
2273 else
2275 unsigned long int i = ulongval ();
2276 if (i != ($2))
2277 return 1;
2278 fprintf (f, "%lu", i);
2280 /* Do not output a trailing newline, as this causes \r\n confusion
2281 on some platforms. */
2282 return ferror (f) || fclose (f) != 0;
2285 return 0;
2287 _ACEOF
2288 if ac_fn_c_try_run "$LINENO"; then :
2289 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2290 else
2291 ac_retval=1
2293 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2294 conftest.$ac_objext conftest.beam conftest.$ac_ext
2295 rm -f conftest.val
2298 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2299 as_fn_set_status $ac_retval
2301 } # ac_fn_c_compute_int
2303 # ac_fn_c_check_func LINENO FUNC VAR
2304 # ----------------------------------
2305 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2306 ac_fn_c_check_func ()
2308 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2310 $as_echo_n "checking for $2... " >&6; }
2311 if eval \${$3+:} false; then :
2312 $as_echo_n "(cached) " >&6
2313 else
2314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2315 /* end confdefs.h. */
2316 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2317 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2318 #define $2 innocuous_$2
2320 /* System header to define __stub macros and hopefully few prototypes,
2321 which can conflict with char $2 (); below.
2322 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2323 <limits.h> exists even on freestanding compilers. */
2325 #ifdef __STDC__
2326 # include <limits.h>
2327 #else
2328 # include <assert.h>
2329 #endif
2331 #undef $2
2333 /* Override any GCC internal prototype to avoid an error.
2334 Use char because int might match the return type of a GCC
2335 builtin and then its argument prototype would still apply. */
2336 #ifdef __cplusplus
2337 extern "C"
2338 #endif
2339 char $2 ();
2340 /* The GNU C library defines this for functions which it implements
2341 to always fail with ENOSYS. Some functions are actually named
2342 something starting with __ and the normal name is an alias. */
2343 #if defined __stub_$2 || defined __stub___$2
2344 choke me
2345 #endif
2348 main ()
2350 return $2 ();
2352 return 0;
2354 _ACEOF
2355 if ac_fn_c_try_link "$LINENO"; then :
2356 eval "$3=yes"
2357 else
2358 eval "$3=no"
2360 rm -f core conftest.err conftest.$ac_objext \
2361 conftest$ac_exeext conftest.$ac_ext
2363 eval ac_res=\$$3
2364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2365 $as_echo "$ac_res" >&6; }
2366 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2368 } # ac_fn_c_check_func
2370 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2371 # -------------------------------------------
2372 # Tests whether TYPE exists after having included INCLUDES, setting cache
2373 # variable VAR accordingly.
2374 ac_fn_c_check_type ()
2376 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2378 $as_echo_n "checking for $2... " >&6; }
2379 if eval \${$3+:} false; then :
2380 $as_echo_n "(cached) " >&6
2381 else
2382 eval "$3=no"
2383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2384 /* end confdefs.h. */
2387 main ()
2389 if (sizeof ($2))
2390 return 0;
2392 return 0;
2394 _ACEOF
2395 if ac_fn_c_try_compile "$LINENO"; then :
2396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2397 /* end confdefs.h. */
2400 main ()
2402 if (sizeof (($2)))
2403 return 0;
2405 return 0;
2407 _ACEOF
2408 if ac_fn_c_try_compile "$LINENO"; then :
2410 else
2411 eval "$3=yes"
2413 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2417 eval ac_res=\$$3
2418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2419 $as_echo "$ac_res" >&6; }
2420 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2422 } # ac_fn_c_check_type
2424 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2425 # ---------------------------------------------
2426 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2427 # accordingly.
2428 ac_fn_c_check_decl ()
2430 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2431 as_decl_name=`echo $2|sed 's/ *(.*//'`
2432 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2434 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2435 if eval \${$3+:} false; then :
2436 $as_echo_n "(cached) " >&6
2437 else
2438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2439 /* end confdefs.h. */
2442 main ()
2444 #ifndef $as_decl_name
2445 #ifdef __cplusplus
2446 (void) $as_decl_use;
2447 #else
2448 (void) $as_decl_name;
2449 #endif
2450 #endif
2453 return 0;
2455 _ACEOF
2456 if ac_fn_c_try_compile "$LINENO"; then :
2457 eval "$3=yes"
2458 else
2459 eval "$3=no"
2461 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2463 eval ac_res=\$$3
2464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2465 $as_echo "$ac_res" >&6; }
2466 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2468 } # ac_fn_c_check_decl
2470 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2471 # ----------------------------------------------------
2472 # Tries to find if the field MEMBER exists in type AGGR, after including
2473 # INCLUDES, setting cache variable VAR accordingly.
2474 ac_fn_c_check_member ()
2476 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2478 $as_echo_n "checking for $2.$3... " >&6; }
2479 if eval \${$4+:} false; then :
2480 $as_echo_n "(cached) " >&6
2481 else
2482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2483 /* end confdefs.h. */
2486 main ()
2488 static $2 ac_aggr;
2489 if (ac_aggr.$3)
2490 return 0;
2492 return 0;
2494 _ACEOF
2495 if ac_fn_c_try_compile "$LINENO"; then :
2496 eval "$4=yes"
2497 else
2498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2499 /* end confdefs.h. */
2502 main ()
2504 static $2 ac_aggr;
2505 if (sizeof ac_aggr.$3)
2506 return 0;
2508 return 0;
2510 _ACEOF
2511 if ac_fn_c_try_compile "$LINENO"; then :
2512 eval "$4=yes"
2513 else
2514 eval "$4=no"
2516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2520 eval ac_res=\$$4
2521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2522 $as_echo "$ac_res" >&6; }
2523 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2525 } # ac_fn_c_check_member
2527 # ac_fn_cxx_try_link LINENO
2528 # -------------------------
2529 # Try to link conftest.$ac_ext, and return whether this succeeded.
2530 ac_fn_cxx_try_link ()
2532 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2533 rm -f conftest.$ac_objext conftest$ac_exeext
2534 if { { ac_try="$ac_link"
2535 case "(($ac_try" in
2536 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2537 *) ac_try_echo=$ac_try;;
2538 esac
2539 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2540 $as_echo "$ac_try_echo"; } >&5
2541 (eval "$ac_link") 2>conftest.err
2542 ac_status=$?
2543 if test -s conftest.err; then
2544 grep -v '^ *+' conftest.err >conftest.er1
2545 cat conftest.er1 >&5
2546 mv -f conftest.er1 conftest.err
2548 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2549 test $ac_status = 0; } && {
2550 test -z "$ac_cxx_werror_flag" ||
2551 test ! -s conftest.err
2552 } && test -s conftest$ac_exeext && {
2553 test "$cross_compiling" = yes ||
2554 test -x conftest$ac_exeext
2555 }; then :
2556 ac_retval=0
2557 else
2558 $as_echo "$as_me: failed program was:" >&5
2559 sed 's/^/| /' conftest.$ac_ext >&5
2561 ac_retval=1
2563 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2564 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2565 # interfere with the next link command; also delete a directory that is
2566 # left behind by Apple's compiler. We do this before executing the actions.
2567 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2568 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2569 as_fn_set_status $ac_retval
2571 } # ac_fn_cxx_try_link
2573 # ac_fn_cxx_check_func LINENO FUNC VAR
2574 # ------------------------------------
2575 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2576 ac_fn_cxx_check_func ()
2578 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2580 $as_echo_n "checking for $2... " >&6; }
2581 if eval \${$3+:} false; then :
2582 $as_echo_n "(cached) " >&6
2583 else
2584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2585 /* end confdefs.h. */
2586 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2587 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2588 #define $2 innocuous_$2
2590 /* System header to define __stub macros and hopefully few prototypes,
2591 which can conflict with char $2 (); below.
2592 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2593 <limits.h> exists even on freestanding compilers. */
2595 #ifdef __STDC__
2596 # include <limits.h>
2597 #else
2598 # include <assert.h>
2599 #endif
2601 #undef $2
2603 /* Override any GCC internal prototype to avoid an error.
2604 Use char because int might match the return type of a GCC
2605 builtin and then its argument prototype would still apply. */
2606 #ifdef __cplusplus
2607 extern "C"
2608 #endif
2609 char $2 ();
2610 /* The GNU C library defines this for functions which it implements
2611 to always fail with ENOSYS. Some functions are actually named
2612 something starting with __ and the normal name is an alias. */
2613 #if defined __stub_$2 || defined __stub___$2
2614 choke me
2615 #endif
2618 main ()
2620 return $2 ();
2622 return 0;
2624 _ACEOF
2625 if ac_fn_cxx_try_link "$LINENO"; then :
2626 eval "$3=yes"
2627 else
2628 eval "$3=no"
2630 rm -f core conftest.err conftest.$ac_objext \
2631 conftest$ac_exeext conftest.$ac_ext
2633 eval ac_res=\$$3
2634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2635 $as_echo "$ac_res" >&6; }
2636 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2638 } # ac_fn_cxx_check_func
2639 cat >config.log <<_ACEOF
2640 This file contains any messages produced by compilers while
2641 running configure, to aid debugging if configure makes a mistake.
2643 It was created by $as_me, which was
2644 generated by GNU Autoconf 2.69. Invocation command line was
2646 $ $0 $@
2648 _ACEOF
2649 exec 5>>config.log
2651 cat <<_ASUNAME
2652 ## --------- ##
2653 ## Platform. ##
2654 ## --------- ##
2656 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2657 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2658 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2659 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2660 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2662 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2663 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2665 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2666 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2667 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2668 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2669 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2670 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2671 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2673 _ASUNAME
2675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2676 for as_dir in $PATH
2678 IFS=$as_save_IFS
2679 test -z "$as_dir" && as_dir=.
2680 $as_echo "PATH: $as_dir"
2681 done
2682 IFS=$as_save_IFS
2684 } >&5
2686 cat >&5 <<_ACEOF
2689 ## ----------- ##
2690 ## Core tests. ##
2691 ## ----------- ##
2693 _ACEOF
2696 # Keep a trace of the command line.
2697 # Strip out --no-create and --no-recursion so they do not pile up.
2698 # Strip out --silent because we don't want to record it for future runs.
2699 # Also quote any args containing shell meta-characters.
2700 # Make two passes to allow for proper duplicate-argument suppression.
2701 ac_configure_args=
2702 ac_configure_args0=
2703 ac_configure_args1=
2704 ac_must_keep_next=false
2705 for ac_pass in 1 2
2707 for ac_arg
2709 case $ac_arg in
2710 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2711 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2712 | -silent | --silent | --silen | --sile | --sil)
2713 continue ;;
2714 *\'*)
2715 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2716 esac
2717 case $ac_pass in
2718 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2720 as_fn_append ac_configure_args1 " '$ac_arg'"
2721 if test $ac_must_keep_next = true; then
2722 ac_must_keep_next=false # Got value, back to normal.
2723 else
2724 case $ac_arg in
2725 *=* | --config-cache | -C | -disable-* | --disable-* \
2726 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2727 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2728 | -with-* | --with-* | -without-* | --without-* | --x)
2729 case "$ac_configure_args0 " in
2730 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2731 esac
2733 -* ) ac_must_keep_next=true ;;
2734 esac
2736 as_fn_append ac_configure_args " '$ac_arg'"
2738 esac
2739 done
2740 done
2741 { ac_configure_args0=; unset ac_configure_args0;}
2742 { ac_configure_args1=; unset ac_configure_args1;}
2744 # When interrupted or exit'd, cleanup temporary files, and complete
2745 # config.log. We remove comments because anyway the quotes in there
2746 # would cause problems or look ugly.
2747 # WARNING: Use '\'' to represent an apostrophe within the trap.
2748 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2749 trap 'exit_status=$?
2750 # Save into config.log some information that might help in debugging.
2752 echo
2754 $as_echo "## ---------------- ##
2755 ## Cache variables. ##
2756 ## ---------------- ##"
2757 echo
2758 # The following way of writing the cache mishandles newlines in values,
2760 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2761 eval ac_val=\$$ac_var
2762 case $ac_val in #(
2763 *${as_nl}*)
2764 case $ac_var in #(
2765 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2766 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2767 esac
2768 case $ac_var in #(
2769 _ | IFS | as_nl) ;; #(
2770 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2771 *) { eval $ac_var=; unset $ac_var;} ;;
2772 esac ;;
2773 esac
2774 done
2775 (set) 2>&1 |
2776 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2777 *${as_nl}ac_space=\ *)
2778 sed -n \
2779 "s/'\''/'\''\\\\'\'''\''/g;
2780 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2781 ;; #(
2783 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2785 esac |
2786 sort
2788 echo
2790 $as_echo "## ----------------- ##
2791 ## Output variables. ##
2792 ## ----------------- ##"
2793 echo
2794 for ac_var in $ac_subst_vars
2796 eval ac_val=\$$ac_var
2797 case $ac_val in
2798 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2799 esac
2800 $as_echo "$ac_var='\''$ac_val'\''"
2801 done | sort
2802 echo
2804 if test -n "$ac_subst_files"; then
2805 $as_echo "## ------------------- ##
2806 ## File substitutions. ##
2807 ## ------------------- ##"
2808 echo
2809 for ac_var in $ac_subst_files
2811 eval ac_val=\$$ac_var
2812 case $ac_val in
2813 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2814 esac
2815 $as_echo "$ac_var='\''$ac_val'\''"
2816 done | sort
2817 echo
2820 if test -s confdefs.h; then
2821 $as_echo "## ----------- ##
2822 ## confdefs.h. ##
2823 ## ----------- ##"
2824 echo
2825 cat confdefs.h
2826 echo
2828 test "$ac_signal" != 0 &&
2829 $as_echo "$as_me: caught signal $ac_signal"
2830 $as_echo "$as_me: exit $exit_status"
2831 } >&5
2832 rm -f core *.core core.conftest.* &&
2833 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2834 exit $exit_status
2836 for ac_signal in 1 2 13 15; do
2837 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2838 done
2839 ac_signal=0
2841 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2842 rm -f -r conftest* confdefs.h
2844 $as_echo "/* confdefs.h */" > confdefs.h
2846 # Predefined preprocessor variables.
2848 cat >>confdefs.h <<_ACEOF
2849 #define PACKAGE_NAME "$PACKAGE_NAME"
2850 _ACEOF
2852 cat >>confdefs.h <<_ACEOF
2853 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2854 _ACEOF
2856 cat >>confdefs.h <<_ACEOF
2857 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2858 _ACEOF
2860 cat >>confdefs.h <<_ACEOF
2861 #define PACKAGE_STRING "$PACKAGE_STRING"
2862 _ACEOF
2864 cat >>confdefs.h <<_ACEOF
2865 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2866 _ACEOF
2868 cat >>confdefs.h <<_ACEOF
2869 #define PACKAGE_URL "$PACKAGE_URL"
2870 _ACEOF
2873 # Let the site file select an alternate cache file if it wants to.
2874 # Prefer an explicitly selected file to automatically selected ones.
2875 ac_site_file1=NONE
2876 ac_site_file2=NONE
2877 if test -n "$CONFIG_SITE"; then
2878 # We do not want a PATH search for config.site.
2879 case $CONFIG_SITE in #((
2880 -*) ac_site_file1=./$CONFIG_SITE;;
2881 */*) ac_site_file1=$CONFIG_SITE;;
2882 *) ac_site_file1=./$CONFIG_SITE;;
2883 esac
2884 elif test "x$prefix" != xNONE; then
2885 ac_site_file1=$prefix/share/config.site
2886 ac_site_file2=$prefix/etc/config.site
2887 else
2888 ac_site_file1=$ac_default_prefix/share/config.site
2889 ac_site_file2=$ac_default_prefix/etc/config.site
2891 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2893 test "x$ac_site_file" = xNONE && continue
2894 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2895 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2896 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2897 sed 's/^/| /' "$ac_site_file" >&5
2898 . "$ac_site_file" \
2899 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2900 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2901 as_fn_error $? "failed to load site script $ac_site_file
2902 See \`config.log' for more details" "$LINENO" 5; }
2904 done
2906 if test -r "$cache_file"; then
2907 # Some versions of bash will fail to source /dev/null (special files
2908 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2909 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2910 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2911 $as_echo "$as_me: loading cache $cache_file" >&6;}
2912 case $cache_file in
2913 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2914 *) . "./$cache_file";;
2915 esac
2917 else
2918 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2919 $as_echo "$as_me: creating cache $cache_file" >&6;}
2920 >$cache_file
2923 as_fn_append ac_header_list " stdlib.h"
2924 as_fn_append ac_header_list " unistd.h"
2925 as_fn_append ac_header_list " sys/param.h"
2926 # Check that the precious variables saved in the cache have kept the same
2927 # value.
2928 ac_cache_corrupted=false
2929 for ac_var in $ac_precious_vars; do
2930 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2931 eval ac_new_set=\$ac_env_${ac_var}_set
2932 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2933 eval ac_new_val=\$ac_env_${ac_var}_value
2934 case $ac_old_set,$ac_new_set in
2935 set,)
2936 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2937 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2938 ac_cache_corrupted=: ;;
2939 ,set)
2940 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2941 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2942 ac_cache_corrupted=: ;;
2943 ,);;
2945 if test "x$ac_old_val" != "x$ac_new_val"; then
2946 # differences in whitespace do not lead to failure.
2947 ac_old_val_w=`echo x $ac_old_val`
2948 ac_new_val_w=`echo x $ac_new_val`
2949 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2950 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2951 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2952 ac_cache_corrupted=:
2953 else
2954 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2955 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2956 eval $ac_var=\$ac_old_val
2958 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2959 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2960 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2961 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2962 fi;;
2963 esac
2964 # Pass precious variables to config.status.
2965 if test "$ac_new_set" = set; then
2966 case $ac_new_val in
2967 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2968 *) ac_arg=$ac_var=$ac_new_val ;;
2969 esac
2970 case " $ac_configure_args " in
2971 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2972 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2973 esac
2975 done
2976 if $ac_cache_corrupted; then
2977 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2978 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2979 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2980 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2981 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2983 ## -------------------- ##
2984 ## Main body of script. ##
2985 ## -------------------- ##
2987 ac_ext=c
2988 ac_cpp='$CPP $CPPFLAGS'
2989 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2990 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2991 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2998 ac_config_headers="$ac_config_headers config.h:config.in"
3001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3002 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3003 # Check whether --enable-maintainer-mode was given.
3004 if test "${enable_maintainer_mode+set}" = set; then :
3005 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3006 else
3007 USE_MAINTAINER_MODE=no
3010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3011 $as_echo "$USE_MAINTAINER_MODE" >&6; }
3012 if test $USE_MAINTAINER_MODE = yes; then
3013 MAINTAINER_MODE_TRUE=
3014 MAINTAINER_MODE_FALSE='#'
3015 else
3016 MAINTAINER_MODE_TRUE='#'
3017 MAINTAINER_MODE_FALSE=
3020 MAINT=$MAINTAINER_MODE_TRUE
3024 ac_ext=c
3025 ac_cpp='$CPP $CPPFLAGS'
3026 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3027 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3028 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3029 if test -n "$ac_tool_prefix"; then
3030 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3031 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3033 $as_echo_n "checking for $ac_word... " >&6; }
3034 if ${ac_cv_prog_CC+:} false; then :
3035 $as_echo_n "(cached) " >&6
3036 else
3037 if test -n "$CC"; then
3038 ac_cv_prog_CC="$CC" # Let the user override the test.
3039 else
3040 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3041 for as_dir in $PATH
3043 IFS=$as_save_IFS
3044 test -z "$as_dir" && as_dir=.
3045 for ac_exec_ext in '' $ac_executable_extensions; do
3046 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3047 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3048 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3049 break 2
3051 done
3052 done
3053 IFS=$as_save_IFS
3057 CC=$ac_cv_prog_CC
3058 if test -n "$CC"; then
3059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3060 $as_echo "$CC" >&6; }
3061 else
3062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3063 $as_echo "no" >&6; }
3068 if test -z "$ac_cv_prog_CC"; then
3069 ac_ct_CC=$CC
3070 # Extract the first word of "gcc", so it can be a program name with args.
3071 set dummy gcc; ac_word=$2
3072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3073 $as_echo_n "checking for $ac_word... " >&6; }
3074 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3075 $as_echo_n "(cached) " >&6
3076 else
3077 if test -n "$ac_ct_CC"; then
3078 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3079 else
3080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3081 for as_dir in $PATH
3083 IFS=$as_save_IFS
3084 test -z "$as_dir" && as_dir=.
3085 for ac_exec_ext in '' $ac_executable_extensions; do
3086 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3087 ac_cv_prog_ac_ct_CC="gcc"
3088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3089 break 2
3091 done
3092 done
3093 IFS=$as_save_IFS
3097 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3098 if test -n "$ac_ct_CC"; then
3099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3100 $as_echo "$ac_ct_CC" >&6; }
3101 else
3102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3103 $as_echo "no" >&6; }
3106 if test "x$ac_ct_CC" = x; then
3107 CC=""
3108 else
3109 case $cross_compiling:$ac_tool_warned in
3110 yes:)
3111 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3112 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3113 ac_tool_warned=yes ;;
3114 esac
3115 CC=$ac_ct_CC
3117 else
3118 CC="$ac_cv_prog_CC"
3121 if test -z "$CC"; then
3122 if test -n "$ac_tool_prefix"; then
3123 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3124 set dummy ${ac_tool_prefix}cc; ac_word=$2
3125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3126 $as_echo_n "checking for $ac_word... " >&6; }
3127 if ${ac_cv_prog_CC+:} false; then :
3128 $as_echo_n "(cached) " >&6
3129 else
3130 if test -n "$CC"; then
3131 ac_cv_prog_CC="$CC" # Let the user override the test.
3132 else
3133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3134 for as_dir in $PATH
3136 IFS=$as_save_IFS
3137 test -z "$as_dir" && as_dir=.
3138 for ac_exec_ext in '' $ac_executable_extensions; do
3139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3140 ac_cv_prog_CC="${ac_tool_prefix}cc"
3141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3142 break 2
3144 done
3145 done
3146 IFS=$as_save_IFS
3150 CC=$ac_cv_prog_CC
3151 if test -n "$CC"; then
3152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3153 $as_echo "$CC" >&6; }
3154 else
3155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3156 $as_echo "no" >&6; }
3162 if test -z "$CC"; then
3163 # Extract the first word of "cc", so it can be a program name with args.
3164 set dummy cc; ac_word=$2
3165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3166 $as_echo_n "checking for $ac_word... " >&6; }
3167 if ${ac_cv_prog_CC+:} false; then :
3168 $as_echo_n "(cached) " >&6
3169 else
3170 if test -n "$CC"; then
3171 ac_cv_prog_CC="$CC" # Let the user override the test.
3172 else
3173 ac_prog_rejected=no
3174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3175 for as_dir in $PATH
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 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3182 ac_prog_rejected=yes
3183 continue
3185 ac_cv_prog_CC="cc"
3186 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3187 break 2
3189 done
3190 done
3191 IFS=$as_save_IFS
3193 if test $ac_prog_rejected = yes; then
3194 # We found a bogon in the path, so make sure we never use it.
3195 set dummy $ac_cv_prog_CC
3196 shift
3197 if test $# != 0; then
3198 # We chose a different compiler from the bogus one.
3199 # However, it has the same basename, so the bogon will be chosen
3200 # first if we set CC to just the basename; use the full file name.
3201 shift
3202 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3207 CC=$ac_cv_prog_CC
3208 if test -n "$CC"; then
3209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3210 $as_echo "$CC" >&6; }
3211 else
3212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3213 $as_echo "no" >&6; }
3218 if test -z "$CC"; then
3219 if test -n "$ac_tool_prefix"; then
3220 for ac_prog in cl.exe
3222 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3223 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3225 $as_echo_n "checking for $ac_word... " >&6; }
3226 if ${ac_cv_prog_CC+:} false; then :
3227 $as_echo_n "(cached) " >&6
3228 else
3229 if test -n "$CC"; then
3230 ac_cv_prog_CC="$CC" # Let the user override the test.
3231 else
3232 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3233 for as_dir in $PATH
3235 IFS=$as_save_IFS
3236 test -z "$as_dir" && as_dir=.
3237 for ac_exec_ext in '' $ac_executable_extensions; do
3238 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3239 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3240 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3241 break 2
3243 done
3244 done
3245 IFS=$as_save_IFS
3249 CC=$ac_cv_prog_CC
3250 if test -n "$CC"; then
3251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3252 $as_echo "$CC" >&6; }
3253 else
3254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3255 $as_echo "no" >&6; }
3259 test -n "$CC" && break
3260 done
3262 if test -z "$CC"; then
3263 ac_ct_CC=$CC
3264 for ac_prog in cl.exe
3266 # Extract the first word of "$ac_prog", so it can be a program name with args.
3267 set dummy $ac_prog; ac_word=$2
3268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3269 $as_echo_n "checking for $ac_word... " >&6; }
3270 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3271 $as_echo_n "(cached) " >&6
3272 else
3273 if test -n "$ac_ct_CC"; then
3274 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3275 else
3276 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3277 for as_dir in $PATH
3279 IFS=$as_save_IFS
3280 test -z "$as_dir" && as_dir=.
3281 for ac_exec_ext in '' $ac_executable_extensions; do
3282 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3283 ac_cv_prog_ac_ct_CC="$ac_prog"
3284 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3285 break 2
3287 done
3288 done
3289 IFS=$as_save_IFS
3293 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3294 if test -n "$ac_ct_CC"; then
3295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3296 $as_echo "$ac_ct_CC" >&6; }
3297 else
3298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3299 $as_echo "no" >&6; }
3303 test -n "$ac_ct_CC" && break
3304 done
3306 if test "x$ac_ct_CC" = x; then
3307 CC=""
3308 else
3309 case $cross_compiling:$ac_tool_warned in
3310 yes:)
3311 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3312 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3313 ac_tool_warned=yes ;;
3314 esac
3315 CC=$ac_ct_CC
3322 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3323 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3324 as_fn_error $? "no acceptable C compiler found in \$PATH
3325 See \`config.log' for more details" "$LINENO" 5; }
3327 # Provide some information about the compiler.
3328 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3329 set X $ac_compile
3330 ac_compiler=$2
3331 for ac_option in --version -v -V -qversion; do
3332 { { ac_try="$ac_compiler $ac_option >&5"
3333 case "(($ac_try" in
3334 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3335 *) ac_try_echo=$ac_try;;
3336 esac
3337 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3338 $as_echo "$ac_try_echo"; } >&5
3339 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3340 ac_status=$?
3341 if test -s conftest.err; then
3342 sed '10a\
3343 ... rest of stderr output deleted ...
3344 10q' conftest.err >conftest.er1
3345 cat conftest.er1 >&5
3347 rm -f conftest.er1 conftest.err
3348 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3349 test $ac_status = 0; }
3350 done
3352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3353 /* end confdefs.h. */
3356 main ()
3360 return 0;
3362 _ACEOF
3363 ac_clean_files_save=$ac_clean_files
3364 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3365 # Try to create an executable without -o first, disregard a.out.
3366 # It will help us diagnose broken compilers, and finding out an intuition
3367 # of exeext.
3368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3369 $as_echo_n "checking whether the C compiler works... " >&6; }
3370 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3372 # The possible output files:
3373 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3375 ac_rmfiles=
3376 for ac_file in $ac_files
3378 case $ac_file in
3379 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3380 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3381 esac
3382 done
3383 rm -f $ac_rmfiles
3385 if { { ac_try="$ac_link_default"
3386 case "(($ac_try" in
3387 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3388 *) ac_try_echo=$ac_try;;
3389 esac
3390 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3391 $as_echo "$ac_try_echo"; } >&5
3392 (eval "$ac_link_default") 2>&5
3393 ac_status=$?
3394 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3395 test $ac_status = 0; }; then :
3396 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3397 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3398 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3399 # so that the user can short-circuit this test for compilers unknown to
3400 # Autoconf.
3401 for ac_file in $ac_files ''
3403 test -f "$ac_file" || continue
3404 case $ac_file in
3405 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3407 [ab].out )
3408 # We found the default executable, but exeext='' is most
3409 # certainly right.
3410 break;;
3411 *.* )
3412 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3413 then :; else
3414 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3416 # We set ac_cv_exeext here because the later test for it is not
3417 # safe: cross compilers may not add the suffix if given an `-o'
3418 # argument, so we may need to know it at that point already.
3419 # Even if this section looks crufty: it has the advantage of
3420 # actually working.
3421 break;;
3423 break;;
3424 esac
3425 done
3426 test "$ac_cv_exeext" = no && ac_cv_exeext=
3428 else
3429 ac_file=''
3431 if test -z "$ac_file"; then :
3432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3433 $as_echo "no" >&6; }
3434 $as_echo "$as_me: failed program was:" >&5
3435 sed 's/^/| /' conftest.$ac_ext >&5
3437 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3438 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3439 as_fn_error 77 "C compiler cannot create executables
3440 See \`config.log' for more details" "$LINENO" 5; }
3441 else
3442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3443 $as_echo "yes" >&6; }
3445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3446 $as_echo_n "checking for C compiler default output file name... " >&6; }
3447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3448 $as_echo "$ac_file" >&6; }
3449 ac_exeext=$ac_cv_exeext
3451 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3452 ac_clean_files=$ac_clean_files_save
3453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3454 $as_echo_n "checking for suffix of executables... " >&6; }
3455 if { { ac_try="$ac_link"
3456 case "(($ac_try" in
3457 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3458 *) ac_try_echo=$ac_try;;
3459 esac
3460 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3461 $as_echo "$ac_try_echo"; } >&5
3462 (eval "$ac_link") 2>&5
3463 ac_status=$?
3464 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3465 test $ac_status = 0; }; then :
3466 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3467 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3468 # work properly (i.e., refer to `conftest.exe'), while it won't with
3469 # `rm'.
3470 for ac_file in conftest.exe conftest conftest.*; do
3471 test -f "$ac_file" || continue
3472 case $ac_file in
3473 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3474 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3475 break;;
3476 * ) break;;
3477 esac
3478 done
3479 else
3480 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3481 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3482 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3483 See \`config.log' for more details" "$LINENO" 5; }
3485 rm -f conftest conftest$ac_cv_exeext
3486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3487 $as_echo "$ac_cv_exeext" >&6; }
3489 rm -f conftest.$ac_ext
3490 EXEEXT=$ac_cv_exeext
3491 ac_exeext=$EXEEXT
3492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3493 /* end confdefs.h. */
3494 #include <stdio.h>
3496 main ()
3498 FILE *f = fopen ("conftest.out", "w");
3499 return ferror (f) || fclose (f) != 0;
3502 return 0;
3504 _ACEOF
3505 ac_clean_files="$ac_clean_files conftest.out"
3506 # Check that the compiler produces executables we can run. If not, either
3507 # the compiler is broken, or we cross compile.
3508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3509 $as_echo_n "checking whether we are cross compiling... " >&6; }
3510 if test "$cross_compiling" != yes; then
3511 { { ac_try="$ac_link"
3512 case "(($ac_try" in
3513 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3514 *) ac_try_echo=$ac_try;;
3515 esac
3516 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3517 $as_echo "$ac_try_echo"; } >&5
3518 (eval "$ac_link") 2>&5
3519 ac_status=$?
3520 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3521 test $ac_status = 0; }
3522 if { ac_try='./conftest$ac_cv_exeext'
3523 { { case "(($ac_try" in
3524 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3525 *) ac_try_echo=$ac_try;;
3526 esac
3527 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3528 $as_echo "$ac_try_echo"; } >&5
3529 (eval "$ac_try") 2>&5
3530 ac_status=$?
3531 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3532 test $ac_status = 0; }; }; then
3533 cross_compiling=no
3534 else
3535 if test "$cross_compiling" = maybe; then
3536 cross_compiling=yes
3537 else
3538 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3539 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3540 as_fn_error $? "cannot run C compiled programs.
3541 If you meant to cross compile, use \`--host'.
3542 See \`config.log' for more details" "$LINENO" 5; }
3546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3547 $as_echo "$cross_compiling" >&6; }
3549 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3550 ac_clean_files=$ac_clean_files_save
3551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3552 $as_echo_n "checking for suffix of object files... " >&6; }
3553 if ${ac_cv_objext+:} false; then :
3554 $as_echo_n "(cached) " >&6
3555 else
3556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3557 /* end confdefs.h. */
3560 main ()
3564 return 0;
3566 _ACEOF
3567 rm -f conftest.o conftest.obj
3568 if { { ac_try="$ac_compile"
3569 case "(($ac_try" in
3570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3571 *) ac_try_echo=$ac_try;;
3572 esac
3573 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3574 $as_echo "$ac_try_echo"; } >&5
3575 (eval "$ac_compile") 2>&5
3576 ac_status=$?
3577 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3578 test $ac_status = 0; }; then :
3579 for ac_file in conftest.o conftest.obj conftest.*; do
3580 test -f "$ac_file" || continue;
3581 case $ac_file in
3582 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3583 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3584 break;;
3585 esac
3586 done
3587 else
3588 $as_echo "$as_me: failed program was:" >&5
3589 sed 's/^/| /' conftest.$ac_ext >&5
3591 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3592 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3593 as_fn_error $? "cannot compute suffix of object files: cannot compile
3594 See \`config.log' for more details" "$LINENO" 5; }
3596 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3599 $as_echo "$ac_cv_objext" >&6; }
3600 OBJEXT=$ac_cv_objext
3601 ac_objext=$OBJEXT
3602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3603 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3604 if ${ac_cv_c_compiler_gnu+:} false; then :
3605 $as_echo_n "(cached) " >&6
3606 else
3607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3608 /* end confdefs.h. */
3611 main ()
3613 #ifndef __GNUC__
3614 choke me
3615 #endif
3618 return 0;
3620 _ACEOF
3621 if ac_fn_c_try_compile "$LINENO"; then :
3622 ac_compiler_gnu=yes
3623 else
3624 ac_compiler_gnu=no
3626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3627 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3631 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3632 if test $ac_compiler_gnu = yes; then
3633 GCC=yes
3634 else
3635 GCC=
3637 ac_test_CFLAGS=${CFLAGS+set}
3638 ac_save_CFLAGS=$CFLAGS
3639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3640 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3641 if ${ac_cv_prog_cc_g+:} false; then :
3642 $as_echo_n "(cached) " >&6
3643 else
3644 ac_save_c_werror_flag=$ac_c_werror_flag
3645 ac_c_werror_flag=yes
3646 ac_cv_prog_cc_g=no
3647 CFLAGS="-g"
3648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3649 /* end confdefs.h. */
3652 main ()
3656 return 0;
3658 _ACEOF
3659 if ac_fn_c_try_compile "$LINENO"; then :
3660 ac_cv_prog_cc_g=yes
3661 else
3662 CFLAGS=""
3663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3664 /* end confdefs.h. */
3667 main ()
3671 return 0;
3673 _ACEOF
3674 if ac_fn_c_try_compile "$LINENO"; then :
3676 else
3677 ac_c_werror_flag=$ac_save_c_werror_flag
3678 CFLAGS="-g"
3679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3680 /* end confdefs.h. */
3683 main ()
3687 return 0;
3689 _ACEOF
3690 if ac_fn_c_try_compile "$LINENO"; then :
3691 ac_cv_prog_cc_g=yes
3693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3698 ac_c_werror_flag=$ac_save_c_werror_flag
3700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3701 $as_echo "$ac_cv_prog_cc_g" >&6; }
3702 if test "$ac_test_CFLAGS" = set; then
3703 CFLAGS=$ac_save_CFLAGS
3704 elif test $ac_cv_prog_cc_g = yes; then
3705 if test "$GCC" = yes; then
3706 CFLAGS="-g -O2"
3707 else
3708 CFLAGS="-g"
3710 else
3711 if test "$GCC" = yes; then
3712 CFLAGS="-O2"
3713 else
3714 CFLAGS=
3717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3718 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3719 if ${ac_cv_prog_cc_c89+:} false; then :
3720 $as_echo_n "(cached) " >&6
3721 else
3722 ac_cv_prog_cc_c89=no
3723 ac_save_CC=$CC
3724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3725 /* end confdefs.h. */
3726 #include <stdarg.h>
3727 #include <stdio.h>
3728 struct stat;
3729 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3730 struct buf { int x; };
3731 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3732 static char *e (p, i)
3733 char **p;
3734 int i;
3736 return p[i];
3738 static char *f (char * (*g) (char **, int), char **p, ...)
3740 char *s;
3741 va_list v;
3742 va_start (v,p);
3743 s = g (p, va_arg (v,int));
3744 va_end (v);
3745 return s;
3748 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3749 function prototypes and stuff, but not '\xHH' hex character constants.
3750 These don't provoke an error unfortunately, instead are silently treated
3751 as 'x'. The following induces an error, until -std is added to get
3752 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3753 array size at least. It's necessary to write '\x00'==0 to get something
3754 that's true only with -std. */
3755 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3757 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3758 inside strings and character constants. */
3759 #define FOO(x) 'x'
3760 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3762 int test (int i, double x);
3763 struct s1 {int (*f) (int a);};
3764 struct s2 {int (*f) (double a);};
3765 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3766 int argc;
3767 char **argv;
3769 main ()
3771 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3773 return 0;
3775 _ACEOF
3776 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3777 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3779 CC="$ac_save_CC $ac_arg"
3780 if ac_fn_c_try_compile "$LINENO"; then :
3781 ac_cv_prog_cc_c89=$ac_arg
3783 rm -f core conftest.err conftest.$ac_objext
3784 test "x$ac_cv_prog_cc_c89" != "xno" && break
3785 done
3786 rm -f conftest.$ac_ext
3787 CC=$ac_save_CC
3790 # AC_CACHE_VAL
3791 case "x$ac_cv_prog_cc_c89" in
3793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3794 $as_echo "none needed" >&6; } ;;
3795 xno)
3796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3797 $as_echo "unsupported" >&6; } ;;
3799 CC="$CC $ac_cv_prog_cc_c89"
3800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3801 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3802 esac
3803 if test "x$ac_cv_prog_cc_c89" != xno; then :
3807 ac_ext=c
3808 ac_cpp='$CPP $CPPFLAGS'
3809 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3810 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3811 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3813 ac_ext=cpp
3814 ac_cpp='$CXXCPP $CPPFLAGS'
3815 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3816 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3817 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3818 if test -z "$CXX"; then
3819 if test -n "$CCC"; then
3820 CXX=$CCC
3821 else
3822 if test -n "$ac_tool_prefix"; then
3823 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3825 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3826 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3828 $as_echo_n "checking for $ac_word... " >&6; }
3829 if ${ac_cv_prog_CXX+:} false; then :
3830 $as_echo_n "(cached) " >&6
3831 else
3832 if test -n "$CXX"; then
3833 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3834 else
3835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3836 for as_dir in $PATH
3838 IFS=$as_save_IFS
3839 test -z "$as_dir" && as_dir=.
3840 for ac_exec_ext in '' $ac_executable_extensions; do
3841 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3842 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3844 break 2
3846 done
3847 done
3848 IFS=$as_save_IFS
3852 CXX=$ac_cv_prog_CXX
3853 if test -n "$CXX"; then
3854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3855 $as_echo "$CXX" >&6; }
3856 else
3857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3858 $as_echo "no" >&6; }
3862 test -n "$CXX" && break
3863 done
3865 if test -z "$CXX"; then
3866 ac_ct_CXX=$CXX
3867 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3869 # Extract the first word of "$ac_prog", so it can be a program name with args.
3870 set dummy $ac_prog; ac_word=$2
3871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3872 $as_echo_n "checking for $ac_word... " >&6; }
3873 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3874 $as_echo_n "(cached) " >&6
3875 else
3876 if test -n "$ac_ct_CXX"; then
3877 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3878 else
3879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3880 for as_dir in $PATH
3882 IFS=$as_save_IFS
3883 test -z "$as_dir" && as_dir=.
3884 for ac_exec_ext in '' $ac_executable_extensions; do
3885 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3886 ac_cv_prog_ac_ct_CXX="$ac_prog"
3887 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3888 break 2
3890 done
3891 done
3892 IFS=$as_save_IFS
3896 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3897 if test -n "$ac_ct_CXX"; then
3898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3899 $as_echo "$ac_ct_CXX" >&6; }
3900 else
3901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3902 $as_echo "no" >&6; }
3906 test -n "$ac_ct_CXX" && break
3907 done
3909 if test "x$ac_ct_CXX" = x; then
3910 CXX="g++"
3911 else
3912 case $cross_compiling:$ac_tool_warned in
3913 yes:)
3914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3915 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3916 ac_tool_warned=yes ;;
3917 esac
3918 CXX=$ac_ct_CXX
3924 # Provide some information about the compiler.
3925 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3926 set X $ac_compile
3927 ac_compiler=$2
3928 for ac_option in --version -v -V -qversion; do
3929 { { ac_try="$ac_compiler $ac_option >&5"
3930 case "(($ac_try" in
3931 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3932 *) ac_try_echo=$ac_try;;
3933 esac
3934 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3935 $as_echo "$ac_try_echo"; } >&5
3936 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3937 ac_status=$?
3938 if test -s conftest.err; then
3939 sed '10a\
3940 ... rest of stderr output deleted ...
3941 10q' conftest.err >conftest.er1
3942 cat conftest.er1 >&5
3944 rm -f conftest.er1 conftest.err
3945 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3946 test $ac_status = 0; }
3947 done
3949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3950 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3951 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3952 $as_echo_n "(cached) " >&6
3953 else
3954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3955 /* end confdefs.h. */
3958 main ()
3960 #ifndef __GNUC__
3961 choke me
3962 #endif
3965 return 0;
3967 _ACEOF
3968 if ac_fn_cxx_try_compile "$LINENO"; then :
3969 ac_compiler_gnu=yes
3970 else
3971 ac_compiler_gnu=no
3973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3974 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3978 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3979 if test $ac_compiler_gnu = yes; then
3980 GXX=yes
3981 else
3982 GXX=
3984 ac_test_CXXFLAGS=${CXXFLAGS+set}
3985 ac_save_CXXFLAGS=$CXXFLAGS
3986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3987 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3988 if ${ac_cv_prog_cxx_g+:} false; then :
3989 $as_echo_n "(cached) " >&6
3990 else
3991 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3992 ac_cxx_werror_flag=yes
3993 ac_cv_prog_cxx_g=no
3994 CXXFLAGS="-g"
3995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3996 /* end confdefs.h. */
3999 main ()
4003 return 0;
4005 _ACEOF
4006 if ac_fn_cxx_try_compile "$LINENO"; then :
4007 ac_cv_prog_cxx_g=yes
4008 else
4009 CXXFLAGS=""
4010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4011 /* end confdefs.h. */
4014 main ()
4018 return 0;
4020 _ACEOF
4021 if ac_fn_cxx_try_compile "$LINENO"; then :
4023 else
4024 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4025 CXXFLAGS="-g"
4026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4027 /* end confdefs.h. */
4030 main ()
4034 return 0;
4036 _ACEOF
4037 if ac_fn_cxx_try_compile "$LINENO"; then :
4038 ac_cv_prog_cxx_g=yes
4040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4045 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4048 $as_echo "$ac_cv_prog_cxx_g" >&6; }
4049 if test "$ac_test_CXXFLAGS" = set; then
4050 CXXFLAGS=$ac_save_CXXFLAGS
4051 elif test $ac_cv_prog_cxx_g = yes; then
4052 if test "$GXX" = yes; then
4053 CXXFLAGS="-g -O2"
4054 else
4055 CXXFLAGS="-g"
4057 else
4058 if test "$GXX" = yes; then
4059 CXXFLAGS="-O2"
4060 else
4061 CXXFLAGS=
4064 ac_ext=c
4065 ac_cpp='$CPP $CPPFLAGS'
4066 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4067 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4068 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4072 ac_ext=c
4073 ac_cpp='$CPP $CPPFLAGS'
4074 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4075 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4076 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4078 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4079 # On Suns, sometimes $CPP names a directory.
4080 if test -n "$CPP" && test -d "$CPP"; then
4081 CPP=
4083 if test -z "$CPP"; then
4084 if ${ac_cv_prog_CPP+:} false; then :
4085 $as_echo_n "(cached) " >&6
4086 else
4087 # Double quotes because CPP needs to be expanded
4088 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4090 ac_preproc_ok=false
4091 for ac_c_preproc_warn_flag in '' yes
4093 # Use a header file that comes with gcc, so configuring glibc
4094 # with a fresh cross-compiler works.
4095 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4096 # <limits.h> exists even on freestanding compilers.
4097 # On the NeXT, cc -E runs the code through the compiler's parser,
4098 # not just through cpp. "Syntax error" is here to catch this case.
4099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4100 /* end confdefs.h. */
4101 #ifdef __STDC__
4102 # include <limits.h>
4103 #else
4104 # include <assert.h>
4105 #endif
4106 Syntax error
4107 _ACEOF
4108 if ac_fn_c_try_cpp "$LINENO"; then :
4110 else
4111 # Broken: fails on valid input.
4112 continue
4114 rm -f conftest.err conftest.i conftest.$ac_ext
4116 # OK, works on sane cases. Now check whether nonexistent headers
4117 # can be detected and how.
4118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4119 /* end confdefs.h. */
4120 #include <ac_nonexistent.h>
4121 _ACEOF
4122 if ac_fn_c_try_cpp "$LINENO"; then :
4123 # Broken: success on invalid input.
4124 continue
4125 else
4126 # Passes both tests.
4127 ac_preproc_ok=:
4128 break
4130 rm -f conftest.err conftest.i conftest.$ac_ext
4132 done
4133 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4134 rm -f conftest.i conftest.err conftest.$ac_ext
4135 if $ac_preproc_ok; then :
4136 break
4139 done
4140 ac_cv_prog_CPP=$CPP
4143 CPP=$ac_cv_prog_CPP
4144 else
4145 ac_cv_prog_CPP=$CPP
4147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4148 $as_echo "$CPP" >&6; }
4149 ac_preproc_ok=false
4150 for ac_c_preproc_warn_flag in '' yes
4152 # Use a header file that comes with gcc, so configuring glibc
4153 # with a fresh cross-compiler works.
4154 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4155 # <limits.h> exists even on freestanding compilers.
4156 # On the NeXT, cc -E runs the code through the compiler's parser,
4157 # not just through cpp. "Syntax error" is here to catch this case.
4158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4159 /* end confdefs.h. */
4160 #ifdef __STDC__
4161 # include <limits.h>
4162 #else
4163 # include <assert.h>
4164 #endif
4165 Syntax error
4166 _ACEOF
4167 if ac_fn_c_try_cpp "$LINENO"; then :
4169 else
4170 # Broken: fails on valid input.
4171 continue
4173 rm -f conftest.err conftest.i conftest.$ac_ext
4175 # OK, works on sane cases. Now check whether nonexistent headers
4176 # can be detected and how.
4177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4178 /* end confdefs.h. */
4179 #include <ac_nonexistent.h>
4180 _ACEOF
4181 if ac_fn_c_try_cpp "$LINENO"; then :
4182 # Broken: success on invalid input.
4183 continue
4184 else
4185 # Passes both tests.
4186 ac_preproc_ok=:
4187 break
4189 rm -f conftest.err conftest.i conftest.$ac_ext
4191 done
4192 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4193 rm -f conftest.i conftest.err conftest.$ac_ext
4194 if $ac_preproc_ok; then :
4196 else
4197 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4198 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4199 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4200 See \`config.log' for more details" "$LINENO" 5; }
4203 ac_ext=c
4204 ac_cpp='$CPP $CPPFLAGS'
4205 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4206 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4207 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4211 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4212 if ${ac_cv_path_GREP+:} false; then :
4213 $as_echo_n "(cached) " >&6
4214 else
4215 if test -z "$GREP"; then
4216 ac_path_GREP_found=false
4217 # Loop through the user's path and test for each of PROGNAME-LIST
4218 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4219 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4221 IFS=$as_save_IFS
4222 test -z "$as_dir" && as_dir=.
4223 for ac_prog in grep ggrep; do
4224 for ac_exec_ext in '' $ac_executable_extensions; do
4225 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4226 as_fn_executable_p "$ac_path_GREP" || continue
4227 # Check for GNU ac_path_GREP and select it if it is found.
4228 # Check for GNU $ac_path_GREP
4229 case `"$ac_path_GREP" --version 2>&1` in
4230 *GNU*)
4231 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4233 ac_count=0
4234 $as_echo_n 0123456789 >"conftest.in"
4235 while :
4237 cat "conftest.in" "conftest.in" >"conftest.tmp"
4238 mv "conftest.tmp" "conftest.in"
4239 cp "conftest.in" "conftest.nl"
4240 $as_echo 'GREP' >> "conftest.nl"
4241 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4242 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4243 as_fn_arith $ac_count + 1 && ac_count=$as_val
4244 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4245 # Best one so far, save it but keep looking for a better one
4246 ac_cv_path_GREP="$ac_path_GREP"
4247 ac_path_GREP_max=$ac_count
4249 # 10*(2^10) chars as input seems more than enough
4250 test $ac_count -gt 10 && break
4251 done
4252 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4253 esac
4255 $ac_path_GREP_found && break 3
4256 done
4257 done
4258 done
4259 IFS=$as_save_IFS
4260 if test -z "$ac_cv_path_GREP"; then
4261 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4263 else
4264 ac_cv_path_GREP=$GREP
4268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4269 $as_echo "$ac_cv_path_GREP" >&6; }
4270 GREP="$ac_cv_path_GREP"
4273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4274 $as_echo_n "checking for egrep... " >&6; }
4275 if ${ac_cv_path_EGREP+:} false; then :
4276 $as_echo_n "(cached) " >&6
4277 else
4278 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4279 then ac_cv_path_EGREP="$GREP -E"
4280 else
4281 if test -z "$EGREP"; then
4282 ac_path_EGREP_found=false
4283 # Loop through the user's path and test for each of PROGNAME-LIST
4284 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4285 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4287 IFS=$as_save_IFS
4288 test -z "$as_dir" && as_dir=.
4289 for ac_prog in egrep; do
4290 for ac_exec_ext in '' $ac_executable_extensions; do
4291 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4292 as_fn_executable_p "$ac_path_EGREP" || continue
4293 # Check for GNU ac_path_EGREP and select it if it is found.
4294 # Check for GNU $ac_path_EGREP
4295 case `"$ac_path_EGREP" --version 2>&1` in
4296 *GNU*)
4297 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4299 ac_count=0
4300 $as_echo_n 0123456789 >"conftest.in"
4301 while :
4303 cat "conftest.in" "conftest.in" >"conftest.tmp"
4304 mv "conftest.tmp" "conftest.in"
4305 cp "conftest.in" "conftest.nl"
4306 $as_echo 'EGREP' >> "conftest.nl"
4307 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4308 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4309 as_fn_arith $ac_count + 1 && ac_count=$as_val
4310 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4311 # Best one so far, save it but keep looking for a better one
4312 ac_cv_path_EGREP="$ac_path_EGREP"
4313 ac_path_EGREP_max=$ac_count
4315 # 10*(2^10) chars as input seems more than enough
4316 test $ac_count -gt 10 && break
4317 done
4318 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4319 esac
4321 $ac_path_EGREP_found && break 3
4322 done
4323 done
4324 done
4325 IFS=$as_save_IFS
4326 if test -z "$ac_cv_path_EGREP"; then
4327 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4329 else
4330 ac_cv_path_EGREP=$EGREP
4335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4336 $as_echo "$ac_cv_path_EGREP" >&6; }
4337 EGREP="$ac_cv_path_EGREP"
4340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4341 $as_echo_n "checking for ANSI C header files... " >&6; }
4342 if ${ac_cv_header_stdc+:} false; then :
4343 $as_echo_n "(cached) " >&6
4344 else
4345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4346 /* end confdefs.h. */
4347 #include <stdlib.h>
4348 #include <stdarg.h>
4349 #include <string.h>
4350 #include <float.h>
4353 main ()
4357 return 0;
4359 _ACEOF
4360 if ac_fn_c_try_compile "$LINENO"; then :
4361 ac_cv_header_stdc=yes
4362 else
4363 ac_cv_header_stdc=no
4365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4367 if test $ac_cv_header_stdc = yes; then
4368 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4370 /* end confdefs.h. */
4371 #include <string.h>
4373 _ACEOF
4374 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4375 $EGREP "memchr" >/dev/null 2>&1; then :
4377 else
4378 ac_cv_header_stdc=no
4380 rm -f conftest*
4384 if test $ac_cv_header_stdc = yes; then
4385 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4387 /* end confdefs.h. */
4388 #include <stdlib.h>
4390 _ACEOF
4391 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4392 $EGREP "free" >/dev/null 2>&1; then :
4394 else
4395 ac_cv_header_stdc=no
4397 rm -f conftest*
4401 if test $ac_cv_header_stdc = yes; then
4402 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4403 if test "$cross_compiling" = yes; then :
4405 else
4406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4407 /* end confdefs.h. */
4408 #include <ctype.h>
4409 #include <stdlib.h>
4410 #if ((' ' & 0x0FF) == 0x020)
4411 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4412 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4413 #else
4414 # define ISLOWER(c) \
4415 (('a' <= (c) && (c) <= 'i') \
4416 || ('j' <= (c) && (c) <= 'r') \
4417 || ('s' <= (c) && (c) <= 'z'))
4418 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4419 #endif
4421 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4423 main ()
4425 int i;
4426 for (i = 0; i < 256; i++)
4427 if (XOR (islower (i), ISLOWER (i))
4428 || toupper (i) != TOUPPER (i))
4429 return 2;
4430 return 0;
4432 _ACEOF
4433 if ac_fn_c_try_run "$LINENO"; then :
4435 else
4436 ac_cv_header_stdc=no
4438 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4439 conftest.$ac_objext conftest.beam conftest.$ac_ext
4444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4445 $as_echo "$ac_cv_header_stdc" >&6; }
4446 if test $ac_cv_header_stdc = yes; then
4448 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4452 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4453 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4454 inttypes.h stdint.h unistd.h
4455 do :
4456 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4457 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4459 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4460 cat >>confdefs.h <<_ACEOF
4461 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4462 _ACEOF
4466 done
4470 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4471 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4472 MINIX=yes
4473 else
4474 MINIX=
4478 if test "$MINIX" = yes; then
4480 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4483 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4486 $as_echo "#define _MINIX 1" >>confdefs.h
4491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4492 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4493 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4494 $as_echo_n "(cached) " >&6
4495 else
4496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4497 /* end confdefs.h. */
4499 # define __EXTENSIONS__ 1
4500 $ac_includes_default
4502 main ()
4506 return 0;
4508 _ACEOF
4509 if ac_fn_c_try_compile "$LINENO"; then :
4510 ac_cv_safe_to_define___extensions__=yes
4511 else
4512 ac_cv_safe_to_define___extensions__=no
4514 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4517 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4518 test $ac_cv_safe_to_define___extensions__ = yes &&
4519 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4521 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4523 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4525 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4527 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4530 ac_aux_dir=
4531 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4532 if test -f "$ac_dir/install-sh"; then
4533 ac_aux_dir=$ac_dir
4534 ac_install_sh="$ac_aux_dir/install-sh -c"
4535 break
4536 elif test -f "$ac_dir/install.sh"; then
4537 ac_aux_dir=$ac_dir
4538 ac_install_sh="$ac_aux_dir/install.sh -c"
4539 break
4540 elif test -f "$ac_dir/shtool"; then
4541 ac_aux_dir=$ac_dir
4542 ac_install_sh="$ac_aux_dir/shtool install -c"
4543 break
4545 done
4546 if test -z "$ac_aux_dir"; then
4547 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4550 # These three variables are undocumented and unsupported,
4551 # and are intended to be withdrawn in a future Autoconf release.
4552 # They can cause serious problems if a builder's source tree is in a directory
4553 # whose full name contains unusual characters.
4554 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4555 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4556 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4559 # Make sure we can run config.sub.
4560 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4561 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4564 $as_echo_n "checking build system type... " >&6; }
4565 if ${ac_cv_build+:} false; then :
4566 $as_echo_n "(cached) " >&6
4567 else
4568 ac_build_alias=$build_alias
4569 test "x$ac_build_alias" = x &&
4570 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4571 test "x$ac_build_alias" = x &&
4572 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4573 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4574 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4578 $as_echo "$ac_cv_build" >&6; }
4579 case $ac_cv_build in
4580 *-*-*) ;;
4581 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4582 esac
4583 build=$ac_cv_build
4584 ac_save_IFS=$IFS; IFS='-'
4585 set x $ac_cv_build
4586 shift
4587 build_cpu=$1
4588 build_vendor=$2
4589 shift; shift
4590 # Remember, the first character of IFS is used to create $*,
4591 # except with old shells:
4592 build_os=$*
4593 IFS=$ac_save_IFS
4594 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4598 $as_echo_n "checking host system type... " >&6; }
4599 if ${ac_cv_host+:} false; then :
4600 $as_echo_n "(cached) " >&6
4601 else
4602 if test "x$host_alias" = x; then
4603 ac_cv_host=$ac_cv_build
4604 else
4605 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4606 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4611 $as_echo "$ac_cv_host" >&6; }
4612 case $ac_cv_host in
4613 *-*-*) ;;
4614 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4615 esac
4616 host=$ac_cv_host
4617 ac_save_IFS=$IFS; IFS='-'
4618 set x $ac_cv_host
4619 shift
4620 host_cpu=$1
4621 host_vendor=$2
4622 shift; shift
4623 # Remember, the first character of IFS is used to create $*,
4624 # except with old shells:
4625 host_os=$*
4626 IFS=$ac_save_IFS
4627 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4631 $as_echo_n "checking target system type... " >&6; }
4632 if ${ac_cv_target+:} false; then :
4633 $as_echo_n "(cached) " >&6
4634 else
4635 if test "x$target_alias" = x; then
4636 ac_cv_target=$ac_cv_host
4637 else
4638 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4639 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4644 $as_echo "$ac_cv_target" >&6; }
4645 case $ac_cv_target in
4646 *-*-*) ;;
4647 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4648 esac
4649 target=$ac_cv_target
4650 ac_save_IFS=$IFS; IFS='-'
4651 set x $ac_cv_target
4652 shift
4653 target_cpu=$1
4654 target_vendor=$2
4655 shift; shift
4656 # Remember, the first character of IFS is used to create $*,
4657 # except with old shells:
4658 target_os=$*
4659 IFS=$ac_save_IFS
4660 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4663 # The aliases save the names the user supplied, while $host etc.
4664 # will get canonicalized.
4665 test -n "$target_alias" &&
4666 test "$program_prefix$program_suffix$program_transform_name" = \
4667 NONENONEs,x,x, &&
4668 program_prefix=${target_alias}-
4670 # The tests for host and target for $enable_largefile require
4671 # canonical names.
4675 # As the $enable_largefile decision depends on --enable-plugins we must set it
4676 # even in directories otherwise not depending on the $plugins option.
4679 maybe_plugins=no
4680 for ac_header in dlfcn.h
4681 do :
4682 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
4684 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
4685 cat >>confdefs.h <<_ACEOF
4686 #define HAVE_DLFCN_H 1
4687 _ACEOF
4688 maybe_plugins=yes
4691 done
4693 for ac_header in windows.h
4694 do :
4695 ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
4697 if test "x$ac_cv_header_windows_h" = xyes; then :
4698 cat >>confdefs.h <<_ACEOF
4699 #define HAVE_WINDOWS_H 1
4700 _ACEOF
4701 maybe_plugins=yes
4704 done
4707 # Check whether --enable-plugins was given.
4708 if test "${enable_plugins+set}" = set; then :
4709 enableval=$enable_plugins; case "${enableval}" in
4710 no) plugins=no ;;
4711 *) plugins=yes
4712 if test "$maybe_plugins" != "yes" ; then
4713 as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
4714 fi ;;
4715 esac
4716 else
4717 plugins=$maybe_plugins
4721 if test "$plugins" = "yes"; then
4722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
4723 $as_echo_n "checking for library containing dlsym... " >&6; }
4724 if ${ac_cv_search_dlsym+:} false; then :
4725 $as_echo_n "(cached) " >&6
4726 else
4727 ac_func_search_save_LIBS=$LIBS
4728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4729 /* end confdefs.h. */
4731 /* Override any GCC internal prototype to avoid an error.
4732 Use char because int might match the return type of a GCC
4733 builtin and then its argument prototype would still apply. */
4734 #ifdef __cplusplus
4735 extern "C"
4736 #endif
4737 char dlsym ();
4739 main ()
4741 return dlsym ();
4743 return 0;
4745 _ACEOF
4746 for ac_lib in '' dl; do
4747 if test -z "$ac_lib"; then
4748 ac_res="none required"
4749 else
4750 ac_res=-l$ac_lib
4751 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4753 if ac_fn_c_try_link "$LINENO"; then :
4754 ac_cv_search_dlsym=$ac_res
4756 rm -f core conftest.err conftest.$ac_objext \
4757 conftest$ac_exeext
4758 if ${ac_cv_search_dlsym+:} false; then :
4759 break
4761 done
4762 if ${ac_cv_search_dlsym+:} false; then :
4764 else
4765 ac_cv_search_dlsym=no
4767 rm conftest.$ac_ext
4768 LIBS=$ac_func_search_save_LIBS
4770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
4771 $as_echo "$ac_cv_search_dlsym" >&6; }
4772 ac_res=$ac_cv_search_dlsym
4773 if test "$ac_res" != no; then :
4774 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4781 case "${host}" in
4782 sparc-*-solaris*|i?86-*-solaris*)
4783 # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
4784 # were mutually exclusive until Solaris 11.3. Without procfs support,
4785 # the bfd/ elf module cannot provide certain routines such as
4786 # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
4787 # explicitly requested large-file support through the
4788 # --enable-largefile switch, disable large-file support in favor of
4789 # procfs support.
4791 # Check if <sys/procfs.h> is incompatible with large-file support.
4792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4793 /* end confdefs.h. */
4794 #define _FILE_OFFSET_BITS 64
4795 #define _STRUCTURED_PROC 1
4796 #include <sys/procfs.h>
4798 main ()
4802 return 0;
4804 _ACEOF
4805 if ac_fn_c_try_compile "$LINENO"; then :
4806 acx_cv_procfs_lfs=yes
4807 else
4808 acx_cv_procfs_lfs=no
4810 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4812 # Forcefully disable large-file support only if necessary, gdb is in
4813 # tree and enabled.
4814 if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
4815 -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
4816 : ${enable_largefile="no"}
4817 if test "$plugins" = yes; then
4818 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
4819 plugin support disabled; require large-file support which is incompatible with GDB." >&5
4820 $as_echo "$as_me: WARNING:
4821 plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
4822 plugins=no
4826 # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
4827 # benefit of g++ 9+ which predefines it on Solaris.
4828 if test "$enable_largefile" = no; then
4829 LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
4833 esac
4835 # Check whether --enable-largefile was given.
4836 if test "${enable_largefile+set}" = set; then :
4837 enableval=$enable_largefile;
4840 if test "$enable_largefile" != no; then
4842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4843 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4844 if ${ac_cv_sys_largefile_CC+:} false; then :
4845 $as_echo_n "(cached) " >&6
4846 else
4847 ac_cv_sys_largefile_CC=no
4848 if test "$GCC" != yes; then
4849 ac_save_CC=$CC
4850 while :; do
4851 # IRIX 6.2 and later do not support large files by default,
4852 # so use the C compiler's -n32 option if that helps.
4853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4854 /* end confdefs.h. */
4855 #include <sys/types.h>
4856 /* Check that off_t can represent 2**63 - 1 correctly.
4857 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4858 since some C++ compilers masquerading as C compilers
4859 incorrectly reject 9223372036854775807. */
4860 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4861 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4862 && LARGE_OFF_T % 2147483647 == 1)
4863 ? 1 : -1];
4865 main ()
4869 return 0;
4871 _ACEOF
4872 if ac_fn_c_try_compile "$LINENO"; then :
4873 break
4875 rm -f core conftest.err conftest.$ac_objext
4876 CC="$CC -n32"
4877 if ac_fn_c_try_compile "$LINENO"; then :
4878 ac_cv_sys_largefile_CC=' -n32'; break
4880 rm -f core conftest.err conftest.$ac_objext
4881 break
4882 done
4883 CC=$ac_save_CC
4884 rm -f conftest.$ac_ext
4887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4888 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4889 if test "$ac_cv_sys_largefile_CC" != no; then
4890 CC=$CC$ac_cv_sys_largefile_CC
4893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4894 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4895 if ${ac_cv_sys_file_offset_bits+:} false; then :
4896 $as_echo_n "(cached) " >&6
4897 else
4898 while :; do
4899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4900 /* end confdefs.h. */
4901 #include <sys/types.h>
4902 /* Check that off_t can represent 2**63 - 1 correctly.
4903 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4904 since some C++ compilers masquerading as C compilers
4905 incorrectly reject 9223372036854775807. */
4906 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4907 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4908 && LARGE_OFF_T % 2147483647 == 1)
4909 ? 1 : -1];
4911 main ()
4915 return 0;
4917 _ACEOF
4918 if ac_fn_c_try_compile "$LINENO"; then :
4919 ac_cv_sys_file_offset_bits=no; break
4921 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4923 /* end confdefs.h. */
4924 #define _FILE_OFFSET_BITS 64
4925 #include <sys/types.h>
4926 /* Check that off_t can represent 2**63 - 1 correctly.
4927 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4928 since some C++ compilers masquerading as C compilers
4929 incorrectly reject 9223372036854775807. */
4930 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4931 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4932 && LARGE_OFF_T % 2147483647 == 1)
4933 ? 1 : -1];
4935 main ()
4939 return 0;
4941 _ACEOF
4942 if ac_fn_c_try_compile "$LINENO"; then :
4943 ac_cv_sys_file_offset_bits=64; break
4945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4946 ac_cv_sys_file_offset_bits=unknown
4947 break
4948 done
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4951 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4952 case $ac_cv_sys_file_offset_bits in #(
4953 no | unknown) ;;
4955 cat >>confdefs.h <<_ACEOF
4956 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4957 _ACEOF
4959 esac
4960 rm -rf conftest*
4961 if test $ac_cv_sys_file_offset_bits = unknown; then
4962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4963 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4964 if ${ac_cv_sys_large_files+:} false; then :
4965 $as_echo_n "(cached) " >&6
4966 else
4967 while :; do
4968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4969 /* end confdefs.h. */
4970 #include <sys/types.h>
4971 /* Check that off_t can represent 2**63 - 1 correctly.
4972 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4973 since some C++ compilers masquerading as C compilers
4974 incorrectly reject 9223372036854775807. */
4975 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4976 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4977 && LARGE_OFF_T % 2147483647 == 1)
4978 ? 1 : -1];
4980 main ()
4984 return 0;
4986 _ACEOF
4987 if ac_fn_c_try_compile "$LINENO"; then :
4988 ac_cv_sys_large_files=no; break
4990 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4992 /* end confdefs.h. */
4993 #define _LARGE_FILES 1
4994 #include <sys/types.h>
4995 /* Check that off_t can represent 2**63 - 1 correctly.
4996 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4997 since some C++ compilers masquerading as C compilers
4998 incorrectly reject 9223372036854775807. */
4999 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5000 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5001 && LARGE_OFF_T % 2147483647 == 1)
5002 ? 1 : -1];
5004 main ()
5008 return 0;
5010 _ACEOF
5011 if ac_fn_c_try_compile "$LINENO"; then :
5012 ac_cv_sys_large_files=1; break
5014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5015 ac_cv_sys_large_files=unknown
5016 break
5017 done
5019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5020 $as_echo "$ac_cv_sys_large_files" >&6; }
5021 case $ac_cv_sys_large_files in #(
5022 no | unknown) ;;
5024 cat >>confdefs.h <<_ACEOF
5025 #define _LARGE_FILES $ac_cv_sys_large_files
5026 _ACEOF
5028 esac
5029 rm -rf conftest*
5036 # Expand $ac_aux_dir to an absolute path.
5037 am_aux_dir=`cd "$ac_aux_dir" && pwd`
5039 if test x"${install_sh+set}" != xset; then
5040 case $am_aux_dir in
5041 *\ * | *\ *)
5042 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
5044 install_sh="\${SHELL} $am_aux_dir/install-sh"
5045 esac
5048 # Installed binaries are usually stripped using 'strip' when the user
5049 # run "make install-strip". However 'strip' might not be the right
5050 # tool to use in cross-compilation environments, therefore Automake
5051 # will honor the 'STRIP' environment variable to overrule this program.
5052 if test "$cross_compiling" != no; then
5053 if test -n "$ac_tool_prefix"; then
5054 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5055 set dummy ${ac_tool_prefix}strip; ac_word=$2
5056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5057 $as_echo_n "checking for $ac_word... " >&6; }
5058 if ${ac_cv_prog_STRIP+:} false; then :
5059 $as_echo_n "(cached) " >&6
5060 else
5061 if test -n "$STRIP"; then
5062 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5063 else
5064 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5065 for as_dir in $PATH
5067 IFS=$as_save_IFS
5068 test -z "$as_dir" && as_dir=.
5069 for ac_exec_ext in '' $ac_executable_extensions; do
5070 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5071 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5072 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5073 break 2
5075 done
5076 done
5077 IFS=$as_save_IFS
5081 STRIP=$ac_cv_prog_STRIP
5082 if test -n "$STRIP"; then
5083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
5084 $as_echo "$STRIP" >&6; }
5085 else
5086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5087 $as_echo "no" >&6; }
5092 if test -z "$ac_cv_prog_STRIP"; then
5093 ac_ct_STRIP=$STRIP
5094 # Extract the first word of "strip", so it can be a program name with args.
5095 set dummy strip; ac_word=$2
5096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5097 $as_echo_n "checking for $ac_word... " >&6; }
5098 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
5099 $as_echo_n "(cached) " >&6
5100 else
5101 if test -n "$ac_ct_STRIP"; then
5102 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5103 else
5104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5105 for as_dir in $PATH
5107 IFS=$as_save_IFS
5108 test -z "$as_dir" && as_dir=.
5109 for ac_exec_ext in '' $ac_executable_extensions; do
5110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5111 ac_cv_prog_ac_ct_STRIP="strip"
5112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5113 break 2
5115 done
5116 done
5117 IFS=$as_save_IFS
5121 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5122 if test -n "$ac_ct_STRIP"; then
5123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5124 $as_echo "$ac_ct_STRIP" >&6; }
5125 else
5126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5127 $as_echo "no" >&6; }
5130 if test "x$ac_ct_STRIP" = x; then
5131 STRIP=":"
5132 else
5133 case $cross_compiling:$ac_tool_warned in
5134 yes:)
5135 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5136 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5137 ac_tool_warned=yes ;;
5138 esac
5139 STRIP=$ac_ct_STRIP
5141 else
5142 STRIP="$ac_cv_prog_STRIP"
5146 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5149 ac_aux_dir=
5150 for ac_dir in .. "$srcdir"/..; do
5151 if test -f "$ac_dir/install-sh"; then
5152 ac_aux_dir=$ac_dir
5153 ac_install_sh="$ac_aux_dir/install-sh -c"
5154 break
5155 elif test -f "$ac_dir/install.sh"; then
5156 ac_aux_dir=$ac_dir
5157 ac_install_sh="$ac_aux_dir/install.sh -c"
5158 break
5159 elif test -f "$ac_dir/shtool"; then
5160 ac_aux_dir=$ac_dir
5161 ac_install_sh="$ac_aux_dir/shtool install -c"
5162 break
5164 done
5165 if test -z "$ac_aux_dir"; then
5166 as_fn_error $? "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
5169 # These three variables are undocumented and unsupported,
5170 # and are intended to be withdrawn in a future Autoconf release.
5171 # They can cause serious problems if a builder's source tree is in a directory
5172 # whose full name contains unusual characters.
5173 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5174 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5175 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5179 # Set build, build_cpu, build_vendor and build_os.
5182 # Set host, host_cpu, host_vendor, and host_os.
5185 # Set target, target_cpu, target_vendor, and target_os.
5188 test "$program_prefix" != NONE &&
5189 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5190 # Use a double $ so make ignores it.
5191 test "$program_suffix" != NONE &&
5192 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5193 # Double any \ or $.
5194 # By default was `s,x,x', remove it if useless.
5195 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5196 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5199 # We require a C++11 compiler. Check if one is available, and if
5200 # necessary, set CXX_DIALECT to some -std=xxx switch.
5202 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
5203 ac_ext=cpp
5204 ac_cpp='$CXXCPP $CPPFLAGS'
5205 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5206 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5207 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5208 CXX_DIALECT=""
5209 ac_success=no
5210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5211 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5212 if ${ax_cv_cxx_compile_cxx11+:} false; then :
5213 $as_echo_n "(cached) " >&6
5214 else
5215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5216 /* end confdefs.h. */
5219 // If the compiler admits that it is not ready for C++11, why torture it?
5220 // Hopefully, this will speed up the test.
5222 #ifndef __cplusplus
5224 #error "This is not a C++ compiler"
5226 #elif __cplusplus < 201103L
5228 #error "This is not a C++11 compiler"
5230 #else
5232 namespace cxx11
5235 namespace test_static_assert
5238 template <typename T>
5239 struct check
5241 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5246 namespace test_final_override
5249 struct Base
5251 virtual void f() {}
5254 struct Derived : public Base
5256 virtual void f() override {}
5261 namespace test_double_right_angle_brackets
5264 template < typename T >
5265 struct check {};
5267 typedef check<void> single_type;
5268 typedef check<check<void>> double_type;
5269 typedef check<check<check<void>>> triple_type;
5270 typedef check<check<check<check<void>>>> quadruple_type;
5274 namespace test_decltype
5280 int a = 1;
5281 decltype(a) b = 2;
5282 return a + b;
5287 namespace test_type_deduction
5290 template < typename T1, typename T2 >
5291 struct is_same
5293 static const bool value = false;
5296 template < typename T >
5297 struct is_same<T, T>
5299 static const bool value = true;
5302 template < typename T1, typename T2 >
5303 auto
5304 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5306 return a1 + a2;
5310 test(const int c, volatile int v)
5312 static_assert(is_same<int, decltype(0)>::value == true, "");
5313 static_assert(is_same<int, decltype(c)>::value == false, "");
5314 static_assert(is_same<int, decltype(v)>::value == false, "");
5315 auto ac = c;
5316 auto av = v;
5317 auto sumi = ac + av + 'x';
5318 auto sumf = ac + av + 1.0;
5319 static_assert(is_same<int, decltype(ac)>::value == true, "");
5320 static_assert(is_same<int, decltype(av)>::value == true, "");
5321 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5322 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5323 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5324 return (sumf > 0.0) ? sumi : add(c, v);
5329 namespace test_noexcept
5332 int f() { return 0; }
5333 int g() noexcept { return 0; }
5335 static_assert(noexcept(f()) == false, "");
5336 static_assert(noexcept(g()) == true, "");
5340 namespace test_constexpr
5343 template < typename CharT >
5344 unsigned long constexpr
5345 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5347 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5350 template < typename CharT >
5351 unsigned long constexpr
5352 strlen_c(const CharT *const s) noexcept
5354 return strlen_c_r(s, 0UL);
5357 static_assert(strlen_c("") == 0UL, "");
5358 static_assert(strlen_c("1") == 1UL, "");
5359 static_assert(strlen_c("example") == 7UL, "");
5360 static_assert(strlen_c("another\0example") == 7UL, "");
5364 namespace test_rvalue_references
5367 template < int N >
5368 struct answer
5370 static constexpr int value = N;
5373 answer<1> f(int&) { return answer<1>(); }
5374 answer<2> f(const int&) { return answer<2>(); }
5375 answer<3> f(int&&) { return answer<3>(); }
5377 void
5378 test()
5380 int i = 0;
5381 const int c = 0;
5382 static_assert(decltype(f(i))::value == 1, "");
5383 static_assert(decltype(f(c))::value == 2, "");
5384 static_assert(decltype(f(0))::value == 3, "");
5389 namespace test_uniform_initialization
5392 struct test
5394 static const int zero {};
5395 static const int one {1};
5398 static_assert(test::zero == 0, "");
5399 static_assert(test::one == 1, "");
5403 namespace test_lambdas
5406 void
5407 test1()
5409 auto lambda1 = [](){};
5410 auto lambda2 = lambda1;
5411 lambda1();
5412 lambda2();
5416 test2()
5418 auto a = [](int i, int j){ return i + j; }(1, 2);
5419 auto b = []() -> int { return '0'; }();
5420 auto c = [=](){ return a + b; }();
5421 auto d = [&](){ return c; }();
5422 auto e = [a, &b](int x) mutable {
5423 const auto identity = [](int y){ return y; };
5424 for (auto i = 0; i < a; ++i)
5425 a += b--;
5426 return x + identity(a + b);
5427 }(0);
5428 return a + b + c + d + e;
5432 test3()
5434 const auto nullary = [](){ return 0; };
5435 const auto unary = [](int x){ return x; };
5436 using nullary_t = decltype(nullary);
5437 using unary_t = decltype(unary);
5438 const auto higher1st = [](nullary_t f){ return f(); };
5439 const auto higher2nd = [unary](nullary_t f1){
5440 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5442 return higher1st(nullary) + higher2nd(nullary)(unary);
5447 namespace test_variadic_templates
5450 template <int...>
5451 struct sum;
5453 template <int N0, int... N1toN>
5454 struct sum<N0, N1toN...>
5456 static constexpr auto value = N0 + sum<N1toN...>::value;
5459 template <>
5460 struct sum<>
5462 static constexpr auto value = 0;
5465 static_assert(sum<>::value == 0, "");
5466 static_assert(sum<1>::value == 1, "");
5467 static_assert(sum<23>::value == 23, "");
5468 static_assert(sum<1, 2>::value == 3, "");
5469 static_assert(sum<5, 5, 11>::value == 21, "");
5470 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5474 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5475 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5476 // because of this.
5477 namespace test_template_alias_sfinae
5480 struct foo {};
5482 template<typename T>
5483 using member = typename T::member_type;
5485 template<typename T>
5486 void func(...) {}
5488 template<typename T>
5489 void func(member<T>*) {}
5491 void test();
5493 void test() { func<foo>(0); }
5497 } // namespace cxx11
5499 #endif // __cplusplus >= 201103L
5503 _ACEOF
5504 if ac_fn_cxx_try_compile "$LINENO"; then :
5505 ax_cv_cxx_compile_cxx11=yes
5506 else
5507 ax_cv_cxx_compile_cxx11=no
5509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
5512 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
5513 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
5514 ac_success=yes
5517 if test x$ac_success = xno; then
5518 for alternative in ${ax_cxx_compile_alternatives}; do
5519 switch="-std=gnu++${alternative}"
5520 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5522 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5523 if eval \${$cachevar+:} false; then :
5524 $as_echo_n "(cached) " >&6
5525 else
5526 ac_save_CXX="$CXX"
5527 CXX="$CXX $switch"
5528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5529 /* end confdefs.h. */
5532 // If the compiler admits that it is not ready for C++11, why torture it?
5533 // Hopefully, this will speed up the test.
5535 #ifndef __cplusplus
5537 #error "This is not a C++ compiler"
5539 #elif __cplusplus < 201103L
5541 #error "This is not a C++11 compiler"
5543 #else
5545 namespace cxx11
5548 namespace test_static_assert
5551 template <typename T>
5552 struct check
5554 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5559 namespace test_final_override
5562 struct Base
5564 virtual void f() {}
5567 struct Derived : public Base
5569 virtual void f() override {}
5574 namespace test_double_right_angle_brackets
5577 template < typename T >
5578 struct check {};
5580 typedef check<void> single_type;
5581 typedef check<check<void>> double_type;
5582 typedef check<check<check<void>>> triple_type;
5583 typedef check<check<check<check<void>>>> quadruple_type;
5587 namespace test_decltype
5593 int a = 1;
5594 decltype(a) b = 2;
5595 return a + b;
5600 namespace test_type_deduction
5603 template < typename T1, typename T2 >
5604 struct is_same
5606 static const bool value = false;
5609 template < typename T >
5610 struct is_same<T, T>
5612 static const bool value = true;
5615 template < typename T1, typename T2 >
5616 auto
5617 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5619 return a1 + a2;
5623 test(const int c, volatile int v)
5625 static_assert(is_same<int, decltype(0)>::value == true, "");
5626 static_assert(is_same<int, decltype(c)>::value == false, "");
5627 static_assert(is_same<int, decltype(v)>::value == false, "");
5628 auto ac = c;
5629 auto av = v;
5630 auto sumi = ac + av + 'x';
5631 auto sumf = ac + av + 1.0;
5632 static_assert(is_same<int, decltype(ac)>::value == true, "");
5633 static_assert(is_same<int, decltype(av)>::value == true, "");
5634 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5635 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5636 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5637 return (sumf > 0.0) ? sumi : add(c, v);
5642 namespace test_noexcept
5645 int f() { return 0; }
5646 int g() noexcept { return 0; }
5648 static_assert(noexcept(f()) == false, "");
5649 static_assert(noexcept(g()) == true, "");
5653 namespace test_constexpr
5656 template < typename CharT >
5657 unsigned long constexpr
5658 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5660 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5663 template < typename CharT >
5664 unsigned long constexpr
5665 strlen_c(const CharT *const s) noexcept
5667 return strlen_c_r(s, 0UL);
5670 static_assert(strlen_c("") == 0UL, "");
5671 static_assert(strlen_c("1") == 1UL, "");
5672 static_assert(strlen_c("example") == 7UL, "");
5673 static_assert(strlen_c("another\0example") == 7UL, "");
5677 namespace test_rvalue_references
5680 template < int N >
5681 struct answer
5683 static constexpr int value = N;
5686 answer<1> f(int&) { return answer<1>(); }
5687 answer<2> f(const int&) { return answer<2>(); }
5688 answer<3> f(int&&) { return answer<3>(); }
5690 void
5691 test()
5693 int i = 0;
5694 const int c = 0;
5695 static_assert(decltype(f(i))::value == 1, "");
5696 static_assert(decltype(f(c))::value == 2, "");
5697 static_assert(decltype(f(0))::value == 3, "");
5702 namespace test_uniform_initialization
5705 struct test
5707 static const int zero {};
5708 static const int one {1};
5711 static_assert(test::zero == 0, "");
5712 static_assert(test::one == 1, "");
5716 namespace test_lambdas
5719 void
5720 test1()
5722 auto lambda1 = [](){};
5723 auto lambda2 = lambda1;
5724 lambda1();
5725 lambda2();
5729 test2()
5731 auto a = [](int i, int j){ return i + j; }(1, 2);
5732 auto b = []() -> int { return '0'; }();
5733 auto c = [=](){ return a + b; }();
5734 auto d = [&](){ return c; }();
5735 auto e = [a, &b](int x) mutable {
5736 const auto identity = [](int y){ return y; };
5737 for (auto i = 0; i < a; ++i)
5738 a += b--;
5739 return x + identity(a + b);
5740 }(0);
5741 return a + b + c + d + e;
5745 test3()
5747 const auto nullary = [](){ return 0; };
5748 const auto unary = [](int x){ return x; };
5749 using nullary_t = decltype(nullary);
5750 using unary_t = decltype(unary);
5751 const auto higher1st = [](nullary_t f){ return f(); };
5752 const auto higher2nd = [unary](nullary_t f1){
5753 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5755 return higher1st(nullary) + higher2nd(nullary)(unary);
5760 namespace test_variadic_templates
5763 template <int...>
5764 struct sum;
5766 template <int N0, int... N1toN>
5767 struct sum<N0, N1toN...>
5769 static constexpr auto value = N0 + sum<N1toN...>::value;
5772 template <>
5773 struct sum<>
5775 static constexpr auto value = 0;
5778 static_assert(sum<>::value == 0, "");
5779 static_assert(sum<1>::value == 1, "");
5780 static_assert(sum<23>::value == 23, "");
5781 static_assert(sum<1, 2>::value == 3, "");
5782 static_assert(sum<5, 5, 11>::value == 21, "");
5783 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5787 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5788 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5789 // because of this.
5790 namespace test_template_alias_sfinae
5793 struct foo {};
5795 template<typename T>
5796 using member = typename T::member_type;
5798 template<typename T>
5799 void func(...) {}
5801 template<typename T>
5802 void func(member<T>*) {}
5804 void test();
5806 void test() { func<foo>(0); }
5810 } // namespace cxx11
5812 #endif // __cplusplus >= 201103L
5816 _ACEOF
5817 if ac_fn_cxx_try_compile "$LINENO"; then :
5818 eval $cachevar=yes
5819 else
5820 eval $cachevar=no
5822 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5823 CXX="$ac_save_CXX"
5825 eval ac_res=\$$cachevar
5826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5827 $as_echo "$ac_res" >&6; }
5828 if eval test x\$$cachevar = xyes; then
5829 CXX_DIALECT="$switch"
5830 ac_success=yes
5831 break
5833 done
5836 if test x$ac_success = xno; then
5837 for alternative in ${ax_cxx_compile_alternatives}; do
5838 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
5839 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5841 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5842 if eval \${$cachevar+:} false; then :
5843 $as_echo_n "(cached) " >&6
5844 else
5845 ac_save_CXX="$CXX"
5846 CXX="$CXX $switch"
5847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5848 /* end confdefs.h. */
5851 // If the compiler admits that it is not ready for C++11, why torture it?
5852 // Hopefully, this will speed up the test.
5854 #ifndef __cplusplus
5856 #error "This is not a C++ compiler"
5858 #elif __cplusplus < 201103L
5860 #error "This is not a C++11 compiler"
5862 #else
5864 namespace cxx11
5867 namespace test_static_assert
5870 template <typename T>
5871 struct check
5873 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5878 namespace test_final_override
5881 struct Base
5883 virtual void f() {}
5886 struct Derived : public Base
5888 virtual void f() override {}
5893 namespace test_double_right_angle_brackets
5896 template < typename T >
5897 struct check {};
5899 typedef check<void> single_type;
5900 typedef check<check<void>> double_type;
5901 typedef check<check<check<void>>> triple_type;
5902 typedef check<check<check<check<void>>>> quadruple_type;
5906 namespace test_decltype
5912 int a = 1;
5913 decltype(a) b = 2;
5914 return a + b;
5919 namespace test_type_deduction
5922 template < typename T1, typename T2 >
5923 struct is_same
5925 static const bool value = false;
5928 template < typename T >
5929 struct is_same<T, T>
5931 static const bool value = true;
5934 template < typename T1, typename T2 >
5935 auto
5936 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5938 return a1 + a2;
5942 test(const int c, volatile int v)
5944 static_assert(is_same<int, decltype(0)>::value == true, "");
5945 static_assert(is_same<int, decltype(c)>::value == false, "");
5946 static_assert(is_same<int, decltype(v)>::value == false, "");
5947 auto ac = c;
5948 auto av = v;
5949 auto sumi = ac + av + 'x';
5950 auto sumf = ac + av + 1.0;
5951 static_assert(is_same<int, decltype(ac)>::value == true, "");
5952 static_assert(is_same<int, decltype(av)>::value == true, "");
5953 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5954 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5955 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5956 return (sumf > 0.0) ? sumi : add(c, v);
5961 namespace test_noexcept
5964 int f() { return 0; }
5965 int g() noexcept { return 0; }
5967 static_assert(noexcept(f()) == false, "");
5968 static_assert(noexcept(g()) == true, "");
5972 namespace test_constexpr
5975 template < typename CharT >
5976 unsigned long constexpr
5977 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5979 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5982 template < typename CharT >
5983 unsigned long constexpr
5984 strlen_c(const CharT *const s) noexcept
5986 return strlen_c_r(s, 0UL);
5989 static_assert(strlen_c("") == 0UL, "");
5990 static_assert(strlen_c("1") == 1UL, "");
5991 static_assert(strlen_c("example") == 7UL, "");
5992 static_assert(strlen_c("another\0example") == 7UL, "");
5996 namespace test_rvalue_references
5999 template < int N >
6000 struct answer
6002 static constexpr int value = N;
6005 answer<1> f(int&) { return answer<1>(); }
6006 answer<2> f(const int&) { return answer<2>(); }
6007 answer<3> f(int&&) { return answer<3>(); }
6009 void
6010 test()
6012 int i = 0;
6013 const int c = 0;
6014 static_assert(decltype(f(i))::value == 1, "");
6015 static_assert(decltype(f(c))::value == 2, "");
6016 static_assert(decltype(f(0))::value == 3, "");
6021 namespace test_uniform_initialization
6024 struct test
6026 static const int zero {};
6027 static const int one {1};
6030 static_assert(test::zero == 0, "");
6031 static_assert(test::one == 1, "");
6035 namespace test_lambdas
6038 void
6039 test1()
6041 auto lambda1 = [](){};
6042 auto lambda2 = lambda1;
6043 lambda1();
6044 lambda2();
6048 test2()
6050 auto a = [](int i, int j){ return i + j; }(1, 2);
6051 auto b = []() -> int { return '0'; }();
6052 auto c = [=](){ return a + b; }();
6053 auto d = [&](){ return c; }();
6054 auto e = [a, &b](int x) mutable {
6055 const auto identity = [](int y){ return y; };
6056 for (auto i = 0; i < a; ++i)
6057 a += b--;
6058 return x + identity(a + b);
6059 }(0);
6060 return a + b + c + d + e;
6064 test3()
6066 const auto nullary = [](){ return 0; };
6067 const auto unary = [](int x){ return x; };
6068 using nullary_t = decltype(nullary);
6069 using unary_t = decltype(unary);
6070 const auto higher1st = [](nullary_t f){ return f(); };
6071 const auto higher2nd = [unary](nullary_t f1){
6072 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6074 return higher1st(nullary) + higher2nd(nullary)(unary);
6079 namespace test_variadic_templates
6082 template <int...>
6083 struct sum;
6085 template <int N0, int... N1toN>
6086 struct sum<N0, N1toN...>
6088 static constexpr auto value = N0 + sum<N1toN...>::value;
6091 template <>
6092 struct sum<>
6094 static constexpr auto value = 0;
6097 static_assert(sum<>::value == 0, "");
6098 static_assert(sum<1>::value == 1, "");
6099 static_assert(sum<23>::value == 23, "");
6100 static_assert(sum<1, 2>::value == 3, "");
6101 static_assert(sum<5, 5, 11>::value == 21, "");
6102 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6106 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6107 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6108 // because of this.
6109 namespace test_template_alias_sfinae
6112 struct foo {};
6114 template<typename T>
6115 using member = typename T::member_type;
6117 template<typename T>
6118 void func(...) {}
6120 template<typename T>
6121 void func(member<T>*) {}
6123 void test();
6125 void test() { func<foo>(0); }
6129 } // namespace cxx11
6131 #endif // __cplusplus >= 201103L
6135 _ACEOF
6136 if ac_fn_cxx_try_compile "$LINENO"; then :
6137 eval $cachevar=yes
6138 else
6139 eval $cachevar=no
6141 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6142 CXX="$ac_save_CXX"
6144 eval ac_res=\$$cachevar
6145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6146 $as_echo "$ac_res" >&6; }
6147 if eval test x\$$cachevar = xyes; then
6148 CXX_DIALECT="$switch"
6149 ac_success=yes
6150 break
6152 done
6153 if test x$ac_success = xyes; then
6154 break
6156 done
6158 ac_ext=c
6159 ac_cpp='$CPP $CPPFLAGS'
6160 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6161 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6162 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6164 if test x$ax_cxx_compile_cxx11_required = xtrue; then
6165 if test x$ac_success = xno; then
6166 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
6169 if test x$ac_success = xno; then
6170 HAVE_CXX11=0
6171 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
6172 $as_echo "$as_me: No compiler with C++11 support was found" >&6;}
6173 else
6174 HAVE_CXX11=1
6176 $as_echo "#define HAVE_CXX11 1" >>confdefs.h
6183 # Dependency checking.
6184 rm -rf .tst 2>/dev/null
6185 mkdir .tst 2>/dev/null
6186 if test -d .tst; then
6187 am__leading_dot=.
6188 else
6189 am__leading_dot=_
6191 rmdir .tst 2>/dev/null
6193 DEPDIR="${am__leading_dot}deps"
6195 ac_config_commands="$ac_config_commands depdir"
6198 depcc="$CC" am_compiler_list=
6200 am_depcomp=$ac_aux_dir/depcomp
6201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6202 $as_echo_n "checking dependency style of $depcc... " >&6; }
6203 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
6204 $as_echo_n "(cached) " >&6
6205 else
6206 if test -f "$am_depcomp"; then
6207 # We make a subdir and do the tests there. Otherwise we can end up
6208 # making bogus files that we don't know about and never remove. For
6209 # instance it was reported that on HP-UX the gcc test will end up
6210 # making a dummy file named `D' -- because `-MD' means `put the output
6211 # in D'.
6212 mkdir conftest.dir
6213 # Copy depcomp to subdir because otherwise we won't find it if we're
6214 # using a relative directory.
6215 cp "$am_depcomp" conftest.dir
6216 cd conftest.dir
6217 # We will build objects and dependencies in a subdirectory because
6218 # it helps to detect inapplicable dependency modes. For instance
6219 # both Tru64's cc and ICC support -MD to output dependencies as a
6220 # side effect of compilation, but ICC will put the dependencies in
6221 # the current directory while Tru64 will put them in the object
6222 # directory.
6223 mkdir sub
6225 am_cv_CC_dependencies_compiler_type=none
6226 if test "$am_compiler_list" = ""; then
6227 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6229 for depmode in $am_compiler_list; do
6230 if test $depmode = none; then break; fi
6232 $as_echo "$as_me:$LINENO: trying $depmode" >&5
6233 # Setup a source with many dependencies, because some compilers
6234 # like to wrap large dependency lists on column 80 (with \), and
6235 # we should not choose a depcomp mode which is confused by this.
6237 # We need to recreate these files for each test, as the compiler may
6238 # overwrite some of them when testing with obscure command lines.
6239 # This happens at least with the AIX C compiler.
6240 : > sub/conftest.c
6241 for i in 1 2 3 4 5 6; do
6242 echo '#include "conftst'$i'.h"' >> sub/conftest.c
6243 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
6244 # Solaris 8's {/usr,}/bin/sh.
6245 touch sub/conftst$i.h
6246 done
6247 echo "include sub/conftest.Po" > confmf
6249 # We check with `-c' and `-o' for the sake of the "dashmstdout"
6250 # mode. It turns out that the SunPro C++ compiler does not properly
6251 # handle `-M -o', and we need to detect this.
6252 depcmd="depmode=$depmode \
6253 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
6254 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6255 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
6256 echo "| $depcmd" | sed -e 's/ */ /g' >&5
6257 if env $depcmd > conftest.err 2>&1 &&
6258 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
6259 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
6260 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
6261 # icc doesn't choke on unknown options, it will just issue warnings
6262 # or remarks (even with -Werror). So we grep stderr for any message
6263 # that says an option was ignored or not supported.
6264 # When given -MP, icc 7.0 and 7.1 complain thusly:
6265 # icc: Command line warning: ignoring option '-M'; no argument required
6266 # The diagnosis changed in icc 8.0:
6267 # icc: Command line remark: option '-MP' not supported
6268 if (grep 'ignoring option' conftest.err ||
6269 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6270 am_cv_CC_dependencies_compiler_type=$depmode
6271 $as_echo "$as_me:$LINENO: success" >&5
6272 break
6275 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
6276 sed -e 's/^/| /' < conftest.err >&5
6277 done
6279 cd ..
6280 rm -rf conftest.dir
6281 else
6282 am_cv_CC_dependencies_compiler_type=none
6286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6287 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6288 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
6289 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
6290 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6296 CONFIG_OBS=
6297 CONFIG_DEPS=
6298 CONFIG_SRCS=
6299 ENABLE_CFLAGS=
6301 CONFIG_ALL=
6302 CONFIG_CLEAN=
6303 CONFIG_INSTALL=
6304 CONFIG_UNINSTALL=
6306 # If we haven't got the data from the intl directory,
6307 # assume NLS is disabled.
6308 USE_NLS=no
6309 LIBINTL=
6310 LIBINTL_DEP=
6311 INCINTL=
6312 XGETTEXT=
6313 GMSGFMT=
6314 POSUB=
6316 if test -f ../intl/config.intl; then
6317 . ../intl/config.intl
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
6320 $as_echo_n "checking whether NLS is requested... " >&6; }
6321 if test x"$USE_NLS" != xyes; then
6322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6323 $as_echo "no" >&6; }
6324 else
6325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6326 $as_echo "yes" >&6; }
6328 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
6331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
6332 $as_echo_n "checking for catalogs to be installed... " >&6; }
6333 # Look for .po and .gmo files in the source directory.
6334 CATALOGS=
6335 XLINGUAS=
6336 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
6337 # If there aren't any .gmo files the shell will give us the
6338 # literal string "../path/to/srcdir/po/*.gmo" which has to be
6339 # weeded out.
6340 case "$cat" in *\**)
6341 continue;;
6342 esac
6343 # The quadruple backslash is collapsed to a double backslash
6344 # by the backticks, then collapsed again by the double quotes,
6345 # leaving us with one backslash in the sed expression (right
6346 # before the dot that mustn't act as a wildcard).
6347 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
6348 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
6349 # The user is allowed to set LINGUAS to a list of languages to
6350 # install catalogs for. If it's empty that means "all of them."
6351 if test "x$LINGUAS" = x; then
6352 CATALOGS="$CATALOGS $cat"
6353 XLINGUAS="$XLINGUAS $lang"
6354 else
6355 case "$LINGUAS" in *$lang*)
6356 CATALOGS="$CATALOGS $cat"
6357 XLINGUAS="$XLINGUAS $lang"
6359 esac
6361 done
6362 LINGUAS="$XLINGUAS"
6363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
6364 $as_echo "$LINGUAS" >&6; }
6367 DATADIRNAME=share
6369 INSTOBJEXT=.mo
6371 GENCAT=gencat
6373 CATOBJEXT=.gmo
6377 localedir='${datadir}/locale'
6380 if test x"$USE_NLS" = xyes; then
6381 CONFIG_ALL="$CONFIG_ALL all-po"
6382 CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
6383 CONFIG_INSTALL="$CONFIG_INSTALL install-po"
6384 CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
6387 PACKAGE=gdb
6389 cat >>confdefs.h <<_ACEOF
6390 #define PACKAGE "$PACKAGE"
6391 _ACEOF
6395 # We never need to detect it in this sub-configure.
6396 # But preserve it for config.status --recheck.
6400 MAKEINFO_EXTRA_FLAGS=""
6401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
6402 $as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
6403 if ${gdb_cv_have_makeinfo_click+:} false; then :
6404 $as_echo_n "(cached) " >&6
6405 else
6406 echo '@clicksequence{a @click{} b}' >conftest.texinfo
6407 if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
6408 gdb_cv_have_makeinfo_click=yes
6409 else
6410 gdb_cv_have_makeinfo_click=no
6413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
6414 $as_echo "$gdb_cv_have_makeinfo_click" >&6; }
6415 if test x"$gdb_cv_have_makeinfo_click" = xyes; then
6416 MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
6422 # Check whether --with-separate-debug-dir was given.
6423 if test "${with_separate_debug_dir+set}" = set; then :
6424 withval=$with_separate_debug_dir;
6425 DEBUGDIR=$withval
6426 else
6427 DEBUGDIR=${libdir}/debug
6431 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6432 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6433 ac_define_dir=`eval echo $DEBUGDIR`
6434 ac_define_dir=`eval echo $ac_define_dir`
6436 cat >>confdefs.h <<_ACEOF
6437 #define DEBUGDIR "$ac_define_dir"
6438 _ACEOF
6443 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6444 if test "x$prefix" = xNONE; then
6445 test_prefix=/usr/local
6446 else
6447 test_prefix=$prefix
6449 else
6450 test_prefix=$exec_prefix
6452 value=0
6453 case ${ac_define_dir} in
6454 "${test_prefix}"|"${test_prefix}/"*|\
6455 '${exec_prefix}'|'${exec_prefix}/'*)
6456 value=1
6458 esac
6460 cat >>confdefs.h <<_ACEOF
6461 #define DEBUGDIR_RELOCATABLE $value
6462 _ACEOF
6467 # We can't pass paths as command line arguments.
6468 # Mingw32 tries to be clever and will convert the paths for us.
6469 # For example -DBINDIR="/usr/local/bin" passed on the command line may get
6470 # converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
6471 # This breaks GDB's relocatable path conversions since paths passed in
6472 # config.h would not get so translated, the path prefixes no longer match.
6474 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6475 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6476 ac_define_dir=`eval echo $bindir`
6477 ac_define_dir=`eval echo $ac_define_dir`
6479 cat >>confdefs.h <<_ACEOF
6480 #define BINDIR "$ac_define_dir"
6481 _ACEOF
6485 # GDB's datadir relocation
6489 # Check whether --with-gdb-datadir was given.
6490 if test "${with_gdb_datadir+set}" = set; then :
6491 withval=$with_gdb_datadir;
6492 GDB_DATADIR=$withval
6493 else
6494 GDB_DATADIR=${datadir}/gdb
6498 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6499 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6500 ac_define_dir=`eval echo $GDB_DATADIR`
6501 ac_define_dir=`eval echo $ac_define_dir`
6503 cat >>confdefs.h <<_ACEOF
6504 #define GDB_DATADIR "$ac_define_dir"
6505 _ACEOF
6510 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6511 if test "x$prefix" = xNONE; then
6512 test_prefix=/usr/local
6513 else
6514 test_prefix=$prefix
6516 else
6517 test_prefix=$exec_prefix
6519 value=0
6520 case ${ac_define_dir} in
6521 "${test_prefix}"|"${test_prefix}/"*|\
6522 '${exec_prefix}'|'${exec_prefix}/'*)
6523 value=1
6525 esac
6527 cat >>confdefs.h <<_ACEOF
6528 #define GDB_DATADIR_RELOCATABLE $value
6529 _ACEOF
6535 # Check whether --with-relocated-sources was given.
6536 if test "${with_relocated_sources+set}" = set; then :
6537 withval=$with_relocated_sources; reloc_srcdir="${withval}"
6539 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6540 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6541 ac_define_dir=`eval echo $reloc_srcdir`
6542 ac_define_dir=`eval echo $ac_define_dir`
6544 cat >>confdefs.h <<_ACEOF
6545 #define RELOC_SRCDIR "$ac_define_dir"
6546 _ACEOF
6553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
6554 $as_echo_n "checking for default auto-load directory... " >&6; }
6556 # Check whether --with-auto-load-dir was given.
6557 if test "${with_auto_load_dir+set}" = set; then :
6558 withval=$with_auto_load_dir;
6559 else
6560 with_auto_load_dir='$debugdir:$datadir/auto-load'
6563 escape_dir=`echo $with_auto_load_dir | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6565 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6566 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6567 ac_define_dir=`eval echo $escape_dir`
6568 ac_define_dir=`eval echo $ac_define_dir`
6570 cat >>confdefs.h <<_ACEOF
6571 #define AUTO_LOAD_DIR "$ac_define_dir"
6572 _ACEOF
6575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
6576 $as_echo "$with_auto_load_dir" >&6; }
6578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
6579 $as_echo_n "checking for default auto-load safe-path... " >&6; }
6581 # Check whether --with-auto-load-safe-path was given.
6582 if test "${with_auto_load_safe_path+set}" = set; then :
6583 withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
6584 with_auto_load_safe_path="/"
6586 else
6587 with_auto_load_safe_path="$with_auto_load_dir"
6590 escape_dir=`echo $with_auto_load_safe_path | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6592 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6593 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6594 ac_define_dir=`eval echo $escape_dir`
6595 ac_define_dir=`eval echo $ac_define_dir`
6597 cat >>confdefs.h <<_ACEOF
6598 #define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
6599 _ACEOF
6602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
6603 $as_echo "$with_auto_load_safe_path" >&6; }
6607 subdirs="$subdirs testsuite"
6610 # Check whether to support alternative target configurations
6611 # Check whether --enable-targets was given.
6612 if test "${enable_targets+set}" = set; then :
6613 enableval=$enable_targets; case "${enableval}" in
6614 yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
6616 no) enable_targets= ;;
6617 *) enable_targets=$enableval ;;
6618 esac
6622 # Check whether to enable 64-bit support on 32-bit hosts
6623 # Check whether --enable-64-bit-bfd was given.
6624 if test "${enable_64_bit_bfd+set}" = set; then :
6625 enableval=$enable_64_bit_bfd; case "${enableval}" in
6626 yes) want64=true ;;
6627 no) want64=false ;;
6628 *) as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
6629 esac
6630 else
6631 want64=false
6634 # Provide defaults for some variables set by the per-host and per-target
6635 # configuration.
6636 gdb_host_obs=posix-hdep.o
6638 if test "${target}" = "${host}"; then
6639 gdb_native=yes
6640 else
6641 gdb_native=no
6644 . $srcdir/configure.host
6646 # Accumulate some settings from configure.tgt over all enabled targets
6648 TARGET_OBS=
6649 all_targets=
6650 HAVE_NATIVE_GCORE_TARGET=
6652 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
6654 if test "$targ_alias" = "all"; then
6655 all_targets=true
6656 else
6657 # Canonicalize the secondary target names.
6658 result=`$ac_config_sub $targ_alias 2>/dev/null`
6659 if test -n "$result"; then
6660 targ=$result
6661 else
6662 targ=$targ_alias
6665 . ${srcdir}/configure.tgt
6667 if test -z "${gdb_target_obs}"; then :
6668 as_fn_error $? "configuration ${targ} is unsupported." "$LINENO" 5
6671 # Target-specific object files
6672 for i in ${gdb_target_obs}; do
6673 case " $TARGET_OBS " in
6674 *" ${i} "*) ;;
6676 TARGET_OBS="$TARGET_OBS ${i}"
6678 esac
6679 done
6681 # Check whether this target needs 64-bit CORE_ADDR
6682 if test x${want64} = xfalse; then
6683 . ${srcdir}/../bfd/config.bfd
6686 # Check whether this target is native and supports gcore.
6687 if test $gdb_native = yes -a "$targ_alias" = "$target_alias" \
6688 && $gdb_have_gcore; then
6689 HAVE_NATIVE_GCORE_TARGET=1
6692 done
6694 if test x${all_targets} = xtrue; then
6696 # We want all 64-bit targets if we either:
6697 # - run on a 64-bit host or
6698 # - already require 64-bit support for some other target or
6699 # - the --enable-64-bit-bfd option was supplied
6700 # Otherwise we only support all 32-bit targets.
6702 # NOTE: This test must be in sync with the corresponding
6703 # tests in BFD!
6705 if test x${want64} = xfalse; then
6706 # The cast to long int works around a bug in the HP C Compiler
6707 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6708 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6709 # This bug is HP SR number 8606223364.
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
6711 $as_echo_n "checking size of long... " >&6; }
6712 if ${ac_cv_sizeof_long+:} false; then :
6713 $as_echo_n "(cached) " >&6
6714 else
6715 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
6717 else
6718 if test "$ac_cv_type_long" = yes; then
6719 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6720 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6721 as_fn_error 77 "cannot compute sizeof (long)
6722 See \`config.log' for more details" "$LINENO" 5; }
6723 else
6724 ac_cv_sizeof_long=0
6729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
6730 $as_echo "$ac_cv_sizeof_long" >&6; }
6734 cat >>confdefs.h <<_ACEOF
6735 #define SIZEOF_LONG $ac_cv_sizeof_long
6736 _ACEOF
6739 if test "x${ac_cv_sizeof_long}" = "x8"; then
6740 want64=true
6743 if test x${want64} = xtrue; then
6744 TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
6745 else
6746 TARGET_OBS='$(ALL_TARGET_OBS)'
6753 # For other settings, only the main target counts.
6754 gdb_sim=
6755 gdb_osabi=
6756 targ=$target; . ${srcdir}/configure.tgt
6758 # Fetch the default architecture and default target vector from BFD.
6759 targ=$target; . $srcdir/../bfd/config.bfd
6761 # We only want the first architecture, so strip off the others if
6762 # there is more than one.
6763 targ_archs=`echo $targ_archs | sed 's/ .*//'`
6765 if test "x$targ_archs" != x; then
6767 cat >>confdefs.h <<_ACEOF
6768 #define DEFAULT_BFD_ARCH $targ_archs
6769 _ACEOF
6772 if test "x$targ_defvec" != x; then
6774 cat >>confdefs.h <<_ACEOF
6775 #define DEFAULT_BFD_VEC $targ_defvec
6776 _ACEOF
6780 # Enable MI.
6781 # Check whether --enable-gdbmi was given.
6782 if test "${enable_gdbmi+set}" = set; then :
6783 enableval=$enable_gdbmi; case $enableval in
6784 yes | no)
6787 as_fn_error $? "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
6788 esac
6789 else
6790 enable_gdbmi=yes
6793 if test x"$enable_gdbmi" = xyes; then
6794 if test -d "$srcdir/mi"; then
6795 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
6796 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
6797 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
6798 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
6802 # Enable TUI.
6803 # Check whether --enable-tui was given.
6804 if test "${enable_tui+set}" = set; then :
6805 enableval=$enable_tui; case $enableval in
6806 yes | no | auto)
6809 as_fn_error $? "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
6810 esac
6811 else
6812 enable_tui=auto
6816 # Enable gdbtk.
6817 # Check whether --enable-gdbtk was given.
6818 if test "${enable_gdbtk+set}" = set; then :
6819 enableval=$enable_gdbtk; case $enableval in
6820 yes | no)
6823 as_fn_error $? "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
6824 esac
6825 else
6826 if test -d "$srcdir/gdbtk"; then
6827 enable_gdbtk=yes
6828 else
6829 enable_gdbtk=no
6833 # We unconditionally disable gdbtk tests on selected platforms.
6834 case $host_os in
6835 go32* | windows*)
6836 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
6837 $as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
6838 enable_gdbtk=no ;;
6839 esac
6841 # Handle optional debuginfod support
6849 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
6850 if test -n "$ac_tool_prefix"; then
6851 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
6852 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
6853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6854 $as_echo_n "checking for $ac_word... " >&6; }
6855 if ${ac_cv_path_PKG_CONFIG+:} false; then :
6856 $as_echo_n "(cached) " >&6
6857 else
6858 case $PKG_CONFIG in
6859 [\\/]* | ?:[\\/]*)
6860 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6864 for as_dir in $PATH
6866 IFS=$as_save_IFS
6867 test -z "$as_dir" && as_dir=.
6868 for ac_exec_ext in '' $ac_executable_extensions; do
6869 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6870 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
6871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6872 break 2
6874 done
6875 done
6876 IFS=$as_save_IFS
6879 esac
6881 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6882 if test -n "$PKG_CONFIG"; then
6883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
6884 $as_echo "$PKG_CONFIG" >&6; }
6885 else
6886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6887 $as_echo "no" >&6; }
6892 if test -z "$ac_cv_path_PKG_CONFIG"; then
6893 ac_pt_PKG_CONFIG=$PKG_CONFIG
6894 # Extract the first word of "pkg-config", so it can be a program name with args.
6895 set dummy pkg-config; ac_word=$2
6896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6897 $as_echo_n "checking for $ac_word... " >&6; }
6898 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
6899 $as_echo_n "(cached) " >&6
6900 else
6901 case $ac_pt_PKG_CONFIG in
6902 [\\/]* | ?:[\\/]*)
6903 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
6906 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6907 for as_dir in $PATH
6909 IFS=$as_save_IFS
6910 test -z "$as_dir" && as_dir=.
6911 for ac_exec_ext in '' $ac_executable_extensions; do
6912 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6913 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
6914 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6915 break 2
6917 done
6918 done
6919 IFS=$as_save_IFS
6922 esac
6924 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
6925 if test -n "$ac_pt_PKG_CONFIG"; then
6926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
6927 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
6928 else
6929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6930 $as_echo "no" >&6; }
6933 if test "x$ac_pt_PKG_CONFIG" = x; then
6934 PKG_CONFIG=""
6935 else
6936 case $cross_compiling:$ac_tool_warned in
6937 yes:)
6938 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6939 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6940 ac_tool_warned=yes ;;
6941 esac
6942 PKG_CONFIG=$ac_pt_PKG_CONFIG
6944 else
6945 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
6949 if test -n "$PKG_CONFIG"; then
6950 _pkg_min_version=0.9.0
6951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
6952 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
6953 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
6954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6955 $as_echo "yes" >&6; }
6956 else
6957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6958 $as_echo "no" >&6; }
6959 PKG_CONFIG=""
6963 # Handle optional debuginfod support
6965 # Check whether --with-debuginfod was given.
6966 if test "${with_debuginfod+set}" = set; then :
6967 withval=$with_debuginfod;
6968 else
6969 with_debuginfod=auto
6972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use debuginfod" >&5
6973 $as_echo_n "checking whether to use debuginfod... " >&6; }
6974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_debuginfod" >&5
6975 $as_echo "$with_debuginfod" >&6; }
6977 if test "x$with_debuginfod" != xno; then
6979 pkg_failed=no
6980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libdebuginfod >= 0.179" >&5
6981 $as_echo_n "checking for libdebuginfod >= 0.179... " >&6; }
6983 if test -n "$DEBUGINFOD_CFLAGS"; then
6984 pkg_cv_DEBUGINFOD_CFLAGS="$DEBUGINFOD_CFLAGS"
6985 elif test -n "$PKG_CONFIG"; then
6986 if test -n "$PKG_CONFIG" && \
6987 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
6988 ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
6989 ac_status=$?
6990 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6991 test $ac_status = 0; }; then
6992 pkg_cv_DEBUGINFOD_CFLAGS=`$PKG_CONFIG --cflags "libdebuginfod >= 0.179" 2>/dev/null`
6993 test "x$?" != "x0" && pkg_failed=yes
6994 else
6995 pkg_failed=yes
6997 else
6998 pkg_failed=untried
7000 if test -n "$DEBUGINFOD_LIBS"; then
7001 pkg_cv_DEBUGINFOD_LIBS="$DEBUGINFOD_LIBS"
7002 elif test -n "$PKG_CONFIG"; then
7003 if test -n "$PKG_CONFIG" && \
7004 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
7005 ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
7006 ac_status=$?
7007 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7008 test $ac_status = 0; }; then
7009 pkg_cv_DEBUGINFOD_LIBS=`$PKG_CONFIG --libs "libdebuginfod >= 0.179" 2>/dev/null`
7010 test "x$?" != "x0" && pkg_failed=yes
7011 else
7012 pkg_failed=yes
7014 else
7015 pkg_failed=untried
7018 if test $pkg_failed = no; then
7019 pkg_save_LDFLAGS="$LDFLAGS"
7020 LDFLAGS="$LDFLAGS $pkg_cv_DEBUGINFOD_LIBS"
7021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7022 /* end confdefs.h. */
7025 main ()
7029 return 0;
7031 _ACEOF
7032 if ac_fn_c_try_link "$LINENO"; then :
7034 else
7035 pkg_failed=yes
7037 rm -f core conftest.err conftest.$ac_objext \
7038 conftest$ac_exeext conftest.$ac_ext
7039 LDFLAGS=$pkg_save_LDFLAGS
7044 if test $pkg_failed = yes; then
7045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7046 $as_echo "no" >&6; }
7048 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
7049 _pkg_short_errors_supported=yes
7050 else
7051 _pkg_short_errors_supported=no
7053 if test $_pkg_short_errors_supported = yes; then
7054 DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
7055 else
7056 DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
7058 # Put the nasty error message in config.log where it belongs
7059 echo "$DEBUGINFOD_PKG_ERRORS" >&5
7061 if test "x$with_debuginfod" = xyes; then
7062 as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
7063 else
7064 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
7065 $as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
7067 elif test $pkg_failed = untried; then
7068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7069 $as_echo "no" >&6; }
7070 if test "x$with_debuginfod" = xyes; then
7071 as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
7072 else
7073 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
7074 $as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
7076 else
7077 DEBUGINFOD_CFLAGS=$pkg_cv_DEBUGINFOD_CFLAGS
7078 DEBUGINFOD_LIBS=$pkg_cv_DEBUGINFOD_LIBS
7079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7080 $as_echo "yes" >&6; }
7082 $as_echo "#define HAVE_LIBDEBUGINFOD 1" >>confdefs.h
7085 else
7086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: debuginfod support disabled; some features may be unavailable." >&5
7087 $as_echo "$as_me: WARNING: debuginfod support disabled; some features may be unavailable." >&2;}
7091 # Libunwind support for ia64.
7093 # Check whether --with-libunwind-ia64 was given.
7094 if test "${with_libunwind_ia64+set}" = set; then :
7095 withval=$with_libunwind_ia64;
7096 else
7097 with_libunwind_ia64=auto
7101 # Backward compatibility option.
7102 if test "${with_libunwind+set}" = set; then
7103 if test x"$with_libunwind_ia64" != xauto; then
7104 as_fn_error $? "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
7106 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
7107 $as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
7108 with_libunwind_ia64="$with_libunwind"
7111 case "$with_libunwind_ia64" in
7112 yes | no)
7114 auto)
7115 for ac_header in libunwind-ia64.h
7116 do :
7117 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
7118 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
7119 cat >>confdefs.h <<_ACEOF
7120 #define HAVE_LIBUNWIND_IA64_H 1
7121 _ACEOF
7125 done
7127 with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
7130 as_fn_error $? "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
7132 esac
7134 if test x"$with_libunwind_ia64" = xyes; then
7135 for ac_header in libunwind-ia64.h
7136 do :
7137 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
7138 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
7139 cat >>confdefs.h <<_ACEOF
7140 #define HAVE_LIBUNWIND_IA64_H 1
7141 _ACEOF
7145 done
7147 if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
7148 as_fn_error $? "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
7150 CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
7151 CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
7152 CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
7155 opt_curses=no
7157 # Check whether --with-curses was given.
7158 if test "${with_curses+set}" = set; then :
7159 withval=$with_curses; opt_curses=$withval
7163 prefer_curses=no
7164 if test "$opt_curses" = "yes"; then
7165 prefer_curses=yes
7168 # Profiling support.
7169 # Check whether --enable-profiling was given.
7170 if test "${enable_profiling+set}" = set; then :
7171 enableval=$enable_profiling; case $enableval in
7172 yes | no)
7175 as_fn_error $? "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
7176 esac
7177 else
7178 enable_profiling=no
7182 for ac_func in monstartup _mcleanup
7183 do :
7184 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7185 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7186 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7187 cat >>confdefs.h <<_ACEOF
7188 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7189 _ACEOF
7192 done
7194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
7195 $as_echo_n "checking for _etext... " >&6; }
7196 if ${ac_cv_var__etext+:} false; then :
7197 $as_echo_n "(cached) " >&6
7198 else
7199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7200 /* end confdefs.h. */
7201 #include <stdlib.h>
7202 extern char _etext;
7204 main ()
7206 free (&_etext);
7209 return 0;
7211 _ACEOF
7212 if ac_fn_c_try_link "$LINENO"; then :
7213 ac_cv_var__etext=yes
7214 else
7215 ac_cv_var__etext=no
7218 rm -f core conftest.err conftest.$ac_objext \
7219 conftest$ac_exeext conftest.$ac_ext
7222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
7223 $as_echo "$ac_cv_var__etext" >&6; }
7224 if test "$ac_cv_var__etext" = yes; then
7226 $as_echo "#define HAVE__ETEXT 1" >>confdefs.h
7229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
7230 $as_echo_n "checking for etext... " >&6; }
7231 if ${ac_cv_var_etext+:} false; then :
7232 $as_echo_n "(cached) " >&6
7233 else
7234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7235 /* end confdefs.h. */
7236 #include <stdlib.h>
7237 extern char etext;
7239 main ()
7241 free (&etext);
7244 return 0;
7246 _ACEOF
7247 if ac_fn_c_try_link "$LINENO"; then :
7248 ac_cv_var_etext=yes
7249 else
7250 ac_cv_var_etext=no
7253 rm -f core conftest.err conftest.$ac_objext \
7254 conftest$ac_exeext conftest.$ac_ext
7257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
7258 $as_echo "$ac_cv_var_etext" >&6; }
7259 if test "$ac_cv_var_etext" = yes; then
7261 $as_echo "#define HAVE_ETEXT 1" >>confdefs.h
7264 if test "$enable_profiling" = yes ; then
7265 if test "$ac_cv_func_monstartup" = no || test "$ac_cv_func__mcleanup" = no; then
7266 as_fn_error $? "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
7268 PROFILE_CFLAGS=-pg
7269 OLD_CFLAGS="$CFLAGS"
7270 CFLAGS="$CFLAGS $PROFILE_CFLAGS"
7272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
7273 $as_echo_n "checking whether $CC supports -pg... " >&6; }
7274 if ${ac_cv_cc_supports_pg+:} false; then :
7275 $as_echo_n "(cached) " >&6
7276 else
7277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7278 /* end confdefs.h. */
7281 main ()
7283 int x;
7285 return 0;
7287 _ACEOF
7288 if ac_fn_c_try_compile "$LINENO"; then :
7289 ac_cv_cc_supports_pg=yes
7290 else
7291 ac_cv_cc_supports_pg=no
7294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
7298 $as_echo "$ac_cv_cc_supports_pg" >&6; }
7300 if test "$ac_cv_cc_supports_pg" = no; then
7301 as_fn_error $? "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
7304 CFLAGS="$OLD_CFLAGS"
7307 CODESIGN_CERT=
7308 # Check whether --enable-codesign was given.
7309 if test "${enable_codesign+set}" = set; then :
7310 enableval=$enable_codesign; CODESIGN_CERT=$enableval
7317 # Check whether --with-pkgversion was given.
7318 if test "${with_pkgversion+set}" = set; then :
7319 withval=$with_pkgversion; case "$withval" in
7320 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
7321 no) PKGVERSION= ;;
7322 *) PKGVERSION="($withval) " ;;
7323 esac
7324 else
7325 PKGVERSION="(GDB) "
7333 # Check whether --with-bugurl was given.
7334 if test "${with_bugurl+set}" = set; then :
7335 withval=$with_bugurl; case "$withval" in
7336 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
7337 no) BUGURL=
7339 *) BUGURL="$withval"
7341 esac
7342 else
7343 BUGURL="https://www.gnu.org/software/gdb/bugs/"
7347 case ${BUGURL} in
7349 REPORT_BUGS_TO=
7350 REPORT_BUGS_TEXI=
7353 REPORT_BUGS_TO="<$BUGURL>"
7354 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
7356 esac;
7361 cat >>confdefs.h <<_ACEOF
7362 #define PKGVERSION "$PKGVERSION"
7363 _ACEOF
7366 cat >>confdefs.h <<_ACEOF
7367 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
7368 _ACEOF
7371 # --------------------- #
7372 # Checks for programs. #
7373 # --------------------- #
7375 for ac_prog in gawk mawk nawk awk
7377 # Extract the first word of "$ac_prog", so it can be a program name with args.
7378 set dummy $ac_prog; ac_word=$2
7379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7380 $as_echo_n "checking for $ac_word... " >&6; }
7381 if ${ac_cv_prog_AWK+:} false; then :
7382 $as_echo_n "(cached) " >&6
7383 else
7384 if test -n "$AWK"; then
7385 ac_cv_prog_AWK="$AWK" # Let the user override the test.
7386 else
7387 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7388 for as_dir in $PATH
7390 IFS=$as_save_IFS
7391 test -z "$as_dir" && as_dir=.
7392 for ac_exec_ext in '' $ac_executable_extensions; do
7393 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7394 ac_cv_prog_AWK="$ac_prog"
7395 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7396 break 2
7398 done
7399 done
7400 IFS=$as_save_IFS
7404 AWK=$ac_cv_prog_AWK
7405 if test -n "$AWK"; then
7406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
7407 $as_echo "$AWK" >&6; }
7408 else
7409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7410 $as_echo "no" >&6; }
7414 test -n "$AWK" && break
7415 done
7417 # Find a good install program. We prefer a C program (faster),
7418 # so one script is as good as another. But avoid the broken or
7419 # incompatible versions:
7420 # SysV /etc/install, /usr/sbin/install
7421 # SunOS /usr/etc/install
7422 # IRIX /sbin/install
7423 # AIX /bin/install
7424 # AmigaOS /C/install, which installs bootblocks on floppy discs
7425 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
7426 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
7427 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
7428 # OS/2's system install, which has a completely different semantic
7429 # ./install, which can be erroneously created by make from ./install.sh.
7430 # Reject install programs that cannot install multiple files.
7431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
7432 $as_echo_n "checking for a BSD-compatible install... " >&6; }
7433 if test -z "$INSTALL"; then
7434 if ${ac_cv_path_install+:} false; then :
7435 $as_echo_n "(cached) " >&6
7436 else
7437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7438 for as_dir in $PATH
7440 IFS=$as_save_IFS
7441 test -z "$as_dir" && as_dir=.
7442 # Account for people who put trailing slashes in PATH elements.
7443 case $as_dir/ in #((
7444 ./ | .// | /[cC]/* | \
7445 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
7446 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
7447 /usr/ucb/* ) ;;
7449 # OSF1 and SCO ODT 3.0 have their own names for install.
7450 # Don't use installbsd from OSF since it installs stuff as root
7451 # by default.
7452 for ac_prog in ginstall scoinst install; do
7453 for ac_exec_ext in '' $ac_executable_extensions; do
7454 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
7455 if test $ac_prog = install &&
7456 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7457 # AIX install. It has an incompatible calling convention.
7459 elif test $ac_prog = install &&
7460 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7461 # program-specific install script used by HP pwplus--don't use.
7463 else
7464 rm -rf conftest.one conftest.two conftest.dir
7465 echo one > conftest.one
7466 echo two > conftest.two
7467 mkdir conftest.dir
7468 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
7469 test -s conftest.one && test -s conftest.two &&
7470 test -s conftest.dir/conftest.one &&
7471 test -s conftest.dir/conftest.two
7472 then
7473 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
7474 break 3
7478 done
7479 done
7481 esac
7483 done
7484 IFS=$as_save_IFS
7486 rm -rf conftest.one conftest.two conftest.dir
7489 if test "${ac_cv_path_install+set}" = set; then
7490 INSTALL=$ac_cv_path_install
7491 else
7492 # As a last resort, use the slow shell script. Don't cache a
7493 # value for INSTALL within a source directory, because that will
7494 # break other packages using the cache if that directory is
7495 # removed, or if the value is a relative name.
7496 INSTALL=$ac_install_sh
7499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
7500 $as_echo "$INSTALL" >&6; }
7502 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
7503 # It thinks the first close brace ends the variable substitution.
7504 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
7506 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
7508 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
7510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7511 $as_echo_n "checking whether ln -s works... " >&6; }
7512 LN_S=$as_ln_s
7513 if test "$LN_S" = "ln -s"; then
7514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7515 $as_echo "yes" >&6; }
7516 else
7517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7518 $as_echo "no, using $LN_S" >&6; }
7521 if test -n "$ac_tool_prefix"; then
7522 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7523 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7525 $as_echo_n "checking for $ac_word... " >&6; }
7526 if ${ac_cv_prog_RANLIB+:} false; then :
7527 $as_echo_n "(cached) " >&6
7528 else
7529 if test -n "$RANLIB"; then
7530 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7531 else
7532 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7533 for as_dir in $PATH
7535 IFS=$as_save_IFS
7536 test -z "$as_dir" && as_dir=.
7537 for ac_exec_ext in '' $ac_executable_extensions; do
7538 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7539 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7540 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7541 break 2
7543 done
7544 done
7545 IFS=$as_save_IFS
7549 RANLIB=$ac_cv_prog_RANLIB
7550 if test -n "$RANLIB"; then
7551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7552 $as_echo "$RANLIB" >&6; }
7553 else
7554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7555 $as_echo "no" >&6; }
7560 if test -z "$ac_cv_prog_RANLIB"; then
7561 ac_ct_RANLIB=$RANLIB
7562 # Extract the first word of "ranlib", so it can be a program name with args.
7563 set dummy ranlib; ac_word=$2
7564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7565 $as_echo_n "checking for $ac_word... " >&6; }
7566 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
7567 $as_echo_n "(cached) " >&6
7568 else
7569 if test -n "$ac_ct_RANLIB"; then
7570 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7571 else
7572 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7573 for as_dir in $PATH
7575 IFS=$as_save_IFS
7576 test -z "$as_dir" && as_dir=.
7577 for ac_exec_ext in '' $ac_executable_extensions; do
7578 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7579 ac_cv_prog_ac_ct_RANLIB="ranlib"
7580 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7581 break 2
7583 done
7584 done
7585 IFS=$as_save_IFS
7589 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7590 if test -n "$ac_ct_RANLIB"; then
7591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7592 $as_echo "$ac_ct_RANLIB" >&6; }
7593 else
7594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7595 $as_echo "no" >&6; }
7598 if test "x$ac_ct_RANLIB" = x; then
7599 RANLIB=":"
7600 else
7601 case $cross_compiling:$ac_tool_warned in
7602 yes:)
7603 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7604 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7605 ac_tool_warned=yes ;;
7606 esac
7607 RANLIB=$ac_ct_RANLIB
7609 else
7610 RANLIB="$ac_cv_prog_RANLIB"
7613 for ac_prog in 'bison -y' byacc
7615 # Extract the first word of "$ac_prog", so it can be a program name with args.
7616 set dummy $ac_prog; ac_word=$2
7617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7618 $as_echo_n "checking for $ac_word... " >&6; }
7619 if ${ac_cv_prog_YACC+:} false; then :
7620 $as_echo_n "(cached) " >&6
7621 else
7622 if test -n "$YACC"; then
7623 ac_cv_prog_YACC="$YACC" # Let the user override the test.
7624 else
7625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7626 for as_dir in $PATH
7628 IFS=$as_save_IFS
7629 test -z "$as_dir" && as_dir=.
7630 for ac_exec_ext in '' $ac_executable_extensions; do
7631 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7632 ac_cv_prog_YACC="$ac_prog"
7633 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7634 break 2
7636 done
7637 done
7638 IFS=$as_save_IFS
7642 YACC=$ac_cv_prog_YACC
7643 if test -n "$YACC"; then
7644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
7645 $as_echo "$YACC" >&6; }
7646 else
7647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7648 $as_echo "no" >&6; }
7652 test -n "$YACC" && break
7653 done
7654 test -n "$YACC" || YACC="yacc"
7657 if test -n "$ac_tool_prefix"; then
7658 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7659 set dummy ${ac_tool_prefix}ar; ac_word=$2
7660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7661 $as_echo_n "checking for $ac_word... " >&6; }
7662 if ${ac_cv_prog_AR+:} false; then :
7663 $as_echo_n "(cached) " >&6
7664 else
7665 if test -n "$AR"; then
7666 ac_cv_prog_AR="$AR" # Let the user override the test.
7667 else
7668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7669 for as_dir in $PATH
7671 IFS=$as_save_IFS
7672 test -z "$as_dir" && as_dir=.
7673 for ac_exec_ext in '' $ac_executable_extensions; do
7674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7675 ac_cv_prog_AR="${ac_tool_prefix}ar"
7676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7677 break 2
7679 done
7680 done
7681 IFS=$as_save_IFS
7685 AR=$ac_cv_prog_AR
7686 if test -n "$AR"; then
7687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7688 $as_echo "$AR" >&6; }
7689 else
7690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7691 $as_echo "no" >&6; }
7696 if test -z "$ac_cv_prog_AR"; then
7697 ac_ct_AR=$AR
7698 # Extract the first word of "ar", so it can be a program name with args.
7699 set dummy ar; ac_word=$2
7700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7701 $as_echo_n "checking for $ac_word... " >&6; }
7702 if ${ac_cv_prog_ac_ct_AR+:} false; then :
7703 $as_echo_n "(cached) " >&6
7704 else
7705 if test -n "$ac_ct_AR"; then
7706 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7707 else
7708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7709 for as_dir in $PATH
7711 IFS=$as_save_IFS
7712 test -z "$as_dir" && as_dir=.
7713 for ac_exec_ext in '' $ac_executable_extensions; do
7714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7715 ac_cv_prog_ac_ct_AR="ar"
7716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7717 break 2
7719 done
7720 done
7721 IFS=$as_save_IFS
7725 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7726 if test -n "$ac_ct_AR"; then
7727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7728 $as_echo "$ac_ct_AR" >&6; }
7729 else
7730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7731 $as_echo "no" >&6; }
7734 if test "x$ac_ct_AR" = x; then
7735 AR=""
7736 else
7737 case $cross_compiling:$ac_tool_warned in
7738 yes:)
7739 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7740 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7741 ac_tool_warned=yes ;;
7742 esac
7743 AR=$ac_ct_AR
7745 else
7746 AR="$ac_cv_prog_AR"
7749 if test -n "$ac_tool_prefix"; then
7750 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
7751 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
7752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7753 $as_echo_n "checking for $ac_word... " >&6; }
7754 if ${ac_cv_prog_DLLTOOL+:} false; then :
7755 $as_echo_n "(cached) " >&6
7756 else
7757 if test -n "$DLLTOOL"; then
7758 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
7759 else
7760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7761 for as_dir in $PATH
7763 IFS=$as_save_IFS
7764 test -z "$as_dir" && as_dir=.
7765 for ac_exec_ext in '' $ac_executable_extensions; do
7766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7767 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
7768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7769 break 2
7771 done
7772 done
7773 IFS=$as_save_IFS
7777 DLLTOOL=$ac_cv_prog_DLLTOOL
7778 if test -n "$DLLTOOL"; then
7779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
7780 $as_echo "$DLLTOOL" >&6; }
7781 else
7782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7783 $as_echo "no" >&6; }
7788 if test -z "$ac_cv_prog_DLLTOOL"; then
7789 ac_ct_DLLTOOL=$DLLTOOL
7790 # Extract the first word of "dlltool", so it can be a program name with args.
7791 set dummy dlltool; ac_word=$2
7792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7793 $as_echo_n "checking for $ac_word... " >&6; }
7794 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
7795 $as_echo_n "(cached) " >&6
7796 else
7797 if test -n "$ac_ct_DLLTOOL"; then
7798 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
7799 else
7800 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7801 for as_dir in $PATH
7803 IFS=$as_save_IFS
7804 test -z "$as_dir" && as_dir=.
7805 for ac_exec_ext in '' $ac_executable_extensions; do
7806 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7807 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
7808 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7809 break 2
7811 done
7812 done
7813 IFS=$as_save_IFS
7817 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
7818 if test -n "$ac_ct_DLLTOOL"; then
7819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
7820 $as_echo "$ac_ct_DLLTOOL" >&6; }
7821 else
7822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7823 $as_echo "no" >&6; }
7826 if test "x$ac_ct_DLLTOOL" = x; then
7827 DLLTOOL=""
7828 else
7829 case $cross_compiling:$ac_tool_warned in
7830 yes:)
7831 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7832 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7833 ac_tool_warned=yes ;;
7834 esac
7835 DLLTOOL=$ac_ct_DLLTOOL
7837 else
7838 DLLTOOL="$ac_cv_prog_DLLTOOL"
7841 if test -n "$ac_tool_prefix"; then
7842 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
7843 set dummy ${ac_tool_prefix}windres; ac_word=$2
7844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7845 $as_echo_n "checking for $ac_word... " >&6; }
7846 if ${ac_cv_prog_WINDRES+:} false; then :
7847 $as_echo_n "(cached) " >&6
7848 else
7849 if test -n "$WINDRES"; then
7850 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
7851 else
7852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7853 for as_dir in $PATH
7855 IFS=$as_save_IFS
7856 test -z "$as_dir" && as_dir=.
7857 for ac_exec_ext in '' $ac_executable_extensions; do
7858 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7859 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
7860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7861 break 2
7863 done
7864 done
7865 IFS=$as_save_IFS
7869 WINDRES=$ac_cv_prog_WINDRES
7870 if test -n "$WINDRES"; then
7871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
7872 $as_echo "$WINDRES" >&6; }
7873 else
7874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7875 $as_echo "no" >&6; }
7880 if test -z "$ac_cv_prog_WINDRES"; then
7881 ac_ct_WINDRES=$WINDRES
7882 # Extract the first word of "windres", so it can be a program name with args.
7883 set dummy windres; ac_word=$2
7884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7885 $as_echo_n "checking for $ac_word... " >&6; }
7886 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
7887 $as_echo_n "(cached) " >&6
7888 else
7889 if test -n "$ac_ct_WINDRES"; then
7890 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
7891 else
7892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7893 for as_dir in $PATH
7895 IFS=$as_save_IFS
7896 test -z "$as_dir" && as_dir=.
7897 for ac_exec_ext in '' $ac_executable_extensions; do
7898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7899 ac_cv_prog_ac_ct_WINDRES="windres"
7900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7901 break 2
7903 done
7904 done
7905 IFS=$as_save_IFS
7909 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
7910 if test -n "$ac_ct_WINDRES"; then
7911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
7912 $as_echo "$ac_ct_WINDRES" >&6; }
7913 else
7914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7915 $as_echo "no" >&6; }
7918 if test "x$ac_ct_WINDRES" = x; then
7919 WINDRES=""
7920 else
7921 case $cross_compiling:$ac_tool_warned in
7922 yes:)
7923 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7924 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7925 ac_tool_warned=yes ;;
7926 esac
7927 WINDRES=$ac_ct_WINDRES
7929 else
7930 WINDRES="$ac_cv_prog_WINDRES"
7934 case $host_os in
7935 gnu*)
7936 # Needed for GNU Hurd hosts.
7937 if test -n "$ac_tool_prefix"; then
7938 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
7939 set dummy ${ac_tool_prefix}mig; ac_word=$2
7940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7941 $as_echo_n "checking for $ac_word... " >&6; }
7942 if ${ac_cv_prog_MIG+:} false; then :
7943 $as_echo_n "(cached) " >&6
7944 else
7945 if test -n "$MIG"; then
7946 ac_cv_prog_MIG="$MIG" # Let the user override the test.
7947 else
7948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7949 for as_dir in $PATH
7951 IFS=$as_save_IFS
7952 test -z "$as_dir" && as_dir=.
7953 for ac_exec_ext in '' $ac_executable_extensions; do
7954 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7955 ac_cv_prog_MIG="${ac_tool_prefix}mig"
7956 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7957 break 2
7959 done
7960 done
7961 IFS=$as_save_IFS
7965 MIG=$ac_cv_prog_MIG
7966 if test -n "$MIG"; then
7967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
7968 $as_echo "$MIG" >&6; }
7969 else
7970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7971 $as_echo "no" >&6; }
7976 if test -z "$ac_cv_prog_MIG"; then
7977 ac_ct_MIG=$MIG
7978 # Extract the first word of "mig", so it can be a program name with args.
7979 set dummy mig; ac_word=$2
7980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7981 $as_echo_n "checking for $ac_word... " >&6; }
7982 if ${ac_cv_prog_ac_ct_MIG+:} false; then :
7983 $as_echo_n "(cached) " >&6
7984 else
7985 if test -n "$ac_ct_MIG"; then
7986 ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
7987 else
7988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7989 for as_dir in $PATH
7991 IFS=$as_save_IFS
7992 test -z "$as_dir" && as_dir=.
7993 for ac_exec_ext in '' $ac_executable_extensions; do
7994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7995 ac_cv_prog_ac_ct_MIG="mig"
7996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7997 break 2
7999 done
8000 done
8001 IFS=$as_save_IFS
8005 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
8006 if test -n "$ac_ct_MIG"; then
8007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
8008 $as_echo "$ac_ct_MIG" >&6; }
8009 else
8010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8011 $as_echo "no" >&6; }
8014 if test "x$ac_ct_MIG" = x; then
8015 MIG=""
8016 else
8017 case $cross_compiling:$ac_tool_warned in
8018 yes:)
8019 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8020 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8021 ac_tool_warned=yes ;;
8022 esac
8023 MIG=$ac_ct_MIG
8025 else
8026 MIG="$ac_cv_prog_MIG"
8029 if test x"$MIG" = x; then
8030 as_fn_error $? "MIG not found but required for $host hosts" "$LINENO" 5
8033 esac
8035 # ---------------------- #
8036 # Checks for libraries. #
8037 # ---------------------- #
8039 # We might need to link with -lm; most simulators need it.
8040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
8041 $as_echo_n "checking for main in -lm... " >&6; }
8042 if ${ac_cv_lib_m_main+:} false; then :
8043 $as_echo_n "(cached) " >&6
8044 else
8045 ac_check_lib_save_LIBS=$LIBS
8046 LIBS="-lm $LIBS"
8047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8048 /* end confdefs.h. */
8052 main ()
8054 return main ();
8056 return 0;
8058 _ACEOF
8059 if ac_fn_c_try_link "$LINENO"; then :
8060 ac_cv_lib_m_main=yes
8061 else
8062 ac_cv_lib_m_main=no
8064 rm -f core conftest.err conftest.$ac_objext \
8065 conftest$ac_exeext conftest.$ac_ext
8066 LIBS=$ac_check_lib_save_LIBS
8068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
8069 $as_echo "$ac_cv_lib_m_main" >&6; }
8070 if test "x$ac_cv_lib_m_main" = xyes; then :
8071 cat >>confdefs.h <<_ACEOF
8072 #define HAVE_LIBM 1
8073 _ACEOF
8075 LIBS="-lm $LIBS"
8080 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
8081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
8082 $as_echo_n "checking for library containing gethostbyname... " >&6; }
8083 if ${ac_cv_search_gethostbyname+:} false; then :
8084 $as_echo_n "(cached) " >&6
8085 else
8086 ac_func_search_save_LIBS=$LIBS
8087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8088 /* end confdefs.h. */
8090 /* Override any GCC internal prototype to avoid an error.
8091 Use char because int might match the return type of a GCC
8092 builtin and then its argument prototype would still apply. */
8093 #ifdef __cplusplus
8094 extern "C"
8095 #endif
8096 char gethostbyname ();
8098 main ()
8100 return gethostbyname ();
8102 return 0;
8104 _ACEOF
8105 for ac_lib in '' nsl; do
8106 if test -z "$ac_lib"; then
8107 ac_res="none required"
8108 else
8109 ac_res=-l$ac_lib
8110 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8112 if ac_fn_c_try_link "$LINENO"; then :
8113 ac_cv_search_gethostbyname=$ac_res
8115 rm -f core conftest.err conftest.$ac_objext \
8116 conftest$ac_exeext
8117 if ${ac_cv_search_gethostbyname+:} false; then :
8118 break
8120 done
8121 if ${ac_cv_search_gethostbyname+:} false; then :
8123 else
8124 ac_cv_search_gethostbyname=no
8126 rm conftest.$ac_ext
8127 LIBS=$ac_func_search_save_LIBS
8129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
8130 $as_echo "$ac_cv_search_gethostbyname" >&6; }
8131 ac_res=$ac_cv_search_gethostbyname
8132 if test "$ac_res" != no; then :
8133 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8138 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
8139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
8140 $as_echo_n "checking for library containing socketpair... " >&6; }
8141 if ${ac_cv_search_socketpair+:} false; then :
8142 $as_echo_n "(cached) " >&6
8143 else
8144 ac_func_search_save_LIBS=$LIBS
8145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8146 /* end confdefs.h. */
8148 /* Override any GCC internal prototype to avoid an error.
8149 Use char because int might match the return type of a GCC
8150 builtin and then its argument prototype would still apply. */
8151 #ifdef __cplusplus
8152 extern "C"
8153 #endif
8154 char socketpair ();
8156 main ()
8158 return socketpair ();
8160 return 0;
8162 _ACEOF
8163 for ac_lib in '' socket; do
8164 if test -z "$ac_lib"; then
8165 ac_res="none required"
8166 else
8167 ac_res=-l$ac_lib
8168 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8170 if ac_fn_c_try_link "$LINENO"; then :
8171 ac_cv_search_socketpair=$ac_res
8173 rm -f core conftest.err conftest.$ac_objext \
8174 conftest$ac_exeext
8175 if ${ac_cv_search_socketpair+:} false; then :
8176 break
8178 done
8179 if ${ac_cv_search_socketpair+:} false; then :
8181 else
8182 ac_cv_search_socketpair=no
8184 rm conftest.$ac_ext
8185 LIBS=$ac_func_search_save_LIBS
8187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
8188 $as_echo "$ac_cv_search_socketpair" >&6; }
8189 ac_res=$ac_cv_search_socketpair
8190 if test "$ac_res" != no; then :
8191 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8196 # Link in zlib if we can. This allows us to read compressed debug sections.
8198 # Use the system's zlib library.
8199 zlibdir="-L\$(top_builddir)/../zlib"
8200 zlibinc="-I\$(top_srcdir)/../zlib"
8202 # Check whether --with-system-zlib was given.
8203 if test "${with_system_zlib+set}" = set; then :
8204 withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
8205 zlibdir=
8206 zlibinc=
8216 if test "X$prefix" = "XNONE"; then
8217 acl_final_prefix="$ac_default_prefix"
8218 else
8219 acl_final_prefix="$prefix"
8221 if test "X$exec_prefix" = "XNONE"; then
8222 acl_final_exec_prefix='${prefix}'
8223 else
8224 acl_final_exec_prefix="$exec_prefix"
8226 acl_save_prefix="$prefix"
8227 prefix="$acl_final_prefix"
8228 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8229 prefix="$acl_save_prefix"
8232 # Check whether --with-gnu-ld was given.
8233 if test "${with_gnu_ld+set}" = set; then :
8234 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8235 else
8236 with_gnu_ld=no
8239 # Prepare PATH_SEPARATOR.
8240 # The user is always right.
8241 if test "${PATH_SEPARATOR+set}" != set; then
8242 echo "#! /bin/sh" >conf$$.sh
8243 echo "exit 0" >>conf$$.sh
8244 chmod +x conf$$.sh
8245 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
8246 PATH_SEPARATOR=';'
8247 else
8248 PATH_SEPARATOR=:
8250 rm -f conf$$.sh
8252 ac_prog=ld
8253 if test "$GCC" = yes; then
8254 # Check if gcc -print-prog-name=ld gives a path.
8255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8256 $as_echo_n "checking for ld used by GCC... " >&6; }
8257 case $host in
8258 *-*-mingw*)
8259 # gcc leaves a trailing carriage return which upsets mingw
8260 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8262 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8263 esac
8264 case $ac_prog in
8265 # Accept absolute paths.
8266 [\\/]* | [A-Za-z]:[\\/]*)
8267 re_direlt='/[^/][^/]*/\.\./'
8268 # Canonicalize the path of ld
8269 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8270 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8271 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8272 done
8273 test -z "$LD" && LD="$ac_prog"
8276 # If it fails, then pretend we aren't using GCC.
8277 ac_prog=ld
8280 # If it is relative, then search for the first ld in PATH.
8281 with_gnu_ld=unknown
8283 esac
8284 elif test "$with_gnu_ld" = yes; then
8285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8286 $as_echo_n "checking for GNU ld... " >&6; }
8287 else
8288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8289 $as_echo_n "checking for non-GNU ld... " >&6; }
8291 if ${acl_cv_path_LD+:} false; then :
8292 $as_echo_n "(cached) " >&6
8293 else
8294 if test -z "$LD"; then
8295 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8296 for ac_dir in $PATH; do
8297 test -z "$ac_dir" && ac_dir=.
8298 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8299 acl_cv_path_LD="$ac_dir/$ac_prog"
8300 # Check to see if the program is GNU ld. I'd rather use --version,
8301 # but apparently some GNU ld's only accept -v.
8302 # Break only if it was the GNU/non-GNU ld that we prefer.
8303 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8304 test "$with_gnu_ld" != no && break
8305 else
8306 test "$with_gnu_ld" != yes && break
8309 done
8310 IFS="$ac_save_ifs"
8311 else
8312 acl_cv_path_LD="$LD" # Let the user override the test with a path.
8316 LD="$acl_cv_path_LD"
8317 if test -n "$LD"; then
8318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8319 $as_echo "$LD" >&6; }
8320 else
8321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8322 $as_echo "no" >&6; }
8324 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8326 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8327 if ${acl_cv_prog_gnu_ld+:} false; then :
8328 $as_echo_n "(cached) " >&6
8329 else
8330 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8331 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8332 acl_cv_prog_gnu_ld=yes
8333 else
8334 acl_cv_prog_gnu_ld=no
8337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8338 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
8339 with_gnu_ld=$acl_cv_prog_gnu_ld
8343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8344 $as_echo_n "checking for shared library run path origin... " >&6; }
8345 if ${acl_cv_rpath+:} false; then :
8346 $as_echo_n "(cached) " >&6
8347 else
8349 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8350 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8351 . ./conftest.sh
8352 rm -f ./conftest.sh
8353 acl_cv_rpath=done
8356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8357 $as_echo "$acl_cv_rpath" >&6; }
8358 wl="$acl_cv_wl"
8359 libext="$acl_cv_libext"
8360 shlibext="$acl_cv_shlibext"
8361 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8362 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8363 hardcode_direct="$acl_cv_hardcode_direct"
8364 hardcode_minus_L="$acl_cv_hardcode_minus_L"
8365 # Check whether --enable-rpath was given.
8366 if test "${enable_rpath+set}" = set; then :
8367 enableval=$enable_rpath; :
8368 else
8369 enable_rpath=yes
8379 use_additional=yes
8381 acl_save_prefix="$prefix"
8382 prefix="$acl_final_prefix"
8383 acl_save_exec_prefix="$exec_prefix"
8384 exec_prefix="$acl_final_exec_prefix"
8386 eval additional_includedir=\"$includedir\"
8387 eval additional_libdir=\"$libdir\"
8389 exec_prefix="$acl_save_exec_prefix"
8390 prefix="$acl_save_prefix"
8393 # Check whether --with-libiconv-prefix was given.
8394 if test "${with_libiconv_prefix+set}" = set; then :
8395 withval=$with_libiconv_prefix;
8396 if test "X$withval" = "Xno"; then
8397 use_additional=no
8398 else
8399 if test "X$withval" = "X"; then
8401 acl_save_prefix="$prefix"
8402 prefix="$acl_final_prefix"
8403 acl_save_exec_prefix="$exec_prefix"
8404 exec_prefix="$acl_final_exec_prefix"
8406 eval additional_includedir=\"$includedir\"
8407 eval additional_libdir=\"$libdir\"
8409 exec_prefix="$acl_save_exec_prefix"
8410 prefix="$acl_save_prefix"
8412 else
8413 additional_includedir="$withval/include"
8414 additional_libdir="$withval/lib"
8421 # Check whether --with-libiconv-type was given.
8422 if test "${with_libiconv_type+set}" = set; then :
8423 withval=$with_libiconv_type; with_libiconv_type=$withval
8424 else
8425 with_libiconv_type=auto
8428 lib_type=`eval echo \$with_libiconv_type`
8430 LIBICONV=
8431 LTLIBICONV=
8432 INCICONV=
8433 rpathdirs=
8434 ltrpathdirs=
8435 names_already_handled=
8436 names_next_round='iconv '
8437 while test -n "$names_next_round"; do
8438 names_this_round="$names_next_round"
8439 names_next_round=
8440 for name in $names_this_round; do
8441 already_handled=
8442 for n in $names_already_handled; do
8443 if test "$n" = "$name"; then
8444 already_handled=yes
8445 break
8447 done
8448 if test -z "$already_handled"; then
8449 names_already_handled="$names_already_handled $name"
8450 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
8451 eval value=\"\$HAVE_LIB$uppername\"
8452 if test -n "$value"; then
8453 if test "$value" = yes; then
8454 eval value=\"\$LIB$uppername\"
8455 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
8456 eval value=\"\$LTLIB$uppername\"
8457 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
8458 else
8461 else
8462 found_dir=
8463 found_la=
8464 found_so=
8465 found_a=
8466 if test $use_additional = yes; then
8467 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
8468 found_dir="$additional_libdir"
8469 found_so="$additional_libdir/lib$name.$shlibext"
8470 if test -f "$additional_libdir/lib$name.la"; then
8471 found_la="$additional_libdir/lib$name.la"
8473 elif test x$lib_type != xshared; then
8474 if test -f "$additional_libdir/lib$name.$libext"; then
8475 found_dir="$additional_libdir"
8476 found_a="$additional_libdir/lib$name.$libext"
8477 if test -f "$additional_libdir/lib$name.la"; then
8478 found_la="$additional_libdir/lib$name.la"
8483 if test "X$found_dir" = "X"; then
8484 for x in $LDFLAGS $LTLIBICONV; do
8486 acl_save_prefix="$prefix"
8487 prefix="$acl_final_prefix"
8488 acl_save_exec_prefix="$exec_prefix"
8489 exec_prefix="$acl_final_exec_prefix"
8490 eval x=\"$x\"
8491 exec_prefix="$acl_save_exec_prefix"
8492 prefix="$acl_save_prefix"
8494 case "$x" in
8495 -L*)
8496 dir=`echo "X$x" | sed -e 's/^X-L//'`
8497 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
8498 found_dir="$dir"
8499 found_so="$dir/lib$name.$shlibext"
8500 if test -f "$dir/lib$name.la"; then
8501 found_la="$dir/lib$name.la"
8503 elif test x$lib_type != xshared; then
8504 if test -f "$dir/lib$name.$libext"; then
8505 found_dir="$dir"
8506 found_a="$dir/lib$name.$libext"
8507 if test -f "$dir/lib$name.la"; then
8508 found_la="$dir/lib$name.la"
8513 esac
8514 if test "X$found_dir" != "X"; then
8515 break
8517 done
8519 if test "X$found_dir" != "X"; then
8520 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
8521 if test "X$found_so" != "X"; then
8522 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
8523 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8524 else
8525 haveit=
8526 for x in $ltrpathdirs; do
8527 if test "X$x" = "X$found_dir"; then
8528 haveit=yes
8529 break
8531 done
8532 if test -z "$haveit"; then
8533 ltrpathdirs="$ltrpathdirs $found_dir"
8535 if test "$hardcode_direct" = yes; then
8536 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8537 else
8538 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
8539 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8540 haveit=
8541 for x in $rpathdirs; do
8542 if test "X$x" = "X$found_dir"; then
8543 haveit=yes
8544 break
8546 done
8547 if test -z "$haveit"; then
8548 rpathdirs="$rpathdirs $found_dir"
8550 else
8551 haveit=
8552 for x in $LDFLAGS $LIBICONV; do
8554 acl_save_prefix="$prefix"
8555 prefix="$acl_final_prefix"
8556 acl_save_exec_prefix="$exec_prefix"
8557 exec_prefix="$acl_final_exec_prefix"
8558 eval x=\"$x\"
8559 exec_prefix="$acl_save_exec_prefix"
8560 prefix="$acl_save_prefix"
8562 if test "X$x" = "X-L$found_dir"; then
8563 haveit=yes
8564 break
8566 done
8567 if test -z "$haveit"; then
8568 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
8570 if test "$hardcode_minus_L" != no; then
8571 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8572 else
8573 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8578 else
8579 if test "X$found_a" != "X"; then
8580 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
8581 else
8582 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
8585 additional_includedir=
8586 case "$found_dir" in
8587 */lib | */lib/)
8588 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
8589 additional_includedir="$basedir/include"
8591 esac
8592 if test "X$additional_includedir" != "X"; then
8593 if test "X$additional_includedir" != "X/usr/include"; then
8594 haveit=
8595 if test "X$additional_includedir" = "X/usr/local/include"; then
8596 if test -n "$GCC"; then
8597 case $host_os in
8598 linux*) haveit=yes;;
8599 esac
8602 if test -z "$haveit"; then
8603 for x in $CPPFLAGS $INCICONV; do
8605 acl_save_prefix="$prefix"
8606 prefix="$acl_final_prefix"
8607 acl_save_exec_prefix="$exec_prefix"
8608 exec_prefix="$acl_final_exec_prefix"
8609 eval x=\"$x\"
8610 exec_prefix="$acl_save_exec_prefix"
8611 prefix="$acl_save_prefix"
8613 if test "X$x" = "X-I$additional_includedir"; then
8614 haveit=yes
8615 break
8617 done
8618 if test -z "$haveit"; then
8619 if test -d "$additional_includedir"; then
8620 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
8626 if test -n "$found_la"; then
8627 save_libdir="$libdir"
8628 case "$found_la" in
8629 */* | *\\*) . "$found_la" ;;
8630 *) . "./$found_la" ;;
8631 esac
8632 libdir="$save_libdir"
8633 for dep in $dependency_libs; do
8634 case "$dep" in
8635 -L*)
8636 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
8637 if test "X$additional_libdir" != "X/usr/lib"; then
8638 haveit=
8639 if test "X$additional_libdir" = "X/usr/local/lib"; then
8640 if test -n "$GCC"; then
8641 case $host_os in
8642 linux*) haveit=yes;;
8643 esac
8646 if test -z "$haveit"; then
8647 haveit=
8648 for x in $LDFLAGS $LIBICONV; do
8650 acl_save_prefix="$prefix"
8651 prefix="$acl_final_prefix"
8652 acl_save_exec_prefix="$exec_prefix"
8653 exec_prefix="$acl_final_exec_prefix"
8654 eval x=\"$x\"
8655 exec_prefix="$acl_save_exec_prefix"
8656 prefix="$acl_save_prefix"
8658 if test "X$x" = "X-L$additional_libdir"; then
8659 haveit=yes
8660 break
8662 done
8663 if test -z "$haveit"; then
8664 if test -d "$additional_libdir"; then
8665 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
8668 haveit=
8669 for x in $LDFLAGS $LTLIBICONV; do
8671 acl_save_prefix="$prefix"
8672 prefix="$acl_final_prefix"
8673 acl_save_exec_prefix="$exec_prefix"
8674 exec_prefix="$acl_final_exec_prefix"
8675 eval x=\"$x\"
8676 exec_prefix="$acl_save_exec_prefix"
8677 prefix="$acl_save_prefix"
8679 if test "X$x" = "X-L$additional_libdir"; then
8680 haveit=yes
8681 break
8683 done
8684 if test -z "$haveit"; then
8685 if test -d "$additional_libdir"; then
8686 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
8692 -R*)
8693 dir=`echo "X$dep" | sed -e 's/^X-R//'`
8694 if test "$enable_rpath" != no; then
8695 haveit=
8696 for x in $rpathdirs; do
8697 if test "X$x" = "X$dir"; then
8698 haveit=yes
8699 break
8701 done
8702 if test -z "$haveit"; then
8703 rpathdirs="$rpathdirs $dir"
8705 haveit=
8706 for x in $ltrpathdirs; do
8707 if test "X$x" = "X$dir"; then
8708 haveit=yes
8709 break
8711 done
8712 if test -z "$haveit"; then
8713 ltrpathdirs="$ltrpathdirs $dir"
8717 -l*)
8718 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
8720 *.la)
8721 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
8724 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
8725 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
8727 esac
8728 done
8730 else
8731 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
8732 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8733 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
8734 else
8735 LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
8736 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
8741 done
8742 done
8743 if test "X$rpathdirs" != "X"; then
8744 if test -n "$hardcode_libdir_separator"; then
8745 alldirs=
8746 for found_dir in $rpathdirs; do
8747 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
8748 done
8749 acl_save_libdir="$libdir"
8750 libdir="$alldirs"
8751 eval flag=\"$hardcode_libdir_flag_spec\"
8752 libdir="$acl_save_libdir"
8753 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8754 else
8755 for found_dir in $rpathdirs; do
8756 acl_save_libdir="$libdir"
8757 libdir="$found_dir"
8758 eval flag=\"$hardcode_libdir_flag_spec\"
8759 libdir="$acl_save_libdir"
8760 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8761 done
8764 if test "X$ltrpathdirs" != "X"; then
8765 for found_dir in $ltrpathdirs; do
8766 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
8767 done
8776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
8777 $as_echo_n "checking for iconv... " >&6; }
8778 if ${am_cv_func_iconv+:} false; then :
8779 $as_echo_n "(cached) " >&6
8780 else
8782 am_cv_func_iconv="no, consider installing GNU libiconv"
8783 am_cv_lib_iconv=no
8784 am_save_CPPFLAGS="$CPPFLAGS"
8785 CPPFLAGS="$CPPFLAGS $INCICONV"
8786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8787 /* end confdefs.h. */
8788 #include <stdlib.h>
8789 #include <iconv.h>
8791 main ()
8793 iconv_t cd = iconv_open("","");
8794 iconv(cd,NULL,NULL,NULL,NULL);
8795 iconv_close(cd);
8797 return 0;
8799 _ACEOF
8800 if ac_fn_c_try_link "$LINENO"; then :
8801 am_cv_func_iconv=yes
8803 rm -f core conftest.err conftest.$ac_objext \
8804 conftest$ac_exeext conftest.$ac_ext
8805 CPPFLAGS="$am_save_CPPFLAGS"
8807 if test "$am_cv_func_iconv" != yes && test -d ../libiconv; then
8808 for _libs in .libs _libs; do
8809 am_save_CPPFLAGS="$CPPFLAGS"
8810 am_save_LIBS="$LIBS"
8811 CPPFLAGS="$CPPFLAGS -I../libiconv/include"
8812 LIBS="$LIBS ../libiconv/lib/$_libs/libiconv.a"
8813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8814 /* end confdefs.h. */
8815 #include <stdlib.h>
8816 #include <iconv.h>
8818 main ()
8820 iconv_t cd = iconv_open("","");
8821 iconv(cd,NULL,NULL,NULL,NULL);
8822 iconv_close(cd);
8824 return 0;
8826 _ACEOF
8827 if ac_fn_c_try_link "$LINENO"; then :
8828 INCICONV="-I../libiconv/include"
8829 LIBICONV='${top_builddir}'/../libiconv/lib/$_libs/libiconv.a
8830 LTLIBICONV='${top_builddir}'/../libiconv/lib/libiconv.la
8831 am_cv_lib_iconv=yes
8832 am_cv_func_iconv=yes
8834 rm -f core conftest.err conftest.$ac_objext \
8835 conftest$ac_exeext conftest.$ac_ext
8836 CPPFLAGS="$am_save_CPPFLAGS"
8837 LIBS="$am_save_LIBS"
8838 if test "$am_cv_func_iconv" = "yes"; then
8839 break
8841 done
8844 if test "$am_cv_func_iconv" != yes; then
8845 am_save_CPPFLAGS="$CPPFLAGS"
8846 am_save_LIBS="$LIBS"
8847 CPPFLAGS="$CPPFLAGS $INCICONV"
8848 LIBS="$LIBS $LIBICONV"
8849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8850 /* end confdefs.h. */
8851 #include <stdlib.h>
8852 #include <iconv.h>
8854 main ()
8856 iconv_t cd = iconv_open("","");
8857 iconv(cd,NULL,NULL,NULL,NULL);
8858 iconv_close(cd);
8860 return 0;
8862 _ACEOF
8863 if ac_fn_c_try_link "$LINENO"; then :
8864 am_cv_lib_iconv=yes
8865 am_cv_func_iconv=yes
8867 rm -f core conftest.err conftest.$ac_objext \
8868 conftest$ac_exeext conftest.$ac_ext
8869 CPPFLAGS="$am_save_CPPFLAGS"
8870 LIBS="$am_save_LIBS"
8874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
8875 $as_echo "$am_cv_func_iconv" >&6; }
8876 if test "$am_cv_func_iconv" = yes; then
8878 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
8881 if test "$am_cv_lib_iconv" = yes; then
8883 for element in $INCICONV; do
8884 haveit=
8885 for x in $CPPFLAGS; do
8887 acl_save_prefix="$prefix"
8888 prefix="$acl_final_prefix"
8889 acl_save_exec_prefix="$exec_prefix"
8890 exec_prefix="$acl_final_exec_prefix"
8891 eval x=\"$x\"
8892 exec_prefix="$acl_save_exec_prefix"
8893 prefix="$acl_save_prefix"
8895 if test "X$x" = "X$element"; then
8896 haveit=yes
8897 break
8899 done
8900 if test -z "$haveit"; then
8901 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
8903 done
8905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
8906 $as_echo_n "checking how to link with libiconv... " >&6; }
8907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
8908 $as_echo "$LIBICONV" >&6; }
8909 else
8910 LIBICONV=
8911 LTLIBICONV=
8916 if test "$am_cv_func_iconv" = yes; then
8917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
8918 $as_echo_n "checking for iconv declaration... " >&6; }
8919 if ${am_cv_proto_iconv+:} false; then :
8920 $as_echo_n "(cached) " >&6
8921 else
8923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8924 /* end confdefs.h. */
8926 #include <stdlib.h>
8927 #include <iconv.h>
8928 extern
8929 #ifdef __cplusplus
8931 #endif
8932 #if defined(__STDC__) || defined(__cplusplus)
8933 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
8934 #else
8935 size_t iconv();
8936 #endif
8939 main ()
8943 return 0;
8945 _ACEOF
8946 if ac_fn_c_try_compile "$LINENO"; then :
8947 am_cv_proto_iconv_arg1=""
8948 else
8949 am_cv_proto_iconv_arg1="const"
8951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8952 am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
8955 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
8956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
8957 }$am_cv_proto_iconv" >&5
8958 $as_echo "${ac_t:-
8959 }$am_cv_proto_iconv" >&6; }
8961 cat >>confdefs.h <<_ACEOF
8962 #define ICONV_CONST $am_cv_proto_iconv_arg1
8963 _ACEOF
8968 # GDB may fork/exec the iconv program to get the list of supported character
8969 # sets. Allow the user to specify where to find it.
8970 # There are several factors affecting the choice of option name:
8971 # - There is already --with-libiconv-prefix but we can't use it, it specifies
8972 # the build-time location of libiconv files.
8973 # - The program we need to find is iconv, which comes with glibc. The user
8974 # doesn't necessarily have libiconv installed. Therefore naming this
8975 # --with-libiconv-foo feels wrong.
8976 # - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
8977 # defined to work on directories not files (though it really doesn't know
8978 # the difference).
8979 # - Calling this --with-iconv-prefix is perceived to cause too much confusion
8980 # with --with-libiconv-prefix.
8981 # Putting these together is why the option name is --with-iconv-bin.
8984 # Check whether --with-iconv-bin was given.
8985 if test "${with_iconv_bin+set}" = set; then :
8986 withval=$with_iconv_bin; iconv_bin="${withval}"
8988 cat >>confdefs.h <<_ACEOF
8989 #define ICONV_BIN "${iconv_bin}"
8990 _ACEOF
8993 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
8994 if test "x$prefix" = xNONE; then
8995 test_prefix=/usr/local
8996 else
8997 test_prefix=$prefix
8999 else
9000 test_prefix=$exec_prefix
9002 value=0
9003 case ${iconv_bin} in
9004 "${test_prefix}"|"${test_prefix}/"*|\
9005 '${exec_prefix}'|'${exec_prefix}/'*)
9006 value=1
9008 esac
9010 cat >>confdefs.h <<_ACEOF
9011 #define ICONV_BIN_RELOCATABLE $value
9012 _ACEOF
9019 # For the TUI, we need enhanced curses functionality.
9020 if test x"$enable_tui" != xno; then
9021 prefer_curses=yes
9024 curses_found=no
9025 if test x"$prefer_curses" = xyes; then
9026 # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
9027 # curses library because the latter might not provide all the
9028 # functionality we need. However, this leads to problems on systems
9029 # where the linker searches /usr/local/lib, but the compiler doesn't
9030 # search /usr/local/include, if ncurses is installed in /usr/local. A
9031 # default installation of ncurses on alpha*-dec-osf* will lead to such
9032 # a situation.
9033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
9034 $as_echo_n "checking for library containing waddstr... " >&6; }
9035 if ${ac_cv_search_waddstr+:} false; then :
9036 $as_echo_n "(cached) " >&6
9037 else
9038 ac_func_search_save_LIBS=$LIBS
9039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9040 /* end confdefs.h. */
9042 /* Override any GCC internal prototype to avoid an error.
9043 Use char because int might match the return type of a GCC
9044 builtin and then its argument prototype would still apply. */
9045 #ifdef __cplusplus
9046 extern "C"
9047 #endif
9048 char waddstr ();
9050 main ()
9052 return waddstr ();
9054 return 0;
9056 _ACEOF
9057 for ac_lib in '' ncursesw ncurses cursesX curses; do
9058 if test -z "$ac_lib"; then
9059 ac_res="none required"
9060 else
9061 ac_res=-l$ac_lib
9062 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9064 if ac_fn_c_try_link "$LINENO"; then :
9065 ac_cv_search_waddstr=$ac_res
9067 rm -f core conftest.err conftest.$ac_objext \
9068 conftest$ac_exeext
9069 if ${ac_cv_search_waddstr+:} false; then :
9070 break
9072 done
9073 if ${ac_cv_search_waddstr+:} false; then :
9075 else
9076 ac_cv_search_waddstr=no
9078 rm conftest.$ac_ext
9079 LIBS=$ac_func_search_save_LIBS
9081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
9082 $as_echo "$ac_cv_search_waddstr" >&6; }
9083 ac_res=$ac_cv_search_waddstr
9084 if test "$ac_res" != no; then :
9085 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9090 if test "$ac_cv_search_waddstr" != no; then
9091 curses_found=yes
9095 # Check whether we should enable the TUI, but only do so if we really
9096 # can.
9097 if test x"$enable_tui" != xno; then
9098 if test -d "$srcdir/tui"; then
9099 if test "$curses_found" != no; then
9100 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
9101 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
9102 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
9103 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
9104 else
9105 if test x"$enable_tui" = xyes; then
9106 as_fn_error $? "no enhanced curses library found; disable TUI" "$LINENO" 5
9107 else
9108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
9109 $as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
9115 # Since GDB uses Readline, we need termcap functionality. In many
9116 # cases this will be provided by the curses library, but some systems
9117 # have a separate termcap library, or no curses library at all.
9119 case $host_os in
9120 cygwin*)
9121 if test -d "$srcdir/libtermcap"; then
9122 LIBS="../libtermcap/libtermcap.a $LIBS"
9123 ac_cv_search_tgetent="../libtermcap/libtermcap.a"
9124 fi ;;
9125 go32* | *djgpp*)
9126 ac_cv_search_tgetent="none required"
9128 esac
9130 # These are the libraries checked by Readline.
9131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
9132 $as_echo_n "checking for library containing tgetent... " >&6; }
9133 if ${ac_cv_search_tgetent+:} false; then :
9134 $as_echo_n "(cached) " >&6
9135 else
9136 ac_func_search_save_LIBS=$LIBS
9137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9138 /* end confdefs.h. */
9140 /* Override any GCC internal prototype to avoid an error.
9141 Use char because int might match the return type of a GCC
9142 builtin and then its argument prototype would still apply. */
9143 #ifdef __cplusplus
9144 extern "C"
9145 #endif
9146 char tgetent ();
9148 main ()
9150 return tgetent ();
9152 return 0;
9154 _ACEOF
9155 for ac_lib in '' termcap tinfow tinfo curses ncursesw ncurses; do
9156 if test -z "$ac_lib"; then
9157 ac_res="none required"
9158 else
9159 ac_res=-l$ac_lib
9160 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9162 if ac_fn_c_try_link "$LINENO"; then :
9163 ac_cv_search_tgetent=$ac_res
9165 rm -f core conftest.err conftest.$ac_objext \
9166 conftest$ac_exeext
9167 if ${ac_cv_search_tgetent+:} false; then :
9168 break
9170 done
9171 if ${ac_cv_search_tgetent+:} false; then :
9173 else
9174 ac_cv_search_tgetent=no
9176 rm conftest.$ac_ext
9177 LIBS=$ac_func_search_save_LIBS
9179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
9180 $as_echo "$ac_cv_search_tgetent" >&6; }
9181 ac_res=$ac_cv_search_tgetent
9182 if test "$ac_res" != no; then :
9183 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9188 if test "$ac_cv_search_tgetent" = no; then
9189 CONFIG_OBS="$CONFIG_OBS stub-termcap.o"
9193 # Check whether --with-system-readline was given.
9194 if test "${with_system_readline+set}" = set; then :
9195 withval=$with_system_readline;
9199 if test "$with_system_readline" = yes; then
9200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system readline is new enough" >&5
9201 $as_echo_n "checking whether system readline is new enough... " >&6; }
9202 if ${gdb_cv_readline_ok+:} false; then :
9203 $as_echo_n "(cached) " >&6
9204 else
9205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9206 /* end confdefs.h. */
9207 #include <stdio.h>
9208 #include <readline/readline.h>
9210 main ()
9212 #if RL_VERSION_MAJOR < 7
9213 # error "readline version 7 required"
9214 #endif
9217 return 0;
9219 _ACEOF
9220 if ac_fn_c_try_compile "$LINENO"; then :
9221 gdb_cv_readline_ok=yes
9222 else
9223 gdb_cv_readline_ok=no
9226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_readline_ok" >&5
9230 $as_echo "$gdb_cv_readline_ok" >&6; }
9231 if test "$gdb_cv_readline_ok" != yes; then
9232 as_fn_error $? "system readline is not new enough" "$LINENO" 5
9235 READLINE=-lreadline
9236 READLINE_DEPS=
9237 READLINE_CFLAGS=
9238 READLINE_TEXI_INCFLAG=
9239 else
9240 READLINE='$(READLINE_DIR)/libreadline.a'
9241 READLINE_DEPS='$(READLINE)'
9242 READLINE_CFLAGS='-I$(READLINE_SRC)/..'
9243 READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
9250 # Generate jit-reader.h
9252 # This is typedeffed to GDB_CORE_ADDR in jit-reader.h
9253 TARGET_PTR=
9255 # The cast to long int works around a bug in the HP C Compiler
9256 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9257 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9258 # This bug is HP SR number 8606223364.
9259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
9260 $as_echo_n "checking size of unsigned long long... " >&6; }
9261 if ${ac_cv_sizeof_unsigned_long_long+:} false; then :
9262 $as_echo_n "(cached) " >&6
9263 else
9264 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long" "$ac_includes_default"; then :
9266 else
9267 if test "$ac_cv_type_unsigned_long_long" = yes; then
9268 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9269 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9270 as_fn_error 77 "cannot compute sizeof (unsigned long long)
9271 See \`config.log' for more details" "$LINENO" 5; }
9272 else
9273 ac_cv_sizeof_unsigned_long_long=0
9278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
9279 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
9283 cat >>confdefs.h <<_ACEOF
9284 #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
9285 _ACEOF
9288 # The cast to long int works around a bug in the HP C Compiler
9289 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9290 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9291 # This bug is HP SR number 8606223364.
9292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
9293 $as_echo_n "checking size of unsigned long... " >&6; }
9294 if ${ac_cv_sizeof_unsigned_long+:} false; then :
9295 $as_echo_n "(cached) " >&6
9296 else
9297 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long" "$ac_includes_default"; then :
9299 else
9300 if test "$ac_cv_type_unsigned_long" = yes; then
9301 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9302 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9303 as_fn_error 77 "cannot compute sizeof (unsigned long)
9304 See \`config.log' for more details" "$LINENO" 5; }
9305 else
9306 ac_cv_sizeof_unsigned_long=0
9311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
9312 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
9316 cat >>confdefs.h <<_ACEOF
9317 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
9318 _ACEOF
9321 # The cast to long int works around a bug in the HP C Compiler
9322 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9323 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9324 # This bug is HP SR number 8606223364.
9325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
9326 $as_echo_n "checking size of unsigned __int128... " >&6; }
9327 if ${ac_cv_sizeof_unsigned___int128+:} false; then :
9328 $as_echo_n "(cached) " >&6
9329 else
9330 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128" "$ac_includes_default"; then :
9332 else
9333 if test "$ac_cv_type_unsigned___int128" = yes; then
9334 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9335 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9336 as_fn_error 77 "cannot compute sizeof (unsigned __int128)
9337 See \`config.log' for more details" "$LINENO" 5; }
9338 else
9339 ac_cv_sizeof_unsigned___int128=0
9344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
9345 $as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
9349 cat >>confdefs.h <<_ACEOF
9350 #define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
9351 _ACEOF
9355 if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
9356 TARGET_PTR="unsigned long"
9357 elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
9358 TARGET_PTR="unsigned long long"
9359 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
9360 TARGET_PTR="unsigned __int128"
9361 else
9362 TARGET_PTR="unsigned long"
9366 ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
9369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
9370 $as_echo_n "checking for library containing dlopen... " >&6; }
9371 if ${ac_cv_search_dlopen+:} false; then :
9372 $as_echo_n "(cached) " >&6
9373 else
9374 ac_func_search_save_LIBS=$LIBS
9375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9376 /* end confdefs.h. */
9378 /* Override any GCC internal prototype to avoid an error.
9379 Use char because int might match the return type of a GCC
9380 builtin and then its argument prototype would still apply. */
9381 #ifdef __cplusplus
9382 extern "C"
9383 #endif
9384 char dlopen ();
9386 main ()
9388 return dlopen ();
9390 return 0;
9392 _ACEOF
9393 for ac_lib in '' dl; do
9394 if test -z "$ac_lib"; then
9395 ac_res="none required"
9396 else
9397 ac_res=-l$ac_lib
9398 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9400 if ac_fn_c_try_link "$LINENO"; then :
9401 ac_cv_search_dlopen=$ac_res
9403 rm -f core conftest.err conftest.$ac_objext \
9404 conftest$ac_exeext
9405 if ${ac_cv_search_dlopen+:} false; then :
9406 break
9408 done
9409 if ${ac_cv_search_dlopen+:} false; then :
9411 else
9412 ac_cv_search_dlopen=no
9414 rm conftest.$ac_ext
9415 LIBS=$ac_func_search_save_LIBS
9417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
9418 $as_echo "$ac_cv_search_dlopen" >&6; }
9419 ac_res=$ac_cv_search_dlopen
9420 if test "$ac_res" != no; then :
9421 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9428 # Check whether --with-jit-reader-dir was given.
9429 if test "${with_jit_reader_dir+set}" = set; then :
9430 withval=$with_jit_reader_dir;
9431 JIT_READER_DIR=$withval
9432 else
9433 JIT_READER_DIR=${libdir}/gdb
9437 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
9438 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9439 ac_define_dir=`eval echo $JIT_READER_DIR`
9440 ac_define_dir=`eval echo $ac_define_dir`
9442 cat >>confdefs.h <<_ACEOF
9443 #define JIT_READER_DIR "$ac_define_dir"
9444 _ACEOF
9449 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
9450 if test "x$prefix" = xNONE; then
9451 test_prefix=/usr/local
9452 else
9453 test_prefix=$prefix
9455 else
9456 test_prefix=$exec_prefix
9458 value=0
9459 case ${ac_define_dir} in
9460 "${test_prefix}"|"${test_prefix}/"*|\
9461 '${exec_prefix}'|'${exec_prefix}/'*)
9462 value=1
9464 esac
9466 cat >>confdefs.h <<_ACEOF
9467 #define JIT_READER_DIR_RELOCATABLE $value
9468 _ACEOF
9474 # Check whether --with-expat was given.
9475 if test "${with_expat+set}" = set; then :
9476 withval=$with_expat;
9477 else
9478 with_expat=auto
9481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
9482 $as_echo_n "checking whether to use expat... " >&6; }
9483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
9484 $as_echo "$with_expat" >&6; }
9486 if test "${with_expat}" = no; then
9487 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
9488 $as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
9489 HAVE_LIBEXPAT=no
9490 else
9499 use_additional=yes
9501 acl_save_prefix="$prefix"
9502 prefix="$acl_final_prefix"
9503 acl_save_exec_prefix="$exec_prefix"
9504 exec_prefix="$acl_final_exec_prefix"
9506 eval additional_includedir=\"$includedir\"
9507 eval additional_libdir=\"$libdir\"
9509 exec_prefix="$acl_save_exec_prefix"
9510 prefix="$acl_save_prefix"
9513 # Check whether --with-libexpat-prefix was given.
9514 if test "${with_libexpat_prefix+set}" = set; then :
9515 withval=$with_libexpat_prefix;
9516 if test "X$withval" = "Xno"; then
9517 use_additional=no
9518 else
9519 if test "X$withval" = "X"; then
9521 acl_save_prefix="$prefix"
9522 prefix="$acl_final_prefix"
9523 acl_save_exec_prefix="$exec_prefix"
9524 exec_prefix="$acl_final_exec_prefix"
9526 eval additional_includedir=\"$includedir\"
9527 eval additional_libdir=\"$libdir\"
9529 exec_prefix="$acl_save_exec_prefix"
9530 prefix="$acl_save_prefix"
9532 else
9533 additional_includedir="$withval/include"
9534 additional_libdir="$withval/lib"
9541 # Check whether --with-libexpat-type was given.
9542 if test "${with_libexpat_type+set}" = set; then :
9543 withval=$with_libexpat_type; with_libexpat_type=$withval
9544 else
9545 with_libexpat_type=auto
9548 lib_type=`eval echo \$with_libexpat_type`
9550 LIBEXPAT=
9551 LTLIBEXPAT=
9552 INCEXPAT=
9553 rpathdirs=
9554 ltrpathdirs=
9555 names_already_handled=
9556 names_next_round='expat '
9557 while test -n "$names_next_round"; do
9558 names_this_round="$names_next_round"
9559 names_next_round=
9560 for name in $names_this_round; do
9561 already_handled=
9562 for n in $names_already_handled; do
9563 if test "$n" = "$name"; then
9564 already_handled=yes
9565 break
9567 done
9568 if test -z "$already_handled"; then
9569 names_already_handled="$names_already_handled $name"
9570 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9571 eval value=\"\$HAVE_LIB$uppername\"
9572 if test -n "$value"; then
9573 if test "$value" = yes; then
9574 eval value=\"\$LIB$uppername\"
9575 test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
9576 eval value=\"\$LTLIB$uppername\"
9577 test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
9578 else
9581 else
9582 found_dir=
9583 found_la=
9584 found_so=
9585 found_a=
9586 if test $use_additional = yes; then
9587 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9588 found_dir="$additional_libdir"
9589 found_so="$additional_libdir/lib$name.$shlibext"
9590 if test -f "$additional_libdir/lib$name.la"; then
9591 found_la="$additional_libdir/lib$name.la"
9593 elif test x$lib_type != xshared; then
9594 if test -f "$additional_libdir/lib$name.$libext"; then
9595 found_dir="$additional_libdir"
9596 found_a="$additional_libdir/lib$name.$libext"
9597 if test -f "$additional_libdir/lib$name.la"; then
9598 found_la="$additional_libdir/lib$name.la"
9603 if test "X$found_dir" = "X"; then
9604 for x in $LDFLAGS $LTLIBEXPAT; do
9606 acl_save_prefix="$prefix"
9607 prefix="$acl_final_prefix"
9608 acl_save_exec_prefix="$exec_prefix"
9609 exec_prefix="$acl_final_exec_prefix"
9610 eval x=\"$x\"
9611 exec_prefix="$acl_save_exec_prefix"
9612 prefix="$acl_save_prefix"
9614 case "$x" in
9615 -L*)
9616 dir=`echo "X$x" | sed -e 's/^X-L//'`
9617 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
9618 found_dir="$dir"
9619 found_so="$dir/lib$name.$shlibext"
9620 if test -f "$dir/lib$name.la"; then
9621 found_la="$dir/lib$name.la"
9623 elif test x$lib_type != xshared; then
9624 if test -f "$dir/lib$name.$libext"; then
9625 found_dir="$dir"
9626 found_a="$dir/lib$name.$libext"
9627 if test -f "$dir/lib$name.la"; then
9628 found_la="$dir/lib$name.la"
9633 esac
9634 if test "X$found_dir" != "X"; then
9635 break
9637 done
9639 if test "X$found_dir" != "X"; then
9640 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
9641 if test "X$found_so" != "X"; then
9642 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9643 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9644 else
9645 haveit=
9646 for x in $ltrpathdirs; do
9647 if test "X$x" = "X$found_dir"; then
9648 haveit=yes
9649 break
9651 done
9652 if test -z "$haveit"; then
9653 ltrpathdirs="$ltrpathdirs $found_dir"
9655 if test "$hardcode_direct" = yes; then
9656 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9657 else
9658 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9659 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9660 haveit=
9661 for x in $rpathdirs; do
9662 if test "X$x" = "X$found_dir"; then
9663 haveit=yes
9664 break
9666 done
9667 if test -z "$haveit"; then
9668 rpathdirs="$rpathdirs $found_dir"
9670 else
9671 haveit=
9672 for x in $LDFLAGS $LIBEXPAT; do
9674 acl_save_prefix="$prefix"
9675 prefix="$acl_final_prefix"
9676 acl_save_exec_prefix="$exec_prefix"
9677 exec_prefix="$acl_final_exec_prefix"
9678 eval x=\"$x\"
9679 exec_prefix="$acl_save_exec_prefix"
9680 prefix="$acl_save_prefix"
9682 if test "X$x" = "X-L$found_dir"; then
9683 haveit=yes
9684 break
9686 done
9687 if test -z "$haveit"; then
9688 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
9690 if test "$hardcode_minus_L" != no; then
9691 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9692 else
9693 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9698 else
9699 if test "X$found_a" != "X"; then
9700 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
9701 else
9702 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
9705 additional_includedir=
9706 case "$found_dir" in
9707 */lib | */lib/)
9708 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9709 additional_includedir="$basedir/include"
9711 esac
9712 if test "X$additional_includedir" != "X"; then
9713 if test "X$additional_includedir" != "X/usr/include"; then
9714 haveit=
9715 if test "X$additional_includedir" = "X/usr/local/include"; then
9716 if test -n "$GCC"; then
9717 case $host_os in
9718 linux*) haveit=yes;;
9719 esac
9722 if test -z "$haveit"; then
9723 for x in $CPPFLAGS $INCEXPAT; do
9725 acl_save_prefix="$prefix"
9726 prefix="$acl_final_prefix"
9727 acl_save_exec_prefix="$exec_prefix"
9728 exec_prefix="$acl_final_exec_prefix"
9729 eval x=\"$x\"
9730 exec_prefix="$acl_save_exec_prefix"
9731 prefix="$acl_save_prefix"
9733 if test "X$x" = "X-I$additional_includedir"; then
9734 haveit=yes
9735 break
9737 done
9738 if test -z "$haveit"; then
9739 if test -d "$additional_includedir"; then
9740 INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
9746 if test -n "$found_la"; then
9747 save_libdir="$libdir"
9748 case "$found_la" in
9749 */* | *\\*) . "$found_la" ;;
9750 *) . "./$found_la" ;;
9751 esac
9752 libdir="$save_libdir"
9753 for dep in $dependency_libs; do
9754 case "$dep" in
9755 -L*)
9756 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9757 if test "X$additional_libdir" != "X/usr/lib"; then
9758 haveit=
9759 if test "X$additional_libdir" = "X/usr/local/lib"; then
9760 if test -n "$GCC"; then
9761 case $host_os in
9762 linux*) haveit=yes;;
9763 esac
9766 if test -z "$haveit"; then
9767 haveit=
9768 for x in $LDFLAGS $LIBEXPAT; do
9770 acl_save_prefix="$prefix"
9771 prefix="$acl_final_prefix"
9772 acl_save_exec_prefix="$exec_prefix"
9773 exec_prefix="$acl_final_exec_prefix"
9774 eval x=\"$x\"
9775 exec_prefix="$acl_save_exec_prefix"
9776 prefix="$acl_save_prefix"
9778 if test "X$x" = "X-L$additional_libdir"; then
9779 haveit=yes
9780 break
9782 done
9783 if test -z "$haveit"; then
9784 if test -d "$additional_libdir"; then
9785 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
9788 haveit=
9789 for x in $LDFLAGS $LTLIBEXPAT; do
9791 acl_save_prefix="$prefix"
9792 prefix="$acl_final_prefix"
9793 acl_save_exec_prefix="$exec_prefix"
9794 exec_prefix="$acl_final_exec_prefix"
9795 eval x=\"$x\"
9796 exec_prefix="$acl_save_exec_prefix"
9797 prefix="$acl_save_prefix"
9799 if test "X$x" = "X-L$additional_libdir"; then
9800 haveit=yes
9801 break
9803 done
9804 if test -z "$haveit"; then
9805 if test -d "$additional_libdir"; then
9806 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
9812 -R*)
9813 dir=`echo "X$dep" | sed -e 's/^X-R//'`
9814 if test "$enable_rpath" != no; then
9815 haveit=
9816 for x in $rpathdirs; do
9817 if test "X$x" = "X$dir"; then
9818 haveit=yes
9819 break
9821 done
9822 if test -z "$haveit"; then
9823 rpathdirs="$rpathdirs $dir"
9825 haveit=
9826 for x in $ltrpathdirs; do
9827 if test "X$x" = "X$dir"; then
9828 haveit=yes
9829 break
9831 done
9832 if test -z "$haveit"; then
9833 ltrpathdirs="$ltrpathdirs $dir"
9837 -l*)
9838 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
9840 *.la)
9841 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
9844 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
9845 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
9847 esac
9848 done
9850 else
9851 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
9852 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9853 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
9854 else
9855 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l:lib$name.$libext"
9856 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l:lib$name.$libext"
9861 done
9862 done
9863 if test "X$rpathdirs" != "X"; then
9864 if test -n "$hardcode_libdir_separator"; then
9865 alldirs=
9866 for found_dir in $rpathdirs; do
9867 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
9868 done
9869 acl_save_libdir="$libdir"
9870 libdir="$alldirs"
9871 eval flag=\"$hardcode_libdir_flag_spec\"
9872 libdir="$acl_save_libdir"
9873 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9874 else
9875 for found_dir in $rpathdirs; do
9876 acl_save_libdir="$libdir"
9877 libdir="$found_dir"
9878 eval flag=\"$hardcode_libdir_flag_spec\"
9879 libdir="$acl_save_libdir"
9880 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9881 done
9884 if test "X$ltrpathdirs" != "X"; then
9885 for found_dir in $ltrpathdirs; do
9886 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
9887 done
9891 ac_save_CPPFLAGS="$CPPFLAGS"
9893 for element in $INCEXPAT; do
9894 haveit=
9895 for x in $CPPFLAGS; do
9897 acl_save_prefix="$prefix"
9898 prefix="$acl_final_prefix"
9899 acl_save_exec_prefix="$exec_prefix"
9900 exec_prefix="$acl_final_exec_prefix"
9901 eval x=\"$x\"
9902 exec_prefix="$acl_save_exec_prefix"
9903 prefix="$acl_save_prefix"
9905 if test "X$x" = "X$element"; then
9906 haveit=yes
9907 break
9909 done
9910 if test -z "$haveit"; then
9911 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
9913 done
9916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
9917 $as_echo_n "checking for libexpat... " >&6; }
9918 if ${ac_cv_libexpat+:} false; then :
9919 $as_echo_n "(cached) " >&6
9920 else
9922 ac_save_LIBS="$LIBS"
9923 LIBS="$LIBS $LIBEXPAT"
9924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9925 /* end confdefs.h. */
9926 #include "expat.h"
9928 main ()
9930 XML_Parser p = XML_ParserCreate (0);
9932 return 0;
9934 _ACEOF
9935 if ac_fn_c_try_link "$LINENO"; then :
9936 ac_cv_libexpat=yes
9937 else
9938 ac_cv_libexpat=no
9940 rm -f core conftest.err conftest.$ac_objext \
9941 conftest$ac_exeext conftest.$ac_ext
9942 LIBS="$ac_save_LIBS"
9945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
9946 $as_echo "$ac_cv_libexpat" >&6; }
9947 if test "$ac_cv_libexpat" = yes; then
9948 HAVE_LIBEXPAT=yes
9950 $as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
9952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
9953 $as_echo_n "checking how to link with libexpat... " >&6; }
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
9955 $as_echo "$LIBEXPAT" >&6; }
9956 else
9957 HAVE_LIBEXPAT=no
9958 CPPFLAGS="$ac_save_CPPFLAGS"
9959 LIBEXPAT=
9960 LTLIBEXPAT=
9968 if test "$HAVE_LIBEXPAT" != yes; then
9969 if test "$with_expat" = yes; then
9970 as_fn_error $? "expat is missing or unusable" "$LINENO" 5
9971 else
9972 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
9973 $as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
9975 else
9976 save_LIBS=$LIBS
9977 LIBS="$LIBS $LIBEXPAT"
9978 for ac_func in XML_StopParser
9979 do :
9980 ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
9981 if test "x$ac_cv_func_XML_StopParser" = xyes; then :
9982 cat >>confdefs.h <<_ACEOF
9983 #define HAVE_XML_STOPPARSER 1
9984 _ACEOF
9987 done
9989 LIBS=$save_LIBS
9993 # Verify that we have a usable GMP library.
10002 use_additional=yes
10004 acl_save_prefix="$prefix"
10005 prefix="$acl_final_prefix"
10006 acl_save_exec_prefix="$exec_prefix"
10007 exec_prefix="$acl_final_exec_prefix"
10009 eval additional_includedir=\"$includedir\"
10010 eval additional_libdir=\"$libdir\"
10012 exec_prefix="$acl_save_exec_prefix"
10013 prefix="$acl_save_prefix"
10016 # Check whether --with-libgmp-prefix was given.
10017 if test "${with_libgmp_prefix+set}" = set; then :
10018 withval=$with_libgmp_prefix;
10019 if test "X$withval" = "Xno"; then
10020 use_additional=no
10021 else
10022 if test "X$withval" = "X"; then
10024 acl_save_prefix="$prefix"
10025 prefix="$acl_final_prefix"
10026 acl_save_exec_prefix="$exec_prefix"
10027 exec_prefix="$acl_final_exec_prefix"
10029 eval additional_includedir=\"$includedir\"
10030 eval additional_libdir=\"$libdir\"
10032 exec_prefix="$acl_save_exec_prefix"
10033 prefix="$acl_save_prefix"
10035 else
10036 additional_includedir="$withval/include"
10037 additional_libdir="$withval/lib"
10044 # Check whether --with-libgmp-type was given.
10045 if test "${with_libgmp_type+set}" = set; then :
10046 withval=$with_libgmp_type; with_libgmp_type=$withval
10047 else
10048 with_libgmp_type=auto
10051 lib_type=`eval echo \$with_libgmp_type`
10053 LIBGMP=
10054 LTLIBGMP=
10055 INCGMP=
10056 rpathdirs=
10057 ltrpathdirs=
10058 names_already_handled=
10059 names_next_round='gmp '
10060 while test -n "$names_next_round"; do
10061 names_this_round="$names_next_round"
10062 names_next_round=
10063 for name in $names_this_round; do
10064 already_handled=
10065 for n in $names_already_handled; do
10066 if test "$n" = "$name"; then
10067 already_handled=yes
10068 break
10070 done
10071 if test -z "$already_handled"; then
10072 names_already_handled="$names_already_handled $name"
10073 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10074 eval value=\"\$HAVE_LIB$uppername\"
10075 if test -n "$value"; then
10076 if test "$value" = yes; then
10077 eval value=\"\$LIB$uppername\"
10078 test -z "$value" || LIBGMP="${LIBGMP}${LIBGMP:+ }$value"
10079 eval value=\"\$LTLIB$uppername\"
10080 test -z "$value" || LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }$value"
10081 else
10084 else
10085 found_dir=
10086 found_la=
10087 found_so=
10088 found_a=
10089 if test $use_additional = yes; then
10090 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10091 found_dir="$additional_libdir"
10092 found_so="$additional_libdir/lib$name.$shlibext"
10093 if test -f "$additional_libdir/lib$name.la"; then
10094 found_la="$additional_libdir/lib$name.la"
10096 elif test x$lib_type != xshared; then
10097 if test -f "$additional_libdir/lib$name.$libext"; then
10098 found_dir="$additional_libdir"
10099 found_a="$additional_libdir/lib$name.$libext"
10100 if test -f "$additional_libdir/lib$name.la"; then
10101 found_la="$additional_libdir/lib$name.la"
10106 if test "X$found_dir" = "X"; then
10107 for x in $LDFLAGS $LTLIBGMP; do
10109 acl_save_prefix="$prefix"
10110 prefix="$acl_final_prefix"
10111 acl_save_exec_prefix="$exec_prefix"
10112 exec_prefix="$acl_final_exec_prefix"
10113 eval x=\"$x\"
10114 exec_prefix="$acl_save_exec_prefix"
10115 prefix="$acl_save_prefix"
10117 case "$x" in
10118 -L*)
10119 dir=`echo "X$x" | sed -e 's/^X-L//'`
10120 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10121 found_dir="$dir"
10122 found_so="$dir/lib$name.$shlibext"
10123 if test -f "$dir/lib$name.la"; then
10124 found_la="$dir/lib$name.la"
10126 elif test x$lib_type != xshared; then
10127 if test -f "$dir/lib$name.$libext"; then
10128 found_dir="$dir"
10129 found_a="$dir/lib$name.$libext"
10130 if test -f "$dir/lib$name.la"; then
10131 found_la="$dir/lib$name.la"
10136 esac
10137 if test "X$found_dir" != "X"; then
10138 break
10140 done
10142 if test "X$found_dir" != "X"; then
10143 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }-L$found_dir -l$name"
10144 if test "X$found_so" != "X"; then
10145 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
10146 LIBGMP="${LIBGMP}${LIBGMP:+ }$found_so"
10147 else
10148 haveit=
10149 for x in $ltrpathdirs; do
10150 if test "X$x" = "X$found_dir"; then
10151 haveit=yes
10152 break
10154 done
10155 if test -z "$haveit"; then
10156 ltrpathdirs="$ltrpathdirs $found_dir"
10158 if test "$hardcode_direct" = yes; then
10159 LIBGMP="${LIBGMP}${LIBGMP:+ }$found_so"
10160 else
10161 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
10162 LIBGMP="${LIBGMP}${LIBGMP:+ }$found_so"
10163 haveit=
10164 for x in $rpathdirs; do
10165 if test "X$x" = "X$found_dir"; then
10166 haveit=yes
10167 break
10169 done
10170 if test -z "$haveit"; then
10171 rpathdirs="$rpathdirs $found_dir"
10173 else
10174 haveit=
10175 for x in $LDFLAGS $LIBGMP; do
10177 acl_save_prefix="$prefix"
10178 prefix="$acl_final_prefix"
10179 acl_save_exec_prefix="$exec_prefix"
10180 exec_prefix="$acl_final_exec_prefix"
10181 eval x=\"$x\"
10182 exec_prefix="$acl_save_exec_prefix"
10183 prefix="$acl_save_prefix"
10185 if test "X$x" = "X-L$found_dir"; then
10186 haveit=yes
10187 break
10189 done
10190 if test -z "$haveit"; then
10191 LIBGMP="${LIBGMP}${LIBGMP:+ }-L$found_dir"
10193 if test "$hardcode_minus_L" != no; then
10194 LIBGMP="${LIBGMP}${LIBGMP:+ }$found_so"
10195 else
10196 LIBGMP="${LIBGMP}${LIBGMP:+ }-l$name"
10201 else
10202 if test "X$found_a" != "X"; then
10203 LIBGMP="${LIBGMP}${LIBGMP:+ }$found_a"
10204 else
10205 LIBGMP="${LIBGMP}${LIBGMP:+ }-L$found_dir -l$name"
10208 additional_includedir=
10209 case "$found_dir" in
10210 */lib | */lib/)
10211 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
10212 additional_includedir="$basedir/include"
10214 esac
10215 if test "X$additional_includedir" != "X"; then
10216 if test "X$additional_includedir" != "X/usr/include"; then
10217 haveit=
10218 if test "X$additional_includedir" = "X/usr/local/include"; then
10219 if test -n "$GCC"; then
10220 case $host_os in
10221 linux*) haveit=yes;;
10222 esac
10225 if test -z "$haveit"; then
10226 for x in $CPPFLAGS $INCGMP; do
10228 acl_save_prefix="$prefix"
10229 prefix="$acl_final_prefix"
10230 acl_save_exec_prefix="$exec_prefix"
10231 exec_prefix="$acl_final_exec_prefix"
10232 eval x=\"$x\"
10233 exec_prefix="$acl_save_exec_prefix"
10234 prefix="$acl_save_prefix"
10236 if test "X$x" = "X-I$additional_includedir"; then
10237 haveit=yes
10238 break
10240 done
10241 if test -z "$haveit"; then
10242 if test -d "$additional_includedir"; then
10243 INCGMP="${INCGMP}${INCGMP:+ }-I$additional_includedir"
10249 if test -n "$found_la"; then
10250 save_libdir="$libdir"
10251 case "$found_la" in
10252 */* | *\\*) . "$found_la" ;;
10253 *) . "./$found_la" ;;
10254 esac
10255 libdir="$save_libdir"
10256 for dep in $dependency_libs; do
10257 case "$dep" in
10258 -L*)
10259 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10260 if test "X$additional_libdir" != "X/usr/lib"; then
10261 haveit=
10262 if test "X$additional_libdir" = "X/usr/local/lib"; then
10263 if test -n "$GCC"; then
10264 case $host_os in
10265 linux*) haveit=yes;;
10266 esac
10269 if test -z "$haveit"; then
10270 haveit=
10271 for x in $LDFLAGS $LIBGMP; do
10273 acl_save_prefix="$prefix"
10274 prefix="$acl_final_prefix"
10275 acl_save_exec_prefix="$exec_prefix"
10276 exec_prefix="$acl_final_exec_prefix"
10277 eval x=\"$x\"
10278 exec_prefix="$acl_save_exec_prefix"
10279 prefix="$acl_save_prefix"
10281 if test "X$x" = "X-L$additional_libdir"; then
10282 haveit=yes
10283 break
10285 done
10286 if test -z "$haveit"; then
10287 if test -d "$additional_libdir"; then
10288 LIBGMP="${LIBGMP}${LIBGMP:+ }-L$additional_libdir"
10291 haveit=
10292 for x in $LDFLAGS $LTLIBGMP; do
10294 acl_save_prefix="$prefix"
10295 prefix="$acl_final_prefix"
10296 acl_save_exec_prefix="$exec_prefix"
10297 exec_prefix="$acl_final_exec_prefix"
10298 eval x=\"$x\"
10299 exec_prefix="$acl_save_exec_prefix"
10300 prefix="$acl_save_prefix"
10302 if test "X$x" = "X-L$additional_libdir"; then
10303 haveit=yes
10304 break
10306 done
10307 if test -z "$haveit"; then
10308 if test -d "$additional_libdir"; then
10309 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }-L$additional_libdir"
10315 -R*)
10316 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10317 if test "$enable_rpath" != no; then
10318 haveit=
10319 for x in $rpathdirs; do
10320 if test "X$x" = "X$dir"; then
10321 haveit=yes
10322 break
10324 done
10325 if test -z "$haveit"; then
10326 rpathdirs="$rpathdirs $dir"
10328 haveit=
10329 for x in $ltrpathdirs; do
10330 if test "X$x" = "X$dir"; then
10331 haveit=yes
10332 break
10334 done
10335 if test -z "$haveit"; then
10336 ltrpathdirs="$ltrpathdirs $dir"
10340 -l*)
10341 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10343 *.la)
10344 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10347 LIBGMP="${LIBGMP}${LIBGMP:+ }$dep"
10348 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }$dep"
10350 esac
10351 done
10353 else
10354 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10355 LIBGMP="${LIBGMP}${LIBGMP:+ }-l$name"
10356 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }-l$name"
10357 else
10358 LIBGMP="${LIBGMP}${LIBGMP:+ }-l:lib$name.$libext"
10359 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }-l:lib$name.$libext"
10364 done
10365 done
10366 if test "X$rpathdirs" != "X"; then
10367 if test -n "$hardcode_libdir_separator"; then
10368 alldirs=
10369 for found_dir in $rpathdirs; do
10370 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10371 done
10372 acl_save_libdir="$libdir"
10373 libdir="$alldirs"
10374 eval flag=\"$hardcode_libdir_flag_spec\"
10375 libdir="$acl_save_libdir"
10376 LIBGMP="${LIBGMP}${LIBGMP:+ }$flag"
10377 else
10378 for found_dir in $rpathdirs; do
10379 acl_save_libdir="$libdir"
10380 libdir="$found_dir"
10381 eval flag=\"$hardcode_libdir_flag_spec\"
10382 libdir="$acl_save_libdir"
10383 LIBGMP="${LIBGMP}${LIBGMP:+ }$flag"
10384 done
10387 if test "X$ltrpathdirs" != "X"; then
10388 for found_dir in $ltrpathdirs; do
10389 LTLIBGMP="${LTLIBGMP}${LTLIBGMP:+ }-R$found_dir"
10390 done
10394 ac_save_CPPFLAGS="$CPPFLAGS"
10396 for element in $INCGMP; do
10397 haveit=
10398 for x in $CPPFLAGS; do
10400 acl_save_prefix="$prefix"
10401 prefix="$acl_final_prefix"
10402 acl_save_exec_prefix="$exec_prefix"
10403 exec_prefix="$acl_final_exec_prefix"
10404 eval x=\"$x\"
10405 exec_prefix="$acl_save_exec_prefix"
10406 prefix="$acl_save_prefix"
10408 if test "X$x" = "X$element"; then
10409 haveit=yes
10410 break
10412 done
10413 if test -z "$haveit"; then
10414 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10416 done
10419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libgmp" >&5
10420 $as_echo_n "checking for libgmp... " >&6; }
10421 if ${ac_cv_libgmp+:} false; then :
10422 $as_echo_n "(cached) " >&6
10423 else
10425 ac_save_LIBS="$LIBS"
10426 LIBS="$LIBS $LIBGMP"
10427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10428 /* end confdefs.h. */
10429 #include <gmp.h>
10431 main ()
10433 mpz_t n;
10434 mpz_init (n);
10436 return 0;
10438 _ACEOF
10439 if ac_fn_c_try_link "$LINENO"; then :
10440 ac_cv_libgmp=yes
10441 else
10442 ac_cv_libgmp=no
10444 rm -f core conftest.err conftest.$ac_objext \
10445 conftest$ac_exeext conftest.$ac_ext
10446 LIBS="$ac_save_LIBS"
10449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libgmp" >&5
10450 $as_echo "$ac_cv_libgmp" >&6; }
10451 if test "$ac_cv_libgmp" = yes; then
10452 HAVE_LIBGMP=yes
10454 $as_echo "#define HAVE_LIBGMP 1" >>confdefs.h
10456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libgmp" >&5
10457 $as_echo_n "checking how to link with libgmp... " >&6; }
10458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGMP" >&5
10459 $as_echo "$LIBGMP" >&6; }
10460 else
10461 HAVE_LIBGMP=no
10462 CPPFLAGS="$ac_save_CPPFLAGS"
10463 LIBGMP=
10464 LTLIBGMP=
10474 # Check whether --with-mpfr was given.
10475 if test "${with_mpfr+set}" = set; then :
10476 withval=$with_mpfr;
10477 else
10478 with_mpfr=auto
10481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use MPFR" >&5
10482 $as_echo_n "checking whether to use MPFR... " >&6; }
10483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_mpfr" >&5
10484 $as_echo "$with_mpfr" >&6; }
10486 if test "${with_mpfr}" = no; then
10487 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR support disabled; some features may be unavailable." >&5
10488 $as_echo "$as_me: WARNING: MPFR support disabled; some features may be unavailable." >&2;}
10489 HAVE_LIBMPFR=no
10490 else
10499 use_additional=yes
10501 acl_save_prefix="$prefix"
10502 prefix="$acl_final_prefix"
10503 acl_save_exec_prefix="$exec_prefix"
10504 exec_prefix="$acl_final_exec_prefix"
10506 eval additional_includedir=\"$includedir\"
10507 eval additional_libdir=\"$libdir\"
10509 exec_prefix="$acl_save_exec_prefix"
10510 prefix="$acl_save_prefix"
10513 # Check whether --with-libmpfr-prefix was given.
10514 if test "${with_libmpfr_prefix+set}" = set; then :
10515 withval=$with_libmpfr_prefix;
10516 if test "X$withval" = "Xno"; then
10517 use_additional=no
10518 else
10519 if test "X$withval" = "X"; then
10521 acl_save_prefix="$prefix"
10522 prefix="$acl_final_prefix"
10523 acl_save_exec_prefix="$exec_prefix"
10524 exec_prefix="$acl_final_exec_prefix"
10526 eval additional_includedir=\"$includedir\"
10527 eval additional_libdir=\"$libdir\"
10529 exec_prefix="$acl_save_exec_prefix"
10530 prefix="$acl_save_prefix"
10532 else
10533 additional_includedir="$withval/include"
10534 additional_libdir="$withval/lib"
10541 # Check whether --with-libmpfr-type was given.
10542 if test "${with_libmpfr_type+set}" = set; then :
10543 withval=$with_libmpfr_type; with_libmpfr_type=$withval
10544 else
10545 with_libmpfr_type=auto
10548 lib_type=`eval echo \$with_libmpfr_type`
10550 LIBMPFR=
10551 LTLIBMPFR=
10552 INCMPFR=
10553 rpathdirs=
10554 ltrpathdirs=
10555 names_already_handled=
10556 names_next_round='mpfr gmp'
10557 while test -n "$names_next_round"; do
10558 names_this_round="$names_next_round"
10559 names_next_round=
10560 for name in $names_this_round; do
10561 already_handled=
10562 for n in $names_already_handled; do
10563 if test "$n" = "$name"; then
10564 already_handled=yes
10565 break
10567 done
10568 if test -z "$already_handled"; then
10569 names_already_handled="$names_already_handled $name"
10570 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10571 eval value=\"\$HAVE_LIB$uppername\"
10572 if test -n "$value"; then
10573 if test "$value" = yes; then
10574 eval value=\"\$LIB$uppername\"
10575 test -z "$value" || LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$value"
10576 eval value=\"\$LTLIB$uppername\"
10577 test -z "$value" || LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$value"
10578 else
10581 else
10582 found_dir=
10583 found_la=
10584 found_so=
10585 found_a=
10586 if test $use_additional = yes; then
10587 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10588 found_dir="$additional_libdir"
10589 found_so="$additional_libdir/lib$name.$shlibext"
10590 if test -f "$additional_libdir/lib$name.la"; then
10591 found_la="$additional_libdir/lib$name.la"
10593 elif test x$lib_type != xshared; then
10594 if test -f "$additional_libdir/lib$name.$libext"; then
10595 found_dir="$additional_libdir"
10596 found_a="$additional_libdir/lib$name.$libext"
10597 if test -f "$additional_libdir/lib$name.la"; then
10598 found_la="$additional_libdir/lib$name.la"
10603 if test "X$found_dir" = "X"; then
10604 for x in $LDFLAGS $LTLIBMPFR; do
10606 acl_save_prefix="$prefix"
10607 prefix="$acl_final_prefix"
10608 acl_save_exec_prefix="$exec_prefix"
10609 exec_prefix="$acl_final_exec_prefix"
10610 eval x=\"$x\"
10611 exec_prefix="$acl_save_exec_prefix"
10612 prefix="$acl_save_prefix"
10614 case "$x" in
10615 -L*)
10616 dir=`echo "X$x" | sed -e 's/^X-L//'`
10617 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
10618 found_dir="$dir"
10619 found_so="$dir/lib$name.$shlibext"
10620 if test -f "$dir/lib$name.la"; then
10621 found_la="$dir/lib$name.la"
10623 elif test x$lib_type != xshared; then
10624 if test -f "$dir/lib$name.$libext"; then
10625 found_dir="$dir"
10626 found_a="$dir/lib$name.$libext"
10627 if test -f "$dir/lib$name.la"; then
10628 found_la="$dir/lib$name.la"
10633 esac
10634 if test "X$found_dir" != "X"; then
10635 break
10637 done
10639 if test "X$found_dir" != "X"; then
10640 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$found_dir -l$name"
10641 if test "X$found_so" != "X"; then
10642 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
10643 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
10644 else
10645 haveit=
10646 for x in $ltrpathdirs; do
10647 if test "X$x" = "X$found_dir"; then
10648 haveit=yes
10649 break
10651 done
10652 if test -z "$haveit"; then
10653 ltrpathdirs="$ltrpathdirs $found_dir"
10655 if test "$hardcode_direct" = yes; then
10656 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
10657 else
10658 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
10659 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
10660 haveit=
10661 for x in $rpathdirs; do
10662 if test "X$x" = "X$found_dir"; then
10663 haveit=yes
10664 break
10666 done
10667 if test -z "$haveit"; then
10668 rpathdirs="$rpathdirs $found_dir"
10670 else
10671 haveit=
10672 for x in $LDFLAGS $LIBMPFR; do
10674 acl_save_prefix="$prefix"
10675 prefix="$acl_final_prefix"
10676 acl_save_exec_prefix="$exec_prefix"
10677 exec_prefix="$acl_final_exec_prefix"
10678 eval x=\"$x\"
10679 exec_prefix="$acl_save_exec_prefix"
10680 prefix="$acl_save_prefix"
10682 if test "X$x" = "X-L$found_dir"; then
10683 haveit=yes
10684 break
10686 done
10687 if test -z "$haveit"; then
10688 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir"
10690 if test "$hardcode_minus_L" != no; then
10691 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
10692 else
10693 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
10698 else
10699 if test "X$found_a" != "X"; then
10700 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_a"
10701 else
10702 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir -l$name"
10705 additional_includedir=
10706 case "$found_dir" in
10707 */lib | */lib/)
10708 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
10709 additional_includedir="$basedir/include"
10711 esac
10712 if test "X$additional_includedir" != "X"; then
10713 if test "X$additional_includedir" != "X/usr/include"; then
10714 haveit=
10715 if test "X$additional_includedir" = "X/usr/local/include"; then
10716 if test -n "$GCC"; then
10717 case $host_os in
10718 linux*) haveit=yes;;
10719 esac
10722 if test -z "$haveit"; then
10723 for x in $CPPFLAGS $INCMPFR; do
10725 acl_save_prefix="$prefix"
10726 prefix="$acl_final_prefix"
10727 acl_save_exec_prefix="$exec_prefix"
10728 exec_prefix="$acl_final_exec_prefix"
10729 eval x=\"$x\"
10730 exec_prefix="$acl_save_exec_prefix"
10731 prefix="$acl_save_prefix"
10733 if test "X$x" = "X-I$additional_includedir"; then
10734 haveit=yes
10735 break
10737 done
10738 if test -z "$haveit"; then
10739 if test -d "$additional_includedir"; then
10740 INCMPFR="${INCMPFR}${INCMPFR:+ }-I$additional_includedir"
10746 if test -n "$found_la"; then
10747 save_libdir="$libdir"
10748 case "$found_la" in
10749 */* | *\\*) . "$found_la" ;;
10750 *) . "./$found_la" ;;
10751 esac
10752 libdir="$save_libdir"
10753 for dep in $dependency_libs; do
10754 case "$dep" in
10755 -L*)
10756 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10757 if test "X$additional_libdir" != "X/usr/lib"; then
10758 haveit=
10759 if test "X$additional_libdir" = "X/usr/local/lib"; then
10760 if test -n "$GCC"; then
10761 case $host_os in
10762 linux*) haveit=yes;;
10763 esac
10766 if test -z "$haveit"; then
10767 haveit=
10768 for x in $LDFLAGS $LIBMPFR; do
10770 acl_save_prefix="$prefix"
10771 prefix="$acl_final_prefix"
10772 acl_save_exec_prefix="$exec_prefix"
10773 exec_prefix="$acl_final_exec_prefix"
10774 eval x=\"$x\"
10775 exec_prefix="$acl_save_exec_prefix"
10776 prefix="$acl_save_prefix"
10778 if test "X$x" = "X-L$additional_libdir"; then
10779 haveit=yes
10780 break
10782 done
10783 if test -z "$haveit"; then
10784 if test -d "$additional_libdir"; then
10785 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$additional_libdir"
10788 haveit=
10789 for x in $LDFLAGS $LTLIBMPFR; do
10791 acl_save_prefix="$prefix"
10792 prefix="$acl_final_prefix"
10793 acl_save_exec_prefix="$exec_prefix"
10794 exec_prefix="$acl_final_exec_prefix"
10795 eval x=\"$x\"
10796 exec_prefix="$acl_save_exec_prefix"
10797 prefix="$acl_save_prefix"
10799 if test "X$x" = "X-L$additional_libdir"; then
10800 haveit=yes
10801 break
10803 done
10804 if test -z "$haveit"; then
10805 if test -d "$additional_libdir"; then
10806 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$additional_libdir"
10812 -R*)
10813 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10814 if test "$enable_rpath" != no; then
10815 haveit=
10816 for x in $rpathdirs; do
10817 if test "X$x" = "X$dir"; then
10818 haveit=yes
10819 break
10821 done
10822 if test -z "$haveit"; then
10823 rpathdirs="$rpathdirs $dir"
10825 haveit=
10826 for x in $ltrpathdirs; do
10827 if test "X$x" = "X$dir"; then
10828 haveit=yes
10829 break
10831 done
10832 if test -z "$haveit"; then
10833 ltrpathdirs="$ltrpathdirs $dir"
10837 -l*)
10838 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10840 *.la)
10841 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10844 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$dep"
10845 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$dep"
10847 esac
10848 done
10850 else
10851 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
10852 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
10853 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-l$name"
10854 else
10855 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l:lib$name.$libext"
10856 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-l:lib$name.$libext"
10861 done
10862 done
10863 if test "X$rpathdirs" != "X"; then
10864 if test -n "$hardcode_libdir_separator"; then
10865 alldirs=
10866 for found_dir in $rpathdirs; do
10867 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10868 done
10869 acl_save_libdir="$libdir"
10870 libdir="$alldirs"
10871 eval flag=\"$hardcode_libdir_flag_spec\"
10872 libdir="$acl_save_libdir"
10873 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10874 else
10875 for found_dir in $rpathdirs; do
10876 acl_save_libdir="$libdir"
10877 libdir="$found_dir"
10878 eval flag=\"$hardcode_libdir_flag_spec\"
10879 libdir="$acl_save_libdir"
10880 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10881 done
10884 if test "X$ltrpathdirs" != "X"; then
10885 for found_dir in $ltrpathdirs; do
10886 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-R$found_dir"
10887 done
10891 ac_save_CPPFLAGS="$CPPFLAGS"
10893 for element in $INCMPFR; do
10894 haveit=
10895 for x in $CPPFLAGS; do
10897 acl_save_prefix="$prefix"
10898 prefix="$acl_final_prefix"
10899 acl_save_exec_prefix="$exec_prefix"
10900 exec_prefix="$acl_final_exec_prefix"
10901 eval x=\"$x\"
10902 exec_prefix="$acl_save_exec_prefix"
10903 prefix="$acl_save_prefix"
10905 if test "X$x" = "X$element"; then
10906 haveit=yes
10907 break
10909 done
10910 if test -z "$haveit"; then
10911 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10913 done
10916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmpfr" >&5
10917 $as_echo_n "checking for libmpfr... " >&6; }
10918 if ${ac_cv_libmpfr+:} false; then :
10919 $as_echo_n "(cached) " >&6
10920 else
10922 ac_save_LIBS="$LIBS"
10923 LIBS="$LIBS $LIBMPFR"
10924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10925 /* end confdefs.h. */
10926 #include <mpfr.h>
10928 main ()
10930 mpfr_exp_t exp; mpfr_t x;
10931 mpfr_frexp (&exp, x, x, MPFR_RNDN);
10933 return 0;
10935 _ACEOF
10936 if ac_fn_c_try_link "$LINENO"; then :
10937 ac_cv_libmpfr=yes
10938 else
10939 ac_cv_libmpfr=no
10941 rm -f core conftest.err conftest.$ac_objext \
10942 conftest$ac_exeext conftest.$ac_ext
10943 LIBS="$ac_save_LIBS"
10946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libmpfr" >&5
10947 $as_echo "$ac_cv_libmpfr" >&6; }
10948 if test "$ac_cv_libmpfr" = yes; then
10949 HAVE_LIBMPFR=yes
10951 $as_echo "#define HAVE_LIBMPFR 1" >>confdefs.h
10953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libmpfr" >&5
10954 $as_echo_n "checking how to link with libmpfr... " >&6; }
10955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBMPFR" >&5
10956 $as_echo "$LIBMPFR" >&6; }
10957 else
10958 HAVE_LIBMPFR=no
10959 CPPFLAGS="$ac_save_CPPFLAGS"
10960 LIBMPFR=
10961 LTLIBMPFR=
10969 if test "$HAVE_LIBMPFR" != yes; then
10970 if test "$with_mpfr" = yes; then
10971 as_fn_error $? "MPFR is missing or unusable" "$LINENO" 5
10972 else
10973 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR is missing or unusable; some features may be unavailable." >&5
10974 $as_echo "$as_me: WARNING: MPFR is missing or unusable; some features may be unavailable." >&2;}
10979 # --------------------- #
10980 # Check for libpython. #
10981 # --------------------- #
10988 # Check whether --with-python was given.
10989 if test "${with_python+set}" = set; then :
10990 withval=$with_python;
10991 else
10992 with_python=auto
10995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
10996 $as_echo_n "checking whether to use python... " >&6; }
10997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
10998 $as_echo "$with_python" >&6; }
11000 if test "${with_python}" = no; then
11001 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
11002 $as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
11003 have_libpython=no
11004 else
11005 case "${with_python}" in
11006 [\\/]* | ?:[\\/]*)
11007 if test -d "${with_python}"; then
11008 # Assume the python binary is ${with_python}/bin/python.
11009 python_prog="${with_python}/bin/python"
11010 python_prefix=
11011 # If python does not exit ${with_python}/bin, then try in
11012 # ${with_python}. On Windows/MinGW, this is where the Python
11013 # executable is.
11014 if test ! -x "${python_prog}"; then
11015 python_prog="${with_python}/python"
11016 python_prefix=
11018 if test ! -x "${python_prog}"; then
11019 # Fall back to gdb 7.0/7.1 behaviour.
11020 python_prog=missing
11021 python_prefix=${with_python}
11023 elif test -x "${with_python}"; then
11024 # While we can't run python compiled for $host (unless host == build),
11025 # the user could write a script that provides the needed information,
11026 # so we support that.
11027 python_prog=${with_python}
11028 python_prefix=
11029 else
11030 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
11033 */*)
11034 # Disallow --with-python=foo/bar.
11035 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
11038 # The user has either specified auto, yes, or the name of the python
11039 # program assumed to be in $PATH.
11040 python_prefix=
11041 case "${with_python}" in
11042 yes | auto)
11043 if test "${build}" = "${host}"; then
11044 # Extract the first word of "python", so it can be a program name with args.
11045 set dummy python; ac_word=$2
11046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11047 $as_echo_n "checking for $ac_word... " >&6; }
11048 if ${ac_cv_path_python_prog_path+:} false; then :
11049 $as_echo_n "(cached) " >&6
11050 else
11051 case $python_prog_path in
11052 [\\/]* | ?:[\\/]*)
11053 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
11056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11057 for as_dir in $PATH
11059 IFS=$as_save_IFS
11060 test -z "$as_dir" && as_dir=.
11061 for ac_exec_ext in '' $ac_executable_extensions; do
11062 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11063 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
11064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11065 break 2
11067 done
11068 done
11069 IFS=$as_save_IFS
11071 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
11073 esac
11075 python_prog_path=$ac_cv_path_python_prog_path
11076 if test -n "$python_prog_path"; then
11077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
11078 $as_echo "$python_prog_path" >&6; }
11079 else
11080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11081 $as_echo "no" >&6; }
11085 if test "${python_prog_path}" = missing; then
11086 python_prog=missing
11087 else
11088 python_prog=${python_prog_path}
11090 else
11091 # Not much we can do except assume the cross-compiler will find the
11092 # right files.
11093 python_prog=missing
11097 # While we can't run python compiled for $host (unless host == build),
11098 # the user could write a script that provides the needed information,
11099 # so we support that.
11100 python_prog="${with_python}"
11101 # Extract the first word of "${python_prog}", so it can be a program name with args.
11102 set dummy ${python_prog}; ac_word=$2
11103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11104 $as_echo_n "checking for $ac_word... " >&6; }
11105 if ${ac_cv_path_python_prog_path+:} false; then :
11106 $as_echo_n "(cached) " >&6
11107 else
11108 case $python_prog_path in
11109 [\\/]* | ?:[\\/]*)
11110 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
11113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11114 for as_dir in $PATH
11116 IFS=$as_save_IFS
11117 test -z "$as_dir" && as_dir=.
11118 for ac_exec_ext in '' $ac_executable_extensions; do
11119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11120 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
11121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11122 break 2
11124 done
11125 done
11126 IFS=$as_save_IFS
11128 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
11130 esac
11132 python_prog_path=$ac_cv_path_python_prog_path
11133 if test -n "$python_prog_path"; then
11134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
11135 $as_echo "$python_prog_path" >&6; }
11136 else
11137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11138 $as_echo "no" >&6; }
11142 if test "${python_prog_path}" = missing; then
11143 as_fn_error $? "unable to find python program ${python_prog}" "$LINENO" 5
11146 esac
11147 esac
11149 if test "${python_prog}" != missing; then
11150 # We have a python program to use, but it may be too old.
11151 # Don't flag an error for --with-python=auto (the default).
11152 have_python_config=yes
11153 python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
11154 if test $? != 0; then
11155 have_python_config=failed
11156 if test "${with_python}" != auto; then
11157 as_fn_error $? "failure running python-config --includes" "$LINENO" 5
11160 python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
11161 if test $? != 0; then
11162 have_python_config=failed
11163 if test "${with_python}" != auto; then
11164 as_fn_error $? "failure running python-config --ldflags" "$LINENO" 5
11167 python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
11168 if test $? != 0; then
11169 have_python_config=failed
11170 if test "${with_python}" != auto; then
11171 as_fn_error $? "failure running python-config --exec-prefix" "$LINENO" 5
11174 else
11175 # We do not have a python executable we can use to determine where
11176 # to find the Python headers and libs. We cannot guess the include
11177 # path from the python_prefix either, because that include path
11178 # depends on the Python version. So, there is nothing much we can
11179 # do except assume that the compiler will be able to find those files.
11180 python_includes=
11181 python_libs=
11182 have_python_config=no
11185 # If we have python-config, only try the configuration it provides.
11186 # Otherwise fallback on the old way of trying different versions of
11187 # python in turn.
11189 have_libpython=no
11190 if test "${have_python_config}" = yes; then
11193 new_CPPFLAGS=${python_includes}
11194 new_LIBS=${python_libs}
11195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
11196 $as_echo_n "checking for python... " >&6; }
11197 save_CPPFLAGS=$CPPFLAGS
11198 save_LIBS=$LIBS
11199 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11200 LIBS="$new_LIBS $LIBS"
11201 found_usable_python=no
11202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11203 /* end confdefs.h. */
11204 #include "Python.h"
11206 main ()
11208 Py_Initialize ();
11210 return 0;
11212 _ACEOF
11213 if ac_fn_c_try_link "$LINENO"; then :
11214 have_libpython=yes
11215 found_usable_python=yes
11216 PYTHON_CPPFLAGS=$new_CPPFLAGS
11217 PYTHON_LIBS=$new_LIBS
11219 rm -f core conftest.err conftest.$ac_objext \
11220 conftest$ac_exeext conftest.$ac_ext
11221 CPPFLAGS=$save_CPPFLAGS
11222 LIBS=$save_LIBS
11223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
11224 $as_echo "${found_usable_python}" >&6; }
11226 elif test "${have_python_config}" != failed; then
11227 if test "${have_libpython}" = no; then
11230 new_CPPFLAGS=${python_includes}
11231 new_LIBS="-lpython2.7 ${python_libs}"
11232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
11233 $as_echo_n "checking for python... " >&6; }
11234 save_CPPFLAGS=$CPPFLAGS
11235 save_LIBS=$LIBS
11236 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11237 LIBS="$new_LIBS $LIBS"
11238 found_usable_python=no
11239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11240 /* end confdefs.h. */
11241 #include "Python.h"
11243 main ()
11245 Py_Initialize ();
11247 return 0;
11249 _ACEOF
11250 if ac_fn_c_try_link "$LINENO"; then :
11251 have_libpython=yes
11252 found_usable_python=yes
11253 PYTHON_CPPFLAGS=$new_CPPFLAGS
11254 PYTHON_LIBS=$new_LIBS
11256 rm -f core conftest.err conftest.$ac_objext \
11257 conftest$ac_exeext conftest.$ac_ext
11258 CPPFLAGS=$save_CPPFLAGS
11259 LIBS=$save_LIBS
11260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
11261 $as_echo "${found_usable_python}" >&6; }
11264 if test "${have_libpython}" = no; then
11267 new_CPPFLAGS=${python_includes}
11268 new_LIBS="-lpython2.6 ${python_libs}"
11269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
11270 $as_echo_n "checking for python... " >&6; }
11271 save_CPPFLAGS=$CPPFLAGS
11272 save_LIBS=$LIBS
11273 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11274 LIBS="$new_LIBS $LIBS"
11275 found_usable_python=no
11276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11277 /* end confdefs.h. */
11278 #include "Python.h"
11280 main ()
11282 Py_Initialize ();
11284 return 0;
11286 _ACEOF
11287 if ac_fn_c_try_link "$LINENO"; then :
11288 have_libpython=yes
11289 found_usable_python=yes
11290 PYTHON_CPPFLAGS=$new_CPPFLAGS
11291 PYTHON_LIBS=$new_LIBS
11293 rm -f core conftest.err conftest.$ac_objext \
11294 conftest$ac_exeext conftest.$ac_ext
11295 CPPFLAGS=$save_CPPFLAGS
11296 LIBS=$save_LIBS
11297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
11298 $as_echo "${found_usable_python}" >&6; }
11303 if test "${have_libpython}" = no; then
11304 case "${with_python}" in
11305 yes)
11306 as_fn_error $? "python is missing or unusable" "$LINENO" 5
11308 auto)
11309 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
11310 $as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
11313 as_fn_error $? "no usable python found at ${with_python}" "$LINENO" 5
11315 esac
11316 else
11317 if test -n "${python_prefix}"; then
11319 cat >>confdefs.h <<_ACEOF
11320 #define WITH_PYTHON_PATH "${python_prefix}"
11321 _ACEOF
11324 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
11325 if test "x$prefix" = xNONE; then
11326 test_prefix=/usr/local
11327 else
11328 test_prefix=$prefix
11330 else
11331 test_prefix=$exec_prefix
11333 value=0
11334 case ${python_prefix} in
11335 "${test_prefix}"|"${test_prefix}/"*|\
11336 '${exec_prefix}'|'${exec_prefix}/'*)
11337 value=1
11339 esac
11341 cat >>confdefs.h <<_ACEOF
11342 #define PYTHON_PATH_RELOCATABLE $value
11343 _ACEOF
11351 # Check whether --with-python-libdir was given.
11352 if test "${with_python_libdir+set}" = set; then :
11353 withval=$with_python_libdir;
11354 else
11356 # If no python libdir is specified then select one based on
11357 # python's prefix path.
11358 if test -n "${python_prefix}"; then
11359 with_python_libdir=${python_prefix}/lib
11365 if test "${have_libpython}" != no; then
11367 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
11369 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
11370 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
11371 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
11372 CONFIG_INSTALL="$CONFIG_INSTALL install-python"
11373 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
11375 if test -n "${with_python_libdir}"; then
11377 cat >>confdefs.h <<_ACEOF
11378 #define WITH_PYTHON_LIBDIR "${with_python_libdir}"
11379 _ACEOF
11382 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
11383 if test "x$prefix" = xNONE; then
11384 test_prefix=/usr/local
11385 else
11386 test_prefix=$prefix
11388 else
11389 test_prefix=$exec_prefix
11391 value=0
11392 case ${with_python_libdir} in
11393 "${test_prefix}"|"${test_prefix}/"*|\
11394 '${exec_prefix}'|'${exec_prefix}/'*)
11395 value=1
11397 esac
11399 cat >>confdefs.h <<_ACEOF
11400 #define PYTHON_LIBDIR_RELOCATABLE $value
11401 _ACEOF
11406 # Flags needed to compile Python code (taken from python-config --cflags).
11407 # We cannot call python-config directly because it will output whatever was
11408 # used when compiling the Python interpreter itself, including flags which
11409 # would make the python-related objects be compiled differently from the
11410 # rest of GDB (e.g., -O2 and -fPIC).
11411 if test "${GCC}" = yes; then
11412 tentative_python_cflags="-fno-strict-aliasing -fwrapv"
11413 # Python headers recommend -DNDEBUG, but it's unclear if that just
11414 # refers to building Python itself. In release mode, though, it
11415 # doesn't hurt for the Python code in gdb to follow.
11416 $development || tentative_python_cflags="$tentative_python_cflags -DNDEBUG"
11419 if test "x${tentative_python_cflags}" != x; then
11420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
11421 $as_echo_n "checking compiler flags for python code... " >&6; }
11422 for flag in ${tentative_python_cflags}; do
11423 # Check that the compiler accepts it
11424 saved_CFLAGS="$CFLAGS"
11425 CFLAGS="$CFLAGS $flag"
11426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11427 /* end confdefs.h. */
11430 main ()
11434 return 0;
11436 _ACEOF
11437 if ac_fn_c_try_compile "$LINENO"; then :
11438 PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
11440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11441 CFLAGS="$saved_CFLAGS"
11442 done
11443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
11444 $as_echo "${PYTHON_CFLAGS}" >&6; }
11447 # On x64 Windows, Python's include headers, and pyconfig.h in
11448 # particular, rely on MS_WIN64 macro to detect that it's a 64bit
11449 # version of Windows. Unfortunately, MS_WIN64 is only defined if
11450 # _MSC_VER, a Microsoft-specific macro, is defined. So, when
11451 # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
11452 # The issue was reported to the Python community, but still isn't
11453 # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
11455 case "$gdb_host" in
11456 mingw64)
11457 if test "${GCC}" = yes; then
11458 CPPFLAGS="$CPPFLAGS -DMS_WIN64"
11461 esac
11462 else
11463 # Even if Python support is not compiled in, we need to have this file
11464 # included so that the "python" command, et.al., still exists.
11465 CONFIG_OBS="$CONFIG_OBS python/python.o"
11466 CONFIG_SRCS="$CONFIG_SRCS python/python.c"
11469 # Work around Python http://bugs.python.org/issue10112. See also
11470 # http://bugs.python.org/issue11410, otherwise -Wl,--dynamic-list has
11471 # no effect. Note that the only test after this that uses Python is
11472 # the -rdynamic/-Wl,--dynamic-list test, and we do want that one to be
11473 # run without -export-dynamic too.
11474 PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/-Xlinker -export-dynamic//'`
11479 if test "${have_libpython}" != no; then
11480 HAVE_PYTHON_TRUE=
11481 HAVE_PYTHON_FALSE='#'
11482 else
11483 HAVE_PYTHON_TRUE='#'
11484 HAVE_PYTHON_FALSE=
11488 # -------------------- #
11489 # Check for libguile. #
11490 # -------------------- #
11497 # Check whether --with-guile was given.
11498 if test "${with_guile+set}" = set; then :
11499 withval=$with_guile;
11500 else
11501 with_guile=auto
11504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use guile" >&5
11505 $as_echo_n "checking whether to use guile... " >&6; }
11506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_guile" >&5
11507 $as_echo "$with_guile" >&6; }
11509 # Extract the first word of "pkg-config", so it can be a program name with args.
11510 set dummy pkg-config; ac_word=$2
11511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11512 $as_echo_n "checking for $ac_word... " >&6; }
11513 if ${ac_cv_path_pkg_config_prog_path+:} false; then :
11514 $as_echo_n "(cached) " >&6
11515 else
11516 case $pkg_config_prog_path in
11517 [\\/]* | ?:[\\/]*)
11518 ac_cv_path_pkg_config_prog_path="$pkg_config_prog_path" # Let the user override the test with a path.
11521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11522 for as_dir in $PATH
11524 IFS=$as_save_IFS
11525 test -z "$as_dir" && as_dir=.
11526 for ac_exec_ext in '' $ac_executable_extensions; do
11527 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11528 ac_cv_path_pkg_config_prog_path="$as_dir/$ac_word$ac_exec_ext"
11529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11530 break 2
11532 done
11533 done
11534 IFS=$as_save_IFS
11536 test -z "$ac_cv_path_pkg_config_prog_path" && ac_cv_path_pkg_config_prog_path="missing"
11538 esac
11540 pkg_config_prog_path=$ac_cv_path_pkg_config_prog_path
11541 if test -n "$pkg_config_prog_path"; then
11542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pkg_config_prog_path" >&5
11543 $as_echo "$pkg_config_prog_path" >&6; }
11544 else
11545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11546 $as_echo "no" >&6; }
11551 try_guile_versions="guile-3.0 guile-2.2 guile-2.0"
11552 have_libguile=no
11553 case "${with_guile}" in
11555 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: guile support disabled; some features will be unavailable." >&5
11556 $as_echo "$as_me: WARNING: guile support disabled; some features will be unavailable." >&2;}
11558 auto)
11559 if test "${pkg_config_prog_path}" = "missing"; then
11560 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config not found, guile support disabled" >&5
11561 $as_echo "$as_me: WARNING: pkg-config not found, guile support disabled" >&2;}
11562 else
11564 pkg_config=${pkg_config_prog_path}
11565 guile_version_list=${try_guile_versions}
11566 flag_errors=no
11568 found_usable_guile=checking
11569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11570 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11571 for guile_version in ${guile_version_list}; do
11572 ${pkg_config} --exists ${guile_version} 2>/dev/null
11573 if test $? != 0; then
11574 continue
11576 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11577 if test $? != 0; then
11578 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11580 new_LIBS=`${pkg_config} --libs ${guile_version}`
11581 if test $? != 0; then
11582 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11584 found_usable_guile=${guile_version}
11585 break
11586 done
11587 if test "${found_usable_guile}" = "checking"; then
11588 if test "${flag_errors}" = "yes"; then
11589 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11590 else
11591 found_usable_guile=no
11594 if test "${found_usable_guile}" != no; then
11595 save_CPPFLAGS=$CPPFLAGS
11596 save_LIBS=$LIBS
11597 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11598 LIBS="$LIBS $new_LIBS"
11599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11600 /* end confdefs.h. */
11601 #include "libguile.h"
11603 main ()
11605 scm_init_guile ();
11607 return 0;
11609 _ACEOF
11610 if ac_fn_c_try_link "$LINENO"; then :
11611 have_libguile=yes
11612 GUILE_CPPFLAGS=$new_CPPFLAGS
11613 GUILE_LIBS=$new_LIBS
11614 else
11615 found_usable_guile=no
11617 rm -f core conftest.err conftest.$ac_objext \
11618 conftest$ac_exeext conftest.$ac_ext
11619 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11620 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11622 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11627 CPPFLAGS=$save_CPPFLAGS
11628 LIBS=$save_LIBS
11629 if test "${found_usable_guile}" = no; then
11630 if test "${flag_errors}" = yes; then
11631 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11632 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11633 as_fn_error $? "linking guile version ${guile_version} test program failed
11634 See \`config.log' for more details" "$LINENO" 5; }
11638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11639 $as_echo "${found_usable_guile}" >&6; }
11643 yes)
11644 if test "${pkg_config_prog_path}" = "missing"; then
11645 as_fn_error $? "pkg-config not found" "$LINENO" 5
11648 pkg_config=${pkg_config_prog_path}
11649 guile_version_list=${try_guile_versions}
11650 flag_errors=yes
11652 found_usable_guile=checking
11653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11654 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11655 for guile_version in ${guile_version_list}; do
11656 ${pkg_config} --exists ${guile_version} 2>/dev/null
11657 if test $? != 0; then
11658 continue
11660 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11661 if test $? != 0; then
11662 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11664 new_LIBS=`${pkg_config} --libs ${guile_version}`
11665 if test $? != 0; then
11666 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11668 found_usable_guile=${guile_version}
11669 break
11670 done
11671 if test "${found_usable_guile}" = "checking"; then
11672 if test "${flag_errors}" = "yes"; then
11673 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11674 else
11675 found_usable_guile=no
11678 if test "${found_usable_guile}" != no; then
11679 save_CPPFLAGS=$CPPFLAGS
11680 save_LIBS=$LIBS
11681 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11682 LIBS="$LIBS $new_LIBS"
11683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11684 /* end confdefs.h. */
11685 #include "libguile.h"
11687 main ()
11689 scm_init_guile ();
11691 return 0;
11693 _ACEOF
11694 if ac_fn_c_try_link "$LINENO"; then :
11695 have_libguile=yes
11696 GUILE_CPPFLAGS=$new_CPPFLAGS
11697 GUILE_LIBS=$new_LIBS
11698 else
11699 found_usable_guile=no
11701 rm -f core conftest.err conftest.$ac_objext \
11702 conftest$ac_exeext conftest.$ac_ext
11703 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11704 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11706 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11711 CPPFLAGS=$save_CPPFLAGS
11712 LIBS=$save_LIBS
11713 if test "${found_usable_guile}" = no; then
11714 if test "${flag_errors}" = yes; then
11715 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11716 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11717 as_fn_error $? "linking guile version ${guile_version} test program failed
11718 See \`config.log' for more details" "$LINENO" 5; }
11722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11723 $as_echo "${found_usable_guile}" >&6; }
11726 [\\/]* | ?:[\\/]*)
11727 if test -x "${with_guile}"; then
11729 pkg_config=${with_guile}
11730 guile_version_list=${try_guile_versions}
11731 flag_errors=yes
11733 found_usable_guile=checking
11734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11735 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11736 for guile_version in ${guile_version_list}; do
11737 ${pkg_config} --exists ${guile_version} 2>/dev/null
11738 if test $? != 0; then
11739 continue
11741 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11742 if test $? != 0; then
11743 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11745 new_LIBS=`${pkg_config} --libs ${guile_version}`
11746 if test $? != 0; then
11747 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11749 found_usable_guile=${guile_version}
11750 break
11751 done
11752 if test "${found_usable_guile}" = "checking"; then
11753 if test "${flag_errors}" = "yes"; then
11754 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11755 else
11756 found_usable_guile=no
11759 if test "${found_usable_guile}" != no; then
11760 save_CPPFLAGS=$CPPFLAGS
11761 save_LIBS=$LIBS
11762 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11763 LIBS="$LIBS $new_LIBS"
11764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11765 /* end confdefs.h. */
11766 #include "libguile.h"
11768 main ()
11770 scm_init_guile ();
11772 return 0;
11774 _ACEOF
11775 if ac_fn_c_try_link "$LINENO"; then :
11776 have_libguile=yes
11777 GUILE_CPPFLAGS=$new_CPPFLAGS
11778 GUILE_LIBS=$new_LIBS
11779 else
11780 found_usable_guile=no
11782 rm -f core conftest.err conftest.$ac_objext \
11783 conftest$ac_exeext conftest.$ac_ext
11784 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11785 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11787 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11792 CPPFLAGS=$save_CPPFLAGS
11793 LIBS=$save_LIBS
11794 if test "${found_usable_guile}" = no; then
11795 if test "${flag_errors}" = yes; then
11796 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11797 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11798 as_fn_error $? "linking guile version ${guile_version} test program failed
11799 See \`config.log' for more details" "$LINENO" 5; }
11803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11804 $as_echo "${found_usable_guile}" >&6; }
11806 else
11807 as_fn_error $? "Guile config program not executable: ${with_guile}" "$LINENO" 5
11810 "" | */*)
11811 # Disallow --with=guile="" and --with-guile=foo/bar.
11812 as_fn_error $? "invalid value for --with-guile" "$LINENO" 5
11815 # A space separate list of guile versions to try, in order.
11816 if test "${pkg_config_prog_path}" = "missing"; then
11817 as_fn_error $? "pkg-config not found" "$LINENO" 5
11820 pkg_config=${pkg_config_prog_path}
11821 guile_version_list=${with_guile}
11822 flag_errors=yes
11824 found_usable_guile=checking
11825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11826 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11827 for guile_version in ${guile_version_list}; do
11828 ${pkg_config} --exists ${guile_version} 2>/dev/null
11829 if test $? != 0; then
11830 continue
11832 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11833 if test $? != 0; then
11834 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11836 new_LIBS=`${pkg_config} --libs ${guile_version}`
11837 if test $? != 0; then
11838 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11840 found_usable_guile=${guile_version}
11841 break
11842 done
11843 if test "${found_usable_guile}" = "checking"; then
11844 if test "${flag_errors}" = "yes"; then
11845 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11846 else
11847 found_usable_guile=no
11850 if test "${found_usable_guile}" != no; then
11851 save_CPPFLAGS=$CPPFLAGS
11852 save_LIBS=$LIBS
11853 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11854 LIBS="$LIBS $new_LIBS"
11855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11856 /* end confdefs.h. */
11857 #include "libguile.h"
11859 main ()
11861 scm_init_guile ();
11863 return 0;
11865 _ACEOF
11866 if ac_fn_c_try_link "$LINENO"; then :
11867 have_libguile=yes
11868 GUILE_CPPFLAGS=$new_CPPFLAGS
11869 GUILE_LIBS=$new_LIBS
11870 else
11871 found_usable_guile=no
11873 rm -f core conftest.err conftest.$ac_objext \
11874 conftest$ac_exeext conftest.$ac_ext
11875 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11876 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11878 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11883 CPPFLAGS=$save_CPPFLAGS
11884 LIBS=$save_LIBS
11885 if test "${found_usable_guile}" = no; then
11886 if test "${flag_errors}" = yes; then
11887 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11888 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11889 as_fn_error $? "linking guile version ${guile_version} test program failed
11890 See \`config.log' for more details" "$LINENO" 5; }
11894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11895 $as_echo "${found_usable_guile}" >&6; }
11898 esac
11900 if test "${have_libguile}" != no; then
11901 case "${with_guile}" in
11902 [\\/]* | ?:[\\/]*)
11904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11905 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11906 if ${ac_cv_guild_program_name+:} false; then :
11907 $as_echo_n "(cached) " >&6
11908 else
11909 ac_cv_guild_program_name="`"${with_guile}" --variable guild "${guile_version}"`"
11911 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11912 # the 'guild' and 'bindir' variables. In that case, try to guess
11913 # what the program name is, at the risk of getting it wrong if
11914 # Guile was configured with '--program-suffix' or similar.
11915 if test "x$ac_cv_guild_program_name" = "x"; then
11916 guile_exec_prefix="`"${with_guile}" --variable exec_prefix "${guile_version}"`"
11917 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11922 $as_echo "$ac_cv_guild_program_name" >&6; }
11924 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11925 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11928 GUILD="$ac_cv_guild_program_name"
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11935 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11936 if ${ac_cv_guild_program_name+:} false; then :
11937 $as_echo_n "(cached) " >&6
11938 else
11939 ac_cv_guild_program_name="`"${pkg_config_prog_path}" --variable guild "${guile_version}"`"
11941 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11942 # the 'guild' and 'bindir' variables. In that case, try to guess
11943 # what the program name is, at the risk of getting it wrong if
11944 # Guile was configured with '--program-suffix' or similar.
11945 if test "x$ac_cv_guild_program_name" = "x"; then
11946 guile_exec_prefix="`"${pkg_config_prog_path}" --variable exec_prefix "${guile_version}"`"
11947 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11952 $as_echo "$ac_cv_guild_program_name" >&6; }
11954 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11955 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11958 GUILD="$ac_cv_guild_program_name"
11962 esac
11965 if test "$cross_compiling" = no; then
11966 GUILD_TARGET_FLAG=
11967 else
11968 GUILD_TARGET_FLAG="--target=$host"
11974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether guild supports this host" >&5
11975 $as_echo_n "checking whether guild supports this host... " >&6; }
11976 if ${ac_cv_guild_ok+:} false; then :
11977 $as_echo_n "(cached) " >&6
11978 else
11979 echo "$ac_cv_guild_program_name compile $GUILD_TARGET_FLAG -o conftest.go $srcdir/guile/lib/gdb/support.scm" >&5
11980 if "$ac_cv_guild_program_name" compile $GUILD_TARGET_FLAG -o conftest.go "$srcdir/guile/lib/gdb/support.scm" >&5 2>&5; then
11981 ac_cv_guild_ok=yes
11982 else
11983 ac_cv_guild_ok=no
11986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_ok" >&5
11987 $as_echo "$ac_cv_guild_ok" >&6; }
11989 if test "$ac_cv_guild_ok" = no; then
11990 have_libguile=no
11991 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling guile support" >&5
11992 $as_echo "$as_me: WARNING: disabling guile support" >&2;}
11996 if test "${have_libguile}" != no; then
11998 $as_echo "#define HAVE_GUILE 1" >>confdefs.h
12000 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_GUILE_OBS)"
12001 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_GUILE_DEPS)"
12002 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_GUILE_SRCS)"
12003 CONFIG_INSTALL="$CONFIG_INSTALL install-guile"
12004 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_GUILE_CFLAGS)"
12006 save_LIBS="$LIBS"
12007 save_CPPFLAGS="$CPPFLAGS"
12008 LIBS="$GUILE_LIBS"
12009 CPPFLAGS="$GUILE_CPPFLAGS"
12010 for ac_func in scm_new_smob
12011 do :
12012 ac_fn_c_check_func "$LINENO" "scm_new_smob" "ac_cv_func_scm_new_smob"
12013 if test "x$ac_cv_func_scm_new_smob" = xyes; then :
12014 cat >>confdefs.h <<_ACEOF
12015 #define HAVE_SCM_NEW_SMOB 1
12016 _ACEOF
12019 done
12021 LIBS="$save_LIBS"
12022 CPPFLAGS="$save_CPPFLAGS"
12023 else
12024 # Even if Guile support is not compiled in, we need to have these files
12025 # included.
12026 CONFIG_OBS="$CONFIG_OBS guile/guile.o"
12027 CONFIG_SRCS="$CONFIG_SRCS guile/guile.c"
12031 if test "${have_libguile}" != no; then
12032 HAVE_GUILE_TRUE=
12033 HAVE_GUILE_FALSE='#'
12034 else
12035 HAVE_GUILE_TRUE='#'
12036 HAVE_GUILE_FALSE=
12040 # ---------------------------- #
12041 # Check for source highlight. #
12042 # ---------------------------- #
12044 SRCHIGH_LIBS=
12045 SRCHIGH_CFLAGS=
12047 # Check whether --enable-source-highlight was given.
12048 if test "${enable_source_highlight+set}" = set; then :
12049 enableval=$enable_source_highlight; case "${enableval}" in
12050 yes) enable_source_highlight=yes ;;
12051 no) enable_source_highlight=no ;;
12052 *) as_fn_error $? "bad value ${enableval} for source-highlight option" "$LINENO" 5 ;;
12053 esac
12054 else
12055 enable_source_highlight=auto
12059 if test "${enable_source_highlight}" != "no"; then
12060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the source-highlight library" >&5
12061 $as_echo_n "checking for the source-highlight library... " >&6; }
12062 if test "${pkg_config_prog_path}" = "missing"; then
12063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - pkg-config not found" >&5
12064 $as_echo "no - pkg-config not found" >&6; }
12065 if test "${enable_source_highlight}" = "yes"; then
12066 as_fn_error $? "pkg-config was not found in your system" "$LINENO" 5
12068 else
12069 case "$LDFLAGS" in
12070 *static-libstdc*)
12071 as_fn_error $? "source highlight is incompatible with -static-libstdc++; either use --disable-source-highlight or --without-static-standard-libraries" "$LINENO" 5
12073 esac
12075 if ${pkg_config_prog_path} --exists source-highlight; then
12076 SRCHIGH_CFLAGS=`${pkg_config_prog_path} --cflags source-highlight`
12077 SRCHIGH_LIBS=`${pkg_config_prog_path} --libs source-highlight`
12079 $as_echo "#define HAVE_SOURCE_HIGHLIGHT 1" >>confdefs.h
12081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12082 $as_echo "yes" >&6; }
12083 else
12084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12085 $as_echo "no" >&6; }
12086 if test "${enable_source_highlight}" = "yes"; then
12087 as_fn_error $? "source-highlight was not found in your system" "$LINENO" 5
12095 # ------------------------- #
12096 # Checks for header files. #
12097 # ------------------------- #
12099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
12100 $as_echo_n "checking for ANSI C header files... " >&6; }
12101 if ${ac_cv_header_stdc+:} false; then :
12102 $as_echo_n "(cached) " >&6
12103 else
12104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12105 /* end confdefs.h. */
12106 #include <stdlib.h>
12107 #include <stdarg.h>
12108 #include <string.h>
12109 #include <float.h>
12112 main ()
12116 return 0;
12118 _ACEOF
12119 if ac_fn_c_try_compile "$LINENO"; then :
12120 ac_cv_header_stdc=yes
12121 else
12122 ac_cv_header_stdc=no
12124 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12126 if test $ac_cv_header_stdc = yes; then
12127 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12129 /* end confdefs.h. */
12130 #include <string.h>
12132 _ACEOF
12133 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12134 $EGREP "memchr" >/dev/null 2>&1; then :
12136 else
12137 ac_cv_header_stdc=no
12139 rm -f conftest*
12143 if test $ac_cv_header_stdc = yes; then
12144 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12146 /* end confdefs.h. */
12147 #include <stdlib.h>
12149 _ACEOF
12150 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12151 $EGREP "free" >/dev/null 2>&1; then :
12153 else
12154 ac_cv_header_stdc=no
12156 rm -f conftest*
12160 if test $ac_cv_header_stdc = yes; then
12161 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12162 if test "$cross_compiling" = yes; then :
12164 else
12165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12166 /* end confdefs.h. */
12167 #include <ctype.h>
12168 #include <stdlib.h>
12169 #if ((' ' & 0x0FF) == 0x020)
12170 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12171 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12172 #else
12173 # define ISLOWER(c) \
12174 (('a' <= (c) && (c) <= 'i') \
12175 || ('j' <= (c) && (c) <= 'r') \
12176 || ('s' <= (c) && (c) <= 'z'))
12177 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12178 #endif
12180 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12182 main ()
12184 int i;
12185 for (i = 0; i < 256; i++)
12186 if (XOR (islower (i), ISLOWER (i))
12187 || toupper (i) != TOUPPER (i))
12188 return 2;
12189 return 0;
12191 _ACEOF
12192 if ac_fn_c_try_run "$LINENO"; then :
12194 else
12195 ac_cv_header_stdc=no
12197 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12198 conftest.$ac_objext conftest.beam conftest.$ac_ext
12203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
12204 $as_echo "$ac_cv_header_stdc" >&6; }
12205 if test $ac_cv_header_stdc = yes; then
12207 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
12211 # elf_hp.h is for HP/UX 64-bit shared library support.
12212 for ac_header in nlist.h machine/reg.h \
12213 thread_db.h \
12214 sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
12215 sys/resource.h sys/ptrace.h ptrace.h \
12216 sys/reg.h sys/debugreg.h \
12217 termios.h elf_hp.h
12218 do :
12219 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12220 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12221 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12222 cat >>confdefs.h <<_ACEOF
12223 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12224 _ACEOF
12228 done
12230 for ac_header in sys/user.h
12231 do :
12232 ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
12233 # include <sys/param.h>
12234 #endif
12237 if test "x$ac_cv_header_sys_user_h" = xyes; then :
12238 cat >>confdefs.h <<_ACEOF
12239 #define HAVE_SYS_USER_H 1
12240 _ACEOF
12244 done
12247 for ac_header in curses.h cursesX.h ncurses.h ncursesw/ncurses.h ncurses/ncurses.h ncurses/term.h
12248 do :
12249 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12250 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12251 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12252 cat >>confdefs.h <<_ACEOF
12253 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12254 _ACEOF
12258 done
12260 for ac_header in term.h
12261 do :
12262 ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
12263 # include <curses.h>
12264 #endif
12267 if test "x$ac_cv_header_term_h" = xyes; then :
12268 cat >>confdefs.h <<_ACEOF
12269 #define HAVE_TERM_H 1
12270 _ACEOF
12274 done
12277 for ac_header in sys/socket.h
12278 do :
12279 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
12280 if test "x$ac_cv_header_sys_socket_h" = xyes; then :
12281 cat >>confdefs.h <<_ACEOF
12282 #define HAVE_SYS_SOCKET_H 1
12283 _ACEOF
12287 done
12289 for ac_header in ws2tcpip.h
12290 do :
12291 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
12292 if test "x$ac_cv_header_ws2tcpip_h" = xyes; then :
12293 cat >>confdefs.h <<_ACEOF
12294 #define HAVE_WS2TCPIP_H 1
12295 _ACEOF
12299 done
12302 # ------------------------- #
12303 # Checks for declarations. #
12304 # ------------------------- #
12307 # Check for presence and size of long long.
12308 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
12309 if test "x$ac_cv_type_long_long" = xyes; then :
12311 cat >>confdefs.h <<_ACEOF
12312 #define HAVE_LONG_LONG 1
12313 _ACEOF
12315 # The cast to long int works around a bug in the HP C Compiler
12316 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12317 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12318 # This bug is HP SR number 8606223364.
12319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
12320 $as_echo_n "checking size of long long... " >&6; }
12321 if ${ac_cv_sizeof_long_long+:} false; then :
12322 $as_echo_n "(cached) " >&6
12323 else
12324 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
12326 else
12327 if test "$ac_cv_type_long_long" = yes; then
12328 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12329 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12330 as_fn_error 77 "cannot compute sizeof (long long)
12331 See \`config.log' for more details" "$LINENO" 5; }
12332 else
12333 ac_cv_sizeof_long_long=0
12338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
12339 $as_echo "$ac_cv_sizeof_long_long" >&6; }
12343 cat >>confdefs.h <<_ACEOF
12344 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
12345 _ACEOF
12351 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
12352 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
12353 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
12354 ac_have_decl=1
12355 else
12356 ac_have_decl=0
12359 cat >>confdefs.h <<_ACEOF
12360 #define HAVE_DECL_BASENAME $ac_have_decl
12361 _ACEOF
12362 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
12363 if test "x$ac_cv_have_decl_ffs" = xyes; then :
12364 ac_have_decl=1
12365 else
12366 ac_have_decl=0
12369 cat >>confdefs.h <<_ACEOF
12370 #define HAVE_DECL_FFS $ac_have_decl
12371 _ACEOF
12372 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
12373 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
12374 ac_have_decl=1
12375 else
12376 ac_have_decl=0
12379 cat >>confdefs.h <<_ACEOF
12380 #define HAVE_DECL_ASPRINTF $ac_have_decl
12381 _ACEOF
12382 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
12383 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
12384 ac_have_decl=1
12385 else
12386 ac_have_decl=0
12389 cat >>confdefs.h <<_ACEOF
12390 #define HAVE_DECL_VASPRINTF $ac_have_decl
12391 _ACEOF
12392 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12393 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12394 ac_have_decl=1
12395 else
12396 ac_have_decl=0
12399 cat >>confdefs.h <<_ACEOF
12400 #define HAVE_DECL_SNPRINTF $ac_have_decl
12401 _ACEOF
12402 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
12403 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
12404 ac_have_decl=1
12405 else
12406 ac_have_decl=0
12409 cat >>confdefs.h <<_ACEOF
12410 #define HAVE_DECL_VSNPRINTF $ac_have_decl
12411 _ACEOF
12413 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
12414 if test "x$ac_cv_have_decl_strtol" = xyes; then :
12415 ac_have_decl=1
12416 else
12417 ac_have_decl=0
12420 cat >>confdefs.h <<_ACEOF
12421 #define HAVE_DECL_STRTOL $ac_have_decl
12422 _ACEOF
12423 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
12424 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
12425 ac_have_decl=1
12426 else
12427 ac_have_decl=0
12430 cat >>confdefs.h <<_ACEOF
12431 #define HAVE_DECL_STRTOUL $ac_have_decl
12432 _ACEOF
12433 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
12434 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
12435 ac_have_decl=1
12436 else
12437 ac_have_decl=0
12440 cat >>confdefs.h <<_ACEOF
12441 #define HAVE_DECL_STRTOLL $ac_have_decl
12442 _ACEOF
12443 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
12444 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
12445 ac_have_decl=1
12446 else
12447 ac_have_decl=0
12450 cat >>confdefs.h <<_ACEOF
12451 #define HAVE_DECL_STRTOULL $ac_have_decl
12452 _ACEOF
12454 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
12455 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
12456 ac_have_decl=1
12457 else
12458 ac_have_decl=0
12461 cat >>confdefs.h <<_ACEOF
12462 #define HAVE_DECL_STRVERSCMP $ac_have_decl
12463 _ACEOF
12467 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12468 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12469 ac_have_decl=1
12470 else
12471 ac_have_decl=0
12474 cat >>confdefs.h <<_ACEOF
12475 #define HAVE_DECL_SNPRINTF $ac_have_decl
12476 _ACEOF
12479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
12480 $as_echo_n "checking for LC_MESSAGES... " >&6; }
12481 if ${am_cv_val_LC_MESSAGES+:} false; then :
12482 $as_echo_n "(cached) " >&6
12483 else
12484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12485 /* end confdefs.h. */
12486 #include <locale.h>
12488 main ()
12490 return LC_MESSAGES
12492 return 0;
12494 _ACEOF
12495 if ac_fn_c_try_link "$LINENO"; then :
12496 am_cv_val_LC_MESSAGES=yes
12497 else
12498 am_cv_val_LC_MESSAGES=no
12500 rm -f core conftest.err conftest.$ac_objext \
12501 conftest$ac_exeext conftest.$ac_ext
12503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
12504 $as_echo "$am_cv_val_LC_MESSAGES" >&6; }
12505 if test $am_cv_val_LC_MESSAGES = yes; then
12507 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
12512 # ------------------ #
12513 # Checks for types. #
12514 # ------------------ #
12516 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
12517 #if HAVE_SYS_SOCKET_H
12518 # include <sys/socket.h>
12519 #elif HAVE_WS2TCPIP_H
12520 # include <ws2tcpip.h>
12521 #endif
12524 if test "x$ac_cv_type_socklen_t" = xyes; then :
12526 cat >>confdefs.h <<_ACEOF
12527 #define HAVE_SOCKLEN_T 1
12528 _ACEOF
12534 # ------------------------------------- #
12535 # Checks for compiler characteristics. #
12536 # ------------------------------------- #
12538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
12539 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
12540 if ${ac_cv_c_const+:} false; then :
12541 $as_echo_n "(cached) " >&6
12542 else
12543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12544 /* end confdefs.h. */
12547 main ()
12550 #ifndef __cplusplus
12551 /* Ultrix mips cc rejects this sort of thing. */
12552 typedef int charset[2];
12553 const charset cs = { 0, 0 };
12554 /* SunOS 4.1.1 cc rejects this. */
12555 char const *const *pcpcc;
12556 char **ppc;
12557 /* NEC SVR4.0.2 mips cc rejects this. */
12558 struct point {int x, y;};
12559 static struct point const zero = {0,0};
12560 /* AIX XL C 1.02.0.0 rejects this.
12561 It does not let you subtract one const X* pointer from another in
12562 an arm of an if-expression whose if-part is not a constant
12563 expression */
12564 const char *g = "string";
12565 pcpcc = &g + (g ? g-g : 0);
12566 /* HPUX 7.0 cc rejects these. */
12567 ++pcpcc;
12568 ppc = (char**) pcpcc;
12569 pcpcc = (char const *const *) ppc;
12570 { /* SCO 3.2v4 cc rejects this sort of thing. */
12571 char tx;
12572 char *t = &tx;
12573 char const *s = 0 ? (char *) 0 : (char const *) 0;
12575 *t++ = 0;
12576 if (s) return 0;
12578 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
12579 int x[] = {25, 17};
12580 const int *foo = &x[0];
12581 ++foo;
12583 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
12584 typedef const int *iptr;
12585 iptr p = 0;
12586 ++p;
12588 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
12589 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
12590 struct s { int j; const int *ap[3]; } bx;
12591 struct s *b = &bx; b->j = 5;
12593 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
12594 const int foo = 10;
12595 if (!foo) return 0;
12597 return !cs[0] && !zero.x;
12598 #endif
12601 return 0;
12603 _ACEOF
12604 if ac_fn_c_try_compile "$LINENO"; then :
12605 ac_cv_c_const=yes
12606 else
12607 ac_cv_c_const=no
12609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
12612 $as_echo "$ac_cv_c_const" >&6; }
12613 if test $ac_cv_c_const = no; then
12615 $as_echo "#define const /**/" >>confdefs.h
12619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
12620 $as_echo_n "checking for inline... " >&6; }
12621 if ${ac_cv_c_inline+:} false; then :
12622 $as_echo_n "(cached) " >&6
12623 else
12624 ac_cv_c_inline=no
12625 for ac_kw in inline __inline__ __inline; do
12626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12627 /* end confdefs.h. */
12628 #ifndef __cplusplus
12629 typedef int foo_t;
12630 static $ac_kw foo_t static_foo () {return 0; }
12631 $ac_kw foo_t foo () {return 0; }
12632 #endif
12634 _ACEOF
12635 if ac_fn_c_try_compile "$LINENO"; then :
12636 ac_cv_c_inline=$ac_kw
12638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12639 test "$ac_cv_c_inline" != no && break
12640 done
12643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
12644 $as_echo "$ac_cv_c_inline" >&6; }
12646 case $ac_cv_c_inline in
12647 inline | yes) ;;
12649 case $ac_cv_c_inline in
12650 no) ac_val=;;
12651 *) ac_val=$ac_cv_c_inline;;
12652 esac
12653 cat >>confdefs.h <<_ACEOF
12654 #ifndef __cplusplus
12655 #define inline $ac_val
12656 #endif
12657 _ACEOF
12659 esac
12661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
12662 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
12663 if ${ac_cv_c_bigendian+:} false; then :
12664 $as_echo_n "(cached) " >&6
12665 else
12666 ac_cv_c_bigendian=unknown
12667 # See if we're dealing with a universal compiler.
12668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12669 /* end confdefs.h. */
12670 #ifndef __APPLE_CC__
12671 not a universal capable compiler
12672 #endif
12673 typedef int dummy;
12675 _ACEOF
12676 if ac_fn_c_try_compile "$LINENO"; then :
12678 # Check for potential -arch flags. It is not universal unless
12679 # there are at least two -arch flags with different values.
12680 ac_arch=
12681 ac_prev=
12682 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
12683 if test -n "$ac_prev"; then
12684 case $ac_word in
12685 i?86 | x86_64 | ppc | ppc64)
12686 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
12687 ac_arch=$ac_word
12688 else
12689 ac_cv_c_bigendian=universal
12690 break
12693 esac
12694 ac_prev=
12695 elif test "x$ac_word" = "x-arch"; then
12696 ac_prev=arch
12698 done
12700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12701 if test $ac_cv_c_bigendian = unknown; then
12702 # See if sys/param.h defines the BYTE_ORDER macro.
12703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12704 /* end confdefs.h. */
12705 #include <sys/types.h>
12706 #include <sys/param.h>
12709 main ()
12711 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
12712 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
12713 && LITTLE_ENDIAN)
12714 bogus endian macros
12715 #endif
12718 return 0;
12720 _ACEOF
12721 if ac_fn_c_try_compile "$LINENO"; then :
12722 # It does; now see whether it defined to BIG_ENDIAN or not.
12723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12724 /* end confdefs.h. */
12725 #include <sys/types.h>
12726 #include <sys/param.h>
12729 main ()
12731 #if BYTE_ORDER != BIG_ENDIAN
12732 not big endian
12733 #endif
12736 return 0;
12738 _ACEOF
12739 if ac_fn_c_try_compile "$LINENO"; then :
12740 ac_cv_c_bigendian=yes
12741 else
12742 ac_cv_c_bigendian=no
12744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12748 if test $ac_cv_c_bigendian = unknown; then
12749 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
12750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12751 /* end confdefs.h. */
12752 #include <limits.h>
12755 main ()
12757 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
12758 bogus endian macros
12759 #endif
12762 return 0;
12764 _ACEOF
12765 if ac_fn_c_try_compile "$LINENO"; then :
12766 # It does; now see whether it defined to _BIG_ENDIAN or not.
12767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12768 /* end confdefs.h. */
12769 #include <limits.h>
12772 main ()
12774 #ifndef _BIG_ENDIAN
12775 not big endian
12776 #endif
12779 return 0;
12781 _ACEOF
12782 if ac_fn_c_try_compile "$LINENO"; then :
12783 ac_cv_c_bigendian=yes
12784 else
12785 ac_cv_c_bigendian=no
12787 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12791 if test $ac_cv_c_bigendian = unknown; then
12792 # Compile a test program.
12793 if test "$cross_compiling" = yes; then :
12794 # Try to guess by grepping values from an object file.
12795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12796 /* end confdefs.h. */
12797 short int ascii_mm[] =
12798 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
12799 short int ascii_ii[] =
12800 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12801 int use_ascii (int i) {
12802 return ascii_mm[i] + ascii_ii[i];
12804 short int ebcdic_ii[] =
12805 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
12806 short int ebcdic_mm[] =
12807 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12808 int use_ebcdic (int i) {
12809 return ebcdic_mm[i] + ebcdic_ii[i];
12811 extern int foo;
12814 main ()
12816 return use_ascii (foo) == use_ebcdic (foo);
12818 return 0;
12820 _ACEOF
12821 if ac_fn_c_try_compile "$LINENO"; then :
12822 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
12823 ac_cv_c_bigendian=yes
12825 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12826 if test "$ac_cv_c_bigendian" = unknown; then
12827 ac_cv_c_bigendian=no
12828 else
12829 # finding both strings is unlikely to happen, but who knows?
12830 ac_cv_c_bigendian=unknown
12834 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12835 else
12836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12837 /* end confdefs.h. */
12838 $ac_includes_default
12840 main ()
12843 /* Are we little or big endian? From Harbison&Steele. */
12844 union
12846 long int l;
12847 char c[sizeof (long int)];
12848 } u;
12849 u.l = 1;
12850 return u.c[sizeof (long int) - 1] == 1;
12853 return 0;
12855 _ACEOF
12856 if ac_fn_c_try_run "$LINENO"; then :
12857 ac_cv_c_bigendian=no
12858 else
12859 ac_cv_c_bigendian=yes
12861 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12862 conftest.$ac_objext conftest.beam conftest.$ac_ext
12867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
12868 $as_echo "$ac_cv_c_bigendian" >&6; }
12869 case $ac_cv_c_bigendian in #(
12870 yes)
12871 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
12872 ;; #(
12874 ;; #(
12875 universal)
12877 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
12879 ;; #(
12881 as_fn_error $? "unknown endianness
12882 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
12883 esac
12886 # ------------------------------ #
12887 # Checks for library functions. #
12888 # ------------------------------ #
12890 for ac_func in getuid getgid \
12891 pipe pread pread64 pwrite resize_term \
12892 getpgid setsid \
12893 sigaction sigsetmask socketpair \
12894 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
12895 setrlimit getrlimit posix_madvise waitpid \
12896 use_default_colors
12897 do :
12898 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12899 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12900 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12901 cat >>confdefs.h <<_ACEOF
12902 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12903 _ACEOF
12906 done
12909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
12910 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
12911 if ${am_cv_langinfo_codeset+:} false; then :
12912 $as_echo_n "(cached) " >&6
12913 else
12914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12915 /* end confdefs.h. */
12916 #include <langinfo.h>
12918 main ()
12920 char* cs = nl_langinfo(CODESET);
12922 return 0;
12924 _ACEOF
12925 if ac_fn_c_try_link "$LINENO"; then :
12926 am_cv_langinfo_codeset=yes
12927 else
12928 am_cv_langinfo_codeset=no
12930 rm -f core conftest.err conftest.$ac_objext \
12931 conftest$ac_exeext conftest.$ac_ext
12934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
12935 $as_echo "$am_cv_langinfo_codeset" >&6; }
12936 if test $am_cv_langinfo_codeset = yes; then
12938 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
12942 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
12943 if test "x$ac_cv_type_size_t" = xyes; then :
12945 else
12947 cat >>confdefs.h <<_ACEOF
12948 #define size_t unsigned int
12949 _ACEOF
12956 for ac_header in $ac_header_list
12957 do :
12958 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12959 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
12961 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12962 cat >>confdefs.h <<_ACEOF
12963 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12964 _ACEOF
12968 done
12976 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
12977 if test "x$ac_cv_type_pid_t" = xyes; then :
12979 else
12981 cat >>confdefs.h <<_ACEOF
12982 #define pid_t int
12983 _ACEOF
12987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12988 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12989 if ${ac_cv_path_SED+:} false; then :
12990 $as_echo_n "(cached) " >&6
12991 else
12992 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12993 for ac_i in 1 2 3 4 5 6 7; do
12994 ac_script="$ac_script$as_nl$ac_script"
12995 done
12996 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12997 { ac_script=; unset ac_script;}
12998 if test -z "$SED"; then
12999 ac_path_SED_found=false
13000 # Loop through the user's path and test for each of PROGNAME-LIST
13001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13002 for as_dir in $PATH
13004 IFS=$as_save_IFS
13005 test -z "$as_dir" && as_dir=.
13006 for ac_prog in sed gsed; do
13007 for ac_exec_ext in '' $ac_executable_extensions; do
13008 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
13009 as_fn_executable_p "$ac_path_SED" || continue
13010 # Check for GNU ac_path_SED and select it if it is found.
13011 # Check for GNU $ac_path_SED
13012 case `"$ac_path_SED" --version 2>&1` in
13013 *GNU*)
13014 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
13016 ac_count=0
13017 $as_echo_n 0123456789 >"conftest.in"
13018 while :
13020 cat "conftest.in" "conftest.in" >"conftest.tmp"
13021 mv "conftest.tmp" "conftest.in"
13022 cp "conftest.in" "conftest.nl"
13023 $as_echo '' >> "conftest.nl"
13024 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
13025 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
13026 as_fn_arith $ac_count + 1 && ac_count=$as_val
13027 if test $ac_count -gt ${ac_path_SED_max-0}; then
13028 # Best one so far, save it but keep looking for a better one
13029 ac_cv_path_SED="$ac_path_SED"
13030 ac_path_SED_max=$ac_count
13032 # 10*(2^10) chars as input seems more than enough
13033 test $ac_count -gt 10 && break
13034 done
13035 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
13036 esac
13038 $ac_path_SED_found && break 3
13039 done
13040 done
13041 done
13042 IFS=$as_save_IFS
13043 if test -z "$ac_cv_path_SED"; then
13044 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
13046 else
13047 ac_cv_path_SED=$SED
13051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
13052 $as_echo "$ac_cv_path_SED" >&6; }
13053 SED="$ac_cv_path_SED"
13054 rm -f conftest.sed
13057 # Set the 'development' global.
13058 . $srcdir/../bfd/development.sh
13060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
13061 $as_echo_n "checking for ANSI C header files... " >&6; }
13062 if ${ac_cv_header_stdc+:} false; then :
13063 $as_echo_n "(cached) " >&6
13064 else
13065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13066 /* end confdefs.h. */
13067 #include <stdlib.h>
13068 #include <stdarg.h>
13069 #include <string.h>
13070 #include <float.h>
13073 main ()
13077 return 0;
13079 _ACEOF
13080 if ac_fn_c_try_compile "$LINENO"; then :
13081 ac_cv_header_stdc=yes
13082 else
13083 ac_cv_header_stdc=no
13085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13087 if test $ac_cv_header_stdc = yes; then
13088 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13090 /* end confdefs.h. */
13091 #include <string.h>
13093 _ACEOF
13094 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13095 $EGREP "memchr" >/dev/null 2>&1; then :
13097 else
13098 ac_cv_header_stdc=no
13100 rm -f conftest*
13104 if test $ac_cv_header_stdc = yes; then
13105 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13107 /* end confdefs.h. */
13108 #include <stdlib.h>
13110 _ACEOF
13111 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13112 $EGREP "free" >/dev/null 2>&1; then :
13114 else
13115 ac_cv_header_stdc=no
13117 rm -f conftest*
13121 if test $ac_cv_header_stdc = yes; then
13122 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13123 if test "$cross_compiling" = yes; then :
13125 else
13126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13127 /* end confdefs.h. */
13128 #include <ctype.h>
13129 #include <stdlib.h>
13130 #if ((' ' & 0x0FF) == 0x020)
13131 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13132 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13133 #else
13134 # define ISLOWER(c) \
13135 (('a' <= (c) && (c) <= 'i') \
13136 || ('j' <= (c) && (c) <= 'r') \
13137 || ('s' <= (c) && (c) <= 'z'))
13138 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13139 #endif
13141 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13143 main ()
13145 int i;
13146 for (i = 0; i < 256; i++)
13147 if (XOR (islower (i), ISLOWER (i))
13148 || toupper (i) != TOUPPER (i))
13149 return 2;
13150 return 0;
13152 _ACEOF
13153 if ac_fn_c_try_run "$LINENO"; then :
13155 else
13156 ac_cv_header_stdc=no
13158 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13159 conftest.$ac_objext conftest.beam conftest.$ac_ext
13164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
13165 $as_echo "$ac_cv_header_stdc" >&6; }
13166 if test $ac_cv_header_stdc = yes; then
13168 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
13172 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
13173 # for constant arguments. Useless!
13174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
13175 $as_echo_n "checking for working alloca.h... " >&6; }
13176 if ${ac_cv_working_alloca_h+:} false; then :
13177 $as_echo_n "(cached) " >&6
13178 else
13179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13180 /* end confdefs.h. */
13181 #include <alloca.h>
13183 main ()
13185 char *p = (char *) alloca (2 * sizeof (int));
13186 if (p) return 0;
13188 return 0;
13190 _ACEOF
13191 if ac_fn_c_try_link "$LINENO"; then :
13192 ac_cv_working_alloca_h=yes
13193 else
13194 ac_cv_working_alloca_h=no
13196 rm -f core conftest.err conftest.$ac_objext \
13197 conftest$ac_exeext conftest.$ac_ext
13199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
13200 $as_echo "$ac_cv_working_alloca_h" >&6; }
13201 if test $ac_cv_working_alloca_h = yes; then
13203 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
13207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
13208 $as_echo_n "checking for alloca... " >&6; }
13209 if ${ac_cv_func_alloca_works+:} false; then :
13210 $as_echo_n "(cached) " >&6
13211 else
13212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13213 /* end confdefs.h. */
13214 #ifdef __GNUC__
13215 # define alloca __builtin_alloca
13216 #else
13217 # ifdef _MSC_VER
13218 # include <malloc.h>
13219 # define alloca _alloca
13220 # else
13221 # ifdef HAVE_ALLOCA_H
13222 # include <alloca.h>
13223 # else
13224 # ifdef _AIX
13225 #pragma alloca
13226 # else
13227 # ifndef alloca /* predefined by HP cc +Olibcalls */
13228 void *alloca (size_t);
13229 # endif
13230 # endif
13231 # endif
13232 # endif
13233 #endif
13236 main ()
13238 char *p = (char *) alloca (1);
13239 if (p) return 0;
13241 return 0;
13243 _ACEOF
13244 if ac_fn_c_try_link "$LINENO"; then :
13245 ac_cv_func_alloca_works=yes
13246 else
13247 ac_cv_func_alloca_works=no
13249 rm -f core conftest.err conftest.$ac_objext \
13250 conftest$ac_exeext conftest.$ac_ext
13252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
13253 $as_echo "$ac_cv_func_alloca_works" >&6; }
13255 if test $ac_cv_func_alloca_works = yes; then
13257 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
13259 else
13260 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
13261 # that cause trouble. Some versions do not even contain alloca or
13262 # contain a buggy version. If you still want to use their alloca,
13263 # use ar to extract alloca.o from them instead of compiling alloca.c.
13265 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
13267 $as_echo "#define C_ALLOCA 1" >>confdefs.h
13270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
13271 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
13272 if ${ac_cv_os_cray+:} false; then :
13273 $as_echo_n "(cached) " >&6
13274 else
13275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13276 /* end confdefs.h. */
13277 #if defined CRAY && ! defined CRAY2
13278 webecray
13279 #else
13280 wenotbecray
13281 #endif
13283 _ACEOF
13284 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13285 $EGREP "webecray" >/dev/null 2>&1; then :
13286 ac_cv_os_cray=yes
13287 else
13288 ac_cv_os_cray=no
13290 rm -f conftest*
13293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
13294 $as_echo "$ac_cv_os_cray" >&6; }
13295 if test $ac_cv_os_cray = yes; then
13296 for ac_func in _getb67 GETB67 getb67; do
13297 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13298 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13299 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13301 cat >>confdefs.h <<_ACEOF
13302 #define CRAY_STACKSEG_END $ac_func
13303 _ACEOF
13305 break
13308 done
13311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
13312 $as_echo_n "checking stack direction for C alloca... " >&6; }
13313 if ${ac_cv_c_stack_direction+:} false; then :
13314 $as_echo_n "(cached) " >&6
13315 else
13316 if test "$cross_compiling" = yes; then :
13317 ac_cv_c_stack_direction=0
13318 else
13319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13320 /* end confdefs.h. */
13321 $ac_includes_default
13323 find_stack_direction (int *addr, int depth)
13325 int dir, dummy = 0;
13326 if (! addr)
13327 addr = &dummy;
13328 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
13329 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
13330 return dir + dummy;
13334 main (int argc, char **argv)
13336 return find_stack_direction (0, argc + !argv + 20) < 0;
13338 _ACEOF
13339 if ac_fn_c_try_run "$LINENO"; then :
13340 ac_cv_c_stack_direction=1
13341 else
13342 ac_cv_c_stack_direction=-1
13344 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13345 conftest.$ac_objext conftest.beam conftest.$ac_ext
13349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
13350 $as_echo "$ac_cv_c_stack_direction" >&6; }
13351 cat >>confdefs.h <<_ACEOF
13352 #define STACK_DIRECTION $ac_cv_c_stack_direction
13353 _ACEOF
13359 WIN32APILIBS=
13360 case ${host} in
13361 *mingw32*)
13363 $as_echo "#define USE_WIN32API 1" >>confdefs.h
13365 WIN32APILIBS="-lws2_32"
13367 esac
13370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13371 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13372 if ${am_cv_langinfo_codeset+:} false; then :
13373 $as_echo_n "(cached) " >&6
13374 else
13375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13376 /* end confdefs.h. */
13377 #include <langinfo.h>
13379 main ()
13381 char* cs = nl_langinfo(CODESET);
13383 return 0;
13385 _ACEOF
13386 if ac_fn_c_try_link "$LINENO"; then :
13387 am_cv_langinfo_codeset=yes
13388 else
13389 am_cv_langinfo_codeset=no
13391 rm -f core conftest.err conftest.$ac_objext \
13392 conftest$ac_exeext conftest.$ac_ext
13395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13396 $as_echo "$am_cv_langinfo_codeset" >&6; }
13397 if test $am_cv_langinfo_codeset = yes; then
13399 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13404 for ac_header in linux/perf_event.h locale.h memory.h signal.h sys/resource.h sys/socket.h sys/un.h sys/wait.h thread_db.h wait.h termios.h dlfcn.h linux/elf.h proc_service.h poll.h sys/poll.h sys/select.h
13405 do :
13406 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13407 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13408 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13409 cat >>confdefs.h <<_ACEOF
13410 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13411 _ACEOF
13415 done
13419 for ac_func in getpagesize
13420 do :
13421 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
13422 if test "x$ac_cv_func_getpagesize" = xyes; then :
13423 cat >>confdefs.h <<_ACEOF
13424 #define HAVE_GETPAGESIZE 1
13425 _ACEOF
13428 done
13430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
13431 $as_echo_n "checking for working mmap... " >&6; }
13432 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
13433 $as_echo_n "(cached) " >&6
13434 else
13435 if test "$cross_compiling" = yes; then :
13436 ac_cv_func_mmap_fixed_mapped=no
13437 else
13438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13439 /* end confdefs.h. */
13440 $ac_includes_default
13441 /* malloc might have been renamed as rpl_malloc. */
13442 #undef malloc
13444 /* Thanks to Mike Haertel and Jim Avera for this test.
13445 Here is a matrix of mmap possibilities:
13446 mmap private not fixed
13447 mmap private fixed at somewhere currently unmapped
13448 mmap private fixed at somewhere already mapped
13449 mmap shared not fixed
13450 mmap shared fixed at somewhere currently unmapped
13451 mmap shared fixed at somewhere already mapped
13452 For private mappings, we should verify that changes cannot be read()
13453 back from the file, nor mmap's back from the file at a different
13454 address. (There have been systems where private was not correctly
13455 implemented like the infamous i386 svr4.0, and systems where the
13456 VM page cache was not coherent with the file system buffer cache
13457 like early versions of FreeBSD and possibly contemporary NetBSD.)
13458 For shared mappings, we should conversely verify that changes get
13459 propagated back to all the places they're supposed to be.
13461 Grep wants private fixed already mapped.
13462 The main things grep needs to know about mmap are:
13463 * does it exist and is it safe to write into the mmap'd area
13464 * how to use it (BSD variants) */
13466 #include <fcntl.h>
13467 #include <sys/mman.h>
13469 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
13470 char *malloc ();
13471 #endif
13473 /* This mess was copied from the GNU getpagesize.h. */
13474 #ifndef HAVE_GETPAGESIZE
13475 # ifdef _SC_PAGESIZE
13476 # define getpagesize() sysconf(_SC_PAGESIZE)
13477 # else /* no _SC_PAGESIZE */
13478 # ifdef HAVE_SYS_PARAM_H
13479 # include <sys/param.h>
13480 # ifdef EXEC_PAGESIZE
13481 # define getpagesize() EXEC_PAGESIZE
13482 # else /* no EXEC_PAGESIZE */
13483 # ifdef NBPG
13484 # define getpagesize() NBPG * CLSIZE
13485 # ifndef CLSIZE
13486 # define CLSIZE 1
13487 # endif /* no CLSIZE */
13488 # else /* no NBPG */
13489 # ifdef NBPC
13490 # define getpagesize() NBPC
13491 # else /* no NBPC */
13492 # ifdef PAGESIZE
13493 # define getpagesize() PAGESIZE
13494 # endif /* PAGESIZE */
13495 # endif /* no NBPC */
13496 # endif /* no NBPG */
13497 # endif /* no EXEC_PAGESIZE */
13498 # else /* no HAVE_SYS_PARAM_H */
13499 # define getpagesize() 8192 /* punt totally */
13500 # endif /* no HAVE_SYS_PARAM_H */
13501 # endif /* no _SC_PAGESIZE */
13503 #endif /* no HAVE_GETPAGESIZE */
13506 main ()
13508 char *data, *data2, *data3;
13509 const char *cdata2;
13510 int i, pagesize;
13511 int fd, fd2;
13513 pagesize = getpagesize ();
13515 /* First, make a file with some known garbage in it. */
13516 data = (char *) malloc (pagesize);
13517 if (!data)
13518 return 1;
13519 for (i = 0; i < pagesize; ++i)
13520 *(data + i) = rand ();
13521 umask (0);
13522 fd = creat ("conftest.mmap", 0600);
13523 if (fd < 0)
13524 return 2;
13525 if (write (fd, data, pagesize) != pagesize)
13526 return 3;
13527 close (fd);
13529 /* Next, check that the tail of a page is zero-filled. File must have
13530 non-zero length, otherwise we risk SIGBUS for entire page. */
13531 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
13532 if (fd2 < 0)
13533 return 4;
13534 cdata2 = "";
13535 if (write (fd2, cdata2, 1) != 1)
13536 return 5;
13537 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
13538 if (data2 == MAP_FAILED)
13539 return 6;
13540 for (i = 0; i < pagesize; ++i)
13541 if (*(data2 + i))
13542 return 7;
13543 close (fd2);
13544 if (munmap (data2, pagesize))
13545 return 8;
13547 /* Next, try to mmap the file at a fixed address which already has
13548 something else allocated at it. If we can, also make sure that
13549 we see the same garbage. */
13550 fd = open ("conftest.mmap", O_RDWR);
13551 if (fd < 0)
13552 return 9;
13553 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
13554 MAP_PRIVATE | MAP_FIXED, fd, 0L))
13555 return 10;
13556 for (i = 0; i < pagesize; ++i)
13557 if (*(data + i) != *(data2 + i))
13558 return 11;
13560 /* Finally, make sure that changes to the mapped area do not
13561 percolate back to the file as seen by read(). (This is a bug on
13562 some variants of i386 svr4.0.) */
13563 for (i = 0; i < pagesize; ++i)
13564 *(data2 + i) = *(data2 + i) + 1;
13565 data3 = (char *) malloc (pagesize);
13566 if (!data3)
13567 return 12;
13568 if (read (fd, data3, pagesize) != pagesize)
13569 return 13;
13570 for (i = 0; i < pagesize; ++i)
13571 if (*(data + i) != *(data3 + i))
13572 return 14;
13573 close (fd);
13574 return 0;
13576 _ACEOF
13577 if ac_fn_c_try_run "$LINENO"; then :
13578 ac_cv_func_mmap_fixed_mapped=yes
13579 else
13580 ac_cv_func_mmap_fixed_mapped=no
13582 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13583 conftest.$ac_objext conftest.beam conftest.$ac_ext
13587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
13588 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
13589 if test $ac_cv_func_mmap_fixed_mapped = yes; then
13591 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
13594 rm -f conftest.mmap conftest.txt
13596 for ac_header in vfork.h
13597 do :
13598 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
13599 if test "x$ac_cv_header_vfork_h" = xyes; then :
13600 cat >>confdefs.h <<_ACEOF
13601 #define HAVE_VFORK_H 1
13602 _ACEOF
13606 done
13608 for ac_func in fork vfork
13609 do :
13610 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13611 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13612 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13613 cat >>confdefs.h <<_ACEOF
13614 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13615 _ACEOF
13618 done
13620 if test "x$ac_cv_func_fork" = xyes; then
13621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
13622 $as_echo_n "checking for working fork... " >&6; }
13623 if ${ac_cv_func_fork_works+:} false; then :
13624 $as_echo_n "(cached) " >&6
13625 else
13626 if test "$cross_compiling" = yes; then :
13627 ac_cv_func_fork_works=cross
13628 else
13629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13630 /* end confdefs.h. */
13631 $ac_includes_default
13633 main ()
13636 /* By Ruediger Kuhlmann. */
13637 return fork () < 0;
13640 return 0;
13642 _ACEOF
13643 if ac_fn_c_try_run "$LINENO"; then :
13644 ac_cv_func_fork_works=yes
13645 else
13646 ac_cv_func_fork_works=no
13648 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13649 conftest.$ac_objext conftest.beam conftest.$ac_ext
13653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13654 $as_echo "$ac_cv_func_fork_works" >&6; }
13656 else
13657 ac_cv_func_fork_works=$ac_cv_func_fork
13659 if test "x$ac_cv_func_fork_works" = xcross; then
13660 case $host in
13661 *-*-amigaos* | *-*-msdosdjgpp*)
13662 # Override, as these systems have only a dummy fork() stub
13663 ac_cv_func_fork_works=no
13666 ac_cv_func_fork_works=yes
13668 esac
13669 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13670 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13672 ac_cv_func_vfork_works=$ac_cv_func_vfork
13673 if test "x$ac_cv_func_vfork" = xyes; then
13674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13675 $as_echo_n "checking for working vfork... " >&6; }
13676 if ${ac_cv_func_vfork_works+:} false; then :
13677 $as_echo_n "(cached) " >&6
13678 else
13679 if test "$cross_compiling" = yes; then :
13680 ac_cv_func_vfork_works=cross
13681 else
13682 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13683 /* end confdefs.h. */
13684 /* Thanks to Paul Eggert for this test. */
13685 $ac_includes_default
13686 #include <sys/wait.h>
13687 #ifdef HAVE_VFORK_H
13688 # include <vfork.h>
13689 #endif
13690 /* On some sparc systems, changes by the child to local and incoming
13691 argument registers are propagated back to the parent. The compiler
13692 is told about this with #include <vfork.h>, but some compilers
13693 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13694 static variable whose address is put into a register that is
13695 clobbered by the vfork. */
13696 static void
13697 #ifdef __cplusplus
13698 sparc_address_test (int arg)
13699 # else
13700 sparc_address_test (arg) int arg;
13701 #endif
13703 static pid_t child;
13704 if (!child) {
13705 child = vfork ();
13706 if (child < 0) {
13707 perror ("vfork");
13708 _exit(2);
13710 if (!child) {
13711 arg = getpid();
13712 write(-1, "", 0);
13713 _exit (arg);
13719 main ()
13721 pid_t parent = getpid ();
13722 pid_t child;
13724 sparc_address_test (0);
13726 child = vfork ();
13728 if (child == 0) {
13729 /* Here is another test for sparc vfork register problems. This
13730 test uses lots of local variables, at least as many local
13731 variables as main has allocated so far including compiler
13732 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13733 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13734 reuse the register of parent for one of the local variables,
13735 since it will think that parent can't possibly be used any more
13736 in this routine. Assigning to the local variable will thus
13737 munge parent in the parent process. */
13738 pid_t
13739 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13740 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13741 /* Convince the compiler that p..p7 are live; otherwise, it might
13742 use the same hardware register for all 8 local variables. */
13743 if (p != p1 || p != p2 || p != p3 || p != p4
13744 || p != p5 || p != p6 || p != p7)
13745 _exit(1);
13747 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13748 from child file descriptors. If the child closes a descriptor
13749 before it execs or exits, this munges the parent's descriptor
13750 as well. Test for this by closing stdout in the child. */
13751 _exit(close(fileno(stdout)) != 0);
13752 } else {
13753 int status;
13754 struct stat st;
13756 while (wait(&status) != child)
13758 return (
13759 /* Was there some problem with vforking? */
13760 child < 0
13762 /* Did the child fail? (This shouldn't happen.) */
13763 || status
13765 /* Did the vfork/compiler bug occur? */
13766 || parent != getpid()
13768 /* Did the file descriptor bug occur? */
13769 || fstat(fileno(stdout), &st) != 0
13773 _ACEOF
13774 if ac_fn_c_try_run "$LINENO"; then :
13775 ac_cv_func_vfork_works=yes
13776 else
13777 ac_cv_func_vfork_works=no
13779 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13780 conftest.$ac_objext conftest.beam conftest.$ac_ext
13784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13785 $as_echo "$ac_cv_func_vfork_works" >&6; }
13788 if test "x$ac_cv_func_fork_works" = xcross; then
13789 ac_cv_func_vfork_works=$ac_cv_func_vfork
13790 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13791 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13794 if test "x$ac_cv_func_vfork_works" = xyes; then
13796 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13798 else
13800 $as_echo "#define vfork fork" >>confdefs.h
13803 if test "x$ac_cv_func_fork_works" = xyes; then
13805 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13809 for ac_func in fdwalk getrlimit pipe pipe2 poll socketpair sigaction \
13810 ptrace64 sbrk setns sigaltstack sigprocmask \
13811 setpgid setpgrp getrusage getauxval
13812 do :
13813 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13814 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13815 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13816 cat >>confdefs.h <<_ACEOF
13817 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13818 _ACEOF
13821 done
13824 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
13826 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
13827 ac_have_decl=1
13828 else
13829 ac_have_decl=0
13832 cat >>confdefs.h <<_ACEOF
13833 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
13834 _ACEOF
13837 if test "$cross_compiling" = yes; then :
13838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13839 /* end confdefs.h. */
13840 #include <sys/personality.h>
13842 main ()
13845 # if !HAVE_DECL_ADDR_NO_RANDOMIZE
13846 # define ADDR_NO_RANDOMIZE 0x0040000
13847 # endif
13848 /* Test the flag could be set and stays set. */
13849 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
13850 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
13851 return 1
13853 return 0;
13855 _ACEOF
13856 if ac_fn_c_try_link "$LINENO"; then :
13857 have_personality=true
13858 else
13859 have_personality=false
13861 rm -f core conftest.err conftest.$ac_objext \
13862 conftest$ac_exeext conftest.$ac_ext
13863 else
13864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13865 /* end confdefs.h. */
13866 #include <sys/personality.h>
13868 main ()
13871 # if !HAVE_DECL_ADDR_NO_RANDOMIZE
13872 # define ADDR_NO_RANDOMIZE 0x0040000
13873 # endif
13874 /* Test the flag could be set and stays set. */
13875 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
13876 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
13877 return 1
13879 return 0;
13881 _ACEOF
13882 if ac_fn_c_try_run "$LINENO"; then :
13883 have_personality=true
13884 else
13885 have_personality=false
13887 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13888 conftest.$ac_objext conftest.beam conftest.$ac_ext
13891 if $have_personality
13892 then
13894 $as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
13898 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
13899 if test "x$ac_cv_have_decl_strstr" = xyes; then :
13900 ac_have_decl=1
13901 else
13902 ac_have_decl=0
13905 cat >>confdefs.h <<_ACEOF
13906 #define HAVE_DECL_STRSTR $ac_have_decl
13907 _ACEOF
13910 # ----------------------- #
13911 # Checks for structures. #
13912 # ----------------------- #
13914 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
13915 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
13917 cat >>confdefs.h <<_ACEOF
13918 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
13919 _ACEOF
13923 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
13924 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
13926 cat >>confdefs.h <<_ACEOF
13927 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13928 _ACEOF
13934 # On FreeBSD we need libutil for the kinfo_get* functions. On
13935 # GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
13936 # Figure out which one to use.
13937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
13938 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
13939 if ${ac_cv_search_kinfo_getfile+:} false; then :
13940 $as_echo_n "(cached) " >&6
13941 else
13942 ac_func_search_save_LIBS=$LIBS
13943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13944 /* end confdefs.h. */
13946 /* Override any GCC internal prototype to avoid an error.
13947 Use char because int might match the return type of a GCC
13948 builtin and then its argument prototype would still apply. */
13949 #ifdef __cplusplus
13950 extern "C"
13951 #endif
13952 char kinfo_getfile ();
13954 main ()
13956 return kinfo_getfile ();
13958 return 0;
13960 _ACEOF
13961 for ac_lib in '' util util-freebsd; do
13962 if test -z "$ac_lib"; then
13963 ac_res="none required"
13964 else
13965 ac_res=-l$ac_lib
13966 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
13968 if ac_fn_c_try_link "$LINENO"; then :
13969 ac_cv_search_kinfo_getfile=$ac_res
13971 rm -f core conftest.err conftest.$ac_objext \
13972 conftest$ac_exeext
13973 if ${ac_cv_search_kinfo_getfile+:} false; then :
13974 break
13976 done
13977 if ${ac_cv_search_kinfo_getfile+:} false; then :
13979 else
13980 ac_cv_search_kinfo_getfile=no
13982 rm conftest.$ac_ext
13983 LIBS=$ac_func_search_save_LIBS
13985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
13986 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
13987 ac_res=$ac_cv_search_kinfo_getfile
13988 if test "$ac_res" != no; then :
13989 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13994 # Define HAVE_KINFO_GETFILE if kinfo_getfile is available.
13995 for ac_func in kinfo_getfile
13996 do :
13997 ac_fn_c_check_func "$LINENO" "kinfo_getfile" "ac_cv_func_kinfo_getfile"
13998 if test "x$ac_cv_func_kinfo_getfile" = xyes; then :
13999 cat >>confdefs.h <<_ACEOF
14000 #define HAVE_KINFO_GETFILE 1
14001 _ACEOF
14004 done
14007 # Check for std::thread. This does not work on some platforms, like
14008 # mingw and DJGPP.
14009 ac_ext=cpp
14010 ac_cpp='$CXXCPP $CPPFLAGS'
14011 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14012 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14013 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14019 ac_ext=c
14020 ac_cpp='$CPP $CPPFLAGS'
14021 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14022 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14023 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14025 ax_pthread_ok=no
14027 # We used to check for pthread.h first, but this fails if pthread.h
14028 # requires special compiler flags (e.g. on Tru64 or Sequent).
14029 # It gets checked for in the link test anyway.
14031 # First of all, check if the user has set any of the PTHREAD_LIBS,
14032 # etcetera environment variables, and if threads linking works using
14033 # them:
14034 if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
14035 ax_pthread_save_CC="$CC"
14036 ax_pthread_save_CFLAGS="$CFLAGS"
14037 ax_pthread_save_LIBS="$LIBS"
14038 if test "x$PTHREAD_CC" != "x"; then :
14039 CC="$PTHREAD_CC"
14041 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14042 LIBS="$PTHREAD_LIBS $LIBS"
14043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
14044 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
14045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14046 /* end confdefs.h. */
14048 /* Override any GCC internal prototype to avoid an error.
14049 Use char because int might match the return type of a GCC
14050 builtin and then its argument prototype would still apply. */
14051 #ifdef __cplusplus
14052 extern "C"
14053 #endif
14054 char pthread_join ();
14056 main ()
14058 return pthread_join ();
14060 return 0;
14062 _ACEOF
14063 if ac_fn_c_try_link "$LINENO"; then :
14064 ax_pthread_ok=yes
14066 rm -f core conftest.err conftest.$ac_objext \
14067 conftest$ac_exeext conftest.$ac_ext
14068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
14069 $as_echo "$ax_pthread_ok" >&6; }
14070 if test "x$ax_pthread_ok" = "xno"; then
14071 PTHREAD_LIBS=""
14072 PTHREAD_CFLAGS=""
14074 CC="$ax_pthread_save_CC"
14075 CFLAGS="$ax_pthread_save_CFLAGS"
14076 LIBS="$ax_pthread_save_LIBS"
14079 # We must check for the threads library under a number of different
14080 # names; the ordering is very important because some systems
14081 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
14082 # libraries is broken (non-POSIX).
14084 # Create a list of thread flags to try. Items starting with a "-" are
14085 # C compiler flags, and other items are library names, except for "none"
14086 # which indicates that we try without any flags at all, and "pthread-config"
14087 # which is a program returning the flags for the Pth emulation library.
14089 ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
14091 # The ordering *is* (sometimes) important. Some notes on the
14092 # individual items follow:
14094 # pthreads: AIX (must check this before -lpthread)
14095 # none: in case threads are in libc; should be tried before -Kthread and
14096 # other compiler flags to prevent continual compiler warnings
14097 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
14098 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
14099 # (Note: HP C rejects this with "bad form for `-t' option")
14100 # -pthreads: Solaris/gcc (Note: HP C also rejects)
14101 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
14102 # doesn't hurt to check since this sometimes defines pthreads and
14103 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
14104 # is present but should not be used directly; and before -mthreads,
14105 # because the compiler interprets this as "-mt" + "-hreads")
14106 # -mthreads: Mingw32/gcc, Lynx/gcc
14107 # pthread: Linux, etcetera
14108 # --thread-safe: KAI C++
14109 # pthread-config: use pthread-config program (for GNU Pth library)
14111 case $host_os in
14113 freebsd*)
14115 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
14116 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
14118 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
14121 hpux*)
14123 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
14124 # multi-threading and also sets -lpthread."
14126 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
14129 openedition*)
14131 # IBM z/OS requires a feature-test macro to be defined in order to
14132 # enable POSIX threads at all, so give the user a hint if this is
14133 # not set. (We don't define these ourselves, as they can affect
14134 # other portions of the system API in unpredictable ways.)
14136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14137 /* end confdefs.h. */
14139 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
14140 AX_PTHREAD_ZOS_MISSING
14141 # endif
14143 _ACEOF
14144 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14145 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
14146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
14147 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
14149 rm -f conftest*
14153 solaris*)
14155 # On Solaris (at least, for some versions), libc contains stubbed
14156 # (non-functional) versions of the pthreads routines, so link-based
14157 # tests will erroneously succeed. (N.B.: The stubs are missing
14158 # pthread_cleanup_push, or rather a function called by this macro,
14159 # so we could check for that, but who knows whether they'll stub
14160 # that too in a future libc.) So we'll check first for the
14161 # standard Solaris way of linking pthreads (-mt -lpthread).
14163 ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
14165 esac
14167 # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
14169 if test "x$GCC" = "xyes"; then :
14170 ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
14173 # The presence of a feature test macro requesting re-entrant function
14174 # definitions is, on some systems, a strong hint that pthreads support is
14175 # correctly enabled
14177 case $host_os in
14178 darwin* | hpux* | linux* | osf* | solaris*)
14179 ax_pthread_check_macro="_REENTRANT"
14182 aix*)
14183 ax_pthread_check_macro="_THREAD_SAFE"
14187 ax_pthread_check_macro="--"
14189 esac
14190 if test "x$ax_pthread_check_macro" = "x--"; then :
14191 ax_pthread_check_cond=0
14192 else
14193 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
14196 # Are we compiling with Clang?
14198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
14199 $as_echo_n "checking whether $CC is Clang... " >&6; }
14200 if ${ax_cv_PTHREAD_CLANG+:} false; then :
14201 $as_echo_n "(cached) " >&6
14202 else
14203 ax_cv_PTHREAD_CLANG=no
14204 # Note that Autoconf sets GCC=yes for Clang as well as GCC
14205 if test "x$GCC" = "xyes"; then
14206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14207 /* end confdefs.h. */
14208 /* Note: Clang 2.7 lacks __clang_[a-z]+__ */
14209 # if defined(__clang__) && defined(__llvm__)
14210 AX_PTHREAD_CC_IS_CLANG
14211 # endif
14213 _ACEOF
14214 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14215 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
14216 ax_cv_PTHREAD_CLANG=yes
14218 rm -f conftest*
14223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
14224 $as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
14225 ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
14227 ax_pthread_clang_warning=no
14229 # Clang needs special handling, because older versions handle the -pthread
14230 # option in a rather... idiosyncratic way
14232 if test "x$ax_pthread_clang" = "xyes"; then
14234 # Clang takes -pthread; it has never supported any other flag
14236 # (Note 1: This will need to be revisited if a system that Clang
14237 # supports has POSIX threads in a separate library. This tends not
14238 # to be the way of modern systems, but it's conceivable.)
14240 # (Note 2: On some systems, notably Darwin, -pthread is not needed
14241 # to get POSIX threads support; the API is always present and
14242 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
14243 # -pthread does define _REENTRANT, and while the Darwin headers
14244 # ignore this macro, third-party headers might not.)
14246 PTHREAD_CFLAGS="-pthread"
14247 PTHREAD_LIBS=
14249 ax_pthread_ok=yes
14251 # However, older versions of Clang make a point of warning the user
14252 # that, in an invocation where only linking and no compilation is
14253 # taking place, the -pthread option has no effect ("argument unused
14254 # during compilation"). They expect -pthread to be passed in only
14255 # when source code is being compiled.
14257 # Problem is, this is at odds with the way Automake and most other
14258 # C build frameworks function, which is that the same flags used in
14259 # compilation (CFLAGS) are also used in linking. Many systems
14260 # supported by AX_PTHREAD require exactly this for POSIX threads
14261 # support, and in fact it is often not straightforward to specify a
14262 # flag that is used only in the compilation phase and not in
14263 # linking. Such a scenario is extremely rare in practice.
14265 # Even though use of the -pthread flag in linking would only print
14266 # a warning, this can be a nuisance for well-run software projects
14267 # that build with -Werror. So if the active version of Clang has
14268 # this misfeature, we search for an option to squash it.
14270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
14271 $as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
14272 if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
14273 $as_echo_n "(cached) " >&6
14274 else
14275 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
14276 # Create an alternate version of $ac_link that compiles and
14277 # links in two steps (.c -> .o, .o -> exe) instead of one
14278 # (.c -> exe), because the warning occurs only in the second
14279 # step
14280 ax_pthread_save_ac_link="$ac_link"
14281 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
14282 ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
14283 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
14284 ax_pthread_save_CFLAGS="$CFLAGS"
14285 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
14286 if test "x$ax_pthread_try" = "xunknown"; then :
14287 break
14289 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
14290 ac_link="$ax_pthread_save_ac_link"
14291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14292 /* end confdefs.h. */
14293 int main(void){return 0;}
14294 _ACEOF
14295 if ac_fn_c_try_link "$LINENO"; then :
14296 ac_link="$ax_pthread_2step_ac_link"
14297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14298 /* end confdefs.h. */
14299 int main(void){return 0;}
14300 _ACEOF
14301 if ac_fn_c_try_link "$LINENO"; then :
14302 break
14304 rm -f core conftest.err conftest.$ac_objext \
14305 conftest$ac_exeext conftest.$ac_ext
14308 rm -f core conftest.err conftest.$ac_objext \
14309 conftest$ac_exeext conftest.$ac_ext
14310 done
14311 ac_link="$ax_pthread_save_ac_link"
14312 CFLAGS="$ax_pthread_save_CFLAGS"
14313 if test "x$ax_pthread_try" = "x"; then :
14314 ax_pthread_try=no
14316 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
14319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
14320 $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
14322 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
14323 no | unknown) ;;
14324 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
14325 esac
14327 fi # $ax_pthread_clang = yes
14329 if test "x$ax_pthread_ok" = "xno"; then
14330 for ax_pthread_try_flag in $ax_pthread_flags; do
14332 case $ax_pthread_try_flag in
14333 none)
14334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
14335 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
14338 -mt,pthread)
14339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
14340 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
14341 PTHREAD_CFLAGS="-mt"
14342 PTHREAD_LIBS="-lpthread"
14346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
14347 $as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
14348 PTHREAD_CFLAGS="$ax_pthread_try_flag"
14351 pthread-config)
14352 # Extract the first word of "pthread-config", so it can be a program name with args.
14353 set dummy pthread-config; ac_word=$2
14354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14355 $as_echo_n "checking for $ac_word... " >&6; }
14356 if ${ac_cv_prog_ax_pthread_config+:} false; then :
14357 $as_echo_n "(cached) " >&6
14358 else
14359 if test -n "$ax_pthread_config"; then
14360 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
14361 else
14362 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14363 for as_dir in $PATH
14365 IFS=$as_save_IFS
14366 test -z "$as_dir" && as_dir=.
14367 for ac_exec_ext in '' $ac_executable_extensions; do
14368 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14369 ac_cv_prog_ax_pthread_config="yes"
14370 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14371 break 2
14373 done
14374 done
14375 IFS=$as_save_IFS
14377 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
14380 ax_pthread_config=$ac_cv_prog_ax_pthread_config
14381 if test -n "$ax_pthread_config"; then
14382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
14383 $as_echo "$ax_pthread_config" >&6; }
14384 else
14385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14386 $as_echo "no" >&6; }
14390 if test "x$ax_pthread_config" = "xno"; then :
14391 continue
14393 PTHREAD_CFLAGS="`pthread-config --cflags`"
14394 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
14398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
14399 $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
14400 PTHREAD_LIBS="-l$ax_pthread_try_flag"
14402 esac
14404 ax_pthread_save_CFLAGS="$CFLAGS"
14405 ax_pthread_save_LIBS="$LIBS"
14406 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14407 LIBS="$PTHREAD_LIBS $LIBS"
14409 # Check for various functions. We must include pthread.h,
14410 # since some functions may be macros. (On the Sequent, we
14411 # need a special flag -Kthread to make this header compile.)
14412 # We check for pthread_join because it is in -lpthread on IRIX
14413 # while pthread_create is in libc. We check for pthread_attr_init
14414 # due to DEC craziness with -lpthreads. We check for
14415 # pthread_cleanup_push because it is one of the few pthread
14416 # functions on Solaris that doesn't have a non-functional libc stub.
14417 # We try pthread_create on general principles.
14419 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14420 /* end confdefs.h. */
14421 #include <pthread.h>
14422 # if $ax_pthread_check_cond
14423 # error "$ax_pthread_check_macro must be defined"
14424 # endif
14425 static void routine(void *a) { a = 0; }
14426 static void *start_routine(void *a) { return a; }
14428 main ()
14430 pthread_t th; pthread_attr_t attr;
14431 pthread_create(&th, 0, start_routine, 0);
14432 pthread_join(th, 0);
14433 pthread_attr_init(&attr);
14434 pthread_cleanup_push(routine, 0);
14435 pthread_cleanup_pop(0) /* ; */
14437 return 0;
14439 _ACEOF
14440 if ac_fn_c_try_link "$LINENO"; then :
14441 ax_pthread_ok=yes
14443 rm -f core conftest.err conftest.$ac_objext \
14444 conftest$ac_exeext conftest.$ac_ext
14446 CFLAGS="$ax_pthread_save_CFLAGS"
14447 LIBS="$ax_pthread_save_LIBS"
14449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
14450 $as_echo "$ax_pthread_ok" >&6; }
14451 if test "x$ax_pthread_ok" = "xyes"; then :
14452 break
14455 PTHREAD_LIBS=""
14456 PTHREAD_CFLAGS=""
14457 done
14460 # Various other checks:
14461 if test "x$ax_pthread_ok" = "xyes"; then
14462 ax_pthread_save_CFLAGS="$CFLAGS"
14463 ax_pthread_save_LIBS="$LIBS"
14464 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14465 LIBS="$PTHREAD_LIBS $LIBS"
14467 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
14468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
14469 $as_echo_n "checking for joinable pthread attribute... " >&6; }
14470 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
14471 $as_echo_n "(cached) " >&6
14472 else
14473 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
14474 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
14475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14476 /* end confdefs.h. */
14477 #include <pthread.h>
14479 main ()
14481 int attr = $ax_pthread_attr; return attr /* ; */
14483 return 0;
14485 _ACEOF
14486 if ac_fn_c_try_link "$LINENO"; then :
14487 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
14489 rm -f core conftest.err conftest.$ac_objext \
14490 conftest$ac_exeext conftest.$ac_ext
14491 done
14494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
14495 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
14496 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
14497 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
14498 test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
14500 cat >>confdefs.h <<_ACEOF
14501 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
14502 _ACEOF
14504 ax_pthread_joinable_attr_defined=yes
14508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
14509 $as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
14510 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
14511 $as_echo_n "(cached) " >&6
14512 else
14513 ax_cv_PTHREAD_SPECIAL_FLAGS=no
14514 case $host_os in
14515 solaris*)
14516 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
14518 esac
14521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
14522 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
14523 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
14524 test "x$ax_pthread_special_flags_added" != "xyes"; then :
14525 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
14526 ax_pthread_special_flags_added=yes
14529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
14530 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
14531 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
14532 $as_echo_n "(cached) " >&6
14533 else
14534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14535 /* end confdefs.h. */
14536 #include <pthread.h>
14538 main ()
14540 int i = PTHREAD_PRIO_INHERIT;
14542 return 0;
14544 _ACEOF
14545 if ac_fn_c_try_link "$LINENO"; then :
14546 ax_cv_PTHREAD_PRIO_INHERIT=yes
14547 else
14548 ax_cv_PTHREAD_PRIO_INHERIT=no
14550 rm -f core conftest.err conftest.$ac_objext \
14551 conftest$ac_exeext conftest.$ac_ext
14554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
14555 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
14556 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
14557 test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
14559 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
14561 ax_pthread_prio_inherit_defined=yes
14565 CFLAGS="$ax_pthread_save_CFLAGS"
14566 LIBS="$ax_pthread_save_LIBS"
14568 # More AIX lossage: compile with *_r variant
14569 if test "x$GCC" != "xyes"; then
14570 case $host_os in
14571 aix*)
14572 case "x/$CC" in #(
14573 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
14574 #handle absolute path differently from PATH based program lookup
14575 case "x$CC" in #(
14576 x/*) :
14577 if as_fn_executable_p ${CC}_r; then :
14578 PTHREAD_CC="${CC}_r"
14579 fi ;; #(
14580 *) :
14581 for ac_prog in ${CC}_r
14583 # Extract the first word of "$ac_prog", so it can be a program name with args.
14584 set dummy $ac_prog; ac_word=$2
14585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14586 $as_echo_n "checking for $ac_word... " >&6; }
14587 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
14588 $as_echo_n "(cached) " >&6
14589 else
14590 if test -n "$PTHREAD_CC"; then
14591 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
14592 else
14593 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14594 for as_dir in $PATH
14596 IFS=$as_save_IFS
14597 test -z "$as_dir" && as_dir=.
14598 for ac_exec_ext in '' $ac_executable_extensions; do
14599 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14600 ac_cv_prog_PTHREAD_CC="$ac_prog"
14601 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14602 break 2
14604 done
14605 done
14606 IFS=$as_save_IFS
14610 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
14611 if test -n "$PTHREAD_CC"; then
14612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
14613 $as_echo "$PTHREAD_CC" >&6; }
14614 else
14615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14616 $as_echo "no" >&6; }
14620 test -n "$PTHREAD_CC" && break
14621 done
14622 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
14624 esac ;; #(
14625 *) :
14627 esac
14629 esac
14633 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
14639 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
14640 if test "x$ax_pthread_ok" = "xyes"; then
14641 threads=yes
14643 else
14644 ax_pthread_ok=no
14645 threads=no
14647 ac_ext=cpp
14648 ac_cpp='$CXXCPP $CPPFLAGS'
14649 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14650 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14651 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14654 if test "$threads" = "yes"; then
14655 save_LIBS="$LIBS"
14656 LIBS="$PTHREAD_LIBS $LIBS"
14657 save_CXXFLAGS="$CXXFLAGS"
14658 CXXFLAGS="$PTHREAD_CFLAGS $save_CXXFLAGS"
14659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for std::thread" >&5
14660 $as_echo_n "checking for std::thread... " >&6; }
14661 if ${gdb_cv_cxx_std_thread+:} false; then :
14662 $as_echo_n "(cached) " >&6
14663 else
14664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14665 /* end confdefs.h. */
14666 #include <thread>
14667 void callback() { }
14669 main ()
14671 std::thread t(callback);
14673 return 0;
14675 _ACEOF
14676 if ac_fn_cxx_try_compile "$LINENO"; then :
14677 gdb_cv_cxx_std_thread=yes
14678 else
14679 gdb_cv_cxx_std_thread=no
14681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_cxx_std_thread" >&5
14684 $as_echo "$gdb_cv_cxx_std_thread" >&6; }
14686 # This check must be here, while LIBS includes any necessary
14687 # threading library.
14688 for ac_func in pthread_sigmask pthread_setname_np
14689 do :
14690 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14691 ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
14692 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14693 cat >>confdefs.h <<_ACEOF
14694 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14695 _ACEOF
14698 done
14701 LIBS="$save_LIBS"
14702 CXXFLAGS="$save_CXXFLAGS"
14704 if test "$gdb_cv_cxx_std_thread" = "yes"; then
14706 $as_echo "#define CXX_STD_THREAD 1" >>confdefs.h
14709 ac_ext=c
14710 ac_cpp='$CPP $CPPFLAGS'
14711 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14712 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14713 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
14717 $as_echo_n "checking for sigsetjmp... " >&6; }
14718 if ${gdb_cv_func_sigsetjmp+:} false; then :
14719 $as_echo_n "(cached) " >&6
14720 else
14721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14722 /* end confdefs.h. */
14723 #include <setjmp.h>
14725 main ()
14727 sigjmp_buf env;
14728 while (! sigsetjmp (env, 1))
14729 siglongjmp (env, 1);
14732 return 0;
14734 _ACEOF
14735 if ac_fn_c_try_compile "$LINENO"; then :
14736 gdb_cv_func_sigsetjmp=yes
14737 else
14738 gdb_cv_func_sigsetjmp=no
14741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
14745 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
14746 if test "$gdb_cv_func_sigsetjmp" = "yes"; then
14748 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
14753 # Check whether --with-intel_pt was given.
14754 if test "${with_intel_pt+set}" = set; then :
14755 withval=$with_intel_pt;
14756 else
14757 with_intel_pt=auto
14760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
14761 $as_echo_n "checking whether to use intel pt... " >&6; }
14762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
14763 $as_echo "$with_intel_pt" >&6; }
14765 if test "${with_intel_pt}" = no; then
14766 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
14767 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
14768 HAVE_LIBIPT=no
14769 else
14770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14771 /* end confdefs.h. */
14773 #include <linux/perf_event.h>
14774 #ifndef PERF_ATTR_SIZE_VER5
14775 # error
14776 #endif
14778 _ACEOF
14779 if ac_fn_c_try_cpp "$LINENO"; then :
14780 perf_event=yes
14781 else
14782 perf_event=no
14784 rm -f conftest.err conftest.i conftest.$ac_ext
14785 if test "$perf_event" != yes; then
14786 if test "$with_intel_pt" = yes; then
14787 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
14788 else
14789 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
14790 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
14802 use_additional=yes
14804 acl_save_prefix="$prefix"
14805 prefix="$acl_final_prefix"
14806 acl_save_exec_prefix="$exec_prefix"
14807 exec_prefix="$acl_final_exec_prefix"
14809 eval additional_includedir=\"$includedir\"
14810 eval additional_libdir=\"$libdir\"
14812 exec_prefix="$acl_save_exec_prefix"
14813 prefix="$acl_save_prefix"
14816 # Check whether --with-libipt-prefix was given.
14817 if test "${with_libipt_prefix+set}" = set; then :
14818 withval=$with_libipt_prefix;
14819 if test "X$withval" = "Xno"; then
14820 use_additional=no
14821 else
14822 if test "X$withval" = "X"; then
14824 acl_save_prefix="$prefix"
14825 prefix="$acl_final_prefix"
14826 acl_save_exec_prefix="$exec_prefix"
14827 exec_prefix="$acl_final_exec_prefix"
14829 eval additional_includedir=\"$includedir\"
14830 eval additional_libdir=\"$libdir\"
14832 exec_prefix="$acl_save_exec_prefix"
14833 prefix="$acl_save_prefix"
14835 else
14836 additional_includedir="$withval/include"
14837 additional_libdir="$withval/lib"
14844 # Check whether --with-libipt-type was given.
14845 if test "${with_libipt_type+set}" = set; then :
14846 withval=$with_libipt_type; with_libipt_type=$withval
14847 else
14848 with_libipt_type=auto
14851 lib_type=`eval echo \$with_libipt_type`
14853 LIBIPT=
14854 LTLIBIPT=
14855 INCIPT=
14856 rpathdirs=
14857 ltrpathdirs=
14858 names_already_handled=
14859 names_next_round='ipt '
14860 while test -n "$names_next_round"; do
14861 names_this_round="$names_next_round"
14862 names_next_round=
14863 for name in $names_this_round; do
14864 already_handled=
14865 for n in $names_already_handled; do
14866 if test "$n" = "$name"; then
14867 already_handled=yes
14868 break
14870 done
14871 if test -z "$already_handled"; then
14872 names_already_handled="$names_already_handled $name"
14873 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
14874 eval value=\"\$HAVE_LIB$uppername\"
14875 if test -n "$value"; then
14876 if test "$value" = yes; then
14877 eval value=\"\$LIB$uppername\"
14878 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
14879 eval value=\"\$LTLIB$uppername\"
14880 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
14881 else
14884 else
14885 found_dir=
14886 found_la=
14887 found_so=
14888 found_a=
14889 if test $use_additional = yes; then
14890 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
14891 found_dir="$additional_libdir"
14892 found_so="$additional_libdir/lib$name.$shlibext"
14893 if test -f "$additional_libdir/lib$name.la"; then
14894 found_la="$additional_libdir/lib$name.la"
14896 elif test x$lib_type != xshared; then
14897 if test -f "$additional_libdir/lib$name.$libext"; then
14898 found_dir="$additional_libdir"
14899 found_a="$additional_libdir/lib$name.$libext"
14900 if test -f "$additional_libdir/lib$name.la"; then
14901 found_la="$additional_libdir/lib$name.la"
14906 if test "X$found_dir" = "X"; then
14907 for x in $LDFLAGS $LTLIBIPT; do
14909 acl_save_prefix="$prefix"
14910 prefix="$acl_final_prefix"
14911 acl_save_exec_prefix="$exec_prefix"
14912 exec_prefix="$acl_final_exec_prefix"
14913 eval x=\"$x\"
14914 exec_prefix="$acl_save_exec_prefix"
14915 prefix="$acl_save_prefix"
14917 case "$x" in
14918 -L*)
14919 dir=`echo "X$x" | sed -e 's/^X-L//'`
14920 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
14921 found_dir="$dir"
14922 found_so="$dir/lib$name.$shlibext"
14923 if test -f "$dir/lib$name.la"; then
14924 found_la="$dir/lib$name.la"
14926 elif test x$lib_type != xshared; then
14927 if test -f "$dir/lib$name.$libext"; then
14928 found_dir="$dir"
14929 found_a="$dir/lib$name.$libext"
14930 if test -f "$dir/lib$name.la"; then
14931 found_la="$dir/lib$name.la"
14936 esac
14937 if test "X$found_dir" != "X"; then
14938 break
14940 done
14942 if test "X$found_dir" != "X"; then
14943 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
14944 if test "X$found_so" != "X"; then
14945 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
14946 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
14947 else
14948 haveit=
14949 for x in $ltrpathdirs; do
14950 if test "X$x" = "X$found_dir"; then
14951 haveit=yes
14952 break
14954 done
14955 if test -z "$haveit"; then
14956 ltrpathdirs="$ltrpathdirs $found_dir"
14958 if test "$hardcode_direct" = yes; then
14959 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
14960 else
14961 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
14962 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
14963 haveit=
14964 for x in $rpathdirs; do
14965 if test "X$x" = "X$found_dir"; then
14966 haveit=yes
14967 break
14969 done
14970 if test -z "$haveit"; then
14971 rpathdirs="$rpathdirs $found_dir"
14973 else
14974 haveit=
14975 for x in $LDFLAGS $LIBIPT; do
14977 acl_save_prefix="$prefix"
14978 prefix="$acl_final_prefix"
14979 acl_save_exec_prefix="$exec_prefix"
14980 exec_prefix="$acl_final_exec_prefix"
14981 eval x=\"$x\"
14982 exec_prefix="$acl_save_exec_prefix"
14983 prefix="$acl_save_prefix"
14985 if test "X$x" = "X-L$found_dir"; then
14986 haveit=yes
14987 break
14989 done
14990 if test -z "$haveit"; then
14991 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
14993 if test "$hardcode_minus_L" != no; then
14994 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
14995 else
14996 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
15001 else
15002 if test "X$found_a" != "X"; then
15003 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
15004 else
15005 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
15008 additional_includedir=
15009 case "$found_dir" in
15010 */lib | */lib/)
15011 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
15012 additional_includedir="$basedir/include"
15014 esac
15015 if test "X$additional_includedir" != "X"; then
15016 if test "X$additional_includedir" != "X/usr/include"; then
15017 haveit=
15018 if test "X$additional_includedir" = "X/usr/local/include"; then
15019 if test -n "$GCC"; then
15020 case $host_os in
15021 linux*) haveit=yes;;
15022 esac
15025 if test -z "$haveit"; then
15026 for x in $CPPFLAGS $INCIPT; do
15028 acl_save_prefix="$prefix"
15029 prefix="$acl_final_prefix"
15030 acl_save_exec_prefix="$exec_prefix"
15031 exec_prefix="$acl_final_exec_prefix"
15032 eval x=\"$x\"
15033 exec_prefix="$acl_save_exec_prefix"
15034 prefix="$acl_save_prefix"
15036 if test "X$x" = "X-I$additional_includedir"; then
15037 haveit=yes
15038 break
15040 done
15041 if test -z "$haveit"; then
15042 if test -d "$additional_includedir"; then
15043 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
15049 if test -n "$found_la"; then
15050 save_libdir="$libdir"
15051 case "$found_la" in
15052 */* | *\\*) . "$found_la" ;;
15053 *) . "./$found_la" ;;
15054 esac
15055 libdir="$save_libdir"
15056 for dep in $dependency_libs; do
15057 case "$dep" in
15058 -L*)
15059 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
15060 if test "X$additional_libdir" != "X/usr/lib"; then
15061 haveit=
15062 if test "X$additional_libdir" = "X/usr/local/lib"; then
15063 if test -n "$GCC"; then
15064 case $host_os in
15065 linux*) haveit=yes;;
15066 esac
15069 if test -z "$haveit"; then
15070 haveit=
15071 for x in $LDFLAGS $LIBIPT; do
15073 acl_save_prefix="$prefix"
15074 prefix="$acl_final_prefix"
15075 acl_save_exec_prefix="$exec_prefix"
15076 exec_prefix="$acl_final_exec_prefix"
15077 eval x=\"$x\"
15078 exec_prefix="$acl_save_exec_prefix"
15079 prefix="$acl_save_prefix"
15081 if test "X$x" = "X-L$additional_libdir"; then
15082 haveit=yes
15083 break
15085 done
15086 if test -z "$haveit"; then
15087 if test -d "$additional_libdir"; then
15088 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
15091 haveit=
15092 for x in $LDFLAGS $LTLIBIPT; do
15094 acl_save_prefix="$prefix"
15095 prefix="$acl_final_prefix"
15096 acl_save_exec_prefix="$exec_prefix"
15097 exec_prefix="$acl_final_exec_prefix"
15098 eval x=\"$x\"
15099 exec_prefix="$acl_save_exec_prefix"
15100 prefix="$acl_save_prefix"
15102 if test "X$x" = "X-L$additional_libdir"; then
15103 haveit=yes
15104 break
15106 done
15107 if test -z "$haveit"; then
15108 if test -d "$additional_libdir"; then
15109 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
15115 -R*)
15116 dir=`echo "X$dep" | sed -e 's/^X-R//'`
15117 if test "$enable_rpath" != no; then
15118 haveit=
15119 for x in $rpathdirs; do
15120 if test "X$x" = "X$dir"; then
15121 haveit=yes
15122 break
15124 done
15125 if test -z "$haveit"; then
15126 rpathdirs="$rpathdirs $dir"
15128 haveit=
15129 for x in $ltrpathdirs; do
15130 if test "X$x" = "X$dir"; then
15131 haveit=yes
15132 break
15134 done
15135 if test -z "$haveit"; then
15136 ltrpathdirs="$ltrpathdirs $dir"
15140 -l*)
15141 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
15143 *.la)
15144 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
15147 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
15148 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
15150 esac
15151 done
15153 else
15154 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
15155 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
15156 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
15157 else
15158 LIBIPT="${LIBIPT}${LIBIPT:+ }-l:lib$name.$libext"
15159 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l:lib$name.$libext"
15164 done
15165 done
15166 if test "X$rpathdirs" != "X"; then
15167 if test -n "$hardcode_libdir_separator"; then
15168 alldirs=
15169 for found_dir in $rpathdirs; do
15170 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
15171 done
15172 acl_save_libdir="$libdir"
15173 libdir="$alldirs"
15174 eval flag=\"$hardcode_libdir_flag_spec\"
15175 libdir="$acl_save_libdir"
15176 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
15177 else
15178 for found_dir in $rpathdirs; do
15179 acl_save_libdir="$libdir"
15180 libdir="$found_dir"
15181 eval flag=\"$hardcode_libdir_flag_spec\"
15182 libdir="$acl_save_libdir"
15183 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
15184 done
15187 if test "X$ltrpathdirs" != "X"; then
15188 for found_dir in $ltrpathdirs; do
15189 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
15190 done
15194 ac_save_CPPFLAGS="$CPPFLAGS"
15196 for element in $INCIPT; do
15197 haveit=
15198 for x in $CPPFLAGS; do
15200 acl_save_prefix="$prefix"
15201 prefix="$acl_final_prefix"
15202 acl_save_exec_prefix="$exec_prefix"
15203 exec_prefix="$acl_final_exec_prefix"
15204 eval x=\"$x\"
15205 exec_prefix="$acl_save_exec_prefix"
15206 prefix="$acl_save_prefix"
15208 if test "X$x" = "X$element"; then
15209 haveit=yes
15210 break
15212 done
15213 if test -z "$haveit"; then
15214 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
15216 done
15219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
15220 $as_echo_n "checking for libipt... " >&6; }
15221 if ${ac_cv_libipt+:} false; then :
15222 $as_echo_n "(cached) " >&6
15223 else
15225 ac_save_LIBS="$LIBS"
15226 LIBS="$LIBS $LIBIPT"
15227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15228 /* end confdefs.h. */
15229 #include "intel-pt.h"
15231 main ()
15233 pt_insn_alloc_decoder (0);
15235 return 0;
15237 _ACEOF
15238 if ac_fn_c_try_link "$LINENO"; then :
15239 ac_cv_libipt=yes
15240 else
15241 ac_cv_libipt=no
15243 rm -f core conftest.err conftest.$ac_objext \
15244 conftest$ac_exeext conftest.$ac_ext
15245 LIBS="$ac_save_LIBS"
15248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
15249 $as_echo "$ac_cv_libipt" >&6; }
15250 if test "$ac_cv_libipt" = yes; then
15251 HAVE_LIBIPT=yes
15253 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
15255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
15256 $as_echo_n "checking how to link with libipt... " >&6; }
15257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
15258 $as_echo "$LIBIPT" >&6; }
15259 else
15260 HAVE_LIBIPT=no
15261 CPPFLAGS="$ac_save_CPPFLAGS"
15262 LIBIPT=
15263 LTLIBIPT=
15271 if test "$HAVE_LIBIPT" != yes; then
15272 if test "$with_intel_pt" = yes; then
15273 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
15274 else
15275 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
15276 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
15278 else
15279 save_LIBS=$LIBS
15280 LIBS="$LIBS $LIBIPT"
15281 for ac_func in pt_insn_event
15282 do :
15283 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
15284 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
15285 cat >>confdefs.h <<_ACEOF
15286 #define HAVE_PT_INSN_EVENT 1
15287 _ACEOF
15290 done
15292 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
15294 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
15296 cat >>confdefs.h <<_ACEOF
15297 #define HAVE_STRUCT_PT_INSN_ENABLED 1
15298 _ACEOF
15302 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
15304 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
15306 cat >>confdefs.h <<_ACEOF
15307 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
15308 _ACEOF
15313 LIBS=$save_LIBS
15318 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15320 for ac_header in sys/procfs.h
15321 do :
15322 ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
15323 if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
15324 cat >>confdefs.h <<_ACEOF
15325 #define HAVE_SYS_PROCFS_H 1
15326 _ACEOF
15330 done
15332 if test "$ac_cv_header_sys_procfs_h" = yes; then
15334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
15335 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
15336 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
15337 $as_echo_n "(cached) " >&6
15338 else
15339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15340 /* end confdefs.h. */
15342 #define _SYSCALL32
15343 #include <sys/procfs.h>
15345 main ()
15347 gregset_t avar
15349 return 0;
15351 _ACEOF
15352 if ac_fn_c_try_compile "$LINENO"; then :
15353 bfd_cv_have_sys_procfs_type_gregset_t=yes
15354 else
15355 bfd_cv_have_sys_procfs_type_gregset_t=no
15358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15361 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
15363 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
15366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
15367 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
15370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
15371 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
15372 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
15373 $as_echo_n "(cached) " >&6
15374 else
15375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15376 /* end confdefs.h. */
15378 #define _SYSCALL32
15379 #include <sys/procfs.h>
15381 main ()
15383 fpregset_t avar
15385 return 0;
15387 _ACEOF
15388 if ac_fn_c_try_compile "$LINENO"; then :
15389 bfd_cv_have_sys_procfs_type_fpregset_t=yes
15390 else
15391 bfd_cv_have_sys_procfs_type_fpregset_t=no
15394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15397 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
15399 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
15402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
15403 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
15406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
15407 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
15408 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
15409 $as_echo_n "(cached) " >&6
15410 else
15411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15412 /* end confdefs.h. */
15414 #define _SYSCALL32
15415 #include <sys/procfs.h>
15417 main ()
15419 prgregset_t avar
15421 return 0;
15423 _ACEOF
15424 if ac_fn_c_try_compile "$LINENO"; then :
15425 bfd_cv_have_sys_procfs_type_prgregset_t=yes
15426 else
15427 bfd_cv_have_sys_procfs_type_prgregset_t=no
15430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15433 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
15435 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
15438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
15439 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
15442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
15443 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
15444 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
15445 $as_echo_n "(cached) " >&6
15446 else
15447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15448 /* end confdefs.h. */
15450 #define _SYSCALL32
15451 #include <sys/procfs.h>
15453 main ()
15455 prfpregset_t avar
15457 return 0;
15459 _ACEOF
15460 if ac_fn_c_try_compile "$LINENO"; then :
15461 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
15462 else
15463 bfd_cv_have_sys_procfs_type_prfpregset_t=no
15466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15469 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
15471 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
15474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
15475 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
15478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
15479 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
15480 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
15481 $as_echo_n "(cached) " >&6
15482 else
15483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15484 /* end confdefs.h. */
15486 #define _SYSCALL32
15487 #include <sys/procfs.h>
15489 main ()
15491 prgregset32_t avar
15493 return 0;
15495 _ACEOF
15496 if ac_fn_c_try_compile "$LINENO"; then :
15497 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
15498 else
15499 bfd_cv_have_sys_procfs_type_prgregset32_t=no
15502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15505 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
15507 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
15510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
15511 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
15514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
15515 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
15516 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
15517 $as_echo_n "(cached) " >&6
15518 else
15519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15520 /* end confdefs.h. */
15522 #define _SYSCALL32
15523 #include <sys/procfs.h>
15525 main ()
15527 lwpid_t avar
15529 return 0;
15531 _ACEOF
15532 if ac_fn_c_try_compile "$LINENO"; then :
15533 bfd_cv_have_sys_procfs_type_lwpid_t=yes
15534 else
15535 bfd_cv_have_sys_procfs_type_lwpid_t=no
15538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15541 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
15543 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
15546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
15547 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
15550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
15551 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
15552 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
15553 $as_echo_n "(cached) " >&6
15554 else
15555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15556 /* end confdefs.h. */
15558 #define _SYSCALL32
15559 #include <sys/procfs.h>
15561 main ()
15563 psaddr_t avar
15565 return 0;
15567 _ACEOF
15568 if ac_fn_c_try_compile "$LINENO"; then :
15569 bfd_cv_have_sys_procfs_type_psaddr_t=yes
15570 else
15571 bfd_cv_have_sys_procfs_type_psaddr_t=no
15574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15577 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
15579 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
15582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
15583 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
15586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
15587 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
15588 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
15589 $as_echo_n "(cached) " >&6
15590 else
15591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15592 /* end confdefs.h. */
15594 #define _SYSCALL32
15595 #include <sys/procfs.h>
15597 main ()
15599 elf_fpregset_t avar
15601 return 0;
15603 _ACEOF
15604 if ac_fn_c_try_compile "$LINENO"; then :
15605 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
15606 else
15607 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
15610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15613 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
15615 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
15618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
15619 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
15624 # Check the return and argument types of ptrace.
15627 for ac_header in sys/ptrace.h ptrace.h
15628 do :
15629 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15630 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
15631 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
15632 cat >>confdefs.h <<_ACEOF
15633 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15634 _ACEOF
15638 done
15641 gdb_ptrace_headers='
15642 #include <sys/types.h>
15643 #if HAVE_SYS_PTRACE_H
15644 # include <sys/ptrace.h>
15645 #endif
15646 #if HAVE_UNISTD_H
15647 # include <unistd.h>
15648 #endif
15651 # Check return type. Varargs (used on GNU/Linux) conflict with the
15652 # empty argument list, so check for that explicitly.
15653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
15654 $as_echo_n "checking return type of ptrace... " >&6; }
15655 if ${gdb_cv_func_ptrace_ret+:} false; then :
15656 $as_echo_n "(cached) " >&6
15657 else
15658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15659 /* end confdefs.h. */
15660  $gdb_ptrace_headers
15662 main ()
15664 extern long ptrace (enum __ptrace_request, ...);
15667 return 0;
15669 _ACEOF
15670 if ac_fn_c_try_compile "$LINENO"; then :
15671 gdb_cv_func_ptrace_ret='long'
15672 else
15673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15674 /* end confdefs.h. */
15675 $gdb_ptrace_headers
15677 main ()
15679 extern int ptrace ();
15682 return 0;
15684 _ACEOF
15685 if ac_fn_c_try_compile "$LINENO"; then :
15686 gdb_cv_func_ptrace_ret='int'
15687 else
15688 gdb_cv_func_ptrace_ret='long'
15691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
15698 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
15701 cat >>confdefs.h <<_ACEOF
15702 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
15703 _ACEOF
15706 # Check argument types.
15707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
15708 $as_echo_n "checking types of arguments for ptrace... " >&6; }
15709 if ${gdb_cv_func_ptrace_args+:} false; then :
15710 $as_echo_n "(cached) " >&6
15711 else
15712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15713 /* end confdefs.h. */
15714 $gdb_ptrace_headers
15716 main ()
15718 extern long ptrace (enum __ptrace_request, ...);
15721 return 0;
15723 _ACEOF
15724 if ac_fn_c_try_compile "$LINENO"; then :
15725 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
15726 else
15727 for gdb_arg1 in 'int' 'long'; do
15728 for gdb_arg2 in 'pid_t' 'int' 'long'; do
15729 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
15730 for gdb_arg4 in 'int' 'long' 'void *'; do
15731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15732 /* end confdefs.h. */
15733 $gdb_ptrace_headers
15735 main ()
15737 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
15740 return 0;
15742 _ACEOF
15743 if ac_fn_c_try_compile "$LINENO"; then :
15744 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
15745 break 4;
15748 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15750 for gdb_arg5 in 'int *' 'int' 'long'; do
15751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15752 /* end confdefs.h. */
15753 $gdb_ptrace_headers
15755 main ()
15757 extern $gdb_cv_func_ptrace_ret ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
15760 return 0;
15762 _ACEOF
15763 if ac_fn_c_try_compile "$LINENO"; then :
15764 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
15765 break 5;
15768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15769 done
15770 done
15771 done
15772 done
15773 done
15774 # Provide a safe default value.
15775 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
15778 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
15782 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
15784 ac_save_IFS=$IFS; IFS=','
15785 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
15786 IFS=$ac_save_IFS
15787 shift
15789 cat >>confdefs.h <<_ACEOF
15790 #define PTRACE_TYPE_ARG1 $1
15791 _ACEOF
15794 cat >>confdefs.h <<_ACEOF
15795 #define PTRACE_TYPE_ARG3 $3
15796 _ACEOF
15799 cat >>confdefs.h <<_ACEOF
15800 #define PTRACE_TYPE_ARG4 $4
15801 _ACEOF
15803 if test -n "$5"; then
15805 cat >>confdefs.h <<_ACEOF
15806 #define PTRACE_TYPE_ARG5 $5
15807 _ACEOF
15812 if test "$cross_compiling" = no; then
15813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
15814 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
15815 if ${ac_cv_func_setpgrp_void+:} false; then :
15816 $as_echo_n "(cached) " >&6
15817 else
15818 if test "$cross_compiling" = yes; then :
15819 as_fn_error $? "cannot check setpgrp when cross compiling" "$LINENO" 5
15820 else
15821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15822 /* end confdefs.h. */
15823 $ac_includes_default
15825 main ()
15827 /* If this system has a BSD-style setpgrp which takes arguments,
15828 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
15829 exit successfully. */
15830 return setpgrp (1,1) != -1;
15832 return 0;
15834 _ACEOF
15835 if ac_fn_c_try_run "$LINENO"; then :
15836 ac_cv_func_setpgrp_void=no
15837 else
15838 ac_cv_func_setpgrp_void=yes
15840 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15841 conftest.$ac_objext conftest.beam conftest.$ac_ext
15845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
15846 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
15847 if test $ac_cv_func_setpgrp_void = yes; then
15849 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
15853 else
15854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
15855 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
15856 if ${ac_cv_func_setpgrp_void+:} false; then :
15857 $as_echo_n "(cached) " >&6
15858 else
15859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15860 /* end confdefs.h. */
15861 #include <unistd.h>
15863 main ()
15865 if (setpgrp(1,1) == -1)
15866 exit (0);
15867 else
15868 exit (1);
15871 return 0;
15873 _ACEOF
15874 if ac_fn_c_try_compile "$LINENO"; then :
15875 ac_cv_func_setpgrp_void=no
15876 else
15877 ac_cv_func_setpgrp_void=yes
15880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
15884 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
15885 if test "$ac_cv_func_setpgrp_void" = yes; then
15886 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
15891 # Assume we'll default to using the included libiberty regex.
15892 gdb_use_included_regex=yes
15894 # However, if the system regex is GNU regex, then default to *not*
15895 # using the included regex.
15896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
15897 $as_echo_n "checking for GNU regex... " >&6; }
15898 if ${gdb_cv_have_gnu_regex+:} false; then :
15899 $as_echo_n "(cached) " >&6
15900 else
15901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15902 /* end confdefs.h. */
15903 #include <gnu-versions.h>
15905 main ()
15907 #define REGEX_INTERFACE_VERSION 1
15908 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
15909 # error "Version mismatch"
15910 #endif
15913 return 0;
15915 _ACEOF
15916 if ac_fn_c_try_compile "$LINENO"; then :
15917 gdb_cv_have_gnu_regex=yes
15918 else
15919 gdb_cv_have_gnu_regex=no
15922 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
15926 $as_echo "$gdb_cv_have_gnu_regex" >&6; }
15927 if test "$gdb_cv_have_gnu_regex" = yes; then
15928 gdb_use_included_regex=no
15932 # Check whether --with-included-regex was given.
15933 if test "${with_included_regex+set}" = set; then :
15934 withval=$with_included_regex; gdb_with_regex=$withval
15935 else
15936 gdb_with_regex=$gdb_use_included_regex
15939 if test "$gdb_with_regex" = yes; then
15941 $as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
15945 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
15946 ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
15947 #include <sys/proc.h>
15950 if test "x$ac_cv_member_struct_thread_td_pcb" = xyes; then :
15952 cat >>confdefs.h <<_ACEOF
15953 #define HAVE_STRUCT_THREAD_TD_PCB 1
15954 _ACEOF
15960 # See if <sys/lwp.h> defines `struct lwp`.
15961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
15962 $as_echo_n "checking for struct lwp... " >&6; }
15963 if ${gdb_cv_struct_lwp+:} false; then :
15964 $as_echo_n "(cached) " >&6
15965 else
15966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15967 /* end confdefs.h. */
15968 #include <sys/param.h>
15969 #define _KMEMUSER
15970 #include <sys/lwp.h>
15972 main ()
15974 struct lwp l;
15977 return 0;
15979 _ACEOF
15980 if ac_fn_c_try_compile "$LINENO"; then :
15981 gdb_cv_struct_lwp=yes
15982 else
15983 gdb_cv_struct_lwp=no
15986 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
15990 $as_echo "$gdb_cv_struct_lwp" >&6; }
15991 if test "$gdb_cv_struct_lwp" = yes; then
15993 $as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
15997 # See if <machine/reg.h> degines `struct reg'.
15998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
15999 $as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
16000 if ${gdb_cv_struct_reg+:} false; then :
16001 $as_echo_n "(cached) " >&6
16002 else
16003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16004 /* end confdefs.h. */
16005 #include <sys/types.h>
16006 #include <machine/reg.h>
16008 main ()
16010 struct reg r;
16013 return 0;
16015 _ACEOF
16016 if ac_fn_c_try_compile "$LINENO"; then :
16017 gdb_cv_struct_reg=yes
16018 else
16019 gdb_cv_struct_reg=no
16022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
16026 $as_echo "$gdb_cv_struct_reg" >&6; }
16027 if test "$gdb_cv_struct_reg" = yes; then
16029 $as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
16033 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
16034 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
16035 ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <sys/types.h>
16036 #include <machine/reg.h>
16038 if test "x$ac_cv_member_struct_reg_r_fs" = xyes; then :
16040 cat >>confdefs.h <<_ACEOF
16041 #define HAVE_STRUCT_REG_R_FS 1
16042 _ACEOF
16046 ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <sys/types.h>
16047 #include <machine/reg.h>
16049 if test "x$ac_cv_member_struct_reg_r_gs" = xyes; then :
16051 cat >>confdefs.h <<_ACEOF
16052 #define HAVE_STRUCT_REG_R_GS 1
16053 _ACEOF
16059 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
16060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
16061 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
16062 if ${gdb_cv_have_ptrace_getregs+:} false; then :
16063 $as_echo_n "(cached) " >&6
16064 else
16065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16066 /* end confdefs.h. */
16067 #include <sys/ptrace.h>
16069 main ()
16071 PTRACE_GETREGS;
16073 return 0;
16075 _ACEOF
16076 if ac_fn_c_try_compile "$LINENO"; then :
16077 gdb_cv_have_ptrace_getregs=yes
16078 else
16079 gdb_cv_have_ptrace_getregs=no
16082 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
16087 $as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
16088 if test "$gdb_cv_have_ptrace_getregs" = yes; then
16090 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
16094 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
16095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
16096 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
16097 if ${gdb_cv_have_ptrace_getfpxregs+:} false; then :
16098 $as_echo_n "(cached) " >&6
16099 else
16100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16101 /* end confdefs.h. */
16102 #include <sys/ptrace.h>
16104 main ()
16106 PTRACE_GETFPXREGS;
16108 return 0;
16110 _ACEOF
16111 if ac_fn_c_try_compile "$LINENO"; then :
16112 gdb_cv_have_ptrace_getfpxregs=yes
16113 else
16114 gdb_cv_have_ptrace_getfpxregs=no
16117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
16122 $as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
16123 if test "$gdb_cv_have_ptrace_getfpxregs" = yes; then
16125 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
16129 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
16130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
16131 $as_echo_n "checking for PT_GETDBREGS... " >&6; }
16132 if ${gdb_cv_have_pt_getdbregs+:} false; then :
16133 $as_echo_n "(cached) " >&6
16134 else
16135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16136 /* end confdefs.h. */
16137 #include <sys/types.h>
16138 #include <sys/ptrace.h>
16140 main ()
16142 PT_GETDBREGS;
16145 return 0;
16147 _ACEOF
16148 if ac_fn_c_try_compile "$LINENO"; then :
16149 gdb_cv_have_pt_getdbregs=yes
16150 else
16151 gdb_cv_have_pt_getdbregs=no
16154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
16159 $as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
16160 if test "$gdb_cv_have_pt_getdbregs" = yes; then
16162 $as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
16166 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
16167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
16168 $as_echo_n "checking for PT_GETXMMREGS... " >&6; }
16169 if ${gdb_cv_have_pt_getxmmregs+:} false; then :
16170 $as_echo_n "(cached) " >&6
16171 else
16172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16173 /* end confdefs.h. */
16174 #include <sys/types.h>
16175 #include <sys/ptrace.h>
16177 main ()
16179 PT_GETXMMREGS;
16182 return 0;
16184 _ACEOF
16185 if ac_fn_c_try_compile "$LINENO"; then :
16186 gdb_cv_have_pt_getxmmregs=yes
16187 else
16188 gdb_cv_have_pt_getxmmregs=no
16191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
16196 $as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
16197 if test "$gdb_cv_have_pt_getxmmregs" = yes; then
16199 $as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
16203 # See if <sys/ptrace.h> supports LWP names on FreeBSD
16204 # Older FreeBSD versions don't have the pl_tdname member of
16205 # `struct ptrace_lwpinfo'.
16206 ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_tdname" "ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" "#include <sys/ptrace.h>
16208 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" = xyes; then :
16210 cat >>confdefs.h <<_ACEOF
16211 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_TDNAME 1
16212 _ACEOF
16218 # See if <sys/ptrace.h> supports syscall fields on FreeBSD. The
16219 # pl_syscall_code member of `struct ptrace_lwpinfo' was added in
16220 # FreeBSD 10.3.
16221 ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_syscall_code" "ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" "#include <sys/ptrace.h>
16223 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" = xyes; then :
16225 cat >>confdefs.h <<_ACEOF
16226 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_SYSCALL_CODE 1
16227 _ACEOF
16233 # Check if the compiler supports the `long long' type.
16235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
16236 $as_echo_n "checking for long long support in compiler... " >&6; }
16237 if ${gdb_cv_c_long_long+:} false; then :
16238 $as_echo_n "(cached) " >&6
16239 else
16240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16241 /* end confdefs.h. */
16242 extern long long foo;
16244 main ()
16246 switch (foo & 2) { case 0: return 1; }
16248 return 0;
16250 _ACEOF
16251 if ac_fn_c_try_compile "$LINENO"; then :
16252 gdb_cv_c_long_long=yes
16253 else
16254 gdb_cv_c_long_long=no
16256 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
16259 $as_echo "$gdb_cv_c_long_long" >&6; }
16260 if test "$gdb_cv_c_long_long" != yes; then
16261 # libdecnumber requires long long.
16262 as_fn_error $? "Compiler must support long long for GDB." "$LINENO" 5
16265 # Check if the compiler and runtime support printing long longs.
16267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
16268 $as_echo_n "checking for long long support in printf... " >&6; }
16269 if ${gdb_cv_printf_has_long_long+:} false; then :
16270 $as_echo_n "(cached) " >&6
16271 else
16272 if test "$cross_compiling" = yes; then :
16273 gdb_cv_printf_has_long_long=no
16274 else
16275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16276 /* end confdefs.h. */
16277 $ac_includes_default
16279 main ()
16281 char buf[32];
16282 long long l = 0;
16283 l = (l << 16) + 0x0123;
16284 l = (l << 16) + 0x4567;
16285 l = (l << 16) + 0x89ab;
16286 l = (l << 16) + 0xcdef;
16287 sprintf (buf, "0x%016llx", l);
16288 return (strcmp ("0x0123456789abcdef", buf));
16290 return 0;
16292 _ACEOF
16293 if ac_fn_c_try_run "$LINENO"; then :
16294 gdb_cv_printf_has_long_long=yes
16295 else
16296 gdb_cv_printf_has_long_long=no
16298 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16299 conftest.$ac_objext conftest.beam conftest.$ac_ext
16303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
16304 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
16305 if test "$gdb_cv_printf_has_long_long" = yes; then
16307 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
16311 # Check if the compiler and runtime support printing decfloats.
16313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
16314 $as_echo_n "checking for decfloat support in printf... " >&6; }
16315 if ${gdb_cv_printf_has_decfloat+:} false; then :
16316 $as_echo_n "(cached) " >&6
16317 else
16318 if test "$cross_compiling" = yes; then :
16319 gdb_cv_printf_has_decfloat=no
16320 else
16321 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16322 /* end confdefs.h. */
16323 $ac_includes_default
16325 main ()
16327 char buf[64];
16328 _Decimal32 d32 = 1.2345df;
16329 _Decimal64 d64 = 1.2345dd;
16330 _Decimal128 d128 = 1.2345dl;
16331 sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
16332 return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
16334 return 0;
16336 _ACEOF
16337 if ac_fn_c_try_run "$LINENO"; then :
16338 gdb_cv_printf_has_decfloat=yes
16339 else
16340 gdb_cv_printf_has_decfloat=no
16342 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16343 conftest.$ac_objext conftest.beam conftest.$ac_ext
16347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
16348 $as_echo "$gdb_cv_printf_has_decfloat" >&6; }
16349 if test "$gdb_cv_printf_has_decfloat" = yes; then
16351 $as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
16355 # Check if the compiler supports the `long double' type. We can't use
16356 # AC_C_LONG_DOUBLE because that one does additional checks on the
16357 # constants defined in <float.h> that fail on some systems,
16358 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
16360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
16361 $as_echo_n "checking for long double support in compiler... " >&6; }
16362 if ${gdb_cv_c_long_double+:} false; then :
16363 $as_echo_n "(cached) " >&6
16364 else
16365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16366 /* end confdefs.h. */
16367 long double foo;
16368 _ACEOF
16369 if ac_fn_c_try_compile "$LINENO"; then :
16370 gdb_cv_c_long_double=yes
16371 else
16372 gdb_cv_c_long_double=no
16374 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
16377 $as_echo "$gdb_cv_c_long_double" >&6; }
16378 if test "$gdb_cv_c_long_double" = yes; then
16380 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
16384 # Check if the compiler and runtime support printing long doubles.
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
16387 $as_echo_n "checking for long double support in printf... " >&6; }
16388 if ${gdb_cv_printf_has_long_double+:} false; then :
16389 $as_echo_n "(cached) " >&6
16390 else
16391 if test "$cross_compiling" = yes; then :
16392 gdb_cv_printf_has_long_double=no
16393 else
16394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16395 /* end confdefs.h. */
16396 $ac_includes_default
16398 main ()
16400 char buf[16];
16401 long double f = 3.141592653;
16402 sprintf (buf, "%Lg", f);
16403 return (strncmp ("3.14159", buf, 7));
16405 return 0;
16407 _ACEOF
16408 if ac_fn_c_try_run "$LINENO"; then :
16409 gdb_cv_printf_has_long_double=yes
16410 else
16411 gdb_cv_printf_has_long_double=no
16413 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16414 conftest.$ac_objext conftest.beam conftest.$ac_ext
16418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
16419 $as_echo "$gdb_cv_printf_has_long_double" >&6; }
16420 if test "$gdb_cv_printf_has_long_double" = yes; then
16422 $as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
16426 # Check if the compiler and runtime support scanning long doubles.
16428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
16429 $as_echo_n "checking for long double support in scanf... " >&6; }
16430 if ${gdb_cv_scanf_has_long_double+:} false; then :
16431 $as_echo_n "(cached) " >&6
16432 else
16433 if test "$cross_compiling" = yes; then :
16434 gdb_cv_scanf_has_long_double=no
16435 else
16436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16437 /* end confdefs.h. */
16438 #include <stdio.h>
16440 main ()
16442 char *buf = "3.141592653";
16443 long double f = 0;
16444 sscanf (buf, "%Lg", &f);
16445 return !(f > 3.14159 && f < 3.14160);
16447 return 0;
16449 _ACEOF
16450 if ac_fn_c_try_run "$LINENO"; then :
16451 gdb_cv_scanf_has_long_double=yes
16452 else
16453 gdb_cv_scanf_has_long_double=no
16455 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16456 conftest.$ac_objext conftest.beam conftest.$ac_ext
16460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
16461 $as_echo "$gdb_cv_scanf_has_long_double" >&6; }
16462 if test "$gdb_cv_scanf_has_long_double" = yes; then
16464 $as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
16468 case ${host_os} in
16469 aix*)
16470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
16471 $as_echo_n "checking for -bbigtoc option... " >&6; }
16472 if ${gdb_cv_bigtoc+:} false; then :
16473 $as_echo_n "(cached) " >&6
16474 else
16475 SAVE_LDFLAGS=$LDFLAGS
16477 case $GCC in
16478 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
16479 *) gdb_cv_bigtoc=-bbigtoc ;;
16480 esac
16482 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
16483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16484 /* end confdefs.h. */
16487 main ()
16489 int i;
16491 return 0;
16493 _ACEOF
16494 if ac_fn_c_try_link "$LINENO"; then :
16496 else
16497 gdb_cv_bigtoc=
16500 rm -f core conftest.err conftest.$ac_objext \
16501 conftest$ac_exeext conftest.$ac_ext
16502 LDFLAGS="${SAVE_LDFLAGS}"
16505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
16506 $as_echo "$gdb_cv_bigtoc" >&6; }
16507 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
16509 esac
16511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
16512 $as_echo_n "checking for the dynamic export flag... " >&6; }
16513 dynamic_list=false
16514 if test "${gdb_native}" = yes; then
16515 # The dynamically loaded libthread_db needs access to symbols in the gdb
16516 # executable. Older GNU ld supports --export-dynamic but --dynamic-list
16517 # may not be supported there.
16518 old_LDFLAGS="$LDFLAGS"
16519 # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
16520 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
16521 LDFLAGS="$LDFLAGS $RDYNAMIC"
16522 if test "${have_libpython}" = no; then
16523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16524 /* end confdefs.h. */
16527 main ()
16531 return 0;
16533 _ACEOF
16534 if ac_fn_c_try_link "$LINENO"; then :
16535 dynamic_list=true
16537 rm -f core conftest.err conftest.$ac_objext \
16538 conftest$ac_exeext conftest.$ac_ext
16539 else
16540 # Workaround http://bugs.python.org/issue4434 where static
16541 # libpythonX.Y.a would get its symbols required for
16542 # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
16543 # Problem does not happen for the recommended libpythonX.Y.so linkage.
16545 # Note the workaround for Python
16546 # http://bugs.python.org/issue10112 earlier has removed
16547 # -export-dynamic from PYTHON_LIBS. That's exactly what we want
16548 # here too, as otherwise it'd make this -Wl,--dynamic-list test
16549 # always pass.
16550 old_CFLAGS="$CFLAGS"
16551 CFLAGS="$CFLAGS $PYTHON_CFLAGS"
16552 old_LIBS="$LIBS"
16553 LIBS="$LIBS $PYTHON_LIBS"
16554 old_CPPFLAGS="$CPPFLAGS"
16555 CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
16556 if test "$cross_compiling" = yes; then :
16557 true
16558 else
16559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16560 /* end confdefs.h. */
16561 #include "Python.h"
16563 main ()
16565 int err;
16566 Py_Initialize ();
16567 err = PyRun_SimpleString ("import ctypes\n");
16568 Py_Finalize ();
16569 return err == 0 ? 0 : 1;
16571 return 0;
16573 _ACEOF
16574 if ac_fn_c_try_run "$LINENO"; then :
16575 dynamic_list=true
16577 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16578 conftest.$ac_objext conftest.beam conftest.$ac_ext
16581 LIBS="$old_LIBS"
16582 CFLAGS="$old_CFLAGS"
16583 CPPFLAGS="$old_CPPFLAGS"
16585 LDFLAGS="$old_LDFLAGS"
16587 if $dynamic_list; then
16588 found="-Wl,--dynamic-list"
16589 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
16590 else
16591 found="-rdynamic"
16592 RDYNAMIC="-rdynamic"
16595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
16596 $as_echo "$found" >&6; }
16599 if test "${build}" = "${host}" -a "${host}" = "${target}" ; then
16600 case ${host_os} in
16601 aix*)
16602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
16603 $as_echo_n "checking for AiX thread debugging library... " >&6; }
16604 if ${gdb_cv_have_aix_thread_debug+:} false; then :
16605 $as_echo_n "(cached) " >&6
16606 else
16607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16608 /* end confdefs.h. */
16609 #include <sys/pthdebug.h>
16611 main ()
16613 #ifndef PTHDB_VERSION_3
16614 #error
16615 #endif
16618 return 0;
16620 _ACEOF
16621 if ac_fn_c_try_compile "$LINENO"; then :
16622 gdb_cv_have_aix_thread_debug=yes
16623 else
16624 gdb_cv_have_aix_thread_debug=no
16627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
16632 $as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
16633 if test "$gdb_cv_have_aix_thread_debug" = yes; then
16634 CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
16635 CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
16636 LIBS="$LIBS -lpthdebug"
16638 # Older versions of AIX do not provide the declaration for
16639 # the getthrds function (it appears that it was introduced
16640 # with AIX 6.x).
16641 ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
16643 if test "x$ac_cv_have_decl_getthrds" = xyes; then :
16644 ac_have_decl=1
16645 else
16646 ac_have_decl=0
16649 cat >>confdefs.h <<_ACEOF
16650 #define HAVE_DECL_GETTHRDS $ac_have_decl
16651 _ACEOF
16655 esac
16659 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
16660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
16661 $as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
16662 if ${gdb_cv_thread_db_h_has_td_notalloc+:} false; then :
16663 $as_echo_n "(cached) " >&6
16664 else
16665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16666 /* end confdefs.h. */
16667 #include <thread_db.h>
16669 main ()
16671 int i = TD_NOTALLOC;
16674 return 0;
16676 _ACEOF
16677 if ac_fn_c_try_compile "$LINENO"; then :
16678 gdb_cv_thread_db_h_has_td_notalloc=yes
16679 else
16680 gdb_cv_thread_db_h_has_td_notalloc=no
16683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
16687 $as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
16689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
16690 $as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
16691 if ${gdb_cv_thread_db_h_has_td_version+:} false; then :
16692 $as_echo_n "(cached) " >&6
16693 else
16694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16695 /* end confdefs.h. */
16696 #include <thread_db.h>
16698 main ()
16700 int i = TD_VERSION;
16703 return 0;
16705 _ACEOF
16706 if ac_fn_c_try_compile "$LINENO"; then :
16707 gdb_cv_thread_db_h_has_td_version=yes
16708 else
16709 gdb_cv_thread_db_h_has_td_version=no
16712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
16716 $as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
16718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
16719 $as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
16720 if ${gdb_cv_thread_db_h_has_td_notls+:} false; then :
16721 $as_echo_n "(cached) " >&6
16722 else
16723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16724 /* end confdefs.h. */
16725 #include <thread_db.h>
16727 main ()
16729 int i = TD_NOTLS;
16732 return 0;
16734 _ACEOF
16735 if ac_fn_c_try_compile "$LINENO"; then :
16736 gdb_cv_thread_db_h_has_td_notls=yes
16737 else
16738 gdb_cv_thread_db_h_has_td_notls=no
16741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
16745 $as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
16747 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
16749 $as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
16752 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
16754 $as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
16757 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
16759 $as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
16763 case $host_os in
16764 go32* | *djgpp*)
16765 gdbinit=gdb.ini
16768 gdbinit=.gdbinit
16770 esac
16772 cat >>confdefs.h <<_ACEOF
16773 #define GDBINIT "$gdbinit"
16774 _ACEOF
16778 # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
16779 # except that the argument to --with-sysroot is optional.
16780 # --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
16781 if test "x$with_sysroot" = xyes; then
16782 with_sysroot="${exec_prefix}/${target_alias}/sys-root"
16785 # Check whether --with-sysroot was given.
16786 if test "${with_sysroot+set}" = set; then :
16787 withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
16788 else
16789 TARGET_SYSTEM_ROOT=
16793 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
16794 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16795 ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
16796 ac_define_dir=`eval echo $ac_define_dir`
16798 cat >>confdefs.h <<_ACEOF
16799 #define TARGET_SYSTEM_ROOT "$ac_define_dir"
16800 _ACEOF
16805 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
16806 if test "x$prefix" = xNONE; then
16807 test_prefix=/usr/local
16808 else
16809 test_prefix=$prefix
16811 else
16812 test_prefix=$exec_prefix
16814 value=0
16815 case ${ac_define_dir} in
16816 "${test_prefix}"|"${test_prefix}/"*|\
16817 '${exec_prefix}'|'${exec_prefix}/'*)
16818 value=1
16820 esac
16822 cat >>confdefs.h <<_ACEOF
16823 #define TARGET_SYSTEM_ROOT_RELOCATABLE $value
16824 _ACEOF
16830 # Check whether --with-system-gdbinit was given.
16831 if test "${with_system_gdbinit+set}" = set; then :
16832 withval=$with_system_gdbinit;
16833 SYSTEM_GDBINIT=$withval
16834 else
16835 SYSTEM_GDBINIT=
16839 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
16840 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16841 ac_define_dir=`eval echo $SYSTEM_GDBINIT`
16842 ac_define_dir=`eval echo $ac_define_dir`
16844 cat >>confdefs.h <<_ACEOF
16845 #define SYSTEM_GDBINIT "$ac_define_dir"
16846 _ACEOF
16851 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
16852 if test "x$prefix" = xNONE; then
16853 test_prefix=/usr/local
16854 else
16855 test_prefix=$prefix
16857 else
16858 test_prefix=$exec_prefix
16860 value=0
16861 case ${ac_define_dir} in
16862 "${test_prefix}"|"${test_prefix}/"*|\
16863 '${exec_prefix}'|'${exec_prefix}/'*)
16864 value=1
16866 esac
16868 cat >>confdefs.h <<_ACEOF
16869 #define SYSTEM_GDBINIT_RELOCATABLE $value
16870 _ACEOF
16876 # Check whether --with-system-gdbinit-dir was given.
16877 if test "${with_system_gdbinit_dir+set}" = set; then :
16878 withval=$with_system_gdbinit_dir;
16879 SYSTEM_GDBINIT_DIR=$withval
16880 else
16881 SYSTEM_GDBINIT_DIR=
16885 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
16886 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16887 ac_define_dir=`eval echo $SYSTEM_GDBINIT_DIR`
16888 ac_define_dir=`eval echo $ac_define_dir`
16890 cat >>confdefs.h <<_ACEOF
16891 #define SYSTEM_GDBINIT_DIR "$ac_define_dir"
16892 _ACEOF
16897 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
16898 if test "x$prefix" = xNONE; then
16899 test_prefix=/usr/local
16900 else
16901 test_prefix=$prefix
16903 else
16904 test_prefix=$exec_prefix
16906 value=0
16907 case ${ac_define_dir} in
16908 "${test_prefix}"|"${test_prefix}/"*|\
16909 '${exec_prefix}'|'${exec_prefix}/'*)
16910 value=1
16912 esac
16914 cat >>confdefs.h <<_ACEOF
16915 #define SYSTEM_GDBINIT_DIR_RELOCATABLE $value
16916 _ACEOF
16922 # Check whether --enable-werror was given.
16923 if test "${enable_werror+set}" = set; then :
16924 enableval=$enable_werror; case "${enableval}" in
16925 yes | y) ERROR_ON_WARNING="yes" ;;
16926 no | n) ERROR_ON_WARNING="no" ;;
16927 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
16928 esac
16932 # Enable -Werror by default when using gcc. Turn it off for releases.
16933 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
16934 ERROR_ON_WARNING=yes
16937 WERROR_CFLAGS=""
16938 if test "${ERROR_ON_WARNING}" = yes ; then
16939 WERROR_CFLAGS="-Werror"
16942 # The options we'll try to enable.
16943 build_warnings="-Wall -Wpointer-arith \
16944 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
16945 -Wno-switch -Wno-char-subscripts \
16946 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
16947 -Wno-sign-compare -Wno-error=maybe-uninitialized \
16948 -Wno-mismatched-tags \
16949 -Wno-error=deprecated-register \
16950 -Wsuggest-override \
16951 -Wimplicit-fallthrough=3 \
16952 -Wduplicated-cond \
16953 -Wshadow=local \
16954 -Wdeprecated-copy \
16955 -Wdeprecated-copy-dtor \
16956 -Wredundant-move \
16957 -Wmissing-declarations \
16958 -Wmissing-prototypes \
16959 -Wstrict-null-sentinel \
16962 case "${host}" in
16963 *-*-mingw32*)
16964 # Enable -Wno-format by default when using gcc on mingw since many
16965 # GCC versions complain about %I64.
16966 build_warnings="$build_warnings -Wno-format" ;;
16967 *-*-solaris*)
16968 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
16969 # doesn't understand.
16970 build_warnings="$build_warnings -Wno-unknown-pragmas"
16971 # Solaris 11 <unistd.h> marks vfork deprecated.
16972 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
16974 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
16975 # but there's a special case for this below.
16976 build_warnings="$build_warnings -Wformat-nonliteral" ;;
16977 esac
16979 # Check whether --enable-build-warnings was given.
16980 if test "${enable_build_warnings+set}" = set; then :
16981 enableval=$enable_build_warnings; case "${enableval}" in
16982 yes) ;;
16983 no) build_warnings="-w";;
16984 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
16985 build_warnings="${build_warnings} ${t}";;
16986 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
16987 build_warnings="${t} ${build_warnings}";;
16988 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
16989 esac
16990 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
16991 echo "Setting compiler warning flags = $build_warnings" 6>&1
16994 # Check whether --enable-gdb-build-warnings was given.
16995 if test "${enable_gdb_build_warnings+set}" = set; then :
16996 enableval=$enable_gdb_build_warnings; case "${enableval}" in
16997 yes) ;;
16998 no) build_warnings="-w";;
16999 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
17000 build_warnings="${build_warnings} ${t}";;
17001 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
17002 build_warnings="${t} ${build_warnings}";;
17003 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
17004 esac
17005 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
17006 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
17010 # The set of warnings supported by a C++ compiler is not the same as
17011 # of the C compiler.
17012 ac_ext=cpp
17013 ac_cpp='$CXXCPP $CPPFLAGS'
17014 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17015 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17016 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
17019 WARN_CFLAGS=""
17020 if test "x${build_warnings}" != x -a "x$GCC" = xyes
17021 then
17022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
17023 $as_echo_n "checking compiler warning flags... " >&6; }
17024 # Separate out the -Werror flag as some files just cannot be
17025 # compiled with it enabled.
17026 for w in ${build_warnings}; do
17027 # GCC does not complain about -Wno-unknown-warning. Invert
17028 # and test -Wunknown-warning instead.
17029 case $w in
17030 -Wno-*)
17031 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
17032 -Wformat-nonliteral)
17033 # gcc requires -Wformat before -Wformat-nonliteral
17034 # will work, so stick them together.
17035 w="-Wformat $w"
17036 wtest="$w"
17039 wtest=$w ;;
17040 esac
17042 case $w in
17043 -Werr*) WERROR_CFLAGS=-Werror ;;
17045 # Check whether GCC accepts it.
17046 saved_CFLAGS="$CFLAGS"
17047 CFLAGS="$CFLAGS -Werror $wtest"
17048 saved_CXXFLAGS="$CXXFLAGS"
17049 CXXFLAGS="$CXXFLAGS -Werror $wtest"
17050 if test "x$w" = "x-Wunused-variable"; then
17051 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
17052 # fixed in GCC 4.9. This test is derived from the gdb
17053 # source code that triggered this bug in GCC.
17054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17055 /* end confdefs.h. */
17056 struct scoped_restore_base {};
17057 struct scoped_restore_tmpl : public scoped_restore_base {
17058 ~scoped_restore_tmpl() {}
17061 main ()
17063 const scoped_restore_base &b = scoped_restore_tmpl();
17066 return 0;
17068 _ACEOF
17069 if ac_fn_cxx_try_compile "$LINENO"; then :
17070 WARN_CFLAGS="${WARN_CFLAGS} $w"
17072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17073 else
17074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17075 /* end confdefs.h. */
17078 main ()
17082 return 0;
17084 _ACEOF
17085 if ac_fn_cxx_try_compile "$LINENO"; then :
17086 WARN_CFLAGS="${WARN_CFLAGS} $w"
17088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17090 CFLAGS="$saved_CFLAGS"
17091 CXXFLAGS="$saved_CXXFLAGS"
17092 esac
17093 done
17094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
17095 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
17100 ac_ext=c
17101 ac_cpp='$CPP $CPPFLAGS'
17102 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17103 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17104 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17108 # Check whether --enable-ubsan was given.
17109 if test "${enable_ubsan+set}" = set; then :
17110 enableval=$enable_ubsan;
17111 else
17112 enable_ubsan=no
17115 if test "x$enable_ubsan" = xauto; then
17116 if $development; then
17117 enable_ubsan=yes
17120 ac_ext=cpp
17121 ac_cpp='$CXXCPP $CPPFLAGS'
17122 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17123 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17124 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
17126 if test "x$enable_ubsan" = xyes; then
17127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fsanitize=undefined is accepted" >&5
17128 $as_echo_n "checking whether -fsanitize=undefined is accepted... " >&6; }
17129 saved_CXXFLAGS="$CXXFLAGS"
17130 CXXFLAGS="$CXXFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
17131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17132 /* end confdefs.h. */
17135 main ()
17139 return 0;
17141 _ACEOF
17142 if ac_fn_cxx_try_link "$LINENO"; then :
17143 enable_ubsan=yes
17144 else
17145 enable_ubsan=no
17148 rm -f core conftest.err conftest.$ac_objext \
17149 conftest$ac_exeext conftest.$ac_ext
17150 CXXFLAGS="$saved_CXXFLAGS"
17151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_ubsan" >&5
17152 $as_echo "$enable_ubsan" >&6; }
17153 if test "x$enable_ubsan" = xyes; then
17154 WARN_CFLAGS="$WARN_CFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
17155 CONFIG_LDFLAGS="$CONFIG_LDFLAGS -fsanitize=undefined"
17158 ac_ext=c
17159 ac_cpp='$CPP $CPPFLAGS'
17160 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
17161 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
17162 ac_compiler_gnu=$ac_cv_c_compiler_gnu
17166 # In the Cygwin environment, we need some additional flags.
17167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
17168 $as_echo_n "checking for cygwin... " >&6; }
17169 if ${gdb_cv_os_cygwin+:} false; then :
17170 $as_echo_n "(cached) " >&6
17171 else
17172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17173 /* end confdefs.h. */
17175 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
17176 lose
17177 #endif
17178 _ACEOF
17179 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17180 $EGREP "^lose$" >/dev/null 2>&1; then :
17181 gdb_cv_os_cygwin=yes
17182 else
17183 gdb_cv_os_cygwin=no
17185 rm -f conftest*
17188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
17189 $as_echo "$gdb_cv_os_cygwin" >&6; }
17192 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
17193 case ${host} in
17194 *go32* ) SER_HARDWIRE=ser-go32.o ;;
17195 *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
17196 *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
17197 *) SER_HARDWIRE="$SER_HARDWIRE ser-uds.o" ;;
17198 esac
17201 # libreadline needs libuser32.a in a cygwin environment
17202 WIN32LIBS=
17203 if test x"$gdb_cv_os_cygwin" = xyes; then
17204 WIN32LIBS="-luser32"
17205 case "${target}" in
17206 *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
17208 esac
17211 # The ser-tcp.c module requires sockets.
17212 # Note that WIN32APILIBS is set by GDB_AC_COMMON.
17213 WIN32LIBS="$WIN32LIBS $WIN32APILIBS"
17215 # Add ELF support to GDB, but only if BFD includes ELF support.
17217 OLD_CFLAGS=$CFLAGS
17218 OLD_LDFLAGS=$LDFLAGS
17219 OLD_LIBS=$LIBS
17220 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
17221 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
17222 # always want our bfd.
17223 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
17224 ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
17225 LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
17226 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
17227 LIBS="-lbfd -liberty -lz $intl $LIBS"
17228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
17229 $as_echo_n "checking for ELF support in BFD... " >&6; }
17230 if ${gdb_cv_var_elf+:} false; then :
17231 $as_echo_n "(cached) " >&6
17232 else
17233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17234 /* end confdefs.h. */
17235 #include <stdlib.h>
17236 #include "bfd.h"
17237 #include "elf-bfd.h"
17239 main ()
17241 return bfd_get_elf_phdr_upper_bound (NULL);
17244 return 0;
17246 _ACEOF
17247 if ac_fn_c_try_link "$LINENO"; then :
17248 gdb_cv_var_elf=yes
17249 else
17250 gdb_cv_var_elf=no
17253 rm -f core conftest.err conftest.$ac_objext \
17254 conftest$ac_exeext conftest.$ac_ext
17257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
17258 $as_echo "$gdb_cv_var_elf" >&6; }
17259 CFLAGS=$OLD_CFLAGS
17260 LDFLAGS=$OLD_LDFLAGS
17261 LIBS=$OLD_LIBS
17262 if test "$gdb_cv_var_elf" = yes; then
17263 CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o dtrace-probe.o"
17265 $as_echo "#define HAVE_ELF 1" >>confdefs.h
17267 # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
17268 if test "$plugins" = "yes"; then
17269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
17270 $as_echo_n "checking for library containing dlopen... " >&6; }
17271 if ${ac_cv_search_dlopen+:} false; then :
17272 $as_echo_n "(cached) " >&6
17273 else
17274 ac_func_search_save_LIBS=$LIBS
17275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17276 /* end confdefs.h. */
17278 /* Override any GCC internal prototype to avoid an error.
17279 Use char because int might match the return type of a GCC
17280 builtin and then its argument prototype would still apply. */
17281 #ifdef __cplusplus
17282 extern "C"
17283 #endif
17284 char dlopen ();
17286 main ()
17288 return dlopen ();
17290 return 0;
17292 _ACEOF
17293 for ac_lib in '' dl; do
17294 if test -z "$ac_lib"; then
17295 ac_res="none required"
17296 else
17297 ac_res=-l$ac_lib
17298 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17300 if ac_fn_c_try_link "$LINENO"; then :
17301 ac_cv_search_dlopen=$ac_res
17303 rm -f core conftest.err conftest.$ac_objext \
17304 conftest$ac_exeext
17305 if ${ac_cv_search_dlopen+:} false; then :
17306 break
17308 done
17309 if ${ac_cv_search_dlopen+:} false; then :
17311 else
17312 ac_cv_search_dlopen=no
17314 rm conftest.$ac_ext
17315 LIBS=$ac_func_search_save_LIBS
17317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
17318 $as_echo "$ac_cv_search_dlopen" >&6; }
17319 ac_res=$ac_cv_search_dlopen
17320 if test "$ac_res" != no; then :
17321 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17328 # Add macho support to GDB, but only if BFD includes it.
17330 OLD_CFLAGS=$CFLAGS
17331 OLD_LDFLAGS=$LDFLAGS
17332 OLD_LIBS=$LIBS
17333 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
17334 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
17335 # always want our bfd.
17336 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
17337 ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
17338 LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
17339 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
17340 LIBS="-lbfd -liberty -lz $intl $LIBS"
17341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mach-O support in BFD" >&5
17342 $as_echo_n "checking for Mach-O support in BFD... " >&6; }
17343 if ${gdb_cv_var_macho+:} false; then :
17344 $as_echo_n "(cached) " >&6
17345 else
17346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17347 /* end confdefs.h. */
17348 #include <stdlib.h>
17349 #include "bfd.h"
17350 #include "mach-o.h"
17352 main ()
17354 return bfd_mach_o_lookup_command (NULL, 0, NULL);
17357 return 0;
17359 _ACEOF
17360 if ac_fn_c_try_link "$LINENO"; then :
17361 gdb_cv_var_macho=yes
17362 else
17363 gdb_cv_var_macho=no
17366 rm -f core conftest.err conftest.$ac_objext \
17367 conftest$ac_exeext conftest.$ac_ext
17370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_macho" >&5
17371 $as_echo "$gdb_cv_var_macho" >&6; }
17372 CFLAGS=$OLD_CFLAGS
17373 LDFLAGS=$OLD_LDFLAGS
17374 LIBS=$OLD_LIBS
17375 if test "$gdb_cv_var_macho" = yes; then
17376 CONFIG_OBS="$CONFIG_OBS machoread.o"
17379 # Add any host-specific objects to GDB.
17380 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
17382 # If building on ELF, look for lzma support for embedded compressed debug info.
17383 if test "$gdb_cv_var_elf" = yes; then
17385 # Check whether --with-lzma was given.
17386 if test "${with_lzma+set}" = set; then :
17387 withval=$with_lzma;
17388 else
17389 with_lzma=auto
17392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
17393 $as_echo_n "checking whether to use lzma... " >&6; }
17394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
17395 $as_echo "$with_lzma" >&6; }
17397 if test "${with_lzma}" != no; then
17406 use_additional=yes
17408 acl_save_prefix="$prefix"
17409 prefix="$acl_final_prefix"
17410 acl_save_exec_prefix="$exec_prefix"
17411 exec_prefix="$acl_final_exec_prefix"
17413 eval additional_includedir=\"$includedir\"
17414 eval additional_libdir=\"$libdir\"
17416 exec_prefix="$acl_save_exec_prefix"
17417 prefix="$acl_save_prefix"
17420 # Check whether --with-liblzma-prefix was given.
17421 if test "${with_liblzma_prefix+set}" = set; then :
17422 withval=$with_liblzma_prefix;
17423 if test "X$withval" = "Xno"; then
17424 use_additional=no
17425 else
17426 if test "X$withval" = "X"; then
17428 acl_save_prefix="$prefix"
17429 prefix="$acl_final_prefix"
17430 acl_save_exec_prefix="$exec_prefix"
17431 exec_prefix="$acl_final_exec_prefix"
17433 eval additional_includedir=\"$includedir\"
17434 eval additional_libdir=\"$libdir\"
17436 exec_prefix="$acl_save_exec_prefix"
17437 prefix="$acl_save_prefix"
17439 else
17440 additional_includedir="$withval/include"
17441 additional_libdir="$withval/lib"
17448 # Check whether --with-liblzma-type was given.
17449 if test "${with_liblzma_type+set}" = set; then :
17450 withval=$with_liblzma_type; with_liblzma_type=$withval
17451 else
17452 with_liblzma_type=auto
17455 lib_type=`eval echo \$with_liblzma_type`
17457 LIBLZMA=
17458 LTLIBLZMA=
17459 INCLZMA=
17460 rpathdirs=
17461 ltrpathdirs=
17462 names_already_handled=
17463 names_next_round='lzma '
17464 while test -n "$names_next_round"; do
17465 names_this_round="$names_next_round"
17466 names_next_round=
17467 for name in $names_this_round; do
17468 already_handled=
17469 for n in $names_already_handled; do
17470 if test "$n" = "$name"; then
17471 already_handled=yes
17472 break
17474 done
17475 if test -z "$already_handled"; then
17476 names_already_handled="$names_already_handled $name"
17477 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
17478 eval value=\"\$HAVE_LIB$uppername\"
17479 if test -n "$value"; then
17480 if test "$value" = yes; then
17481 eval value=\"\$LIB$uppername\"
17482 test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
17483 eval value=\"\$LTLIB$uppername\"
17484 test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
17485 else
17488 else
17489 found_dir=
17490 found_la=
17491 found_so=
17492 found_a=
17493 if test $use_additional = yes; then
17494 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
17495 found_dir="$additional_libdir"
17496 found_so="$additional_libdir/lib$name.$shlibext"
17497 if test -f "$additional_libdir/lib$name.la"; then
17498 found_la="$additional_libdir/lib$name.la"
17500 elif test x$lib_type != xshared; then
17501 if test -f "$additional_libdir/lib$name.$libext"; then
17502 found_dir="$additional_libdir"
17503 found_a="$additional_libdir/lib$name.$libext"
17504 if test -f "$additional_libdir/lib$name.la"; then
17505 found_la="$additional_libdir/lib$name.la"
17510 if test "X$found_dir" = "X"; then
17511 for x in $LDFLAGS $LTLIBLZMA; do
17513 acl_save_prefix="$prefix"
17514 prefix="$acl_final_prefix"
17515 acl_save_exec_prefix="$exec_prefix"
17516 exec_prefix="$acl_final_exec_prefix"
17517 eval x=\"$x\"
17518 exec_prefix="$acl_save_exec_prefix"
17519 prefix="$acl_save_prefix"
17521 case "$x" in
17522 -L*)
17523 dir=`echo "X$x" | sed -e 's/^X-L//'`
17524 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
17525 found_dir="$dir"
17526 found_so="$dir/lib$name.$shlibext"
17527 if test -f "$dir/lib$name.la"; then
17528 found_la="$dir/lib$name.la"
17530 elif test x$lib_type != xshared; then
17531 if test -f "$dir/lib$name.$libext"; then
17532 found_dir="$dir"
17533 found_a="$dir/lib$name.$libext"
17534 if test -f "$dir/lib$name.la"; then
17535 found_la="$dir/lib$name.la"
17540 esac
17541 if test "X$found_dir" != "X"; then
17542 break
17544 done
17546 if test "X$found_dir" != "X"; then
17547 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
17548 if test "X$found_so" != "X"; then
17549 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
17550 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
17551 else
17552 haveit=
17553 for x in $ltrpathdirs; do
17554 if test "X$x" = "X$found_dir"; then
17555 haveit=yes
17556 break
17558 done
17559 if test -z "$haveit"; then
17560 ltrpathdirs="$ltrpathdirs $found_dir"
17562 if test "$hardcode_direct" = yes; then
17563 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
17564 else
17565 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
17566 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
17567 haveit=
17568 for x in $rpathdirs; do
17569 if test "X$x" = "X$found_dir"; then
17570 haveit=yes
17571 break
17573 done
17574 if test -z "$haveit"; then
17575 rpathdirs="$rpathdirs $found_dir"
17577 else
17578 haveit=
17579 for x in $LDFLAGS $LIBLZMA; do
17581 acl_save_prefix="$prefix"
17582 prefix="$acl_final_prefix"
17583 acl_save_exec_prefix="$exec_prefix"
17584 exec_prefix="$acl_final_exec_prefix"
17585 eval x=\"$x\"
17586 exec_prefix="$acl_save_exec_prefix"
17587 prefix="$acl_save_prefix"
17589 if test "X$x" = "X-L$found_dir"; then
17590 haveit=yes
17591 break
17593 done
17594 if test -z "$haveit"; then
17595 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
17597 if test "$hardcode_minus_L" != no; then
17598 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
17599 else
17600 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
17605 else
17606 if test "X$found_a" != "X"; then
17607 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
17608 else
17609 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
17612 additional_includedir=
17613 case "$found_dir" in
17614 */lib | */lib/)
17615 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
17616 additional_includedir="$basedir/include"
17618 esac
17619 if test "X$additional_includedir" != "X"; then
17620 if test "X$additional_includedir" != "X/usr/include"; then
17621 haveit=
17622 if test "X$additional_includedir" = "X/usr/local/include"; then
17623 if test -n "$GCC"; then
17624 case $host_os in
17625 linux*) haveit=yes;;
17626 esac
17629 if test -z "$haveit"; then
17630 for x in $CPPFLAGS $INCLZMA; do
17632 acl_save_prefix="$prefix"
17633 prefix="$acl_final_prefix"
17634 acl_save_exec_prefix="$exec_prefix"
17635 exec_prefix="$acl_final_exec_prefix"
17636 eval x=\"$x\"
17637 exec_prefix="$acl_save_exec_prefix"
17638 prefix="$acl_save_prefix"
17640 if test "X$x" = "X-I$additional_includedir"; then
17641 haveit=yes
17642 break
17644 done
17645 if test -z "$haveit"; then
17646 if test -d "$additional_includedir"; then
17647 INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
17653 if test -n "$found_la"; then
17654 save_libdir="$libdir"
17655 case "$found_la" in
17656 */* | *\\*) . "$found_la" ;;
17657 *) . "./$found_la" ;;
17658 esac
17659 libdir="$save_libdir"
17660 for dep in $dependency_libs; do
17661 case "$dep" in
17662 -L*)
17663 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
17664 if test "X$additional_libdir" != "X/usr/lib"; then
17665 haveit=
17666 if test "X$additional_libdir" = "X/usr/local/lib"; then
17667 if test -n "$GCC"; then
17668 case $host_os in
17669 linux*) haveit=yes;;
17670 esac
17673 if test -z "$haveit"; then
17674 haveit=
17675 for x in $LDFLAGS $LIBLZMA; do
17677 acl_save_prefix="$prefix"
17678 prefix="$acl_final_prefix"
17679 acl_save_exec_prefix="$exec_prefix"
17680 exec_prefix="$acl_final_exec_prefix"
17681 eval x=\"$x\"
17682 exec_prefix="$acl_save_exec_prefix"
17683 prefix="$acl_save_prefix"
17685 if test "X$x" = "X-L$additional_libdir"; then
17686 haveit=yes
17687 break
17689 done
17690 if test -z "$haveit"; then
17691 if test -d "$additional_libdir"; then
17692 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
17695 haveit=
17696 for x in $LDFLAGS $LTLIBLZMA; do
17698 acl_save_prefix="$prefix"
17699 prefix="$acl_final_prefix"
17700 acl_save_exec_prefix="$exec_prefix"
17701 exec_prefix="$acl_final_exec_prefix"
17702 eval x=\"$x\"
17703 exec_prefix="$acl_save_exec_prefix"
17704 prefix="$acl_save_prefix"
17706 if test "X$x" = "X-L$additional_libdir"; then
17707 haveit=yes
17708 break
17710 done
17711 if test -z "$haveit"; then
17712 if test -d "$additional_libdir"; then
17713 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
17719 -R*)
17720 dir=`echo "X$dep" | sed -e 's/^X-R//'`
17721 if test "$enable_rpath" != no; then
17722 haveit=
17723 for x in $rpathdirs; do
17724 if test "X$x" = "X$dir"; then
17725 haveit=yes
17726 break
17728 done
17729 if test -z "$haveit"; then
17730 rpathdirs="$rpathdirs $dir"
17732 haveit=
17733 for x in $ltrpathdirs; do
17734 if test "X$x" = "X$dir"; then
17735 haveit=yes
17736 break
17738 done
17739 if test -z "$haveit"; then
17740 ltrpathdirs="$ltrpathdirs $dir"
17744 -l*)
17745 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
17747 *.la)
17748 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
17751 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
17752 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
17754 esac
17755 done
17757 else
17758 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
17759 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
17760 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
17761 else
17762 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l:lib$name.$libext"
17763 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l:lib$name.$libext"
17768 done
17769 done
17770 if test "X$rpathdirs" != "X"; then
17771 if test -n "$hardcode_libdir_separator"; then
17772 alldirs=
17773 for found_dir in $rpathdirs; do
17774 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
17775 done
17776 acl_save_libdir="$libdir"
17777 libdir="$alldirs"
17778 eval flag=\"$hardcode_libdir_flag_spec\"
17779 libdir="$acl_save_libdir"
17780 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
17781 else
17782 for found_dir in $rpathdirs; do
17783 acl_save_libdir="$libdir"
17784 libdir="$found_dir"
17785 eval flag=\"$hardcode_libdir_flag_spec\"
17786 libdir="$acl_save_libdir"
17787 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
17788 done
17791 if test "X$ltrpathdirs" != "X"; then
17792 for found_dir in $ltrpathdirs; do
17793 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
17794 done
17798 ac_save_CPPFLAGS="$CPPFLAGS"
17800 for element in $INCLZMA; do
17801 haveit=
17802 for x in $CPPFLAGS; do
17804 acl_save_prefix="$prefix"
17805 prefix="$acl_final_prefix"
17806 acl_save_exec_prefix="$exec_prefix"
17807 exec_prefix="$acl_final_exec_prefix"
17808 eval x=\"$x\"
17809 exec_prefix="$acl_save_exec_prefix"
17810 prefix="$acl_save_prefix"
17812 if test "X$x" = "X$element"; then
17813 haveit=yes
17814 break
17816 done
17817 if test -z "$haveit"; then
17818 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
17820 done
17823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
17824 $as_echo_n "checking for liblzma... " >&6; }
17825 if ${ac_cv_liblzma+:} false; then :
17826 $as_echo_n "(cached) " >&6
17827 else
17829 ac_save_LIBS="$LIBS"
17830 LIBS="$LIBS $LIBLZMA"
17831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17832 /* end confdefs.h. */
17833 #include "lzma.h"
17835 main ()
17837 lzma_index_iter iter;
17838 lzma_index_iter_init (&iter, 0);
17839 lzma_mf_is_supported (LZMA_MF_HC3);
17841 return 0;
17843 _ACEOF
17844 if ac_fn_c_try_link "$LINENO"; then :
17845 ac_cv_liblzma=yes
17846 else
17847 ac_cv_liblzma=no
17849 rm -f core conftest.err conftest.$ac_objext \
17850 conftest$ac_exeext conftest.$ac_ext
17851 LIBS="$ac_save_LIBS"
17854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
17855 $as_echo "$ac_cv_liblzma" >&6; }
17856 if test "$ac_cv_liblzma" = yes; then
17857 HAVE_LIBLZMA=yes
17859 $as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
17861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
17862 $as_echo_n "checking how to link with liblzma... " >&6; }
17863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
17864 $as_echo "$LIBLZMA" >&6; }
17865 else
17866 HAVE_LIBLZMA=no
17867 CPPFLAGS="$ac_save_CPPFLAGS"
17868 LIBLZMA=
17869 LTLIBLZMA=
17877 if test "$HAVE_LIBLZMA" != yes; then
17878 if test "$with_lzma" = yes; then
17879 as_fn_error $? "missing liblzma for --with-lzma" "$LINENO" 5
17885 LIBGUI="../libgui/src/libgui.a"
17886 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
17890 WIN32LDAPP=
17894 case "${host}" in
17895 *-*-cygwin* | *-*-mingw* )
17896 configdir="win"
17899 configdir="unix"
17901 esac
17903 GDBTKLIBS=
17904 if test "${enable_gdbtk}" = "yes"; then
17906 # Gdbtk must have an absolute path to srcdir in order to run
17907 # properly when not installed.
17908 here=`pwd`
17909 cd ${srcdir}
17910 GDBTK_SRC_DIR=`pwd`
17911 cd $here
17915 # Ok, lets find the tcl configuration
17916 # First, look for one uninstalled.
17917 # the alternative search directory is invoked by --with-tcl
17920 if test x"${no_tcl}" = x ; then
17921 # we reset no_tcl in case something fails here
17922 no_tcl=true
17924 # Check whether --with-tcl was given.
17925 if test "${with_tcl+set}" = set; then :
17926 withval=$with_tcl; with_tclconfig=${withval}
17929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
17930 $as_echo_n "checking for Tcl configuration... " >&6; }
17931 if ${ac_cv_c_tclconfig+:} false; then :
17932 $as_echo_n "(cached) " >&6
17933 else
17936 # First check to see if --with-tcl was specified.
17937 case "${host}" in
17938 *-*-cygwin*) platDir="win" ;;
17939 *) platDir="unix" ;;
17940 esac
17941 if test x"${with_tclconfig}" != x ; then
17942 if test -f "${with_tclconfig}/tclConfig.sh" ; then
17943 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
17944 else
17945 as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
17949 # then check for a private Tcl installation
17950 if test x"${ac_cv_c_tclconfig}" = x ; then
17951 for i in \
17952 ../tcl \
17953 `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
17954 `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
17955 `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
17956 ../../tcl \
17957 `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
17958 `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
17959 `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
17960 ../../../tcl \
17961 `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
17962 `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
17963 `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
17964 if test -f "$i/$platDir/tclConfig.sh" ; then
17965 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
17966 break
17968 done
17971 # on Darwin, check in Framework installation locations
17972 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
17973 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
17974 `ls -d /Library/Frameworks 2>/dev/null` \
17975 `ls -d /Network/Library/Frameworks 2>/dev/null` \
17976 `ls -d /System/Library/Frameworks 2>/dev/null` \
17977 ; do
17978 if test -f "$i/Tcl.framework/tclConfig.sh" ; then
17979 ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
17980 break
17982 done
17985 # check in a few common install locations
17986 if test x"${ac_cv_c_tclconfig}" = x ; then
17987 for i in `ls -d ${libdir} 2>/dev/null` \
17988 `ls -d ${exec_prefix}/lib 2>/dev/null` \
17989 `ls -d ${prefix}/lib 2>/dev/null` \
17990 `ls -d /usr/local/lib 2>/dev/null` \
17991 `ls -d /usr/contrib/lib 2>/dev/null` \
17992 `ls -d /usr/lib 2>/dev/null` \
17993 ; do
17994 if test -f "$i/tclConfig.sh" ; then
17995 ac_cv_c_tclconfig=`(cd $i; pwd)`
17996 break
17998 done
18001 # check in a few other private locations
18002 if test x"${ac_cv_c_tclconfig}" = x ; then
18003 for i in \
18004 ${srcdir}/../tcl \
18005 `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
18006 `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
18007 `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
18008 if test -f "$i/$platDir/tclConfig.sh" ; then
18009 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
18010 break
18012 done
18018 if test x"${ac_cv_c_tclconfig}" = x ; then
18019 TCL_BIN_DIR="# no Tcl configs found"
18020 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
18021 $as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
18022 else
18023 no_tcl=
18024 TCL_BIN_DIR=${ac_cv_c_tclconfig}
18025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
18026 $as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
18031 # If $no_tk is nonempty, then we can't do Tk, and there is no
18032 # point to doing Tcl.
18035 # Ok, lets find the tk configuration
18036 # First, look for one uninstalled.
18037 # the alternative search directory is invoked by --with-tk
18040 if test x"${no_tk}" = x ; then
18041 # we reset no_tk in case something fails here
18042 no_tk=true
18044 # Check whether --with-tk was given.
18045 if test "${with_tk+set}" = set; then :
18046 withval=$with_tk; with_tkconfig=${withval}
18049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
18050 $as_echo_n "checking for Tk configuration... " >&6; }
18051 if ${ac_cv_c_tkconfig+:} false; then :
18052 $as_echo_n "(cached) " >&6
18053 else
18056 # First check to see if --with-tkconfig was specified.
18057 if test x"${with_tkconfig}" != x ; then
18058 if test -f "${with_tkconfig}/tkConfig.sh" ; then
18059 ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
18060 else
18061 as_fn_error $? "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
18065 # then check for a private Tk library
18066 case "${host}" in
18067 *-*-cygwin*) platDir="win" ;;
18068 *) platDir="unix" ;;
18069 esac
18070 if test x"${ac_cv_c_tkconfig}" = x ; then
18071 for i in \
18072 ../tk \
18073 `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
18074 `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
18075 `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
18076 ../../tk \
18077 `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
18078 `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
18079 `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
18080 ../../../tk \
18081 `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
18082 `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
18083 `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
18084 if test -f "$i/$platDir/tkConfig.sh" ; then
18085 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
18086 break
18088 done
18091 # on Darwin, check in Framework installation locations
18092 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
18093 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
18094 `ls -d /Library/Frameworks 2>/dev/null` \
18095 `ls -d /Network/Library/Frameworks 2>/dev/null` \
18096 `ls -d /System/Library/Frameworks 2>/dev/null` \
18097 ; do
18098 if test -f "$i/Tk.framework/tkConfig.sh" ; then
18099 ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
18100 break
18102 done
18105 # check in a few common install locations
18106 if test x"${ac_cv_c_tkconfig}" = x ; then
18107 for i in `ls -d ${libdir} 2>/dev/null` \
18108 `ls -d ${exec_prefix}/lib 2>/dev/null` \
18109 `ls -d ${prefix}/lib 2>/dev/null` \
18110 `ls -d /usr/local/lib 2>/dev/null` \
18111 `ls -d /usr/contrib/lib 2>/dev/null` \
18112 `ls -d /usr/lib 2>/dev/null` \
18113 ; do
18114 if test -f "$i/tkConfig.sh" ; then
18115 ac_cv_c_tkconfig=`(cd $i; pwd)`
18116 break
18118 done
18120 # check in a few other private locations
18121 if test x"${ac_cv_c_tkconfig}" = x ; then
18122 for i in \
18123 ${srcdir}/../tk \
18124 `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
18125 `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
18126 `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
18127 if test -f "$i/$platDir/tkConfig.sh" ; then
18128 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
18129 break
18131 done
18137 if test x"${ac_cv_c_tkconfig}" = x ; then
18138 TK_BIN_DIR="# no Tk configs found"
18139 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
18140 $as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
18141 else
18142 no_tk=
18143 TK_BIN_DIR=${ac_cv_c_tkconfig}
18144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
18145 $as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
18150 if test -z "${no_tcl}" -a -z "${no_tk}"; then
18152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
18153 $as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
18155 if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
18156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
18157 $as_echo "loading" >&6; }
18158 . ${TCL_BIN_DIR}/tclConfig.sh
18159 else
18160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
18161 $as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
18164 # eval is required to do the TCL_DBGX substitution
18165 eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
18166 eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
18168 # If the TCL_BIN_DIR is the build directory (not the install directory),
18169 # then set the common variable name to the value of the build variables.
18170 # For example, the variable TCL_LIB_SPEC will be set to the value
18171 # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
18172 # instead of TCL_BUILD_LIB_SPEC since it will work with both an
18173 # installed and uninstalled version of Tcl.
18174 if test -f "${TCL_BIN_DIR}/Makefile" ; then
18175 TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
18176 TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
18177 TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
18178 elif test "`uname -s`" = "Darwin"; then
18179 # If Tcl was built as a framework, attempt to use the libraries
18180 # from the framework at the given location so that linking works
18181 # against Tcl.framework installed in an arbitrary location.
18182 case ${TCL_DEFS} in
18183 *TCL_FRAMEWORK*)
18184 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
18185 for i in "`cd ${TCL_BIN_DIR}; pwd`" \
18186 "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
18187 if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
18188 TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
18189 break
18191 done
18193 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
18194 TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
18195 TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
18198 esac
18201 # eval is required to do the TCL_DBGX substitution
18202 eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
18203 eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
18204 eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
18205 eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
18221 # Check for in-tree tcl
18222 here=`pwd`
18223 cd ${srcdir}/..
18224 topdir=`pwd`
18225 cd ${here}
18227 intree="no"
18228 if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
18229 intree="yes"
18232 # Find Tcl private headers
18233 if test x"${intree}" = xno; then
18235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
18236 $as_echo_n "checking for Tcl private headers... " >&6; }
18237 private_dir=""
18238 dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
18239 if test -f ${dir}/tclInt.h ; then
18240 private_dir=${dir}
18243 if test x"${private_dir}" = x; then
18244 as_fn_error $? "could not find private Tcl headers" "$LINENO" 5
18245 else
18246 TCL_PRIVATE_INCLUDE="-I${private_dir}"
18247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
18248 $as_echo "${private_dir}" >&6; }
18251 TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
18252 TCL_LIBRARY="${TCL_LIB_SPEC}"
18253 TCL_DEPS=""
18254 else
18255 # If building tcl in the same src tree, private headers
18256 # are not needed, but we need to be sure to use the right
18257 # headers library
18258 TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
18259 TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
18260 TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
18267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
18268 $as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
18270 if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
18271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
18272 $as_echo "loading" >&6; }
18273 . ${TK_BIN_DIR}/tkConfig.sh
18274 else
18275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
18276 $as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
18279 # eval is required to do the TK_DBGX substitution
18280 eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
18281 eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
18283 # If the TK_BIN_DIR is the build directory (not the install directory),
18284 # then set the common variable name to the value of the build variables.
18285 # For example, the variable TK_LIB_SPEC will be set to the value
18286 # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
18287 # instead of TK_BUILD_LIB_SPEC since it will work with both an
18288 # installed and uninstalled version of Tcl.
18289 if test -f "${TK_BIN_DIR}/Makefile" ; then
18290 TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
18291 TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
18292 TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
18293 elif test "`uname -s`" = "Darwin"; then
18294 # If Tk was built as a framework, attempt to use the libraries
18295 # from the framework at the given location so that linking works
18296 # against Tk.framework installed in an arbitrary location.
18297 case ${TK_DEFS} in
18298 *TK_FRAMEWORK*)
18299 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
18300 for i in "`cd ${TK_BIN_DIR}; pwd`" \
18301 "`cd ${TK_BIN_DIR}/../..; pwd`"; do
18302 if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
18303 TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
18304 break
18306 done
18308 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
18309 TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
18310 TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
18313 esac
18316 # eval is required to do the TK_DBGX substitution
18317 eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
18318 eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
18319 eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
18320 eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
18335 # Check for in-tree Tk
18336 intree="no"
18337 if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
18338 intree="yes"
18341 # Find Tk private headers
18342 if test x"${intree}" = xno; then
18344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
18345 $as_echo_n "checking for Tk private headers... " >&6; }
18346 private_dir=""
18347 dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
18348 if test -f ${dir}/tkInt.h; then
18349 private_dir=${dir}
18352 if test x"${private_dir}" = x; then
18353 as_fn_error $? "could not find Tk private headers" "$LINENO" 5
18354 else
18355 TK_PRIVATE_INCLUDE="-I${private_dir}"
18356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
18357 $as_echo "${private_dir}" >&6; }
18360 TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
18361 TK_LIBRARY=${TK_LIB_SPEC}
18362 TK_DEPS=""
18363 else
18364 TK_INCLUDE="-I${TK_SRC_DIR}/generic"
18365 TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
18366 TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
18373 ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
18375 # Include some libraries that Tcl and Tk want.
18376 TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
18377 # Yes, the ordering seems wrong here. But it isn't.
18378 # TK_LIBS is the list of libraries that need to be linked
18379 # after Tcl/Tk. Note that this isn't put into LIBS. If it
18380 # were in LIBS then any link tests after this point would
18381 # try to include things like `$(LIBGUI)', which wouldn't work.
18382 GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
18384 CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
18385 CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
18386 CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
18387 CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
18388 CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
18389 CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
18390 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
18392 if test x"$gdb_cv_os_cygwin" = xyes; then
18393 WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
18394 WIN32LDAPP="-Wl,--subsystem,console"
18395 CONFIG_OBS="${CONFIG_OBS} gdbres.o"
18398 subdirs="$subdirs gdbtk"
18410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
18411 $as_echo_n "checking for X... " >&6; }
18414 # Check whether --with-x was given.
18415 if test "${with_x+set}" = set; then :
18416 withval=$with_x;
18419 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
18420 if test "x$with_x" = xno; then
18421 # The user explicitly disabled X.
18422 have_x=disabled
18423 else
18424 case $x_includes,$x_libraries in #(
18425 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
18426 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
18427 $as_echo_n "(cached) " >&6
18428 else
18429 # One or both of the vars are not set, and there is no cached value.
18430 ac_x_includes=no ac_x_libraries=no
18431 rm -f -r conftest.dir
18432 if mkdir conftest.dir; then
18433 cd conftest.dir
18434 cat >Imakefile <<'_ACEOF'
18435 incroot:
18436 @echo incroot='${INCROOT}'
18437 usrlibdir:
18438 @echo usrlibdir='${USRLIBDIR}'
18439 libdir:
18440 @echo libdir='${LIBDIR}'
18441 _ACEOF
18442 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
18443 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
18444 for ac_var in incroot usrlibdir libdir; do
18445 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
18446 done
18447 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
18448 for ac_extension in a so sl dylib la dll; do
18449 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
18450 test -f "$ac_im_libdir/libX11.$ac_extension"; then
18451 ac_im_usrlibdir=$ac_im_libdir; break
18453 done
18454 # Screen out bogus values from the imake configuration. They are
18455 # bogus both because they are the default anyway, and because
18456 # using them would break gcc on systems where it needs fixed includes.
18457 case $ac_im_incroot in
18458 /usr/include) ac_x_includes= ;;
18459 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
18460 esac
18461 case $ac_im_usrlibdir in
18462 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
18463 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
18464 esac
18466 cd ..
18467 rm -f -r conftest.dir
18470 # Standard set of common directories for X headers.
18471 # Check X11 before X11Rn because it is often a symlink to the current release.
18472 ac_x_header_dirs='
18473 /usr/X11/include
18474 /usr/X11R7/include
18475 /usr/X11R6/include
18476 /usr/X11R5/include
18477 /usr/X11R4/include
18479 /usr/include/X11
18480 /usr/include/X11R7
18481 /usr/include/X11R6
18482 /usr/include/X11R5
18483 /usr/include/X11R4
18485 /usr/local/X11/include
18486 /usr/local/X11R7/include
18487 /usr/local/X11R6/include
18488 /usr/local/X11R5/include
18489 /usr/local/X11R4/include
18491 /usr/local/include/X11
18492 /usr/local/include/X11R7
18493 /usr/local/include/X11R6
18494 /usr/local/include/X11R5
18495 /usr/local/include/X11R4
18497 /usr/X386/include
18498 /usr/x386/include
18499 /usr/XFree86/include/X11
18501 /usr/include
18502 /usr/local/include
18503 /usr/unsupported/include
18504 /usr/athena/include
18505 /usr/local/x11r5/include
18506 /usr/lpp/Xamples/include
18508 /usr/openwin/include
18509 /usr/openwin/share/include'
18511 if test "$ac_x_includes" = no; then
18512 # Guess where to find include files, by looking for Xlib.h.
18513 # First, try using that file with no special directory specified.
18514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18515 /* end confdefs.h. */
18516 #include <X11/Xlib.h>
18517 _ACEOF
18518 if ac_fn_c_try_cpp "$LINENO"; then :
18519 # We can compile using X headers with no special include directory.
18520 ac_x_includes=
18521 else
18522 for ac_dir in $ac_x_header_dirs; do
18523 if test -r "$ac_dir/X11/Xlib.h"; then
18524 ac_x_includes=$ac_dir
18525 break
18527 done
18529 rm -f conftest.err conftest.i conftest.$ac_ext
18530 fi # $ac_x_includes = no
18532 if test "$ac_x_libraries" = no; then
18533 # Check for the libraries.
18534 # See if we find them without any special options.
18535 # Don't add to $LIBS permanently.
18536 ac_save_LIBS=$LIBS
18537 LIBS="-lX11 $LIBS"
18538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18539 /* end confdefs.h. */
18540 #include <X11/Xlib.h>
18542 main ()
18544 XrmInitialize ()
18546 return 0;
18548 _ACEOF
18549 if ac_fn_c_try_link "$LINENO"; then :
18550 LIBS=$ac_save_LIBS
18551 # We can link X programs with no special library path.
18552 ac_x_libraries=
18553 else
18554 LIBS=$ac_save_LIBS
18555 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
18557 # Don't even attempt the hair of trying to link an X program!
18558 for ac_extension in a so sl dylib la dll; do
18559 if test -r "$ac_dir/libX11.$ac_extension"; then
18560 ac_x_libraries=$ac_dir
18561 break 2
18563 done
18564 done
18566 rm -f core conftest.err conftest.$ac_objext \
18567 conftest$ac_exeext conftest.$ac_ext
18568 fi # $ac_x_libraries = no
18570 case $ac_x_includes,$ac_x_libraries in #(
18571 no,* | *,no | *\'*)
18572 # Didn't find X, or a directory has "'" in its name.
18573 ac_cv_have_x="have_x=no";; #(
18575 # Record where we found X for the cache.
18576 ac_cv_have_x="have_x=yes\
18577 ac_x_includes='$ac_x_includes'\
18578 ac_x_libraries='$ac_x_libraries'"
18579 esac
18581 ;; #(
18582 *) have_x=yes;;
18583 esac
18584 eval "$ac_cv_have_x"
18585 fi # $with_x != no
18587 if test "$have_x" != yes; then
18588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
18589 $as_echo "$have_x" >&6; }
18590 no_x=yes
18591 else
18592 # If each of the values was on the command line, it overrides each guess.
18593 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
18594 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
18595 # Update the cache value to reflect the command line values.
18596 ac_cv_have_x="have_x=yes\
18597 ac_x_includes='$x_includes'\
18598 ac_x_libraries='$x_libraries'"
18599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
18600 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
18604 # Unlike the sim directory, whether a simulator is linked is controlled by
18605 # presence of a gdb_sim definition in the target configure.tgt entry.
18606 # This code just checks for a few cases where we'd like to ignore those
18607 # definitions, even when they're present in the '.mt' file. These cases
18608 # are when --disable-sim is specified, or if the simulator directory is
18609 # not part of the source tree.
18611 # Check whether --enable-sim was given.
18612 if test "${enable_sim+set}" = set; then :
18613 enableval=$enable_sim; echo "enable_sim = $enable_sim";
18614 echo "enableval = ${enableval}";
18615 case "${enableval}" in
18616 yes) ignore_sim=false ;;
18617 no) ignore_sim=true ;;
18618 *) ignore_sim=false ;;
18619 esac
18620 else
18621 ignore_sim=false
18625 if test ! -d "${srcdir}/../sim"; then
18626 ignore_sim=true
18629 SIM=
18630 SIM_OBS=
18631 if test "${ignore_sim}" = "false"; then
18632 if test x"${gdb_sim}" != x ; then
18633 SIM="${gdb_sim}"
18634 SIM_OBS="remote-sim.o"
18636 $as_echo "#define WITH_SIM 1" >>confdefs.h
18639 # Some tdep code should only be compiled in when the ppc sim is
18640 # built. PR sim/13418.
18641 case $target in
18642 powerpc*-*-*)
18644 $as_echo "#define WITH_PPC_SIM 1" >>confdefs.h
18647 esac
18664 # List of host floatformats.
18666 cat >>confdefs.h <<_ACEOF
18667 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
18668 _ACEOF
18671 cat >>confdefs.h <<_ACEOF
18672 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
18673 _ACEOF
18676 cat >>confdefs.h <<_ACEOF
18677 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
18678 _ACEOF
18681 # target_subdir is used by the testsuite to find the target libraries.
18682 target_subdir=
18683 if test "${host}" != "${target}"; then
18684 target_subdir="${target_alias}/"
18688 # Import nat definitions.
18689 nat_makefile_frag=/dev/null
18690 if test "${gdb_native}" = "yes"; then
18691 . ${srcdir}/configure.nat
18692 nativefile=$NAT_FILE
18705 if test x"${gdb_osabi}" != x ; then
18707 cat >>confdefs.h <<_ACEOF
18708 #define GDB_OSABI_DEFAULT $gdb_osabi
18709 _ACEOF
18713 # Check for babeltrace and babeltrace-ctf
18715 # Check whether --with-babeltrace was given.
18716 if test "${with_babeltrace+set}" = set; then :
18717 withval=$with_babeltrace;
18718 else
18719 with_babeltrace=auto
18722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use babeltrace" >&5
18723 $as_echo_n "checking whether to use babeltrace... " >&6; }
18724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_babeltrace" >&5
18725 $as_echo "$with_babeltrace" >&6; }
18727 if test "x$with_babeltrace" = "xno"; then
18728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&5
18729 $as_echo "$as_me: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&2;}
18730 else
18731 # Append -Werror to CFLAGS so that configure can catch the warning
18732 # "assignment from incompatible pointer type", which is related to
18733 # the babeltrace change from 1.0.3 to 1.1.0. Babeltrace 1.1.0 works
18734 # in GDB, while babeltrace 1.0.3 is broken.
18735 # AC_LIB_HAVE_LINKFLAGS may modify CPPFLAGS in it, so it should be
18736 # safe to save and restore CFLAGS here.
18737 saved_CFLAGS=$CFLAGS
18738 CFLAGS="$CFLAGS -Werror"
18747 use_additional=yes
18749 acl_save_prefix="$prefix"
18750 prefix="$acl_final_prefix"
18751 acl_save_exec_prefix="$exec_prefix"
18752 exec_prefix="$acl_final_exec_prefix"
18754 eval additional_includedir=\"$includedir\"
18755 eval additional_libdir=\"$libdir\"
18757 exec_prefix="$acl_save_exec_prefix"
18758 prefix="$acl_save_prefix"
18761 # Check whether --with-libbabeltrace-prefix was given.
18762 if test "${with_libbabeltrace_prefix+set}" = set; then :
18763 withval=$with_libbabeltrace_prefix;
18764 if test "X$withval" = "Xno"; then
18765 use_additional=no
18766 else
18767 if test "X$withval" = "X"; then
18769 acl_save_prefix="$prefix"
18770 prefix="$acl_final_prefix"
18771 acl_save_exec_prefix="$exec_prefix"
18772 exec_prefix="$acl_final_exec_prefix"
18774 eval additional_includedir=\"$includedir\"
18775 eval additional_libdir=\"$libdir\"
18777 exec_prefix="$acl_save_exec_prefix"
18778 prefix="$acl_save_prefix"
18780 else
18781 additional_includedir="$withval/include"
18782 additional_libdir="$withval/lib"
18789 # Check whether --with-libbabeltrace-type was given.
18790 if test "${with_libbabeltrace_type+set}" = set; then :
18791 withval=$with_libbabeltrace_type; with_libbabeltrace_type=$withval
18792 else
18793 with_libbabeltrace_type=auto
18796 lib_type=`eval echo \$with_libbabeltrace_type`
18798 LIBBABELTRACE=
18799 LTLIBBABELTRACE=
18800 INCBABELTRACE=
18801 rpathdirs=
18802 ltrpathdirs=
18803 names_already_handled=
18804 names_next_round='babeltrace babeltrace-ctf'
18805 while test -n "$names_next_round"; do
18806 names_this_round="$names_next_round"
18807 names_next_round=
18808 for name in $names_this_round; do
18809 already_handled=
18810 for n in $names_already_handled; do
18811 if test "$n" = "$name"; then
18812 already_handled=yes
18813 break
18815 done
18816 if test -z "$already_handled"; then
18817 names_already_handled="$names_already_handled $name"
18818 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
18819 eval value=\"\$HAVE_LIB$uppername\"
18820 if test -n "$value"; then
18821 if test "$value" = yes; then
18822 eval value=\"\$LIB$uppername\"
18823 test -z "$value" || LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$value"
18824 eval value=\"\$LTLIB$uppername\"
18825 test -z "$value" || LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$value"
18826 else
18829 else
18830 found_dir=
18831 found_la=
18832 found_so=
18833 found_a=
18834 if test $use_additional = yes; then
18835 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
18836 found_dir="$additional_libdir"
18837 found_so="$additional_libdir/lib$name.$shlibext"
18838 if test -f "$additional_libdir/lib$name.la"; then
18839 found_la="$additional_libdir/lib$name.la"
18841 elif test x$lib_type != xshared; then
18842 if test -f "$additional_libdir/lib$name.$libext"; then
18843 found_dir="$additional_libdir"
18844 found_a="$additional_libdir/lib$name.$libext"
18845 if test -f "$additional_libdir/lib$name.la"; then
18846 found_la="$additional_libdir/lib$name.la"
18851 if test "X$found_dir" = "X"; then
18852 for x in $LDFLAGS $LTLIBBABELTRACE; do
18854 acl_save_prefix="$prefix"
18855 prefix="$acl_final_prefix"
18856 acl_save_exec_prefix="$exec_prefix"
18857 exec_prefix="$acl_final_exec_prefix"
18858 eval x=\"$x\"
18859 exec_prefix="$acl_save_exec_prefix"
18860 prefix="$acl_save_prefix"
18862 case "$x" in
18863 -L*)
18864 dir=`echo "X$x" | sed -e 's/^X-L//'`
18865 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
18866 found_dir="$dir"
18867 found_so="$dir/lib$name.$shlibext"
18868 if test -f "$dir/lib$name.la"; then
18869 found_la="$dir/lib$name.la"
18871 elif test x$lib_type != xshared; then
18872 if test -f "$dir/lib$name.$libext"; then
18873 found_dir="$dir"
18874 found_a="$dir/lib$name.$libext"
18875 if test -f "$dir/lib$name.la"; then
18876 found_la="$dir/lib$name.la"
18881 esac
18882 if test "X$found_dir" != "X"; then
18883 break
18885 done
18887 if test "X$found_dir" != "X"; then
18888 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$found_dir -l$name"
18889 if test "X$found_so" != "X"; then
18890 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
18891 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
18892 else
18893 haveit=
18894 for x in $ltrpathdirs; do
18895 if test "X$x" = "X$found_dir"; then
18896 haveit=yes
18897 break
18899 done
18900 if test -z "$haveit"; then
18901 ltrpathdirs="$ltrpathdirs $found_dir"
18903 if test "$hardcode_direct" = yes; then
18904 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
18905 else
18906 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
18907 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
18908 haveit=
18909 for x in $rpathdirs; do
18910 if test "X$x" = "X$found_dir"; then
18911 haveit=yes
18912 break
18914 done
18915 if test -z "$haveit"; then
18916 rpathdirs="$rpathdirs $found_dir"
18918 else
18919 haveit=
18920 for x in $LDFLAGS $LIBBABELTRACE; do
18922 acl_save_prefix="$prefix"
18923 prefix="$acl_final_prefix"
18924 acl_save_exec_prefix="$exec_prefix"
18925 exec_prefix="$acl_final_exec_prefix"
18926 eval x=\"$x\"
18927 exec_prefix="$acl_save_exec_prefix"
18928 prefix="$acl_save_prefix"
18930 if test "X$x" = "X-L$found_dir"; then
18931 haveit=yes
18932 break
18934 done
18935 if test -z "$haveit"; then
18936 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir"
18938 if test "$hardcode_minus_L" != no; then
18939 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
18940 else
18941 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
18946 else
18947 if test "X$found_a" != "X"; then
18948 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_a"
18949 else
18950 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir -l$name"
18953 additional_includedir=
18954 case "$found_dir" in
18955 */lib | */lib/)
18956 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
18957 additional_includedir="$basedir/include"
18959 esac
18960 if test "X$additional_includedir" != "X"; then
18961 if test "X$additional_includedir" != "X/usr/include"; then
18962 haveit=
18963 if test "X$additional_includedir" = "X/usr/local/include"; then
18964 if test -n "$GCC"; then
18965 case $host_os in
18966 linux*) haveit=yes;;
18967 esac
18970 if test -z "$haveit"; then
18971 for x in $CPPFLAGS $INCBABELTRACE; do
18973 acl_save_prefix="$prefix"
18974 prefix="$acl_final_prefix"
18975 acl_save_exec_prefix="$exec_prefix"
18976 exec_prefix="$acl_final_exec_prefix"
18977 eval x=\"$x\"
18978 exec_prefix="$acl_save_exec_prefix"
18979 prefix="$acl_save_prefix"
18981 if test "X$x" = "X-I$additional_includedir"; then
18982 haveit=yes
18983 break
18985 done
18986 if test -z "$haveit"; then
18987 if test -d "$additional_includedir"; then
18988 INCBABELTRACE="${INCBABELTRACE}${INCBABELTRACE:+ }-I$additional_includedir"
18994 if test -n "$found_la"; then
18995 save_libdir="$libdir"
18996 case "$found_la" in
18997 */* | *\\*) . "$found_la" ;;
18998 *) . "./$found_la" ;;
18999 esac
19000 libdir="$save_libdir"
19001 for dep in $dependency_libs; do
19002 case "$dep" in
19003 -L*)
19004 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
19005 if test "X$additional_libdir" != "X/usr/lib"; then
19006 haveit=
19007 if test "X$additional_libdir" = "X/usr/local/lib"; then
19008 if test -n "$GCC"; then
19009 case $host_os in
19010 linux*) haveit=yes;;
19011 esac
19014 if test -z "$haveit"; then
19015 haveit=
19016 for x in $LDFLAGS $LIBBABELTRACE; do
19018 acl_save_prefix="$prefix"
19019 prefix="$acl_final_prefix"
19020 acl_save_exec_prefix="$exec_prefix"
19021 exec_prefix="$acl_final_exec_prefix"
19022 eval x=\"$x\"
19023 exec_prefix="$acl_save_exec_prefix"
19024 prefix="$acl_save_prefix"
19026 if test "X$x" = "X-L$additional_libdir"; then
19027 haveit=yes
19028 break
19030 done
19031 if test -z "$haveit"; then
19032 if test -d "$additional_libdir"; then
19033 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$additional_libdir"
19036 haveit=
19037 for x in $LDFLAGS $LTLIBBABELTRACE; do
19039 acl_save_prefix="$prefix"
19040 prefix="$acl_final_prefix"
19041 acl_save_exec_prefix="$exec_prefix"
19042 exec_prefix="$acl_final_exec_prefix"
19043 eval x=\"$x\"
19044 exec_prefix="$acl_save_exec_prefix"
19045 prefix="$acl_save_prefix"
19047 if test "X$x" = "X-L$additional_libdir"; then
19048 haveit=yes
19049 break
19051 done
19052 if test -z "$haveit"; then
19053 if test -d "$additional_libdir"; then
19054 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$additional_libdir"
19060 -R*)
19061 dir=`echo "X$dep" | sed -e 's/^X-R//'`
19062 if test "$enable_rpath" != no; then
19063 haveit=
19064 for x in $rpathdirs; do
19065 if test "X$x" = "X$dir"; then
19066 haveit=yes
19067 break
19069 done
19070 if test -z "$haveit"; then
19071 rpathdirs="$rpathdirs $dir"
19073 haveit=
19074 for x in $ltrpathdirs; do
19075 if test "X$x" = "X$dir"; then
19076 haveit=yes
19077 break
19079 done
19080 if test -z "$haveit"; then
19081 ltrpathdirs="$ltrpathdirs $dir"
19085 -l*)
19086 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
19088 *.la)
19089 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
19092 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$dep"
19093 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$dep"
19095 esac
19096 done
19098 else
19099 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
19100 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
19101 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l$name"
19102 else
19103 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l:lib$name.$libext"
19104 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l:lib$name.$libext"
19109 done
19110 done
19111 if test "X$rpathdirs" != "X"; then
19112 if test -n "$hardcode_libdir_separator"; then
19113 alldirs=
19114 for found_dir in $rpathdirs; do
19115 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
19116 done
19117 acl_save_libdir="$libdir"
19118 libdir="$alldirs"
19119 eval flag=\"$hardcode_libdir_flag_spec\"
19120 libdir="$acl_save_libdir"
19121 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
19122 else
19123 for found_dir in $rpathdirs; do
19124 acl_save_libdir="$libdir"
19125 libdir="$found_dir"
19126 eval flag=\"$hardcode_libdir_flag_spec\"
19127 libdir="$acl_save_libdir"
19128 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
19129 done
19132 if test "X$ltrpathdirs" != "X"; then
19133 for found_dir in $ltrpathdirs; do
19134 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-R$found_dir"
19135 done
19139 ac_save_CPPFLAGS="$CPPFLAGS"
19141 for element in $INCBABELTRACE; do
19142 haveit=
19143 for x in $CPPFLAGS; do
19145 acl_save_prefix="$prefix"
19146 prefix="$acl_final_prefix"
19147 acl_save_exec_prefix="$exec_prefix"
19148 exec_prefix="$acl_final_exec_prefix"
19149 eval x=\"$x\"
19150 exec_prefix="$acl_save_exec_prefix"
19151 prefix="$acl_save_prefix"
19153 if test "X$x" = "X$element"; then
19154 haveit=yes
19155 break
19157 done
19158 if test -z "$haveit"; then
19159 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
19161 done
19164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbabeltrace" >&5
19165 $as_echo_n "checking for libbabeltrace... " >&6; }
19166 if ${ac_cv_libbabeltrace+:} false; then :
19167 $as_echo_n "(cached) " >&6
19168 else
19170 ac_save_LIBS="$LIBS"
19171 LIBS="$LIBS $LIBBABELTRACE"
19172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19173 /* end confdefs.h. */
19174 #include <babeltrace/babeltrace.h>
19175 #include <babeltrace/ctf/events.h>
19176 #include <babeltrace/ctf/iterator.h>
19178 main ()
19180 struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL));
19181 struct bt_ctf_event *event = NULL;
19182 const struct bt_definition *scope;
19184 pos->type = BT_SEEK_BEGIN;
19185 bt_iter_set_pos (bt_ctf_get_iter (NULL), pos);
19186 scope = bt_ctf_get_top_level_scope (event,
19187 BT_STREAM_EVENT_HEADER);
19188 bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));
19191 return 0;
19193 _ACEOF
19194 if ac_fn_c_try_link "$LINENO"; then :
19195 ac_cv_libbabeltrace=yes
19196 else
19197 ac_cv_libbabeltrace=no
19199 rm -f core conftest.err conftest.$ac_objext \
19200 conftest$ac_exeext conftest.$ac_ext
19201 LIBS="$ac_save_LIBS"
19204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libbabeltrace" >&5
19205 $as_echo "$ac_cv_libbabeltrace" >&6; }
19206 if test "$ac_cv_libbabeltrace" = yes; then
19207 HAVE_LIBBABELTRACE=yes
19209 $as_echo "#define HAVE_LIBBABELTRACE 1" >>confdefs.h
19211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libbabeltrace" >&5
19212 $as_echo_n "checking how to link with libbabeltrace... " >&6; }
19213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBBABELTRACE" >&5
19214 $as_echo "$LIBBABELTRACE" >&6; }
19215 else
19216 HAVE_LIBBABELTRACE=no
19217 CPPFLAGS="$ac_save_CPPFLAGS"
19218 LIBBABELTRACE=
19219 LTLIBBABELTRACE=
19227 CFLAGS=$saved_CFLAGS
19229 if test "$HAVE_LIBBABELTRACE" != yes; then
19230 if test "$with_babeltrace" = yes; then
19231 as_fn_error $? "babeltrace is missing or unusable" "$LINENO" 5
19232 else
19233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&5
19234 $as_echo "$as_me: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&2;}
19239 # Check for xxhash
19241 # Check whether --with-xxhash was given.
19242 if test "${with_xxhash+set}" = set; then :
19243 withval=$with_xxhash;
19244 else
19245 with_xxhash=auto
19249 # Check whether --enable-libctf was given.
19250 if test "${enable_libctf+set}" = set; then :
19251 enableval=$enable_libctf;
19252 case "$enableval" in
19253 yes|no) ;;
19254 *) as_fn_error $? "Argument to enable/disable libctf must be yes or no" "$LINENO" 5 ;;
19255 esac
19257 else
19258 enable_libctf=yes
19262 if test x${enable_static} = xno; then
19263 LIBCTF="-Wl,--rpath,../libctf/.libs ../libctf/.libs/libctf.so"
19264 CTF_DEPS="../libctf/.libs/libctf.so"
19265 else
19266 LIBCTF="../libctf/.libs/libctf.a"
19267 CTF_DEPS="$LIBCTF"
19269 if test "${enable_libctf}" = yes; then
19271 $as_echo "#define ENABLE_LIBCTF 1" >>confdefs.h
19273 else
19274 LIBCTF=
19275 CTF_DEPS=
19281 # If nativefile (NAT_FILE) is not set in configure.nat, we link to an
19282 # empty version.
19284 if test "x$with_xxhash" != "xno"; then
19293 use_additional=yes
19295 acl_save_prefix="$prefix"
19296 prefix="$acl_final_prefix"
19297 acl_save_exec_prefix="$exec_prefix"
19298 exec_prefix="$acl_final_exec_prefix"
19300 eval additional_includedir=\"$includedir\"
19301 eval additional_libdir=\"$libdir\"
19303 exec_prefix="$acl_save_exec_prefix"
19304 prefix="$acl_save_prefix"
19307 # Check whether --with-libxxhash-prefix was given.
19308 if test "${with_libxxhash_prefix+set}" = set; then :
19309 withval=$with_libxxhash_prefix;
19310 if test "X$withval" = "Xno"; then
19311 use_additional=no
19312 else
19313 if test "X$withval" = "X"; then
19315 acl_save_prefix="$prefix"
19316 prefix="$acl_final_prefix"
19317 acl_save_exec_prefix="$exec_prefix"
19318 exec_prefix="$acl_final_exec_prefix"
19320 eval additional_includedir=\"$includedir\"
19321 eval additional_libdir=\"$libdir\"
19323 exec_prefix="$acl_save_exec_prefix"
19324 prefix="$acl_save_prefix"
19326 else
19327 additional_includedir="$withval/include"
19328 additional_libdir="$withval/lib"
19335 # Check whether --with-libxxhash-type was given.
19336 if test "${with_libxxhash_type+set}" = set; then :
19337 withval=$with_libxxhash_type; with_libxxhash_type=$withval
19338 else
19339 with_libxxhash_type=auto
19342 lib_type=`eval echo \$with_libxxhash_type`
19344 LIBXXHASH=
19345 LTLIBXXHASH=
19346 INCXXHASH=
19347 rpathdirs=
19348 ltrpathdirs=
19349 names_already_handled=
19350 names_next_round='xxhash '
19351 while test -n "$names_next_round"; do
19352 names_this_round="$names_next_round"
19353 names_next_round=
19354 for name in $names_this_round; do
19355 already_handled=
19356 for n in $names_already_handled; do
19357 if test "$n" = "$name"; then
19358 already_handled=yes
19359 break
19361 done
19362 if test -z "$already_handled"; then
19363 names_already_handled="$names_already_handled $name"
19364 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
19365 eval value=\"\$HAVE_LIB$uppername\"
19366 if test -n "$value"; then
19367 if test "$value" = yes; then
19368 eval value=\"\$LIB$uppername\"
19369 test -z "$value" || LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$value"
19370 eval value=\"\$LTLIB$uppername\"
19371 test -z "$value" || LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$value"
19372 else
19375 else
19376 found_dir=
19377 found_la=
19378 found_so=
19379 found_a=
19380 if test $use_additional = yes; then
19381 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
19382 found_dir="$additional_libdir"
19383 found_so="$additional_libdir/lib$name.$shlibext"
19384 if test -f "$additional_libdir/lib$name.la"; then
19385 found_la="$additional_libdir/lib$name.la"
19387 elif test x$lib_type != xshared; then
19388 if test -f "$additional_libdir/lib$name.$libext"; then
19389 found_dir="$additional_libdir"
19390 found_a="$additional_libdir/lib$name.$libext"
19391 if test -f "$additional_libdir/lib$name.la"; then
19392 found_la="$additional_libdir/lib$name.la"
19397 if test "X$found_dir" = "X"; then
19398 for x in $LDFLAGS $LTLIBXXHASH; do
19400 acl_save_prefix="$prefix"
19401 prefix="$acl_final_prefix"
19402 acl_save_exec_prefix="$exec_prefix"
19403 exec_prefix="$acl_final_exec_prefix"
19404 eval x=\"$x\"
19405 exec_prefix="$acl_save_exec_prefix"
19406 prefix="$acl_save_prefix"
19408 case "$x" in
19409 -L*)
19410 dir=`echo "X$x" | sed -e 's/^X-L//'`
19411 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
19412 found_dir="$dir"
19413 found_so="$dir/lib$name.$shlibext"
19414 if test -f "$dir/lib$name.la"; then
19415 found_la="$dir/lib$name.la"
19417 elif test x$lib_type != xshared; then
19418 if test -f "$dir/lib$name.$libext"; then
19419 found_dir="$dir"
19420 found_a="$dir/lib$name.$libext"
19421 if test -f "$dir/lib$name.la"; then
19422 found_la="$dir/lib$name.la"
19427 esac
19428 if test "X$found_dir" != "X"; then
19429 break
19431 done
19433 if test "X$found_dir" != "X"; then
19434 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$found_dir -l$name"
19435 if test "X$found_so" != "X"; then
19436 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
19437 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
19438 else
19439 haveit=
19440 for x in $ltrpathdirs; do
19441 if test "X$x" = "X$found_dir"; then
19442 haveit=yes
19443 break
19445 done
19446 if test -z "$haveit"; then
19447 ltrpathdirs="$ltrpathdirs $found_dir"
19449 if test "$hardcode_direct" = yes; then
19450 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
19451 else
19452 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
19453 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
19454 haveit=
19455 for x in $rpathdirs; do
19456 if test "X$x" = "X$found_dir"; then
19457 haveit=yes
19458 break
19460 done
19461 if test -z "$haveit"; then
19462 rpathdirs="$rpathdirs $found_dir"
19464 else
19465 haveit=
19466 for x in $LDFLAGS $LIBXXHASH; do
19468 acl_save_prefix="$prefix"
19469 prefix="$acl_final_prefix"
19470 acl_save_exec_prefix="$exec_prefix"
19471 exec_prefix="$acl_final_exec_prefix"
19472 eval x=\"$x\"
19473 exec_prefix="$acl_save_exec_prefix"
19474 prefix="$acl_save_prefix"
19476 if test "X$x" = "X-L$found_dir"; then
19477 haveit=yes
19478 break
19480 done
19481 if test -z "$haveit"; then
19482 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir"
19484 if test "$hardcode_minus_L" != no; then
19485 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
19486 else
19487 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
19492 else
19493 if test "X$found_a" != "X"; then
19494 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_a"
19495 else
19496 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir -l$name"
19499 additional_includedir=
19500 case "$found_dir" in
19501 */lib | */lib/)
19502 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
19503 additional_includedir="$basedir/include"
19505 esac
19506 if test "X$additional_includedir" != "X"; then
19507 if test "X$additional_includedir" != "X/usr/include"; then
19508 haveit=
19509 if test "X$additional_includedir" = "X/usr/local/include"; then
19510 if test -n "$GCC"; then
19511 case $host_os in
19512 linux*) haveit=yes;;
19513 esac
19516 if test -z "$haveit"; then
19517 for x in $CPPFLAGS $INCXXHASH; do
19519 acl_save_prefix="$prefix"
19520 prefix="$acl_final_prefix"
19521 acl_save_exec_prefix="$exec_prefix"
19522 exec_prefix="$acl_final_exec_prefix"
19523 eval x=\"$x\"
19524 exec_prefix="$acl_save_exec_prefix"
19525 prefix="$acl_save_prefix"
19527 if test "X$x" = "X-I$additional_includedir"; then
19528 haveit=yes
19529 break
19531 done
19532 if test -z "$haveit"; then
19533 if test -d "$additional_includedir"; then
19534 INCXXHASH="${INCXXHASH}${INCXXHASH:+ }-I$additional_includedir"
19540 if test -n "$found_la"; then
19541 save_libdir="$libdir"
19542 case "$found_la" in
19543 */* | *\\*) . "$found_la" ;;
19544 *) . "./$found_la" ;;
19545 esac
19546 libdir="$save_libdir"
19547 for dep in $dependency_libs; do
19548 case "$dep" in
19549 -L*)
19550 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
19551 if test "X$additional_libdir" != "X/usr/lib"; then
19552 haveit=
19553 if test "X$additional_libdir" = "X/usr/local/lib"; then
19554 if test -n "$GCC"; then
19555 case $host_os in
19556 linux*) haveit=yes;;
19557 esac
19560 if test -z "$haveit"; then
19561 haveit=
19562 for x in $LDFLAGS $LIBXXHASH; do
19564 acl_save_prefix="$prefix"
19565 prefix="$acl_final_prefix"
19566 acl_save_exec_prefix="$exec_prefix"
19567 exec_prefix="$acl_final_exec_prefix"
19568 eval x=\"$x\"
19569 exec_prefix="$acl_save_exec_prefix"
19570 prefix="$acl_save_prefix"
19572 if test "X$x" = "X-L$additional_libdir"; then
19573 haveit=yes
19574 break
19576 done
19577 if test -z "$haveit"; then
19578 if test -d "$additional_libdir"; then
19579 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$additional_libdir"
19582 haveit=
19583 for x in $LDFLAGS $LTLIBXXHASH; do
19585 acl_save_prefix="$prefix"
19586 prefix="$acl_final_prefix"
19587 acl_save_exec_prefix="$exec_prefix"
19588 exec_prefix="$acl_final_exec_prefix"
19589 eval x=\"$x\"
19590 exec_prefix="$acl_save_exec_prefix"
19591 prefix="$acl_save_prefix"
19593 if test "X$x" = "X-L$additional_libdir"; then
19594 haveit=yes
19595 break
19597 done
19598 if test -z "$haveit"; then
19599 if test -d "$additional_libdir"; then
19600 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$additional_libdir"
19606 -R*)
19607 dir=`echo "X$dep" | sed -e 's/^X-R//'`
19608 if test "$enable_rpath" != no; then
19609 haveit=
19610 for x in $rpathdirs; do
19611 if test "X$x" = "X$dir"; then
19612 haveit=yes
19613 break
19615 done
19616 if test -z "$haveit"; then
19617 rpathdirs="$rpathdirs $dir"
19619 haveit=
19620 for x in $ltrpathdirs; do
19621 if test "X$x" = "X$dir"; then
19622 haveit=yes
19623 break
19625 done
19626 if test -z "$haveit"; then
19627 ltrpathdirs="$ltrpathdirs $dir"
19631 -l*)
19632 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
19634 *.la)
19635 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
19638 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$dep"
19639 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$dep"
19641 esac
19642 done
19644 else
19645 if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
19646 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
19647 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l$name"
19648 else
19649 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l:lib$name.$libext"
19650 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l:lib$name.$libext"
19655 done
19656 done
19657 if test "X$rpathdirs" != "X"; then
19658 if test -n "$hardcode_libdir_separator"; then
19659 alldirs=
19660 for found_dir in $rpathdirs; do
19661 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
19662 done
19663 acl_save_libdir="$libdir"
19664 libdir="$alldirs"
19665 eval flag=\"$hardcode_libdir_flag_spec\"
19666 libdir="$acl_save_libdir"
19667 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
19668 else
19669 for found_dir in $rpathdirs; do
19670 acl_save_libdir="$libdir"
19671 libdir="$found_dir"
19672 eval flag=\"$hardcode_libdir_flag_spec\"
19673 libdir="$acl_save_libdir"
19674 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
19675 done
19678 if test "X$ltrpathdirs" != "X"; then
19679 for found_dir in $ltrpathdirs; do
19680 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-R$found_dir"
19681 done
19685 ac_save_CPPFLAGS="$CPPFLAGS"
19687 for element in $INCXXHASH; do
19688 haveit=
19689 for x in $CPPFLAGS; do
19691 acl_save_prefix="$prefix"
19692 prefix="$acl_final_prefix"
19693 acl_save_exec_prefix="$exec_prefix"
19694 exec_prefix="$acl_final_exec_prefix"
19695 eval x=\"$x\"
19696 exec_prefix="$acl_save_exec_prefix"
19697 prefix="$acl_save_prefix"
19699 if test "X$x" = "X$element"; then
19700 haveit=yes
19701 break
19703 done
19704 if test -z "$haveit"; then
19705 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
19707 done
19710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxxhash" >&5
19711 $as_echo_n "checking for libxxhash... " >&6; }
19712 if ${ac_cv_libxxhash+:} false; then :
19713 $as_echo_n "(cached) " >&6
19714 else
19716 ac_save_LIBS="$LIBS"
19717 LIBS="$LIBS $LIBXXHASH"
19718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19719 /* end confdefs.h. */
19720 #include <xxhash.h>
19722 main ()
19724 XXH32("foo", 3, 0);
19727 return 0;
19729 _ACEOF
19730 if ac_fn_c_try_link "$LINENO"; then :
19731 ac_cv_libxxhash=yes
19732 else
19733 ac_cv_libxxhash=no
19735 rm -f core conftest.err conftest.$ac_objext \
19736 conftest$ac_exeext conftest.$ac_ext
19737 LIBS="$ac_save_LIBS"
19740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libxxhash" >&5
19741 $as_echo "$ac_cv_libxxhash" >&6; }
19742 if test "$ac_cv_libxxhash" = yes; then
19743 HAVE_LIBXXHASH=yes
19745 $as_echo "#define HAVE_LIBXXHASH 1" >>confdefs.h
19747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libxxhash" >&5
19748 $as_echo_n "checking how to link with libxxhash... " >&6; }
19749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXXHASH" >&5
19750 $as_echo "$LIBXXHASH" >&6; }
19751 else
19752 HAVE_LIBXXHASH=no
19753 CPPFLAGS="$ac_save_CPPFLAGS"
19754 LIBXXHASH=
19755 LTLIBXXHASH=
19763 if test "$HAVE_LIBXXHASH" != yes; then
19764 if test "$with_xxhash" = yes; then
19765 as_fn_error $? "xxhash is missing or unusable" "$LINENO" 5
19768 if test "x$with_xxhash" = "xauto"; then
19769 with_xxhash="$HAVE_LIBXXHASH"
19773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use xxhash" >&5
19774 $as_echo_n "checking whether to use xxhash... " >&6; }
19775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_xxhash" >&5
19776 $as_echo "$with_xxhash" >&6; }
19778 NM_H=
19779 rm -f nm.h
19780 if test "${nativefile}" != ""; then
19781 case "${nativefile}" in
19782 nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
19783 * ) GDB_NM_FILE="${nativefile}"
19784 esac
19785 ac_config_links="$ac_config_links nm.h:$GDB_NM_FILE"
19788 cat >>confdefs.h <<_ACEOF
19789 #define GDB_NM_FILE "${GDB_NM_FILE}"
19790 _ACEOF
19792 NM_H=nm.h
19797 for ac_prog in xsltproc
19799 # Extract the first word of "$ac_prog", so it can be a program name with args.
19800 set dummy $ac_prog; ac_word=$2
19801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19802 $as_echo_n "checking for $ac_word... " >&6; }
19803 if ${ac_cv_path_XSLTPROC+:} false; then :
19804 $as_echo_n "(cached) " >&6
19805 else
19806 case $XSLTPROC in
19807 [\\/]* | ?:[\\/]*)
19808 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
19811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19812 for as_dir in $PATH
19814 IFS=$as_save_IFS
19815 test -z "$as_dir" && as_dir=.
19816 for ac_exec_ext in '' $ac_executable_extensions; do
19817 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19818 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
19819 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19820 break 2
19822 done
19823 done
19824 IFS=$as_save_IFS
19827 esac
19829 XSLTPROC=$ac_cv_path_XSLTPROC
19830 if test -n "$XSLTPROC"; then
19831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
19832 $as_echo "$XSLTPROC" >&6; }
19833 else
19834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19835 $as_echo "no" >&6; }
19839 test -n "$XSLTPROC" && break
19840 done
19841 test -n "$XSLTPROC" || XSLTPROC="missing"
19843 if test "x$USE_MAINTAINER_MODE" = xyes; then
19844 if test "${XSLTPROC}" = missing; then
19845 as_fn_error $? "unable to find xsltproc. maintainer-mode requires xsltproc." "$LINENO" 5
19853 $as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
19857 # Check whether we will enable the inclusion of unit tests when
19858 # compiling GDB.
19860 # The default value of this option changes depending whether we're on
19861 # development mode (in which case it's "true") or not (in which case
19862 # it's "false"). The $development variable is set by the GDB_AC_COMMON
19863 # macro, which must therefore be used before GDB_AC_SELFTEST.
19865 if test "x$development" != xtrue && test "x$development" != xfalse; then :
19866 as_fn_error $? "Invalid value for \$development, got \"$development\", expecting \"true\" or \"false\"." "$LINENO" 5
19869 # Check whether --enable-unit-tests was given.
19870 if test "${enable_unit_tests+set}" = set; then :
19871 enableval=$enable_unit_tests; case "${enableval}" in
19872 yes) enable_unittests=true ;;
19873 no) enable_unittests=false ;;
19874 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
19875 esac
19876 else
19877 enable_unittests=$development
19881 if $enable_unittests; then
19883 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
19886 CONFIG_OBS="$CONFIG_OBS \$(SELFTESTS_OBS)"
19887 CONFIG_SRCS="$CONFIG_SRCS \$(SELFTESTS_SRCS)"
19893 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
19894 GDB_TRANSFORM_NAME=`echo gdb | sed -e "$gdb_ac_transform"`
19895 if test "x$GDB_TRANSFORM_NAME" = x; then
19896 GDB_TRANSFORM_NAME=gdb
19901 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
19902 GCORE_TRANSFORM_NAME=`echo gcore | sed -e "$gdb_ac_transform"`
19903 if test "x$GCORE_TRANSFORM_NAME" = x; then
19904 GCORE_TRANSFORM_NAME=gcore
19908 ac_config_files="$ac_config_files gcore"
19910 ac_config_files="$ac_config_files Makefile gdb-gdb.gdb gdb-gdb.py doc/Makefile data-directory/Makefile"
19913 cat >confcache <<\_ACEOF
19914 # This file is a shell script that caches the results of configure
19915 # tests run on this system so they can be shared between configure
19916 # scripts and configure runs, see configure's option --config-cache.
19917 # It is not useful on other systems. If it contains results you don't
19918 # want to keep, you may remove or edit it.
19920 # config.status only pays attention to the cache file if you give it
19921 # the --recheck option to rerun configure.
19923 # `ac_cv_env_foo' variables (set or unset) will be overridden when
19924 # loading this file, other *unset* `ac_cv_foo' will be assigned the
19925 # following values.
19927 _ACEOF
19929 # The following way of writing the cache mishandles newlines in values,
19930 # but we know of no workaround that is simple, portable, and efficient.
19931 # So, we kill variables containing newlines.
19932 # Ultrix sh set writes to stderr and can't be redirected directly,
19933 # and sets the high bit in the cache file unless we assign to the vars.
19935 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19936 eval ac_val=\$$ac_var
19937 case $ac_val in #(
19938 *${as_nl}*)
19939 case $ac_var in #(
19940 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19941 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19942 esac
19943 case $ac_var in #(
19944 _ | IFS | as_nl) ;; #(
19945 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19946 *) { eval $ac_var=; unset $ac_var;} ;;
19947 esac ;;
19948 esac
19949 done
19951 (set) 2>&1 |
19952 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19953 *${as_nl}ac_space=\ *)
19954 # `set' does not quote correctly, so add quotes: double-quote
19955 # substitution turns \\\\ into \\, and sed turns \\ into \.
19956 sed -n \
19957 "s/'/'\\\\''/g;
19958 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19959 ;; #(
19961 # `set' quotes correctly as required by POSIX, so do not add quotes.
19962 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19964 esac |
19965 sort
19967 sed '
19968 /^ac_cv_env_/b end
19969 t clear
19970 :clear
19971 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19972 t end
19973 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19974 :end' >>confcache
19975 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19976 if test -w "$cache_file"; then
19977 if test "x$cache_file" != "x/dev/null"; then
19978 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19979 $as_echo "$as_me: updating cache $cache_file" >&6;}
19980 if test ! -f "$cache_file" || test -h "$cache_file"; then
19981 cat confcache >"$cache_file"
19982 else
19983 case $cache_file in #(
19984 */* | ?:*)
19985 mv -f confcache "$cache_file"$$ &&
19986 mv -f "$cache_file"$$ "$cache_file" ;; #(
19988 mv -f confcache "$cache_file" ;;
19989 esac
19992 else
19993 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19994 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19997 rm -f confcache
19999 test "x$prefix" = xNONE && prefix=$ac_default_prefix
20000 # Let make expand exec_prefix.
20001 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
20003 DEFS=-DHAVE_CONFIG_H
20005 ac_libobjs=
20006 ac_ltlibobjs=
20008 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
20009 # 1. Remove the extension, and $U if already installed.
20010 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
20011 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
20012 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
20013 # will be set to the directory where LIBOBJS objects are built.
20014 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
20015 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
20016 done
20017 LIBOBJS=$ac_libobjs
20019 LTLIBOBJS=$ac_ltlibobjs
20022 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
20023 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
20024 Usually this means the macro was only invoked conditionally." "$LINENO" 5
20026 if test -z "${HAVE_PYTHON_TRUE}" && test -z "${HAVE_PYTHON_FALSE}"; then
20027 as_fn_error $? "conditional \"HAVE_PYTHON\" was never defined.
20028 Usually this means the macro was only invoked conditionally." "$LINENO" 5
20030 if test -z "${HAVE_GUILE_TRUE}" && test -z "${HAVE_GUILE_FALSE}"; then
20031 as_fn_error $? "conditional \"HAVE_GUILE\" was never defined.
20032 Usually this means the macro was only invoked conditionally." "$LINENO" 5
20036 : "${CONFIG_STATUS=./config.status}"
20037 ac_write_fail=0
20038 ac_clean_files_save=$ac_clean_files
20039 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
20040 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
20041 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
20042 as_write_fail=0
20043 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
20044 #! $SHELL
20045 # Generated by $as_me.
20046 # Run this file to recreate the current configuration.
20047 # Compiler output produced by configure, useful for debugging
20048 # configure, is in config.log if it exists.
20050 debug=false
20051 ac_cs_recheck=false
20052 ac_cs_silent=false
20054 SHELL=\${CONFIG_SHELL-$SHELL}
20055 export SHELL
20056 _ASEOF
20057 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
20058 ## -------------------- ##
20059 ## M4sh Initialization. ##
20060 ## -------------------- ##
20062 # Be more Bourne compatible
20063 DUALCASE=1; export DUALCASE # for MKS sh
20064 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20065 emulate sh
20066 NULLCMD=:
20067 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
20068 # is contrary to our usage. Disable this feature.
20069 alias -g '${1+"$@"}'='"$@"'
20070 setopt NO_GLOB_SUBST
20071 else
20072 case `(set -o) 2>/dev/null` in #(
20073 *posix*) :
20074 set -o posix ;; #(
20075 *) :
20077 esac
20081 as_nl='
20083 export as_nl
20084 # Printing a long string crashes Solaris 7 /usr/bin/printf.
20085 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
20086 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
20087 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
20088 # Prefer a ksh shell builtin over an external printf program on Solaris,
20089 # but without wasting forks for bash or zsh.
20090 if test -z "$BASH_VERSION$ZSH_VERSION" \
20091 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
20092 as_echo='print -r --'
20093 as_echo_n='print -rn --'
20094 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
20095 as_echo='printf %s\n'
20096 as_echo_n='printf %s'
20097 else
20098 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
20099 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
20100 as_echo_n='/usr/ucb/echo -n'
20101 else
20102 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
20103 as_echo_n_body='eval
20104 arg=$1;
20105 case $arg in #(
20106 *"$as_nl"*)
20107 expr "X$arg" : "X\\(.*\\)$as_nl";
20108 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
20109 esac;
20110 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
20112 export as_echo_n_body
20113 as_echo_n='sh -c $as_echo_n_body as_echo'
20115 export as_echo_body
20116 as_echo='sh -c $as_echo_body as_echo'
20119 # The user is always right.
20120 if test "${PATH_SEPARATOR+set}" != set; then
20121 PATH_SEPARATOR=:
20122 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
20123 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
20124 PATH_SEPARATOR=';'
20129 # IFS
20130 # We need space, tab and new line, in precisely that order. Quoting is
20131 # there to prevent editors from complaining about space-tab.
20132 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
20133 # splitting by setting IFS to empty value.)
20134 IFS=" "" $as_nl"
20136 # Find who we are. Look in the path if we contain no directory separator.
20137 as_myself=
20138 case $0 in #((
20139 *[\\/]* ) as_myself=$0 ;;
20140 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20141 for as_dir in $PATH
20143 IFS=$as_save_IFS
20144 test -z "$as_dir" && as_dir=.
20145 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
20146 done
20147 IFS=$as_save_IFS
20150 esac
20151 # We did not find ourselves, most probably we were run as `sh COMMAND'
20152 # in which case we are not to be found in the path.
20153 if test "x$as_myself" = x; then
20154 as_myself=$0
20156 if test ! -f "$as_myself"; then
20157 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
20158 exit 1
20161 # Unset variables that we do not need and which cause bugs (e.g. in
20162 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
20163 # suppresses any "Segmentation fault" message there. '((' could
20164 # trigger a bug in pdksh 5.2.14.
20165 for as_var in BASH_ENV ENV MAIL MAILPATH
20166 do eval test x\${$as_var+set} = xset \
20167 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
20168 done
20169 PS1='$ '
20170 PS2='> '
20171 PS4='+ '
20173 # NLS nuisances.
20174 LC_ALL=C
20175 export LC_ALL
20176 LANGUAGE=C
20177 export LANGUAGE
20179 # CDPATH.
20180 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
20183 # as_fn_error STATUS ERROR [LINENO LOG_FD]
20184 # ----------------------------------------
20185 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
20186 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
20187 # script with STATUS, using 1 if that was 0.
20188 as_fn_error ()
20190 as_status=$1; test $as_status -eq 0 && as_status=1
20191 if test "$4"; then
20192 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
20193 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
20195 $as_echo "$as_me: error: $2" >&2
20196 as_fn_exit $as_status
20197 } # as_fn_error
20200 # as_fn_set_status STATUS
20201 # -----------------------
20202 # Set $? to STATUS, without forking.
20203 as_fn_set_status ()
20205 return $1
20206 } # as_fn_set_status
20208 # as_fn_exit STATUS
20209 # -----------------
20210 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
20211 as_fn_exit ()
20213 set +e
20214 as_fn_set_status $1
20215 exit $1
20216 } # as_fn_exit
20218 # as_fn_unset VAR
20219 # ---------------
20220 # Portably unset VAR.
20221 as_fn_unset ()
20223 { eval $1=; unset $1;}
20225 as_unset=as_fn_unset
20226 # as_fn_append VAR VALUE
20227 # ----------------------
20228 # Append the text in VALUE to the end of the definition contained in VAR. Take
20229 # advantage of any shell optimizations that allow amortized linear growth over
20230 # repeated appends, instead of the typical quadratic growth present in naive
20231 # implementations.
20232 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
20233 eval 'as_fn_append ()
20235 eval $1+=\$2
20237 else
20238 as_fn_append ()
20240 eval $1=\$$1\$2
20242 fi # as_fn_append
20244 # as_fn_arith ARG...
20245 # ------------------
20246 # Perform arithmetic evaluation on the ARGs, and store the result in the
20247 # global $as_val. Take advantage of shells that can avoid forks. The arguments
20248 # must be portable across $(()) and expr.
20249 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
20250 eval 'as_fn_arith ()
20252 as_val=$(( $* ))
20254 else
20255 as_fn_arith ()
20257 as_val=`expr "$@" || test $? -eq 1`
20259 fi # as_fn_arith
20262 if expr a : '\(a\)' >/dev/null 2>&1 &&
20263 test "X`expr 00001 : '.*\(...\)'`" = X001; then
20264 as_expr=expr
20265 else
20266 as_expr=false
20269 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
20270 as_basename=basename
20271 else
20272 as_basename=false
20275 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
20276 as_dirname=dirname
20277 else
20278 as_dirname=false
20281 as_me=`$as_basename -- "$0" ||
20282 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
20283 X"$0" : 'X\(//\)$' \| \
20284 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
20285 $as_echo X/"$0" |
20286 sed '/^.*\/\([^/][^/]*\)\/*$/{
20287 s//\1/
20290 /^X\/\(\/\/\)$/{
20291 s//\1/
20294 /^X\/\(\/\).*/{
20295 s//\1/
20298 s/.*/./; q'`
20300 # Avoid depending upon Character Ranges.
20301 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
20302 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
20303 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
20304 as_cr_digits='0123456789'
20305 as_cr_alnum=$as_cr_Letters$as_cr_digits
20307 ECHO_C= ECHO_N= ECHO_T=
20308 case `echo -n x` in #(((((
20309 -n*)
20310 case `echo 'xy\c'` in
20311 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
20312 xy) ECHO_C='\c';;
20313 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
20314 ECHO_T=' ';;
20315 esac;;
20317 ECHO_N='-n';;
20318 esac
20320 rm -f conf$$ conf$$.exe conf$$.file
20321 if test -d conf$$.dir; then
20322 rm -f conf$$.dir/conf$$.file
20323 else
20324 rm -f conf$$.dir
20325 mkdir conf$$.dir 2>/dev/null
20327 if (echo >conf$$.file) 2>/dev/null; then
20328 if ln -s conf$$.file conf$$ 2>/dev/null; then
20329 as_ln_s='ln -s'
20330 # ... but there are two gotchas:
20331 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
20332 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
20333 # In both cases, we have to default to `cp -pR'.
20334 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
20335 as_ln_s='cp -pR'
20336 elif ln conf$$.file conf$$ 2>/dev/null; then
20337 as_ln_s=ln
20338 else
20339 as_ln_s='cp -pR'
20341 else
20342 as_ln_s='cp -pR'
20344 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
20345 rmdir conf$$.dir 2>/dev/null
20348 # as_fn_mkdir_p
20349 # -------------
20350 # Create "$as_dir" as a directory, including parents if necessary.
20351 as_fn_mkdir_p ()
20354 case $as_dir in #(
20355 -*) as_dir=./$as_dir;;
20356 esac
20357 test -d "$as_dir" || eval $as_mkdir_p || {
20358 as_dirs=
20359 while :; do
20360 case $as_dir in #(
20361 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
20362 *) as_qdir=$as_dir;;
20363 esac
20364 as_dirs="'$as_qdir' $as_dirs"
20365 as_dir=`$as_dirname -- "$as_dir" ||
20366 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20367 X"$as_dir" : 'X\(//\)[^/]' \| \
20368 X"$as_dir" : 'X\(//\)$' \| \
20369 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
20370 $as_echo X"$as_dir" |
20371 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20372 s//\1/
20375 /^X\(\/\/\)[^/].*/{
20376 s//\1/
20379 /^X\(\/\/\)$/{
20380 s//\1/
20383 /^X\(\/\).*/{
20384 s//\1/
20387 s/.*/./; q'`
20388 test -d "$as_dir" && break
20389 done
20390 test -z "$as_dirs" || eval "mkdir $as_dirs"
20391 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
20394 } # as_fn_mkdir_p
20395 if mkdir -p . 2>/dev/null; then
20396 as_mkdir_p='mkdir -p "$as_dir"'
20397 else
20398 test -d ./-p && rmdir ./-p
20399 as_mkdir_p=false
20403 # as_fn_executable_p FILE
20404 # -----------------------
20405 # Test if FILE is an executable regular file.
20406 as_fn_executable_p ()
20408 test -f "$1" && test -x "$1"
20409 } # as_fn_executable_p
20410 as_test_x='test -x'
20411 as_executable_p=as_fn_executable_p
20413 # Sed expression to map a string onto a valid CPP name.
20414 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
20416 # Sed expression to map a string onto a valid variable name.
20417 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
20420 exec 6>&1
20421 ## ----------------------------------- ##
20422 ## Main body of $CONFIG_STATUS script. ##
20423 ## ----------------------------------- ##
20424 _ASEOF
20425 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
20427 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20428 # Save the log message, to keep $0 and so on meaningful, and to
20429 # report actual input values of CONFIG_FILES etc. instead of their
20430 # values after options handling.
20431 ac_log="
20432 This file was extended by $as_me, which was
20433 generated by GNU Autoconf 2.69. Invocation command line was
20435 CONFIG_FILES = $CONFIG_FILES
20436 CONFIG_HEADERS = $CONFIG_HEADERS
20437 CONFIG_LINKS = $CONFIG_LINKS
20438 CONFIG_COMMANDS = $CONFIG_COMMANDS
20439 $ $0 $@
20441 on `(hostname || uname -n) 2>/dev/null | sed 1q`
20444 _ACEOF
20446 case $ac_config_files in *"
20447 "*) set x $ac_config_files; shift; ac_config_files=$*;;
20448 esac
20450 case $ac_config_headers in *"
20451 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
20452 esac
20455 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20456 # Files that config.status was made for.
20457 config_files="$ac_config_files"
20458 config_headers="$ac_config_headers"
20459 config_links="$ac_config_links"
20460 config_commands="$ac_config_commands"
20462 _ACEOF
20464 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20465 ac_cs_usage="\
20466 \`$as_me' instantiates files and other configuration actions
20467 from templates according to the current configuration. Unless the files
20468 and actions are specified as TAGs, all are instantiated by default.
20470 Usage: $0 [OPTION]... [TAG]...
20472 -h, --help print this help, then exit
20473 -V, --version print version number and configuration settings, then exit
20474 --config print configuration, then exit
20475 -q, --quiet, --silent
20476 do not print progress messages
20477 -d, --debug don't remove temporary files
20478 --recheck update $as_me by reconfiguring in the same conditions
20479 --file=FILE[:TEMPLATE]
20480 instantiate the configuration file FILE
20481 --header=FILE[:TEMPLATE]
20482 instantiate the configuration header FILE
20484 Configuration files:
20485 $config_files
20487 Configuration headers:
20488 $config_headers
20490 Configuration links:
20491 $config_links
20493 Configuration commands:
20494 $config_commands
20496 Report bugs to the package provider."
20498 _ACEOF
20499 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20500 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
20501 ac_cs_version="\\
20502 config.status
20503 configured by $0, generated by GNU Autoconf 2.69,
20504 with options \\"\$ac_cs_config\\"
20506 Copyright (C) 2012 Free Software Foundation, Inc.
20507 This config.status script is free software; the Free Software Foundation
20508 gives unlimited permission to copy, distribute and modify it."
20510 ac_pwd='$ac_pwd'
20511 srcdir='$srcdir'
20512 INSTALL='$INSTALL'
20513 AWK='$AWK'
20514 test -n "\$AWK" || AWK=awk
20515 _ACEOF
20517 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20518 # The default lists apply if the user does not specify any file.
20519 ac_need_defaults=:
20520 while test $# != 0
20522 case $1 in
20523 --*=?*)
20524 ac_option=`expr "X$1" : 'X\([^=]*\)='`
20525 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
20526 ac_shift=:
20528 --*=)
20529 ac_option=`expr "X$1" : 'X\([^=]*\)='`
20530 ac_optarg=
20531 ac_shift=:
20534 ac_option=$1
20535 ac_optarg=$2
20536 ac_shift=shift
20538 esac
20540 case $ac_option in
20541 # Handling of the options.
20542 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
20543 ac_cs_recheck=: ;;
20544 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
20545 $as_echo "$ac_cs_version"; exit ;;
20546 --config | --confi | --conf | --con | --co | --c )
20547 $as_echo "$ac_cs_config"; exit ;;
20548 --debug | --debu | --deb | --de | --d | -d )
20549 debug=: ;;
20550 --file | --fil | --fi | --f )
20551 $ac_shift
20552 case $ac_optarg in
20553 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
20554 '') as_fn_error $? "missing file argument" ;;
20555 esac
20556 as_fn_append CONFIG_FILES " '$ac_optarg'"
20557 ac_need_defaults=false;;
20558 --header | --heade | --head | --hea )
20559 $ac_shift
20560 case $ac_optarg in
20561 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
20562 esac
20563 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
20564 ac_need_defaults=false;;
20565 --he | --h)
20566 # Conflict between --help and --header
20567 as_fn_error $? "ambiguous option: \`$1'
20568 Try \`$0 --help' for more information.";;
20569 --help | --hel | -h )
20570 $as_echo "$ac_cs_usage"; exit ;;
20571 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
20572 | -silent | --silent | --silen | --sile | --sil | --si | --s)
20573 ac_cs_silent=: ;;
20575 # This is an error.
20576 -*) as_fn_error $? "unrecognized option: \`$1'
20577 Try \`$0 --help' for more information." ;;
20579 *) as_fn_append ac_config_targets " $1"
20580 ac_need_defaults=false ;;
20582 esac
20583 shift
20584 done
20586 ac_configure_extra_args=
20588 if $ac_cs_silent; then
20589 exec 6>/dev/null
20590 ac_configure_extra_args="$ac_configure_extra_args --silent"
20593 _ACEOF
20594 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20595 if \$ac_cs_recheck; then
20596 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
20597 shift
20598 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
20599 CONFIG_SHELL='$SHELL'
20600 export CONFIG_SHELL
20601 exec "\$@"
20604 _ACEOF
20605 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20606 exec 5>>config.log
20608 echo
20609 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
20610 ## Running $as_me. ##
20611 _ASBOX
20612 $as_echo "$ac_log"
20613 } >&5
20615 _ACEOF
20616 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20618 # INIT-COMMANDS
20620 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
20621 GDB_NM_FILE=$GDB_NM_FILE
20623 _ACEOF
20625 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20627 # Handling of arguments.
20628 for ac_config_target in $ac_config_targets
20630 case $ac_config_target in
20631 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
20632 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
20633 "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
20634 "nm.h") CONFIG_LINKS="$CONFIG_LINKS nm.h:$GDB_NM_FILE" ;;
20635 "gcore") CONFIG_FILES="$CONFIG_FILES gcore" ;;
20636 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
20637 "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
20638 "gdb-gdb.py") CONFIG_FILES="$CONFIG_FILES gdb-gdb.py" ;;
20639 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
20640 "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
20642 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
20643 esac
20644 done
20647 # If the user did not use the arguments to specify the items to instantiate,
20648 # then the envvar interface is used. Set only those that are not.
20649 # We use the long form for the default assignment because of an extremely
20650 # bizarre bug on SunOS 4.1.3.
20651 if $ac_need_defaults; then
20652 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
20653 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
20654 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
20655 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
20658 # Have a temporary directory for convenience. Make it in the build tree
20659 # simply because there is no reason against having it here, and in addition,
20660 # creating and moving files from /tmp can sometimes cause problems.
20661 # Hook for its removal unless debugging.
20662 # Note that there is a small window in which the directory will not be cleaned:
20663 # after its creation but before its name has been assigned to `$tmp'.
20664 $debug ||
20666 tmp= ac_tmp=
20667 trap 'exit_status=$?
20668 : "${ac_tmp:=$tmp}"
20669 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
20671 trap 'as_fn_exit 1' 1 2 13 15
20673 # Create a (secure) tmp directory for tmp files.
20676 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
20677 test -d "$tmp"
20678 } ||
20680 tmp=./conf$$-$RANDOM
20681 (umask 077 && mkdir "$tmp")
20682 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
20683 ac_tmp=$tmp
20685 # Set up the scripts for CONFIG_FILES section.
20686 # No need to generate them if there are no CONFIG_FILES.
20687 # This happens for instance with `./config.status config.h'.
20688 if test -n "$CONFIG_FILES"; then
20690 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
20691 ac_cs_awk_getline=:
20692 ac_cs_awk_pipe_init=
20693 ac_cs_awk_read_file='
20694 while ((getline aline < (F[key])) > 0)
20695 print(aline)
20696 close(F[key])'
20697 ac_cs_awk_pipe_fini=
20698 else
20699 ac_cs_awk_getline=false
20700 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
20701 ac_cs_awk_read_file='
20702 print "|#_!!_#|"
20703 print "cat " F[key] " &&"
20704 '$ac_cs_awk_pipe_init
20705 # The final `:' finishes the AND list.
20706 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
20708 ac_cr=`echo X | tr X '\015'`
20709 # On cygwin, bash can eat \r inside `` if the user requested igncr.
20710 # But we know of no other shell where ac_cr would be empty at this
20711 # point, so we can use a bashism as a fallback.
20712 if test "x$ac_cr" = x; then
20713 eval ac_cr=\$\'\\r\'
20715 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
20716 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
20717 ac_cs_awk_cr='\\r'
20718 else
20719 ac_cs_awk_cr=$ac_cr
20722 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
20723 _ACEOF
20725 # Create commands to substitute file output variables.
20727 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
20728 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
20729 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
20730 echo "_ACAWK" &&
20731 echo "_ACEOF"
20732 } >conf$$files.sh &&
20733 . ./conf$$files.sh ||
20734 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20735 rm -f conf$$files.sh
20738 echo "cat >conf$$subs.awk <<_ACEOF" &&
20739 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
20740 echo "_ACEOF"
20741 } >conf$$subs.sh ||
20742 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20743 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
20744 ac_delim='%!_!# '
20745 for ac_last_try in false false false false false :; do
20746 . ./conf$$subs.sh ||
20747 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20749 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
20750 if test $ac_delim_n = $ac_delim_num; then
20751 break
20752 elif $ac_last_try; then
20753 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20754 else
20755 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20757 done
20758 rm -f conf$$subs.sh
20760 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20761 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
20762 _ACEOF
20763 sed -n '
20765 s/^/S["/; s/!.*/"]=/
20768 s/^[^!]*!//
20769 :repl
20770 t repl
20771 s/'"$ac_delim"'$//
20772 t delim
20775 s/\(.\{148\}\)..*/\1/
20776 t more1
20777 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
20780 b repl
20781 :more1
20782 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20785 s/.\{148\}//
20786 t nl
20787 :delim
20789 s/\(.\{148\}\)..*/\1/
20790 t more2
20791 s/["\\]/\\&/g; s/^/"/; s/$/"/
20794 :more2
20795 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20798 s/.\{148\}//
20799 t delim
20800 ' <conf$$subs.awk | sed '
20801 /^[^""]/{
20803 s/\n//
20805 ' >>$CONFIG_STATUS || ac_write_fail=1
20806 rm -f conf$$subs.awk
20807 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20808 _ACAWK
20809 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
20810 for (key in S) S_is_set[key] = 1
20811 FS = "\a"
20812 \$ac_cs_awk_pipe_init
20815 line = $ 0
20816 nfields = split(line, field, "@")
20817 substed = 0
20818 len = length(field[1])
20819 for (i = 2; i < nfields; i++) {
20820 key = field[i]
20821 keylen = length(key)
20822 if (S_is_set[key]) {
20823 value = S[key]
20824 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
20825 len += length(value) + length(field[++i])
20826 substed = 1
20827 } else
20828 len += 1 + keylen
20830 if (nfields == 3 && !substed) {
20831 key = field[2]
20832 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
20833 \$ac_cs_awk_read_file
20834 next
20837 print line
20839 \$ac_cs_awk_pipe_fini
20840 _ACAWK
20841 _ACEOF
20842 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20843 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
20844 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
20845 else
20847 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
20848 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
20849 _ACEOF
20851 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
20852 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
20853 # trailing colons and then remove the whole line if VPATH becomes empty
20854 # (actually we leave an empty line to preserve line numbers).
20855 if test "x$srcdir" = x.; then
20856 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
20858 s///
20859 s/^/:/
20860 s/[ ]*$/:/
20861 s/:\$(srcdir):/:/g
20862 s/:\${srcdir}:/:/g
20863 s/:@srcdir@:/:/g
20864 s/^:*//
20865 s/:*$//
20867 s/\(=[ ]*\).*/\1/
20869 s/\n//
20870 s/^[^=]*=[ ]*$//
20874 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20875 fi # test -n "$CONFIG_FILES"
20877 # Set up the scripts for CONFIG_HEADERS section.
20878 # No need to generate them if there are no CONFIG_HEADERS.
20879 # This happens for instance with `./config.status Makefile'.
20880 if test -n "$CONFIG_HEADERS"; then
20881 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
20882 BEGIN {
20883 _ACEOF
20885 # Transform confdefs.h into an awk script `defines.awk', embedded as
20886 # here-document in config.status, that substitutes the proper values into
20887 # config.h.in to produce config.h.
20889 # Create a delimiter string that does not exist in confdefs.h, to ease
20890 # handling of long lines.
20891 ac_delim='%!_!# '
20892 for ac_last_try in false false :; do
20893 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
20894 if test -z "$ac_tt"; then
20895 break
20896 elif $ac_last_try; then
20897 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
20898 else
20899 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20901 done
20903 # For the awk script, D is an array of macro values keyed by name,
20904 # likewise P contains macro parameters if any. Preserve backslash
20905 # newline sequences.
20907 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
20908 sed -n '
20909 s/.\{148\}/&'"$ac_delim"'/g
20910 t rset
20911 :rset
20912 s/^[ ]*#[ ]*define[ ][ ]*/ /
20913 t def
20915 :def
20916 s/\\$//
20917 t bsnl
20918 s/["\\]/\\&/g
20919 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20920 D["\1"]=" \3"/p
20921 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
20923 :bsnl
20924 s/["\\]/\\&/g
20925 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20926 D["\1"]=" \3\\\\\\n"\\/p
20927 t cont
20928 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
20929 t cont
20931 :cont
20933 s/.\{148\}/&'"$ac_delim"'/g
20934 t clear
20935 :clear
20936 s/\\$//
20937 t bsnlc
20938 s/["\\]/\\&/g; s/^/"/; s/$/"/p
20940 :bsnlc
20941 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
20942 b cont
20943 ' <confdefs.h | sed '
20944 s/'"$ac_delim"'/"\\\
20945 "/g' >>$CONFIG_STATUS || ac_write_fail=1
20947 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20948 for (key in D) D_is_set[key] = 1
20949 FS = "\a"
20951 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
20952 line = \$ 0
20953 split(line, arg, " ")
20954 if (arg[1] == "#") {
20955 defundef = arg[2]
20956 mac1 = arg[3]
20957 } else {
20958 defundef = substr(arg[1], 2)
20959 mac1 = arg[2]
20961 split(mac1, mac2, "(") #)
20962 macro = mac2[1]
20963 prefix = substr(line, 1, index(line, defundef) - 1)
20964 if (D_is_set[macro]) {
20965 # Preserve the white space surrounding the "#".
20966 print prefix "define", macro P[macro] D[macro]
20967 next
20968 } else {
20969 # Replace #undef with comments. This is necessary, for example,
20970 # in the case of _POSIX_SOURCE, which is predefined and required
20971 # on some systems where configure will not decide to define it.
20972 if (defundef == "undef") {
20973 print "/*", prefix defundef, macro, "*/"
20974 next
20978 { print }
20979 _ACAWK
20980 _ACEOF
20981 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20982 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
20983 fi # test -n "$CONFIG_HEADERS"
20986 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
20987 shift
20988 for ac_tag
20990 case $ac_tag in
20991 :[FHLC]) ac_mode=$ac_tag; continue;;
20992 esac
20993 case $ac_mode$ac_tag in
20994 :[FHL]*:*);;
20995 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
20996 :[FH]-) ac_tag=-:-;;
20997 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20998 esac
20999 ac_save_IFS=$IFS
21000 IFS=:
21001 set x $ac_tag
21002 IFS=$ac_save_IFS
21003 shift
21004 ac_file=$1
21005 shift
21007 case $ac_mode in
21008 :L) ac_source=$1;;
21009 :[FH])
21010 ac_file_inputs=
21011 for ac_f
21013 case $ac_f in
21014 -) ac_f="$ac_tmp/stdin";;
21015 *) # Look for the file first in the build tree, then in the source tree
21016 # (if the path is not absolute). The absolute path cannot be DOS-style,
21017 # because $ac_f cannot contain `:'.
21018 test -f "$ac_f" ||
21019 case $ac_f in
21020 [\\/$]*) false;;
21021 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
21022 esac ||
21023 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
21024 esac
21025 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
21026 as_fn_append ac_file_inputs " '$ac_f'"
21027 done
21029 # Let's still pretend it is `configure' which instantiates (i.e., don't
21030 # use $as_me), people would be surprised to read:
21031 # /* config.h. Generated by config.status. */
21032 configure_input='Generated from '`
21033 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
21034 `' by configure.'
21035 if test x"$ac_file" != x-; then
21036 configure_input="$ac_file. $configure_input"
21037 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
21038 $as_echo "$as_me: creating $ac_file" >&6;}
21040 # Neutralize special characters interpreted by sed in replacement strings.
21041 case $configure_input in #(
21042 *\&* | *\|* | *\\* )
21043 ac_sed_conf_input=`$as_echo "$configure_input" |
21044 sed 's/[\\\\&|]/\\\\&/g'`;; #(
21045 *) ac_sed_conf_input=$configure_input;;
21046 esac
21048 case $ac_tag in
21049 *:-:* | *:-) cat >"$ac_tmp/stdin" \
21050 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
21051 esac
21053 esac
21055 ac_dir=`$as_dirname -- "$ac_file" ||
21056 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21057 X"$ac_file" : 'X\(//\)[^/]' \| \
21058 X"$ac_file" : 'X\(//\)$' \| \
21059 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
21060 $as_echo X"$ac_file" |
21061 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21062 s//\1/
21065 /^X\(\/\/\)[^/].*/{
21066 s//\1/
21069 /^X\(\/\/\)$/{
21070 s//\1/
21073 /^X\(\/\).*/{
21074 s//\1/
21077 s/.*/./; q'`
21078 as_dir="$ac_dir"; as_fn_mkdir_p
21079 ac_builddir=.
21081 case "$ac_dir" in
21082 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
21084 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
21085 # A ".." for each directory in $ac_dir_suffix.
21086 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
21087 case $ac_top_builddir_sub in
21088 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
21089 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
21090 esac ;;
21091 esac
21092 ac_abs_top_builddir=$ac_pwd
21093 ac_abs_builddir=$ac_pwd$ac_dir_suffix
21094 # for backward compatibility:
21095 ac_top_builddir=$ac_top_build_prefix
21097 case $srcdir in
21098 .) # We are building in place.
21099 ac_srcdir=.
21100 ac_top_srcdir=$ac_top_builddir_sub
21101 ac_abs_top_srcdir=$ac_pwd ;;
21102 [\\/]* | ?:[\\/]* ) # Absolute name.
21103 ac_srcdir=$srcdir$ac_dir_suffix;
21104 ac_top_srcdir=$srcdir
21105 ac_abs_top_srcdir=$srcdir ;;
21106 *) # Relative name.
21107 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
21108 ac_top_srcdir=$ac_top_build_prefix$srcdir
21109 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
21110 esac
21111 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
21114 case $ac_mode in
21117 # CONFIG_FILE
21120 case $INSTALL in
21121 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
21122 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
21123 esac
21124 _ACEOF
21126 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21127 # If the template does not know about datarootdir, expand it.
21128 # FIXME: This hack should be removed a few years after 2.60.
21129 ac_datarootdir_hack=; ac_datarootdir_seen=
21130 ac_sed_dataroot='
21131 /datarootdir/ {
21135 /@datadir@/p
21136 /@docdir@/p
21137 /@infodir@/p
21138 /@localedir@/p
21139 /@mandir@/p'
21140 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
21141 *datarootdir*) ac_datarootdir_seen=yes;;
21142 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
21143 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
21144 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
21145 _ACEOF
21146 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21147 ac_datarootdir_hack='
21148 s&@datadir@&$datadir&g
21149 s&@docdir@&$docdir&g
21150 s&@infodir@&$infodir&g
21151 s&@localedir@&$localedir&g
21152 s&@mandir@&$mandir&g
21153 s&\\\${datarootdir}&$datarootdir&g' ;;
21154 esac
21155 _ACEOF
21157 # Neutralize VPATH when `$srcdir' = `.'.
21158 # Shell code in configure.ac might set extrasub.
21159 # FIXME: do we really want to maintain this feature?
21160 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21161 ac_sed_extra="$ac_vpsub
21162 $extrasub
21163 _ACEOF
21164 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21166 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
21167 s|@configure_input@|$ac_sed_conf_input|;t t
21168 s&@top_builddir@&$ac_top_builddir_sub&;t t
21169 s&@top_build_prefix@&$ac_top_build_prefix&;t t
21170 s&@srcdir@&$ac_srcdir&;t t
21171 s&@abs_srcdir@&$ac_abs_srcdir&;t t
21172 s&@top_srcdir@&$ac_top_srcdir&;t t
21173 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
21174 s&@builddir@&$ac_builddir&;t t
21175 s&@abs_builddir@&$ac_abs_builddir&;t t
21176 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
21177 s&@INSTALL@&$ac_INSTALL&;t t
21178 $ac_datarootdir_hack
21180 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
21181 if $ac_cs_awk_getline; then
21182 $AWK -f "$ac_tmp/subs.awk"
21183 else
21184 $AWK -f "$ac_tmp/subs.awk" | $SHELL
21185 fi \
21186 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
21188 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
21189 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
21190 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
21191 "$ac_tmp/out"`; test -z "$ac_out"; } &&
21192 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
21193 which seems to be undefined. Please make sure it is defined" >&5
21194 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
21195 which seems to be undefined. Please make sure it is defined" >&2;}
21197 rm -f "$ac_tmp/stdin"
21198 case $ac_file in
21199 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
21200 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
21201 esac \
21202 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
21206 # CONFIG_HEADER
21208 if test x"$ac_file" != x-; then
21210 $as_echo "/* $configure_input */" \
21211 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
21212 } >"$ac_tmp/config.h" \
21213 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
21214 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
21215 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
21216 $as_echo "$as_me: $ac_file is unchanged" >&6;}
21217 else
21218 rm -f "$ac_file"
21219 mv "$ac_tmp/config.h" "$ac_file" \
21220 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
21222 else
21223 $as_echo "/* $configure_input */" \
21224 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
21225 || as_fn_error $? "could not create -" "$LINENO" 5
21230 # CONFIG_LINK
21233 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
21235 else
21236 # Prefer the file from the source tree if names are identical.
21237 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
21238 ac_source=$srcdir/$ac_source
21241 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
21242 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
21244 if test ! -r "$ac_source"; then
21245 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
21247 rm -f "$ac_file"
21249 # Try a relative symlink, then a hard link, then a copy.
21250 case $ac_source in
21251 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
21252 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
21253 esac
21254 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
21255 ln "$ac_source" "$ac_file" 2>/dev/null ||
21256 cp -p "$ac_source" "$ac_file" ||
21257 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
21260 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
21261 $as_echo "$as_me: executing $ac_file commands" >&6;}
21263 esac
21266 case $ac_file$ac_mode in
21267 "config.h":H) echo > stamp-h ;;
21268 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
21269 "nm.h":L) echo > stamp-nmh ;;
21270 "gcore":F) chmod +x gcore ;;
21272 esac
21273 done # for ac_tag
21276 as_fn_exit 0
21277 _ACEOF
21278 ac_clean_files=$ac_clean_files_save
21280 test $ac_write_fail = 0 ||
21281 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
21284 # configure is writing to config.log, and then calls config.status.
21285 # config.status does its own redirection, appending to config.log.
21286 # Unfortunately, on DOS this fails, as config.log is still kept open
21287 # by configure, so config.status won't be able to write to it; its
21288 # output is simply discarded. So we exec the FD to /dev/null,
21289 # effectively closing config.log, so it can be properly (re)opened and
21290 # appended to by config.status. When coming back to configure, we
21291 # need to make the FD available again.
21292 if test "$no_create" != yes; then
21293 ac_cs_success=:
21294 ac_config_status_args=
21295 test "$silent" = yes &&
21296 ac_config_status_args="$ac_config_status_args --quiet"
21297 exec 5>/dev/null
21298 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
21299 exec 5>>config.log
21300 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
21301 # would make configure fail if this is the last instruction.
21302 $ac_cs_success || as_fn_exit 1
21306 # CONFIG_SUBDIRS section.
21308 if test "$no_recursion" != yes; then
21310 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
21311 # so they do not pile up.
21312 ac_sub_configure_args=
21313 ac_prev=
21314 eval "set x $ac_configure_args"
21315 shift
21316 for ac_arg
21318 if test -n "$ac_prev"; then
21319 ac_prev=
21320 continue
21322 case $ac_arg in
21323 -cache-file | --cache-file | --cache-fil | --cache-fi \
21324 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
21325 ac_prev=cache_file ;;
21326 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
21327 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
21328 | --c=*)
21330 --config-cache | -C)
21332 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
21333 ac_prev=srcdir ;;
21334 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
21336 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
21337 ac_prev=prefix ;;
21338 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
21340 --disable-option-checking)
21343 case $ac_arg in
21344 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
21345 esac
21346 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
21347 esac
21348 done
21350 # Always prepend --prefix to ensure using the same prefix
21351 # in subdir configurations.
21352 ac_arg="--prefix=$prefix"
21353 case $ac_arg in
21354 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
21355 esac
21356 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
21358 # Pass --silent
21359 if test "$silent" = yes; then
21360 ac_sub_configure_args="--silent $ac_sub_configure_args"
21363 # Always prepend --disable-option-checking to silence warnings, since
21364 # different subdirs can have different --enable and --with options.
21365 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
21367 ac_popdir=`pwd`
21368 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
21370 # Do not complain, so a configure script can configure whichever
21371 # parts of a large source tree are present.
21372 test -d "$srcdir/$ac_dir" || continue
21374 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
21375 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
21376 $as_echo "$ac_msg" >&6
21377 as_dir="$ac_dir"; as_fn_mkdir_p
21378 ac_builddir=.
21380 case "$ac_dir" in
21381 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
21383 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
21384 # A ".." for each directory in $ac_dir_suffix.
21385 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
21386 case $ac_top_builddir_sub in
21387 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
21388 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
21389 esac ;;
21390 esac
21391 ac_abs_top_builddir=$ac_pwd
21392 ac_abs_builddir=$ac_pwd$ac_dir_suffix
21393 # for backward compatibility:
21394 ac_top_builddir=$ac_top_build_prefix
21396 case $srcdir in
21397 .) # We are building in place.
21398 ac_srcdir=.
21399 ac_top_srcdir=$ac_top_builddir_sub
21400 ac_abs_top_srcdir=$ac_pwd ;;
21401 [\\/]* | ?:[\\/]* ) # Absolute name.
21402 ac_srcdir=$srcdir$ac_dir_suffix;
21403 ac_top_srcdir=$srcdir
21404 ac_abs_top_srcdir=$srcdir ;;
21405 *) # Relative name.
21406 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
21407 ac_top_srcdir=$ac_top_build_prefix$srcdir
21408 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
21409 esac
21410 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
21413 cd "$ac_dir"
21415 # Check for guested configure; otherwise get Cygnus style configure.
21416 if test -f "$ac_srcdir/configure.gnu"; then
21417 ac_sub_configure=$ac_srcdir/configure.gnu
21418 elif test -f "$ac_srcdir/configure"; then
21419 ac_sub_configure=$ac_srcdir/configure
21420 elif test -f "$ac_srcdir/configure.in"; then
21421 # This should be Cygnus configure.
21422 ac_sub_configure=$ac_aux_dir/configure
21423 else
21424 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
21425 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
21426 ac_sub_configure=
21429 # The recursion is here.
21430 if test -n "$ac_sub_configure"; then
21431 # Make the cache file name correct relative to the subdirectory.
21432 case $cache_file in
21433 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
21434 *) # Relative name.
21435 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
21436 esac
21438 { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
21439 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
21440 # The eval makes quoting arguments work.
21441 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
21442 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
21443 as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
21446 cd "$ac_popdir"
21447 done
21449 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
21450 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
21451 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}