]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/configure
Move check for strerror_r to common.m4 where it belongs
[thirdparty/binutils-gdb.git] / gdb / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.
4 #
5 #
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7 #
8 #
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 ## -------------------- ##
14
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 *) :
29 ;;
30 esac
31 fi
32
33
34 as_nl='
35 '
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"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70 fi
71
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=';'
78 }
79 fi
80
81
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"
88
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
95 do
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
101
102 ;;
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
108 fi
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
112 fi
113
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='+ '
125
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
131
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
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
157 fi
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 *) :
173 ;;
174 esac
175 fi
176 "
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; }
182
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 :
189
190 else
191 exitcode=1; echo positional parameters were not saved.
192 fi
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
204 fi
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
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
211 do
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
216 /*)
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
225 fi
226 fi
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
236
237
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
258 fi
259
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."
271 fi
272 exit 1
273 fi
274 fi
275 fi
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
281
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
289 {
290 { eval $1=; unset $1;}
291 }
292 as_unset=as_fn_unset
293
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
298 {
299 return $1
300 } # as_fn_set_status
301
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 ()
306 {
307 set +e
308 as_fn_set_status $1
309 exit $1
310 } # as_fn_exit
311
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
316 {
317
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/
337 q
338 }
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
341 q
342 }
343 /^X\(\/\/\)$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\).*/{
348 s//\1/
349 q
350 }
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"
356
357
358 } # as_fn_mkdir_p
359
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
364 {
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 ()
375 {
376 eval $1+=\$2
377 }'
378 else
379 as_fn_append ()
380 {
381 eval $1=\$$1\$2
382 }
383 fi # as_fn_append
384
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 ()
392 {
393 as_val=$(( $* ))
394 }'
395 else
396 as_fn_arith ()
397 {
398 as_val=`expr "$@" || test $? -eq 1`
399 }
400 fi # as_fn_arith
401
402
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 ()
409 {
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
414 fi
415 $as_echo "$as_me: error: $2" >&2
416 as_fn_exit $as_status
417 } # as_fn_error
418
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
424 fi
425
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427 as_basename=basename
428 else
429 as_basename=false
430 fi
431
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
436 fi
437
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/
445 q
446 }
447 /^X\/\(\/\/\)$/{
448 s//\1/
449 q
450 }
451 /^X\/\(\/\).*/{
452 s//\1/
453 q
454 }
455 s/.*/./; q'`
456
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
463
464
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 '
471 p
472 /[$]LINENO/=
473 ' <$as_myself |
474 sed '
475 s/[$]LINENO.*/&-/
476 t lineno
477 b
478 :lineno
479 N
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; }
487
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
498 }
499
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;;
509 *)
510 ECHO_N='-n';;
511 esac
512
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
519 fi
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'
533 fi
534 else
535 as_ln_s='cp -pR'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
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
545 fi
546
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
549
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'"
552
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'"
555
556
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
559
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`
564
565 #
566 # Initializations.
567 #
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=
576
577 # Identity of this package.
578 PACKAGE_NAME=
579 PACKAGE_TARNAME=
580 PACKAGE_VERSION=
581 PACKAGE_STRING=
582 PACKAGE_BUGREPORT=
583 PACKAGE_URL=
584
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"
621
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 LTLIBBABELTRACE
635 LIBBABELTRACE
636 HAVE_LIBBABELTRACE
637 HAVE_NATIVE_GCORE_HOST
638 NAT_GENERATED_FILES
639 XM_CLIBS
640 MH_CFLAGS
641 LOADLIBES
642 NAT_CDEPS
643 NATDEPFILES
644 NAT_FILE
645 target_subdir
646 CONFIG_UNINSTALL
647 CONFIG_INSTALL
648 CONFIG_CLEAN
649 CONFIG_ALL
650 CONFIG_SRCS
651 CONFIG_DEPS
652 CONFIG_OBS
653 PROFILE_CFLAGS
654 ENABLE_CFLAGS
655 SIM_OBS
656 SIM
657 XMKMF
658 GDBTK_SRC_DIR
659 GDBTK_CFLAGS
660 GDBTKLIBS
661 X_LIBS
662 X_LDFLAGS
663 X_CFLAGS
664 TK_XINCLUDES
665 TK_DEPS
666 TK_LIBRARY
667 TK_INCLUDE
668 TK_STUB_LIB_SPEC
669 TK_STUB_LIB_FLAG
670 TK_STUB_LIB_FILE
671 TK_LIB_SPEC
672 TK_LIB_FLAG
673 TK_LIB_FILE
674 TK_SRC_DIR
675 TK_BIN_DIR
676 TK_VERSION
677 TCL_DEPS
678 TCL_LIBRARY
679 TCL_INCLUDE
680 TCL_STUB_LIB_SPEC
681 TCL_STUB_LIB_FLAG
682 TCL_STUB_LIB_FILE
683 TCL_LIB_SPEC
684 TCL_LIB_FLAG
685 TCL_LIB_FILE
686 TCL_SRC_DIR
687 TCL_BIN_DIR
688 TCL_PATCH_LEVEL
689 TCL_VERSION
690 WIN32LDAPP
691 GUI_CFLAGS_X
692 LIBGUI
693 LTLIBLZMA
694 LIBLZMA
695 HAVE_LIBLZMA
696 WIN32LIBS
697 SER_HARDWIRE
698 WERROR_CFLAGS
699 WARN_CFLAGS
700 SYSTEM_GDBINIT_DIR
701 SYSTEM_GDBINIT
702 TARGET_SYSTEM_ROOT
703 CONFIG_LDFLAGS
704 RDYNAMIC
705 ALLOCA
706 LTLIBIPT
707 LIBIPT
708 HAVE_LIBIPT
709 SRCHIGH_CFLAGS
710 SRCHIGH_LIBS
711 HAVE_GUILE_FALSE
712 HAVE_GUILE_TRUE
713 GUILE_LIBS
714 GUILE_CPPFLAGS
715 GUILD_TARGET_FLAG
716 GUILD
717 pkg_config_prog_path
718 HAVE_PYTHON_FALSE
719 HAVE_PYTHON_TRUE
720 PYTHON_LIBS
721 PYTHON_CPPFLAGS
722 PYTHON_CFLAGS
723 python_prog_path
724 LTLIBMPFR
725 LIBMPFR
726 HAVE_LIBMPFR
727 LTLIBEXPAT
728 LIBEXPAT
729 HAVE_LIBEXPAT
730 JIT_READER_DIR
731 TARGET_PTR
732 READLINE_TEXI_INCFLAG
733 READLINE_CFLAGS
734 READLINE_DEPS
735 READLINE
736 LTLIBICONV
737 LIBICONV
738 zlibinc
739 zlibdir
740 MIG
741 WINDRES
742 DLLTOOL
743 AR
744 YFLAGS
745 YACC
746 RANLIB
747 LN_S
748 INSTALL_DATA
749 INSTALL_SCRIPT
750 INSTALL_PROGRAM
751 AWK
752 REPORT_BUGS_TEXI
753 REPORT_BUGS_TO
754 PKGVERSION
755 CODESIGN_CERT
756 HAVE_NATIVE_GCORE_TARGET
757 TARGET_OBS
758 subdirs
759 GDB_DATADIR
760 DEBUGDIR
761 MAKEINFO_EXTRA_FLAGS
762 MAKEINFOFLAGS
763 MAKEINFO
764 PACKAGE
765 CATOBJEXT
766 GENCAT
767 INSTOBJEXT
768 DATADIRNAME
769 CATALOGS
770 POSUB
771 GMSGFMT
772 XGETTEXT
773 INCINTL
774 LIBINTL_DEP
775 LIBINTL
776 USE_NLS
777 CCDEPMODE
778 DEPDIR
779 am__leading_dot
780 CXX_DIALECT
781 HAVE_CXX11
782 INSTALL_STRIP_PROGRAM
783 STRIP
784 install_sh
785 target_os
786 target_vendor
787 target_cpu
788 target
789 host_os
790 host_vendor
791 host_cpu
792 host
793 build_os
794 build_vendor
795 build_cpu
796 build
797 EGREP
798 GREP
799 CPP
800 ac_ct_CXX
801 CXXFLAGS
802 CXX
803 OBJEXT
804 EXEEXT
805 ac_ct_CC
806 CPPFLAGS
807 LDFLAGS
808 CFLAGS
809 CC
810 MAINT
811 MAINTAINER_MODE_FALSE
812 MAINTAINER_MODE_TRUE
813 target_alias
814 host_alias
815 build_alias
816 LIBS
817 ECHO_T
818 ECHO_N
819 ECHO_C
820 DEFS
821 mandir
822 localedir
823 libdir
824 psdir
825 pdfdir
826 dvidir
827 htmldir
828 infodir
829 docdir
830 oldincludedir
831 includedir
832 localstatedir
833 sharedstatedir
834 sysconfdir
835 datadir
836 datarootdir
837 libexecdir
838 sbindir
839 bindir
840 program_transform_name
841 prefix
842 exec_prefix
843 PACKAGE_URL
844 PACKAGE_BUGREPORT
845 PACKAGE_STRING
846 PACKAGE_VERSION
847 PACKAGE_TARNAME
848 PACKAGE_NAME
849 PATH_SEPARATOR
850 SHELL'
851 ac_subst_files='nat_makefile_frag'
852 ac_user_opts='
853 enable_option_checking
854 enable_maintainer_mode
855 enable_plugins
856 enable_largefile
857 with_separate_debug_dir
858 with_gdb_datadir
859 with_relocated_sources
860 with_auto_load_dir
861 with_auto_load_safe_path
862 enable_targets
863 enable_64_bit_bfd
864 enable_gdbmi
865 enable_tui
866 enable_gdbtk
867 with_libunwind_ia64
868 with_curses
869 enable_profiling
870 enable_codesign
871 with_pkgversion
872 with_bugurl
873 with_system_zlib
874 with_gnu_ld
875 enable_rpath
876 with_libiconv_prefix
877 with_iconv_bin
878 with_system_readline
879 with_jit_reader_dir
880 with_expat
881 with_libexpat_prefix
882 with_mpfr
883 with_libmpfr_prefix
884 with_python
885 with_guile
886 enable_source_highlight
887 with_intel_pt
888 with_libipt_prefix
889 with_included_regex
890 with_sysroot
891 with_system_gdbinit
892 with_system_gdbinit_dir
893 enable_werror
894 enable_build_warnings
895 enable_gdb_build_warnings
896 enable_ubsan
897 with_lzma
898 with_liblzma_prefix
899 with_tcl
900 with_tk
901 with_x
902 enable_sim
903 enable_gdbserver
904 with_babeltrace
905 with_libbabeltrace_prefix
906 with_xxhash
907 with_libxxhash_prefix
908 enable_unit_tests
909 '
910 ac_precious_vars='build_alias
911 host_alias
912 target_alias
913 CC
914 CFLAGS
915 LDFLAGS
916 LIBS
917 CPPFLAGS
918 CXX
919 CXXFLAGS
920 CCC
921 CPP
922 MAKEINFO
923 MAKEINFOFLAGS
924 YACC
925 YFLAGS
926 XMKMF'
927 ac_subdirs_all='testsuite
928 gdbtk
929 gdbserver'
930
931 # Initialize some variables set by options.
932 ac_init_help=
933 ac_init_version=false
934 ac_unrecognized_opts=
935 ac_unrecognized_sep=
936 # The variables have the same names as the options, with
937 # dashes changed to underlines.
938 cache_file=/dev/null
939 exec_prefix=NONE
940 no_create=
941 no_recursion=
942 prefix=NONE
943 program_prefix=NONE
944 program_suffix=NONE
945 program_transform_name=s,x,x,
946 silent=
947 site=
948 srcdir=
949 verbose=
950 x_includes=NONE
951 x_libraries=NONE
952
953 # Installation directory options.
954 # These are left unexpanded so users can "make install exec_prefix=/foo"
955 # and all the variables that are supposed to be based on exec_prefix
956 # by default will actually change.
957 # Use braces instead of parens because sh, perl, etc. also accept them.
958 # (The list follows the same order as the GNU Coding Standards.)
959 bindir='${exec_prefix}/bin'
960 sbindir='${exec_prefix}/sbin'
961 libexecdir='${exec_prefix}/libexec'
962 datarootdir='${prefix}/share'
963 datadir='${datarootdir}'
964 sysconfdir='${prefix}/etc'
965 sharedstatedir='${prefix}/com'
966 localstatedir='${prefix}/var'
967 includedir='${prefix}/include'
968 oldincludedir='/usr/include'
969 docdir='${datarootdir}/doc/${PACKAGE}'
970 infodir='${datarootdir}/info'
971 htmldir='${docdir}'
972 dvidir='${docdir}'
973 pdfdir='${docdir}'
974 psdir='${docdir}'
975 libdir='${exec_prefix}/lib'
976 localedir='${datarootdir}/locale'
977 mandir='${datarootdir}/man'
978
979 ac_prev=
980 ac_dashdash=
981 for ac_option
982 do
983 # If the previous option needs an argument, assign it.
984 if test -n "$ac_prev"; then
985 eval $ac_prev=\$ac_option
986 ac_prev=
987 continue
988 fi
989
990 case $ac_option in
991 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
992 *=) ac_optarg= ;;
993 *) ac_optarg=yes ;;
994 esac
995
996 # Accept the important Cygnus configure options, so we can diagnose typos.
997
998 case $ac_dashdash$ac_option in
999 --)
1000 ac_dashdash=yes ;;
1001
1002 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1003 ac_prev=bindir ;;
1004 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1005 bindir=$ac_optarg ;;
1006
1007 -build | --build | --buil | --bui | --bu)
1008 ac_prev=build_alias ;;
1009 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1010 build_alias=$ac_optarg ;;
1011
1012 -cache-file | --cache-file | --cache-fil | --cache-fi \
1013 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1014 ac_prev=cache_file ;;
1015 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1016 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1017 cache_file=$ac_optarg ;;
1018
1019 --config-cache | -C)
1020 cache_file=config.cache ;;
1021
1022 -datadir | --datadir | --datadi | --datad)
1023 ac_prev=datadir ;;
1024 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1025 datadir=$ac_optarg ;;
1026
1027 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1028 | --dataroo | --dataro | --datar)
1029 ac_prev=datarootdir ;;
1030 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1031 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1032 datarootdir=$ac_optarg ;;
1033
1034 -disable-* | --disable-*)
1035 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1036 # Reject names that are not valid shell variable names.
1037 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1038 as_fn_error $? "invalid feature name: $ac_useropt"
1039 ac_useropt_orig=$ac_useropt
1040 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1041 case $ac_user_opts in
1042 *"
1043 "enable_$ac_useropt"
1044 "*) ;;
1045 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1046 ac_unrecognized_sep=', ';;
1047 esac
1048 eval enable_$ac_useropt=no ;;
1049
1050 -docdir | --docdir | --docdi | --doc | --do)
1051 ac_prev=docdir ;;
1052 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1053 docdir=$ac_optarg ;;
1054
1055 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1056 ac_prev=dvidir ;;
1057 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1058 dvidir=$ac_optarg ;;
1059
1060 -enable-* | --enable-*)
1061 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1062 # Reject names that are not valid shell variable names.
1063 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1064 as_fn_error $? "invalid feature name: $ac_useropt"
1065 ac_useropt_orig=$ac_useropt
1066 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1067 case $ac_user_opts in
1068 *"
1069 "enable_$ac_useropt"
1070 "*) ;;
1071 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1072 ac_unrecognized_sep=', ';;
1073 esac
1074 eval enable_$ac_useropt=\$ac_optarg ;;
1075
1076 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1077 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1078 | --exec | --exe | --ex)
1079 ac_prev=exec_prefix ;;
1080 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1081 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1082 | --exec=* | --exe=* | --ex=*)
1083 exec_prefix=$ac_optarg ;;
1084
1085 -gas | --gas | --ga | --g)
1086 # Obsolete; use --with-gas.
1087 with_gas=yes ;;
1088
1089 -help | --help | --hel | --he | -h)
1090 ac_init_help=long ;;
1091 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1092 ac_init_help=recursive ;;
1093 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1094 ac_init_help=short ;;
1095
1096 -host | --host | --hos | --ho)
1097 ac_prev=host_alias ;;
1098 -host=* | --host=* | --hos=* | --ho=*)
1099 host_alias=$ac_optarg ;;
1100
1101 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1102 ac_prev=htmldir ;;
1103 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1104 | --ht=*)
1105 htmldir=$ac_optarg ;;
1106
1107 -includedir | --includedir | --includedi | --included | --include \
1108 | --includ | --inclu | --incl | --inc)
1109 ac_prev=includedir ;;
1110 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1111 | --includ=* | --inclu=* | --incl=* | --inc=*)
1112 includedir=$ac_optarg ;;
1113
1114 -infodir | --infodir | --infodi | --infod | --info | --inf)
1115 ac_prev=infodir ;;
1116 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1117 infodir=$ac_optarg ;;
1118
1119 -libdir | --libdir | --libdi | --libd)
1120 ac_prev=libdir ;;
1121 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1122 libdir=$ac_optarg ;;
1123
1124 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1125 | --libexe | --libex | --libe)
1126 ac_prev=libexecdir ;;
1127 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1128 | --libexe=* | --libex=* | --libe=*)
1129 libexecdir=$ac_optarg ;;
1130
1131 -localedir | --localedir | --localedi | --localed | --locale)
1132 ac_prev=localedir ;;
1133 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1134 localedir=$ac_optarg ;;
1135
1136 -localstatedir | --localstatedir | --localstatedi | --localstated \
1137 | --localstate | --localstat | --localsta | --localst | --locals)
1138 ac_prev=localstatedir ;;
1139 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1140 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1141 localstatedir=$ac_optarg ;;
1142
1143 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1144 ac_prev=mandir ;;
1145 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1146 mandir=$ac_optarg ;;
1147
1148 -nfp | --nfp | --nf)
1149 # Obsolete; use --without-fp.
1150 with_fp=no ;;
1151
1152 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1153 | --no-cr | --no-c | -n)
1154 no_create=yes ;;
1155
1156 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1157 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1158 no_recursion=yes ;;
1159
1160 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1161 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1162 | --oldin | --oldi | --old | --ol | --o)
1163 ac_prev=oldincludedir ;;
1164 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1165 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1166 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1167 oldincludedir=$ac_optarg ;;
1168
1169 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1170 ac_prev=prefix ;;
1171 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1172 prefix=$ac_optarg ;;
1173
1174 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1175 | --program-pre | --program-pr | --program-p)
1176 ac_prev=program_prefix ;;
1177 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1178 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1179 program_prefix=$ac_optarg ;;
1180
1181 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1182 | --program-suf | --program-su | --program-s)
1183 ac_prev=program_suffix ;;
1184 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1185 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1186 program_suffix=$ac_optarg ;;
1187
1188 -program-transform-name | --program-transform-name \
1189 | --program-transform-nam | --program-transform-na \
1190 | --program-transform-n | --program-transform- \
1191 | --program-transform | --program-transfor \
1192 | --program-transfo | --program-transf \
1193 | --program-trans | --program-tran \
1194 | --progr-tra | --program-tr | --program-t)
1195 ac_prev=program_transform_name ;;
1196 -program-transform-name=* | --program-transform-name=* \
1197 | --program-transform-nam=* | --program-transform-na=* \
1198 | --program-transform-n=* | --program-transform-=* \
1199 | --program-transform=* | --program-transfor=* \
1200 | --program-transfo=* | --program-transf=* \
1201 | --program-trans=* | --program-tran=* \
1202 | --progr-tra=* | --program-tr=* | --program-t=*)
1203 program_transform_name=$ac_optarg ;;
1204
1205 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1206 ac_prev=pdfdir ;;
1207 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1208 pdfdir=$ac_optarg ;;
1209
1210 -psdir | --psdir | --psdi | --psd | --ps)
1211 ac_prev=psdir ;;
1212 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1213 psdir=$ac_optarg ;;
1214
1215 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1216 | -silent | --silent | --silen | --sile | --sil)
1217 silent=yes ;;
1218
1219 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1220 ac_prev=sbindir ;;
1221 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1222 | --sbi=* | --sb=*)
1223 sbindir=$ac_optarg ;;
1224
1225 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1226 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1227 | --sharedst | --shareds | --shared | --share | --shar \
1228 | --sha | --sh)
1229 ac_prev=sharedstatedir ;;
1230 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1231 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1232 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1233 | --sha=* | --sh=*)
1234 sharedstatedir=$ac_optarg ;;
1235
1236 -site | --site | --sit)
1237 ac_prev=site ;;
1238 -site=* | --site=* | --sit=*)
1239 site=$ac_optarg ;;
1240
1241 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1242 ac_prev=srcdir ;;
1243 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1244 srcdir=$ac_optarg ;;
1245
1246 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1247 | --syscon | --sysco | --sysc | --sys | --sy)
1248 ac_prev=sysconfdir ;;
1249 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1250 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1251 sysconfdir=$ac_optarg ;;
1252
1253 -target | --target | --targe | --targ | --tar | --ta | --t)
1254 ac_prev=target_alias ;;
1255 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1256 target_alias=$ac_optarg ;;
1257
1258 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1259 verbose=yes ;;
1260
1261 -version | --version | --versio | --versi | --vers | -V)
1262 ac_init_version=: ;;
1263
1264 -with-* | --with-*)
1265 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1266 # Reject names that are not valid shell variable names.
1267 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1268 as_fn_error $? "invalid package name: $ac_useropt"
1269 ac_useropt_orig=$ac_useropt
1270 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1271 case $ac_user_opts in
1272 *"
1273 "with_$ac_useropt"
1274 "*) ;;
1275 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1276 ac_unrecognized_sep=', ';;
1277 esac
1278 eval with_$ac_useropt=\$ac_optarg ;;
1279
1280 -without-* | --without-*)
1281 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1282 # Reject names that are not valid shell variable names.
1283 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1284 as_fn_error $? "invalid package name: $ac_useropt"
1285 ac_useropt_orig=$ac_useropt
1286 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1287 case $ac_user_opts in
1288 *"
1289 "with_$ac_useropt"
1290 "*) ;;
1291 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1292 ac_unrecognized_sep=', ';;
1293 esac
1294 eval with_$ac_useropt=no ;;
1295
1296 --x)
1297 # Obsolete; use --with-x.
1298 with_x=yes ;;
1299
1300 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1301 | --x-incl | --x-inc | --x-in | --x-i)
1302 ac_prev=x_includes ;;
1303 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1304 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1305 x_includes=$ac_optarg ;;
1306
1307 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1308 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1309 ac_prev=x_libraries ;;
1310 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1311 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1312 x_libraries=$ac_optarg ;;
1313
1314 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1315 Try \`$0 --help' for more information"
1316 ;;
1317
1318 *=*)
1319 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1320 # Reject names that are not valid shell variable names.
1321 case $ac_envvar in #(
1322 '' | [0-9]* | *[!_$as_cr_alnum]* )
1323 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1324 esac
1325 eval $ac_envvar=\$ac_optarg
1326 export $ac_envvar ;;
1327
1328 *)
1329 # FIXME: should be removed in autoconf 3.0.
1330 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1331 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1332 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1333 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1334 ;;
1335
1336 esac
1337 done
1338
1339 if test -n "$ac_prev"; then
1340 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1341 as_fn_error $? "missing argument to $ac_option"
1342 fi
1343
1344 if test -n "$ac_unrecognized_opts"; then
1345 case $enable_option_checking in
1346 no) ;;
1347 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1348 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1349 esac
1350 fi
1351
1352 # Check all directory arguments for consistency.
1353 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1354 datadir sysconfdir sharedstatedir localstatedir includedir \
1355 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1356 libdir localedir mandir
1357 do
1358 eval ac_val=\$$ac_var
1359 # Remove trailing slashes.
1360 case $ac_val in
1361 */ )
1362 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1363 eval $ac_var=\$ac_val;;
1364 esac
1365 # Be sure to have absolute directory names.
1366 case $ac_val in
1367 [\\/$]* | ?:[\\/]* ) continue;;
1368 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1369 esac
1370 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1371 done
1372
1373 # There might be people who depend on the old broken behavior: `$host'
1374 # used to hold the argument of --host etc.
1375 # FIXME: To remove some day.
1376 build=$build_alias
1377 host=$host_alias
1378 target=$target_alias
1379
1380 # FIXME: To remove some day.
1381 if test "x$host_alias" != x; then
1382 if test "x$build_alias" = x; then
1383 cross_compiling=maybe
1384 elif test "x$build_alias" != "x$host_alias"; then
1385 cross_compiling=yes
1386 fi
1387 fi
1388
1389 ac_tool_prefix=
1390 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1391
1392 test "$silent" = yes && exec 6>/dev/null
1393
1394
1395 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1396 ac_ls_di=`ls -di .` &&
1397 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1398 as_fn_error $? "working directory cannot be determined"
1399 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1400 as_fn_error $? "pwd does not report name of working directory"
1401
1402
1403 # Find the source files, if location was not specified.
1404 if test -z "$srcdir"; then
1405 ac_srcdir_defaulted=yes
1406 # Try the directory containing this script, then the parent directory.
1407 ac_confdir=`$as_dirname -- "$as_myself" ||
1408 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1409 X"$as_myself" : 'X\(//\)[^/]' \| \
1410 X"$as_myself" : 'X\(//\)$' \| \
1411 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1412 $as_echo X"$as_myself" |
1413 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1414 s//\1/
1415 q
1416 }
1417 /^X\(\/\/\)[^/].*/{
1418 s//\1/
1419 q
1420 }
1421 /^X\(\/\/\)$/{
1422 s//\1/
1423 q
1424 }
1425 /^X\(\/\).*/{
1426 s//\1/
1427 q
1428 }
1429 s/.*/./; q'`
1430 srcdir=$ac_confdir
1431 if test ! -r "$srcdir/$ac_unique_file"; then
1432 srcdir=..
1433 fi
1434 else
1435 ac_srcdir_defaulted=no
1436 fi
1437 if test ! -r "$srcdir/$ac_unique_file"; then
1438 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1439 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1440 fi
1441 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1442 ac_abs_confdir=`(
1443 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1444 pwd)`
1445 # When building in place, set srcdir=.
1446 if test "$ac_abs_confdir" = "$ac_pwd"; then
1447 srcdir=.
1448 fi
1449 # Remove unnecessary trailing slashes from srcdir.
1450 # Double slashes in file names in object file debugging info
1451 # mess up M-x gdb in Emacs.
1452 case $srcdir in
1453 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1454 esac
1455 for ac_var in $ac_precious_vars; do
1456 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1457 eval ac_env_${ac_var}_value=\$${ac_var}
1458 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1459 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1460 done
1461
1462 #
1463 # Report the --help message.
1464 #
1465 if test "$ac_init_help" = "long"; then
1466 # Omit some internal or obsolete options to make the list less imposing.
1467 # This message is too long to be a string in the A/UX 3.1 sh.
1468 cat <<_ACEOF
1469 \`configure' configures this package to adapt to many kinds of systems.
1470
1471 Usage: $0 [OPTION]... [VAR=VALUE]...
1472
1473 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1474 VAR=VALUE. See below for descriptions of some of the useful variables.
1475
1476 Defaults for the options are specified in brackets.
1477
1478 Configuration:
1479 -h, --help display this help and exit
1480 --help=short display options specific to this package
1481 --help=recursive display the short help of all the included packages
1482 -V, --version display version information and exit
1483 -q, --quiet, --silent do not print \`checking ...' messages
1484 --cache-file=FILE cache test results in FILE [disabled]
1485 -C, --config-cache alias for \`--cache-file=config.cache'
1486 -n, --no-create do not create output files
1487 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1488
1489 Installation directories:
1490 --prefix=PREFIX install architecture-independent files in PREFIX
1491 [$ac_default_prefix]
1492 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1493 [PREFIX]
1494
1495 By default, \`make install' will install all the files in
1496 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1497 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1498 for instance \`--prefix=\$HOME'.
1499
1500 For better control, use the options below.
1501
1502 Fine tuning of the installation directories:
1503 --bindir=DIR user executables [EPREFIX/bin]
1504 --sbindir=DIR system admin executables [EPREFIX/sbin]
1505 --libexecdir=DIR program executables [EPREFIX/libexec]
1506 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1507 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1508 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1509 --libdir=DIR object code libraries [EPREFIX/lib]
1510 --includedir=DIR C header files [PREFIX/include]
1511 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1512 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1513 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1514 --infodir=DIR info documentation [DATAROOTDIR/info]
1515 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1516 --mandir=DIR man documentation [DATAROOTDIR/man]
1517 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1518 --htmldir=DIR html documentation [DOCDIR]
1519 --dvidir=DIR dvi documentation [DOCDIR]
1520 --pdfdir=DIR pdf documentation [DOCDIR]
1521 --psdir=DIR ps documentation [DOCDIR]
1522 _ACEOF
1523
1524 cat <<\_ACEOF
1525
1526 Program names:
1527 --program-prefix=PREFIX prepend PREFIX to installed program names
1528 --program-suffix=SUFFIX append SUFFIX to installed program names
1529 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1530
1531 X features:
1532 --x-includes=DIR X include files are in DIR
1533 --x-libraries=DIR X library files are in DIR
1534
1535 System types:
1536 --build=BUILD configure for building on BUILD [guessed]
1537 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1538 --target=TARGET configure for building compilers for TARGET [HOST]
1539 _ACEOF
1540 fi
1541
1542 if test -n "$ac_init_help"; then
1543
1544 cat <<\_ACEOF
1545
1546 Optional Features:
1547 --disable-option-checking ignore unrecognized --enable/--with options
1548 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1549 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1550 --enable-maintainer-mode
1551 enable make rules and dependencies not useful (and
1552 sometimes confusing) to the casual installer
1553 --enable-plugins Enable support for plugins
1554 --disable-largefile omit support for large files
1555 --enable-targets=TARGETS
1556 alternative target configurations
1557 --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
1558 --disable-gdbmi disable machine-interface (MI)
1559 --enable-tui enable full-screen terminal user interface (TUI)
1560 --enable-gdbtk enable gdbtk graphical user interface (GUI)
1561 --enable-profiling enable profiling of GDB
1562 --enable-codesign=CERT sign gdb with 'codesign -s CERT'
1563 --disable-rpath do not hardcode runtime library paths
1564 --enable-source-highlight
1565 enable source-highlight for source listings
1566 --enable-werror treat compile warnings as errors
1567 --enable-build-warnings enable build-time compiler warnings if gcc is used
1568 --enable-gdb-build-warnings
1569 enable GDB specific build-time compiler warnings if
1570 gcc is used
1571 --enable-ubsan enable undefined behavior sanitizer (auto/yes/no)
1572 --enable-sim link gdb with simulator
1573 --enable-gdbserver automatically build gdbserver (yes/no/auto, default
1574 is auto)
1575 --enable-unit-tests Enable the inclusion of unit tests when compiling
1576 GDB
1577
1578 Optional Packages:
1579 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1580 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1581 --with-separate-debug-dir=PATH
1582 look for global separate debug info in this path
1583 [LIBDIR/debug]
1584 --with-gdb-datadir=PATH look for global separate data files in this path
1585 [DATADIR/gdb]
1586 --with-relocated-sources=PATH
1587 automatically relocate this path for source files
1588 --with-auto-load-dir=PATH
1589 directories from which to load auto-loaded scripts
1590 [$debugdir:$datadir/auto-load]
1591 --with-auto-load-safe-path=PATH
1592 directories safe to hold auto-loaded files
1593 [--with-auto-load-dir]
1594 --without-auto-load-safe-path
1595 do not restrict auto-loaded files locations
1596 --with-libunwind-ia64 use libunwind frame unwinding for ia64 targets
1597 --with-curses use the curses library instead of the termcap
1598 library
1599 --with-pkgversion=PKG Use PKG in the version string in place of "GDB"
1600 --with-bugurl=URL Direct users to URL to report a bug
1601 --with-system-zlib use installed libz
1602 --with-gnu-ld assume the C compiler uses GNU ld default=no
1603 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1604 --without-libiconv-prefix don't search for libiconv in includedir and libdir
1605 --with-iconv-bin=PATH specify where to find the iconv program
1606 --with-system-readline use installed readline library
1607 --with-jit-reader-dir=PATH
1608 directory to load the JIT readers from
1609 --with-expat include expat support (auto/yes/no)
1610 --with-libexpat-prefix[=DIR] search for libexpat in DIR/include and DIR/lib
1611 --without-libexpat-prefix don't search for libexpat in includedir and libdir
1612 --with-mpfr include MPFR support (auto/yes/no)
1613 --with-libmpfr-prefix[=DIR] search for libmpfr in DIR/include and DIR/lib
1614 --without-libmpfr-prefix don't search for libmpfr in includedir and libdir
1615 --with-python[=PYTHON] include python support
1616 (auto/yes/no/<python-program>)
1617 --with-guile[=GUILE] include guile support
1618 (auto/yes/no/<guile-version>/<pkg-config-program>)
1619 --with-intel-pt include Intel Processor Trace support (auto/yes/no)
1620 --with-libipt-prefix[=DIR] search for libipt in DIR/include and DIR/lib
1621 --without-libipt-prefix don't search for libipt in includedir and libdir
1622 --without-included-regex
1623 don't use included regex; this is the default on
1624 systems with version 2 of the GNU C library (use
1625 with caution on other system)
1626 --with-sysroot[=DIR] search for usr/lib et al within DIR
1627 --with-system-gdbinit=PATH
1628 automatically load a system-wide gdbinit file
1629 --with-system-gdbinit-dir=PATH
1630 automatically load system-wide gdbinit files from
1631 this directory
1632 --with-lzma support lzma compression (auto/yes/no)
1633 --with-liblzma-prefix[=DIR] search for liblzma in DIR/include and DIR/lib
1634 --without-liblzma-prefix don't search for liblzma in includedir and libdir
1635 --with-tcl directory containing tcl configuration (tclConfig.sh)
1636 --with-tk directory containing tk configuration (tkConfig.sh)
1637 --with-x use the X Window System
1638 --with-babeltrace include babeltrace support (auto/yes/no)
1639 --with-libbabeltrace-prefix[=DIR] search for libbabeltrace in DIR/include and DIR/lib
1640 --without-libbabeltrace-prefix don't search for libbabeltrace in includedir and libdir
1641 --with-xxhash use libxxhash for hashing (faster) (auto/yes/no)
1642 --with-libxxhash-prefix[=DIR] search for libxxhash in DIR/include and DIR/lib
1643 --without-libxxhash-prefix don't search for libxxhash in includedir and libdir
1644
1645 Some influential environment variables:
1646 CC C compiler command
1647 CFLAGS C compiler flags
1648 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1649 nonstandard directory <lib dir>
1650 LIBS libraries to pass to the linker, e.g. -l<library>
1651 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1652 you have headers in a nonstandard directory <include dir>
1653 CXX C++ compiler command
1654 CXXFLAGS C++ compiler flags
1655 CPP C preprocessor
1656 MAKEINFO Parent configure detects if it is of sufficient version.
1657 MAKEINFOFLAGS
1658 Parameters for MAKEINFO.
1659 YACC The `Yet Another Compiler Compiler' implementation to use.
1660 Defaults to the first program found out of: `bison -y', `byacc',
1661 `yacc'.
1662 YFLAGS The list of arguments that will be passed by default to $YACC.
1663 This script will default YFLAGS to the empty string to avoid a
1664 default value of `-d' given by some make applications.
1665 XMKMF Path to xmkmf, Makefile generator for X Window System
1666
1667 Use these variables to override the choices made by `configure' or to help
1668 it to find libraries and programs with nonstandard names/locations.
1669
1670 Report bugs to the package provider.
1671 _ACEOF
1672 ac_status=$?
1673 fi
1674
1675 if test "$ac_init_help" = "recursive"; then
1676 # If there are subdirs, report their specific --help.
1677 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1678 test -d "$ac_dir" ||
1679 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1680 continue
1681 ac_builddir=.
1682
1683 case "$ac_dir" in
1684 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1685 *)
1686 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1687 # A ".." for each directory in $ac_dir_suffix.
1688 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1689 case $ac_top_builddir_sub in
1690 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1691 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1692 esac ;;
1693 esac
1694 ac_abs_top_builddir=$ac_pwd
1695 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1696 # for backward compatibility:
1697 ac_top_builddir=$ac_top_build_prefix
1698
1699 case $srcdir in
1700 .) # We are building in place.
1701 ac_srcdir=.
1702 ac_top_srcdir=$ac_top_builddir_sub
1703 ac_abs_top_srcdir=$ac_pwd ;;
1704 [\\/]* | ?:[\\/]* ) # Absolute name.
1705 ac_srcdir=$srcdir$ac_dir_suffix;
1706 ac_top_srcdir=$srcdir
1707 ac_abs_top_srcdir=$srcdir ;;
1708 *) # Relative name.
1709 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1710 ac_top_srcdir=$ac_top_build_prefix$srcdir
1711 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1712 esac
1713 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1714
1715 cd "$ac_dir" || { ac_status=$?; continue; }
1716 # Check for guested configure.
1717 if test -f "$ac_srcdir/configure.gnu"; then
1718 echo &&
1719 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1720 elif test -f "$ac_srcdir/configure"; then
1721 echo &&
1722 $SHELL "$ac_srcdir/configure" --help=recursive
1723 else
1724 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1725 fi || ac_status=$?
1726 cd "$ac_pwd" || { ac_status=$?; break; }
1727 done
1728 fi
1729
1730 test -n "$ac_init_help" && exit $ac_status
1731 if $ac_init_version; then
1732 cat <<\_ACEOF
1733 configure
1734 generated by GNU Autoconf 2.69
1735
1736 Copyright (C) 2012 Free Software Foundation, Inc.
1737 This configure script is free software; the Free Software Foundation
1738 gives unlimited permission to copy, distribute and modify it.
1739 _ACEOF
1740 exit
1741 fi
1742
1743 ## ------------------------ ##
1744 ## Autoconf initialization. ##
1745 ## ------------------------ ##
1746
1747 # ac_fn_c_try_compile LINENO
1748 # --------------------------
1749 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1750 ac_fn_c_try_compile ()
1751 {
1752 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1753 rm -f conftest.$ac_objext
1754 if { { ac_try="$ac_compile"
1755 case "(($ac_try" in
1756 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1757 *) ac_try_echo=$ac_try;;
1758 esac
1759 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1760 $as_echo "$ac_try_echo"; } >&5
1761 (eval "$ac_compile") 2>conftest.err
1762 ac_status=$?
1763 if test -s conftest.err; then
1764 grep -v '^ *+' conftest.err >conftest.er1
1765 cat conftest.er1 >&5
1766 mv -f conftest.er1 conftest.err
1767 fi
1768 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1769 test $ac_status = 0; } && {
1770 test -z "$ac_c_werror_flag" ||
1771 test ! -s conftest.err
1772 } && test -s conftest.$ac_objext; then :
1773 ac_retval=0
1774 else
1775 $as_echo "$as_me: failed program was:" >&5
1776 sed 's/^/| /' conftest.$ac_ext >&5
1777
1778 ac_retval=1
1779 fi
1780 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1781 as_fn_set_status $ac_retval
1782
1783 } # ac_fn_c_try_compile
1784
1785 # ac_fn_cxx_try_compile LINENO
1786 # ----------------------------
1787 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1788 ac_fn_cxx_try_compile ()
1789 {
1790 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1791 rm -f conftest.$ac_objext
1792 if { { ac_try="$ac_compile"
1793 case "(($ac_try" in
1794 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1795 *) ac_try_echo=$ac_try;;
1796 esac
1797 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1798 $as_echo "$ac_try_echo"; } >&5
1799 (eval "$ac_compile") 2>conftest.err
1800 ac_status=$?
1801 if test -s conftest.err; then
1802 grep -v '^ *+' conftest.err >conftest.er1
1803 cat conftest.er1 >&5
1804 mv -f conftest.er1 conftest.err
1805 fi
1806 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1807 test $ac_status = 0; } && {
1808 test -z "$ac_cxx_werror_flag" ||
1809 test ! -s conftest.err
1810 } && test -s conftest.$ac_objext; then :
1811 ac_retval=0
1812 else
1813 $as_echo "$as_me: failed program was:" >&5
1814 sed 's/^/| /' conftest.$ac_ext >&5
1815
1816 ac_retval=1
1817 fi
1818 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1819 as_fn_set_status $ac_retval
1820
1821 } # ac_fn_cxx_try_compile
1822
1823 # ac_fn_c_try_cpp LINENO
1824 # ----------------------
1825 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1826 ac_fn_c_try_cpp ()
1827 {
1828 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1829 if { { ac_try="$ac_cpp conftest.$ac_ext"
1830 case "(($ac_try" in
1831 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1832 *) ac_try_echo=$ac_try;;
1833 esac
1834 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1835 $as_echo "$ac_try_echo"; } >&5
1836 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1837 ac_status=$?
1838 if test -s conftest.err; then
1839 grep -v '^ *+' conftest.err >conftest.er1
1840 cat conftest.er1 >&5
1841 mv -f conftest.er1 conftest.err
1842 fi
1843 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1844 test $ac_status = 0; } > conftest.i && {
1845 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1846 test ! -s conftest.err
1847 }; then :
1848 ac_retval=0
1849 else
1850 $as_echo "$as_me: failed program was:" >&5
1851 sed 's/^/| /' conftest.$ac_ext >&5
1852
1853 ac_retval=1
1854 fi
1855 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1856 as_fn_set_status $ac_retval
1857
1858 } # ac_fn_c_try_cpp
1859
1860 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1861 # -------------------------------------------------------
1862 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1863 # the include files in INCLUDES and setting the cache variable VAR
1864 # accordingly.
1865 ac_fn_c_check_header_mongrel ()
1866 {
1867 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1868 if eval \${$3+:} false; then :
1869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1870 $as_echo_n "checking for $2... " >&6; }
1871 if eval \${$3+:} false; then :
1872 $as_echo_n "(cached) " >&6
1873 fi
1874 eval ac_res=\$$3
1875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1876 $as_echo "$ac_res" >&6; }
1877 else
1878 # Is the header compilable?
1879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1880 $as_echo_n "checking $2 usability... " >&6; }
1881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1882 /* end confdefs.h. */
1883 $4
1884 #include <$2>
1885 _ACEOF
1886 if ac_fn_c_try_compile "$LINENO"; then :
1887 ac_header_compiler=yes
1888 else
1889 ac_header_compiler=no
1890 fi
1891 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1893 $as_echo "$ac_header_compiler" >&6; }
1894
1895 # Is the header present?
1896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1897 $as_echo_n "checking $2 presence... " >&6; }
1898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1899 /* end confdefs.h. */
1900 #include <$2>
1901 _ACEOF
1902 if ac_fn_c_try_cpp "$LINENO"; then :
1903 ac_header_preproc=yes
1904 else
1905 ac_header_preproc=no
1906 fi
1907 rm -f conftest.err conftest.i conftest.$ac_ext
1908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1909 $as_echo "$ac_header_preproc" >&6; }
1910
1911 # So? What about this header?
1912 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1913 yes:no: )
1914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1915 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1917 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1918 ;;
1919 no:yes:* )
1920 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1921 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1922 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1923 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1924 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1925 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1926 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1927 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1929 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1930 ;;
1931 esac
1932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1933 $as_echo_n "checking for $2... " >&6; }
1934 if eval \${$3+:} false; then :
1935 $as_echo_n "(cached) " >&6
1936 else
1937 eval "$3=\$ac_header_compiler"
1938 fi
1939 eval ac_res=\$$3
1940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1941 $as_echo "$ac_res" >&6; }
1942 fi
1943 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1944
1945 } # ac_fn_c_check_header_mongrel
1946
1947 # ac_fn_c_try_run LINENO
1948 # ----------------------
1949 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1950 # that executables *can* be run.
1951 ac_fn_c_try_run ()
1952 {
1953 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1954 if { { ac_try="$ac_link"
1955 case "(($ac_try" in
1956 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1957 *) ac_try_echo=$ac_try;;
1958 esac
1959 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1960 $as_echo "$ac_try_echo"; } >&5
1961 (eval "$ac_link") 2>&5
1962 ac_status=$?
1963 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1964 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1965 { { case "(($ac_try" in
1966 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1967 *) ac_try_echo=$ac_try;;
1968 esac
1969 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1970 $as_echo "$ac_try_echo"; } >&5
1971 (eval "$ac_try") 2>&5
1972 ac_status=$?
1973 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1974 test $ac_status = 0; }; }; then :
1975 ac_retval=0
1976 else
1977 $as_echo "$as_me: program exited with status $ac_status" >&5
1978 $as_echo "$as_me: failed program was:" >&5
1979 sed 's/^/| /' conftest.$ac_ext >&5
1980
1981 ac_retval=$ac_status
1982 fi
1983 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1984 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1985 as_fn_set_status $ac_retval
1986
1987 } # ac_fn_c_try_run
1988
1989 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1990 # -------------------------------------------------------
1991 # Tests whether HEADER exists and can be compiled using the include files in
1992 # INCLUDES, setting the cache variable VAR accordingly.
1993 ac_fn_c_check_header_compile ()
1994 {
1995 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1997 $as_echo_n "checking for $2... " >&6; }
1998 if eval \${$3+:} false; then :
1999 $as_echo_n "(cached) " >&6
2000 else
2001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2002 /* end confdefs.h. */
2003 $4
2004 #include <$2>
2005 _ACEOF
2006 if ac_fn_c_try_compile "$LINENO"; then :
2007 eval "$3=yes"
2008 else
2009 eval "$3=no"
2010 fi
2011 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2012 fi
2013 eval ac_res=\$$3
2014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2015 $as_echo "$ac_res" >&6; }
2016 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2017
2018 } # ac_fn_c_check_header_compile
2019
2020 # ac_fn_c_try_link LINENO
2021 # -----------------------
2022 # Try to link conftest.$ac_ext, and return whether this succeeded.
2023 ac_fn_c_try_link ()
2024 {
2025 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2026 rm -f conftest.$ac_objext conftest$ac_exeext
2027 if { { ac_try="$ac_link"
2028 case "(($ac_try" in
2029 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2030 *) ac_try_echo=$ac_try;;
2031 esac
2032 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2033 $as_echo "$ac_try_echo"; } >&5
2034 (eval "$ac_link") 2>conftest.err
2035 ac_status=$?
2036 if test -s conftest.err; then
2037 grep -v '^ *+' conftest.err >conftest.er1
2038 cat conftest.er1 >&5
2039 mv -f conftest.er1 conftest.err
2040 fi
2041 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2042 test $ac_status = 0; } && {
2043 test -z "$ac_c_werror_flag" ||
2044 test ! -s conftest.err
2045 } && test -s conftest$ac_exeext && {
2046 test "$cross_compiling" = yes ||
2047 test -x conftest$ac_exeext
2048 }; then :
2049 ac_retval=0
2050 else
2051 $as_echo "$as_me: failed program was:" >&5
2052 sed 's/^/| /' conftest.$ac_ext >&5
2053
2054 ac_retval=1
2055 fi
2056 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2057 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2058 # interfere with the next link command; also delete a directory that is
2059 # left behind by Apple's compiler. We do this before executing the actions.
2060 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2061 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2062 as_fn_set_status $ac_retval
2063
2064 } # ac_fn_c_try_link
2065
2066 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2067 # --------------------------------------------
2068 # Tries to find the compile-time value of EXPR in a program that includes
2069 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2070 # computed
2071 ac_fn_c_compute_int ()
2072 {
2073 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2074 if test "$cross_compiling" = yes; then
2075 # Depending upon the size, compute the lo and hi bounds.
2076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2077 /* end confdefs.h. */
2078 $4
2079 int
2080 main ()
2081 {
2082 static int test_array [1 - 2 * !(($2) >= 0)];
2083 test_array [0] = 0;
2084 return test_array [0];
2085
2086 ;
2087 return 0;
2088 }
2089 _ACEOF
2090 if ac_fn_c_try_compile "$LINENO"; then :
2091 ac_lo=0 ac_mid=0
2092 while :; do
2093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2094 /* end confdefs.h. */
2095 $4
2096 int
2097 main ()
2098 {
2099 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2100 test_array [0] = 0;
2101 return test_array [0];
2102
2103 ;
2104 return 0;
2105 }
2106 _ACEOF
2107 if ac_fn_c_try_compile "$LINENO"; then :
2108 ac_hi=$ac_mid; break
2109 else
2110 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2111 if test $ac_lo -le $ac_mid; then
2112 ac_lo= ac_hi=
2113 break
2114 fi
2115 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2116 fi
2117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2118 done
2119 else
2120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2121 /* end confdefs.h. */
2122 $4
2123 int
2124 main ()
2125 {
2126 static int test_array [1 - 2 * !(($2) < 0)];
2127 test_array [0] = 0;
2128 return test_array [0];
2129
2130 ;
2131 return 0;
2132 }
2133 _ACEOF
2134 if ac_fn_c_try_compile "$LINENO"; then :
2135 ac_hi=-1 ac_mid=-1
2136 while :; do
2137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2138 /* end confdefs.h. */
2139 $4
2140 int
2141 main ()
2142 {
2143 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2144 test_array [0] = 0;
2145 return test_array [0];
2146
2147 ;
2148 return 0;
2149 }
2150 _ACEOF
2151 if ac_fn_c_try_compile "$LINENO"; then :
2152 ac_lo=$ac_mid; break
2153 else
2154 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2155 if test $ac_mid -le $ac_hi; then
2156 ac_lo= ac_hi=
2157 break
2158 fi
2159 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2160 fi
2161 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2162 done
2163 else
2164 ac_lo= ac_hi=
2165 fi
2166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2167 fi
2168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2169 # Binary search between lo and hi bounds.
2170 while test "x$ac_lo" != "x$ac_hi"; do
2171 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2173 /* end confdefs.h. */
2174 $4
2175 int
2176 main ()
2177 {
2178 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2179 test_array [0] = 0;
2180 return test_array [0];
2181
2182 ;
2183 return 0;
2184 }
2185 _ACEOF
2186 if ac_fn_c_try_compile "$LINENO"; then :
2187 ac_hi=$ac_mid
2188 else
2189 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2190 fi
2191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2192 done
2193 case $ac_lo in #((
2194 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2195 '') ac_retval=1 ;;
2196 esac
2197 else
2198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2199 /* end confdefs.h. */
2200 $4
2201 static long int longval () { return $2; }
2202 static unsigned long int ulongval () { return $2; }
2203 #include <stdio.h>
2204 #include <stdlib.h>
2205 int
2206 main ()
2207 {
2208
2209 FILE *f = fopen ("conftest.val", "w");
2210 if (! f)
2211 return 1;
2212 if (($2) < 0)
2213 {
2214 long int i = longval ();
2215 if (i != ($2))
2216 return 1;
2217 fprintf (f, "%ld", i);
2218 }
2219 else
2220 {
2221 unsigned long int i = ulongval ();
2222 if (i != ($2))
2223 return 1;
2224 fprintf (f, "%lu", i);
2225 }
2226 /* Do not output a trailing newline, as this causes \r\n confusion
2227 on some platforms. */
2228 return ferror (f) || fclose (f) != 0;
2229
2230 ;
2231 return 0;
2232 }
2233 _ACEOF
2234 if ac_fn_c_try_run "$LINENO"; then :
2235 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2236 else
2237 ac_retval=1
2238 fi
2239 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2240 conftest.$ac_objext conftest.beam conftest.$ac_ext
2241 rm -f conftest.val
2242
2243 fi
2244 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2245 as_fn_set_status $ac_retval
2246
2247 } # ac_fn_c_compute_int
2248
2249 # ac_fn_c_check_func LINENO FUNC VAR
2250 # ----------------------------------
2251 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2252 ac_fn_c_check_func ()
2253 {
2254 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2256 $as_echo_n "checking for $2... " >&6; }
2257 if eval \${$3+:} false; then :
2258 $as_echo_n "(cached) " >&6
2259 else
2260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2261 /* end confdefs.h. */
2262 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2263 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2264 #define $2 innocuous_$2
2265
2266 /* System header to define __stub macros and hopefully few prototypes,
2267 which can conflict with char $2 (); below.
2268 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2269 <limits.h> exists even on freestanding compilers. */
2270
2271 #ifdef __STDC__
2272 # include <limits.h>
2273 #else
2274 # include <assert.h>
2275 #endif
2276
2277 #undef $2
2278
2279 /* Override any GCC internal prototype to avoid an error.
2280 Use char because int might match the return type of a GCC
2281 builtin and then its argument prototype would still apply. */
2282 #ifdef __cplusplus
2283 extern "C"
2284 #endif
2285 char $2 ();
2286 /* The GNU C library defines this for functions which it implements
2287 to always fail with ENOSYS. Some functions are actually named
2288 something starting with __ and the normal name is an alias. */
2289 #if defined __stub_$2 || defined __stub___$2
2290 choke me
2291 #endif
2292
2293 int
2294 main ()
2295 {
2296 return $2 ();
2297 ;
2298 return 0;
2299 }
2300 _ACEOF
2301 if ac_fn_c_try_link "$LINENO"; then :
2302 eval "$3=yes"
2303 else
2304 eval "$3=no"
2305 fi
2306 rm -f core conftest.err conftest.$ac_objext \
2307 conftest$ac_exeext conftest.$ac_ext
2308 fi
2309 eval ac_res=\$$3
2310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2311 $as_echo "$ac_res" >&6; }
2312 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2313
2314 } # ac_fn_c_check_func
2315
2316 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2317 # ----------------------------------------------------
2318 # Tries to find if the field MEMBER exists in type AGGR, after including
2319 # INCLUDES, setting cache variable VAR accordingly.
2320 ac_fn_c_check_member ()
2321 {
2322 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2324 $as_echo_n "checking for $2.$3... " >&6; }
2325 if eval \${$4+:} false; then :
2326 $as_echo_n "(cached) " >&6
2327 else
2328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2329 /* end confdefs.h. */
2330 $5
2331 int
2332 main ()
2333 {
2334 static $2 ac_aggr;
2335 if (ac_aggr.$3)
2336 return 0;
2337 ;
2338 return 0;
2339 }
2340 _ACEOF
2341 if ac_fn_c_try_compile "$LINENO"; then :
2342 eval "$4=yes"
2343 else
2344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2345 /* end confdefs.h. */
2346 $5
2347 int
2348 main ()
2349 {
2350 static $2 ac_aggr;
2351 if (sizeof ac_aggr.$3)
2352 return 0;
2353 ;
2354 return 0;
2355 }
2356 _ACEOF
2357 if ac_fn_c_try_compile "$LINENO"; then :
2358 eval "$4=yes"
2359 else
2360 eval "$4=no"
2361 fi
2362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2363 fi
2364 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2365 fi
2366 eval ac_res=\$$4
2367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2368 $as_echo "$ac_res" >&6; }
2369 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2370
2371 } # ac_fn_c_check_member
2372
2373 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2374 # -------------------------------------------
2375 # Tests whether TYPE exists after having included INCLUDES, setting cache
2376 # variable VAR accordingly.
2377 ac_fn_c_check_type ()
2378 {
2379 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2381 $as_echo_n "checking for $2... " >&6; }
2382 if eval \${$3+:} false; then :
2383 $as_echo_n "(cached) " >&6
2384 else
2385 eval "$3=no"
2386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2387 /* end confdefs.h. */
2388 $4
2389 int
2390 main ()
2391 {
2392 if (sizeof ($2))
2393 return 0;
2394 ;
2395 return 0;
2396 }
2397 _ACEOF
2398 if ac_fn_c_try_compile "$LINENO"; then :
2399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2400 /* end confdefs.h. */
2401 $4
2402 int
2403 main ()
2404 {
2405 if (sizeof (($2)))
2406 return 0;
2407 ;
2408 return 0;
2409 }
2410 _ACEOF
2411 if ac_fn_c_try_compile "$LINENO"; then :
2412
2413 else
2414 eval "$3=yes"
2415 fi
2416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2417 fi
2418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2419 fi
2420 eval ac_res=\$$3
2421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2422 $as_echo "$ac_res" >&6; }
2423 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2424
2425 } # ac_fn_c_check_type
2426
2427 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2428 # ---------------------------------------------
2429 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2430 # accordingly.
2431 ac_fn_c_check_decl ()
2432 {
2433 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2434 as_decl_name=`echo $2|sed 's/ *(.*//'`
2435 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2437 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2438 if eval \${$3+:} false; then :
2439 $as_echo_n "(cached) " >&6
2440 else
2441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2442 /* end confdefs.h. */
2443 $4
2444 int
2445 main ()
2446 {
2447 #ifndef $as_decl_name
2448 #ifdef __cplusplus
2449 (void) $as_decl_use;
2450 #else
2451 (void) $as_decl_name;
2452 #endif
2453 #endif
2454
2455 ;
2456 return 0;
2457 }
2458 _ACEOF
2459 if ac_fn_c_try_compile "$LINENO"; then :
2460 eval "$3=yes"
2461 else
2462 eval "$3=no"
2463 fi
2464 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2465 fi
2466 eval ac_res=\$$3
2467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2468 $as_echo "$ac_res" >&6; }
2469 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2470
2471 } # ac_fn_c_check_decl
2472
2473 # ac_fn_cxx_try_link LINENO
2474 # -------------------------
2475 # Try to link conftest.$ac_ext, and return whether this succeeded.
2476 ac_fn_cxx_try_link ()
2477 {
2478 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2479 rm -f conftest.$ac_objext conftest$ac_exeext
2480 if { { ac_try="$ac_link"
2481 case "(($ac_try" in
2482 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2483 *) ac_try_echo=$ac_try;;
2484 esac
2485 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2486 $as_echo "$ac_try_echo"; } >&5
2487 (eval "$ac_link") 2>conftest.err
2488 ac_status=$?
2489 if test -s conftest.err; then
2490 grep -v '^ *+' conftest.err >conftest.er1
2491 cat conftest.er1 >&5
2492 mv -f conftest.er1 conftest.err
2493 fi
2494 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2495 test $ac_status = 0; } && {
2496 test -z "$ac_cxx_werror_flag" ||
2497 test ! -s conftest.err
2498 } && test -s conftest$ac_exeext && {
2499 test "$cross_compiling" = yes ||
2500 test -x conftest$ac_exeext
2501 }; then :
2502 ac_retval=0
2503 else
2504 $as_echo "$as_me: failed program was:" >&5
2505 sed 's/^/| /' conftest.$ac_ext >&5
2506
2507 ac_retval=1
2508 fi
2509 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2510 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2511 # interfere with the next link command; also delete a directory that is
2512 # left behind by Apple's compiler. We do this before executing the actions.
2513 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2514 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2515 as_fn_set_status $ac_retval
2516
2517 } # ac_fn_cxx_try_link
2518 cat >config.log <<_ACEOF
2519 This file contains any messages produced by compilers while
2520 running configure, to aid debugging if configure makes a mistake.
2521
2522 It was created by $as_me, which was
2523 generated by GNU Autoconf 2.69. Invocation command line was
2524
2525 $ $0 $@
2526
2527 _ACEOF
2528 exec 5>>config.log
2529 {
2530 cat <<_ASUNAME
2531 ## --------- ##
2532 ## Platform. ##
2533 ## --------- ##
2534
2535 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2536 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2537 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2538 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2539 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2540
2541 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2542 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2543
2544 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2545 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2546 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2547 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2548 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2549 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2550 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2551
2552 _ASUNAME
2553
2554 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2555 for as_dir in $PATH
2556 do
2557 IFS=$as_save_IFS
2558 test -z "$as_dir" && as_dir=.
2559 $as_echo "PATH: $as_dir"
2560 done
2561 IFS=$as_save_IFS
2562
2563 } >&5
2564
2565 cat >&5 <<_ACEOF
2566
2567
2568 ## ----------- ##
2569 ## Core tests. ##
2570 ## ----------- ##
2571
2572 _ACEOF
2573
2574
2575 # Keep a trace of the command line.
2576 # Strip out --no-create and --no-recursion so they do not pile up.
2577 # Strip out --silent because we don't want to record it for future runs.
2578 # Also quote any args containing shell meta-characters.
2579 # Make two passes to allow for proper duplicate-argument suppression.
2580 ac_configure_args=
2581 ac_configure_args0=
2582 ac_configure_args1=
2583 ac_must_keep_next=false
2584 for ac_pass in 1 2
2585 do
2586 for ac_arg
2587 do
2588 case $ac_arg in
2589 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2590 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2591 | -silent | --silent | --silen | --sile | --sil)
2592 continue ;;
2593 *\'*)
2594 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2595 esac
2596 case $ac_pass in
2597 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2598 2)
2599 as_fn_append ac_configure_args1 " '$ac_arg'"
2600 if test $ac_must_keep_next = true; then
2601 ac_must_keep_next=false # Got value, back to normal.
2602 else
2603 case $ac_arg in
2604 *=* | --config-cache | -C | -disable-* | --disable-* \
2605 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2606 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2607 | -with-* | --with-* | -without-* | --without-* | --x)
2608 case "$ac_configure_args0 " in
2609 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2610 esac
2611 ;;
2612 -* ) ac_must_keep_next=true ;;
2613 esac
2614 fi
2615 as_fn_append ac_configure_args " '$ac_arg'"
2616 ;;
2617 esac
2618 done
2619 done
2620 { ac_configure_args0=; unset ac_configure_args0;}
2621 { ac_configure_args1=; unset ac_configure_args1;}
2622
2623 # When interrupted or exit'd, cleanup temporary files, and complete
2624 # config.log. We remove comments because anyway the quotes in there
2625 # would cause problems or look ugly.
2626 # WARNING: Use '\'' to represent an apostrophe within the trap.
2627 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2628 trap 'exit_status=$?
2629 # Save into config.log some information that might help in debugging.
2630 {
2631 echo
2632
2633 $as_echo "## ---------------- ##
2634 ## Cache variables. ##
2635 ## ---------------- ##"
2636 echo
2637 # The following way of writing the cache mishandles newlines in values,
2638 (
2639 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2640 eval ac_val=\$$ac_var
2641 case $ac_val in #(
2642 *${as_nl}*)
2643 case $ac_var in #(
2644 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2645 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2646 esac
2647 case $ac_var in #(
2648 _ | IFS | as_nl) ;; #(
2649 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2650 *) { eval $ac_var=; unset $ac_var;} ;;
2651 esac ;;
2652 esac
2653 done
2654 (set) 2>&1 |
2655 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2656 *${as_nl}ac_space=\ *)
2657 sed -n \
2658 "s/'\''/'\''\\\\'\'''\''/g;
2659 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2660 ;; #(
2661 *)
2662 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2663 ;;
2664 esac |
2665 sort
2666 )
2667 echo
2668
2669 $as_echo "## ----------------- ##
2670 ## Output variables. ##
2671 ## ----------------- ##"
2672 echo
2673 for ac_var in $ac_subst_vars
2674 do
2675 eval ac_val=\$$ac_var
2676 case $ac_val in
2677 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2678 esac
2679 $as_echo "$ac_var='\''$ac_val'\''"
2680 done | sort
2681 echo
2682
2683 if test -n "$ac_subst_files"; then
2684 $as_echo "## ------------------- ##
2685 ## File substitutions. ##
2686 ## ------------------- ##"
2687 echo
2688 for ac_var in $ac_subst_files
2689 do
2690 eval ac_val=\$$ac_var
2691 case $ac_val in
2692 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2693 esac
2694 $as_echo "$ac_var='\''$ac_val'\''"
2695 done | sort
2696 echo
2697 fi
2698
2699 if test -s confdefs.h; then
2700 $as_echo "## ----------- ##
2701 ## confdefs.h. ##
2702 ## ----------- ##"
2703 echo
2704 cat confdefs.h
2705 echo
2706 fi
2707 test "$ac_signal" != 0 &&
2708 $as_echo "$as_me: caught signal $ac_signal"
2709 $as_echo "$as_me: exit $exit_status"
2710 } >&5
2711 rm -f core *.core core.conftest.* &&
2712 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2713 exit $exit_status
2714 ' 0
2715 for ac_signal in 1 2 13 15; do
2716 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2717 done
2718 ac_signal=0
2719
2720 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2721 rm -f -r conftest* confdefs.h
2722
2723 $as_echo "/* confdefs.h */" > confdefs.h
2724
2725 # Predefined preprocessor variables.
2726
2727 cat >>confdefs.h <<_ACEOF
2728 #define PACKAGE_NAME "$PACKAGE_NAME"
2729 _ACEOF
2730
2731 cat >>confdefs.h <<_ACEOF
2732 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2733 _ACEOF
2734
2735 cat >>confdefs.h <<_ACEOF
2736 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2737 _ACEOF
2738
2739 cat >>confdefs.h <<_ACEOF
2740 #define PACKAGE_STRING "$PACKAGE_STRING"
2741 _ACEOF
2742
2743 cat >>confdefs.h <<_ACEOF
2744 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2745 _ACEOF
2746
2747 cat >>confdefs.h <<_ACEOF
2748 #define PACKAGE_URL "$PACKAGE_URL"
2749 _ACEOF
2750
2751
2752 # Let the site file select an alternate cache file if it wants to.
2753 # Prefer an explicitly selected file to automatically selected ones.
2754 ac_site_file1=NONE
2755 ac_site_file2=NONE
2756 if test -n "$CONFIG_SITE"; then
2757 # We do not want a PATH search for config.site.
2758 case $CONFIG_SITE in #((
2759 -*) ac_site_file1=./$CONFIG_SITE;;
2760 */*) ac_site_file1=$CONFIG_SITE;;
2761 *) ac_site_file1=./$CONFIG_SITE;;
2762 esac
2763 elif test "x$prefix" != xNONE; then
2764 ac_site_file1=$prefix/share/config.site
2765 ac_site_file2=$prefix/etc/config.site
2766 else
2767 ac_site_file1=$ac_default_prefix/share/config.site
2768 ac_site_file2=$ac_default_prefix/etc/config.site
2769 fi
2770 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2771 do
2772 test "x$ac_site_file" = xNONE && continue
2773 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2774 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2775 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2776 sed 's/^/| /' "$ac_site_file" >&5
2777 . "$ac_site_file" \
2778 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2779 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2780 as_fn_error $? "failed to load site script $ac_site_file
2781 See \`config.log' for more details" "$LINENO" 5; }
2782 fi
2783 done
2784
2785 if test -r "$cache_file"; then
2786 # Some versions of bash will fail to source /dev/null (special files
2787 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2788 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2789 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2790 $as_echo "$as_me: loading cache $cache_file" >&6;}
2791 case $cache_file in
2792 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2793 *) . "./$cache_file";;
2794 esac
2795 fi
2796 else
2797 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2798 $as_echo "$as_me: creating cache $cache_file" >&6;}
2799 >$cache_file
2800 fi
2801
2802 as_fn_append ac_header_list " stdlib.h"
2803 as_fn_append ac_header_list " unistd.h"
2804 as_fn_append ac_header_list " sys/param.h"
2805 # Check that the precious variables saved in the cache have kept the same
2806 # value.
2807 ac_cache_corrupted=false
2808 for ac_var in $ac_precious_vars; do
2809 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2810 eval ac_new_set=\$ac_env_${ac_var}_set
2811 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2812 eval ac_new_val=\$ac_env_${ac_var}_value
2813 case $ac_old_set,$ac_new_set in
2814 set,)
2815 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2816 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2817 ac_cache_corrupted=: ;;
2818 ,set)
2819 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2820 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2821 ac_cache_corrupted=: ;;
2822 ,);;
2823 *)
2824 if test "x$ac_old_val" != "x$ac_new_val"; then
2825 # differences in whitespace do not lead to failure.
2826 ac_old_val_w=`echo x $ac_old_val`
2827 ac_new_val_w=`echo x $ac_new_val`
2828 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2829 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2830 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2831 ac_cache_corrupted=:
2832 else
2833 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2834 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2835 eval $ac_var=\$ac_old_val
2836 fi
2837 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2838 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2839 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2840 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2841 fi;;
2842 esac
2843 # Pass precious variables to config.status.
2844 if test "$ac_new_set" = set; then
2845 case $ac_new_val in
2846 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2847 *) ac_arg=$ac_var=$ac_new_val ;;
2848 esac
2849 case " $ac_configure_args " in
2850 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2851 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2852 esac
2853 fi
2854 done
2855 if $ac_cache_corrupted; then
2856 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2857 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2858 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2859 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2860 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2861 fi
2862 ## -------------------- ##
2863 ## Main body of script. ##
2864 ## -------------------- ##
2865
2866 ac_ext=c
2867 ac_cpp='$CPP $CPPFLAGS'
2868 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2869 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2870 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2871
2872
2873
2874
2875
2876 ac_config_headers="$ac_config_headers config.h:config.in"
2877
2878
2879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2880 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2881 # Check whether --enable-maintainer-mode was given.
2882 if test "${enable_maintainer_mode+set}" = set; then :
2883 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2884 else
2885 USE_MAINTAINER_MODE=no
2886 fi
2887
2888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2889 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2890 if test $USE_MAINTAINER_MODE = yes; then
2891 MAINTAINER_MODE_TRUE=
2892 MAINTAINER_MODE_FALSE='#'
2893 else
2894 MAINTAINER_MODE_TRUE='#'
2895 MAINTAINER_MODE_FALSE=
2896 fi
2897
2898 MAINT=$MAINTAINER_MODE_TRUE
2899
2900
2901
2902 # Set the 'development' global.
2903 . $srcdir/../bfd/development.sh
2904
2905 ac_ext=c
2906 ac_cpp='$CPP $CPPFLAGS'
2907 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2908 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2909 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2910 if test -n "$ac_tool_prefix"; then
2911 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2912 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2914 $as_echo_n "checking for $ac_word... " >&6; }
2915 if ${ac_cv_prog_CC+:} false; then :
2916 $as_echo_n "(cached) " >&6
2917 else
2918 if test -n "$CC"; then
2919 ac_cv_prog_CC="$CC" # Let the user override the test.
2920 else
2921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2922 for as_dir in $PATH
2923 do
2924 IFS=$as_save_IFS
2925 test -z "$as_dir" && as_dir=.
2926 for ac_exec_ext in '' $ac_executable_extensions; do
2927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2928 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2930 break 2
2931 fi
2932 done
2933 done
2934 IFS=$as_save_IFS
2935
2936 fi
2937 fi
2938 CC=$ac_cv_prog_CC
2939 if test -n "$CC"; then
2940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2941 $as_echo "$CC" >&6; }
2942 else
2943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2944 $as_echo "no" >&6; }
2945 fi
2946
2947
2948 fi
2949 if test -z "$ac_cv_prog_CC"; then
2950 ac_ct_CC=$CC
2951 # Extract the first word of "gcc", so it can be a program name with args.
2952 set dummy gcc; ac_word=$2
2953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2954 $as_echo_n "checking for $ac_word... " >&6; }
2955 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2956 $as_echo_n "(cached) " >&6
2957 else
2958 if test -n "$ac_ct_CC"; then
2959 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2960 else
2961 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2962 for as_dir in $PATH
2963 do
2964 IFS=$as_save_IFS
2965 test -z "$as_dir" && as_dir=.
2966 for ac_exec_ext in '' $ac_executable_extensions; do
2967 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2968 ac_cv_prog_ac_ct_CC="gcc"
2969 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2970 break 2
2971 fi
2972 done
2973 done
2974 IFS=$as_save_IFS
2975
2976 fi
2977 fi
2978 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2979 if test -n "$ac_ct_CC"; then
2980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2981 $as_echo "$ac_ct_CC" >&6; }
2982 else
2983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2984 $as_echo "no" >&6; }
2985 fi
2986
2987 if test "x$ac_ct_CC" = x; then
2988 CC=""
2989 else
2990 case $cross_compiling:$ac_tool_warned in
2991 yes:)
2992 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2993 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2994 ac_tool_warned=yes ;;
2995 esac
2996 CC=$ac_ct_CC
2997 fi
2998 else
2999 CC="$ac_cv_prog_CC"
3000 fi
3001
3002 if test -z "$CC"; then
3003 if test -n "$ac_tool_prefix"; then
3004 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3005 set dummy ${ac_tool_prefix}cc; ac_word=$2
3006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3007 $as_echo_n "checking for $ac_word... " >&6; }
3008 if ${ac_cv_prog_CC+:} false; then :
3009 $as_echo_n "(cached) " >&6
3010 else
3011 if test -n "$CC"; then
3012 ac_cv_prog_CC="$CC" # Let the user override the test.
3013 else
3014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3015 for as_dir in $PATH
3016 do
3017 IFS=$as_save_IFS
3018 test -z "$as_dir" && as_dir=.
3019 for ac_exec_ext in '' $ac_executable_extensions; do
3020 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3021 ac_cv_prog_CC="${ac_tool_prefix}cc"
3022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3023 break 2
3024 fi
3025 done
3026 done
3027 IFS=$as_save_IFS
3028
3029 fi
3030 fi
3031 CC=$ac_cv_prog_CC
3032 if test -n "$CC"; then
3033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3034 $as_echo "$CC" >&6; }
3035 else
3036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3037 $as_echo "no" >&6; }
3038 fi
3039
3040
3041 fi
3042 fi
3043 if test -z "$CC"; then
3044 # Extract the first word of "cc", so it can be a program name with args.
3045 set dummy cc; ac_word=$2
3046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3047 $as_echo_n "checking for $ac_word... " >&6; }
3048 if ${ac_cv_prog_CC+:} false; then :
3049 $as_echo_n "(cached) " >&6
3050 else
3051 if test -n "$CC"; then
3052 ac_cv_prog_CC="$CC" # Let the user override the test.
3053 else
3054 ac_prog_rejected=no
3055 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3056 for as_dir in $PATH
3057 do
3058 IFS=$as_save_IFS
3059 test -z "$as_dir" && as_dir=.
3060 for ac_exec_ext in '' $ac_executable_extensions; do
3061 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3062 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3063 ac_prog_rejected=yes
3064 continue
3065 fi
3066 ac_cv_prog_CC="cc"
3067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3068 break 2
3069 fi
3070 done
3071 done
3072 IFS=$as_save_IFS
3073
3074 if test $ac_prog_rejected = yes; then
3075 # We found a bogon in the path, so make sure we never use it.
3076 set dummy $ac_cv_prog_CC
3077 shift
3078 if test $# != 0; then
3079 # We chose a different compiler from the bogus one.
3080 # However, it has the same basename, so the bogon will be chosen
3081 # first if we set CC to just the basename; use the full file name.
3082 shift
3083 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3084 fi
3085 fi
3086 fi
3087 fi
3088 CC=$ac_cv_prog_CC
3089 if test -n "$CC"; then
3090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3091 $as_echo "$CC" >&6; }
3092 else
3093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3094 $as_echo "no" >&6; }
3095 fi
3096
3097
3098 fi
3099 if test -z "$CC"; then
3100 if test -n "$ac_tool_prefix"; then
3101 for ac_prog in cl.exe
3102 do
3103 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3104 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3106 $as_echo_n "checking for $ac_word... " >&6; }
3107 if ${ac_cv_prog_CC+:} false; then :
3108 $as_echo_n "(cached) " >&6
3109 else
3110 if test -n "$CC"; then
3111 ac_cv_prog_CC="$CC" # Let the user override the test.
3112 else
3113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3114 for as_dir in $PATH
3115 do
3116 IFS=$as_save_IFS
3117 test -z "$as_dir" && as_dir=.
3118 for ac_exec_ext in '' $ac_executable_extensions; do
3119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3120 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3122 break 2
3123 fi
3124 done
3125 done
3126 IFS=$as_save_IFS
3127
3128 fi
3129 fi
3130 CC=$ac_cv_prog_CC
3131 if test -n "$CC"; then
3132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3133 $as_echo "$CC" >&6; }
3134 else
3135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3136 $as_echo "no" >&6; }
3137 fi
3138
3139
3140 test -n "$CC" && break
3141 done
3142 fi
3143 if test -z "$CC"; then
3144 ac_ct_CC=$CC
3145 for ac_prog in cl.exe
3146 do
3147 # Extract the first word of "$ac_prog", so it can be a program name with args.
3148 set dummy $ac_prog; ac_word=$2
3149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3150 $as_echo_n "checking for $ac_word... " >&6; }
3151 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3152 $as_echo_n "(cached) " >&6
3153 else
3154 if test -n "$ac_ct_CC"; then
3155 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3156 else
3157 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3158 for as_dir in $PATH
3159 do
3160 IFS=$as_save_IFS
3161 test -z "$as_dir" && as_dir=.
3162 for ac_exec_ext in '' $ac_executable_extensions; do
3163 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3164 ac_cv_prog_ac_ct_CC="$ac_prog"
3165 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3166 break 2
3167 fi
3168 done
3169 done
3170 IFS=$as_save_IFS
3171
3172 fi
3173 fi
3174 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3175 if test -n "$ac_ct_CC"; then
3176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3177 $as_echo "$ac_ct_CC" >&6; }
3178 else
3179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3180 $as_echo "no" >&6; }
3181 fi
3182
3183
3184 test -n "$ac_ct_CC" && break
3185 done
3186
3187 if test "x$ac_ct_CC" = x; then
3188 CC=""
3189 else
3190 case $cross_compiling:$ac_tool_warned in
3191 yes:)
3192 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3193 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3194 ac_tool_warned=yes ;;
3195 esac
3196 CC=$ac_ct_CC
3197 fi
3198 fi
3199
3200 fi
3201
3202
3203 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3204 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3205 as_fn_error $? "no acceptable C compiler found in \$PATH
3206 See \`config.log' for more details" "$LINENO" 5; }
3207
3208 # Provide some information about the compiler.
3209 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3210 set X $ac_compile
3211 ac_compiler=$2
3212 for ac_option in --version -v -V -qversion; do
3213 { { ac_try="$ac_compiler $ac_option >&5"
3214 case "(($ac_try" in
3215 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3216 *) ac_try_echo=$ac_try;;
3217 esac
3218 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3219 $as_echo "$ac_try_echo"; } >&5
3220 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3221 ac_status=$?
3222 if test -s conftest.err; then
3223 sed '10a\
3224 ... rest of stderr output deleted ...
3225 10q' conftest.err >conftest.er1
3226 cat conftest.er1 >&5
3227 fi
3228 rm -f conftest.er1 conftest.err
3229 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3230 test $ac_status = 0; }
3231 done
3232
3233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3234 /* end confdefs.h. */
3235
3236 int
3237 main ()
3238 {
3239
3240 ;
3241 return 0;
3242 }
3243 _ACEOF
3244 ac_clean_files_save=$ac_clean_files
3245 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3246 # Try to create an executable without -o first, disregard a.out.
3247 # It will help us diagnose broken compilers, and finding out an intuition
3248 # of exeext.
3249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3250 $as_echo_n "checking whether the C compiler works... " >&6; }
3251 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3252
3253 # The possible output files:
3254 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3255
3256 ac_rmfiles=
3257 for ac_file in $ac_files
3258 do
3259 case $ac_file in
3260 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3261 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3262 esac
3263 done
3264 rm -f $ac_rmfiles
3265
3266 if { { ac_try="$ac_link_default"
3267 case "(($ac_try" in
3268 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3269 *) ac_try_echo=$ac_try;;
3270 esac
3271 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3272 $as_echo "$ac_try_echo"; } >&5
3273 (eval "$ac_link_default") 2>&5
3274 ac_status=$?
3275 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3276 test $ac_status = 0; }; then :
3277 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3278 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3279 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3280 # so that the user can short-circuit this test for compilers unknown to
3281 # Autoconf.
3282 for ac_file in $ac_files ''
3283 do
3284 test -f "$ac_file" || continue
3285 case $ac_file in
3286 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3287 ;;
3288 [ab].out )
3289 # We found the default executable, but exeext='' is most
3290 # certainly right.
3291 break;;
3292 *.* )
3293 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3294 then :; else
3295 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3296 fi
3297 # We set ac_cv_exeext here because the later test for it is not
3298 # safe: cross compilers may not add the suffix if given an `-o'
3299 # argument, so we may need to know it at that point already.
3300 # Even if this section looks crufty: it has the advantage of
3301 # actually working.
3302 break;;
3303 * )
3304 break;;
3305 esac
3306 done
3307 test "$ac_cv_exeext" = no && ac_cv_exeext=
3308
3309 else
3310 ac_file=''
3311 fi
3312 if test -z "$ac_file"; then :
3313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3314 $as_echo "no" >&6; }
3315 $as_echo "$as_me: failed program was:" >&5
3316 sed 's/^/| /' conftest.$ac_ext >&5
3317
3318 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3319 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3320 as_fn_error 77 "C compiler cannot create executables
3321 See \`config.log' for more details" "$LINENO" 5; }
3322 else
3323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3324 $as_echo "yes" >&6; }
3325 fi
3326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3327 $as_echo_n "checking for C compiler default output file name... " >&6; }
3328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3329 $as_echo "$ac_file" >&6; }
3330 ac_exeext=$ac_cv_exeext
3331
3332 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3333 ac_clean_files=$ac_clean_files_save
3334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3335 $as_echo_n "checking for suffix of executables... " >&6; }
3336 if { { ac_try="$ac_link"
3337 case "(($ac_try" in
3338 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3339 *) ac_try_echo=$ac_try;;
3340 esac
3341 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3342 $as_echo "$ac_try_echo"; } >&5
3343 (eval "$ac_link") 2>&5
3344 ac_status=$?
3345 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3346 test $ac_status = 0; }; then :
3347 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3348 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3349 # work properly (i.e., refer to `conftest.exe'), while it won't with
3350 # `rm'.
3351 for ac_file in conftest.exe conftest conftest.*; do
3352 test -f "$ac_file" || continue
3353 case $ac_file in
3354 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3355 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3356 break;;
3357 * ) break;;
3358 esac
3359 done
3360 else
3361 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3362 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3363 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3364 See \`config.log' for more details" "$LINENO" 5; }
3365 fi
3366 rm -f conftest conftest$ac_cv_exeext
3367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3368 $as_echo "$ac_cv_exeext" >&6; }
3369
3370 rm -f conftest.$ac_ext
3371 EXEEXT=$ac_cv_exeext
3372 ac_exeext=$EXEEXT
3373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3374 /* end confdefs.h. */
3375 #include <stdio.h>
3376 int
3377 main ()
3378 {
3379 FILE *f = fopen ("conftest.out", "w");
3380 return ferror (f) || fclose (f) != 0;
3381
3382 ;
3383 return 0;
3384 }
3385 _ACEOF
3386 ac_clean_files="$ac_clean_files conftest.out"
3387 # Check that the compiler produces executables we can run. If not, either
3388 # the compiler is broken, or we cross compile.
3389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3390 $as_echo_n "checking whether we are cross compiling... " >&6; }
3391 if test "$cross_compiling" != yes; then
3392 { { ac_try="$ac_link"
3393 case "(($ac_try" in
3394 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3395 *) ac_try_echo=$ac_try;;
3396 esac
3397 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3398 $as_echo "$ac_try_echo"; } >&5
3399 (eval "$ac_link") 2>&5
3400 ac_status=$?
3401 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3402 test $ac_status = 0; }
3403 if { ac_try='./conftest$ac_cv_exeext'
3404 { { case "(($ac_try" in
3405 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3406 *) ac_try_echo=$ac_try;;
3407 esac
3408 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3409 $as_echo "$ac_try_echo"; } >&5
3410 (eval "$ac_try") 2>&5
3411 ac_status=$?
3412 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3413 test $ac_status = 0; }; }; then
3414 cross_compiling=no
3415 else
3416 if test "$cross_compiling" = maybe; then
3417 cross_compiling=yes
3418 else
3419 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3420 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3421 as_fn_error $? "cannot run C compiled programs.
3422 If you meant to cross compile, use \`--host'.
3423 See \`config.log' for more details" "$LINENO" 5; }
3424 fi
3425 fi
3426 fi
3427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3428 $as_echo "$cross_compiling" >&6; }
3429
3430 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3431 ac_clean_files=$ac_clean_files_save
3432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3433 $as_echo_n "checking for suffix of object files... " >&6; }
3434 if ${ac_cv_objext+:} false; then :
3435 $as_echo_n "(cached) " >&6
3436 else
3437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3438 /* end confdefs.h. */
3439
3440 int
3441 main ()
3442 {
3443
3444 ;
3445 return 0;
3446 }
3447 _ACEOF
3448 rm -f conftest.o conftest.obj
3449 if { { ac_try="$ac_compile"
3450 case "(($ac_try" in
3451 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3452 *) ac_try_echo=$ac_try;;
3453 esac
3454 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3455 $as_echo "$ac_try_echo"; } >&5
3456 (eval "$ac_compile") 2>&5
3457 ac_status=$?
3458 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3459 test $ac_status = 0; }; then :
3460 for ac_file in conftest.o conftest.obj conftest.*; do
3461 test -f "$ac_file" || continue;
3462 case $ac_file in
3463 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3464 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3465 break;;
3466 esac
3467 done
3468 else
3469 $as_echo "$as_me: failed program was:" >&5
3470 sed 's/^/| /' conftest.$ac_ext >&5
3471
3472 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3473 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3474 as_fn_error $? "cannot compute suffix of object files: cannot compile
3475 See \`config.log' for more details" "$LINENO" 5; }
3476 fi
3477 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3478 fi
3479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3480 $as_echo "$ac_cv_objext" >&6; }
3481 OBJEXT=$ac_cv_objext
3482 ac_objext=$OBJEXT
3483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3484 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3485 if ${ac_cv_c_compiler_gnu+:} false; then :
3486 $as_echo_n "(cached) " >&6
3487 else
3488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3489 /* end confdefs.h. */
3490
3491 int
3492 main ()
3493 {
3494 #ifndef __GNUC__
3495 choke me
3496 #endif
3497
3498 ;
3499 return 0;
3500 }
3501 _ACEOF
3502 if ac_fn_c_try_compile "$LINENO"; then :
3503 ac_compiler_gnu=yes
3504 else
3505 ac_compiler_gnu=no
3506 fi
3507 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3508 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3509
3510 fi
3511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3512 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3513 if test $ac_compiler_gnu = yes; then
3514 GCC=yes
3515 else
3516 GCC=
3517 fi
3518 ac_test_CFLAGS=${CFLAGS+set}
3519 ac_save_CFLAGS=$CFLAGS
3520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3521 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3522 if ${ac_cv_prog_cc_g+:} false; then :
3523 $as_echo_n "(cached) " >&6
3524 else
3525 ac_save_c_werror_flag=$ac_c_werror_flag
3526 ac_c_werror_flag=yes
3527 ac_cv_prog_cc_g=no
3528 CFLAGS="-g"
3529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3530 /* end confdefs.h. */
3531
3532 int
3533 main ()
3534 {
3535
3536 ;
3537 return 0;
3538 }
3539 _ACEOF
3540 if ac_fn_c_try_compile "$LINENO"; then :
3541 ac_cv_prog_cc_g=yes
3542 else
3543 CFLAGS=""
3544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3545 /* end confdefs.h. */
3546
3547 int
3548 main ()
3549 {
3550
3551 ;
3552 return 0;
3553 }
3554 _ACEOF
3555 if ac_fn_c_try_compile "$LINENO"; then :
3556
3557 else
3558 ac_c_werror_flag=$ac_save_c_werror_flag
3559 CFLAGS="-g"
3560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3561 /* end confdefs.h. */
3562
3563 int
3564 main ()
3565 {
3566
3567 ;
3568 return 0;
3569 }
3570 _ACEOF
3571 if ac_fn_c_try_compile "$LINENO"; then :
3572 ac_cv_prog_cc_g=yes
3573 fi
3574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3575 fi
3576 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3577 fi
3578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3579 ac_c_werror_flag=$ac_save_c_werror_flag
3580 fi
3581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3582 $as_echo "$ac_cv_prog_cc_g" >&6; }
3583 if test "$ac_test_CFLAGS" = set; then
3584 CFLAGS=$ac_save_CFLAGS
3585 elif test $ac_cv_prog_cc_g = yes; then
3586 if test "$GCC" = yes; then
3587 CFLAGS="-g -O2"
3588 else
3589 CFLAGS="-g"
3590 fi
3591 else
3592 if test "$GCC" = yes; then
3593 CFLAGS="-O2"
3594 else
3595 CFLAGS=
3596 fi
3597 fi
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3599 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3600 if ${ac_cv_prog_cc_c89+:} false; then :
3601 $as_echo_n "(cached) " >&6
3602 else
3603 ac_cv_prog_cc_c89=no
3604 ac_save_CC=$CC
3605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3606 /* end confdefs.h. */
3607 #include <stdarg.h>
3608 #include <stdio.h>
3609 struct stat;
3610 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3611 struct buf { int x; };
3612 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3613 static char *e (p, i)
3614 char **p;
3615 int i;
3616 {
3617 return p[i];
3618 }
3619 static char *f (char * (*g) (char **, int), char **p, ...)
3620 {
3621 char *s;
3622 va_list v;
3623 va_start (v,p);
3624 s = g (p, va_arg (v,int));
3625 va_end (v);
3626 return s;
3627 }
3628
3629 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3630 function prototypes and stuff, but not '\xHH' hex character constants.
3631 These don't provoke an error unfortunately, instead are silently treated
3632 as 'x'. The following induces an error, until -std is added to get
3633 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3634 array size at least. It's necessary to write '\x00'==0 to get something
3635 that's true only with -std. */
3636 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3637
3638 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3639 inside strings and character constants. */
3640 #define FOO(x) 'x'
3641 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3642
3643 int test (int i, double x);
3644 struct s1 {int (*f) (int a);};
3645 struct s2 {int (*f) (double a);};
3646 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3647 int argc;
3648 char **argv;
3649 int
3650 main ()
3651 {
3652 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3653 ;
3654 return 0;
3655 }
3656 _ACEOF
3657 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3658 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3659 do
3660 CC="$ac_save_CC $ac_arg"
3661 if ac_fn_c_try_compile "$LINENO"; then :
3662 ac_cv_prog_cc_c89=$ac_arg
3663 fi
3664 rm -f core conftest.err conftest.$ac_objext
3665 test "x$ac_cv_prog_cc_c89" != "xno" && break
3666 done
3667 rm -f conftest.$ac_ext
3668 CC=$ac_save_CC
3669
3670 fi
3671 # AC_CACHE_VAL
3672 case "x$ac_cv_prog_cc_c89" in
3673 x)
3674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3675 $as_echo "none needed" >&6; } ;;
3676 xno)
3677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3678 $as_echo "unsupported" >&6; } ;;
3679 *)
3680 CC="$CC $ac_cv_prog_cc_c89"
3681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3682 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3683 esac
3684 if test "x$ac_cv_prog_cc_c89" != xno; then :
3685
3686 fi
3687
3688 ac_ext=c
3689 ac_cpp='$CPP $CPPFLAGS'
3690 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3691 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3692 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3693
3694 ac_ext=cpp
3695 ac_cpp='$CXXCPP $CPPFLAGS'
3696 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3697 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3698 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3699 if test -z "$CXX"; then
3700 if test -n "$CCC"; then
3701 CXX=$CCC
3702 else
3703 if test -n "$ac_tool_prefix"; then
3704 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3705 do
3706 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3707 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3709 $as_echo_n "checking for $ac_word... " >&6; }
3710 if ${ac_cv_prog_CXX+:} false; then :
3711 $as_echo_n "(cached) " >&6
3712 else
3713 if test -n "$CXX"; then
3714 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3715 else
3716 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3717 for as_dir in $PATH
3718 do
3719 IFS=$as_save_IFS
3720 test -z "$as_dir" && as_dir=.
3721 for ac_exec_ext in '' $ac_executable_extensions; do
3722 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3723 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3724 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3725 break 2
3726 fi
3727 done
3728 done
3729 IFS=$as_save_IFS
3730
3731 fi
3732 fi
3733 CXX=$ac_cv_prog_CXX
3734 if test -n "$CXX"; then
3735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3736 $as_echo "$CXX" >&6; }
3737 else
3738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3739 $as_echo "no" >&6; }
3740 fi
3741
3742
3743 test -n "$CXX" && break
3744 done
3745 fi
3746 if test -z "$CXX"; then
3747 ac_ct_CXX=$CXX
3748 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3749 do
3750 # Extract the first word of "$ac_prog", so it can be a program name with args.
3751 set dummy $ac_prog; ac_word=$2
3752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3753 $as_echo_n "checking for $ac_word... " >&6; }
3754 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3755 $as_echo_n "(cached) " >&6
3756 else
3757 if test -n "$ac_ct_CXX"; then
3758 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3759 else
3760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3761 for as_dir in $PATH
3762 do
3763 IFS=$as_save_IFS
3764 test -z "$as_dir" && as_dir=.
3765 for ac_exec_ext in '' $ac_executable_extensions; do
3766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3767 ac_cv_prog_ac_ct_CXX="$ac_prog"
3768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3769 break 2
3770 fi
3771 done
3772 done
3773 IFS=$as_save_IFS
3774
3775 fi
3776 fi
3777 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3778 if test -n "$ac_ct_CXX"; then
3779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3780 $as_echo "$ac_ct_CXX" >&6; }
3781 else
3782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3783 $as_echo "no" >&6; }
3784 fi
3785
3786
3787 test -n "$ac_ct_CXX" && break
3788 done
3789
3790 if test "x$ac_ct_CXX" = x; then
3791 CXX="g++"
3792 else
3793 case $cross_compiling:$ac_tool_warned in
3794 yes:)
3795 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3796 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3797 ac_tool_warned=yes ;;
3798 esac
3799 CXX=$ac_ct_CXX
3800 fi
3801 fi
3802
3803 fi
3804 fi
3805 # Provide some information about the compiler.
3806 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3807 set X $ac_compile
3808 ac_compiler=$2
3809 for ac_option in --version -v -V -qversion; do
3810 { { ac_try="$ac_compiler $ac_option >&5"
3811 case "(($ac_try" in
3812 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3813 *) ac_try_echo=$ac_try;;
3814 esac
3815 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3816 $as_echo "$ac_try_echo"; } >&5
3817 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3818 ac_status=$?
3819 if test -s conftest.err; then
3820 sed '10a\
3821 ... rest of stderr output deleted ...
3822 10q' conftest.err >conftest.er1
3823 cat conftest.er1 >&5
3824 fi
3825 rm -f conftest.er1 conftest.err
3826 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3827 test $ac_status = 0; }
3828 done
3829
3830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3831 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3832 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3833 $as_echo_n "(cached) " >&6
3834 else
3835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3836 /* end confdefs.h. */
3837
3838 int
3839 main ()
3840 {
3841 #ifndef __GNUC__
3842 choke me
3843 #endif
3844
3845 ;
3846 return 0;
3847 }
3848 _ACEOF
3849 if ac_fn_cxx_try_compile "$LINENO"; then :
3850 ac_compiler_gnu=yes
3851 else
3852 ac_compiler_gnu=no
3853 fi
3854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3855 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3856
3857 fi
3858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3859 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3860 if test $ac_compiler_gnu = yes; then
3861 GXX=yes
3862 else
3863 GXX=
3864 fi
3865 ac_test_CXXFLAGS=${CXXFLAGS+set}
3866 ac_save_CXXFLAGS=$CXXFLAGS
3867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3868 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3869 if ${ac_cv_prog_cxx_g+:} false; then :
3870 $as_echo_n "(cached) " >&6
3871 else
3872 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3873 ac_cxx_werror_flag=yes
3874 ac_cv_prog_cxx_g=no
3875 CXXFLAGS="-g"
3876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3877 /* end confdefs.h. */
3878
3879 int
3880 main ()
3881 {
3882
3883 ;
3884 return 0;
3885 }
3886 _ACEOF
3887 if ac_fn_cxx_try_compile "$LINENO"; then :
3888 ac_cv_prog_cxx_g=yes
3889 else
3890 CXXFLAGS=""
3891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3892 /* end confdefs.h. */
3893
3894 int
3895 main ()
3896 {
3897
3898 ;
3899 return 0;
3900 }
3901 _ACEOF
3902 if ac_fn_cxx_try_compile "$LINENO"; then :
3903
3904 else
3905 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3906 CXXFLAGS="-g"
3907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3908 /* end confdefs.h. */
3909
3910 int
3911 main ()
3912 {
3913
3914 ;
3915 return 0;
3916 }
3917 _ACEOF
3918 if ac_fn_cxx_try_compile "$LINENO"; then :
3919 ac_cv_prog_cxx_g=yes
3920 fi
3921 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3922 fi
3923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3924 fi
3925 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3926 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3927 fi
3928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3929 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3930 if test "$ac_test_CXXFLAGS" = set; then
3931 CXXFLAGS=$ac_save_CXXFLAGS
3932 elif test $ac_cv_prog_cxx_g = yes; then
3933 if test "$GXX" = yes; then
3934 CXXFLAGS="-g -O2"
3935 else
3936 CXXFLAGS="-g"
3937 fi
3938 else
3939 if test "$GXX" = yes; then
3940 CXXFLAGS="-O2"
3941 else
3942 CXXFLAGS=
3943 fi
3944 fi
3945 ac_ext=c
3946 ac_cpp='$CPP $CPPFLAGS'
3947 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3948 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3949 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3950
3951
3952
3953 ac_ext=c
3954 ac_cpp='$CPP $CPPFLAGS'
3955 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3956 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3957 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3959 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3960 # On Suns, sometimes $CPP names a directory.
3961 if test -n "$CPP" && test -d "$CPP"; then
3962 CPP=
3963 fi
3964 if test -z "$CPP"; then
3965 if ${ac_cv_prog_CPP+:} false; then :
3966 $as_echo_n "(cached) " >&6
3967 else
3968 # Double quotes because CPP needs to be expanded
3969 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3970 do
3971 ac_preproc_ok=false
3972 for ac_c_preproc_warn_flag in '' yes
3973 do
3974 # Use a header file that comes with gcc, so configuring glibc
3975 # with a fresh cross-compiler works.
3976 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3977 # <limits.h> exists even on freestanding compilers.
3978 # On the NeXT, cc -E runs the code through the compiler's parser,
3979 # not just through cpp. "Syntax error" is here to catch this case.
3980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3981 /* end confdefs.h. */
3982 #ifdef __STDC__
3983 # include <limits.h>
3984 #else
3985 # include <assert.h>
3986 #endif
3987 Syntax error
3988 _ACEOF
3989 if ac_fn_c_try_cpp "$LINENO"; then :
3990
3991 else
3992 # Broken: fails on valid input.
3993 continue
3994 fi
3995 rm -f conftest.err conftest.i conftest.$ac_ext
3996
3997 # OK, works on sane cases. Now check whether nonexistent headers
3998 # can be detected and how.
3999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4000 /* end confdefs.h. */
4001 #include <ac_nonexistent.h>
4002 _ACEOF
4003 if ac_fn_c_try_cpp "$LINENO"; then :
4004 # Broken: success on invalid input.
4005 continue
4006 else
4007 # Passes both tests.
4008 ac_preproc_ok=:
4009 break
4010 fi
4011 rm -f conftest.err conftest.i conftest.$ac_ext
4012
4013 done
4014 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4015 rm -f conftest.i conftest.err conftest.$ac_ext
4016 if $ac_preproc_ok; then :
4017 break
4018 fi
4019
4020 done
4021 ac_cv_prog_CPP=$CPP
4022
4023 fi
4024 CPP=$ac_cv_prog_CPP
4025 else
4026 ac_cv_prog_CPP=$CPP
4027 fi
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4029 $as_echo "$CPP" >&6; }
4030 ac_preproc_ok=false
4031 for ac_c_preproc_warn_flag in '' yes
4032 do
4033 # Use a header file that comes with gcc, so configuring glibc
4034 # with a fresh cross-compiler works.
4035 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4036 # <limits.h> exists even on freestanding compilers.
4037 # On the NeXT, cc -E runs the code through the compiler's parser,
4038 # not just through cpp. "Syntax error" is here to catch this case.
4039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4040 /* end confdefs.h. */
4041 #ifdef __STDC__
4042 # include <limits.h>
4043 #else
4044 # include <assert.h>
4045 #endif
4046 Syntax error
4047 _ACEOF
4048 if ac_fn_c_try_cpp "$LINENO"; then :
4049
4050 else
4051 # Broken: fails on valid input.
4052 continue
4053 fi
4054 rm -f conftest.err conftest.i conftest.$ac_ext
4055
4056 # OK, works on sane cases. Now check whether nonexistent headers
4057 # can be detected and how.
4058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4059 /* end confdefs.h. */
4060 #include <ac_nonexistent.h>
4061 _ACEOF
4062 if ac_fn_c_try_cpp "$LINENO"; then :
4063 # Broken: success on invalid input.
4064 continue
4065 else
4066 # Passes both tests.
4067 ac_preproc_ok=:
4068 break
4069 fi
4070 rm -f conftest.err conftest.i conftest.$ac_ext
4071
4072 done
4073 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4074 rm -f conftest.i conftest.err conftest.$ac_ext
4075 if $ac_preproc_ok; then :
4076
4077 else
4078 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4079 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4080 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4081 See \`config.log' for more details" "$LINENO" 5; }
4082 fi
4083
4084 ac_ext=c
4085 ac_cpp='$CPP $CPPFLAGS'
4086 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4087 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4088 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4089
4090
4091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4092 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4093 if ${ac_cv_path_GREP+:} false; then :
4094 $as_echo_n "(cached) " >&6
4095 else
4096 if test -z "$GREP"; then
4097 ac_path_GREP_found=false
4098 # Loop through the user's path and test for each of PROGNAME-LIST
4099 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4100 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4101 do
4102 IFS=$as_save_IFS
4103 test -z "$as_dir" && as_dir=.
4104 for ac_prog in grep ggrep; do
4105 for ac_exec_ext in '' $ac_executable_extensions; do
4106 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4107 as_fn_executable_p "$ac_path_GREP" || continue
4108 # Check for GNU ac_path_GREP and select it if it is found.
4109 # Check for GNU $ac_path_GREP
4110 case `"$ac_path_GREP" --version 2>&1` in
4111 *GNU*)
4112 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4113 *)
4114 ac_count=0
4115 $as_echo_n 0123456789 >"conftest.in"
4116 while :
4117 do
4118 cat "conftest.in" "conftest.in" >"conftest.tmp"
4119 mv "conftest.tmp" "conftest.in"
4120 cp "conftest.in" "conftest.nl"
4121 $as_echo 'GREP' >> "conftest.nl"
4122 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4123 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4124 as_fn_arith $ac_count + 1 && ac_count=$as_val
4125 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4126 # Best one so far, save it but keep looking for a better one
4127 ac_cv_path_GREP="$ac_path_GREP"
4128 ac_path_GREP_max=$ac_count
4129 fi
4130 # 10*(2^10) chars as input seems more than enough
4131 test $ac_count -gt 10 && break
4132 done
4133 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4134 esac
4135
4136 $ac_path_GREP_found && break 3
4137 done
4138 done
4139 done
4140 IFS=$as_save_IFS
4141 if test -z "$ac_cv_path_GREP"; then
4142 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4143 fi
4144 else
4145 ac_cv_path_GREP=$GREP
4146 fi
4147
4148 fi
4149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4150 $as_echo "$ac_cv_path_GREP" >&6; }
4151 GREP="$ac_cv_path_GREP"
4152
4153
4154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4155 $as_echo_n "checking for egrep... " >&6; }
4156 if ${ac_cv_path_EGREP+:} false; then :
4157 $as_echo_n "(cached) " >&6
4158 else
4159 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4160 then ac_cv_path_EGREP="$GREP -E"
4161 else
4162 if test -z "$EGREP"; then
4163 ac_path_EGREP_found=false
4164 # Loop through the user's path and test for each of PROGNAME-LIST
4165 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4166 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4167 do
4168 IFS=$as_save_IFS
4169 test -z "$as_dir" && as_dir=.
4170 for ac_prog in egrep; do
4171 for ac_exec_ext in '' $ac_executable_extensions; do
4172 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4173 as_fn_executable_p "$ac_path_EGREP" || continue
4174 # Check for GNU ac_path_EGREP and select it if it is found.
4175 # Check for GNU $ac_path_EGREP
4176 case `"$ac_path_EGREP" --version 2>&1` in
4177 *GNU*)
4178 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4179 *)
4180 ac_count=0
4181 $as_echo_n 0123456789 >"conftest.in"
4182 while :
4183 do
4184 cat "conftest.in" "conftest.in" >"conftest.tmp"
4185 mv "conftest.tmp" "conftest.in"
4186 cp "conftest.in" "conftest.nl"
4187 $as_echo 'EGREP' >> "conftest.nl"
4188 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4189 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4190 as_fn_arith $ac_count + 1 && ac_count=$as_val
4191 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4192 # Best one so far, save it but keep looking for a better one
4193 ac_cv_path_EGREP="$ac_path_EGREP"
4194 ac_path_EGREP_max=$ac_count
4195 fi
4196 # 10*(2^10) chars as input seems more than enough
4197 test $ac_count -gt 10 && break
4198 done
4199 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4200 esac
4201
4202 $ac_path_EGREP_found && break 3
4203 done
4204 done
4205 done
4206 IFS=$as_save_IFS
4207 if test -z "$ac_cv_path_EGREP"; then
4208 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4209 fi
4210 else
4211 ac_cv_path_EGREP=$EGREP
4212 fi
4213
4214 fi
4215 fi
4216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4217 $as_echo "$ac_cv_path_EGREP" >&6; }
4218 EGREP="$ac_cv_path_EGREP"
4219
4220
4221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4222 $as_echo_n "checking for ANSI C header files... " >&6; }
4223 if ${ac_cv_header_stdc+:} false; then :
4224 $as_echo_n "(cached) " >&6
4225 else
4226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4227 /* end confdefs.h. */
4228 #include <stdlib.h>
4229 #include <stdarg.h>
4230 #include <string.h>
4231 #include <float.h>
4232
4233 int
4234 main ()
4235 {
4236
4237 ;
4238 return 0;
4239 }
4240 _ACEOF
4241 if ac_fn_c_try_compile "$LINENO"; then :
4242 ac_cv_header_stdc=yes
4243 else
4244 ac_cv_header_stdc=no
4245 fi
4246 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4247
4248 if test $ac_cv_header_stdc = yes; then
4249 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4251 /* end confdefs.h. */
4252 #include <string.h>
4253
4254 _ACEOF
4255 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4256 $EGREP "memchr" >/dev/null 2>&1; then :
4257
4258 else
4259 ac_cv_header_stdc=no
4260 fi
4261 rm -f conftest*
4262
4263 fi
4264
4265 if test $ac_cv_header_stdc = yes; then
4266 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4268 /* end confdefs.h. */
4269 #include <stdlib.h>
4270
4271 _ACEOF
4272 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4273 $EGREP "free" >/dev/null 2>&1; then :
4274
4275 else
4276 ac_cv_header_stdc=no
4277 fi
4278 rm -f conftest*
4279
4280 fi
4281
4282 if test $ac_cv_header_stdc = yes; then
4283 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4284 if test "$cross_compiling" = yes; then :
4285 :
4286 else
4287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4288 /* end confdefs.h. */
4289 #include <ctype.h>
4290 #include <stdlib.h>
4291 #if ((' ' & 0x0FF) == 0x020)
4292 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4293 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4294 #else
4295 # define ISLOWER(c) \
4296 (('a' <= (c) && (c) <= 'i') \
4297 || ('j' <= (c) && (c) <= 'r') \
4298 || ('s' <= (c) && (c) <= 'z'))
4299 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4300 #endif
4301
4302 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4303 int
4304 main ()
4305 {
4306 int i;
4307 for (i = 0; i < 256; i++)
4308 if (XOR (islower (i), ISLOWER (i))
4309 || toupper (i) != TOUPPER (i))
4310 return 2;
4311 return 0;
4312 }
4313 _ACEOF
4314 if ac_fn_c_try_run "$LINENO"; then :
4315
4316 else
4317 ac_cv_header_stdc=no
4318 fi
4319 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4320 conftest.$ac_objext conftest.beam conftest.$ac_ext
4321 fi
4322
4323 fi
4324 fi
4325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4326 $as_echo "$ac_cv_header_stdc" >&6; }
4327 if test $ac_cv_header_stdc = yes; then
4328
4329 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4330
4331 fi
4332
4333 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4334 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4335 inttypes.h stdint.h unistd.h
4336 do :
4337 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4338 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4339 "
4340 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4341 cat >>confdefs.h <<_ACEOF
4342 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4343 _ACEOF
4344
4345 fi
4346
4347 done
4348
4349
4350
4351 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4352 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4353 MINIX=yes
4354 else
4355 MINIX=
4356 fi
4357
4358
4359 if test "$MINIX" = yes; then
4360
4361 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4362
4363
4364 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4365
4366
4367 $as_echo "#define _MINIX 1" >>confdefs.h
4368
4369 fi
4370
4371
4372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4373 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4374 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4375 $as_echo_n "(cached) " >&6
4376 else
4377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4378 /* end confdefs.h. */
4379
4380 # define __EXTENSIONS__ 1
4381 $ac_includes_default
4382 int
4383 main ()
4384 {
4385
4386 ;
4387 return 0;
4388 }
4389 _ACEOF
4390 if ac_fn_c_try_compile "$LINENO"; then :
4391 ac_cv_safe_to_define___extensions__=yes
4392 else
4393 ac_cv_safe_to_define___extensions__=no
4394 fi
4395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4396 fi
4397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4398 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4399 test $ac_cv_safe_to_define___extensions__ = yes &&
4400 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4401
4402 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4403
4404 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4405
4406 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4407
4408 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4409
4410
4411 ac_aux_dir=
4412 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4413 if test -f "$ac_dir/install-sh"; then
4414 ac_aux_dir=$ac_dir
4415 ac_install_sh="$ac_aux_dir/install-sh -c"
4416 break
4417 elif test -f "$ac_dir/install.sh"; then
4418 ac_aux_dir=$ac_dir
4419 ac_install_sh="$ac_aux_dir/install.sh -c"
4420 break
4421 elif test -f "$ac_dir/shtool"; then
4422 ac_aux_dir=$ac_dir
4423 ac_install_sh="$ac_aux_dir/shtool install -c"
4424 break
4425 fi
4426 done
4427 if test -z "$ac_aux_dir"; then
4428 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4429 fi
4430
4431 # These three variables are undocumented and unsupported,
4432 # and are intended to be withdrawn in a future Autoconf release.
4433 # They can cause serious problems if a builder's source tree is in a directory
4434 # whose full name contains unusual characters.
4435 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4436 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4437 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4438
4439
4440 # Make sure we can run config.sub.
4441 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4442 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4443
4444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4445 $as_echo_n "checking build system type... " >&6; }
4446 if ${ac_cv_build+:} false; then :
4447 $as_echo_n "(cached) " >&6
4448 else
4449 ac_build_alias=$build_alias
4450 test "x$ac_build_alias" = x &&
4451 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4452 test "x$ac_build_alias" = x &&
4453 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4454 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4455 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4456
4457 fi
4458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4459 $as_echo "$ac_cv_build" >&6; }
4460 case $ac_cv_build in
4461 *-*-*) ;;
4462 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4463 esac
4464 build=$ac_cv_build
4465 ac_save_IFS=$IFS; IFS='-'
4466 set x $ac_cv_build
4467 shift
4468 build_cpu=$1
4469 build_vendor=$2
4470 shift; shift
4471 # Remember, the first character of IFS is used to create $*,
4472 # except with old shells:
4473 build_os=$*
4474 IFS=$ac_save_IFS
4475 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4476
4477
4478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4479 $as_echo_n "checking host system type... " >&6; }
4480 if ${ac_cv_host+:} false; then :
4481 $as_echo_n "(cached) " >&6
4482 else
4483 if test "x$host_alias" = x; then
4484 ac_cv_host=$ac_cv_build
4485 else
4486 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4487 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4488 fi
4489
4490 fi
4491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4492 $as_echo "$ac_cv_host" >&6; }
4493 case $ac_cv_host in
4494 *-*-*) ;;
4495 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4496 esac
4497 host=$ac_cv_host
4498 ac_save_IFS=$IFS; IFS='-'
4499 set x $ac_cv_host
4500 shift
4501 host_cpu=$1
4502 host_vendor=$2
4503 shift; shift
4504 # Remember, the first character of IFS is used to create $*,
4505 # except with old shells:
4506 host_os=$*
4507 IFS=$ac_save_IFS
4508 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4509
4510
4511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4512 $as_echo_n "checking target system type... " >&6; }
4513 if ${ac_cv_target+:} false; then :
4514 $as_echo_n "(cached) " >&6
4515 else
4516 if test "x$target_alias" = x; then
4517 ac_cv_target=$ac_cv_host
4518 else
4519 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4520 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4521 fi
4522
4523 fi
4524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4525 $as_echo "$ac_cv_target" >&6; }
4526 case $ac_cv_target in
4527 *-*-*) ;;
4528 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4529 esac
4530 target=$ac_cv_target
4531 ac_save_IFS=$IFS; IFS='-'
4532 set x $ac_cv_target
4533 shift
4534 target_cpu=$1
4535 target_vendor=$2
4536 shift; shift
4537 # Remember, the first character of IFS is used to create $*,
4538 # except with old shells:
4539 target_os=$*
4540 IFS=$ac_save_IFS
4541 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4542
4543
4544 # The aliases save the names the user supplied, while $host etc.
4545 # will get canonicalized.
4546 test -n "$target_alias" &&
4547 test "$program_prefix$program_suffix$program_transform_name" = \
4548 NONENONEs,x,x, &&
4549 program_prefix=${target_alias}-
4550
4551 # The tests for host and target for $enable_largefile require
4552 # canonical names.
4553
4554
4555
4556 # As the $enable_largefile decision depends on --enable-plugins we must set it
4557 # even in directories otherwise not depending on the $plugins option.
4558
4559
4560 maybe_plugins=no
4561 for ac_header in dlfcn.h
4562 do :
4563 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
4564 "
4565 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
4566 cat >>confdefs.h <<_ACEOF
4567 #define HAVE_DLFCN_H 1
4568 _ACEOF
4569 maybe_plugins=yes
4570 fi
4571
4572 done
4573
4574 for ac_header in windows.h
4575 do :
4576 ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
4577 "
4578 if test "x$ac_cv_header_windows_h" = xyes; then :
4579 cat >>confdefs.h <<_ACEOF
4580 #define HAVE_WINDOWS_H 1
4581 _ACEOF
4582 maybe_plugins=yes
4583 fi
4584
4585 done
4586
4587
4588 # Check whether --enable-plugins was given.
4589 if test "${enable_plugins+set}" = set; then :
4590 enableval=$enable_plugins; case "${enableval}" in
4591 no) plugins=no ;;
4592 *) plugins=yes
4593 if test "$maybe_plugins" != "yes" ; then
4594 as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
4595 fi ;;
4596 esac
4597 else
4598 plugins=$maybe_plugins
4599
4600 fi
4601
4602 if test "$plugins" = "yes"; then
4603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
4604 $as_echo_n "checking for library containing dlsym... " >&6; }
4605 if ${ac_cv_search_dlsym+:} false; then :
4606 $as_echo_n "(cached) " >&6
4607 else
4608 ac_func_search_save_LIBS=$LIBS
4609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4610 /* end confdefs.h. */
4611
4612 /* Override any GCC internal prototype to avoid an error.
4613 Use char because int might match the return type of a GCC
4614 builtin and then its argument prototype would still apply. */
4615 #ifdef __cplusplus
4616 extern "C"
4617 #endif
4618 char dlsym ();
4619 int
4620 main ()
4621 {
4622 return dlsym ();
4623 ;
4624 return 0;
4625 }
4626 _ACEOF
4627 for ac_lib in '' dl; do
4628 if test -z "$ac_lib"; then
4629 ac_res="none required"
4630 else
4631 ac_res=-l$ac_lib
4632 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4633 fi
4634 if ac_fn_c_try_link "$LINENO"; then :
4635 ac_cv_search_dlsym=$ac_res
4636 fi
4637 rm -f core conftest.err conftest.$ac_objext \
4638 conftest$ac_exeext
4639 if ${ac_cv_search_dlsym+:} false; then :
4640 break
4641 fi
4642 done
4643 if ${ac_cv_search_dlsym+:} false; then :
4644
4645 else
4646 ac_cv_search_dlsym=no
4647 fi
4648 rm conftest.$ac_ext
4649 LIBS=$ac_func_search_save_LIBS
4650 fi
4651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
4652 $as_echo "$ac_cv_search_dlsym" >&6; }
4653 ac_res=$ac_cv_search_dlsym
4654 if test "$ac_res" != no; then :
4655 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4656
4657 fi
4658
4659 fi
4660
4661
4662 case "${host}" in
4663 sparc-*-solaris*|i[3-7]86-*-solaris*)
4664 # On native 32bit sparc and ia32 solaris, large-file and procfs support
4665 # are mutually exclusive; and without procfs support, the bfd/ elf module
4666 # cannot provide certain routines such as elfcore_write_prpsinfo
4667 # or elfcore_write_prstatus. So unless the user explicitly requested
4668 # large-file support through the --enable-largefile switch, disable
4669 # large-file support in favor of procfs support.
4670 test "${target}" = "${host}" -a "x$plugins" = xno \
4671 && : ${enable_largefile="no"}
4672 ;;
4673 esac
4674
4675 # Check whether --enable-largefile was given.
4676 if test "${enable_largefile+set}" = set; then :
4677 enableval=$enable_largefile;
4678 fi
4679
4680 if test "$enable_largefile" != no; then
4681
4682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4683 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4684 if ${ac_cv_sys_largefile_CC+:} false; then :
4685 $as_echo_n "(cached) " >&6
4686 else
4687 ac_cv_sys_largefile_CC=no
4688 if test "$GCC" != yes; then
4689 ac_save_CC=$CC
4690 while :; do
4691 # IRIX 6.2 and later do not support large files by default,
4692 # so use the C compiler's -n32 option if that helps.
4693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4694 /* end confdefs.h. */
4695 #include <sys/types.h>
4696 /* Check that off_t can represent 2**63 - 1 correctly.
4697 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4698 since some C++ compilers masquerading as C compilers
4699 incorrectly reject 9223372036854775807. */
4700 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4701 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4702 && LARGE_OFF_T % 2147483647 == 1)
4703 ? 1 : -1];
4704 int
4705 main ()
4706 {
4707
4708 ;
4709 return 0;
4710 }
4711 _ACEOF
4712 if ac_fn_c_try_compile "$LINENO"; then :
4713 break
4714 fi
4715 rm -f core conftest.err conftest.$ac_objext
4716 CC="$CC -n32"
4717 if ac_fn_c_try_compile "$LINENO"; then :
4718 ac_cv_sys_largefile_CC=' -n32'; break
4719 fi
4720 rm -f core conftest.err conftest.$ac_objext
4721 break
4722 done
4723 CC=$ac_save_CC
4724 rm -f conftest.$ac_ext
4725 fi
4726 fi
4727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4728 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4729 if test "$ac_cv_sys_largefile_CC" != no; then
4730 CC=$CC$ac_cv_sys_largefile_CC
4731 fi
4732
4733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4734 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4735 if ${ac_cv_sys_file_offset_bits+:} false; then :
4736 $as_echo_n "(cached) " >&6
4737 else
4738 while :; do
4739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4740 /* end confdefs.h. */
4741 #include <sys/types.h>
4742 /* Check that off_t can represent 2**63 - 1 correctly.
4743 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4744 since some C++ compilers masquerading as C compilers
4745 incorrectly reject 9223372036854775807. */
4746 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4747 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4748 && LARGE_OFF_T % 2147483647 == 1)
4749 ? 1 : -1];
4750 int
4751 main ()
4752 {
4753
4754 ;
4755 return 0;
4756 }
4757 _ACEOF
4758 if ac_fn_c_try_compile "$LINENO"; then :
4759 ac_cv_sys_file_offset_bits=no; break
4760 fi
4761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4763 /* end confdefs.h. */
4764 #define _FILE_OFFSET_BITS 64
4765 #include <sys/types.h>
4766 /* Check that off_t can represent 2**63 - 1 correctly.
4767 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4768 since some C++ compilers masquerading as C compilers
4769 incorrectly reject 9223372036854775807. */
4770 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4771 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4772 && LARGE_OFF_T % 2147483647 == 1)
4773 ? 1 : -1];
4774 int
4775 main ()
4776 {
4777
4778 ;
4779 return 0;
4780 }
4781 _ACEOF
4782 if ac_fn_c_try_compile "$LINENO"; then :
4783 ac_cv_sys_file_offset_bits=64; break
4784 fi
4785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4786 ac_cv_sys_file_offset_bits=unknown
4787 break
4788 done
4789 fi
4790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4791 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4792 case $ac_cv_sys_file_offset_bits in #(
4793 no | unknown) ;;
4794 *)
4795 cat >>confdefs.h <<_ACEOF
4796 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4797 _ACEOF
4798 ;;
4799 esac
4800 rm -rf conftest*
4801 if test $ac_cv_sys_file_offset_bits = unknown; then
4802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4803 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4804 if ${ac_cv_sys_large_files+:} false; then :
4805 $as_echo_n "(cached) " >&6
4806 else
4807 while :; do
4808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4809 /* end confdefs.h. */
4810 #include <sys/types.h>
4811 /* Check that off_t can represent 2**63 - 1 correctly.
4812 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4813 since some C++ compilers masquerading as C compilers
4814 incorrectly reject 9223372036854775807. */
4815 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4816 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4817 && LARGE_OFF_T % 2147483647 == 1)
4818 ? 1 : -1];
4819 int
4820 main ()
4821 {
4822
4823 ;
4824 return 0;
4825 }
4826 _ACEOF
4827 if ac_fn_c_try_compile "$LINENO"; then :
4828 ac_cv_sys_large_files=no; break
4829 fi
4830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4832 /* end confdefs.h. */
4833 #define _LARGE_FILES 1
4834 #include <sys/types.h>
4835 /* Check that off_t can represent 2**63 - 1 correctly.
4836 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4837 since some C++ compilers masquerading as C compilers
4838 incorrectly reject 9223372036854775807. */
4839 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4840 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4841 && LARGE_OFF_T % 2147483647 == 1)
4842 ? 1 : -1];
4843 int
4844 main ()
4845 {
4846
4847 ;
4848 return 0;
4849 }
4850 _ACEOF
4851 if ac_fn_c_try_compile "$LINENO"; then :
4852 ac_cv_sys_large_files=1; break
4853 fi
4854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4855 ac_cv_sys_large_files=unknown
4856 break
4857 done
4858 fi
4859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4860 $as_echo "$ac_cv_sys_large_files" >&6; }
4861 case $ac_cv_sys_large_files in #(
4862 no | unknown) ;;
4863 *)
4864 cat >>confdefs.h <<_ACEOF
4865 #define _LARGE_FILES $ac_cv_sys_large_files
4866 _ACEOF
4867 ;;
4868 esac
4869 rm -rf conftest*
4870 fi
4871
4872
4873 fi
4874
4875
4876
4877
4878
4879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${CC-cc} option to accept ANSI C" >&5
4880 $as_echo_n "checking for ${CC-cc} option to accept ANSI C... " >&6; }
4881 if ${am_cv_prog_cc_stdc+:} false; then :
4882 $as_echo_n "(cached) " >&6
4883 else
4884 am_cv_prog_cc_stdc=no
4885 ac_save_CC="$CC"
4886 # Don't try gcc -ansi; that turns off useful extensions and
4887 # breaks some systems' header files.
4888 # AIX -qlanglvl=ansi
4889 # Ultrix and OSF/1 -std1
4890 # HP-UX 10.20 and later -Ae
4891 # HP-UX older versions -Aa -D_HPUX_SOURCE
4892 # SVR4 -Xc -D__EXTENSIONS__
4893 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4894 do
4895 CC="$ac_save_CC $ac_arg"
4896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4897 /* end confdefs.h. */
4898 #include <stdarg.h>
4899 #include <stdio.h>
4900 #include <sys/types.h>
4901 #include <sys/stat.h>
4902 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4903 struct buf { int x; };
4904 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4905 static char *e (p, i)
4906 char **p;
4907 int i;
4908 {
4909 return p[i];
4910 }
4911 static char *f (char * (*g) (char **, int), char **p, ...)
4912 {
4913 char *s;
4914 va_list v;
4915 va_start (v,p);
4916 s = g (p, va_arg (v,int));
4917 va_end (v);
4918 return s;
4919 }
4920 int test (int i, double x);
4921 struct s1 {int (*f) (int a);};
4922 struct s2 {int (*f) (double a);};
4923 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4924 int argc;
4925 char **argv;
4926
4927 int
4928 main ()
4929 {
4930
4931 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4932
4933 ;
4934 return 0;
4935 }
4936 _ACEOF
4937 if ac_fn_c_try_compile "$LINENO"; then :
4938 am_cv_prog_cc_stdc="$ac_arg"; break
4939 fi
4940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4941 done
4942 CC="$ac_save_CC"
4943
4944 fi
4945
4946 if test -z "$am_cv_prog_cc_stdc"; then
4947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4948 $as_echo "none needed" >&6; }
4949 else
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_stdc" >&5
4951 $as_echo "$am_cv_prog_cc_stdc" >&6; }
4952 fi
4953 case "x$am_cv_prog_cc_stdc" in
4954 x|xno) ;;
4955 *) CC="$CC $am_cv_prog_cc_stdc" ;;
4956 esac
4957
4958 # Expand $ac_aux_dir to an absolute path.
4959 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4960
4961 if test x"${install_sh+set}" != xset; then
4962 case $am_aux_dir in
4963 *\ * | *\ *)
4964 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4965 *)
4966 install_sh="\${SHELL} $am_aux_dir/install-sh"
4967 esac
4968 fi
4969
4970 # Installed binaries are usually stripped using 'strip' when the user
4971 # run "make install-strip". However 'strip' might not be the right
4972 # tool to use in cross-compilation environments, therefore Automake
4973 # will honor the 'STRIP' environment variable to overrule this program.
4974 if test "$cross_compiling" != no; then
4975 if test -n "$ac_tool_prefix"; then
4976 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4977 set dummy ${ac_tool_prefix}strip; ac_word=$2
4978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4979 $as_echo_n "checking for $ac_word... " >&6; }
4980 if ${ac_cv_prog_STRIP+:} false; then :
4981 $as_echo_n "(cached) " >&6
4982 else
4983 if test -n "$STRIP"; then
4984 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4985 else
4986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4987 for as_dir in $PATH
4988 do
4989 IFS=$as_save_IFS
4990 test -z "$as_dir" && as_dir=.
4991 for ac_exec_ext in '' $ac_executable_extensions; do
4992 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4993 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4994 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4995 break 2
4996 fi
4997 done
4998 done
4999 IFS=$as_save_IFS
5000
5001 fi
5002 fi
5003 STRIP=$ac_cv_prog_STRIP
5004 if test -n "$STRIP"; then
5005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
5006 $as_echo "$STRIP" >&6; }
5007 else
5008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5009 $as_echo "no" >&6; }
5010 fi
5011
5012
5013 fi
5014 if test -z "$ac_cv_prog_STRIP"; then
5015 ac_ct_STRIP=$STRIP
5016 # Extract the first word of "strip", so it can be a program name with args.
5017 set dummy strip; ac_word=$2
5018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5019 $as_echo_n "checking for $ac_word... " >&6; }
5020 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
5021 $as_echo_n "(cached) " >&6
5022 else
5023 if test -n "$ac_ct_STRIP"; then
5024 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5025 else
5026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5027 for as_dir in $PATH
5028 do
5029 IFS=$as_save_IFS
5030 test -z "$as_dir" && as_dir=.
5031 for ac_exec_ext in '' $ac_executable_extensions; do
5032 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5033 ac_cv_prog_ac_ct_STRIP="strip"
5034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5035 break 2
5036 fi
5037 done
5038 done
5039 IFS=$as_save_IFS
5040
5041 fi
5042 fi
5043 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5044 if test -n "$ac_ct_STRIP"; then
5045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5046 $as_echo "$ac_ct_STRIP" >&6; }
5047 else
5048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5049 $as_echo "no" >&6; }
5050 fi
5051
5052 if test "x$ac_ct_STRIP" = x; then
5053 STRIP=":"
5054 else
5055 case $cross_compiling:$ac_tool_warned in
5056 yes:)
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5058 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5059 ac_tool_warned=yes ;;
5060 esac
5061 STRIP=$ac_ct_STRIP
5062 fi
5063 else
5064 STRIP="$ac_cv_prog_STRIP"
5065 fi
5066
5067 fi
5068 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5069
5070
5071 ac_aux_dir=
5072 for ac_dir in .. "$srcdir"/..; do
5073 if test -f "$ac_dir/install-sh"; then
5074 ac_aux_dir=$ac_dir
5075 ac_install_sh="$ac_aux_dir/install-sh -c"
5076 break
5077 elif test -f "$ac_dir/install.sh"; then
5078 ac_aux_dir=$ac_dir
5079 ac_install_sh="$ac_aux_dir/install.sh -c"
5080 break
5081 elif test -f "$ac_dir/shtool"; then
5082 ac_aux_dir=$ac_dir
5083 ac_install_sh="$ac_aux_dir/shtool install -c"
5084 break
5085 fi
5086 done
5087 if test -z "$ac_aux_dir"; then
5088 as_fn_error $? "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
5089 fi
5090
5091 # These three variables are undocumented and unsupported,
5092 # and are intended to be withdrawn in a future Autoconf release.
5093 # They can cause serious problems if a builder's source tree is in a directory
5094 # whose full name contains unusual characters.
5095 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
5096 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
5097 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
5098
5099
5100
5101 test "$program_prefix" != NONE &&
5102 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5103 # Use a double $ so make ignores it.
5104 test "$program_suffix" != NONE &&
5105 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5106 # Double any \ or $.
5107 # By default was `s,x,x', remove it if useless.
5108 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5109 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5110
5111
5112 # We require a C++11 compiler. Check if one is available, and if
5113 # necessary, set CXX_DIALECT to some -std=xxx switch.
5114
5115 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
5116 ac_ext=cpp
5117 ac_cpp='$CXXCPP $CPPFLAGS'
5118 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5119 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5120 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5121 CXX_DIALECT=""
5122 ac_success=no
5123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5124 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5125 if ${ax_cv_cxx_compile_cxx11+:} false; then :
5126 $as_echo_n "(cached) " >&6
5127 else
5128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5129 /* end confdefs.h. */
5130
5131
5132 // If the compiler admits that it is not ready for C++11, why torture it?
5133 // Hopefully, this will speed up the test.
5134
5135 #ifndef __cplusplus
5136
5137 #error "This is not a C++ compiler"
5138
5139 #elif __cplusplus < 201103L
5140
5141 #error "This is not a C++11 compiler"
5142
5143 #else
5144
5145 namespace cxx11
5146 {
5147
5148 namespace test_static_assert
5149 {
5150
5151 template <typename T>
5152 struct check
5153 {
5154 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5155 };
5156
5157 }
5158
5159 namespace test_final_override
5160 {
5161
5162 struct Base
5163 {
5164 virtual void f() {}
5165 };
5166
5167 struct Derived : public Base
5168 {
5169 virtual void f() override {}
5170 };
5171
5172 }
5173
5174 namespace test_double_right_angle_brackets
5175 {
5176
5177 template < typename T >
5178 struct check {};
5179
5180 typedef check<void> single_type;
5181 typedef check<check<void>> double_type;
5182 typedef check<check<check<void>>> triple_type;
5183 typedef check<check<check<check<void>>>> quadruple_type;
5184
5185 }
5186
5187 namespace test_decltype
5188 {
5189
5190 int
5191 f()
5192 {
5193 int a = 1;
5194 decltype(a) b = 2;
5195 return a + b;
5196 }
5197
5198 }
5199
5200 namespace test_type_deduction
5201 {
5202
5203 template < typename T1, typename T2 >
5204 struct is_same
5205 {
5206 static const bool value = false;
5207 };
5208
5209 template < typename T >
5210 struct is_same<T, T>
5211 {
5212 static const bool value = true;
5213 };
5214
5215 template < typename T1, typename T2 >
5216 auto
5217 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5218 {
5219 return a1 + a2;
5220 }
5221
5222 int
5223 test(const int c, volatile int v)
5224 {
5225 static_assert(is_same<int, decltype(0)>::value == true, "");
5226 static_assert(is_same<int, decltype(c)>::value == false, "");
5227 static_assert(is_same<int, decltype(v)>::value == false, "");
5228 auto ac = c;
5229 auto av = v;
5230 auto sumi = ac + av + 'x';
5231 auto sumf = ac + av + 1.0;
5232 static_assert(is_same<int, decltype(ac)>::value == true, "");
5233 static_assert(is_same<int, decltype(av)>::value == true, "");
5234 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5235 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5236 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5237 return (sumf > 0.0) ? sumi : add(c, v);
5238 }
5239
5240 }
5241
5242 namespace test_noexcept
5243 {
5244
5245 int f() { return 0; }
5246 int g() noexcept { return 0; }
5247
5248 static_assert(noexcept(f()) == false, "");
5249 static_assert(noexcept(g()) == true, "");
5250
5251 }
5252
5253 namespace test_constexpr
5254 {
5255
5256 template < typename CharT >
5257 unsigned long constexpr
5258 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5259 {
5260 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5261 }
5262
5263 template < typename CharT >
5264 unsigned long constexpr
5265 strlen_c(const CharT *const s) noexcept
5266 {
5267 return strlen_c_r(s, 0UL);
5268 }
5269
5270 static_assert(strlen_c("") == 0UL, "");
5271 static_assert(strlen_c("1") == 1UL, "");
5272 static_assert(strlen_c("example") == 7UL, "");
5273 static_assert(strlen_c("another\0example") == 7UL, "");
5274
5275 }
5276
5277 namespace test_rvalue_references
5278 {
5279
5280 template < int N >
5281 struct answer
5282 {
5283 static constexpr int value = N;
5284 };
5285
5286 answer<1> f(int&) { return answer<1>(); }
5287 answer<2> f(const int&) { return answer<2>(); }
5288 answer<3> f(int&&) { return answer<3>(); }
5289
5290 void
5291 test()
5292 {
5293 int i = 0;
5294 const int c = 0;
5295 static_assert(decltype(f(i))::value == 1, "");
5296 static_assert(decltype(f(c))::value == 2, "");
5297 static_assert(decltype(f(0))::value == 3, "");
5298 }
5299
5300 }
5301
5302 namespace test_uniform_initialization
5303 {
5304
5305 struct test
5306 {
5307 static const int zero {};
5308 static const int one {1};
5309 };
5310
5311 static_assert(test::zero == 0, "");
5312 static_assert(test::one == 1, "");
5313
5314 }
5315
5316 namespace test_lambdas
5317 {
5318
5319 void
5320 test1()
5321 {
5322 auto lambda1 = [](){};
5323 auto lambda2 = lambda1;
5324 lambda1();
5325 lambda2();
5326 }
5327
5328 int
5329 test2()
5330 {
5331 auto a = [](int i, int j){ return i + j; }(1, 2);
5332 auto b = []() -> int { return '0'; }();
5333 auto c = [=](){ return a + b; }();
5334 auto d = [&](){ return c; }();
5335 auto e = [a, &b](int x) mutable {
5336 const auto identity = [](int y){ return y; };
5337 for (auto i = 0; i < a; ++i)
5338 a += b--;
5339 return x + identity(a + b);
5340 }(0);
5341 return a + b + c + d + e;
5342 }
5343
5344 int
5345 test3()
5346 {
5347 const auto nullary = [](){ return 0; };
5348 const auto unary = [](int x){ return x; };
5349 using nullary_t = decltype(nullary);
5350 using unary_t = decltype(unary);
5351 const auto higher1st = [](nullary_t f){ return f(); };
5352 const auto higher2nd = [unary](nullary_t f1){
5353 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5354 };
5355 return higher1st(nullary) + higher2nd(nullary)(unary);
5356 }
5357
5358 }
5359
5360 namespace test_variadic_templates
5361 {
5362
5363 template <int...>
5364 struct sum;
5365
5366 template <int N0, int... N1toN>
5367 struct sum<N0, N1toN...>
5368 {
5369 static constexpr auto value = N0 + sum<N1toN...>::value;
5370 };
5371
5372 template <>
5373 struct sum<>
5374 {
5375 static constexpr auto value = 0;
5376 };
5377
5378 static_assert(sum<>::value == 0, "");
5379 static_assert(sum<1>::value == 1, "");
5380 static_assert(sum<23>::value == 23, "");
5381 static_assert(sum<1, 2>::value == 3, "");
5382 static_assert(sum<5, 5, 11>::value == 21, "");
5383 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5384
5385 }
5386
5387 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5388 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5389 // because of this.
5390 namespace test_template_alias_sfinae
5391 {
5392
5393 struct foo {};
5394
5395 template<typename T>
5396 using member = typename T::member_type;
5397
5398 template<typename T>
5399 void func(...) {}
5400
5401 template<typename T>
5402 void func(member<T>*) {}
5403
5404 void test();
5405
5406 void test() { func<foo>(0); }
5407
5408 }
5409
5410 } // namespace cxx11
5411
5412 #endif // __cplusplus >= 201103L
5413
5414
5415
5416 _ACEOF
5417 if ac_fn_cxx_try_compile "$LINENO"; then :
5418 ax_cv_cxx_compile_cxx11=yes
5419 else
5420 ax_cv_cxx_compile_cxx11=no
5421 fi
5422 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5423 fi
5424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
5425 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
5426 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
5427 ac_success=yes
5428 fi
5429
5430 if test x$ac_success = xno; then
5431 for alternative in ${ax_cxx_compile_alternatives}; do
5432 switch="-std=gnu++${alternative}"
5433 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5435 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5436 if eval \${$cachevar+:} false; then :
5437 $as_echo_n "(cached) " >&6
5438 else
5439 ac_save_CXX="$CXX"
5440 CXX="$CXX $switch"
5441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5442 /* end confdefs.h. */
5443
5444
5445 // If the compiler admits that it is not ready for C++11, why torture it?
5446 // Hopefully, this will speed up the test.
5447
5448 #ifndef __cplusplus
5449
5450 #error "This is not a C++ compiler"
5451
5452 #elif __cplusplus < 201103L
5453
5454 #error "This is not a C++11 compiler"
5455
5456 #else
5457
5458 namespace cxx11
5459 {
5460
5461 namespace test_static_assert
5462 {
5463
5464 template <typename T>
5465 struct check
5466 {
5467 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5468 };
5469
5470 }
5471
5472 namespace test_final_override
5473 {
5474
5475 struct Base
5476 {
5477 virtual void f() {}
5478 };
5479
5480 struct Derived : public Base
5481 {
5482 virtual void f() override {}
5483 };
5484
5485 }
5486
5487 namespace test_double_right_angle_brackets
5488 {
5489
5490 template < typename T >
5491 struct check {};
5492
5493 typedef check<void> single_type;
5494 typedef check<check<void>> double_type;
5495 typedef check<check<check<void>>> triple_type;
5496 typedef check<check<check<check<void>>>> quadruple_type;
5497
5498 }
5499
5500 namespace test_decltype
5501 {
5502
5503 int
5504 f()
5505 {
5506 int a = 1;
5507 decltype(a) b = 2;
5508 return a + b;
5509 }
5510
5511 }
5512
5513 namespace test_type_deduction
5514 {
5515
5516 template < typename T1, typename T2 >
5517 struct is_same
5518 {
5519 static const bool value = false;
5520 };
5521
5522 template < typename T >
5523 struct is_same<T, T>
5524 {
5525 static const bool value = true;
5526 };
5527
5528 template < typename T1, typename T2 >
5529 auto
5530 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5531 {
5532 return a1 + a2;
5533 }
5534
5535 int
5536 test(const int c, volatile int v)
5537 {
5538 static_assert(is_same<int, decltype(0)>::value == true, "");
5539 static_assert(is_same<int, decltype(c)>::value == false, "");
5540 static_assert(is_same<int, decltype(v)>::value == false, "");
5541 auto ac = c;
5542 auto av = v;
5543 auto sumi = ac + av + 'x';
5544 auto sumf = ac + av + 1.0;
5545 static_assert(is_same<int, decltype(ac)>::value == true, "");
5546 static_assert(is_same<int, decltype(av)>::value == true, "");
5547 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5548 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5549 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5550 return (sumf > 0.0) ? sumi : add(c, v);
5551 }
5552
5553 }
5554
5555 namespace test_noexcept
5556 {
5557
5558 int f() { return 0; }
5559 int g() noexcept { return 0; }
5560
5561 static_assert(noexcept(f()) == false, "");
5562 static_assert(noexcept(g()) == true, "");
5563
5564 }
5565
5566 namespace test_constexpr
5567 {
5568
5569 template < typename CharT >
5570 unsigned long constexpr
5571 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5572 {
5573 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5574 }
5575
5576 template < typename CharT >
5577 unsigned long constexpr
5578 strlen_c(const CharT *const s) noexcept
5579 {
5580 return strlen_c_r(s, 0UL);
5581 }
5582
5583 static_assert(strlen_c("") == 0UL, "");
5584 static_assert(strlen_c("1") == 1UL, "");
5585 static_assert(strlen_c("example") == 7UL, "");
5586 static_assert(strlen_c("another\0example") == 7UL, "");
5587
5588 }
5589
5590 namespace test_rvalue_references
5591 {
5592
5593 template < int N >
5594 struct answer
5595 {
5596 static constexpr int value = N;
5597 };
5598
5599 answer<1> f(int&) { return answer<1>(); }
5600 answer<2> f(const int&) { return answer<2>(); }
5601 answer<3> f(int&&) { return answer<3>(); }
5602
5603 void
5604 test()
5605 {
5606 int i = 0;
5607 const int c = 0;
5608 static_assert(decltype(f(i))::value == 1, "");
5609 static_assert(decltype(f(c))::value == 2, "");
5610 static_assert(decltype(f(0))::value == 3, "");
5611 }
5612
5613 }
5614
5615 namespace test_uniform_initialization
5616 {
5617
5618 struct test
5619 {
5620 static const int zero {};
5621 static const int one {1};
5622 };
5623
5624 static_assert(test::zero == 0, "");
5625 static_assert(test::one == 1, "");
5626
5627 }
5628
5629 namespace test_lambdas
5630 {
5631
5632 void
5633 test1()
5634 {
5635 auto lambda1 = [](){};
5636 auto lambda2 = lambda1;
5637 lambda1();
5638 lambda2();
5639 }
5640
5641 int
5642 test2()
5643 {
5644 auto a = [](int i, int j){ return i + j; }(1, 2);
5645 auto b = []() -> int { return '0'; }();
5646 auto c = [=](){ return a + b; }();
5647 auto d = [&](){ return c; }();
5648 auto e = [a, &b](int x) mutable {
5649 const auto identity = [](int y){ return y; };
5650 for (auto i = 0; i < a; ++i)
5651 a += b--;
5652 return x + identity(a + b);
5653 }(0);
5654 return a + b + c + d + e;
5655 }
5656
5657 int
5658 test3()
5659 {
5660 const auto nullary = [](){ return 0; };
5661 const auto unary = [](int x){ return x; };
5662 using nullary_t = decltype(nullary);
5663 using unary_t = decltype(unary);
5664 const auto higher1st = [](nullary_t f){ return f(); };
5665 const auto higher2nd = [unary](nullary_t f1){
5666 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5667 };
5668 return higher1st(nullary) + higher2nd(nullary)(unary);
5669 }
5670
5671 }
5672
5673 namespace test_variadic_templates
5674 {
5675
5676 template <int...>
5677 struct sum;
5678
5679 template <int N0, int... N1toN>
5680 struct sum<N0, N1toN...>
5681 {
5682 static constexpr auto value = N0 + sum<N1toN...>::value;
5683 };
5684
5685 template <>
5686 struct sum<>
5687 {
5688 static constexpr auto value = 0;
5689 };
5690
5691 static_assert(sum<>::value == 0, "");
5692 static_assert(sum<1>::value == 1, "");
5693 static_assert(sum<23>::value == 23, "");
5694 static_assert(sum<1, 2>::value == 3, "");
5695 static_assert(sum<5, 5, 11>::value == 21, "");
5696 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5697
5698 }
5699
5700 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5701 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5702 // because of this.
5703 namespace test_template_alias_sfinae
5704 {
5705
5706 struct foo {};
5707
5708 template<typename T>
5709 using member = typename T::member_type;
5710
5711 template<typename T>
5712 void func(...) {}
5713
5714 template<typename T>
5715 void func(member<T>*) {}
5716
5717 void test();
5718
5719 void test() { func<foo>(0); }
5720
5721 }
5722
5723 } // namespace cxx11
5724
5725 #endif // __cplusplus >= 201103L
5726
5727
5728
5729 _ACEOF
5730 if ac_fn_cxx_try_compile "$LINENO"; then :
5731 eval $cachevar=yes
5732 else
5733 eval $cachevar=no
5734 fi
5735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5736 CXX="$ac_save_CXX"
5737 fi
5738 eval ac_res=\$$cachevar
5739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5740 $as_echo "$ac_res" >&6; }
5741 if eval test x\$$cachevar = xyes; then
5742 CXX_DIALECT="$switch"
5743 ac_success=yes
5744 break
5745 fi
5746 done
5747 fi
5748
5749 if test x$ac_success = xno; then
5750 for alternative in ${ax_cxx_compile_alternatives}; do
5751 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
5752 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5754 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5755 if eval \${$cachevar+:} false; then :
5756 $as_echo_n "(cached) " >&6
5757 else
5758 ac_save_CXX="$CXX"
5759 CXX="$CXX $switch"
5760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5761 /* end confdefs.h. */
5762
5763
5764 // If the compiler admits that it is not ready for C++11, why torture it?
5765 // Hopefully, this will speed up the test.
5766
5767 #ifndef __cplusplus
5768
5769 #error "This is not a C++ compiler"
5770
5771 #elif __cplusplus < 201103L
5772
5773 #error "This is not a C++11 compiler"
5774
5775 #else
5776
5777 namespace cxx11
5778 {
5779
5780 namespace test_static_assert
5781 {
5782
5783 template <typename T>
5784 struct check
5785 {
5786 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5787 };
5788
5789 }
5790
5791 namespace test_final_override
5792 {
5793
5794 struct Base
5795 {
5796 virtual void f() {}
5797 };
5798
5799 struct Derived : public Base
5800 {
5801 virtual void f() override {}
5802 };
5803
5804 }
5805
5806 namespace test_double_right_angle_brackets
5807 {
5808
5809 template < typename T >
5810 struct check {};
5811
5812 typedef check<void> single_type;
5813 typedef check<check<void>> double_type;
5814 typedef check<check<check<void>>> triple_type;
5815 typedef check<check<check<check<void>>>> quadruple_type;
5816
5817 }
5818
5819 namespace test_decltype
5820 {
5821
5822 int
5823 f()
5824 {
5825 int a = 1;
5826 decltype(a) b = 2;
5827 return a + b;
5828 }
5829
5830 }
5831
5832 namespace test_type_deduction
5833 {
5834
5835 template < typename T1, typename T2 >
5836 struct is_same
5837 {
5838 static const bool value = false;
5839 };
5840
5841 template < typename T >
5842 struct is_same<T, T>
5843 {
5844 static const bool value = true;
5845 };
5846
5847 template < typename T1, typename T2 >
5848 auto
5849 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5850 {
5851 return a1 + a2;
5852 }
5853
5854 int
5855 test(const int c, volatile int v)
5856 {
5857 static_assert(is_same<int, decltype(0)>::value == true, "");
5858 static_assert(is_same<int, decltype(c)>::value == false, "");
5859 static_assert(is_same<int, decltype(v)>::value == false, "");
5860 auto ac = c;
5861 auto av = v;
5862 auto sumi = ac + av + 'x';
5863 auto sumf = ac + av + 1.0;
5864 static_assert(is_same<int, decltype(ac)>::value == true, "");
5865 static_assert(is_same<int, decltype(av)>::value == true, "");
5866 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5867 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5868 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5869 return (sumf > 0.0) ? sumi : add(c, v);
5870 }
5871
5872 }
5873
5874 namespace test_noexcept
5875 {
5876
5877 int f() { return 0; }
5878 int g() noexcept { return 0; }
5879
5880 static_assert(noexcept(f()) == false, "");
5881 static_assert(noexcept(g()) == true, "");
5882
5883 }
5884
5885 namespace test_constexpr
5886 {
5887
5888 template < typename CharT >
5889 unsigned long constexpr
5890 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5891 {
5892 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5893 }
5894
5895 template < typename CharT >
5896 unsigned long constexpr
5897 strlen_c(const CharT *const s) noexcept
5898 {
5899 return strlen_c_r(s, 0UL);
5900 }
5901
5902 static_assert(strlen_c("") == 0UL, "");
5903 static_assert(strlen_c("1") == 1UL, "");
5904 static_assert(strlen_c("example") == 7UL, "");
5905 static_assert(strlen_c("another\0example") == 7UL, "");
5906
5907 }
5908
5909 namespace test_rvalue_references
5910 {
5911
5912 template < int N >
5913 struct answer
5914 {
5915 static constexpr int value = N;
5916 };
5917
5918 answer<1> f(int&) { return answer<1>(); }
5919 answer<2> f(const int&) { return answer<2>(); }
5920 answer<3> f(int&&) { return answer<3>(); }
5921
5922 void
5923 test()
5924 {
5925 int i = 0;
5926 const int c = 0;
5927 static_assert(decltype(f(i))::value == 1, "");
5928 static_assert(decltype(f(c))::value == 2, "");
5929 static_assert(decltype(f(0))::value == 3, "");
5930 }
5931
5932 }
5933
5934 namespace test_uniform_initialization
5935 {
5936
5937 struct test
5938 {
5939 static const int zero {};
5940 static const int one {1};
5941 };
5942
5943 static_assert(test::zero == 0, "");
5944 static_assert(test::one == 1, "");
5945
5946 }
5947
5948 namespace test_lambdas
5949 {
5950
5951 void
5952 test1()
5953 {
5954 auto lambda1 = [](){};
5955 auto lambda2 = lambda1;
5956 lambda1();
5957 lambda2();
5958 }
5959
5960 int
5961 test2()
5962 {
5963 auto a = [](int i, int j){ return i + j; }(1, 2);
5964 auto b = []() -> int { return '0'; }();
5965 auto c = [=](){ return a + b; }();
5966 auto d = [&](){ return c; }();
5967 auto e = [a, &b](int x) mutable {
5968 const auto identity = [](int y){ return y; };
5969 for (auto i = 0; i < a; ++i)
5970 a += b--;
5971 return x + identity(a + b);
5972 }(0);
5973 return a + b + c + d + e;
5974 }
5975
5976 int
5977 test3()
5978 {
5979 const auto nullary = [](){ return 0; };
5980 const auto unary = [](int x){ return x; };
5981 using nullary_t = decltype(nullary);
5982 using unary_t = decltype(unary);
5983 const auto higher1st = [](nullary_t f){ return f(); };
5984 const auto higher2nd = [unary](nullary_t f1){
5985 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5986 };
5987 return higher1st(nullary) + higher2nd(nullary)(unary);
5988 }
5989
5990 }
5991
5992 namespace test_variadic_templates
5993 {
5994
5995 template <int...>
5996 struct sum;
5997
5998 template <int N0, int... N1toN>
5999 struct sum<N0, N1toN...>
6000 {
6001 static constexpr auto value = N0 + sum<N1toN...>::value;
6002 };
6003
6004 template <>
6005 struct sum<>
6006 {
6007 static constexpr auto value = 0;
6008 };
6009
6010 static_assert(sum<>::value == 0, "");
6011 static_assert(sum<1>::value == 1, "");
6012 static_assert(sum<23>::value == 23, "");
6013 static_assert(sum<1, 2>::value == 3, "");
6014 static_assert(sum<5, 5, 11>::value == 21, "");
6015 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6016
6017 }
6018
6019 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6020 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6021 // because of this.
6022 namespace test_template_alias_sfinae
6023 {
6024
6025 struct foo {};
6026
6027 template<typename T>
6028 using member = typename T::member_type;
6029
6030 template<typename T>
6031 void func(...) {}
6032
6033 template<typename T>
6034 void func(member<T>*) {}
6035
6036 void test();
6037
6038 void test() { func<foo>(0); }
6039
6040 }
6041
6042 } // namespace cxx11
6043
6044 #endif // __cplusplus >= 201103L
6045
6046
6047
6048 _ACEOF
6049 if ac_fn_cxx_try_compile "$LINENO"; then :
6050 eval $cachevar=yes
6051 else
6052 eval $cachevar=no
6053 fi
6054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6055 CXX="$ac_save_CXX"
6056 fi
6057 eval ac_res=\$$cachevar
6058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6059 $as_echo "$ac_res" >&6; }
6060 if eval test x\$$cachevar = xyes; then
6061 CXX_DIALECT="$switch"
6062 ac_success=yes
6063 break
6064 fi
6065 done
6066 if test x$ac_success = xyes; then
6067 break
6068 fi
6069 done
6070 fi
6071 ac_ext=c
6072 ac_cpp='$CPP $CPPFLAGS'
6073 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6074 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6075 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6076
6077 if test x$ax_cxx_compile_cxx11_required = xtrue; then
6078 if test x$ac_success = xno; then
6079 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
6080 fi
6081 fi
6082 if test x$ac_success = xno; then
6083 HAVE_CXX11=0
6084 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
6085 $as_echo "$as_me: No compiler with C++11 support was found" >&6;}
6086 else
6087 HAVE_CXX11=1
6088
6089 $as_echo "#define HAVE_CXX11 1" >>confdefs.h
6090
6091 fi
6092
6093
6094
6095
6096 # Dependency checking.
6097 rm -rf .tst 2>/dev/null
6098 mkdir .tst 2>/dev/null
6099 if test -d .tst; then
6100 am__leading_dot=.
6101 else
6102 am__leading_dot=_
6103 fi
6104 rmdir .tst 2>/dev/null
6105
6106 DEPDIR="${am__leading_dot}deps"
6107
6108 ac_config_commands="$ac_config_commands depdir"
6109
6110
6111 depcc="$CC" am_compiler_list=
6112
6113 am_depcomp=$ac_aux_dir/depcomp
6114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6115 $as_echo_n "checking dependency style of $depcc... " >&6; }
6116 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
6117 $as_echo_n "(cached) " >&6
6118 else
6119 if test -f "$am_depcomp"; then
6120 # We make a subdir and do the tests there. Otherwise we can end up
6121 # making bogus files that we don't know about and never remove. For
6122 # instance it was reported that on HP-UX the gcc test will end up
6123 # making a dummy file named `D' -- because `-MD' means `put the output
6124 # in D'.
6125 mkdir conftest.dir
6126 # Copy depcomp to subdir because otherwise we won't find it if we're
6127 # using a relative directory.
6128 cp "$am_depcomp" conftest.dir
6129 cd conftest.dir
6130 # We will build objects and dependencies in a subdirectory because
6131 # it helps to detect inapplicable dependency modes. For instance
6132 # both Tru64's cc and ICC support -MD to output dependencies as a
6133 # side effect of compilation, but ICC will put the dependencies in
6134 # the current directory while Tru64 will put them in the object
6135 # directory.
6136 mkdir sub
6137
6138 am_cv_CC_dependencies_compiler_type=none
6139 if test "$am_compiler_list" = ""; then
6140 am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6141 fi
6142 for depmode in $am_compiler_list; do
6143 if test $depmode = none; then break; fi
6144
6145 $as_echo "$as_me:$LINENO: trying $depmode" >&5
6146 # Setup a source with many dependencies, because some compilers
6147 # like to wrap large dependency lists on column 80 (with \), and
6148 # we should not choose a depcomp mode which is confused by this.
6149 #
6150 # We need to recreate these files for each test, as the compiler may
6151 # overwrite some of them when testing with obscure command lines.
6152 # This happens at least with the AIX C compiler.
6153 : > sub/conftest.c
6154 for i in 1 2 3 4 5 6; do
6155 echo '#include "conftst'$i'.h"' >> sub/conftest.c
6156 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
6157 # Solaris 8's {/usr,}/bin/sh.
6158 touch sub/conftst$i.h
6159 done
6160 echo "include sub/conftest.Po" > confmf
6161
6162 # We check with `-c' and `-o' for the sake of the "dashmstdout"
6163 # mode. It turns out that the SunPro C++ compiler does not properly
6164 # handle `-M -o', and we need to detect this.
6165 depcmd="depmode=$depmode \
6166 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
6167 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6168 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
6169 echo "| $depcmd" | sed -e 's/ */ /g' >&5
6170 if env $depcmd > conftest.err 2>&1 &&
6171 grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
6172 grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
6173 ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
6174 # icc doesn't choke on unknown options, it will just issue warnings
6175 # or remarks (even with -Werror). So we grep stderr for any message
6176 # that says an option was ignored or not supported.
6177 # When given -MP, icc 7.0 and 7.1 complain thusly:
6178 # icc: Command line warning: ignoring option '-M'; no argument required
6179 # The diagnosis changed in icc 8.0:
6180 # icc: Command line remark: option '-MP' not supported
6181 if (grep 'ignoring option' conftest.err ||
6182 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6183 am_cv_CC_dependencies_compiler_type=$depmode
6184 $as_echo "$as_me:$LINENO: success" >&5
6185 break
6186 fi
6187 fi
6188 $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
6189 sed -e 's/^/| /' < conftest.err >&5
6190 done
6191
6192 cd ..
6193 rm -rf conftest.dir
6194 else
6195 am_cv_CC_dependencies_compiler_type=none
6196 fi
6197
6198 fi
6199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6200 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6201 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
6202 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
6203 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6204
6205 fi
6206
6207
6208
6209 CONFIG_OBS=
6210 CONFIG_DEPS=
6211 CONFIG_SRCS=
6212 ENABLE_CFLAGS=
6213
6214 CONFIG_ALL=
6215 CONFIG_CLEAN=
6216 CONFIG_INSTALL=
6217 CONFIG_UNINSTALL=
6218
6219 # If we haven't got the data from the intl directory,
6220 # assume NLS is disabled.
6221 USE_NLS=no
6222 LIBINTL=
6223 LIBINTL_DEP=
6224 INCINTL=
6225 XGETTEXT=
6226 GMSGFMT=
6227 POSUB=
6228
6229 if test -f ../intl/config.intl; then
6230 . ../intl/config.intl
6231 fi
6232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
6233 $as_echo_n "checking whether NLS is requested... " >&6; }
6234 if test x"$USE_NLS" != xyes; then
6235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6236 $as_echo "no" >&6; }
6237 else
6238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6239 $as_echo "yes" >&6; }
6240
6241 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
6242
6243
6244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
6245 $as_echo_n "checking for catalogs to be installed... " >&6; }
6246 # Look for .po and .gmo files in the source directory.
6247 CATALOGS=
6248 XLINGUAS=
6249 for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
6250 # If there aren't any .gmo files the shell will give us the
6251 # literal string "../path/to/srcdir/po/*.gmo" which has to be
6252 # weeded out.
6253 case "$cat" in *\**)
6254 continue;;
6255 esac
6256 # The quadruple backslash is collapsed to a double backslash
6257 # by the backticks, then collapsed again by the double quotes,
6258 # leaving us with one backslash in the sed expression (right
6259 # before the dot that mustn't act as a wildcard).
6260 cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
6261 lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
6262 # The user is allowed to set LINGUAS to a list of languages to
6263 # install catalogs for. If it's empty that means "all of them."
6264 if test "x$LINGUAS" = x; then
6265 CATALOGS="$CATALOGS $cat"
6266 XLINGUAS="$XLINGUAS $lang"
6267 else
6268 case "$LINGUAS" in *$lang*)
6269 CATALOGS="$CATALOGS $cat"
6270 XLINGUAS="$XLINGUAS $lang"
6271 ;;
6272 esac
6273 fi
6274 done
6275 LINGUAS="$XLINGUAS"
6276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
6277 $as_echo "$LINGUAS" >&6; }
6278
6279
6280 DATADIRNAME=share
6281
6282 INSTOBJEXT=.mo
6283
6284 GENCAT=gencat
6285
6286 CATOBJEXT=.gmo
6287
6288 fi
6289
6290 localedir='${datadir}/locale'
6291
6292
6293 if test x"$USE_NLS" = xyes; then
6294 CONFIG_ALL="$CONFIG_ALL all-po"
6295 CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
6296 CONFIG_INSTALL="$CONFIG_INSTALL install-po"
6297 CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
6298 fi
6299
6300 PACKAGE=gdb
6301
6302 cat >>confdefs.h <<_ACEOF
6303 #define PACKAGE "$PACKAGE"
6304 _ACEOF
6305
6306
6307
6308 # We never need to detect it in this sub-configure.
6309 # But preserve it for config.status --recheck.
6310
6311
6312
6313 MAKEINFO_EXTRA_FLAGS=""
6314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
6315 $as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
6316 if ${gdb_cv_have_makeinfo_click+:} false; then :
6317 $as_echo_n "(cached) " >&6
6318 else
6319 echo '@clicksequence{a @click{} b}' >conftest.texinfo
6320 if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
6321 gdb_cv_have_makeinfo_click=yes
6322 else
6323 gdb_cv_have_makeinfo_click=no
6324 fi
6325 fi
6326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
6327 $as_echo "$gdb_cv_have_makeinfo_click" >&6; }
6328 if test x"$gdb_cv_have_makeinfo_click" = xyes; then
6329 MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
6330 fi
6331
6332
6333
6334
6335 # Check whether --with-separate-debug-dir was given.
6336 if test "${with_separate_debug_dir+set}" = set; then :
6337 withval=$with_separate_debug_dir;
6338 DEBUGDIR=$withval
6339 else
6340 DEBUGDIR=${libdir}/debug
6341 fi
6342
6343
6344 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6345 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6346 ac_define_dir=`eval echo $DEBUGDIR`
6347 ac_define_dir=`eval echo $ac_define_dir`
6348
6349 cat >>confdefs.h <<_ACEOF
6350 #define DEBUGDIR "$ac_define_dir"
6351 _ACEOF
6352
6353
6354
6355
6356 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6357 if test "x$prefix" = xNONE; then
6358 test_prefix=/usr/local
6359 else
6360 test_prefix=$prefix
6361 fi
6362 else
6363 test_prefix=$exec_prefix
6364 fi
6365 value=0
6366 case ${ac_define_dir} in
6367 "${test_prefix}"|"${test_prefix}/"*|\
6368 '${exec_prefix}'|'${exec_prefix}/'*)
6369 value=1
6370 ;;
6371 esac
6372
6373 cat >>confdefs.h <<_ACEOF
6374 #define DEBUGDIR_RELOCATABLE $value
6375 _ACEOF
6376
6377
6378
6379
6380 # We can't pass paths as command line arguments.
6381 # Mingw32 tries to be clever and will convert the paths for us.
6382 # For example -DBINDIR="/usr/local/bin" passed on the command line may get
6383 # converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
6384 # This breaks GDB's relocatable path conversions since paths passed in
6385 # config.h would not get so translated, the path prefixes no longer match.
6386
6387 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6388 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6389 ac_define_dir=`eval echo $bindir`
6390 ac_define_dir=`eval echo $ac_define_dir`
6391
6392 cat >>confdefs.h <<_ACEOF
6393 #define BINDIR "$ac_define_dir"
6394 _ACEOF
6395
6396
6397
6398 # GDB's datadir relocation
6399
6400
6401
6402 # Check whether --with-gdb-datadir was given.
6403 if test "${with_gdb_datadir+set}" = set; then :
6404 withval=$with_gdb_datadir;
6405 GDB_DATADIR=$withval
6406 else
6407 GDB_DATADIR=${datadir}/gdb
6408 fi
6409
6410
6411 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6412 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6413 ac_define_dir=`eval echo $GDB_DATADIR`
6414 ac_define_dir=`eval echo $ac_define_dir`
6415
6416 cat >>confdefs.h <<_ACEOF
6417 #define GDB_DATADIR "$ac_define_dir"
6418 _ACEOF
6419
6420
6421
6422
6423 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6424 if test "x$prefix" = xNONE; then
6425 test_prefix=/usr/local
6426 else
6427 test_prefix=$prefix
6428 fi
6429 else
6430 test_prefix=$exec_prefix
6431 fi
6432 value=0
6433 case ${ac_define_dir} in
6434 "${test_prefix}"|"${test_prefix}/"*|\
6435 '${exec_prefix}'|'${exec_prefix}/'*)
6436 value=1
6437 ;;
6438 esac
6439
6440 cat >>confdefs.h <<_ACEOF
6441 #define GDB_DATADIR_RELOCATABLE $value
6442 _ACEOF
6443
6444
6445
6446
6447
6448 # Check whether --with-relocated-sources was given.
6449 if test "${with_relocated_sources+set}" = set; then :
6450 withval=$with_relocated_sources; reloc_srcdir="${withval}"
6451
6452 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6453 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6454 ac_define_dir=`eval echo $reloc_srcdir`
6455 ac_define_dir=`eval echo $ac_define_dir`
6456
6457 cat >>confdefs.h <<_ACEOF
6458 #define RELOC_SRCDIR "$ac_define_dir"
6459 _ACEOF
6460
6461
6462
6463 fi
6464
6465
6466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
6467 $as_echo_n "checking for default auto-load directory... " >&6; }
6468
6469 # Check whether --with-auto-load-dir was given.
6470 if test "${with_auto_load_dir+set}" = set; then :
6471 withval=$with_auto_load_dir;
6472 else
6473 with_auto_load_dir='$debugdir:$datadir/auto-load'
6474 fi
6475
6476 escape_dir=`echo $with_auto_load_dir | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6477
6478 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6479 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6480 ac_define_dir=`eval echo $escape_dir`
6481 ac_define_dir=`eval echo $ac_define_dir`
6482
6483 cat >>confdefs.h <<_ACEOF
6484 #define AUTO_LOAD_DIR "$ac_define_dir"
6485 _ACEOF
6486
6487
6488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
6489 $as_echo "$with_auto_load_dir" >&6; }
6490
6491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
6492 $as_echo_n "checking for default auto-load safe-path... " >&6; }
6493
6494 # Check whether --with-auto-load-safe-path was given.
6495 if test "${with_auto_load_safe_path+set}" = set; then :
6496 withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
6497 with_auto_load_safe_path="/"
6498 fi
6499 else
6500 with_auto_load_safe_path="$with_auto_load_dir"
6501 fi
6502
6503 escape_dir=`echo $with_auto_load_safe_path | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6504
6505 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6506 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6507 ac_define_dir=`eval echo $escape_dir`
6508 ac_define_dir=`eval echo $ac_define_dir`
6509
6510 cat >>confdefs.h <<_ACEOF
6511 #define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
6512 _ACEOF
6513
6514
6515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
6516 $as_echo "$with_auto_load_safe_path" >&6; }
6517
6518
6519
6520 subdirs="$subdirs testsuite"
6521
6522
6523 # Check whether to support alternative target configurations
6524 # Check whether --enable-targets was given.
6525 if test "${enable_targets+set}" = set; then :
6526 enableval=$enable_targets; case "${enableval}" in
6527 yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
6528 ;;
6529 no) enable_targets= ;;
6530 *) enable_targets=$enableval ;;
6531 esac
6532 fi
6533
6534
6535 # Check whether to enable 64-bit support on 32-bit hosts
6536 # Check whether --enable-64-bit-bfd was given.
6537 if test "${enable_64_bit_bfd+set}" = set; then :
6538 enableval=$enable_64_bit_bfd; case "${enableval}" in
6539 yes) want64=true ;;
6540 no) want64=false ;;
6541 *) as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
6542 esac
6543 else
6544 want64=false
6545 fi
6546
6547 # Provide defaults for some variables set by the per-host and per-target
6548 # configuration.
6549 gdb_host_obs=posix-hdep.o
6550
6551 if test "${target}" = "${host}"; then
6552 gdb_native=yes
6553 else
6554 gdb_native=no
6555 fi
6556
6557 . $srcdir/configure.host
6558
6559 # Add in the common host objects.
6560 . $srcdir/gdbsupport/common.host
6561 gdb_host_obs="$gdb_host_obs $common_host_obs"
6562
6563 # Accumulate some settings from configure.tgt over all enabled targets
6564
6565 TARGET_OBS=
6566 all_targets=
6567 HAVE_NATIVE_GCORE_TARGET=
6568
6569 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
6570 do
6571 if test "$targ_alias" = "all"; then
6572 all_targets=true
6573 else
6574 # Canonicalize the secondary target names.
6575 result=`$ac_config_sub $targ_alias 2>/dev/null`
6576 if test -n "$result"; then
6577 targ=$result
6578 else
6579 targ=$targ_alias
6580 fi
6581
6582 . ${srcdir}/configure.tgt
6583
6584 if test -z "${gdb_target_obs}"; then :
6585 as_fn_error $? "configuration ${targ} is unsupported." "$LINENO" 5
6586 fi
6587
6588 # Target-specific object files
6589 for i in ${gdb_target_obs}; do
6590 case " $TARGET_OBS " in
6591 *" ${i} "*) ;;
6592 *)
6593 TARGET_OBS="$TARGET_OBS ${i}"
6594 ;;
6595 esac
6596 done
6597
6598 # Check whether this target needs 64-bit CORE_ADDR
6599 if test x${want64} = xfalse; then
6600 . ${srcdir}/../bfd/config.bfd
6601 fi
6602
6603 # Check whether this target is native and supports gcore.
6604 if test $gdb_native = yes -a "$targ_alias" = "$target_alias" \
6605 && $gdb_have_gcore; then
6606 HAVE_NATIVE_GCORE_TARGET=1
6607 fi
6608 fi
6609 done
6610
6611 if test x${all_targets} = xtrue; then
6612
6613 # We want all 64-bit targets if we either:
6614 # - run on a 64-bit host or
6615 # - already require 64-bit support for some other target or
6616 # - the --enable-64-bit-bfd option was supplied
6617 # Otherwise we only support all 32-bit targets.
6618 #
6619 # NOTE: This test must be in sync with the corresponding
6620 # tests in BFD!
6621
6622 if test x${want64} = xfalse; then
6623 # The cast to long int works around a bug in the HP C Compiler
6624 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6625 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6626 # This bug is HP SR number 8606223364.
6627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
6628 $as_echo_n "checking size of long... " >&6; }
6629 if ${ac_cv_sizeof_long+:} false; then :
6630 $as_echo_n "(cached) " >&6
6631 else
6632 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
6633
6634 else
6635 if test "$ac_cv_type_long" = yes; then
6636 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6637 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6638 as_fn_error 77 "cannot compute sizeof (long)
6639 See \`config.log' for more details" "$LINENO" 5; }
6640 else
6641 ac_cv_sizeof_long=0
6642 fi
6643 fi
6644
6645 fi
6646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
6647 $as_echo "$ac_cv_sizeof_long" >&6; }
6648
6649
6650
6651 cat >>confdefs.h <<_ACEOF
6652 #define SIZEOF_LONG $ac_cv_sizeof_long
6653 _ACEOF
6654
6655
6656 if test "x${ac_cv_sizeof_long}" = "x8"; then
6657 want64=true
6658 fi
6659 fi
6660 if test x${want64} = xtrue; then
6661 TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
6662 else
6663 TARGET_OBS='$(ALL_TARGET_OBS)'
6664 fi
6665 fi
6666
6667
6668
6669
6670 # For other settings, only the main target counts.
6671 gdb_sim=
6672 gdb_osabi=
6673 build_gdbserver=
6674 targ=$target; . ${srcdir}/configure.tgt
6675
6676 # Fetch the default architecture and default target vector from BFD.
6677 targ=$target; . $srcdir/../bfd/config.bfd
6678
6679 # We only want the first architecture, so strip off the others if
6680 # there is more than one.
6681 targ_archs=`echo $targ_archs | sed 's/ .*//'`
6682
6683 if test "x$targ_archs" != x; then
6684
6685 cat >>confdefs.h <<_ACEOF
6686 #define DEFAULT_BFD_ARCH $targ_archs
6687 _ACEOF
6688
6689 fi
6690 if test "x$targ_defvec" != x; then
6691
6692 cat >>confdefs.h <<_ACEOF
6693 #define DEFAULT_BFD_VEC $targ_defvec
6694 _ACEOF
6695
6696 fi
6697
6698 # Enable MI.
6699 # Check whether --enable-gdbmi was given.
6700 if test "${enable_gdbmi+set}" = set; then :
6701 enableval=$enable_gdbmi; case $enableval in
6702 yes | no)
6703 ;;
6704 *)
6705 as_fn_error $? "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
6706 esac
6707 else
6708 enable_gdbmi=yes
6709 fi
6710
6711 if test x"$enable_gdbmi" = xyes; then
6712 if test -d $srcdir/mi; then
6713 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
6714 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
6715 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
6716 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
6717 fi
6718 fi
6719
6720 # Enable TUI.
6721 # Check whether --enable-tui was given.
6722 if test "${enable_tui+set}" = set; then :
6723 enableval=$enable_tui; case $enableval in
6724 yes | no | auto)
6725 ;;
6726 *)
6727 as_fn_error $? "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
6728 esac
6729 else
6730 enable_tui=auto
6731 fi
6732
6733
6734 # Enable gdbtk.
6735 # Check whether --enable-gdbtk was given.
6736 if test "${enable_gdbtk+set}" = set; then :
6737 enableval=$enable_gdbtk; case $enableval in
6738 yes | no)
6739 ;;
6740 *)
6741 as_fn_error $? "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
6742 esac
6743 else
6744 if test -d $srcdir/gdbtk; then
6745 enable_gdbtk=yes
6746 else
6747 enable_gdbtk=no
6748 fi
6749 fi
6750
6751 # We unconditionally disable gdbtk tests on selected platforms.
6752 case $host_os in
6753 go32* | windows*)
6754 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
6755 $as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
6756 enable_gdbtk=no ;;
6757 esac
6758
6759 # Libunwind support for ia64.
6760
6761
6762 # Check whether --with-libunwind-ia64 was given.
6763 if test "${with_libunwind_ia64+set}" = set; then :
6764 withval=$with_libunwind_ia64;
6765 else
6766 with_libunwind_ia64=auto
6767 fi
6768
6769
6770 # Backward compatibility option.
6771 if test "${with_libunwind+set}" = set; then
6772 if test x"$with_libunwind_ia64" != xauto; then
6773 as_fn_error $? "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
6774 fi
6775 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
6776 $as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
6777 with_libunwind_ia64="$with_libunwind"
6778 fi
6779
6780 case "$with_libunwind_ia64" in
6781 yes | no)
6782 ;;
6783 auto)
6784 for ac_header in libunwind-ia64.h
6785 do :
6786 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
6787 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
6788 cat >>confdefs.h <<_ACEOF
6789 #define HAVE_LIBUNWIND_IA64_H 1
6790 _ACEOF
6791
6792 fi
6793
6794 done
6795
6796 with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
6797 ;;
6798 *)
6799 as_fn_error $? "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
6800 ;;
6801 esac
6802
6803 if test x"$with_libunwind_ia64" = xyes; then
6804 for ac_header in libunwind-ia64.h
6805 do :
6806 ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
6807 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
6808 cat >>confdefs.h <<_ACEOF
6809 #define HAVE_LIBUNWIND_IA64_H 1
6810 _ACEOF
6811
6812 fi
6813
6814 done
6815
6816 if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
6817 as_fn_error $? "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
6818 fi
6819 CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
6820 CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
6821 CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
6822 fi
6823
6824 opt_curses=no
6825
6826 # Check whether --with-curses was given.
6827 if test "${with_curses+set}" = set; then :
6828 withval=$with_curses; opt_curses=$withval
6829 fi
6830
6831
6832 prefer_curses=no
6833 if test "$opt_curses" = "yes"; then
6834 prefer_curses=yes
6835 fi
6836
6837 # Profiling support.
6838 # Check whether --enable-profiling was given.
6839 if test "${enable_profiling+set}" = set; then :
6840 enableval=$enable_profiling; case $enableval in
6841 yes | no)
6842 ;;
6843 *)
6844 as_fn_error $? "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
6845 esac
6846 else
6847 enable_profiling=no
6848 fi
6849
6850
6851 for ac_func in monstartup _mcleanup
6852 do :
6853 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6854 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6855 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6856 cat >>confdefs.h <<_ACEOF
6857 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6858 _ACEOF
6859
6860 fi
6861 done
6862
6863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
6864 $as_echo_n "checking for _etext... " >&6; }
6865 if ${ac_cv_var__etext+:} false; then :
6866 $as_echo_n "(cached) " >&6
6867 else
6868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6869 /* end confdefs.h. */
6870 #include <stdlib.h>
6871 extern char _etext;
6872
6873 int
6874 main ()
6875 {
6876 free (&_etext);
6877 ;
6878 return 0;
6879 }
6880 _ACEOF
6881 if ac_fn_c_try_link "$LINENO"; then :
6882 ac_cv_var__etext=yes
6883 else
6884 ac_cv_var__etext=no
6885 fi
6886 rm -f core conftest.err conftest.$ac_objext \
6887 conftest$ac_exeext conftest.$ac_ext
6888 fi
6889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
6890 $as_echo "$ac_cv_var__etext" >&6; }
6891 if test $ac_cv_var__etext = yes; then
6892
6893 $as_echo "#define HAVE__ETEXT 1" >>confdefs.h
6894
6895 fi
6896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
6897 $as_echo_n "checking for etext... " >&6; }
6898 if ${ac_cv_var_etext+:} false; then :
6899 $as_echo_n "(cached) " >&6
6900 else
6901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6902 /* end confdefs.h. */
6903 #include <stdlib.h>
6904 extern char etext;
6905
6906 int
6907 main ()
6908 {
6909 free (&etext);
6910 ;
6911 return 0;
6912 }
6913 _ACEOF
6914 if ac_fn_c_try_link "$LINENO"; then :
6915 ac_cv_var_etext=yes
6916 else
6917 ac_cv_var_etext=no
6918 fi
6919 rm -f core conftest.err conftest.$ac_objext \
6920 conftest$ac_exeext conftest.$ac_ext
6921 fi
6922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
6923 $as_echo "$ac_cv_var_etext" >&6; }
6924 if test $ac_cv_var_etext = yes; then
6925
6926 $as_echo "#define HAVE_ETEXT 1" >>confdefs.h
6927
6928 fi
6929 if test "$enable_profiling" = yes ; then
6930 if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
6931 as_fn_error $? "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
6932 fi
6933 PROFILE_CFLAGS=-pg
6934 OLD_CFLAGS="$CFLAGS"
6935 CFLAGS="$CFLAGS $PROFILE_CFLAGS"
6936
6937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
6938 $as_echo_n "checking whether $CC supports -pg... " >&6; }
6939 if ${ac_cv_cc_supports_pg+:} false; then :
6940 $as_echo_n "(cached) " >&6
6941 else
6942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6943 /* end confdefs.h. */
6944
6945 int
6946 main ()
6947 {
6948 int x;
6949 ;
6950 return 0;
6951 }
6952 _ACEOF
6953 if ac_fn_c_try_compile "$LINENO"; then :
6954 ac_cv_cc_supports_pg=yes
6955 else
6956 ac_cv_cc_supports_pg=no
6957 fi
6958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6959 fi
6960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
6961 $as_echo "$ac_cv_cc_supports_pg" >&6; }
6962
6963 if test $ac_cv_cc_supports_pg = no; then
6964 as_fn_error $? "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
6965 fi
6966
6967 CFLAGS="$OLD_CFLAGS"
6968 fi
6969
6970 CODESIGN_CERT=
6971 # Check whether --enable-codesign was given.
6972 if test "${enable_codesign+set}" = set; then :
6973 enableval=$enable_codesign; CODESIGN_CERT=$enableval
6974 fi
6975
6976
6977
6978
6979
6980 # Check whether --with-pkgversion was given.
6981 if test "${with_pkgversion+set}" = set; then :
6982 withval=$with_pkgversion; case "$withval" in
6983 yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
6984 no) PKGVERSION= ;;
6985 *) PKGVERSION="($withval) " ;;
6986 esac
6987 else
6988 PKGVERSION="(GDB) "
6989
6990 fi
6991
6992
6993
6994
6995
6996 # Check whether --with-bugurl was given.
6997 if test "${with_bugurl+set}" = set; then :
6998 withval=$with_bugurl; case "$withval" in
6999 yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
7000 no) BUGURL=
7001 ;;
7002 *) BUGURL="$withval"
7003 ;;
7004 esac
7005 else
7006 BUGURL="http://www.gnu.org/software/gdb/bugs/"
7007
7008 fi
7009
7010 case ${BUGURL} in
7011 "")
7012 REPORT_BUGS_TO=
7013 REPORT_BUGS_TEXI=
7014 ;;
7015 *)
7016 REPORT_BUGS_TO="<$BUGURL>"
7017 REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
7018 ;;
7019 esac;
7020
7021
7022
7023
7024 cat >>confdefs.h <<_ACEOF
7025 #define PKGVERSION "$PKGVERSION"
7026 _ACEOF
7027
7028
7029 cat >>confdefs.h <<_ACEOF
7030 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
7031 _ACEOF
7032
7033
7034 # --------------------- #
7035 # Checks for programs. #
7036 # --------------------- #
7037
7038 for ac_prog in gawk mawk nawk awk
7039 do
7040 # Extract the first word of "$ac_prog", so it can be a program name with args.
7041 set dummy $ac_prog; ac_word=$2
7042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7043 $as_echo_n "checking for $ac_word... " >&6; }
7044 if ${ac_cv_prog_AWK+:} false; then :
7045 $as_echo_n "(cached) " >&6
7046 else
7047 if test -n "$AWK"; then
7048 ac_cv_prog_AWK="$AWK" # Let the user override the test.
7049 else
7050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7051 for as_dir in $PATH
7052 do
7053 IFS=$as_save_IFS
7054 test -z "$as_dir" && as_dir=.
7055 for ac_exec_ext in '' $ac_executable_extensions; do
7056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7057 ac_cv_prog_AWK="$ac_prog"
7058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7059 break 2
7060 fi
7061 done
7062 done
7063 IFS=$as_save_IFS
7064
7065 fi
7066 fi
7067 AWK=$ac_cv_prog_AWK
7068 if test -n "$AWK"; then
7069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
7070 $as_echo "$AWK" >&6; }
7071 else
7072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7073 $as_echo "no" >&6; }
7074 fi
7075
7076
7077 test -n "$AWK" && break
7078 done
7079
7080 # Find a good install program. We prefer a C program (faster),
7081 # so one script is as good as another. But avoid the broken or
7082 # incompatible versions:
7083 # SysV /etc/install, /usr/sbin/install
7084 # SunOS /usr/etc/install
7085 # IRIX /sbin/install
7086 # AIX /bin/install
7087 # AmigaOS /C/install, which installs bootblocks on floppy discs
7088 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
7089 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
7090 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
7091 # OS/2's system install, which has a completely different semantic
7092 # ./install, which can be erroneously created by make from ./install.sh.
7093 # Reject install programs that cannot install multiple files.
7094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
7095 $as_echo_n "checking for a BSD-compatible install... " >&6; }
7096 if test -z "$INSTALL"; then
7097 if ${ac_cv_path_install+:} false; then :
7098 $as_echo_n "(cached) " >&6
7099 else
7100 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7101 for as_dir in $PATH
7102 do
7103 IFS=$as_save_IFS
7104 test -z "$as_dir" && as_dir=.
7105 # Account for people who put trailing slashes in PATH elements.
7106 case $as_dir/ in #((
7107 ./ | .// | /[cC]/* | \
7108 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
7109 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
7110 /usr/ucb/* ) ;;
7111 *)
7112 # OSF1 and SCO ODT 3.0 have their own names for install.
7113 # Don't use installbsd from OSF since it installs stuff as root
7114 # by default.
7115 for ac_prog in ginstall scoinst install; do
7116 for ac_exec_ext in '' $ac_executable_extensions; do
7117 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
7118 if test $ac_prog = install &&
7119 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7120 # AIX install. It has an incompatible calling convention.
7121 :
7122 elif test $ac_prog = install &&
7123 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7124 # program-specific install script used by HP pwplus--don't use.
7125 :
7126 else
7127 rm -rf conftest.one conftest.two conftest.dir
7128 echo one > conftest.one
7129 echo two > conftest.two
7130 mkdir conftest.dir
7131 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
7132 test -s conftest.one && test -s conftest.two &&
7133 test -s conftest.dir/conftest.one &&
7134 test -s conftest.dir/conftest.two
7135 then
7136 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
7137 break 3
7138 fi
7139 fi
7140 fi
7141 done
7142 done
7143 ;;
7144 esac
7145
7146 done
7147 IFS=$as_save_IFS
7148
7149 rm -rf conftest.one conftest.two conftest.dir
7150
7151 fi
7152 if test "${ac_cv_path_install+set}" = set; then
7153 INSTALL=$ac_cv_path_install
7154 else
7155 # As a last resort, use the slow shell script. Don't cache a
7156 # value for INSTALL within a source directory, because that will
7157 # break other packages using the cache if that directory is
7158 # removed, or if the value is a relative name.
7159 INSTALL=$ac_install_sh
7160 fi
7161 fi
7162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
7163 $as_echo "$INSTALL" >&6; }
7164
7165 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
7166 # It thinks the first close brace ends the variable substitution.
7167 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
7168
7169 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
7170
7171 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
7172
7173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7174 $as_echo_n "checking whether ln -s works... " >&6; }
7175 LN_S=$as_ln_s
7176 if test "$LN_S" = "ln -s"; then
7177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7178 $as_echo "yes" >&6; }
7179 else
7180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7181 $as_echo "no, using $LN_S" >&6; }
7182 fi
7183
7184 if test -n "$ac_tool_prefix"; then
7185 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7186 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7188 $as_echo_n "checking for $ac_word... " >&6; }
7189 if ${ac_cv_prog_RANLIB+:} false; then :
7190 $as_echo_n "(cached) " >&6
7191 else
7192 if test -n "$RANLIB"; then
7193 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7194 else
7195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7196 for as_dir in $PATH
7197 do
7198 IFS=$as_save_IFS
7199 test -z "$as_dir" && as_dir=.
7200 for ac_exec_ext in '' $ac_executable_extensions; do
7201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7202 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7204 break 2
7205 fi
7206 done
7207 done
7208 IFS=$as_save_IFS
7209
7210 fi
7211 fi
7212 RANLIB=$ac_cv_prog_RANLIB
7213 if test -n "$RANLIB"; then
7214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7215 $as_echo "$RANLIB" >&6; }
7216 else
7217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7218 $as_echo "no" >&6; }
7219 fi
7220
7221
7222 fi
7223 if test -z "$ac_cv_prog_RANLIB"; then
7224 ac_ct_RANLIB=$RANLIB
7225 # Extract the first word of "ranlib", so it can be a program name with args.
7226 set dummy ranlib; ac_word=$2
7227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7228 $as_echo_n "checking for $ac_word... " >&6; }
7229 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
7230 $as_echo_n "(cached) " >&6
7231 else
7232 if test -n "$ac_ct_RANLIB"; then
7233 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7234 else
7235 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7236 for as_dir in $PATH
7237 do
7238 IFS=$as_save_IFS
7239 test -z "$as_dir" && as_dir=.
7240 for ac_exec_ext in '' $ac_executable_extensions; do
7241 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7242 ac_cv_prog_ac_ct_RANLIB="ranlib"
7243 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7244 break 2
7245 fi
7246 done
7247 done
7248 IFS=$as_save_IFS
7249
7250 fi
7251 fi
7252 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7253 if test -n "$ac_ct_RANLIB"; then
7254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7255 $as_echo "$ac_ct_RANLIB" >&6; }
7256 else
7257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7258 $as_echo "no" >&6; }
7259 fi
7260
7261 if test "x$ac_ct_RANLIB" = x; then
7262 RANLIB=":"
7263 else
7264 case $cross_compiling:$ac_tool_warned in
7265 yes:)
7266 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7267 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7268 ac_tool_warned=yes ;;
7269 esac
7270 RANLIB=$ac_ct_RANLIB
7271 fi
7272 else
7273 RANLIB="$ac_cv_prog_RANLIB"
7274 fi
7275
7276 for ac_prog in 'bison -y' byacc
7277 do
7278 # Extract the first word of "$ac_prog", so it can be a program name with args.
7279 set dummy $ac_prog; ac_word=$2
7280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7281 $as_echo_n "checking for $ac_word... " >&6; }
7282 if ${ac_cv_prog_YACC+:} false; then :
7283 $as_echo_n "(cached) " >&6
7284 else
7285 if test -n "$YACC"; then
7286 ac_cv_prog_YACC="$YACC" # Let the user override the test.
7287 else
7288 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7289 for as_dir in $PATH
7290 do
7291 IFS=$as_save_IFS
7292 test -z "$as_dir" && as_dir=.
7293 for ac_exec_ext in '' $ac_executable_extensions; do
7294 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7295 ac_cv_prog_YACC="$ac_prog"
7296 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7297 break 2
7298 fi
7299 done
7300 done
7301 IFS=$as_save_IFS
7302
7303 fi
7304 fi
7305 YACC=$ac_cv_prog_YACC
7306 if test -n "$YACC"; then
7307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
7308 $as_echo "$YACC" >&6; }
7309 else
7310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7311 $as_echo "no" >&6; }
7312 fi
7313
7314
7315 test -n "$YACC" && break
7316 done
7317 test -n "$YACC" || YACC="yacc"
7318
7319
7320 if test -n "$ac_tool_prefix"; then
7321 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7322 set dummy ${ac_tool_prefix}ar; ac_word=$2
7323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7324 $as_echo_n "checking for $ac_word... " >&6; }
7325 if ${ac_cv_prog_AR+:} false; then :
7326 $as_echo_n "(cached) " >&6
7327 else
7328 if test -n "$AR"; then
7329 ac_cv_prog_AR="$AR" # Let the user override the test.
7330 else
7331 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7332 for as_dir in $PATH
7333 do
7334 IFS=$as_save_IFS
7335 test -z "$as_dir" && as_dir=.
7336 for ac_exec_ext in '' $ac_executable_extensions; do
7337 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7338 ac_cv_prog_AR="${ac_tool_prefix}ar"
7339 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7340 break 2
7341 fi
7342 done
7343 done
7344 IFS=$as_save_IFS
7345
7346 fi
7347 fi
7348 AR=$ac_cv_prog_AR
7349 if test -n "$AR"; then
7350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7351 $as_echo "$AR" >&6; }
7352 else
7353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7354 $as_echo "no" >&6; }
7355 fi
7356
7357
7358 fi
7359 if test -z "$ac_cv_prog_AR"; then
7360 ac_ct_AR=$AR
7361 # Extract the first word of "ar", so it can be a program name with args.
7362 set dummy ar; ac_word=$2
7363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7364 $as_echo_n "checking for $ac_word... " >&6; }
7365 if ${ac_cv_prog_ac_ct_AR+:} false; then :
7366 $as_echo_n "(cached) " >&6
7367 else
7368 if test -n "$ac_ct_AR"; then
7369 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7370 else
7371 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7372 for as_dir in $PATH
7373 do
7374 IFS=$as_save_IFS
7375 test -z "$as_dir" && as_dir=.
7376 for ac_exec_ext in '' $ac_executable_extensions; do
7377 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7378 ac_cv_prog_ac_ct_AR="ar"
7379 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7380 break 2
7381 fi
7382 done
7383 done
7384 IFS=$as_save_IFS
7385
7386 fi
7387 fi
7388 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7389 if test -n "$ac_ct_AR"; then
7390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7391 $as_echo "$ac_ct_AR" >&6; }
7392 else
7393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7394 $as_echo "no" >&6; }
7395 fi
7396
7397 if test "x$ac_ct_AR" = x; then
7398 AR=""
7399 else
7400 case $cross_compiling:$ac_tool_warned in
7401 yes:)
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7403 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7404 ac_tool_warned=yes ;;
7405 esac
7406 AR=$ac_ct_AR
7407 fi
7408 else
7409 AR="$ac_cv_prog_AR"
7410 fi
7411
7412 if test -n "$ac_tool_prefix"; then
7413 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
7414 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
7415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7416 $as_echo_n "checking for $ac_word... " >&6; }
7417 if ${ac_cv_prog_DLLTOOL+:} false; then :
7418 $as_echo_n "(cached) " >&6
7419 else
7420 if test -n "$DLLTOOL"; then
7421 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
7422 else
7423 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7424 for as_dir in $PATH
7425 do
7426 IFS=$as_save_IFS
7427 test -z "$as_dir" && as_dir=.
7428 for ac_exec_ext in '' $ac_executable_extensions; do
7429 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7430 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
7431 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7432 break 2
7433 fi
7434 done
7435 done
7436 IFS=$as_save_IFS
7437
7438 fi
7439 fi
7440 DLLTOOL=$ac_cv_prog_DLLTOOL
7441 if test -n "$DLLTOOL"; then
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
7443 $as_echo "$DLLTOOL" >&6; }
7444 else
7445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7446 $as_echo "no" >&6; }
7447 fi
7448
7449
7450 fi
7451 if test -z "$ac_cv_prog_DLLTOOL"; then
7452 ac_ct_DLLTOOL=$DLLTOOL
7453 # Extract the first word of "dlltool", so it can be a program name with args.
7454 set dummy dlltool; ac_word=$2
7455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7456 $as_echo_n "checking for $ac_word... " >&6; }
7457 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
7458 $as_echo_n "(cached) " >&6
7459 else
7460 if test -n "$ac_ct_DLLTOOL"; then
7461 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
7462 else
7463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7464 for as_dir in $PATH
7465 do
7466 IFS=$as_save_IFS
7467 test -z "$as_dir" && as_dir=.
7468 for ac_exec_ext in '' $ac_executable_extensions; do
7469 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7470 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
7471 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7472 break 2
7473 fi
7474 done
7475 done
7476 IFS=$as_save_IFS
7477
7478 fi
7479 fi
7480 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
7481 if test -n "$ac_ct_DLLTOOL"; then
7482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
7483 $as_echo "$ac_ct_DLLTOOL" >&6; }
7484 else
7485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7486 $as_echo "no" >&6; }
7487 fi
7488
7489 if test "x$ac_ct_DLLTOOL" = x; then
7490 DLLTOOL=""
7491 else
7492 case $cross_compiling:$ac_tool_warned in
7493 yes:)
7494 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7495 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7496 ac_tool_warned=yes ;;
7497 esac
7498 DLLTOOL=$ac_ct_DLLTOOL
7499 fi
7500 else
7501 DLLTOOL="$ac_cv_prog_DLLTOOL"
7502 fi
7503
7504 if test -n "$ac_tool_prefix"; then
7505 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
7506 set dummy ${ac_tool_prefix}windres; ac_word=$2
7507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7508 $as_echo_n "checking for $ac_word... " >&6; }
7509 if ${ac_cv_prog_WINDRES+:} false; then :
7510 $as_echo_n "(cached) " >&6
7511 else
7512 if test -n "$WINDRES"; then
7513 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
7514 else
7515 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7516 for as_dir in $PATH
7517 do
7518 IFS=$as_save_IFS
7519 test -z "$as_dir" && as_dir=.
7520 for ac_exec_ext in '' $ac_executable_extensions; do
7521 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7522 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
7523 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7524 break 2
7525 fi
7526 done
7527 done
7528 IFS=$as_save_IFS
7529
7530 fi
7531 fi
7532 WINDRES=$ac_cv_prog_WINDRES
7533 if test -n "$WINDRES"; then
7534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
7535 $as_echo "$WINDRES" >&6; }
7536 else
7537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7538 $as_echo "no" >&6; }
7539 fi
7540
7541
7542 fi
7543 if test -z "$ac_cv_prog_WINDRES"; then
7544 ac_ct_WINDRES=$WINDRES
7545 # Extract the first word of "windres", so it can be a program name with args.
7546 set dummy windres; ac_word=$2
7547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7548 $as_echo_n "checking for $ac_word... " >&6; }
7549 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
7550 $as_echo_n "(cached) " >&6
7551 else
7552 if test -n "$ac_ct_WINDRES"; then
7553 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
7554 else
7555 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7556 for as_dir in $PATH
7557 do
7558 IFS=$as_save_IFS
7559 test -z "$as_dir" && as_dir=.
7560 for ac_exec_ext in '' $ac_executable_extensions; do
7561 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7562 ac_cv_prog_ac_ct_WINDRES="windres"
7563 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7564 break 2
7565 fi
7566 done
7567 done
7568 IFS=$as_save_IFS
7569
7570 fi
7571 fi
7572 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
7573 if test -n "$ac_ct_WINDRES"; then
7574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
7575 $as_echo "$ac_ct_WINDRES" >&6; }
7576 else
7577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7578 $as_echo "no" >&6; }
7579 fi
7580
7581 if test "x$ac_ct_WINDRES" = x; then
7582 WINDRES=""
7583 else
7584 case $cross_compiling:$ac_tool_warned in
7585 yes:)
7586 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7587 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7588 ac_tool_warned=yes ;;
7589 esac
7590 WINDRES=$ac_ct_WINDRES
7591 fi
7592 else
7593 WINDRES="$ac_cv_prog_WINDRES"
7594 fi
7595
7596
7597 case $host_os in
7598 gnu*)
7599 # Needed for GNU Hurd hosts.
7600 if test -n "$ac_tool_prefix"; then
7601 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
7602 set dummy ${ac_tool_prefix}mig; ac_word=$2
7603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7604 $as_echo_n "checking for $ac_word... " >&6; }
7605 if ${ac_cv_prog_MIG+:} false; then :
7606 $as_echo_n "(cached) " >&6
7607 else
7608 if test -n "$MIG"; then
7609 ac_cv_prog_MIG="$MIG" # Let the user override the test.
7610 else
7611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7612 for as_dir in $PATH
7613 do
7614 IFS=$as_save_IFS
7615 test -z "$as_dir" && as_dir=.
7616 for ac_exec_ext in '' $ac_executable_extensions; do
7617 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7618 ac_cv_prog_MIG="${ac_tool_prefix}mig"
7619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7620 break 2
7621 fi
7622 done
7623 done
7624 IFS=$as_save_IFS
7625
7626 fi
7627 fi
7628 MIG=$ac_cv_prog_MIG
7629 if test -n "$MIG"; then
7630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
7631 $as_echo "$MIG" >&6; }
7632 else
7633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7634 $as_echo "no" >&6; }
7635 fi
7636
7637
7638 fi
7639 if test -z "$ac_cv_prog_MIG"; then
7640 ac_ct_MIG=$MIG
7641 # Extract the first word of "mig", so it can be a program name with args.
7642 set dummy mig; ac_word=$2
7643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7644 $as_echo_n "checking for $ac_word... " >&6; }
7645 if ${ac_cv_prog_ac_ct_MIG+:} false; then :
7646 $as_echo_n "(cached) " >&6
7647 else
7648 if test -n "$ac_ct_MIG"; then
7649 ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
7650 else
7651 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7652 for as_dir in $PATH
7653 do
7654 IFS=$as_save_IFS
7655 test -z "$as_dir" && as_dir=.
7656 for ac_exec_ext in '' $ac_executable_extensions; do
7657 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7658 ac_cv_prog_ac_ct_MIG="mig"
7659 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7660 break 2
7661 fi
7662 done
7663 done
7664 IFS=$as_save_IFS
7665
7666 fi
7667 fi
7668 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
7669 if test -n "$ac_ct_MIG"; then
7670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
7671 $as_echo "$ac_ct_MIG" >&6; }
7672 else
7673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7674 $as_echo "no" >&6; }
7675 fi
7676
7677 if test "x$ac_ct_MIG" = x; then
7678 MIG=""
7679 else
7680 case $cross_compiling:$ac_tool_warned in
7681 yes:)
7682 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7683 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7684 ac_tool_warned=yes ;;
7685 esac
7686 MIG=$ac_ct_MIG
7687 fi
7688 else
7689 MIG="$ac_cv_prog_MIG"
7690 fi
7691
7692 if test x"$MIG" = x; then
7693 as_fn_error $? "MIG not found but required for $host hosts" "$LINENO" 5
7694 fi
7695 ;;
7696 esac
7697
7698 # ---------------------- #
7699 # Checks for libraries. #
7700 # ---------------------- #
7701
7702 # We might need to link with -lm; most simulators need it.
7703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
7704 $as_echo_n "checking for main in -lm... " >&6; }
7705 if ${ac_cv_lib_m_main+:} false; then :
7706 $as_echo_n "(cached) " >&6
7707 else
7708 ac_check_lib_save_LIBS=$LIBS
7709 LIBS="-lm $LIBS"
7710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7711 /* end confdefs.h. */
7712
7713
7714 int
7715 main ()
7716 {
7717 return main ();
7718 ;
7719 return 0;
7720 }
7721 _ACEOF
7722 if ac_fn_c_try_link "$LINENO"; then :
7723 ac_cv_lib_m_main=yes
7724 else
7725 ac_cv_lib_m_main=no
7726 fi
7727 rm -f core conftest.err conftest.$ac_objext \
7728 conftest$ac_exeext conftest.$ac_ext
7729 LIBS=$ac_check_lib_save_LIBS
7730 fi
7731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
7732 $as_echo "$ac_cv_lib_m_main" >&6; }
7733 if test "x$ac_cv_lib_m_main" = xyes; then :
7734 cat >>confdefs.h <<_ACEOF
7735 #define HAVE_LIBM 1
7736 _ACEOF
7737
7738 LIBS="-lm $LIBS"
7739
7740 fi
7741
7742
7743 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
7744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
7745 $as_echo_n "checking for library containing gethostbyname... " >&6; }
7746 if ${ac_cv_search_gethostbyname+:} false; then :
7747 $as_echo_n "(cached) " >&6
7748 else
7749 ac_func_search_save_LIBS=$LIBS
7750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7751 /* end confdefs.h. */
7752
7753 /* Override any GCC internal prototype to avoid an error.
7754 Use char because int might match the return type of a GCC
7755 builtin and then its argument prototype would still apply. */
7756 #ifdef __cplusplus
7757 extern "C"
7758 #endif
7759 char gethostbyname ();
7760 int
7761 main ()
7762 {
7763 return gethostbyname ();
7764 ;
7765 return 0;
7766 }
7767 _ACEOF
7768 for ac_lib in '' nsl; do
7769 if test -z "$ac_lib"; then
7770 ac_res="none required"
7771 else
7772 ac_res=-l$ac_lib
7773 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7774 fi
7775 if ac_fn_c_try_link "$LINENO"; then :
7776 ac_cv_search_gethostbyname=$ac_res
7777 fi
7778 rm -f core conftest.err conftest.$ac_objext \
7779 conftest$ac_exeext
7780 if ${ac_cv_search_gethostbyname+:} false; then :
7781 break
7782 fi
7783 done
7784 if ${ac_cv_search_gethostbyname+:} false; then :
7785
7786 else
7787 ac_cv_search_gethostbyname=no
7788 fi
7789 rm conftest.$ac_ext
7790 LIBS=$ac_func_search_save_LIBS
7791 fi
7792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
7793 $as_echo "$ac_cv_search_gethostbyname" >&6; }
7794 ac_res=$ac_cv_search_gethostbyname
7795 if test "$ac_res" != no; then :
7796 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7797
7798 fi
7799
7800
7801 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
7802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
7803 $as_echo_n "checking for library containing socketpair... " >&6; }
7804 if ${ac_cv_search_socketpair+:} false; then :
7805 $as_echo_n "(cached) " >&6
7806 else
7807 ac_func_search_save_LIBS=$LIBS
7808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7809 /* end confdefs.h. */
7810
7811 /* Override any GCC internal prototype to avoid an error.
7812 Use char because int might match the return type of a GCC
7813 builtin and then its argument prototype would still apply. */
7814 #ifdef __cplusplus
7815 extern "C"
7816 #endif
7817 char socketpair ();
7818 int
7819 main ()
7820 {
7821 return socketpair ();
7822 ;
7823 return 0;
7824 }
7825 _ACEOF
7826 for ac_lib in '' socket; do
7827 if test -z "$ac_lib"; then
7828 ac_res="none required"
7829 else
7830 ac_res=-l$ac_lib
7831 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7832 fi
7833 if ac_fn_c_try_link "$LINENO"; then :
7834 ac_cv_search_socketpair=$ac_res
7835 fi
7836 rm -f core conftest.err conftest.$ac_objext \
7837 conftest$ac_exeext
7838 if ${ac_cv_search_socketpair+:} false; then :
7839 break
7840 fi
7841 done
7842 if ${ac_cv_search_socketpair+:} false; then :
7843
7844 else
7845 ac_cv_search_socketpair=no
7846 fi
7847 rm conftest.$ac_ext
7848 LIBS=$ac_func_search_save_LIBS
7849 fi
7850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
7851 $as_echo "$ac_cv_search_socketpair" >&6; }
7852 ac_res=$ac_cv_search_socketpair
7853 if test "$ac_res" != no; then :
7854 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7855
7856 fi
7857
7858
7859 # Link in zlib if we can. This allows us to read compressed debug sections.
7860
7861 # Use the system's zlib library.
7862 zlibdir="-L\$(top_builddir)/../zlib"
7863 zlibinc="-I\$(top_srcdir)/../zlib"
7864
7865 # Check whether --with-system-zlib was given.
7866 if test "${with_system_zlib+set}" = set; then :
7867 withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
7868 zlibdir=
7869 zlibinc=
7870 fi
7871
7872 fi
7873
7874
7875
7876
7877
7878 # On FreeBSD we may need libutil for kinfo_getvmmap (used by fbsd-nat.c).
7879 # On GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
7880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getvmmap" >&5
7881 $as_echo_n "checking for library containing kinfo_getvmmap... " >&6; }
7882 if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7883 $as_echo_n "(cached) " >&6
7884 else
7885 ac_func_search_save_LIBS=$LIBS
7886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7887 /* end confdefs.h. */
7888
7889 /* Override any GCC internal prototype to avoid an error.
7890 Use char because int might match the return type of a GCC
7891 builtin and then its argument prototype would still apply. */
7892 #ifdef __cplusplus
7893 extern "C"
7894 #endif
7895 char kinfo_getvmmap ();
7896 int
7897 main ()
7898 {
7899 return kinfo_getvmmap ();
7900 ;
7901 return 0;
7902 }
7903 _ACEOF
7904 for ac_lib in '' util util-freebsd; do
7905 if test -z "$ac_lib"; then
7906 ac_res="none required"
7907 else
7908 ac_res=-l$ac_lib
7909 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7910 fi
7911 if ac_fn_c_try_link "$LINENO"; then :
7912 ac_cv_search_kinfo_getvmmap=$ac_res
7913 fi
7914 rm -f core conftest.err conftest.$ac_objext \
7915 conftest$ac_exeext
7916 if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7917 break
7918 fi
7919 done
7920 if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7921
7922 else
7923 ac_cv_search_kinfo_getvmmap=no
7924 fi
7925 rm conftest.$ac_ext
7926 LIBS=$ac_func_search_save_LIBS
7927 fi
7928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getvmmap" >&5
7929 $as_echo "$ac_cv_search_kinfo_getvmmap" >&6; }
7930 ac_res=$ac_cv_search_kinfo_getvmmap
7931 if test "$ac_res" != no; then :
7932 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7933
7934 $as_echo "#define HAVE_KINFO_GETVMMAP 1" >>confdefs.h
7935
7936 fi
7937
7938
7939 # fbsd-nat.c can also use kinfo_getfile.
7940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
7941 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
7942 if ${ac_cv_search_kinfo_getfile+:} false; then :
7943 $as_echo_n "(cached) " >&6
7944 else
7945 ac_func_search_save_LIBS=$LIBS
7946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7947 /* end confdefs.h. */
7948
7949 /* Override any GCC internal prototype to avoid an error.
7950 Use char because int might match the return type of a GCC
7951 builtin and then its argument prototype would still apply. */
7952 #ifdef __cplusplus
7953 extern "C"
7954 #endif
7955 char kinfo_getfile ();
7956 int
7957 main ()
7958 {
7959 return kinfo_getfile ();
7960 ;
7961 return 0;
7962 }
7963 _ACEOF
7964 for ac_lib in '' util util-freebsd; do
7965 if test -z "$ac_lib"; then
7966 ac_res="none required"
7967 else
7968 ac_res=-l$ac_lib
7969 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7970 fi
7971 if ac_fn_c_try_link "$LINENO"; then :
7972 ac_cv_search_kinfo_getfile=$ac_res
7973 fi
7974 rm -f core conftest.err conftest.$ac_objext \
7975 conftest$ac_exeext
7976 if ${ac_cv_search_kinfo_getfile+:} false; then :
7977 break
7978 fi
7979 done
7980 if ${ac_cv_search_kinfo_getfile+:} false; then :
7981
7982 else
7983 ac_cv_search_kinfo_getfile=no
7984 fi
7985 rm conftest.$ac_ext
7986 LIBS=$ac_func_search_save_LIBS
7987 fi
7988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
7989 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
7990 ac_res=$ac_cv_search_kinfo_getfile
7991 if test "$ac_res" != no; then :
7992 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7993
7994 $as_echo "#define HAVE_KINFO_GETFILE 1" >>confdefs.h
7995
7996 fi
7997
7998
7999
8000 if test "X$prefix" = "XNONE"; then
8001 acl_final_prefix="$ac_default_prefix"
8002 else
8003 acl_final_prefix="$prefix"
8004 fi
8005 if test "X$exec_prefix" = "XNONE"; then
8006 acl_final_exec_prefix='${prefix}'
8007 else
8008 acl_final_exec_prefix="$exec_prefix"
8009 fi
8010 acl_save_prefix="$prefix"
8011 prefix="$acl_final_prefix"
8012 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8013 prefix="$acl_save_prefix"
8014
8015
8016 # Check whether --with-gnu-ld was given.
8017 if test "${with_gnu_ld+set}" = set; then :
8018 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8019 else
8020 with_gnu_ld=no
8021 fi
8022
8023 # Prepare PATH_SEPARATOR.
8024 # The user is always right.
8025 if test "${PATH_SEPARATOR+set}" != set; then
8026 echo "#! /bin/sh" >conf$$.sh
8027 echo "exit 0" >>conf$$.sh
8028 chmod +x conf$$.sh
8029 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
8030 PATH_SEPARATOR=';'
8031 else
8032 PATH_SEPARATOR=:
8033 fi
8034 rm -f conf$$.sh
8035 fi
8036 ac_prog=ld
8037 if test "$GCC" = yes; then
8038 # Check if gcc -print-prog-name=ld gives a path.
8039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8040 $as_echo_n "checking for ld used by GCC... " >&6; }
8041 case $host in
8042 *-*-mingw*)
8043 # gcc leaves a trailing carriage return which upsets mingw
8044 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8045 *)
8046 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8047 esac
8048 case $ac_prog in
8049 # Accept absolute paths.
8050 [\\/]* | [A-Za-z]:[\\/]*)
8051 re_direlt='/[^/][^/]*/\.\./'
8052 # Canonicalize the path of ld
8053 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8054 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8055 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8056 done
8057 test -z "$LD" && LD="$ac_prog"
8058 ;;
8059 "")
8060 # If it fails, then pretend we aren't using GCC.
8061 ac_prog=ld
8062 ;;
8063 *)
8064 # If it is relative, then search for the first ld in PATH.
8065 with_gnu_ld=unknown
8066 ;;
8067 esac
8068 elif test "$with_gnu_ld" = yes; then
8069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8070 $as_echo_n "checking for GNU ld... " >&6; }
8071 else
8072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8073 $as_echo_n "checking for non-GNU ld... " >&6; }
8074 fi
8075 if ${acl_cv_path_LD+:} false; then :
8076 $as_echo_n "(cached) " >&6
8077 else
8078 if test -z "$LD"; then
8079 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8080 for ac_dir in $PATH; do
8081 test -z "$ac_dir" && ac_dir=.
8082 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8083 acl_cv_path_LD="$ac_dir/$ac_prog"
8084 # Check to see if the program is GNU ld. I'd rather use --version,
8085 # but apparently some GNU ld's only accept -v.
8086 # Break only if it was the GNU/non-GNU ld that we prefer.
8087 if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8088 test "$with_gnu_ld" != no && break
8089 else
8090 test "$with_gnu_ld" != yes && break
8091 fi
8092 fi
8093 done
8094 IFS="$ac_save_ifs"
8095 else
8096 acl_cv_path_LD="$LD" # Let the user override the test with a path.
8097 fi
8098 fi
8099
8100 LD="$acl_cv_path_LD"
8101 if test -n "$LD"; then
8102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8103 $as_echo "$LD" >&6; }
8104 else
8105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8106 $as_echo "no" >&6; }
8107 fi
8108 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8110 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8111 if ${acl_cv_prog_gnu_ld+:} false; then :
8112 $as_echo_n "(cached) " >&6
8113 else
8114 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8115 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8116 acl_cv_prog_gnu_ld=yes
8117 else
8118 acl_cv_prog_gnu_ld=no
8119 fi
8120 fi
8121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8122 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
8123 with_gnu_ld=$acl_cv_prog_gnu_ld
8124
8125
8126
8127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8128 $as_echo_n "checking for shared library run path origin... " >&6; }
8129 if ${acl_cv_rpath+:} false; then :
8130 $as_echo_n "(cached) " >&6
8131 else
8132
8133 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8134 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8135 . ./conftest.sh
8136 rm -f ./conftest.sh
8137 acl_cv_rpath=done
8138
8139 fi
8140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8141 $as_echo "$acl_cv_rpath" >&6; }
8142 wl="$acl_cv_wl"
8143 libext="$acl_cv_libext"
8144 shlibext="$acl_cv_shlibext"
8145 hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8146 hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8147 hardcode_direct="$acl_cv_hardcode_direct"
8148 hardcode_minus_L="$acl_cv_hardcode_minus_L"
8149 # Check whether --enable-rpath was given.
8150 if test "${enable_rpath+set}" = set; then :
8151 enableval=$enable_rpath; :
8152 else
8153 enable_rpath=yes
8154 fi
8155
8156
8157
8158
8159
8160
8161
8162
8163 use_additional=yes
8164
8165 acl_save_prefix="$prefix"
8166 prefix="$acl_final_prefix"
8167 acl_save_exec_prefix="$exec_prefix"
8168 exec_prefix="$acl_final_exec_prefix"
8169
8170 eval additional_includedir=\"$includedir\"
8171 eval additional_libdir=\"$libdir\"
8172
8173 exec_prefix="$acl_save_exec_prefix"
8174 prefix="$acl_save_prefix"
8175
8176
8177 # Check whether --with-libiconv-prefix was given.
8178 if test "${with_libiconv_prefix+set}" = set; then :
8179 withval=$with_libiconv_prefix;
8180 if test "X$withval" = "Xno"; then
8181 use_additional=no
8182 else
8183 if test "X$withval" = "X"; then
8184
8185 acl_save_prefix="$prefix"
8186 prefix="$acl_final_prefix"
8187 acl_save_exec_prefix="$exec_prefix"
8188 exec_prefix="$acl_final_exec_prefix"
8189
8190 eval additional_includedir=\"$includedir\"
8191 eval additional_libdir=\"$libdir\"
8192
8193 exec_prefix="$acl_save_exec_prefix"
8194 prefix="$acl_save_prefix"
8195
8196 else
8197 additional_includedir="$withval/include"
8198 additional_libdir="$withval/lib"
8199 fi
8200 fi
8201
8202 fi
8203
8204 LIBICONV=
8205 LTLIBICONV=
8206 INCICONV=
8207 rpathdirs=
8208 ltrpathdirs=
8209 names_already_handled=
8210 names_next_round='iconv '
8211 while test -n "$names_next_round"; do
8212 names_this_round="$names_next_round"
8213 names_next_round=
8214 for name in $names_this_round; do
8215 already_handled=
8216 for n in $names_already_handled; do
8217 if test "$n" = "$name"; then
8218 already_handled=yes
8219 break
8220 fi
8221 done
8222 if test -z "$already_handled"; then
8223 names_already_handled="$names_already_handled $name"
8224 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
8225 eval value=\"\$HAVE_LIB$uppername\"
8226 if test -n "$value"; then
8227 if test "$value" = yes; then
8228 eval value=\"\$LIB$uppername\"
8229 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
8230 eval value=\"\$LTLIB$uppername\"
8231 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
8232 else
8233 :
8234 fi
8235 else
8236 found_dir=
8237 found_la=
8238 found_so=
8239 found_a=
8240 if test $use_additional = yes; then
8241 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
8242 found_dir="$additional_libdir"
8243 found_so="$additional_libdir/lib$name.$shlibext"
8244 if test -f "$additional_libdir/lib$name.la"; then
8245 found_la="$additional_libdir/lib$name.la"
8246 fi
8247 else
8248 if test -f "$additional_libdir/lib$name.$libext"; then
8249 found_dir="$additional_libdir"
8250 found_a="$additional_libdir/lib$name.$libext"
8251 if test -f "$additional_libdir/lib$name.la"; then
8252 found_la="$additional_libdir/lib$name.la"
8253 fi
8254 fi
8255 fi
8256 fi
8257 if test "X$found_dir" = "X"; then
8258 for x in $LDFLAGS $LTLIBICONV; do
8259
8260 acl_save_prefix="$prefix"
8261 prefix="$acl_final_prefix"
8262 acl_save_exec_prefix="$exec_prefix"
8263 exec_prefix="$acl_final_exec_prefix"
8264 eval x=\"$x\"
8265 exec_prefix="$acl_save_exec_prefix"
8266 prefix="$acl_save_prefix"
8267
8268 case "$x" in
8269 -L*)
8270 dir=`echo "X$x" | sed -e 's/^X-L//'`
8271 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
8272 found_dir="$dir"
8273 found_so="$dir/lib$name.$shlibext"
8274 if test -f "$dir/lib$name.la"; then
8275 found_la="$dir/lib$name.la"
8276 fi
8277 else
8278 if test -f "$dir/lib$name.$libext"; then
8279 found_dir="$dir"
8280 found_a="$dir/lib$name.$libext"
8281 if test -f "$dir/lib$name.la"; then
8282 found_la="$dir/lib$name.la"
8283 fi
8284 fi
8285 fi
8286 ;;
8287 esac
8288 if test "X$found_dir" != "X"; then
8289 break
8290 fi
8291 done
8292 fi
8293 if test "X$found_dir" != "X"; then
8294 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
8295 if test "X$found_so" != "X"; then
8296 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
8297 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8298 else
8299 haveit=
8300 for x in $ltrpathdirs; do
8301 if test "X$x" = "X$found_dir"; then
8302 haveit=yes
8303 break
8304 fi
8305 done
8306 if test -z "$haveit"; then
8307 ltrpathdirs="$ltrpathdirs $found_dir"
8308 fi
8309 if test "$hardcode_direct" = yes; then
8310 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8311 else
8312 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
8313 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8314 haveit=
8315 for x in $rpathdirs; do
8316 if test "X$x" = "X$found_dir"; then
8317 haveit=yes
8318 break
8319 fi
8320 done
8321 if test -z "$haveit"; then
8322 rpathdirs="$rpathdirs $found_dir"
8323 fi
8324 else
8325 haveit=
8326 for x in $LDFLAGS $LIBICONV; do
8327
8328 acl_save_prefix="$prefix"
8329 prefix="$acl_final_prefix"
8330 acl_save_exec_prefix="$exec_prefix"
8331 exec_prefix="$acl_final_exec_prefix"
8332 eval x=\"$x\"
8333 exec_prefix="$acl_save_exec_prefix"
8334 prefix="$acl_save_prefix"
8335
8336 if test "X$x" = "X-L$found_dir"; then
8337 haveit=yes
8338 break
8339 fi
8340 done
8341 if test -z "$haveit"; then
8342 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
8343 fi
8344 if test "$hardcode_minus_L" != no; then
8345 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8346 else
8347 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8348 fi
8349 fi
8350 fi
8351 fi
8352 else
8353 if test "X$found_a" != "X"; then
8354 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
8355 else
8356 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
8357 fi
8358 fi
8359 additional_includedir=
8360 case "$found_dir" in
8361 */lib | */lib/)
8362 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
8363 additional_includedir="$basedir/include"
8364 ;;
8365 esac
8366 if test "X$additional_includedir" != "X"; then
8367 if test "X$additional_includedir" != "X/usr/include"; then
8368 haveit=
8369 if test "X$additional_includedir" = "X/usr/local/include"; then
8370 if test -n "$GCC"; then
8371 case $host_os in
8372 linux*) haveit=yes;;
8373 esac
8374 fi
8375 fi
8376 if test -z "$haveit"; then
8377 for x in $CPPFLAGS $INCICONV; do
8378
8379 acl_save_prefix="$prefix"
8380 prefix="$acl_final_prefix"
8381 acl_save_exec_prefix="$exec_prefix"
8382 exec_prefix="$acl_final_exec_prefix"
8383 eval x=\"$x\"
8384 exec_prefix="$acl_save_exec_prefix"
8385 prefix="$acl_save_prefix"
8386
8387 if test "X$x" = "X-I$additional_includedir"; then
8388 haveit=yes
8389 break
8390 fi
8391 done
8392 if test -z "$haveit"; then
8393 if test -d "$additional_includedir"; then
8394 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
8395 fi
8396 fi
8397 fi
8398 fi
8399 fi
8400 if test -n "$found_la"; then
8401 save_libdir="$libdir"
8402 case "$found_la" in
8403 */* | *\\*) . "$found_la" ;;
8404 *) . "./$found_la" ;;
8405 esac
8406 libdir="$save_libdir"
8407 for dep in $dependency_libs; do
8408 case "$dep" in
8409 -L*)
8410 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
8411 if test "X$additional_libdir" != "X/usr/lib"; then
8412 haveit=
8413 if test "X$additional_libdir" = "X/usr/local/lib"; then
8414 if test -n "$GCC"; then
8415 case $host_os in
8416 linux*) haveit=yes;;
8417 esac
8418 fi
8419 fi
8420 if test -z "$haveit"; then
8421 haveit=
8422 for x in $LDFLAGS $LIBICONV; do
8423
8424 acl_save_prefix="$prefix"
8425 prefix="$acl_final_prefix"
8426 acl_save_exec_prefix="$exec_prefix"
8427 exec_prefix="$acl_final_exec_prefix"
8428 eval x=\"$x\"
8429 exec_prefix="$acl_save_exec_prefix"
8430 prefix="$acl_save_prefix"
8431
8432 if test "X$x" = "X-L$additional_libdir"; then
8433 haveit=yes
8434 break
8435 fi
8436 done
8437 if test -z "$haveit"; then
8438 if test -d "$additional_libdir"; then
8439 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
8440 fi
8441 fi
8442 haveit=
8443 for x in $LDFLAGS $LTLIBICONV; do
8444
8445 acl_save_prefix="$prefix"
8446 prefix="$acl_final_prefix"
8447 acl_save_exec_prefix="$exec_prefix"
8448 exec_prefix="$acl_final_exec_prefix"
8449 eval x=\"$x\"
8450 exec_prefix="$acl_save_exec_prefix"
8451 prefix="$acl_save_prefix"
8452
8453 if test "X$x" = "X-L$additional_libdir"; then
8454 haveit=yes
8455 break
8456 fi
8457 done
8458 if test -z "$haveit"; then
8459 if test -d "$additional_libdir"; then
8460 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
8461 fi
8462 fi
8463 fi
8464 fi
8465 ;;
8466 -R*)
8467 dir=`echo "X$dep" | sed -e 's/^X-R//'`
8468 if test "$enable_rpath" != no; then
8469 haveit=
8470 for x in $rpathdirs; do
8471 if test "X$x" = "X$dir"; then
8472 haveit=yes
8473 break
8474 fi
8475 done
8476 if test -z "$haveit"; then
8477 rpathdirs="$rpathdirs $dir"
8478 fi
8479 haveit=
8480 for x in $ltrpathdirs; do
8481 if test "X$x" = "X$dir"; then
8482 haveit=yes
8483 break
8484 fi
8485 done
8486 if test -z "$haveit"; then
8487 ltrpathdirs="$ltrpathdirs $dir"
8488 fi
8489 fi
8490 ;;
8491 -l*)
8492 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
8493 ;;
8494 *.la)
8495 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
8496 ;;
8497 *)
8498 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
8499 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
8500 ;;
8501 esac
8502 done
8503 fi
8504 else
8505 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8506 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
8507 fi
8508 fi
8509 fi
8510 done
8511 done
8512 if test "X$rpathdirs" != "X"; then
8513 if test -n "$hardcode_libdir_separator"; then
8514 alldirs=
8515 for found_dir in $rpathdirs; do
8516 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
8517 done
8518 acl_save_libdir="$libdir"
8519 libdir="$alldirs"
8520 eval flag=\"$hardcode_libdir_flag_spec\"
8521 libdir="$acl_save_libdir"
8522 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8523 else
8524 for found_dir in $rpathdirs; do
8525 acl_save_libdir="$libdir"
8526 libdir="$found_dir"
8527 eval flag=\"$hardcode_libdir_flag_spec\"
8528 libdir="$acl_save_libdir"
8529 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8530 done
8531 fi
8532 fi
8533 if test "X$ltrpathdirs" != "X"; then
8534 for found_dir in $ltrpathdirs; do
8535 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
8536 done
8537 fi
8538
8539
8540
8541
8542
8543
8544
8545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
8546 $as_echo_n "checking for iconv... " >&6; }
8547 if ${am_cv_func_iconv+:} false; then :
8548 $as_echo_n "(cached) " >&6
8549 else
8550
8551 am_cv_func_iconv="no, consider installing GNU libiconv"
8552 am_cv_lib_iconv=no
8553 am_save_CPPFLAGS="$CPPFLAGS"
8554 CPPFLAGS="$CPPFLAGS $INCICONV"
8555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8556 /* end confdefs.h. */
8557 #include <stdlib.h>
8558 #include <iconv.h>
8559 int
8560 main ()
8561 {
8562 iconv_t cd = iconv_open("","");
8563 iconv(cd,NULL,NULL,NULL,NULL);
8564 iconv_close(cd);
8565 ;
8566 return 0;
8567 }
8568 _ACEOF
8569 if ac_fn_c_try_link "$LINENO"; then :
8570 am_cv_func_iconv=yes
8571 fi
8572 rm -f core conftest.err conftest.$ac_objext \
8573 conftest$ac_exeext conftest.$ac_ext
8574 CPPFLAGS="$am_save_CPPFLAGS"
8575
8576 if test "$am_cv_func_iconv" != yes && test -d ../libiconv; then
8577 for _libs in .libs _libs; do
8578 am_save_CPPFLAGS="$CPPFLAGS"
8579 am_save_LIBS="$LIBS"
8580 CPPFLAGS="$CPPFLAGS -I../libiconv/include"
8581 LIBS="$LIBS ../libiconv/lib/$_libs/libiconv.a"
8582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8583 /* end confdefs.h. */
8584 #include <stdlib.h>
8585 #include <iconv.h>
8586 int
8587 main ()
8588 {
8589 iconv_t cd = iconv_open("","");
8590 iconv(cd,NULL,NULL,NULL,NULL);
8591 iconv_close(cd);
8592 ;
8593 return 0;
8594 }
8595 _ACEOF
8596 if ac_fn_c_try_link "$LINENO"; then :
8597 INCICONV="-I../libiconv/include"
8598 LIBICONV='${top_builddir}'/../libiconv/lib/$_libs/libiconv.a
8599 LTLIBICONV='${top_builddir}'/../libiconv/lib/libiconv.la
8600 am_cv_lib_iconv=yes
8601 am_cv_func_iconv=yes
8602 fi
8603 rm -f core conftest.err conftest.$ac_objext \
8604 conftest$ac_exeext conftest.$ac_ext
8605 CPPFLAGS="$am_save_CPPFLAGS"
8606 LIBS="$am_save_LIBS"
8607 if test "$am_cv_func_iconv" = "yes"; then
8608 break
8609 fi
8610 done
8611 fi
8612
8613 if test "$am_cv_func_iconv" != yes; then
8614 am_save_CPPFLAGS="$CPPFLAGS"
8615 am_save_LIBS="$LIBS"
8616 CPPFLAGS="$CPPFLAGS $INCICONV"
8617 LIBS="$LIBS $LIBICONV"
8618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8619 /* end confdefs.h. */
8620 #include <stdlib.h>
8621 #include <iconv.h>
8622 int
8623 main ()
8624 {
8625 iconv_t cd = iconv_open("","");
8626 iconv(cd,NULL,NULL,NULL,NULL);
8627 iconv_close(cd);
8628 ;
8629 return 0;
8630 }
8631 _ACEOF
8632 if ac_fn_c_try_link "$LINENO"; then :
8633 am_cv_lib_iconv=yes
8634 am_cv_func_iconv=yes
8635 fi
8636 rm -f core conftest.err conftest.$ac_objext \
8637 conftest$ac_exeext conftest.$ac_ext
8638 CPPFLAGS="$am_save_CPPFLAGS"
8639 LIBS="$am_save_LIBS"
8640 fi
8641
8642 fi
8643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
8644 $as_echo "$am_cv_func_iconv" >&6; }
8645 if test "$am_cv_func_iconv" = yes; then
8646
8647 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
8648
8649 fi
8650 if test "$am_cv_lib_iconv" = yes; then
8651
8652 for element in $INCICONV; do
8653 haveit=
8654 for x in $CPPFLAGS; do
8655
8656 acl_save_prefix="$prefix"
8657 prefix="$acl_final_prefix"
8658 acl_save_exec_prefix="$exec_prefix"
8659 exec_prefix="$acl_final_exec_prefix"
8660 eval x=\"$x\"
8661 exec_prefix="$acl_save_exec_prefix"
8662 prefix="$acl_save_prefix"
8663
8664 if test "X$x" = "X$element"; then
8665 haveit=yes
8666 break
8667 fi
8668 done
8669 if test -z "$haveit"; then
8670 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
8671 fi
8672 done
8673
8674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
8675 $as_echo_n "checking how to link with libiconv... " >&6; }
8676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
8677 $as_echo "$LIBICONV" >&6; }
8678 else
8679 LIBICONV=
8680 LTLIBICONV=
8681 fi
8682
8683
8684
8685 if test "$am_cv_func_iconv" = yes; then
8686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
8687 $as_echo_n "checking for iconv declaration... " >&6; }
8688 if ${am_cv_proto_iconv+:} false; then :
8689 $as_echo_n "(cached) " >&6
8690 else
8691
8692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8693 /* end confdefs.h. */
8694
8695 #include <stdlib.h>
8696 #include <iconv.h>
8697 extern
8698 #ifdef __cplusplus
8699 "C"
8700 #endif
8701 #if defined(__STDC__) || defined(__cplusplus)
8702 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
8703 #else
8704 size_t iconv();
8705 #endif
8706
8707 int
8708 main ()
8709 {
8710
8711 ;
8712 return 0;
8713 }
8714 _ACEOF
8715 if ac_fn_c_try_compile "$LINENO"; then :
8716 am_cv_proto_iconv_arg1=""
8717 else
8718 am_cv_proto_iconv_arg1="const"
8719 fi
8720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8721 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);"
8722 fi
8723
8724 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
8725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
8726 }$am_cv_proto_iconv" >&5
8727 $as_echo "${ac_t:-
8728 }$am_cv_proto_iconv" >&6; }
8729
8730 cat >>confdefs.h <<_ACEOF
8731 #define ICONV_CONST $am_cv_proto_iconv_arg1
8732 _ACEOF
8733
8734 fi
8735
8736
8737 # GDB may fork/exec the iconv program to get the list of supported character
8738 # sets. Allow the user to specify where to find it.
8739 # There are several factors affecting the choice of option name:
8740 # - There is already --with-libiconv-prefix but we can't use it, it specifies
8741 # the build-time location of libiconv files.
8742 # - The program we need to find is iconv, which comes with glibc. The user
8743 # doesn't necessarily have libiconv installed. Therefore naming this
8744 # --with-libiconv-foo feels wrong.
8745 # - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
8746 # defined to work on directories not files (though it really doesn't know
8747 # the difference).
8748 # - Calling this --with-iconv-prefix is perceived to cause too much confusion
8749 # with --with-libiconv-prefix.
8750 # Putting these together is why the option name is --with-iconv-bin.
8751
8752
8753 # Check whether --with-iconv-bin was given.
8754 if test "${with_iconv_bin+set}" = set; then :
8755 withval=$with_iconv_bin; iconv_bin="${withval}"
8756
8757 cat >>confdefs.h <<_ACEOF
8758 #define ICONV_BIN "${iconv_bin}"
8759 _ACEOF
8760
8761
8762 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
8763 if test "x$prefix" = xNONE; then
8764 test_prefix=/usr/local
8765 else
8766 test_prefix=$prefix
8767 fi
8768 else
8769 test_prefix=$exec_prefix
8770 fi
8771 value=0
8772 case ${iconv_bin} in
8773 "${test_prefix}"|"${test_prefix}/"*|\
8774 '${exec_prefix}'|'${exec_prefix}/'*)
8775 value=1
8776 ;;
8777 esac
8778
8779 cat >>confdefs.h <<_ACEOF
8780 #define ICONV_BIN_RELOCATABLE $value
8781 _ACEOF
8782
8783
8784
8785 fi
8786
8787
8788 # For the TUI, we need enhanced curses functionality.
8789 if test x"$enable_tui" != xno; then
8790 prefer_curses=yes
8791 fi
8792
8793 curses_found=no
8794 if test x"$prefer_curses" = xyes; then
8795 # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
8796 # curses library because the latter might not provide all the
8797 # functionality we need. However, this leads to problems on systems
8798 # where the linker searches /usr/local/lib, but the compiler doesn't
8799 # search /usr/local/include, if ncurses is installed in /usr/local. A
8800 # default installation of ncurses on alpha*-dec-osf* will lead to such
8801 # a situation.
8802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
8803 $as_echo_n "checking for library containing waddstr... " >&6; }
8804 if ${ac_cv_search_waddstr+:} false; then :
8805 $as_echo_n "(cached) " >&6
8806 else
8807 ac_func_search_save_LIBS=$LIBS
8808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8809 /* end confdefs.h. */
8810
8811 /* Override any GCC internal prototype to avoid an error.
8812 Use char because int might match the return type of a GCC
8813 builtin and then its argument prototype would still apply. */
8814 #ifdef __cplusplus
8815 extern "C"
8816 #endif
8817 char waddstr ();
8818 int
8819 main ()
8820 {
8821 return waddstr ();
8822 ;
8823 return 0;
8824 }
8825 _ACEOF
8826 for ac_lib in '' ncursesw ncurses cursesX curses; do
8827 if test -z "$ac_lib"; then
8828 ac_res="none required"
8829 else
8830 ac_res=-l$ac_lib
8831 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8832 fi
8833 if ac_fn_c_try_link "$LINENO"; then :
8834 ac_cv_search_waddstr=$ac_res
8835 fi
8836 rm -f core conftest.err conftest.$ac_objext \
8837 conftest$ac_exeext
8838 if ${ac_cv_search_waddstr+:} false; then :
8839 break
8840 fi
8841 done
8842 if ${ac_cv_search_waddstr+:} false; then :
8843
8844 else
8845 ac_cv_search_waddstr=no
8846 fi
8847 rm conftest.$ac_ext
8848 LIBS=$ac_func_search_save_LIBS
8849 fi
8850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
8851 $as_echo "$ac_cv_search_waddstr" >&6; }
8852 ac_res=$ac_cv_search_waddstr
8853 if test "$ac_res" != no; then :
8854 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8855
8856 fi
8857
8858
8859 if test "$ac_cv_search_waddstr" != no; then
8860 curses_found=yes
8861 fi
8862 fi
8863
8864 # Check whether we should enable the TUI, but only do so if we really
8865 # can.
8866 if test x"$enable_tui" != xno; then
8867 if test -d $srcdir/tui; then
8868 if test "$curses_found" != no; then
8869 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
8870 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
8871 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
8872 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
8873 else
8874 if test x"$enable_tui" = xyes; then
8875 as_fn_error $? "no enhanced curses library found; disable TUI" "$LINENO" 5
8876 else
8877 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
8878 $as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
8879 fi
8880 fi
8881 fi
8882 fi
8883
8884 # Since GDB uses Readline, we need termcap functionality. In many
8885 # cases this will be provided by the curses library, but some systems
8886 # have a separate termcap library, or no curses library at all.
8887
8888 case $host_os in
8889 cygwin*)
8890 if test -d $srcdir/libtermcap; then
8891 LIBS="../libtermcap/libtermcap.a $LIBS"
8892 ac_cv_search_tgetent="../libtermcap/libtermcap.a"
8893 fi ;;
8894 go32* | *djgpp*)
8895 ac_cv_search_tgetent="none required"
8896 ;;
8897 esac
8898
8899 # These are the libraries checked by Readline.
8900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
8901 $as_echo_n "checking for library containing tgetent... " >&6; }
8902 if ${ac_cv_search_tgetent+:} false; then :
8903 $as_echo_n "(cached) " >&6
8904 else
8905 ac_func_search_save_LIBS=$LIBS
8906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8907 /* end confdefs.h. */
8908
8909 /* Override any GCC internal prototype to avoid an error.
8910 Use char because int might match the return type of a GCC
8911 builtin and then its argument prototype would still apply. */
8912 #ifdef __cplusplus
8913 extern "C"
8914 #endif
8915 char tgetent ();
8916 int
8917 main ()
8918 {
8919 return tgetent ();
8920 ;
8921 return 0;
8922 }
8923 _ACEOF
8924 for ac_lib in '' termcap tinfow tinfo curses ncursesw ncurses; do
8925 if test -z "$ac_lib"; then
8926 ac_res="none required"
8927 else
8928 ac_res=-l$ac_lib
8929 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
8930 fi
8931 if ac_fn_c_try_link "$LINENO"; then :
8932 ac_cv_search_tgetent=$ac_res
8933 fi
8934 rm -f core conftest.err conftest.$ac_objext \
8935 conftest$ac_exeext
8936 if ${ac_cv_search_tgetent+:} false; then :
8937 break
8938 fi
8939 done
8940 if ${ac_cv_search_tgetent+:} false; then :
8941
8942 else
8943 ac_cv_search_tgetent=no
8944 fi
8945 rm conftest.$ac_ext
8946 LIBS=$ac_func_search_save_LIBS
8947 fi
8948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
8949 $as_echo "$ac_cv_search_tgetent" >&6; }
8950 ac_res=$ac_cv_search_tgetent
8951 if test "$ac_res" != no; then :
8952 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8953
8954 fi
8955
8956
8957 if test "$ac_cv_search_tgetent" = no; then
8958 CONFIG_OBS="$CONFIG_OBS stub-termcap.o"
8959 fi
8960
8961
8962 # Check whether --with-system-readline was given.
8963 if test "${with_system_readline+set}" = set; then :
8964 withval=$with_system_readline;
8965 fi
8966
8967
8968 if test "$with_system_readline" = yes; then
8969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system readline is new enough" >&5
8970 $as_echo_n "checking whether system readline is new enough... " >&6; }
8971 if ${gdb_cv_readline_ok+:} false; then :
8972 $as_echo_n "(cached) " >&6
8973 else
8974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8975 /* end confdefs.h. */
8976 #include <stdio.h>
8977 #include <readline/readline.h>
8978 int
8979 main ()
8980 {
8981 #if RL_VERSION_MAJOR < 7
8982 # error "readline version 7 required"
8983 #endif
8984 ;
8985 return 0;
8986 }
8987 _ACEOF
8988 if ac_fn_c_try_compile "$LINENO"; then :
8989 gdb_cv_readline_ok=yes
8990 else
8991 gdb_cv_readline_ok=no
8992 fi
8993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8994 fi
8995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_readline_ok" >&5
8996 $as_echo "$gdb_cv_readline_ok" >&6; }
8997 if test "$gdb_cv_readline_ok" != yes; then
8998 as_fn_error $? "system readline is not new enough" "$LINENO" 5
8999 fi
9000
9001 READLINE=-lreadline
9002 READLINE_DEPS=
9003 READLINE_CFLAGS=
9004 READLINE_TEXI_INCFLAG=
9005 else
9006 READLINE='$(READLINE_DIR)/libreadline.a'
9007 READLINE_DEPS='$(READLINE)'
9008 READLINE_CFLAGS='-I$(READLINE_SRC)/..'
9009 READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
9010 fi
9011
9012
9013
9014
9015
9016 # Generate jit-reader.h
9017
9018 # This is typedeffed to GDB_CORE_ADDR in jit-reader.h
9019 TARGET_PTR=
9020
9021 # The cast to long int works around a bug in the HP C Compiler
9022 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9023 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9024 # This bug is HP SR number 8606223364.
9025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
9026 $as_echo_n "checking size of unsigned long long... " >&6; }
9027 if ${ac_cv_sizeof_unsigned_long_long+:} false; then :
9028 $as_echo_n "(cached) " >&6
9029 else
9030 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long" "$ac_includes_default"; then :
9031
9032 else
9033 if test "$ac_cv_type_unsigned_long_long" = yes; then
9034 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9035 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9036 as_fn_error 77 "cannot compute sizeof (unsigned long long)
9037 See \`config.log' for more details" "$LINENO" 5; }
9038 else
9039 ac_cv_sizeof_unsigned_long_long=0
9040 fi
9041 fi
9042
9043 fi
9044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
9045 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
9046
9047
9048
9049 cat >>confdefs.h <<_ACEOF
9050 #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
9051 _ACEOF
9052
9053
9054 # The cast to long int works around a bug in the HP C Compiler
9055 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9056 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9057 # This bug is HP SR number 8606223364.
9058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
9059 $as_echo_n "checking size of unsigned long... " >&6; }
9060 if ${ac_cv_sizeof_unsigned_long+:} false; then :
9061 $as_echo_n "(cached) " >&6
9062 else
9063 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long" "$ac_includes_default"; then :
9064
9065 else
9066 if test "$ac_cv_type_unsigned_long" = yes; then
9067 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9068 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9069 as_fn_error 77 "cannot compute sizeof (unsigned long)
9070 See \`config.log' for more details" "$LINENO" 5; }
9071 else
9072 ac_cv_sizeof_unsigned_long=0
9073 fi
9074 fi
9075
9076 fi
9077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
9078 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
9079
9080
9081
9082 cat >>confdefs.h <<_ACEOF
9083 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
9084 _ACEOF
9085
9086
9087 # The cast to long int works around a bug in the HP C Compiler
9088 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9089 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9090 # This bug is HP SR number 8606223364.
9091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
9092 $as_echo_n "checking size of unsigned __int128... " >&6; }
9093 if ${ac_cv_sizeof_unsigned___int128+:} false; then :
9094 $as_echo_n "(cached) " >&6
9095 else
9096 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128" "$ac_includes_default"; then :
9097
9098 else
9099 if test "$ac_cv_type_unsigned___int128" = yes; then
9100 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9101 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9102 as_fn_error 77 "cannot compute sizeof (unsigned __int128)
9103 See \`config.log' for more details" "$LINENO" 5; }
9104 else
9105 ac_cv_sizeof_unsigned___int128=0
9106 fi
9107 fi
9108
9109 fi
9110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
9111 $as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
9112
9113
9114
9115 cat >>confdefs.h <<_ACEOF
9116 #define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
9117 _ACEOF
9118
9119
9120
9121 if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
9122 TARGET_PTR="unsigned long"
9123 elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
9124 TARGET_PTR="unsigned long long"
9125 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
9126 TARGET_PTR="unsigned __int128"
9127 else
9128 TARGET_PTR="unsigned long"
9129 fi
9130
9131
9132 ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
9133
9134
9135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
9136 $as_echo_n "checking for library containing dlopen... " >&6; }
9137 if ${ac_cv_search_dlopen+:} false; then :
9138 $as_echo_n "(cached) " >&6
9139 else
9140 ac_func_search_save_LIBS=$LIBS
9141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9142 /* end confdefs.h. */
9143
9144 /* Override any GCC internal prototype to avoid an error.
9145 Use char because int might match the return type of a GCC
9146 builtin and then its argument prototype would still apply. */
9147 #ifdef __cplusplus
9148 extern "C"
9149 #endif
9150 char dlopen ();
9151 int
9152 main ()
9153 {
9154 return dlopen ();
9155 ;
9156 return 0;
9157 }
9158 _ACEOF
9159 for ac_lib in '' dl; do
9160 if test -z "$ac_lib"; then
9161 ac_res="none required"
9162 else
9163 ac_res=-l$ac_lib
9164 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9165 fi
9166 if ac_fn_c_try_link "$LINENO"; then :
9167 ac_cv_search_dlopen=$ac_res
9168 fi
9169 rm -f core conftest.err conftest.$ac_objext \
9170 conftest$ac_exeext
9171 if ${ac_cv_search_dlopen+:} false; then :
9172 break
9173 fi
9174 done
9175 if ${ac_cv_search_dlopen+:} false; then :
9176
9177 else
9178 ac_cv_search_dlopen=no
9179 fi
9180 rm conftest.$ac_ext
9181 LIBS=$ac_func_search_save_LIBS
9182 fi
9183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
9184 $as_echo "$ac_cv_search_dlopen" >&6; }
9185 ac_res=$ac_cv_search_dlopen
9186 if test "$ac_res" != no; then :
9187 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9188
9189 fi
9190
9191
9192
9193
9194 # Check whether --with-jit-reader-dir was given.
9195 if test "${with_jit_reader_dir+set}" = set; then :
9196 withval=$with_jit_reader_dir;
9197 JIT_READER_DIR=$withval
9198 else
9199 JIT_READER_DIR=${libdir}/gdb
9200 fi
9201
9202
9203 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
9204 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9205 ac_define_dir=`eval echo $JIT_READER_DIR`
9206 ac_define_dir=`eval echo $ac_define_dir`
9207
9208 cat >>confdefs.h <<_ACEOF
9209 #define JIT_READER_DIR "$ac_define_dir"
9210 _ACEOF
9211
9212
9213
9214
9215 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
9216 if test "x$prefix" = xNONE; then
9217 test_prefix=/usr/local
9218 else
9219 test_prefix=$prefix
9220 fi
9221 else
9222 test_prefix=$exec_prefix
9223 fi
9224 value=0
9225 case ${ac_define_dir} in
9226 "${test_prefix}"|"${test_prefix}/"*|\
9227 '${exec_prefix}'|'${exec_prefix}/'*)
9228 value=1
9229 ;;
9230 esac
9231
9232 cat >>confdefs.h <<_ACEOF
9233 #define JIT_READER_DIR_RELOCATABLE $value
9234 _ACEOF
9235
9236
9237
9238
9239
9240 # Check whether --with-expat was given.
9241 if test "${with_expat+set}" = set; then :
9242 withval=$with_expat;
9243 else
9244 with_expat=auto
9245 fi
9246
9247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
9248 $as_echo_n "checking whether to use expat... " >&6; }
9249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
9250 $as_echo "$with_expat" >&6; }
9251
9252 if test "${with_expat}" = no; then
9253 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
9254 $as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
9255 HAVE_LIBEXPAT=no
9256 else
9257
9258
9259
9260
9261
9262
9263
9264
9265 use_additional=yes
9266
9267 acl_save_prefix="$prefix"
9268 prefix="$acl_final_prefix"
9269 acl_save_exec_prefix="$exec_prefix"
9270 exec_prefix="$acl_final_exec_prefix"
9271
9272 eval additional_includedir=\"$includedir\"
9273 eval additional_libdir=\"$libdir\"
9274
9275 exec_prefix="$acl_save_exec_prefix"
9276 prefix="$acl_save_prefix"
9277
9278
9279 # Check whether --with-libexpat-prefix was given.
9280 if test "${with_libexpat_prefix+set}" = set; then :
9281 withval=$with_libexpat_prefix;
9282 if test "X$withval" = "Xno"; then
9283 use_additional=no
9284 else
9285 if test "X$withval" = "X"; then
9286
9287 acl_save_prefix="$prefix"
9288 prefix="$acl_final_prefix"
9289 acl_save_exec_prefix="$exec_prefix"
9290 exec_prefix="$acl_final_exec_prefix"
9291
9292 eval additional_includedir=\"$includedir\"
9293 eval additional_libdir=\"$libdir\"
9294
9295 exec_prefix="$acl_save_exec_prefix"
9296 prefix="$acl_save_prefix"
9297
9298 else
9299 additional_includedir="$withval/include"
9300 additional_libdir="$withval/lib"
9301 fi
9302 fi
9303
9304 fi
9305
9306 LIBEXPAT=
9307 LTLIBEXPAT=
9308 INCEXPAT=
9309 rpathdirs=
9310 ltrpathdirs=
9311 names_already_handled=
9312 names_next_round='expat '
9313 while test -n "$names_next_round"; do
9314 names_this_round="$names_next_round"
9315 names_next_round=
9316 for name in $names_this_round; do
9317 already_handled=
9318 for n in $names_already_handled; do
9319 if test "$n" = "$name"; then
9320 already_handled=yes
9321 break
9322 fi
9323 done
9324 if test -z "$already_handled"; then
9325 names_already_handled="$names_already_handled $name"
9326 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9327 eval value=\"\$HAVE_LIB$uppername\"
9328 if test -n "$value"; then
9329 if test "$value" = yes; then
9330 eval value=\"\$LIB$uppername\"
9331 test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
9332 eval value=\"\$LTLIB$uppername\"
9333 test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
9334 else
9335 :
9336 fi
9337 else
9338 found_dir=
9339 found_la=
9340 found_so=
9341 found_a=
9342 if test $use_additional = yes; then
9343 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
9344 found_dir="$additional_libdir"
9345 found_so="$additional_libdir/lib$name.$shlibext"
9346 if test -f "$additional_libdir/lib$name.la"; then
9347 found_la="$additional_libdir/lib$name.la"
9348 fi
9349 else
9350 if test -f "$additional_libdir/lib$name.$libext"; then
9351 found_dir="$additional_libdir"
9352 found_a="$additional_libdir/lib$name.$libext"
9353 if test -f "$additional_libdir/lib$name.la"; then
9354 found_la="$additional_libdir/lib$name.la"
9355 fi
9356 fi
9357 fi
9358 fi
9359 if test "X$found_dir" = "X"; then
9360 for x in $LDFLAGS $LTLIBEXPAT; do
9361
9362 acl_save_prefix="$prefix"
9363 prefix="$acl_final_prefix"
9364 acl_save_exec_prefix="$exec_prefix"
9365 exec_prefix="$acl_final_exec_prefix"
9366 eval x=\"$x\"
9367 exec_prefix="$acl_save_exec_prefix"
9368 prefix="$acl_save_prefix"
9369
9370 case "$x" in
9371 -L*)
9372 dir=`echo "X$x" | sed -e 's/^X-L//'`
9373 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
9374 found_dir="$dir"
9375 found_so="$dir/lib$name.$shlibext"
9376 if test -f "$dir/lib$name.la"; then
9377 found_la="$dir/lib$name.la"
9378 fi
9379 else
9380 if test -f "$dir/lib$name.$libext"; then
9381 found_dir="$dir"
9382 found_a="$dir/lib$name.$libext"
9383 if test -f "$dir/lib$name.la"; then
9384 found_la="$dir/lib$name.la"
9385 fi
9386 fi
9387 fi
9388 ;;
9389 esac
9390 if test "X$found_dir" != "X"; then
9391 break
9392 fi
9393 done
9394 fi
9395 if test "X$found_dir" != "X"; then
9396 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
9397 if test "X$found_so" != "X"; then
9398 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9399 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9400 else
9401 haveit=
9402 for x in $ltrpathdirs; do
9403 if test "X$x" = "X$found_dir"; then
9404 haveit=yes
9405 break
9406 fi
9407 done
9408 if test -z "$haveit"; then
9409 ltrpathdirs="$ltrpathdirs $found_dir"
9410 fi
9411 if test "$hardcode_direct" = yes; then
9412 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9413 else
9414 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9415 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9416 haveit=
9417 for x in $rpathdirs; do
9418 if test "X$x" = "X$found_dir"; then
9419 haveit=yes
9420 break
9421 fi
9422 done
9423 if test -z "$haveit"; then
9424 rpathdirs="$rpathdirs $found_dir"
9425 fi
9426 else
9427 haveit=
9428 for x in $LDFLAGS $LIBEXPAT; do
9429
9430 acl_save_prefix="$prefix"
9431 prefix="$acl_final_prefix"
9432 acl_save_exec_prefix="$exec_prefix"
9433 exec_prefix="$acl_final_exec_prefix"
9434 eval x=\"$x\"
9435 exec_prefix="$acl_save_exec_prefix"
9436 prefix="$acl_save_prefix"
9437
9438 if test "X$x" = "X-L$found_dir"; then
9439 haveit=yes
9440 break
9441 fi
9442 done
9443 if test -z "$haveit"; then
9444 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
9445 fi
9446 if test "$hardcode_minus_L" != no; then
9447 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9448 else
9449 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9450 fi
9451 fi
9452 fi
9453 fi
9454 else
9455 if test "X$found_a" != "X"; then
9456 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
9457 else
9458 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
9459 fi
9460 fi
9461 additional_includedir=
9462 case "$found_dir" in
9463 */lib | */lib/)
9464 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9465 additional_includedir="$basedir/include"
9466 ;;
9467 esac
9468 if test "X$additional_includedir" != "X"; then
9469 if test "X$additional_includedir" != "X/usr/include"; then
9470 haveit=
9471 if test "X$additional_includedir" = "X/usr/local/include"; then
9472 if test -n "$GCC"; then
9473 case $host_os in
9474 linux*) haveit=yes;;
9475 esac
9476 fi
9477 fi
9478 if test -z "$haveit"; then
9479 for x in $CPPFLAGS $INCEXPAT; do
9480
9481 acl_save_prefix="$prefix"
9482 prefix="$acl_final_prefix"
9483 acl_save_exec_prefix="$exec_prefix"
9484 exec_prefix="$acl_final_exec_prefix"
9485 eval x=\"$x\"
9486 exec_prefix="$acl_save_exec_prefix"
9487 prefix="$acl_save_prefix"
9488
9489 if test "X$x" = "X-I$additional_includedir"; then
9490 haveit=yes
9491 break
9492 fi
9493 done
9494 if test -z "$haveit"; then
9495 if test -d "$additional_includedir"; then
9496 INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
9497 fi
9498 fi
9499 fi
9500 fi
9501 fi
9502 if test -n "$found_la"; then
9503 save_libdir="$libdir"
9504 case "$found_la" in
9505 */* | *\\*) . "$found_la" ;;
9506 *) . "./$found_la" ;;
9507 esac
9508 libdir="$save_libdir"
9509 for dep in $dependency_libs; do
9510 case "$dep" in
9511 -L*)
9512 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9513 if test "X$additional_libdir" != "X/usr/lib"; then
9514 haveit=
9515 if test "X$additional_libdir" = "X/usr/local/lib"; then
9516 if test -n "$GCC"; then
9517 case $host_os in
9518 linux*) haveit=yes;;
9519 esac
9520 fi
9521 fi
9522 if test -z "$haveit"; then
9523 haveit=
9524 for x in $LDFLAGS $LIBEXPAT; do
9525
9526 acl_save_prefix="$prefix"
9527 prefix="$acl_final_prefix"
9528 acl_save_exec_prefix="$exec_prefix"
9529 exec_prefix="$acl_final_exec_prefix"
9530 eval x=\"$x\"
9531 exec_prefix="$acl_save_exec_prefix"
9532 prefix="$acl_save_prefix"
9533
9534 if test "X$x" = "X-L$additional_libdir"; then
9535 haveit=yes
9536 break
9537 fi
9538 done
9539 if test -z "$haveit"; then
9540 if test -d "$additional_libdir"; then
9541 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
9542 fi
9543 fi
9544 haveit=
9545 for x in $LDFLAGS $LTLIBEXPAT; do
9546
9547 acl_save_prefix="$prefix"
9548 prefix="$acl_final_prefix"
9549 acl_save_exec_prefix="$exec_prefix"
9550 exec_prefix="$acl_final_exec_prefix"
9551 eval x=\"$x\"
9552 exec_prefix="$acl_save_exec_prefix"
9553 prefix="$acl_save_prefix"
9554
9555 if test "X$x" = "X-L$additional_libdir"; then
9556 haveit=yes
9557 break
9558 fi
9559 done
9560 if test -z "$haveit"; then
9561 if test -d "$additional_libdir"; then
9562 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
9563 fi
9564 fi
9565 fi
9566 fi
9567 ;;
9568 -R*)
9569 dir=`echo "X$dep" | sed -e 's/^X-R//'`
9570 if test "$enable_rpath" != no; then
9571 haveit=
9572 for x in $rpathdirs; do
9573 if test "X$x" = "X$dir"; then
9574 haveit=yes
9575 break
9576 fi
9577 done
9578 if test -z "$haveit"; then
9579 rpathdirs="$rpathdirs $dir"
9580 fi
9581 haveit=
9582 for x in $ltrpathdirs; do
9583 if test "X$x" = "X$dir"; then
9584 haveit=yes
9585 break
9586 fi
9587 done
9588 if test -z "$haveit"; then
9589 ltrpathdirs="$ltrpathdirs $dir"
9590 fi
9591 fi
9592 ;;
9593 -l*)
9594 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
9595 ;;
9596 *.la)
9597 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
9598 ;;
9599 *)
9600 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
9601 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
9602 ;;
9603 esac
9604 done
9605 fi
9606 else
9607 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9608 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
9609 fi
9610 fi
9611 fi
9612 done
9613 done
9614 if test "X$rpathdirs" != "X"; then
9615 if test -n "$hardcode_libdir_separator"; then
9616 alldirs=
9617 for found_dir in $rpathdirs; do
9618 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
9619 done
9620 acl_save_libdir="$libdir"
9621 libdir="$alldirs"
9622 eval flag=\"$hardcode_libdir_flag_spec\"
9623 libdir="$acl_save_libdir"
9624 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9625 else
9626 for found_dir in $rpathdirs; do
9627 acl_save_libdir="$libdir"
9628 libdir="$found_dir"
9629 eval flag=\"$hardcode_libdir_flag_spec\"
9630 libdir="$acl_save_libdir"
9631 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9632 done
9633 fi
9634 fi
9635 if test "X$ltrpathdirs" != "X"; then
9636 for found_dir in $ltrpathdirs; do
9637 LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
9638 done
9639 fi
9640
9641
9642 ac_save_CPPFLAGS="$CPPFLAGS"
9643
9644 for element in $INCEXPAT; do
9645 haveit=
9646 for x in $CPPFLAGS; do
9647
9648 acl_save_prefix="$prefix"
9649 prefix="$acl_final_prefix"
9650 acl_save_exec_prefix="$exec_prefix"
9651 exec_prefix="$acl_final_exec_prefix"
9652 eval x=\"$x\"
9653 exec_prefix="$acl_save_exec_prefix"
9654 prefix="$acl_save_prefix"
9655
9656 if test "X$x" = "X$element"; then
9657 haveit=yes
9658 break
9659 fi
9660 done
9661 if test -z "$haveit"; then
9662 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
9663 fi
9664 done
9665
9666
9667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
9668 $as_echo_n "checking for libexpat... " >&6; }
9669 if ${ac_cv_libexpat+:} false; then :
9670 $as_echo_n "(cached) " >&6
9671 else
9672
9673 ac_save_LIBS="$LIBS"
9674 LIBS="$LIBS $LIBEXPAT"
9675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9676 /* end confdefs.h. */
9677 #include "expat.h"
9678 int
9679 main ()
9680 {
9681 XML_Parser p = XML_ParserCreate (0);
9682 ;
9683 return 0;
9684 }
9685 _ACEOF
9686 if ac_fn_c_try_link "$LINENO"; then :
9687 ac_cv_libexpat=yes
9688 else
9689 ac_cv_libexpat=no
9690 fi
9691 rm -f core conftest.err conftest.$ac_objext \
9692 conftest$ac_exeext conftest.$ac_ext
9693 LIBS="$ac_save_LIBS"
9694
9695 fi
9696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
9697 $as_echo "$ac_cv_libexpat" >&6; }
9698 if test "$ac_cv_libexpat" = yes; then
9699 HAVE_LIBEXPAT=yes
9700
9701 $as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
9702
9703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
9704 $as_echo_n "checking how to link with libexpat... " >&6; }
9705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
9706 $as_echo "$LIBEXPAT" >&6; }
9707 else
9708 HAVE_LIBEXPAT=no
9709 CPPFLAGS="$ac_save_CPPFLAGS"
9710 LIBEXPAT=
9711 LTLIBEXPAT=
9712 fi
9713
9714
9715
9716
9717
9718
9719 if test "$HAVE_LIBEXPAT" != yes; then
9720 if test "$with_expat" = yes; then
9721 as_fn_error $? "expat is missing or unusable" "$LINENO" 5
9722 else
9723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
9724 $as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
9725 fi
9726 else
9727 save_LIBS=$LIBS
9728 LIBS="$LIBS $LIBEXPAT"
9729 for ac_func in XML_StopParser
9730 do :
9731 ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
9732 if test "x$ac_cv_func_XML_StopParser" = xyes; then :
9733 cat >>confdefs.h <<_ACEOF
9734 #define HAVE_XML_STOPPARSER 1
9735 _ACEOF
9736
9737 fi
9738 done
9739
9740 LIBS=$save_LIBS
9741 fi
9742 fi
9743
9744
9745 # Check whether --with-mpfr was given.
9746 if test "${with_mpfr+set}" = set; then :
9747 withval=$with_mpfr;
9748 else
9749 with_mpfr=auto
9750 fi
9751
9752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use MPFR" >&5
9753 $as_echo_n "checking whether to use MPFR... " >&6; }
9754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_mpfr" >&5
9755 $as_echo "$with_mpfr" >&6; }
9756
9757 if test "${with_mpfr}" = no; then
9758 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR support disabled; some features may be unavailable." >&5
9759 $as_echo "$as_me: WARNING: MPFR support disabled; some features may be unavailable." >&2;}
9760 HAVE_LIBMPFR=no
9761 else
9762
9763
9764
9765
9766
9767
9768
9769
9770 use_additional=yes
9771
9772 acl_save_prefix="$prefix"
9773 prefix="$acl_final_prefix"
9774 acl_save_exec_prefix="$exec_prefix"
9775 exec_prefix="$acl_final_exec_prefix"
9776
9777 eval additional_includedir=\"$includedir\"
9778 eval additional_libdir=\"$libdir\"
9779
9780 exec_prefix="$acl_save_exec_prefix"
9781 prefix="$acl_save_prefix"
9782
9783
9784 # Check whether --with-libmpfr-prefix was given.
9785 if test "${with_libmpfr_prefix+set}" = set; then :
9786 withval=$with_libmpfr_prefix;
9787 if test "X$withval" = "Xno"; then
9788 use_additional=no
9789 else
9790 if test "X$withval" = "X"; then
9791
9792 acl_save_prefix="$prefix"
9793 prefix="$acl_final_prefix"
9794 acl_save_exec_prefix="$exec_prefix"
9795 exec_prefix="$acl_final_exec_prefix"
9796
9797 eval additional_includedir=\"$includedir\"
9798 eval additional_libdir=\"$libdir\"
9799
9800 exec_prefix="$acl_save_exec_prefix"
9801 prefix="$acl_save_prefix"
9802
9803 else
9804 additional_includedir="$withval/include"
9805 additional_libdir="$withval/lib"
9806 fi
9807 fi
9808
9809 fi
9810
9811 LIBMPFR=
9812 LTLIBMPFR=
9813 INCMPFR=
9814 rpathdirs=
9815 ltrpathdirs=
9816 names_already_handled=
9817 names_next_round='mpfr gmp'
9818 while test -n "$names_next_round"; do
9819 names_this_round="$names_next_round"
9820 names_next_round=
9821 for name in $names_this_round; do
9822 already_handled=
9823 for n in $names_already_handled; do
9824 if test "$n" = "$name"; then
9825 already_handled=yes
9826 break
9827 fi
9828 done
9829 if test -z "$already_handled"; then
9830 names_already_handled="$names_already_handled $name"
9831 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9832 eval value=\"\$HAVE_LIB$uppername\"
9833 if test -n "$value"; then
9834 if test "$value" = yes; then
9835 eval value=\"\$LIB$uppername\"
9836 test -z "$value" || LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$value"
9837 eval value=\"\$LTLIB$uppername\"
9838 test -z "$value" || LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$value"
9839 else
9840 :
9841 fi
9842 else
9843 found_dir=
9844 found_la=
9845 found_so=
9846 found_a=
9847 if test $use_additional = yes; then
9848 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
9849 found_dir="$additional_libdir"
9850 found_so="$additional_libdir/lib$name.$shlibext"
9851 if test -f "$additional_libdir/lib$name.la"; then
9852 found_la="$additional_libdir/lib$name.la"
9853 fi
9854 else
9855 if test -f "$additional_libdir/lib$name.$libext"; then
9856 found_dir="$additional_libdir"
9857 found_a="$additional_libdir/lib$name.$libext"
9858 if test -f "$additional_libdir/lib$name.la"; then
9859 found_la="$additional_libdir/lib$name.la"
9860 fi
9861 fi
9862 fi
9863 fi
9864 if test "X$found_dir" = "X"; then
9865 for x in $LDFLAGS $LTLIBMPFR; do
9866
9867 acl_save_prefix="$prefix"
9868 prefix="$acl_final_prefix"
9869 acl_save_exec_prefix="$exec_prefix"
9870 exec_prefix="$acl_final_exec_prefix"
9871 eval x=\"$x\"
9872 exec_prefix="$acl_save_exec_prefix"
9873 prefix="$acl_save_prefix"
9874
9875 case "$x" in
9876 -L*)
9877 dir=`echo "X$x" | sed -e 's/^X-L//'`
9878 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
9879 found_dir="$dir"
9880 found_so="$dir/lib$name.$shlibext"
9881 if test -f "$dir/lib$name.la"; then
9882 found_la="$dir/lib$name.la"
9883 fi
9884 else
9885 if test -f "$dir/lib$name.$libext"; then
9886 found_dir="$dir"
9887 found_a="$dir/lib$name.$libext"
9888 if test -f "$dir/lib$name.la"; then
9889 found_la="$dir/lib$name.la"
9890 fi
9891 fi
9892 fi
9893 ;;
9894 esac
9895 if test "X$found_dir" != "X"; then
9896 break
9897 fi
9898 done
9899 fi
9900 if test "X$found_dir" != "X"; then
9901 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$found_dir -l$name"
9902 if test "X$found_so" != "X"; then
9903 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9904 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9905 else
9906 haveit=
9907 for x in $ltrpathdirs; do
9908 if test "X$x" = "X$found_dir"; then
9909 haveit=yes
9910 break
9911 fi
9912 done
9913 if test -z "$haveit"; then
9914 ltrpathdirs="$ltrpathdirs $found_dir"
9915 fi
9916 if test "$hardcode_direct" = yes; then
9917 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9918 else
9919 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9920 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9921 haveit=
9922 for x in $rpathdirs; do
9923 if test "X$x" = "X$found_dir"; then
9924 haveit=yes
9925 break
9926 fi
9927 done
9928 if test -z "$haveit"; then
9929 rpathdirs="$rpathdirs $found_dir"
9930 fi
9931 else
9932 haveit=
9933 for x in $LDFLAGS $LIBMPFR; do
9934
9935 acl_save_prefix="$prefix"
9936 prefix="$acl_final_prefix"
9937 acl_save_exec_prefix="$exec_prefix"
9938 exec_prefix="$acl_final_exec_prefix"
9939 eval x=\"$x\"
9940 exec_prefix="$acl_save_exec_prefix"
9941 prefix="$acl_save_prefix"
9942
9943 if test "X$x" = "X-L$found_dir"; then
9944 haveit=yes
9945 break
9946 fi
9947 done
9948 if test -z "$haveit"; then
9949 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir"
9950 fi
9951 if test "$hardcode_minus_L" != no; then
9952 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9953 else
9954 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
9955 fi
9956 fi
9957 fi
9958 fi
9959 else
9960 if test "X$found_a" != "X"; then
9961 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_a"
9962 else
9963 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir -l$name"
9964 fi
9965 fi
9966 additional_includedir=
9967 case "$found_dir" in
9968 */lib | */lib/)
9969 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9970 additional_includedir="$basedir/include"
9971 ;;
9972 esac
9973 if test "X$additional_includedir" != "X"; then
9974 if test "X$additional_includedir" != "X/usr/include"; then
9975 haveit=
9976 if test "X$additional_includedir" = "X/usr/local/include"; then
9977 if test -n "$GCC"; then
9978 case $host_os in
9979 linux*) haveit=yes;;
9980 esac
9981 fi
9982 fi
9983 if test -z "$haveit"; then
9984 for x in $CPPFLAGS $INCMPFR; do
9985
9986 acl_save_prefix="$prefix"
9987 prefix="$acl_final_prefix"
9988 acl_save_exec_prefix="$exec_prefix"
9989 exec_prefix="$acl_final_exec_prefix"
9990 eval x=\"$x\"
9991 exec_prefix="$acl_save_exec_prefix"
9992 prefix="$acl_save_prefix"
9993
9994 if test "X$x" = "X-I$additional_includedir"; then
9995 haveit=yes
9996 break
9997 fi
9998 done
9999 if test -z "$haveit"; then
10000 if test -d "$additional_includedir"; then
10001 INCMPFR="${INCMPFR}${INCMPFR:+ }-I$additional_includedir"
10002 fi
10003 fi
10004 fi
10005 fi
10006 fi
10007 if test -n "$found_la"; then
10008 save_libdir="$libdir"
10009 case "$found_la" in
10010 */* | *\\*) . "$found_la" ;;
10011 *) . "./$found_la" ;;
10012 esac
10013 libdir="$save_libdir"
10014 for dep in $dependency_libs; do
10015 case "$dep" in
10016 -L*)
10017 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10018 if test "X$additional_libdir" != "X/usr/lib"; then
10019 haveit=
10020 if test "X$additional_libdir" = "X/usr/local/lib"; then
10021 if test -n "$GCC"; then
10022 case $host_os in
10023 linux*) haveit=yes;;
10024 esac
10025 fi
10026 fi
10027 if test -z "$haveit"; then
10028 haveit=
10029 for x in $LDFLAGS $LIBMPFR; do
10030
10031 acl_save_prefix="$prefix"
10032 prefix="$acl_final_prefix"
10033 acl_save_exec_prefix="$exec_prefix"
10034 exec_prefix="$acl_final_exec_prefix"
10035 eval x=\"$x\"
10036 exec_prefix="$acl_save_exec_prefix"
10037 prefix="$acl_save_prefix"
10038
10039 if test "X$x" = "X-L$additional_libdir"; then
10040 haveit=yes
10041 break
10042 fi
10043 done
10044 if test -z "$haveit"; then
10045 if test -d "$additional_libdir"; then
10046 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$additional_libdir"
10047 fi
10048 fi
10049 haveit=
10050 for x in $LDFLAGS $LTLIBMPFR; do
10051
10052 acl_save_prefix="$prefix"
10053 prefix="$acl_final_prefix"
10054 acl_save_exec_prefix="$exec_prefix"
10055 exec_prefix="$acl_final_exec_prefix"
10056 eval x=\"$x\"
10057 exec_prefix="$acl_save_exec_prefix"
10058 prefix="$acl_save_prefix"
10059
10060 if test "X$x" = "X-L$additional_libdir"; then
10061 haveit=yes
10062 break
10063 fi
10064 done
10065 if test -z "$haveit"; then
10066 if test -d "$additional_libdir"; then
10067 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$additional_libdir"
10068 fi
10069 fi
10070 fi
10071 fi
10072 ;;
10073 -R*)
10074 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10075 if test "$enable_rpath" != no; then
10076 haveit=
10077 for x in $rpathdirs; do
10078 if test "X$x" = "X$dir"; then
10079 haveit=yes
10080 break
10081 fi
10082 done
10083 if test -z "$haveit"; then
10084 rpathdirs="$rpathdirs $dir"
10085 fi
10086 haveit=
10087 for x in $ltrpathdirs; do
10088 if test "X$x" = "X$dir"; then
10089 haveit=yes
10090 break
10091 fi
10092 done
10093 if test -z "$haveit"; then
10094 ltrpathdirs="$ltrpathdirs $dir"
10095 fi
10096 fi
10097 ;;
10098 -l*)
10099 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10100 ;;
10101 *.la)
10102 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10103 ;;
10104 *)
10105 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$dep"
10106 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$dep"
10107 ;;
10108 esac
10109 done
10110 fi
10111 else
10112 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
10113 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-l$name"
10114 fi
10115 fi
10116 fi
10117 done
10118 done
10119 if test "X$rpathdirs" != "X"; then
10120 if test -n "$hardcode_libdir_separator"; then
10121 alldirs=
10122 for found_dir in $rpathdirs; do
10123 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10124 done
10125 acl_save_libdir="$libdir"
10126 libdir="$alldirs"
10127 eval flag=\"$hardcode_libdir_flag_spec\"
10128 libdir="$acl_save_libdir"
10129 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10130 else
10131 for found_dir in $rpathdirs; do
10132 acl_save_libdir="$libdir"
10133 libdir="$found_dir"
10134 eval flag=\"$hardcode_libdir_flag_spec\"
10135 libdir="$acl_save_libdir"
10136 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10137 done
10138 fi
10139 fi
10140 if test "X$ltrpathdirs" != "X"; then
10141 for found_dir in $ltrpathdirs; do
10142 LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-R$found_dir"
10143 done
10144 fi
10145
10146
10147 ac_save_CPPFLAGS="$CPPFLAGS"
10148
10149 for element in $INCMPFR; do
10150 haveit=
10151 for x in $CPPFLAGS; do
10152
10153 acl_save_prefix="$prefix"
10154 prefix="$acl_final_prefix"
10155 acl_save_exec_prefix="$exec_prefix"
10156 exec_prefix="$acl_final_exec_prefix"
10157 eval x=\"$x\"
10158 exec_prefix="$acl_save_exec_prefix"
10159 prefix="$acl_save_prefix"
10160
10161 if test "X$x" = "X$element"; then
10162 haveit=yes
10163 break
10164 fi
10165 done
10166 if test -z "$haveit"; then
10167 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10168 fi
10169 done
10170
10171
10172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmpfr" >&5
10173 $as_echo_n "checking for libmpfr... " >&6; }
10174 if ${ac_cv_libmpfr+:} false; then :
10175 $as_echo_n "(cached) " >&6
10176 else
10177
10178 ac_save_LIBS="$LIBS"
10179 LIBS="$LIBS $LIBMPFR"
10180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10181 /* end confdefs.h. */
10182 #include <mpfr.h>
10183 int
10184 main ()
10185 {
10186 mpfr_exp_t exp; mpfr_t x;
10187 mpfr_frexp (&exp, x, x, MPFR_RNDN);
10188 ;
10189 return 0;
10190 }
10191 _ACEOF
10192 if ac_fn_c_try_link "$LINENO"; then :
10193 ac_cv_libmpfr=yes
10194 else
10195 ac_cv_libmpfr=no
10196 fi
10197 rm -f core conftest.err conftest.$ac_objext \
10198 conftest$ac_exeext conftest.$ac_ext
10199 LIBS="$ac_save_LIBS"
10200
10201 fi
10202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libmpfr" >&5
10203 $as_echo "$ac_cv_libmpfr" >&6; }
10204 if test "$ac_cv_libmpfr" = yes; then
10205 HAVE_LIBMPFR=yes
10206
10207 $as_echo "#define HAVE_LIBMPFR 1" >>confdefs.h
10208
10209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libmpfr" >&5
10210 $as_echo_n "checking how to link with libmpfr... " >&6; }
10211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBMPFR" >&5
10212 $as_echo "$LIBMPFR" >&6; }
10213 else
10214 HAVE_LIBMPFR=no
10215 CPPFLAGS="$ac_save_CPPFLAGS"
10216 LIBMPFR=
10217 LTLIBMPFR=
10218 fi
10219
10220
10221
10222
10223
10224
10225 if test "$HAVE_LIBMPFR" != yes; then
10226 if test "$with_mpfr" = yes; then
10227 as_fn_error $? "MPFR is missing or unusable" "$LINENO" 5
10228 else
10229 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR is missing or unusable; some features may be unavailable." >&5
10230 $as_echo "$as_me: WARNING: MPFR is missing or unusable; some features may be unavailable." >&2;}
10231 fi
10232 fi
10233 fi
10234
10235 # --------------------- #
10236 # Check for libpython. #
10237 # --------------------- #
10238
10239
10240
10241
10242
10243
10244 # Check whether --with-python was given.
10245 if test "${with_python+set}" = set; then :
10246 withval=$with_python;
10247 else
10248 with_python=auto
10249 fi
10250
10251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
10252 $as_echo_n "checking whether to use python... " >&6; }
10253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
10254 $as_echo "$with_python" >&6; }
10255
10256 if test "${with_python}" = no; then
10257 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
10258 $as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
10259 have_libpython=no
10260 else
10261 case "${with_python}" in
10262 [\\/]* | ?:[\\/]*)
10263 if test -d ${with_python}; then
10264 # Assume the python binary is ${with_python}/bin/python.
10265 python_prog="${with_python}/bin/python"
10266 python_prefix=
10267 # If python does not exit ${with_python}/bin, then try in
10268 # ${with_python}. On Windows/MinGW, this is where the Python
10269 # executable is.
10270 if test ! -x "${python_prog}"; then
10271 python_prog="${with_python}/python"
10272 python_prefix=
10273 fi
10274 if test ! -x "${python_prog}"; then
10275 # Fall back to gdb 7.0/7.1 behaviour.
10276 python_prog=missing
10277 python_prefix=${with_python}
10278 fi
10279 elif test -x "${with_python}"; then
10280 # While we can't run python compiled for $host (unless host == build),
10281 # the user could write a script that provides the needed information,
10282 # so we support that.
10283 python_prog=${with_python}
10284 python_prefix=
10285 else
10286 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
10287 fi
10288 ;;
10289 */*)
10290 # Disallow --with-python=foo/bar.
10291 as_fn_error $? "invalid value for --with-python" "$LINENO" 5
10292 ;;
10293 *)
10294 # The user has either specified auto, yes, or the name of the python
10295 # program assumed to be in $PATH.
10296 python_prefix=
10297 case "${with_python}" in
10298 yes | auto)
10299 if test ${build} = ${host}; then
10300 # Extract the first word of "python", so it can be a program name with args.
10301 set dummy python; ac_word=$2
10302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10303 $as_echo_n "checking for $ac_word... " >&6; }
10304 if ${ac_cv_path_python_prog_path+:} false; then :
10305 $as_echo_n "(cached) " >&6
10306 else
10307 case $python_prog_path in
10308 [\\/]* | ?:[\\/]*)
10309 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10310 ;;
10311 *)
10312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10313 for as_dir in $PATH
10314 do
10315 IFS=$as_save_IFS
10316 test -z "$as_dir" && as_dir=.
10317 for ac_exec_ext in '' $ac_executable_extensions; do
10318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10319 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10321 break 2
10322 fi
10323 done
10324 done
10325 IFS=$as_save_IFS
10326
10327 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10328 ;;
10329 esac
10330 fi
10331 python_prog_path=$ac_cv_path_python_prog_path
10332 if test -n "$python_prog_path"; then
10333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10334 $as_echo "$python_prog_path" >&6; }
10335 else
10336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10337 $as_echo "no" >&6; }
10338 fi
10339
10340
10341 if test "${python_prog_path}" = missing; then
10342 python_prog=missing
10343 else
10344 python_prog=${python_prog_path}
10345 fi
10346 else
10347 # Not much we can do except assume the cross-compiler will find the
10348 # right files.
10349 python_prog=missing
10350 fi
10351 ;;
10352 *)
10353 # While we can't run python compiled for $host (unless host == build),
10354 # the user could write a script that provides the needed information,
10355 # so we support that.
10356 python_prog="${with_python}"
10357 # Extract the first word of "${python_prog}", so it can be a program name with args.
10358 set dummy ${python_prog}; ac_word=$2
10359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10360 $as_echo_n "checking for $ac_word... " >&6; }
10361 if ${ac_cv_path_python_prog_path+:} false; then :
10362 $as_echo_n "(cached) " >&6
10363 else
10364 case $python_prog_path in
10365 [\\/]* | ?:[\\/]*)
10366 ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10367 ;;
10368 *)
10369 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10370 for as_dir in $PATH
10371 do
10372 IFS=$as_save_IFS
10373 test -z "$as_dir" && as_dir=.
10374 for ac_exec_ext in '' $ac_executable_extensions; do
10375 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10376 ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10377 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10378 break 2
10379 fi
10380 done
10381 done
10382 IFS=$as_save_IFS
10383
10384 test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10385 ;;
10386 esac
10387 fi
10388 python_prog_path=$ac_cv_path_python_prog_path
10389 if test -n "$python_prog_path"; then
10390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10391 $as_echo "$python_prog_path" >&6; }
10392 else
10393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10394 $as_echo "no" >&6; }
10395 fi
10396
10397
10398 if test "${python_prog_path}" = missing; then
10399 as_fn_error $? "unable to find python program ${python_prog}" "$LINENO" 5
10400 fi
10401 ;;
10402 esac
10403 esac
10404
10405 if test "${python_prog}" != missing; then
10406 # We have a python program to use, but it may be too old.
10407 # Don't flag an error for --with-python=auto (the default).
10408 have_python_config=yes
10409 python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
10410 if test $? != 0; then
10411 have_python_config=failed
10412 if test "${with_python}" != auto; then
10413 as_fn_error $? "failure running python-config --includes" "$LINENO" 5
10414 fi
10415 fi
10416 python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
10417 if test $? != 0; then
10418 have_python_config=failed
10419 if test "${with_python}" != auto; then
10420 as_fn_error $? "failure running python-config --ldflags" "$LINENO" 5
10421 fi
10422 fi
10423 python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
10424 if test $? != 0; then
10425 have_python_config=failed
10426 if test "${with_python}" != auto; then
10427 as_fn_error $? "failure running python-config --exec-prefix" "$LINENO" 5
10428 fi
10429 fi
10430 else
10431 # We do not have a python executable we can use to determine where
10432 # to find the Python headers and libs. We cannot guess the include
10433 # path from the python_prefix either, because that include path
10434 # depends on the Python version. So, there is nothing much we can
10435 # do except assume that the compiler will be able to find those files.
10436 python_includes=
10437 python_libs=
10438 have_python_config=no
10439 fi
10440
10441 # If we have python-config, only try the configuration it provides.
10442 # Otherwise fallback on the old way of trying different versions of
10443 # python in turn.
10444
10445 have_libpython=no
10446 if test "${have_python_config}" = yes; then
10447
10448
10449 new_CPPFLAGS=${python_includes}
10450 new_LIBS=${python_libs}
10451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
10452 $as_echo_n "checking for python... " >&6; }
10453 save_CPPFLAGS=$CPPFLAGS
10454 save_LIBS=$LIBS
10455 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10456 LIBS="$new_LIBS $LIBS"
10457 found_usable_python=no
10458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10459 /* end confdefs.h. */
10460 #include "Python.h"
10461 int
10462 main ()
10463 {
10464 Py_Initialize ();
10465 ;
10466 return 0;
10467 }
10468 _ACEOF
10469 if ac_fn_c_try_link "$LINENO"; then :
10470 have_libpython=yes
10471 found_usable_python=yes
10472 PYTHON_CPPFLAGS=$new_CPPFLAGS
10473 PYTHON_LIBS=$new_LIBS
10474 fi
10475 rm -f core conftest.err conftest.$ac_objext \
10476 conftest$ac_exeext conftest.$ac_ext
10477 CPPFLAGS=$save_CPPFLAGS
10478 LIBS=$save_LIBS
10479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10480 $as_echo "${found_usable_python}" >&6; }
10481
10482 elif test "${have_python_config}" != failed; then
10483 if test "${have_libpython}" = no; then
10484
10485
10486 new_CPPFLAGS=${python_includes}
10487 new_LIBS="-lpython2.7 ${python_libs}"
10488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
10489 $as_echo_n "checking for python... " >&6; }
10490 save_CPPFLAGS=$CPPFLAGS
10491 save_LIBS=$LIBS
10492 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10493 LIBS="$new_LIBS $LIBS"
10494 found_usable_python=no
10495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10496 /* end confdefs.h. */
10497 #include "Python.h"
10498 int
10499 main ()
10500 {
10501 Py_Initialize ();
10502 ;
10503 return 0;
10504 }
10505 _ACEOF
10506 if ac_fn_c_try_link "$LINENO"; then :
10507 have_libpython=yes
10508 found_usable_python=yes
10509 PYTHON_CPPFLAGS=$new_CPPFLAGS
10510 PYTHON_LIBS=$new_LIBS
10511 fi
10512 rm -f core conftest.err conftest.$ac_objext \
10513 conftest$ac_exeext conftest.$ac_ext
10514 CPPFLAGS=$save_CPPFLAGS
10515 LIBS=$save_LIBS
10516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10517 $as_echo "${found_usable_python}" >&6; }
10518
10519 fi
10520 if test "${have_libpython}" = no; then
10521
10522
10523 new_CPPFLAGS=${python_includes}
10524 new_LIBS="-lpython2.6 ${python_libs}"
10525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python" >&5
10526 $as_echo_n "checking for python... " >&6; }
10527 save_CPPFLAGS=$CPPFLAGS
10528 save_LIBS=$LIBS
10529 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10530 LIBS="$new_LIBS $LIBS"
10531 found_usable_python=no
10532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10533 /* end confdefs.h. */
10534 #include "Python.h"
10535 int
10536 main ()
10537 {
10538 Py_Initialize ();
10539 ;
10540 return 0;
10541 }
10542 _ACEOF
10543 if ac_fn_c_try_link "$LINENO"; then :
10544 have_libpython=yes
10545 found_usable_python=yes
10546 PYTHON_CPPFLAGS=$new_CPPFLAGS
10547 PYTHON_LIBS=$new_LIBS
10548 fi
10549 rm -f core conftest.err conftest.$ac_objext \
10550 conftest$ac_exeext conftest.$ac_ext
10551 CPPFLAGS=$save_CPPFLAGS
10552 LIBS=$save_LIBS
10553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10554 $as_echo "${found_usable_python}" >&6; }
10555
10556 fi
10557 fi
10558
10559 if test "${have_libpython}" = no; then
10560 case "${with_python}" in
10561 yes)
10562 as_fn_error $? "python is missing or unusable" "$LINENO" 5
10563 ;;
10564 auto)
10565 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
10566 $as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
10567 ;;
10568 *)
10569 as_fn_error $? "no usable python found at ${with_python}" "$LINENO" 5
10570 ;;
10571 esac
10572 else
10573 if test -n "${python_prefix}"; then
10574
10575 cat >>confdefs.h <<_ACEOF
10576 #define WITH_PYTHON_PATH "${python_prefix}"
10577 _ACEOF
10578
10579
10580 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
10581 if test "x$prefix" = xNONE; then
10582 test_prefix=/usr/local
10583 else
10584 test_prefix=$prefix
10585 fi
10586 else
10587 test_prefix=$exec_prefix
10588 fi
10589 value=0
10590 case ${python_prefix} in
10591 "${test_prefix}"|"${test_prefix}/"*|\
10592 '${exec_prefix}'|'${exec_prefix}/'*)
10593 value=1
10594 ;;
10595 esac
10596
10597 cat >>confdefs.h <<_ACEOF
10598 #define PYTHON_PATH_RELOCATABLE $value
10599 _ACEOF
10600
10601
10602 fi
10603 fi
10604 fi
10605
10606 if test "${have_libpython}" != no; then
10607
10608 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
10609
10610 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
10611 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
10612 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
10613 CONFIG_INSTALL="$CONFIG_INSTALL install-python"
10614 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
10615
10616 # Flags needed to compile Python code (taken from python-config --cflags).
10617 # We cannot call python-config directly because it will output whatever was
10618 # used when compiling the Python interpreter itself, including flags which
10619 # would make the python-related objects be compiled differently from the
10620 # rest of GDB (e.g., -O2 and -fPIC).
10621 if test "${GCC}" = yes; then
10622 tentative_python_cflags="-fno-strict-aliasing -fwrapv"
10623 # Python headers recommend -DNDEBUG, but it's unclear if that just
10624 # refers to building Python itself. In release mode, though, it
10625 # doesn't hurt for the Python code in gdb to follow.
10626 $development || tentative_python_cflags="$tentative_python_cflags -DNDEBUG"
10627 fi
10628
10629 if test "x${tentative_python_cflags}" != x; then
10630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
10631 $as_echo_n "checking compiler flags for python code... " >&6; }
10632 for flag in ${tentative_python_cflags}; do
10633 # Check that the compiler accepts it
10634 saved_CFLAGS="$CFLAGS"
10635 CFLAGS="$CFLAGS $flag"
10636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10637 /* end confdefs.h. */
10638
10639 int
10640 main ()
10641 {
10642
10643 ;
10644 return 0;
10645 }
10646 _ACEOF
10647 if ac_fn_c_try_compile "$LINENO"; then :
10648 PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
10649 fi
10650 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10651 CFLAGS="$saved_CFLAGS"
10652 done
10653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
10654 $as_echo "${PYTHON_CFLAGS}" >&6; }
10655 fi
10656
10657 # On x64 Windows, Python's include headers, and pyconfig.h in
10658 # particular, rely on MS_WIN64 macro to detect that it's a 64bit
10659 # version of Windows. Unfortunately, MS_WIN64 is only defined if
10660 # _MSC_VER, a Microsoft-specific macro, is defined. So, when
10661 # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
10662 # The issue was reported to the Python community, but still isn't
10663 # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
10664
10665 case "$gdb_host" in
10666 mingw64)
10667 if test "${GCC}" = yes; then
10668 CPPFLAGS="$CPPFLAGS -DMS_WIN64"
10669 fi
10670 ;;
10671 esac
10672 else
10673 # Even if Python support is not compiled in, we need to have this file
10674 # included so that the "python" command, et.al., still exists.
10675 CONFIG_OBS="$CONFIG_OBS python/python.o"
10676 CONFIG_SRCS="$CONFIG_SRCS python/python.c"
10677 fi
10678
10679 # Work around Python http://bugs.python.org/issue10112. See also
10680 # http://bugs.python.org/issue11410, otherwise -Wl,--dynamic-list has
10681 # no effect. Note that the only test after this that uses Python is
10682 # the -rdynamic/-Wl,--dynamic-list test, and we do want that one to be
10683 # run without -export-dynamic too.
10684 PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/-Xlinker -export-dynamic//'`
10685
10686
10687
10688
10689 if test "${have_libpython}" != no; then
10690 HAVE_PYTHON_TRUE=
10691 HAVE_PYTHON_FALSE='#'
10692 else
10693 HAVE_PYTHON_TRUE='#'
10694 HAVE_PYTHON_FALSE=
10695 fi
10696
10697
10698 # -------------------- #
10699 # Check for libguile. #
10700 # -------------------- #
10701
10702
10703
10704
10705
10706
10707 # Check whether --with-guile was given.
10708 if test "${with_guile+set}" = set; then :
10709 withval=$with_guile;
10710 else
10711 with_guile=auto
10712 fi
10713
10714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use guile" >&5
10715 $as_echo_n "checking whether to use guile... " >&6; }
10716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_guile" >&5
10717 $as_echo "$with_guile" >&6; }
10718
10719 # Extract the first word of "pkg-config", so it can be a program name with args.
10720 set dummy pkg-config; ac_word=$2
10721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10722 $as_echo_n "checking for $ac_word... " >&6; }
10723 if ${ac_cv_path_pkg_config_prog_path+:} false; then :
10724 $as_echo_n "(cached) " >&6
10725 else
10726 case $pkg_config_prog_path in
10727 [\\/]* | ?:[\\/]*)
10728 ac_cv_path_pkg_config_prog_path="$pkg_config_prog_path" # Let the user override the test with a path.
10729 ;;
10730 *)
10731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10732 for as_dir in $PATH
10733 do
10734 IFS=$as_save_IFS
10735 test -z "$as_dir" && as_dir=.
10736 for ac_exec_ext in '' $ac_executable_extensions; do
10737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10738 ac_cv_path_pkg_config_prog_path="$as_dir/$ac_word$ac_exec_ext"
10739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10740 break 2
10741 fi
10742 done
10743 done
10744 IFS=$as_save_IFS
10745
10746 test -z "$ac_cv_path_pkg_config_prog_path" && ac_cv_path_pkg_config_prog_path="missing"
10747 ;;
10748 esac
10749 fi
10750 pkg_config_prog_path=$ac_cv_path_pkg_config_prog_path
10751 if test -n "$pkg_config_prog_path"; then
10752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pkg_config_prog_path" >&5
10753 $as_echo "$pkg_config_prog_path" >&6; }
10754 else
10755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10756 $as_echo "no" >&6; }
10757 fi
10758
10759
10760
10761 try_guile_versions="guile-2.0"
10762 have_libguile=no
10763 case "${with_guile}" in
10764 no)
10765 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: guile support disabled; some features will be unavailable." >&5
10766 $as_echo "$as_me: WARNING: guile support disabled; some features will be unavailable." >&2;}
10767 ;;
10768 auto)
10769 if test "${pkg_config_prog_path}" = "missing"; then
10770 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config not found, guile support disabled" >&5
10771 $as_echo "$as_me: WARNING: pkg-config not found, guile support disabled" >&2;}
10772 else
10773
10774 pkg_config=${pkg_config_prog_path}
10775 guile_version_list=${try_guile_versions}
10776 flag_errors=no
10777
10778 found_usable_guile=checking
10779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10780 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10781 for guile_version in ${guile_version_list}; do
10782 ${pkg_config} --exists ${guile_version} 2>/dev/null
10783 if test $? != 0; then
10784 continue
10785 fi
10786 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10787 if test $? != 0; then
10788 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10789 fi
10790 new_LIBS=`${pkg_config} --libs ${guile_version}`
10791 if test $? != 0; then
10792 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10793 fi
10794 found_usable_guile=${guile_version}
10795 break
10796 done
10797 if test "${found_usable_guile}" = "checking"; then
10798 if test "${flag_errors}" = "yes"; then
10799 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10800 else
10801 found_usable_guile=no
10802 fi
10803 fi
10804 if test "${found_usable_guile}" != no; then
10805 save_CPPFLAGS=$CPPFLAGS
10806 save_LIBS=$LIBS
10807 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10808 LIBS="$LIBS $new_LIBS"
10809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10810 /* end confdefs.h. */
10811 #include "libguile.h"
10812 int
10813 main ()
10814 {
10815 scm_init_guile ();
10816 ;
10817 return 0;
10818 }
10819 _ACEOF
10820 if ac_fn_c_try_link "$LINENO"; then :
10821 have_libguile=yes
10822 GUILE_CPPFLAGS=$new_CPPFLAGS
10823 GUILE_LIBS=$new_LIBS
10824 else
10825 found_usable_guile=no
10826 fi
10827 rm -f core conftest.err conftest.$ac_objext \
10828 conftest$ac_exeext conftest.$ac_ext
10829 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
10830 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
10831
10832 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
10833
10834
10835 fi
10836
10837 CPPFLAGS=$save_CPPFLAGS
10838 LIBS=$save_LIBS
10839 if test "${found_usable_guile}" = no; then
10840 if test "${flag_errors}" = yes; then
10841 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10842 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10843 as_fn_error $? "linking guile version ${guile_version} test program failed
10844 See \`config.log' for more details" "$LINENO" 5; }
10845 fi
10846 fi
10847 fi
10848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
10849 $as_echo "${found_usable_guile}" >&6; }
10850
10851 fi
10852 ;;
10853 yes)
10854 if test "${pkg_config_prog_path}" = "missing"; then
10855 as_fn_error $? "pkg-config not found" "$LINENO" 5
10856 fi
10857
10858 pkg_config=${pkg_config_prog_path}
10859 guile_version_list=${try_guile_versions}
10860 flag_errors=yes
10861
10862 found_usable_guile=checking
10863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10864 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10865 for guile_version in ${guile_version_list}; do
10866 ${pkg_config} --exists ${guile_version} 2>/dev/null
10867 if test $? != 0; then
10868 continue
10869 fi
10870 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10871 if test $? != 0; then
10872 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10873 fi
10874 new_LIBS=`${pkg_config} --libs ${guile_version}`
10875 if test $? != 0; then
10876 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10877 fi
10878 found_usable_guile=${guile_version}
10879 break
10880 done
10881 if test "${found_usable_guile}" = "checking"; then
10882 if test "${flag_errors}" = "yes"; then
10883 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10884 else
10885 found_usable_guile=no
10886 fi
10887 fi
10888 if test "${found_usable_guile}" != no; then
10889 save_CPPFLAGS=$CPPFLAGS
10890 save_LIBS=$LIBS
10891 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10892 LIBS="$LIBS $new_LIBS"
10893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10894 /* end confdefs.h. */
10895 #include "libguile.h"
10896 int
10897 main ()
10898 {
10899 scm_init_guile ();
10900 ;
10901 return 0;
10902 }
10903 _ACEOF
10904 if ac_fn_c_try_link "$LINENO"; then :
10905 have_libguile=yes
10906 GUILE_CPPFLAGS=$new_CPPFLAGS
10907 GUILE_LIBS=$new_LIBS
10908 else
10909 found_usable_guile=no
10910 fi
10911 rm -f core conftest.err conftest.$ac_objext \
10912 conftest$ac_exeext conftest.$ac_ext
10913 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
10914 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
10915
10916 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
10917
10918
10919 fi
10920
10921 CPPFLAGS=$save_CPPFLAGS
10922 LIBS=$save_LIBS
10923 if test "${found_usable_guile}" = no; then
10924 if test "${flag_errors}" = yes; then
10925 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10926 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10927 as_fn_error $? "linking guile version ${guile_version} test program failed
10928 See \`config.log' for more details" "$LINENO" 5; }
10929 fi
10930 fi
10931 fi
10932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
10933 $as_echo "${found_usable_guile}" >&6; }
10934
10935 ;;
10936 [\\/]* | ?:[\\/]*)
10937 if test -x "${with_guile}"; then
10938
10939 pkg_config=${with_guile}
10940 guile_version_list=${try_guile_versions}
10941 flag_errors=yes
10942
10943 found_usable_guile=checking
10944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10945 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10946 for guile_version in ${guile_version_list}; do
10947 ${pkg_config} --exists ${guile_version} 2>/dev/null
10948 if test $? != 0; then
10949 continue
10950 fi
10951 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10952 if test $? != 0; then
10953 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10954 fi
10955 new_LIBS=`${pkg_config} --libs ${guile_version}`
10956 if test $? != 0; then
10957 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10958 fi
10959 found_usable_guile=${guile_version}
10960 break
10961 done
10962 if test "${found_usable_guile}" = "checking"; then
10963 if test "${flag_errors}" = "yes"; then
10964 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10965 else
10966 found_usable_guile=no
10967 fi
10968 fi
10969 if test "${found_usable_guile}" != no; then
10970 save_CPPFLAGS=$CPPFLAGS
10971 save_LIBS=$LIBS
10972 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10973 LIBS="$LIBS $new_LIBS"
10974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10975 /* end confdefs.h. */
10976 #include "libguile.h"
10977 int
10978 main ()
10979 {
10980 scm_init_guile ();
10981 ;
10982 return 0;
10983 }
10984 _ACEOF
10985 if ac_fn_c_try_link "$LINENO"; then :
10986 have_libguile=yes
10987 GUILE_CPPFLAGS=$new_CPPFLAGS
10988 GUILE_LIBS=$new_LIBS
10989 else
10990 found_usable_guile=no
10991 fi
10992 rm -f core conftest.err conftest.$ac_objext \
10993 conftest$ac_exeext conftest.$ac_ext
10994 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
10995 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
10996
10997 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
10998
10999
11000 fi
11001
11002 CPPFLAGS=$save_CPPFLAGS
11003 LIBS=$save_LIBS
11004 if test "${found_usable_guile}" = no; then
11005 if test "${flag_errors}" = yes; then
11006 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11007 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11008 as_fn_error $? "linking guile version ${guile_version} test program failed
11009 See \`config.log' for more details" "$LINENO" 5; }
11010 fi
11011 fi
11012 fi
11013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11014 $as_echo "${found_usable_guile}" >&6; }
11015
11016 else
11017 as_fn_error $? "Guile config program not executable: ${with_guile}" "$LINENO" 5
11018 fi
11019 ;;
11020 "" | */*)
11021 # Disallow --with=guile="" and --with-guile=foo/bar.
11022 as_fn_error $? "invalid value for --with-guile" "$LINENO" 5
11023 ;;
11024 *)
11025 # A space separate list of guile versions to try, in order.
11026 if test "${pkg_config_prog_path}" = "missing"; then
11027 as_fn_error $? "pkg-config not found" "$LINENO" 5
11028 fi
11029
11030 pkg_config=${pkg_config_prog_path}
11031 guile_version_list=${with_guile}
11032 flag_errors=yes
11033
11034 found_usable_guile=checking
11035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11036 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11037 for guile_version in ${guile_version_list}; do
11038 ${pkg_config} --exists ${guile_version} 2>/dev/null
11039 if test $? != 0; then
11040 continue
11041 fi
11042 new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11043 if test $? != 0; then
11044 as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11045 fi
11046 new_LIBS=`${pkg_config} --libs ${guile_version}`
11047 if test $? != 0; then
11048 as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11049 fi
11050 found_usable_guile=${guile_version}
11051 break
11052 done
11053 if test "${found_usable_guile}" = "checking"; then
11054 if test "${flag_errors}" = "yes"; then
11055 as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11056 else
11057 found_usable_guile=no
11058 fi
11059 fi
11060 if test "${found_usable_guile}" != no; then
11061 save_CPPFLAGS=$CPPFLAGS
11062 save_LIBS=$LIBS
11063 CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11064 LIBS="$LIBS $new_LIBS"
11065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11066 /* end confdefs.h. */
11067 #include "libguile.h"
11068 int
11069 main ()
11070 {
11071 scm_init_guile ();
11072 ;
11073 return 0;
11074 }
11075 _ACEOF
11076 if ac_fn_c_try_link "$LINENO"; then :
11077 have_libguile=yes
11078 GUILE_CPPFLAGS=$new_CPPFLAGS
11079 GUILE_LIBS=$new_LIBS
11080 else
11081 found_usable_guile=no
11082 fi
11083 rm -f core conftest.err conftest.$ac_objext \
11084 conftest$ac_exeext conftest.$ac_ext
11085 ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11086 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11087
11088 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11089
11090
11091 fi
11092
11093 CPPFLAGS=$save_CPPFLAGS
11094 LIBS=$save_LIBS
11095 if test "${found_usable_guile}" = no; then
11096 if test "${flag_errors}" = yes; then
11097 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11098 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11099 as_fn_error $? "linking guile version ${guile_version} test program failed
11100 See \`config.log' for more details" "$LINENO" 5; }
11101 fi
11102 fi
11103 fi
11104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11105 $as_echo "${found_usable_guile}" >&6; }
11106
11107 ;;
11108 esac
11109
11110 if test "${have_libguile}" != no; then
11111 case "${with_guile}" in
11112 [\\/]* | ?:[\\/]*)
11113
11114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11115 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11116 if ${ac_cv_guild_program_name+:} false; then :
11117 $as_echo_n "(cached) " >&6
11118 else
11119 ac_cv_guild_program_name="`"${with_guile}" --variable guild "${guile_version}"`"
11120
11121 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11122 # the 'guild' and 'bindir' variables. In that case, try to guess
11123 # what the program name is, at the risk of getting it wrong if
11124 # Guile was configured with '--program-suffix' or similar.
11125 if test "x$ac_cv_guild_program_name" = "x"; then
11126 guile_exec_prefix="`"${with_guile}" --variable exec_prefix "${guile_version}"`"
11127 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11128 fi
11129
11130 fi
11131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11132 $as_echo "$ac_cv_guild_program_name" >&6; }
11133
11134 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11135 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11136 fi
11137
11138 GUILD="$ac_cv_guild_program_name"
11139
11140
11141 ;;
11142 *)
11143
11144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11145 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11146 if ${ac_cv_guild_program_name+:} false; then :
11147 $as_echo_n "(cached) " >&6
11148 else
11149 ac_cv_guild_program_name="`"${pkg_config_prog_path}" --variable guild "${guile_version}"`"
11150
11151 # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11152 # the 'guild' and 'bindir' variables. In that case, try to guess
11153 # what the program name is, at the risk of getting it wrong if
11154 # Guile was configured with '--program-suffix' or similar.
11155 if test "x$ac_cv_guild_program_name" = "x"; then
11156 guile_exec_prefix="`"${pkg_config_prog_path}" --variable exec_prefix "${guile_version}"`"
11157 ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11158 fi
11159
11160 fi
11161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11162 $as_echo "$ac_cv_guild_program_name" >&6; }
11163
11164 if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11165 as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11166 fi
11167
11168 GUILD="$ac_cv_guild_program_name"
11169
11170
11171 ;;
11172 esac
11173
11174
11175 if test "$cross_compiling" = no; then
11176 GUILD_TARGET_FLAG=
11177 else
11178 GUILD_TARGET_FLAG="--target=$host"
11179 fi
11180
11181
11182
11183
11184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether guild supports this host" >&5
11185 $as_echo_n "checking whether guild supports this host... " >&6; }
11186 if ${ac_cv_guild_ok+:} false; then :
11187 $as_echo_n "(cached) " >&6
11188 else
11189 echo "$ac_cv_guild_program_name compile $GUILD_TARGET_FLAG -o conftest.go $srcdir/guile/lib/gdb/support.scm" >&5
11190 if "$ac_cv_guild_program_name" compile $GUILD_TARGET_FLAG -o conftest.go "$srcdir/guile/lib/gdb/support.scm" >&5 2>&5; then
11191 ac_cv_guild_ok=yes
11192 else
11193 ac_cv_guild_ok=no
11194 fi
11195 fi
11196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_ok" >&5
11197 $as_echo "$ac_cv_guild_ok" >&6; }
11198
11199 if test "$ac_cv_guild_ok" = no; then
11200 have_libguile=no
11201 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling guile support" >&5
11202 $as_echo "$as_me: WARNING: disabling guile support" >&2;}
11203 fi
11204 fi
11205
11206 if test "${have_libguile}" != no; then
11207
11208 $as_echo "#define HAVE_GUILE 1" >>confdefs.h
11209
11210 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_GUILE_OBS)"
11211 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_GUILE_DEPS)"
11212 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_GUILE_SRCS)"
11213 CONFIG_INSTALL="$CONFIG_INSTALL install-guile"
11214 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_GUILE_CFLAGS)"
11215
11216 save_LIBS="$LIBS"
11217 save_CPPFLAGS="$CPPFLAGS"
11218 LIBS="$GUILE_LIBS"
11219 CPPFLAGS="$GUILE_CPPFLAGS"
11220 for ac_func in scm_new_smob
11221 do :
11222 ac_fn_c_check_func "$LINENO" "scm_new_smob" "ac_cv_func_scm_new_smob"
11223 if test "x$ac_cv_func_scm_new_smob" = xyes; then :
11224 cat >>confdefs.h <<_ACEOF
11225 #define HAVE_SCM_NEW_SMOB 1
11226 _ACEOF
11227
11228 fi
11229 done
11230
11231 LIBS="$save_LIBS"
11232 CPPFLAGS="$save_CPPFLAGS"
11233 else
11234 # Even if Guile support is not compiled in, we need to have these files
11235 # included.
11236 CONFIG_OBS="$CONFIG_OBS guile/guile.o"
11237 CONFIG_SRCS="$CONFIG_SRCS guile/guile.c"
11238 fi
11239
11240
11241 if test "${have_libguile}" != no; then
11242 HAVE_GUILE_TRUE=
11243 HAVE_GUILE_FALSE='#'
11244 else
11245 HAVE_GUILE_TRUE='#'
11246 HAVE_GUILE_FALSE=
11247 fi
11248
11249
11250 # ---------------------------- #
11251 # Check for source highlight. #
11252 # ---------------------------- #
11253
11254 SRCHIGH_LIBS=
11255 SRCHIGH_CFLAGS=
11256
11257 # Check whether --enable-source-highlight was given.
11258 if test "${enable_source_highlight+set}" = set; then :
11259 enableval=$enable_source_highlight; case "${enableval}" in
11260 yes) enable_source_highlight=yes ;;
11261 no) enable_source_highlight=no ;;
11262 *) as_fn_error $? "bad value ${enableval} for source-highlight option" "$LINENO" 5 ;;
11263 esac
11264 else
11265 enable_source_highlight=auto
11266 fi
11267
11268
11269 if test "${enable_source_highlight}" != "no"; then
11270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the source-highlight library" >&5
11271 $as_echo_n "checking for the source-highlight library... " >&6; }
11272 if test "${pkg_config_prog_path}" = "missing"; then
11273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - pkg-config not found" >&5
11274 $as_echo "no - pkg-config not found" >&6; }
11275 if test "${enable_source_highlight}" = "yes"; then
11276 as_fn_error $? "pkg-config was not found in your system" "$LINENO" 5
11277 fi
11278 else
11279 case "$LDFLAGS" in
11280 *static-libstdc*)
11281 as_fn_error $? "source highlight is incompatible with -static-libstdc++; either use --disable-source-highlight or --without-static-standard-libraries" "$LINENO" 5
11282 ;;
11283 esac
11284
11285 if ${pkg_config_prog_path} --exists source-highlight; then
11286 SRCHIGH_CFLAGS=`${pkg_config_prog_path} --cflags source-highlight`
11287 SRCHIGH_LIBS=`${pkg_config_prog_path} --libs source-highlight`
11288
11289 $as_echo "#define HAVE_SOURCE_HIGHLIGHT 1" >>confdefs.h
11290
11291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11292 $as_echo "yes" >&6; }
11293 else
11294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11295 $as_echo "no" >&6; }
11296 if test "${enable_source_highlight}" = "yes"; then
11297 as_fn_error $? "source-highlight was not found in your system" "$LINENO" 5
11298 fi
11299 fi
11300 fi
11301 fi
11302
11303
11304
11305
11306 # Check whether --with-intel_pt was given.
11307 if test "${with_intel_pt+set}" = set; then :
11308 withval=$with_intel_pt;
11309 else
11310 with_intel_pt=auto
11311 fi
11312
11313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
11314 $as_echo_n "checking whether to use intel pt... " >&6; }
11315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
11316 $as_echo "$with_intel_pt" >&6; }
11317
11318 if test "${with_intel_pt}" = no; then
11319 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
11320 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
11321 HAVE_LIBIPT=no
11322 else
11323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11324 /* end confdefs.h. */
11325
11326 #include <linux/perf_event.h>
11327 #ifndef PERF_ATTR_SIZE_VER5
11328 # error
11329 #endif
11330
11331 _ACEOF
11332 if ac_fn_c_try_cpp "$LINENO"; then :
11333 perf_event=yes
11334 else
11335 perf_event=no
11336 fi
11337 rm -f conftest.err conftest.i conftest.$ac_ext
11338 if test "$perf_event" != yes; then
11339 if test "$with_intel_pt" = yes; then
11340 as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
11341 else
11342 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
11343 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
11344 fi
11345 fi
11346
11347
11348
11349
11350
11351
11352
11353
11354
11355 use_additional=yes
11356
11357 acl_save_prefix="$prefix"
11358 prefix="$acl_final_prefix"
11359 acl_save_exec_prefix="$exec_prefix"
11360 exec_prefix="$acl_final_exec_prefix"
11361
11362 eval additional_includedir=\"$includedir\"
11363 eval additional_libdir=\"$libdir\"
11364
11365 exec_prefix="$acl_save_exec_prefix"
11366 prefix="$acl_save_prefix"
11367
11368
11369 # Check whether --with-libipt-prefix was given.
11370 if test "${with_libipt_prefix+set}" = set; then :
11371 withval=$with_libipt_prefix;
11372 if test "X$withval" = "Xno"; then
11373 use_additional=no
11374 else
11375 if test "X$withval" = "X"; then
11376
11377 acl_save_prefix="$prefix"
11378 prefix="$acl_final_prefix"
11379 acl_save_exec_prefix="$exec_prefix"
11380 exec_prefix="$acl_final_exec_prefix"
11381
11382 eval additional_includedir=\"$includedir\"
11383 eval additional_libdir=\"$libdir\"
11384
11385 exec_prefix="$acl_save_exec_prefix"
11386 prefix="$acl_save_prefix"
11387
11388 else
11389 additional_includedir="$withval/include"
11390 additional_libdir="$withval/lib"
11391 fi
11392 fi
11393
11394 fi
11395
11396 LIBIPT=
11397 LTLIBIPT=
11398 INCIPT=
11399 rpathdirs=
11400 ltrpathdirs=
11401 names_already_handled=
11402 names_next_round='ipt '
11403 while test -n "$names_next_round"; do
11404 names_this_round="$names_next_round"
11405 names_next_round=
11406 for name in $names_this_round; do
11407 already_handled=
11408 for n in $names_already_handled; do
11409 if test "$n" = "$name"; then
11410 already_handled=yes
11411 break
11412 fi
11413 done
11414 if test -z "$already_handled"; then
11415 names_already_handled="$names_already_handled $name"
11416 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
11417 eval value=\"\$HAVE_LIB$uppername\"
11418 if test -n "$value"; then
11419 if test "$value" = yes; then
11420 eval value=\"\$LIB$uppername\"
11421 test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
11422 eval value=\"\$LTLIB$uppername\"
11423 test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
11424 else
11425 :
11426 fi
11427 else
11428 found_dir=
11429 found_la=
11430 found_so=
11431 found_a=
11432 if test $use_additional = yes; then
11433 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
11434 found_dir="$additional_libdir"
11435 found_so="$additional_libdir/lib$name.$shlibext"
11436 if test -f "$additional_libdir/lib$name.la"; then
11437 found_la="$additional_libdir/lib$name.la"
11438 fi
11439 else
11440 if test -f "$additional_libdir/lib$name.$libext"; then
11441 found_dir="$additional_libdir"
11442 found_a="$additional_libdir/lib$name.$libext"
11443 if test -f "$additional_libdir/lib$name.la"; then
11444 found_la="$additional_libdir/lib$name.la"
11445 fi
11446 fi
11447 fi
11448 fi
11449 if test "X$found_dir" = "X"; then
11450 for x in $LDFLAGS $LTLIBIPT; do
11451
11452 acl_save_prefix="$prefix"
11453 prefix="$acl_final_prefix"
11454 acl_save_exec_prefix="$exec_prefix"
11455 exec_prefix="$acl_final_exec_prefix"
11456 eval x=\"$x\"
11457 exec_prefix="$acl_save_exec_prefix"
11458 prefix="$acl_save_prefix"
11459
11460 case "$x" in
11461 -L*)
11462 dir=`echo "X$x" | sed -e 's/^X-L//'`
11463 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
11464 found_dir="$dir"
11465 found_so="$dir/lib$name.$shlibext"
11466 if test -f "$dir/lib$name.la"; then
11467 found_la="$dir/lib$name.la"
11468 fi
11469 else
11470 if test -f "$dir/lib$name.$libext"; then
11471 found_dir="$dir"
11472 found_a="$dir/lib$name.$libext"
11473 if test -f "$dir/lib$name.la"; then
11474 found_la="$dir/lib$name.la"
11475 fi
11476 fi
11477 fi
11478 ;;
11479 esac
11480 if test "X$found_dir" != "X"; then
11481 break
11482 fi
11483 done
11484 fi
11485 if test "X$found_dir" != "X"; then
11486 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
11487 if test "X$found_so" != "X"; then
11488 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11489 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11490 else
11491 haveit=
11492 for x in $ltrpathdirs; do
11493 if test "X$x" = "X$found_dir"; then
11494 haveit=yes
11495 break
11496 fi
11497 done
11498 if test -z "$haveit"; then
11499 ltrpathdirs="$ltrpathdirs $found_dir"
11500 fi
11501 if test "$hardcode_direct" = yes; then
11502 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11503 else
11504 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11505 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11506 haveit=
11507 for x in $rpathdirs; do
11508 if test "X$x" = "X$found_dir"; then
11509 haveit=yes
11510 break
11511 fi
11512 done
11513 if test -z "$haveit"; then
11514 rpathdirs="$rpathdirs $found_dir"
11515 fi
11516 else
11517 haveit=
11518 for x in $LDFLAGS $LIBIPT; do
11519
11520 acl_save_prefix="$prefix"
11521 prefix="$acl_final_prefix"
11522 acl_save_exec_prefix="$exec_prefix"
11523 exec_prefix="$acl_final_exec_prefix"
11524 eval x=\"$x\"
11525 exec_prefix="$acl_save_exec_prefix"
11526 prefix="$acl_save_prefix"
11527
11528 if test "X$x" = "X-L$found_dir"; then
11529 haveit=yes
11530 break
11531 fi
11532 done
11533 if test -z "$haveit"; then
11534 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
11535 fi
11536 if test "$hardcode_minus_L" != no; then
11537 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11538 else
11539 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
11540 fi
11541 fi
11542 fi
11543 fi
11544 else
11545 if test "X$found_a" != "X"; then
11546 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
11547 else
11548 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
11549 fi
11550 fi
11551 additional_includedir=
11552 case "$found_dir" in
11553 */lib | */lib/)
11554 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11555 additional_includedir="$basedir/include"
11556 ;;
11557 esac
11558 if test "X$additional_includedir" != "X"; then
11559 if test "X$additional_includedir" != "X/usr/include"; then
11560 haveit=
11561 if test "X$additional_includedir" = "X/usr/local/include"; then
11562 if test -n "$GCC"; then
11563 case $host_os in
11564 linux*) haveit=yes;;
11565 esac
11566 fi
11567 fi
11568 if test -z "$haveit"; then
11569 for x in $CPPFLAGS $INCIPT; do
11570
11571 acl_save_prefix="$prefix"
11572 prefix="$acl_final_prefix"
11573 acl_save_exec_prefix="$exec_prefix"
11574 exec_prefix="$acl_final_exec_prefix"
11575 eval x=\"$x\"
11576 exec_prefix="$acl_save_exec_prefix"
11577 prefix="$acl_save_prefix"
11578
11579 if test "X$x" = "X-I$additional_includedir"; then
11580 haveit=yes
11581 break
11582 fi
11583 done
11584 if test -z "$haveit"; then
11585 if test -d "$additional_includedir"; then
11586 INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
11587 fi
11588 fi
11589 fi
11590 fi
11591 fi
11592 if test -n "$found_la"; then
11593 save_libdir="$libdir"
11594 case "$found_la" in
11595 */* | *\\*) . "$found_la" ;;
11596 *) . "./$found_la" ;;
11597 esac
11598 libdir="$save_libdir"
11599 for dep in $dependency_libs; do
11600 case "$dep" in
11601 -L*)
11602 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11603 if test "X$additional_libdir" != "X/usr/lib"; then
11604 haveit=
11605 if test "X$additional_libdir" = "X/usr/local/lib"; then
11606 if test -n "$GCC"; then
11607 case $host_os in
11608 linux*) haveit=yes;;
11609 esac
11610 fi
11611 fi
11612 if test -z "$haveit"; then
11613 haveit=
11614 for x in $LDFLAGS $LIBIPT; do
11615
11616 acl_save_prefix="$prefix"
11617 prefix="$acl_final_prefix"
11618 acl_save_exec_prefix="$exec_prefix"
11619 exec_prefix="$acl_final_exec_prefix"
11620 eval x=\"$x\"
11621 exec_prefix="$acl_save_exec_prefix"
11622 prefix="$acl_save_prefix"
11623
11624 if test "X$x" = "X-L$additional_libdir"; then
11625 haveit=yes
11626 break
11627 fi
11628 done
11629 if test -z "$haveit"; then
11630 if test -d "$additional_libdir"; then
11631 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
11632 fi
11633 fi
11634 haveit=
11635 for x in $LDFLAGS $LTLIBIPT; do
11636
11637 acl_save_prefix="$prefix"
11638 prefix="$acl_final_prefix"
11639 acl_save_exec_prefix="$exec_prefix"
11640 exec_prefix="$acl_final_exec_prefix"
11641 eval x=\"$x\"
11642 exec_prefix="$acl_save_exec_prefix"
11643 prefix="$acl_save_prefix"
11644
11645 if test "X$x" = "X-L$additional_libdir"; then
11646 haveit=yes
11647 break
11648 fi
11649 done
11650 if test -z "$haveit"; then
11651 if test -d "$additional_libdir"; then
11652 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
11653 fi
11654 fi
11655 fi
11656 fi
11657 ;;
11658 -R*)
11659 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11660 if test "$enable_rpath" != no; then
11661 haveit=
11662 for x in $rpathdirs; do
11663 if test "X$x" = "X$dir"; then
11664 haveit=yes
11665 break
11666 fi
11667 done
11668 if test -z "$haveit"; then
11669 rpathdirs="$rpathdirs $dir"
11670 fi
11671 haveit=
11672 for x in $ltrpathdirs; do
11673 if test "X$x" = "X$dir"; then
11674 haveit=yes
11675 break
11676 fi
11677 done
11678 if test -z "$haveit"; then
11679 ltrpathdirs="$ltrpathdirs $dir"
11680 fi
11681 fi
11682 ;;
11683 -l*)
11684 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11685 ;;
11686 *.la)
11687 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11688 ;;
11689 *)
11690 LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
11691 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
11692 ;;
11693 esac
11694 done
11695 fi
11696 else
11697 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
11698 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
11699 fi
11700 fi
11701 fi
11702 done
11703 done
11704 if test "X$rpathdirs" != "X"; then
11705 if test -n "$hardcode_libdir_separator"; then
11706 alldirs=
11707 for found_dir in $rpathdirs; do
11708 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11709 done
11710 acl_save_libdir="$libdir"
11711 libdir="$alldirs"
11712 eval flag=\"$hardcode_libdir_flag_spec\"
11713 libdir="$acl_save_libdir"
11714 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
11715 else
11716 for found_dir in $rpathdirs; do
11717 acl_save_libdir="$libdir"
11718 libdir="$found_dir"
11719 eval flag=\"$hardcode_libdir_flag_spec\"
11720 libdir="$acl_save_libdir"
11721 LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
11722 done
11723 fi
11724 fi
11725 if test "X$ltrpathdirs" != "X"; then
11726 for found_dir in $ltrpathdirs; do
11727 LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
11728 done
11729 fi
11730
11731
11732 ac_save_CPPFLAGS="$CPPFLAGS"
11733
11734 for element in $INCIPT; do
11735 haveit=
11736 for x in $CPPFLAGS; do
11737
11738 acl_save_prefix="$prefix"
11739 prefix="$acl_final_prefix"
11740 acl_save_exec_prefix="$exec_prefix"
11741 exec_prefix="$acl_final_exec_prefix"
11742 eval x=\"$x\"
11743 exec_prefix="$acl_save_exec_prefix"
11744 prefix="$acl_save_prefix"
11745
11746 if test "X$x" = "X$element"; then
11747 haveit=yes
11748 break
11749 fi
11750 done
11751 if test -z "$haveit"; then
11752 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11753 fi
11754 done
11755
11756
11757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
11758 $as_echo_n "checking for libipt... " >&6; }
11759 if ${ac_cv_libipt+:} false; then :
11760 $as_echo_n "(cached) " >&6
11761 else
11762
11763 ac_save_LIBS="$LIBS"
11764 LIBS="$LIBS $LIBIPT"
11765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11766 /* end confdefs.h. */
11767 #include "intel-pt.h"
11768 int
11769 main ()
11770 {
11771 pt_insn_alloc_decoder (0);
11772 ;
11773 return 0;
11774 }
11775 _ACEOF
11776 if ac_fn_c_try_link "$LINENO"; then :
11777 ac_cv_libipt=yes
11778 else
11779 ac_cv_libipt=no
11780 fi
11781 rm -f core conftest.err conftest.$ac_objext \
11782 conftest$ac_exeext conftest.$ac_ext
11783 LIBS="$ac_save_LIBS"
11784
11785 fi
11786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
11787 $as_echo "$ac_cv_libipt" >&6; }
11788 if test "$ac_cv_libipt" = yes; then
11789 HAVE_LIBIPT=yes
11790
11791 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
11792
11793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
11794 $as_echo_n "checking how to link with libipt... " >&6; }
11795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
11796 $as_echo "$LIBIPT" >&6; }
11797 else
11798 HAVE_LIBIPT=no
11799 CPPFLAGS="$ac_save_CPPFLAGS"
11800 LIBIPT=
11801 LTLIBIPT=
11802 fi
11803
11804
11805
11806
11807
11808
11809 if test "$HAVE_LIBIPT" != yes; then
11810 if test "$with_intel_pt" = yes; then
11811 as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
11812 else
11813 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
11814 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
11815 fi
11816 else
11817 save_LIBS=$LIBS
11818 LIBS="$LIBS $LIBIPT"
11819 for ac_func in pt_insn_event
11820 do :
11821 ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
11822 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
11823 cat >>confdefs.h <<_ACEOF
11824 #define HAVE_PT_INSN_EVENT 1
11825 _ACEOF
11826
11827 fi
11828 done
11829
11830 ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
11831 "
11832 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
11833
11834 cat >>confdefs.h <<_ACEOF
11835 #define HAVE_STRUCT_PT_INSN_ENABLED 1
11836 _ACEOF
11837
11838
11839 fi
11840 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
11841 "
11842 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
11843
11844 cat >>confdefs.h <<_ACEOF
11845 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
11846 _ACEOF
11847
11848
11849 fi
11850
11851 LIBS=$save_LIBS
11852 fi
11853 fi
11854
11855 # ------------------------- #
11856 # Checks for header files. #
11857 # ------------------------- #
11858
11859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
11860 $as_echo_n "checking for ANSI C header files... " >&6; }
11861 if ${ac_cv_header_stdc+:} false; then :
11862 $as_echo_n "(cached) " >&6
11863 else
11864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11865 /* end confdefs.h. */
11866 #include <stdlib.h>
11867 #include <stdarg.h>
11868 #include <string.h>
11869 #include <float.h>
11870
11871 int
11872 main ()
11873 {
11874
11875 ;
11876 return 0;
11877 }
11878 _ACEOF
11879 if ac_fn_c_try_compile "$LINENO"; then :
11880 ac_cv_header_stdc=yes
11881 else
11882 ac_cv_header_stdc=no
11883 fi
11884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11885
11886 if test $ac_cv_header_stdc = yes; then
11887 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
11888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11889 /* end confdefs.h. */
11890 #include <string.h>
11891
11892 _ACEOF
11893 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11894 $EGREP "memchr" >/dev/null 2>&1; then :
11895
11896 else
11897 ac_cv_header_stdc=no
11898 fi
11899 rm -f conftest*
11900
11901 fi
11902
11903 if test $ac_cv_header_stdc = yes; then
11904 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
11905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11906 /* end confdefs.h. */
11907 #include <stdlib.h>
11908
11909 _ACEOF
11910 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11911 $EGREP "free" >/dev/null 2>&1; then :
11912
11913 else
11914 ac_cv_header_stdc=no
11915 fi
11916 rm -f conftest*
11917
11918 fi
11919
11920 if test $ac_cv_header_stdc = yes; then
11921 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
11922 if test "$cross_compiling" = yes; then :
11923 :
11924 else
11925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11926 /* end confdefs.h. */
11927 #include <ctype.h>
11928 #include <stdlib.h>
11929 #if ((' ' & 0x0FF) == 0x020)
11930 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
11931 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
11932 #else
11933 # define ISLOWER(c) \
11934 (('a' <= (c) && (c) <= 'i') \
11935 || ('j' <= (c) && (c) <= 'r') \
11936 || ('s' <= (c) && (c) <= 'z'))
11937 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
11938 #endif
11939
11940 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
11941 int
11942 main ()
11943 {
11944 int i;
11945 for (i = 0; i < 256; i++)
11946 if (XOR (islower (i), ISLOWER (i))
11947 || toupper (i) != TOUPPER (i))
11948 return 2;
11949 return 0;
11950 }
11951 _ACEOF
11952 if ac_fn_c_try_run "$LINENO"; then :
11953
11954 else
11955 ac_cv_header_stdc=no
11956 fi
11957 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11958 conftest.$ac_objext conftest.beam conftest.$ac_ext
11959 fi
11960
11961 fi
11962 fi
11963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
11964 $as_echo "$ac_cv_header_stdc" >&6; }
11965 if test $ac_cv_header_stdc = yes; then
11966
11967 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
11968
11969 fi
11970
11971 # elf_hp.h is for HP/UX 64-bit shared library support.
11972 for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
11973 thread_db.h linux/elf.h \
11974 sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
11975 sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
11976 sys/reg.h sys/debugreg.h sys/select.h \
11977 termios.h elf_hp.h
11978 do :
11979 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11980 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
11981 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
11982 cat >>confdefs.h <<_ACEOF
11983 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11984 _ACEOF
11985
11986 fi
11987
11988 done
11989
11990 for ac_header in sys/user.h
11991 do :
11992 ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
11993 # include <sys/param.h>
11994 #endif
11995
11996 "
11997 if test "x$ac_cv_header_sys_user_h" = xyes; then :
11998 cat >>confdefs.h <<_ACEOF
11999 #define HAVE_SYS_USER_H 1
12000 _ACEOF
12001
12002 fi
12003
12004 done
12005
12006
12007 for ac_header in curses.h cursesX.h ncurses.h ncursesw/ncurses.h ncurses/ncurses.h ncurses/term.h
12008 do :
12009 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12010 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12011 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12012 cat >>confdefs.h <<_ACEOF
12013 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12014 _ACEOF
12015
12016 fi
12017
12018 done
12019
12020 for ac_header in term.h
12021 do :
12022 ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
12023 # include <curses.h>
12024 #endif
12025
12026 "
12027 if test "x$ac_cv_header_term_h" = xyes; then :
12028 cat >>confdefs.h <<_ACEOF
12029 #define HAVE_TERM_H 1
12030 _ACEOF
12031
12032 fi
12033
12034 done
12035
12036
12037 # ------------------------- #
12038 # Checks for declarations. #
12039 # ------------------------- #
12040
12041
12042 # Check for presence and size of long long.
12043 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
12044 if test "x$ac_cv_type_long_long" = xyes; then :
12045
12046 cat >>confdefs.h <<_ACEOF
12047 #define HAVE_LONG_LONG 1
12048 _ACEOF
12049
12050 # The cast to long int works around a bug in the HP C Compiler
12051 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12052 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12053 # This bug is HP SR number 8606223364.
12054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
12055 $as_echo_n "checking size of long long... " >&6; }
12056 if ${ac_cv_sizeof_long_long+:} false; then :
12057 $as_echo_n "(cached) " >&6
12058 else
12059 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
12060
12061 else
12062 if test "$ac_cv_type_long_long" = yes; then
12063 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12064 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12065 as_fn_error 77 "cannot compute sizeof (long long)
12066 See \`config.log' for more details" "$LINENO" 5; }
12067 else
12068 ac_cv_sizeof_long_long=0
12069 fi
12070 fi
12071
12072 fi
12073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
12074 $as_echo "$ac_cv_sizeof_long_long" >&6; }
12075
12076
12077
12078 cat >>confdefs.h <<_ACEOF
12079 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
12080 _ACEOF
12081
12082
12083 fi
12084
12085
12086 as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
12087 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
12088 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
12089 ac_have_decl=1
12090 else
12091 ac_have_decl=0
12092 fi
12093
12094 cat >>confdefs.h <<_ACEOF
12095 #define HAVE_DECL_BASENAME $ac_have_decl
12096 _ACEOF
12097 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
12098 if test "x$ac_cv_have_decl_ffs" = xyes; then :
12099 ac_have_decl=1
12100 else
12101 ac_have_decl=0
12102 fi
12103
12104 cat >>confdefs.h <<_ACEOF
12105 #define HAVE_DECL_FFS $ac_have_decl
12106 _ACEOF
12107 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
12108 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
12109 ac_have_decl=1
12110 else
12111 ac_have_decl=0
12112 fi
12113
12114 cat >>confdefs.h <<_ACEOF
12115 #define HAVE_DECL_ASPRINTF $ac_have_decl
12116 _ACEOF
12117 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
12118 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
12119 ac_have_decl=1
12120 else
12121 ac_have_decl=0
12122 fi
12123
12124 cat >>confdefs.h <<_ACEOF
12125 #define HAVE_DECL_VASPRINTF $ac_have_decl
12126 _ACEOF
12127 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12128 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12129 ac_have_decl=1
12130 else
12131 ac_have_decl=0
12132 fi
12133
12134 cat >>confdefs.h <<_ACEOF
12135 #define HAVE_DECL_SNPRINTF $ac_have_decl
12136 _ACEOF
12137 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
12138 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
12139 ac_have_decl=1
12140 else
12141 ac_have_decl=0
12142 fi
12143
12144 cat >>confdefs.h <<_ACEOF
12145 #define HAVE_DECL_VSNPRINTF $ac_have_decl
12146 _ACEOF
12147
12148 ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
12149 if test "x$ac_cv_have_decl_strtol" = xyes; then :
12150 ac_have_decl=1
12151 else
12152 ac_have_decl=0
12153 fi
12154
12155 cat >>confdefs.h <<_ACEOF
12156 #define HAVE_DECL_STRTOL $ac_have_decl
12157 _ACEOF
12158 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
12159 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
12160 ac_have_decl=1
12161 else
12162 ac_have_decl=0
12163 fi
12164
12165 cat >>confdefs.h <<_ACEOF
12166 #define HAVE_DECL_STRTOUL $ac_have_decl
12167 _ACEOF
12168 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
12169 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
12170 ac_have_decl=1
12171 else
12172 ac_have_decl=0
12173 fi
12174
12175 cat >>confdefs.h <<_ACEOF
12176 #define HAVE_DECL_STRTOLL $ac_have_decl
12177 _ACEOF
12178 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
12179 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
12180 ac_have_decl=1
12181 else
12182 ac_have_decl=0
12183 fi
12184
12185 cat >>confdefs.h <<_ACEOF
12186 #define HAVE_DECL_STRTOULL $ac_have_decl
12187 _ACEOF
12188
12189 ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
12190 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
12191 ac_have_decl=1
12192 else
12193 ac_have_decl=0
12194 fi
12195
12196 cat >>confdefs.h <<_ACEOF
12197 #define HAVE_DECL_STRVERSCMP $ac_have_decl
12198 _ACEOF
12199
12200
12201
12202 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12203 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12204 ac_have_decl=1
12205 else
12206 ac_have_decl=0
12207 fi
12208
12209 cat >>confdefs.h <<_ACEOF
12210 #define HAVE_DECL_SNPRINTF $ac_have_decl
12211 _ACEOF
12212
12213
12214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
12215 $as_echo_n "checking for LC_MESSAGES... " >&6; }
12216 if ${am_cv_val_LC_MESSAGES+:} false; then :
12217 $as_echo_n "(cached) " >&6
12218 else
12219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12220 /* end confdefs.h. */
12221 #include <locale.h>
12222 int
12223 main ()
12224 {
12225 return LC_MESSAGES
12226 ;
12227 return 0;
12228 }
12229 _ACEOF
12230 if ac_fn_c_try_link "$LINENO"; then :
12231 am_cv_val_LC_MESSAGES=yes
12232 else
12233 am_cv_val_LC_MESSAGES=no
12234 fi
12235 rm -f core conftest.err conftest.$ac_objext \
12236 conftest$ac_exeext conftest.$ac_ext
12237 fi
12238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
12239 $as_echo "$am_cv_val_LC_MESSAGES" >&6; }
12240 if test $am_cv_val_LC_MESSAGES = yes; then
12241
12242 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
12243
12244 fi
12245
12246
12247 # ----------------------- #
12248 # Checks for structures. #
12249 # ----------------------- #
12250
12251 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
12252 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
12253
12254 cat >>confdefs.h <<_ACEOF
12255 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
12256 _ACEOF
12257
12258
12259 fi
12260 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
12261 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
12262
12263 cat >>confdefs.h <<_ACEOF
12264 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
12265 _ACEOF
12266
12267
12268 fi
12269
12270
12271 # ------------------ #
12272 # Checks for types. #
12273 # ------------------ #
12274
12275 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
12276 #include <sys/socket.h>
12277
12278 "
12279 if test "x$ac_cv_type_socklen_t" = xyes; then :
12280
12281 cat >>confdefs.h <<_ACEOF
12282 #define HAVE_SOCKLEN_T 1
12283 _ACEOF
12284
12285
12286 fi
12287
12288
12289 # ------------------------------------- #
12290 # Checks for compiler characteristics. #
12291 # ------------------------------------- #
12292
12293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
12294 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
12295 if ${ac_cv_c_const+:} false; then :
12296 $as_echo_n "(cached) " >&6
12297 else
12298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12299 /* end confdefs.h. */
12300
12301 int
12302 main ()
12303 {
12304
12305 #ifndef __cplusplus
12306 /* Ultrix mips cc rejects this sort of thing. */
12307 typedef int charset[2];
12308 const charset cs = { 0, 0 };
12309 /* SunOS 4.1.1 cc rejects this. */
12310 char const *const *pcpcc;
12311 char **ppc;
12312 /* NEC SVR4.0.2 mips cc rejects this. */
12313 struct point {int x, y;};
12314 static struct point const zero = {0,0};
12315 /* AIX XL C 1.02.0.0 rejects this.
12316 It does not let you subtract one const X* pointer from another in
12317 an arm of an if-expression whose if-part is not a constant
12318 expression */
12319 const char *g = "string";
12320 pcpcc = &g + (g ? g-g : 0);
12321 /* HPUX 7.0 cc rejects these. */
12322 ++pcpcc;
12323 ppc = (char**) pcpcc;
12324 pcpcc = (char const *const *) ppc;
12325 { /* SCO 3.2v4 cc rejects this sort of thing. */
12326 char tx;
12327 char *t = &tx;
12328 char const *s = 0 ? (char *) 0 : (char const *) 0;
12329
12330 *t++ = 0;
12331 if (s) return 0;
12332 }
12333 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
12334 int x[] = {25, 17};
12335 const int *foo = &x[0];
12336 ++foo;
12337 }
12338 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
12339 typedef const int *iptr;
12340 iptr p = 0;
12341 ++p;
12342 }
12343 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
12344 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
12345 struct s { int j; const int *ap[3]; } bx;
12346 struct s *b = &bx; b->j = 5;
12347 }
12348 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
12349 const int foo = 10;
12350 if (!foo) return 0;
12351 }
12352 return !cs[0] && !zero.x;
12353 #endif
12354
12355 ;
12356 return 0;
12357 }
12358 _ACEOF
12359 if ac_fn_c_try_compile "$LINENO"; then :
12360 ac_cv_c_const=yes
12361 else
12362 ac_cv_c_const=no
12363 fi
12364 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12365 fi
12366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
12367 $as_echo "$ac_cv_c_const" >&6; }
12368 if test $ac_cv_c_const = no; then
12369
12370 $as_echo "#define const /**/" >>confdefs.h
12371
12372 fi
12373
12374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
12375 $as_echo_n "checking for inline... " >&6; }
12376 if ${ac_cv_c_inline+:} false; then :
12377 $as_echo_n "(cached) " >&6
12378 else
12379 ac_cv_c_inline=no
12380 for ac_kw in inline __inline__ __inline; do
12381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12382 /* end confdefs.h. */
12383 #ifndef __cplusplus
12384 typedef int foo_t;
12385 static $ac_kw foo_t static_foo () {return 0; }
12386 $ac_kw foo_t foo () {return 0; }
12387 #endif
12388
12389 _ACEOF
12390 if ac_fn_c_try_compile "$LINENO"; then :
12391 ac_cv_c_inline=$ac_kw
12392 fi
12393 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12394 test "$ac_cv_c_inline" != no && break
12395 done
12396
12397 fi
12398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
12399 $as_echo "$ac_cv_c_inline" >&6; }
12400
12401 case $ac_cv_c_inline in
12402 inline | yes) ;;
12403 *)
12404 case $ac_cv_c_inline in
12405 no) ac_val=;;
12406 *) ac_val=$ac_cv_c_inline;;
12407 esac
12408 cat >>confdefs.h <<_ACEOF
12409 #ifndef __cplusplus
12410 #define inline $ac_val
12411 #endif
12412 _ACEOF
12413 ;;
12414 esac
12415
12416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
12417 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
12418 if ${ac_cv_c_bigendian+:} false; then :
12419 $as_echo_n "(cached) " >&6
12420 else
12421 ac_cv_c_bigendian=unknown
12422 # See if we're dealing with a universal compiler.
12423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12424 /* end confdefs.h. */
12425 #ifndef __APPLE_CC__
12426 not a universal capable compiler
12427 #endif
12428 typedef int dummy;
12429
12430 _ACEOF
12431 if ac_fn_c_try_compile "$LINENO"; then :
12432
12433 # Check for potential -arch flags. It is not universal unless
12434 # there are at least two -arch flags with different values.
12435 ac_arch=
12436 ac_prev=
12437 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
12438 if test -n "$ac_prev"; then
12439 case $ac_word in
12440 i?86 | x86_64 | ppc | ppc64)
12441 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
12442 ac_arch=$ac_word
12443 else
12444 ac_cv_c_bigendian=universal
12445 break
12446 fi
12447 ;;
12448 esac
12449 ac_prev=
12450 elif test "x$ac_word" = "x-arch"; then
12451 ac_prev=arch
12452 fi
12453 done
12454 fi
12455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12456 if test $ac_cv_c_bigendian = unknown; then
12457 # See if sys/param.h defines the BYTE_ORDER macro.
12458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12459 /* end confdefs.h. */
12460 #include <sys/types.h>
12461 #include <sys/param.h>
12462
12463 int
12464 main ()
12465 {
12466 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
12467 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
12468 && LITTLE_ENDIAN)
12469 bogus endian macros
12470 #endif
12471
12472 ;
12473 return 0;
12474 }
12475 _ACEOF
12476 if ac_fn_c_try_compile "$LINENO"; then :
12477 # It does; now see whether it defined to BIG_ENDIAN or not.
12478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12479 /* end confdefs.h. */
12480 #include <sys/types.h>
12481 #include <sys/param.h>
12482
12483 int
12484 main ()
12485 {
12486 #if BYTE_ORDER != BIG_ENDIAN
12487 not big endian
12488 #endif
12489
12490 ;
12491 return 0;
12492 }
12493 _ACEOF
12494 if ac_fn_c_try_compile "$LINENO"; then :
12495 ac_cv_c_bigendian=yes
12496 else
12497 ac_cv_c_bigendian=no
12498 fi
12499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12500 fi
12501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12502 fi
12503 if test $ac_cv_c_bigendian = unknown; then
12504 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
12505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12506 /* end confdefs.h. */
12507 #include <limits.h>
12508
12509 int
12510 main ()
12511 {
12512 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
12513 bogus endian macros
12514 #endif
12515
12516 ;
12517 return 0;
12518 }
12519 _ACEOF
12520 if ac_fn_c_try_compile "$LINENO"; then :
12521 # It does; now see whether it defined to _BIG_ENDIAN or not.
12522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12523 /* end confdefs.h. */
12524 #include <limits.h>
12525
12526 int
12527 main ()
12528 {
12529 #ifndef _BIG_ENDIAN
12530 not big endian
12531 #endif
12532
12533 ;
12534 return 0;
12535 }
12536 _ACEOF
12537 if ac_fn_c_try_compile "$LINENO"; then :
12538 ac_cv_c_bigendian=yes
12539 else
12540 ac_cv_c_bigendian=no
12541 fi
12542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12543 fi
12544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12545 fi
12546 if test $ac_cv_c_bigendian = unknown; then
12547 # Compile a test program.
12548 if test "$cross_compiling" = yes; then :
12549 # Try to guess by grepping values from an object file.
12550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12551 /* end confdefs.h. */
12552 short int ascii_mm[] =
12553 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
12554 short int ascii_ii[] =
12555 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12556 int use_ascii (int i) {
12557 return ascii_mm[i] + ascii_ii[i];
12558 }
12559 short int ebcdic_ii[] =
12560 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
12561 short int ebcdic_mm[] =
12562 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12563 int use_ebcdic (int i) {
12564 return ebcdic_mm[i] + ebcdic_ii[i];
12565 }
12566 extern int foo;
12567
12568 int
12569 main ()
12570 {
12571 return use_ascii (foo) == use_ebcdic (foo);
12572 ;
12573 return 0;
12574 }
12575 _ACEOF
12576 if ac_fn_c_try_compile "$LINENO"; then :
12577 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
12578 ac_cv_c_bigendian=yes
12579 fi
12580 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12581 if test "$ac_cv_c_bigendian" = unknown; then
12582 ac_cv_c_bigendian=no
12583 else
12584 # finding both strings is unlikely to happen, but who knows?
12585 ac_cv_c_bigendian=unknown
12586 fi
12587 fi
12588 fi
12589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12590 else
12591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12592 /* end confdefs.h. */
12593 $ac_includes_default
12594 int
12595 main ()
12596 {
12597
12598 /* Are we little or big endian? From Harbison&Steele. */
12599 union
12600 {
12601 long int l;
12602 char c[sizeof (long int)];
12603 } u;
12604 u.l = 1;
12605 return u.c[sizeof (long int) - 1] == 1;
12606
12607 ;
12608 return 0;
12609 }
12610 _ACEOF
12611 if ac_fn_c_try_run "$LINENO"; then :
12612 ac_cv_c_bigendian=no
12613 else
12614 ac_cv_c_bigendian=yes
12615 fi
12616 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12617 conftest.$ac_objext conftest.beam conftest.$ac_ext
12618 fi
12619
12620 fi
12621 fi
12622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
12623 $as_echo "$ac_cv_c_bigendian" >&6; }
12624 case $ac_cv_c_bigendian in #(
12625 yes)
12626 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
12627 ;; #(
12628 no)
12629 ;; #(
12630 universal)
12631
12632 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
12633
12634 ;; #(
12635 *)
12636 as_fn_error $? "unknown endianness
12637 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
12638 esac
12639
12640
12641 # ------------------------------ #
12642 # Checks for library functions. #
12643 # ------------------------------ #
12644
12645
12646
12647
12648 for ac_header in $ac_header_list
12649 do :
12650 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12651 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
12652 "
12653 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12654 cat >>confdefs.h <<_ACEOF
12655 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12656 _ACEOF
12657
12658 fi
12659
12660 done
12661
12662
12663
12664
12665
12666
12667
12668
12669 for ac_func in getpagesize
12670 do :
12671 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
12672 if test "x$ac_cv_func_getpagesize" = xyes; then :
12673 cat >>confdefs.h <<_ACEOF
12674 #define HAVE_GETPAGESIZE 1
12675 _ACEOF
12676
12677 fi
12678 done
12679
12680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
12681 $as_echo_n "checking for working mmap... " >&6; }
12682 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
12683 $as_echo_n "(cached) " >&6
12684 else
12685 if test "$cross_compiling" = yes; then :
12686 ac_cv_func_mmap_fixed_mapped=no
12687 else
12688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12689 /* end confdefs.h. */
12690 $ac_includes_default
12691 /* malloc might have been renamed as rpl_malloc. */
12692 #undef malloc
12693
12694 /* Thanks to Mike Haertel and Jim Avera for this test.
12695 Here is a matrix of mmap possibilities:
12696 mmap private not fixed
12697 mmap private fixed at somewhere currently unmapped
12698 mmap private fixed at somewhere already mapped
12699 mmap shared not fixed
12700 mmap shared fixed at somewhere currently unmapped
12701 mmap shared fixed at somewhere already mapped
12702 For private mappings, we should verify that changes cannot be read()
12703 back from the file, nor mmap's back from the file at a different
12704 address. (There have been systems where private was not correctly
12705 implemented like the infamous i386 svr4.0, and systems where the
12706 VM page cache was not coherent with the file system buffer cache
12707 like early versions of FreeBSD and possibly contemporary NetBSD.)
12708 For shared mappings, we should conversely verify that changes get
12709 propagated back to all the places they're supposed to be.
12710
12711 Grep wants private fixed already mapped.
12712 The main things grep needs to know about mmap are:
12713 * does it exist and is it safe to write into the mmap'd area
12714 * how to use it (BSD variants) */
12715
12716 #include <fcntl.h>
12717 #include <sys/mman.h>
12718
12719 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
12720 char *malloc ();
12721 #endif
12722
12723 /* This mess was copied from the GNU getpagesize.h. */
12724 #ifndef HAVE_GETPAGESIZE
12725 # ifdef _SC_PAGESIZE
12726 # define getpagesize() sysconf(_SC_PAGESIZE)
12727 # else /* no _SC_PAGESIZE */
12728 # ifdef HAVE_SYS_PARAM_H
12729 # include <sys/param.h>
12730 # ifdef EXEC_PAGESIZE
12731 # define getpagesize() EXEC_PAGESIZE
12732 # else /* no EXEC_PAGESIZE */
12733 # ifdef NBPG
12734 # define getpagesize() NBPG * CLSIZE
12735 # ifndef CLSIZE
12736 # define CLSIZE 1
12737 # endif /* no CLSIZE */
12738 # else /* no NBPG */
12739 # ifdef NBPC
12740 # define getpagesize() NBPC
12741 # else /* no NBPC */
12742 # ifdef PAGESIZE
12743 # define getpagesize() PAGESIZE
12744 # endif /* PAGESIZE */
12745 # endif /* no NBPC */
12746 # endif /* no NBPG */
12747 # endif /* no EXEC_PAGESIZE */
12748 # else /* no HAVE_SYS_PARAM_H */
12749 # define getpagesize() 8192 /* punt totally */
12750 # endif /* no HAVE_SYS_PARAM_H */
12751 # endif /* no _SC_PAGESIZE */
12752
12753 #endif /* no HAVE_GETPAGESIZE */
12754
12755 int
12756 main ()
12757 {
12758 char *data, *data2, *data3;
12759 const char *cdata2;
12760 int i, pagesize;
12761 int fd, fd2;
12762
12763 pagesize = getpagesize ();
12764
12765 /* First, make a file with some known garbage in it. */
12766 data = (char *) malloc (pagesize);
12767 if (!data)
12768 return 1;
12769 for (i = 0; i < pagesize; ++i)
12770 *(data + i) = rand ();
12771 umask (0);
12772 fd = creat ("conftest.mmap", 0600);
12773 if (fd < 0)
12774 return 2;
12775 if (write (fd, data, pagesize) != pagesize)
12776 return 3;
12777 close (fd);
12778
12779 /* Next, check that the tail of a page is zero-filled. File must have
12780 non-zero length, otherwise we risk SIGBUS for entire page. */
12781 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
12782 if (fd2 < 0)
12783 return 4;
12784 cdata2 = "";
12785 if (write (fd2, cdata2, 1) != 1)
12786 return 5;
12787 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
12788 if (data2 == MAP_FAILED)
12789 return 6;
12790 for (i = 0; i < pagesize; ++i)
12791 if (*(data2 + i))
12792 return 7;
12793 close (fd2);
12794 if (munmap (data2, pagesize))
12795 return 8;
12796
12797 /* Next, try to mmap the file at a fixed address which already has
12798 something else allocated at it. If we can, also make sure that
12799 we see the same garbage. */
12800 fd = open ("conftest.mmap", O_RDWR);
12801 if (fd < 0)
12802 return 9;
12803 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
12804 MAP_PRIVATE | MAP_FIXED, fd, 0L))
12805 return 10;
12806 for (i = 0; i < pagesize; ++i)
12807 if (*(data + i) != *(data2 + i))
12808 return 11;
12809
12810 /* Finally, make sure that changes to the mapped area do not
12811 percolate back to the file as seen by read(). (This is a bug on
12812 some variants of i386 svr4.0.) */
12813 for (i = 0; i < pagesize; ++i)
12814 *(data2 + i) = *(data2 + i) + 1;
12815 data3 = (char *) malloc (pagesize);
12816 if (!data3)
12817 return 12;
12818 if (read (fd, data3, pagesize) != pagesize)
12819 return 13;
12820 for (i = 0; i < pagesize; ++i)
12821 if (*(data + i) != *(data3 + i))
12822 return 14;
12823 close (fd);
12824 return 0;
12825 }
12826 _ACEOF
12827 if ac_fn_c_try_run "$LINENO"; then :
12828 ac_cv_func_mmap_fixed_mapped=yes
12829 else
12830 ac_cv_func_mmap_fixed_mapped=no
12831 fi
12832 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12833 conftest.$ac_objext conftest.beam conftest.$ac_ext
12834 fi
12835
12836 fi
12837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
12838 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
12839 if test $ac_cv_func_mmap_fixed_mapped = yes; then
12840
12841 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
12842
12843 fi
12844 rm -f conftest.mmap conftest.txt
12845
12846 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
12847 if test "x$ac_cv_type_pid_t" = xyes; then :
12848
12849 else
12850
12851 cat >>confdefs.h <<_ACEOF
12852 #define pid_t int
12853 _ACEOF
12854
12855 fi
12856
12857 for ac_header in vfork.h
12858 do :
12859 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
12860 if test "x$ac_cv_header_vfork_h" = xyes; then :
12861 cat >>confdefs.h <<_ACEOF
12862 #define HAVE_VFORK_H 1
12863 _ACEOF
12864
12865 fi
12866
12867 done
12868
12869 for ac_func in fork vfork
12870 do :
12871 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12872 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12873 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12874 cat >>confdefs.h <<_ACEOF
12875 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12876 _ACEOF
12877
12878 fi
12879 done
12880
12881 if test "x$ac_cv_func_fork" = xyes; then
12882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
12883 $as_echo_n "checking for working fork... " >&6; }
12884 if ${ac_cv_func_fork_works+:} false; then :
12885 $as_echo_n "(cached) " >&6
12886 else
12887 if test "$cross_compiling" = yes; then :
12888 ac_cv_func_fork_works=cross
12889 else
12890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12891 /* end confdefs.h. */
12892 $ac_includes_default
12893 int
12894 main ()
12895 {
12896
12897 /* By Ruediger Kuhlmann. */
12898 return fork () < 0;
12899
12900 ;
12901 return 0;
12902 }
12903 _ACEOF
12904 if ac_fn_c_try_run "$LINENO"; then :
12905 ac_cv_func_fork_works=yes
12906 else
12907 ac_cv_func_fork_works=no
12908 fi
12909 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12910 conftest.$ac_objext conftest.beam conftest.$ac_ext
12911 fi
12912
12913 fi
12914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
12915 $as_echo "$ac_cv_func_fork_works" >&6; }
12916
12917 else
12918 ac_cv_func_fork_works=$ac_cv_func_fork
12919 fi
12920 if test "x$ac_cv_func_fork_works" = xcross; then
12921 case $host in
12922 *-*-amigaos* | *-*-msdosdjgpp*)
12923 # Override, as these systems have only a dummy fork() stub
12924 ac_cv_func_fork_works=no
12925 ;;
12926 *)
12927 ac_cv_func_fork_works=yes
12928 ;;
12929 esac
12930 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
12931 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
12932 fi
12933 ac_cv_func_vfork_works=$ac_cv_func_vfork
12934 if test "x$ac_cv_func_vfork" = xyes; then
12935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
12936 $as_echo_n "checking for working vfork... " >&6; }
12937 if ${ac_cv_func_vfork_works+:} false; then :
12938 $as_echo_n "(cached) " >&6
12939 else
12940 if test "$cross_compiling" = yes; then :
12941 ac_cv_func_vfork_works=cross
12942 else
12943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12944 /* end confdefs.h. */
12945 /* Thanks to Paul Eggert for this test. */
12946 $ac_includes_default
12947 #include <sys/wait.h>
12948 #ifdef HAVE_VFORK_H
12949 # include <vfork.h>
12950 #endif
12951 /* On some sparc systems, changes by the child to local and incoming
12952 argument registers are propagated back to the parent. The compiler
12953 is told about this with #include <vfork.h>, but some compilers
12954 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
12955 static variable whose address is put into a register that is
12956 clobbered by the vfork. */
12957 static void
12958 #ifdef __cplusplus
12959 sparc_address_test (int arg)
12960 # else
12961 sparc_address_test (arg) int arg;
12962 #endif
12963 {
12964 static pid_t child;
12965 if (!child) {
12966 child = vfork ();
12967 if (child < 0) {
12968 perror ("vfork");
12969 _exit(2);
12970 }
12971 if (!child) {
12972 arg = getpid();
12973 write(-1, "", 0);
12974 _exit (arg);
12975 }
12976 }
12977 }
12978
12979 int
12980 main ()
12981 {
12982 pid_t parent = getpid ();
12983 pid_t child;
12984
12985 sparc_address_test (0);
12986
12987 child = vfork ();
12988
12989 if (child == 0) {
12990 /* Here is another test for sparc vfork register problems. This
12991 test uses lots of local variables, at least as many local
12992 variables as main has allocated so far including compiler
12993 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
12994 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
12995 reuse the register of parent for one of the local variables,
12996 since it will think that parent can't possibly be used any more
12997 in this routine. Assigning to the local variable will thus
12998 munge parent in the parent process. */
12999 pid_t
13000 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13001 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13002 /* Convince the compiler that p..p7 are live; otherwise, it might
13003 use the same hardware register for all 8 local variables. */
13004 if (p != p1 || p != p2 || p != p3 || p != p4
13005 || p != p5 || p != p6 || p != p7)
13006 _exit(1);
13007
13008 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13009 from child file descriptors. If the child closes a descriptor
13010 before it execs or exits, this munges the parent's descriptor
13011 as well. Test for this by closing stdout in the child. */
13012 _exit(close(fileno(stdout)) != 0);
13013 } else {
13014 int status;
13015 struct stat st;
13016
13017 while (wait(&status) != child)
13018 ;
13019 return (
13020 /* Was there some problem with vforking? */
13021 child < 0
13022
13023 /* Did the child fail? (This shouldn't happen.) */
13024 || status
13025
13026 /* Did the vfork/compiler bug occur? */
13027 || parent != getpid()
13028
13029 /* Did the file descriptor bug occur? */
13030 || fstat(fileno(stdout), &st) != 0
13031 );
13032 }
13033 }
13034 _ACEOF
13035 if ac_fn_c_try_run "$LINENO"; then :
13036 ac_cv_func_vfork_works=yes
13037 else
13038 ac_cv_func_vfork_works=no
13039 fi
13040 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13041 conftest.$ac_objext conftest.beam conftest.$ac_ext
13042 fi
13043
13044 fi
13045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13046 $as_echo "$ac_cv_func_vfork_works" >&6; }
13047
13048 fi;
13049 if test "x$ac_cv_func_fork_works" = xcross; then
13050 ac_cv_func_vfork_works=$ac_cv_func_vfork
13051 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13052 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13053 fi
13054
13055 if test "x$ac_cv_func_vfork_works" = xyes; then
13056
13057 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13058
13059 else
13060
13061 $as_echo "#define vfork fork" >>confdefs.h
13062
13063 fi
13064 if test "x$ac_cv_func_fork_works" = xyes; then
13065
13066 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13067
13068 fi
13069
13070 for ac_func in getauxval getrusage getuid getgid \
13071 pipe poll pread pread64 pwrite resize_term \
13072 sbrk getpgid setpgid setpgrp setsid \
13073 sigaction sigsetmask socketpair \
13074 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
13075 setrlimit getrlimit posix_madvise waitpid \
13076 ptrace64 sigaltstack setns use_default_colors
13077 do :
13078 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13079 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13080 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13081 cat >>confdefs.h <<_ACEOF
13082 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13083 _ACEOF
13084
13085 fi
13086 done
13087
13088
13089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13090 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13091 if ${am_cv_langinfo_codeset+:} false; then :
13092 $as_echo_n "(cached) " >&6
13093 else
13094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13095 /* end confdefs.h. */
13096 #include <langinfo.h>
13097 int
13098 main ()
13099 {
13100 char* cs = nl_langinfo(CODESET);
13101 ;
13102 return 0;
13103 }
13104 _ACEOF
13105 if ac_fn_c_try_link "$LINENO"; then :
13106 am_cv_langinfo_codeset=yes
13107 else
13108 am_cv_langinfo_codeset=no
13109 fi
13110 rm -f core conftest.err conftest.$ac_objext \
13111 conftest$ac_exeext conftest.$ac_ext
13112
13113 fi
13114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13115 $as_echo "$am_cv_langinfo_codeset" >&6; }
13116 if test $am_cv_langinfo_codeset = yes; then
13117
13118 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13119
13120 fi
13121
13122 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
13123 if test "x$ac_cv_type_size_t" = xyes; then :
13124
13125 else
13126
13127 cat >>confdefs.h <<_ACEOF
13128 #define size_t unsigned int
13129 _ACEOF
13130
13131 fi
13132
13133
13134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
13135 $as_echo_n "checking for ANSI C header files... " >&6; }
13136 if ${ac_cv_header_stdc+:} false; then :
13137 $as_echo_n "(cached) " >&6
13138 else
13139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13140 /* end confdefs.h. */
13141 #include <stdlib.h>
13142 #include <stdarg.h>
13143 #include <string.h>
13144 #include <float.h>
13145
13146 int
13147 main ()
13148 {
13149
13150 ;
13151 return 0;
13152 }
13153 _ACEOF
13154 if ac_fn_c_try_compile "$LINENO"; then :
13155 ac_cv_header_stdc=yes
13156 else
13157 ac_cv_header_stdc=no
13158 fi
13159 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13160
13161 if test $ac_cv_header_stdc = yes; then
13162 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13164 /* end confdefs.h. */
13165 #include <string.h>
13166
13167 _ACEOF
13168 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13169 $EGREP "memchr" >/dev/null 2>&1; then :
13170
13171 else
13172 ac_cv_header_stdc=no
13173 fi
13174 rm -f conftest*
13175
13176 fi
13177
13178 if test $ac_cv_header_stdc = yes; then
13179 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13181 /* end confdefs.h. */
13182 #include <stdlib.h>
13183
13184 _ACEOF
13185 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13186 $EGREP "free" >/dev/null 2>&1; then :
13187
13188 else
13189 ac_cv_header_stdc=no
13190 fi
13191 rm -f conftest*
13192
13193 fi
13194
13195 if test $ac_cv_header_stdc = yes; then
13196 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13197 if test "$cross_compiling" = yes; then :
13198 :
13199 else
13200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13201 /* end confdefs.h. */
13202 #include <ctype.h>
13203 #include <stdlib.h>
13204 #if ((' ' & 0x0FF) == 0x020)
13205 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13206 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13207 #else
13208 # define ISLOWER(c) \
13209 (('a' <= (c) && (c) <= 'i') \
13210 || ('j' <= (c) && (c) <= 'r') \
13211 || ('s' <= (c) && (c) <= 'z'))
13212 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13213 #endif
13214
13215 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13216 int
13217 main ()
13218 {
13219 int i;
13220 for (i = 0; i < 256; i++)
13221 if (XOR (islower (i), ISLOWER (i))
13222 || toupper (i) != TOUPPER (i))
13223 return 2;
13224 return 0;
13225 }
13226 _ACEOF
13227 if ac_fn_c_try_run "$LINENO"; then :
13228
13229 else
13230 ac_cv_header_stdc=no
13231 fi
13232 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13233 conftest.$ac_objext conftest.beam conftest.$ac_ext
13234 fi
13235
13236 fi
13237 fi
13238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
13239 $as_echo "$ac_cv_header_stdc" >&6; }
13240 if test $ac_cv_header_stdc = yes; then
13241
13242 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
13243
13244 fi
13245
13246 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
13247 # for constant arguments. Useless!
13248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
13249 $as_echo_n "checking for working alloca.h... " >&6; }
13250 if ${ac_cv_working_alloca_h+:} false; then :
13251 $as_echo_n "(cached) " >&6
13252 else
13253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13254 /* end confdefs.h. */
13255 #include <alloca.h>
13256 int
13257 main ()
13258 {
13259 char *p = (char *) alloca (2 * sizeof (int));
13260 if (p) return 0;
13261 ;
13262 return 0;
13263 }
13264 _ACEOF
13265 if ac_fn_c_try_link "$LINENO"; then :
13266 ac_cv_working_alloca_h=yes
13267 else
13268 ac_cv_working_alloca_h=no
13269 fi
13270 rm -f core conftest.err conftest.$ac_objext \
13271 conftest$ac_exeext conftest.$ac_ext
13272 fi
13273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
13274 $as_echo "$ac_cv_working_alloca_h" >&6; }
13275 if test $ac_cv_working_alloca_h = yes; then
13276
13277 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
13278
13279 fi
13280
13281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
13282 $as_echo_n "checking for alloca... " >&6; }
13283 if ${ac_cv_func_alloca_works+:} false; then :
13284 $as_echo_n "(cached) " >&6
13285 else
13286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13287 /* end confdefs.h. */
13288 #ifdef __GNUC__
13289 # define alloca __builtin_alloca
13290 #else
13291 # ifdef _MSC_VER
13292 # include <malloc.h>
13293 # define alloca _alloca
13294 # else
13295 # ifdef HAVE_ALLOCA_H
13296 # include <alloca.h>
13297 # else
13298 # ifdef _AIX
13299 #pragma alloca
13300 # else
13301 # ifndef alloca /* predefined by HP cc +Olibcalls */
13302 void *alloca (size_t);
13303 # endif
13304 # endif
13305 # endif
13306 # endif
13307 #endif
13308
13309 int
13310 main ()
13311 {
13312 char *p = (char *) alloca (1);
13313 if (p) return 0;
13314 ;
13315 return 0;
13316 }
13317 _ACEOF
13318 if ac_fn_c_try_link "$LINENO"; then :
13319 ac_cv_func_alloca_works=yes
13320 else
13321 ac_cv_func_alloca_works=no
13322 fi
13323 rm -f core conftest.err conftest.$ac_objext \
13324 conftest$ac_exeext conftest.$ac_ext
13325 fi
13326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
13327 $as_echo "$ac_cv_func_alloca_works" >&6; }
13328
13329 if test $ac_cv_func_alloca_works = yes; then
13330
13331 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
13332
13333 else
13334 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
13335 # that cause trouble. Some versions do not even contain alloca or
13336 # contain a buggy version. If you still want to use their alloca,
13337 # use ar to extract alloca.o from them instead of compiling alloca.c.
13338
13339 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
13340
13341 $as_echo "#define C_ALLOCA 1" >>confdefs.h
13342
13343
13344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
13345 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
13346 if ${ac_cv_os_cray+:} false; then :
13347 $as_echo_n "(cached) " >&6
13348 else
13349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13350 /* end confdefs.h. */
13351 #if defined CRAY && ! defined CRAY2
13352 webecray
13353 #else
13354 wenotbecray
13355 #endif
13356
13357 _ACEOF
13358 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13359 $EGREP "webecray" >/dev/null 2>&1; then :
13360 ac_cv_os_cray=yes
13361 else
13362 ac_cv_os_cray=no
13363 fi
13364 rm -f conftest*
13365
13366 fi
13367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
13368 $as_echo "$ac_cv_os_cray" >&6; }
13369 if test $ac_cv_os_cray = yes; then
13370 for ac_func in _getb67 GETB67 getb67; do
13371 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13372 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13373 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13374
13375 cat >>confdefs.h <<_ACEOF
13376 #define CRAY_STACKSEG_END $ac_func
13377 _ACEOF
13378
13379 break
13380 fi
13381
13382 done
13383 fi
13384
13385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
13386 $as_echo_n "checking stack direction for C alloca... " >&6; }
13387 if ${ac_cv_c_stack_direction+:} false; then :
13388 $as_echo_n "(cached) " >&6
13389 else
13390 if test "$cross_compiling" = yes; then :
13391 ac_cv_c_stack_direction=0
13392 else
13393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13394 /* end confdefs.h. */
13395 $ac_includes_default
13396 int
13397 find_stack_direction (int *addr, int depth)
13398 {
13399 int dir, dummy = 0;
13400 if (! addr)
13401 addr = &dummy;
13402 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
13403 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
13404 return dir + dummy;
13405 }
13406
13407 int
13408 main (int argc, char **argv)
13409 {
13410 return find_stack_direction (0, argc + !argv + 20) < 0;
13411 }
13412 _ACEOF
13413 if ac_fn_c_try_run "$LINENO"; then :
13414 ac_cv_c_stack_direction=1
13415 else
13416 ac_cv_c_stack_direction=-1
13417 fi
13418 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13419 conftest.$ac_objext conftest.beam conftest.$ac_ext
13420 fi
13421
13422 fi
13423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
13424 $as_echo "$ac_cv_c_stack_direction" >&6; }
13425 cat >>confdefs.h <<_ACEOF
13426 #define STACK_DIRECTION $ac_cv_c_stack_direction
13427 _ACEOF
13428
13429
13430 fi
13431
13432
13433
13434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13435 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13436 if ${am_cv_langinfo_codeset+:} false; then :
13437 $as_echo_n "(cached) " >&6
13438 else
13439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13440 /* end confdefs.h. */
13441 #include <langinfo.h>
13442 int
13443 main ()
13444 {
13445 char* cs = nl_langinfo(CODESET);
13446 ;
13447 return 0;
13448 }
13449 _ACEOF
13450 if ac_fn_c_try_link "$LINENO"; then :
13451 am_cv_langinfo_codeset=yes
13452 else
13453 am_cv_langinfo_codeset=no
13454 fi
13455 rm -f core conftest.err conftest.$ac_objext \
13456 conftest$ac_exeext conftest.$ac_ext
13457
13458 fi
13459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13460 $as_echo "$am_cv_langinfo_codeset" >&6; }
13461 if test $am_cv_langinfo_codeset = yes; then
13462
13463 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13464
13465 fi
13466
13467
13468 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
13469 do :
13470 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13471 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13472 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13473 cat >>confdefs.h <<_ACEOF
13474 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13475 _ACEOF
13476
13477 fi
13478
13479 done
13480
13481
13482 for ac_func in fdwalk getrlimit pipe pipe2 socketpair sigaction \
13483 sigprocmask strerror_r
13484 do :
13485 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13486 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13487 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13488 cat >>confdefs.h <<_ACEOF
13489 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13490 _ACEOF
13491
13492 fi
13493 done
13494
13495
13496 ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
13497 if test "x$ac_cv_have_decl_strerror" = xyes; then :
13498 ac_have_decl=1
13499 else
13500 ac_have_decl=0
13501 fi
13502
13503 cat >>confdefs.h <<_ACEOF
13504 #define HAVE_DECL_STRERROR $ac_have_decl
13505 _ACEOF
13506 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
13507 if test "x$ac_cv_have_decl_strstr" = xyes; then :
13508 ac_have_decl=1
13509 else
13510 ac_have_decl=0
13511 fi
13512
13513 cat >>confdefs.h <<_ACEOF
13514 #define HAVE_DECL_STRSTR $ac_have_decl
13515 _ACEOF
13516
13517
13518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
13519 $as_echo_n "checking for sigsetjmp... " >&6; }
13520 if ${gdb_cv_func_sigsetjmp+:} false; then :
13521 $as_echo_n "(cached) " >&6
13522 else
13523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13524 /* end confdefs.h. */
13525
13526 #include <setjmp.h>
13527
13528 int
13529 main ()
13530 {
13531 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
13532 ;
13533 return 0;
13534 }
13535 _ACEOF
13536 if ac_fn_c_try_compile "$LINENO"; then :
13537 gdb_cv_func_sigsetjmp=yes
13538 else
13539 gdb_cv_func_sigsetjmp=no
13540 fi
13541 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13542 fi
13543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
13544 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
13545 if test $gdb_cv_func_sigsetjmp = yes; then
13546
13547 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
13548
13549 fi
13550
13551
13552 # Check the return and argument types of ptrace.
13553
13554
13555 for ac_header in sys/ptrace.h ptrace.h
13556 do :
13557 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13558 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13559 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13560 cat >>confdefs.h <<_ACEOF
13561 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13562 _ACEOF
13563
13564 fi
13565
13566 done
13567
13568
13569 gdb_ptrace_headers='
13570 #include <sys/types.h>
13571 #if HAVE_SYS_PTRACE_H
13572 # include <sys/ptrace.h>
13573 #endif
13574 #if HAVE_UNISTD_H
13575 # include <unistd.h>
13576 #endif
13577 '
13578 # There is no point in checking if we don't have a prototype.
13579 ac_fn_c_check_decl "$LINENO" "ptrace" "ac_cv_have_decl_ptrace" "$gdb_ptrace_headers
13580 "
13581 if test "x$ac_cv_have_decl_ptrace" = xyes; then :
13582 ac_have_decl=1
13583 else
13584 ac_have_decl=0
13585 fi
13586
13587 cat >>confdefs.h <<_ACEOF
13588 #define HAVE_DECL_PTRACE $ac_have_decl
13589 _ACEOF
13590 if test $ac_have_decl = 1; then :
13591
13592 else
13593
13594 : ${gdb_cv_func_ptrace_ret='int'}
13595 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13596
13597 fi
13598
13599 # Check return type. Varargs (used on GNU/Linux) conflict with the
13600 # empty argument list, so check for that explicitly.
13601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
13602 $as_echo_n "checking return type of ptrace... " >&6; }
13603 if ${gdb_cv_func_ptrace_ret+:} false; then :
13604 $as_echo_n "(cached) " >&6
13605 else
13606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13607 /* end confdefs.h. */
13608 $gdb_ptrace_headers
13609 int
13610 main ()
13611 {
13612 extern long ptrace (enum __ptrace_request, ...);
13613 ;
13614 return 0;
13615 }
13616 _ACEOF
13617 if ac_fn_c_try_compile "$LINENO"; then :
13618 gdb_cv_func_ptrace_ret='long'
13619 else
13620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13621 /* end confdefs.h. */
13622 $gdb_ptrace_headers
13623 int
13624 main ()
13625 {
13626 extern int ptrace ();
13627 ;
13628 return 0;
13629 }
13630 _ACEOF
13631 if ac_fn_c_try_compile "$LINENO"; then :
13632 gdb_cv_func_ptrace_ret='int'
13633 else
13634 gdb_cv_func_ptrace_ret='long'
13635 fi
13636 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13637 fi
13638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13639 fi
13640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
13641 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
13642
13643 cat >>confdefs.h <<_ACEOF
13644 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
13645 _ACEOF
13646
13647 # Check argument types.
13648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
13649 $as_echo_n "checking types of arguments for ptrace... " >&6; }
13650 if ${gdb_cv_func_ptrace_args+:} false; then :
13651 $as_echo_n "(cached) " >&6
13652 else
13653
13654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13655 /* end confdefs.h. */
13656 $gdb_ptrace_headers
13657 int
13658 main ()
13659 {
13660 extern long ptrace (enum __ptrace_request, ...);
13661 ;
13662 return 0;
13663 }
13664 _ACEOF
13665 if ac_fn_c_try_compile "$LINENO"; then :
13666 gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
13667 else
13668
13669 for gdb_arg1 in 'int' 'long'; do
13670 for gdb_arg2 in 'pid_t' 'int' 'long'; do
13671 for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
13672 for gdb_arg4 in 'int' 'long' 'void *'; do
13673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13674 /* end confdefs.h. */
13675 $gdb_ptrace_headers
13676 int
13677 main ()
13678 {
13679
13680 extern $gdb_cv_func_ptrace_ret
13681 ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
13682
13683 ;
13684 return 0;
13685 }
13686 _ACEOF
13687 if ac_fn_c_try_compile "$LINENO"; then :
13688 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
13689 break 4;
13690 fi
13691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13692 for gdb_arg5 in 'int *' 'int' 'long'; do
13693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13694 /* end confdefs.h. */
13695 $gdb_ptrace_headers
13696 int
13697 main ()
13698 {
13699
13700 extern $gdb_cv_func_ptrace_ret
13701 ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
13702
13703 ;
13704 return 0;
13705 }
13706 _ACEOF
13707 if ac_fn_c_try_compile "$LINENO"; then :
13708
13709 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
13710 break 5;
13711 fi
13712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13713 done
13714 done
13715 done
13716 done
13717 done
13718 # Provide a safe default value.
13719 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13720
13721 fi
13722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13723 fi
13724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
13725 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
13726 ac_save_IFS=$IFS; IFS=','
13727 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
13728 IFS=$ac_save_IFS
13729 shift
13730
13731 cat >>confdefs.h <<_ACEOF
13732 #define PTRACE_TYPE_ARG1 $1
13733 _ACEOF
13734
13735
13736 cat >>confdefs.h <<_ACEOF
13737 #define PTRACE_TYPE_ARG3 $3
13738 _ACEOF
13739
13740
13741 cat >>confdefs.h <<_ACEOF
13742 #define PTRACE_TYPE_ARG4 $4
13743 _ACEOF
13744
13745 if test -n "$5"; then
13746
13747 cat >>confdefs.h <<_ACEOF
13748 #define PTRACE_TYPE_ARG5 $5
13749 _ACEOF
13750
13751 fi
13752
13753
13754 if test "$cross_compiling" = no; then
13755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
13756 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
13757 if ${ac_cv_func_setpgrp_void+:} false; then :
13758 $as_echo_n "(cached) " >&6
13759 else
13760 if test "$cross_compiling" = yes; then :
13761 as_fn_error $? "cannot check setpgrp when cross compiling" "$LINENO" 5
13762 else
13763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13764 /* end confdefs.h. */
13765 $ac_includes_default
13766 int
13767 main ()
13768 {
13769 /* If this system has a BSD-style setpgrp which takes arguments,
13770 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
13771 exit successfully. */
13772 return setpgrp (1,1) != -1;
13773 ;
13774 return 0;
13775 }
13776 _ACEOF
13777 if ac_fn_c_try_run "$LINENO"; then :
13778 ac_cv_func_setpgrp_void=no
13779 else
13780 ac_cv_func_setpgrp_void=yes
13781 fi
13782 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13783 conftest.$ac_objext conftest.beam conftest.$ac_ext
13784 fi
13785
13786 fi
13787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
13788 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
13789 if test $ac_cv_func_setpgrp_void = yes; then
13790
13791 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
13792
13793 fi
13794
13795 else
13796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
13797 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
13798 if ${ac_cv_func_setpgrp_void+:} false; then :
13799 $as_echo_n "(cached) " >&6
13800 else
13801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13802 /* end confdefs.h. */
13803
13804 #include <unistd.h>
13805
13806 int
13807 main ()
13808 {
13809
13810 if (setpgrp(1,1) == -1)
13811 exit (0);
13812 else
13813 exit (1);
13814
13815 ;
13816 return 0;
13817 }
13818 _ACEOF
13819 if ac_fn_c_try_compile "$LINENO"; then :
13820 ac_cv_func_setpgrp_void=no
13821 else
13822 ac_cv_func_setpgrp_void=yes
13823 fi
13824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13825 fi
13826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
13827 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
13828 if test $ac_cv_func_setpgrp_void = yes; then
13829 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
13830
13831 fi
13832 fi
13833
13834 # Assume we'll default to using the included libiberty regex.
13835 gdb_use_included_regex=yes
13836
13837 # However, if the system regex is GNU regex, then default to *not*
13838 # using the included regex.
13839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
13840 $as_echo_n "checking for GNU regex... " >&6; }
13841 if ${gdb_cv_have_gnu_regex+:} false; then :
13842 $as_echo_n "(cached) " >&6
13843 else
13844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13845 /* end confdefs.h. */
13846 #include <gnu-versions.h>
13847 int
13848 main ()
13849 {
13850 #define REGEX_INTERFACE_VERSION 1
13851 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
13852 # error "Version mismatch"
13853 #endif
13854 ;
13855 return 0;
13856 }
13857 _ACEOF
13858 if ac_fn_c_try_compile "$LINENO"; then :
13859 gdb_cv_have_gnu_regex=yes
13860 else
13861 gdb_cv_have_gnu_regex=no
13862 fi
13863 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13864 fi
13865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
13866 $as_echo "$gdb_cv_have_gnu_regex" >&6; }
13867 if test $gdb_cv_have_gnu_regex = yes; then
13868 gdb_use_included_regex=no
13869 fi
13870
13871
13872 # Check whether --with-included-regex was given.
13873 if test "${with_included_regex+set}" = set; then :
13874 withval=$with_included_regex; gdb_with_regex=$withval
13875 else
13876 gdb_with_regex=$gdb_use_included_regex
13877 fi
13878
13879 if test "$gdb_with_regex" = yes; then
13880
13881 $as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
13882
13883 fi
13884
13885 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
13886 ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
13887 #include <sys/proc.h>
13888
13889 "
13890 if test "x$ac_cv_member_struct_thread_td_pcb" = xyes; then :
13891
13892 cat >>confdefs.h <<_ACEOF
13893 #define HAVE_STRUCT_THREAD_TD_PCB 1
13894 _ACEOF
13895
13896
13897 fi
13898
13899
13900 # See if <sys/lwp.h> defines `struct lwp`.
13901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
13902 $as_echo_n "checking for struct lwp... " >&6; }
13903 if ${gdb_cv_struct_lwp+:} false; then :
13904 $as_echo_n "(cached) " >&6
13905 else
13906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13907 /* end confdefs.h. */
13908 #include <sys/param.h>
13909 #define _KMEMUSER
13910 #include <sys/lwp.h>
13911 int
13912 main ()
13913 {
13914 struct lwp l;
13915 ;
13916 return 0;
13917 }
13918 _ACEOF
13919 if ac_fn_c_try_compile "$LINENO"; then :
13920 gdb_cv_struct_lwp=yes
13921 else
13922 gdb_cv_struct_lwp=no
13923 fi
13924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13925 fi
13926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
13927 $as_echo "$gdb_cv_struct_lwp" >&6; }
13928 if test $gdb_cv_struct_lwp = yes; then
13929
13930 $as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
13931
13932 fi
13933
13934 # See if <machine/reg.h> degines `struct reg'.
13935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
13936 $as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
13937 if ${gdb_cv_struct_reg+:} false; then :
13938 $as_echo_n "(cached) " >&6
13939 else
13940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13941 /* end confdefs.h. */
13942 #include <sys/types.h>
13943 #include <machine/reg.h>
13944 int
13945 main ()
13946 {
13947 struct reg r;
13948 ;
13949 return 0;
13950 }
13951 _ACEOF
13952 if ac_fn_c_try_compile "$LINENO"; then :
13953 gdb_cv_struct_reg=yes
13954 else
13955 gdb_cv_struct_reg=no
13956 fi
13957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13958 fi
13959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
13960 $as_echo "$gdb_cv_struct_reg" >&6; }
13961 if test $gdb_cv_struct_reg = yes; then
13962
13963 $as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
13964
13965 fi
13966
13967 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
13968 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
13969 ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <sys/types.h>
13970 #include <machine/reg.h>
13971 "
13972 if test "x$ac_cv_member_struct_reg_r_fs" = xyes; then :
13973
13974 cat >>confdefs.h <<_ACEOF
13975 #define HAVE_STRUCT_REG_R_FS 1
13976 _ACEOF
13977
13978
13979 fi
13980 ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <sys/types.h>
13981 #include <machine/reg.h>
13982 "
13983 if test "x$ac_cv_member_struct_reg_r_gs" = xyes; then :
13984
13985 cat >>confdefs.h <<_ACEOF
13986 #define HAVE_STRUCT_REG_R_GS 1
13987 _ACEOF
13988
13989
13990 fi
13991
13992
13993 # See if <sys/user.h> supports the %fs_base and %gs_bas amd64 segment registers.
13994 # Older amd64 Linux's don't have the fs_base and gs_base members of
13995 # `struct user_regs_struct'.
13996 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "fs_base" "ac_cv_member_struct_user_regs_struct_fs_base" "#include <sys/types.h>
13997 #include <sys/user.h>
13998 "
13999 if test "x$ac_cv_member_struct_user_regs_struct_fs_base" = xyes; then :
14000
14001 cat >>confdefs.h <<_ACEOF
14002 #define HAVE_STRUCT_USER_REGS_STRUCT_FS_BASE 1
14003 _ACEOF
14004
14005
14006 fi
14007 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "gs_base" "ac_cv_member_struct_user_regs_struct_gs_base" "#include <sys/types.h>
14008 #include <sys/user.h>
14009 "
14010 if test "x$ac_cv_member_struct_user_regs_struct_gs_base" = xyes; then :
14011
14012 cat >>confdefs.h <<_ACEOF
14013 #define HAVE_STRUCT_USER_REGS_STRUCT_GS_BASE 1
14014 _ACEOF
14015
14016
14017 fi
14018
14019
14020 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
14021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
14022 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
14023 if ${gdb_cv_have_ptrace_getregs+:} false; then :
14024 $as_echo_n "(cached) " >&6
14025 else
14026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14027 /* end confdefs.h. */
14028 #include <sys/ptrace.h>
14029 int
14030 main ()
14031 {
14032 PTRACE_GETREGS;
14033 ;
14034 return 0;
14035 }
14036 _ACEOF
14037 if ac_fn_c_try_compile "$LINENO"; then :
14038 gdb_cv_have_ptrace_getregs=yes
14039 else
14040 gdb_cv_have_ptrace_getregs=no
14041 fi
14042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14043 fi
14044
14045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
14046 $as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
14047 if test $gdb_cv_have_ptrace_getregs = yes; then
14048
14049 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
14050
14051 fi
14052
14053 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
14054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
14055 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
14056 if ${gdb_cv_have_ptrace_getfpxregs+:} false; then :
14057 $as_echo_n "(cached) " >&6
14058 else
14059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14060 /* end confdefs.h. */
14061 #include <sys/ptrace.h>
14062 int
14063 main ()
14064 {
14065 PTRACE_GETFPXREGS;
14066 ;
14067 return 0;
14068 }
14069 _ACEOF
14070 if ac_fn_c_try_compile "$LINENO"; then :
14071 gdb_cv_have_ptrace_getfpxregs=yes
14072 else
14073 gdb_cv_have_ptrace_getfpxregs=no
14074 fi
14075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14076 fi
14077
14078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
14079 $as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
14080 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
14081
14082 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
14083
14084 fi
14085
14086 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
14087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
14088 $as_echo_n "checking for PT_GETDBREGS... " >&6; }
14089 if ${gdb_cv_have_pt_getdbregs+:} false; then :
14090 $as_echo_n "(cached) " >&6
14091 else
14092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14093 /* end confdefs.h. */
14094 #include <sys/types.h>
14095 #include <sys/ptrace.h>
14096 int
14097 main ()
14098 {
14099 PT_GETDBREGS;
14100 ;
14101 return 0;
14102 }
14103 _ACEOF
14104 if ac_fn_c_try_compile "$LINENO"; then :
14105 gdb_cv_have_pt_getdbregs=yes
14106 else
14107 gdb_cv_have_pt_getdbregs=no
14108 fi
14109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14110 fi
14111
14112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
14113 $as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
14114 if test $gdb_cv_have_pt_getdbregs = yes; then
14115
14116 $as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
14117
14118 fi
14119
14120 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
14121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
14122 $as_echo_n "checking for PT_GETXMMREGS... " >&6; }
14123 if ${gdb_cv_have_pt_getxmmregs+:} false; then :
14124 $as_echo_n "(cached) " >&6
14125 else
14126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14127 /* end confdefs.h. */
14128 #include <sys/types.h>
14129 #include <sys/ptrace.h>
14130 int
14131 main ()
14132 {
14133 PT_GETXMMREGS;
14134 ;
14135 return 0;
14136 }
14137 _ACEOF
14138 if ac_fn_c_try_compile "$LINENO"; then :
14139 gdb_cv_have_pt_getxmmregs=yes
14140 else
14141 gdb_cv_have_pt_getxmmregs=no
14142 fi
14143 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14144 fi
14145
14146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
14147 $as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
14148 if test $gdb_cv_have_pt_getxmmregs = yes; then
14149
14150 $as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
14151
14152 fi
14153
14154 # See if <sys/ptrace.h> supports LWP names on FreeBSD
14155 # Older FreeBSD versions don't have the pl_tdname member of
14156 # `struct ptrace_lwpinfo'.
14157 ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_tdname" "ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" "#include <sys/ptrace.h>
14158 "
14159 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" = xyes; then :
14160
14161 cat >>confdefs.h <<_ACEOF
14162 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_TDNAME 1
14163 _ACEOF
14164
14165
14166 fi
14167
14168
14169 # See if <sys/ptrace.h> supports syscall fields on FreeBSD. The
14170 # pl_syscall_code member of `struct ptrace_lwpinfo' was added in
14171 # FreeBSD 10.3.
14172 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>
14173 "
14174 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" = xyes; then :
14175
14176 cat >>confdefs.h <<_ACEOF
14177 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_SYSCALL_CODE 1
14178 _ACEOF
14179
14180
14181 fi
14182
14183
14184 if test "$ac_cv_header_sys_procfs_h" = yes; then
14185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
14186 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
14187 if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
14188 $as_echo_n "(cached) " >&6
14189 else
14190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14191 /* end confdefs.h. */
14192
14193 #define _SYSCALL32
14194 /* Needed for new procfs interface on sparc-solaris. */
14195 #define _STRUCTURED_PROC 1
14196 #include <sys/procfs.h>
14197 int
14198 main ()
14199 {
14200 gregset_t avar
14201 ;
14202 return 0;
14203 }
14204 _ACEOF
14205 if ac_fn_c_try_compile "$LINENO"; then :
14206 bfd_cv_have_sys_procfs_type_gregset_t=yes
14207 else
14208 bfd_cv_have_sys_procfs_type_gregset_t=no
14209
14210 fi
14211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14212 fi
14213
14214 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
14215
14216 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
14217
14218 fi
14219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
14220 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
14221
14222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
14223 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
14224 if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
14225 $as_echo_n "(cached) " >&6
14226 else
14227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14228 /* end confdefs.h. */
14229
14230 #define _SYSCALL32
14231 /* Needed for new procfs interface on sparc-solaris. */
14232 #define _STRUCTURED_PROC 1
14233 #include <sys/procfs.h>
14234 int
14235 main ()
14236 {
14237 fpregset_t avar
14238 ;
14239 return 0;
14240 }
14241 _ACEOF
14242 if ac_fn_c_try_compile "$LINENO"; then :
14243 bfd_cv_have_sys_procfs_type_fpregset_t=yes
14244 else
14245 bfd_cv_have_sys_procfs_type_fpregset_t=no
14246
14247 fi
14248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14249 fi
14250
14251 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
14252
14253 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
14254
14255 fi
14256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
14257 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
14258
14259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
14260 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
14261 if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
14262 $as_echo_n "(cached) " >&6
14263 else
14264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14265 /* end confdefs.h. */
14266
14267 #define _SYSCALL32
14268 /* Needed for new procfs interface on sparc-solaris. */
14269 #define _STRUCTURED_PROC 1
14270 #include <sys/procfs.h>
14271 int
14272 main ()
14273 {
14274 prgregset_t avar
14275 ;
14276 return 0;
14277 }
14278 _ACEOF
14279 if ac_fn_c_try_compile "$LINENO"; then :
14280 bfd_cv_have_sys_procfs_type_prgregset_t=yes
14281 else
14282 bfd_cv_have_sys_procfs_type_prgregset_t=no
14283
14284 fi
14285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14286 fi
14287
14288 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
14289
14290 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
14291
14292 fi
14293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
14294 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
14295
14296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
14297 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
14298 if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
14299 $as_echo_n "(cached) " >&6
14300 else
14301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14302 /* end confdefs.h. */
14303
14304 #define _SYSCALL32
14305 /* Needed for new procfs interface on sparc-solaris. */
14306 #define _STRUCTURED_PROC 1
14307 #include <sys/procfs.h>
14308 int
14309 main ()
14310 {
14311 prfpregset_t avar
14312 ;
14313 return 0;
14314 }
14315 _ACEOF
14316 if ac_fn_c_try_compile "$LINENO"; then :
14317 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
14318 else
14319 bfd_cv_have_sys_procfs_type_prfpregset_t=no
14320
14321 fi
14322 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14323 fi
14324
14325 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
14326
14327 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
14328
14329 fi
14330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
14331 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
14332
14333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
14334 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
14335 if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
14336 $as_echo_n "(cached) " >&6
14337 else
14338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14339 /* end confdefs.h. */
14340
14341 #define _SYSCALL32
14342 /* Needed for new procfs interface on sparc-solaris. */
14343 #define _STRUCTURED_PROC 1
14344 #include <sys/procfs.h>
14345 int
14346 main ()
14347 {
14348 prgregset32_t avar
14349 ;
14350 return 0;
14351 }
14352 _ACEOF
14353 if ac_fn_c_try_compile "$LINENO"; then :
14354 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
14355 else
14356 bfd_cv_have_sys_procfs_type_prgregset32_t=no
14357
14358 fi
14359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14360 fi
14361
14362 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
14363
14364 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
14365
14366 fi
14367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
14368 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
14369
14370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
14371 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
14372 if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
14373 $as_echo_n "(cached) " >&6
14374 else
14375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14376 /* end confdefs.h. */
14377
14378 #define _SYSCALL32
14379 /* Needed for new procfs interface on sparc-solaris. */
14380 #define _STRUCTURED_PROC 1
14381 #include <sys/procfs.h>
14382 int
14383 main ()
14384 {
14385 lwpid_t avar
14386 ;
14387 return 0;
14388 }
14389 _ACEOF
14390 if ac_fn_c_try_compile "$LINENO"; then :
14391 bfd_cv_have_sys_procfs_type_lwpid_t=yes
14392 else
14393 bfd_cv_have_sys_procfs_type_lwpid_t=no
14394
14395 fi
14396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14397 fi
14398
14399 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
14400
14401 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
14402
14403 fi
14404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
14405 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
14406
14407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
14408 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
14409 if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
14410 $as_echo_n "(cached) " >&6
14411 else
14412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14413 /* end confdefs.h. */
14414
14415 #define _SYSCALL32
14416 /* Needed for new procfs interface on sparc-solaris. */
14417 #define _STRUCTURED_PROC 1
14418 #include <sys/procfs.h>
14419 int
14420 main ()
14421 {
14422 psaddr_t avar
14423 ;
14424 return 0;
14425 }
14426 _ACEOF
14427 if ac_fn_c_try_compile "$LINENO"; then :
14428 bfd_cv_have_sys_procfs_type_psaddr_t=yes
14429 else
14430 bfd_cv_have_sys_procfs_type_psaddr_t=no
14431
14432 fi
14433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14434 fi
14435
14436 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
14437
14438 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
14439
14440 fi
14441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
14442 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
14443
14444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
14445 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
14446 if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
14447 $as_echo_n "(cached) " >&6
14448 else
14449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14450 /* end confdefs.h. */
14451
14452 #define _SYSCALL32
14453 /* Needed for new procfs interface on sparc-solaris. */
14454 #define _STRUCTURED_PROC 1
14455 #include <sys/procfs.h>
14456 int
14457 main ()
14458 {
14459 elf_fpregset_t avar
14460 ;
14461 return 0;
14462 }
14463 _ACEOF
14464 if ac_fn_c_try_compile "$LINENO"; then :
14465 bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
14466 else
14467 bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
14468
14469 fi
14470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14471 fi
14472
14473 if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
14474
14475 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
14476
14477 fi
14478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
14479 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
14480
14481 fi
14482
14483 # Check if the compiler supports the `long long' type.
14484
14485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
14486 $as_echo_n "checking for long long support in compiler... " >&6; }
14487 if ${gdb_cv_c_long_long+:} false; then :
14488 $as_echo_n "(cached) " >&6
14489 else
14490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14491 /* end confdefs.h. */
14492 extern long long foo;
14493 int
14494 main ()
14495 {
14496 switch (foo & 2) { case 0: return 1; }
14497 ;
14498 return 0;
14499 }
14500 _ACEOF
14501 if ac_fn_c_try_compile "$LINENO"; then :
14502 gdb_cv_c_long_long=yes
14503 else
14504 gdb_cv_c_long_long=no
14505 fi
14506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14507 fi
14508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
14509 $as_echo "$gdb_cv_c_long_long" >&6; }
14510 if test $gdb_cv_c_long_long != yes; then
14511 # libdecnumber requires long long.
14512 as_fn_error $? "Compiler must support long long for GDB." "$LINENO" 5
14513 fi
14514
14515 # Check if the compiler and runtime support printing long longs.
14516
14517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
14518 $as_echo_n "checking for long long support in printf... " >&6; }
14519 if ${gdb_cv_printf_has_long_long+:} false; then :
14520 $as_echo_n "(cached) " >&6
14521 else
14522 if test "$cross_compiling" = yes; then :
14523 gdb_cv_printf_has_long_long=no
14524 else
14525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14526 /* end confdefs.h. */
14527 $ac_includes_default
14528 int
14529 main ()
14530 {
14531 char buf[32];
14532 long long l = 0;
14533 l = (l << 16) + 0x0123;
14534 l = (l << 16) + 0x4567;
14535 l = (l << 16) + 0x89ab;
14536 l = (l << 16) + 0xcdef;
14537 sprintf (buf, "0x%016llx", l);
14538 return (strcmp ("0x0123456789abcdef", buf));
14539 ;
14540 return 0;
14541 }
14542 _ACEOF
14543 if ac_fn_c_try_run "$LINENO"; then :
14544 gdb_cv_printf_has_long_long=yes
14545 else
14546 gdb_cv_printf_has_long_long=no
14547 fi
14548 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14549 conftest.$ac_objext conftest.beam conftest.$ac_ext
14550 fi
14551
14552 fi
14553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
14554 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
14555 if test $gdb_cv_printf_has_long_long = yes; then
14556
14557 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
14558
14559 fi
14560
14561 # Check if the compiler and runtime support printing decfloats.
14562
14563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
14564 $as_echo_n "checking for decfloat support in printf... " >&6; }
14565 if ${gdb_cv_printf_has_decfloat+:} false; then :
14566 $as_echo_n "(cached) " >&6
14567 else
14568 if test "$cross_compiling" = yes; then :
14569 gdb_cv_printf_has_decfloat=no
14570 else
14571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14572 /* end confdefs.h. */
14573 $ac_includes_default
14574 int
14575 main ()
14576 {
14577 char buf[64];
14578 _Decimal32 d32 = 1.2345df;
14579 _Decimal64 d64 = 1.2345dd;
14580 _Decimal128 d128 = 1.2345dl;
14581 sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
14582 return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
14583 ;
14584 return 0;
14585 }
14586 _ACEOF
14587 if ac_fn_c_try_run "$LINENO"; then :
14588 gdb_cv_printf_has_decfloat=yes
14589 else
14590 gdb_cv_printf_has_decfloat=no
14591 fi
14592 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14593 conftest.$ac_objext conftest.beam conftest.$ac_ext
14594 fi
14595
14596 fi
14597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
14598 $as_echo "$gdb_cv_printf_has_decfloat" >&6; }
14599 if test $gdb_cv_printf_has_decfloat = yes; then
14600
14601 $as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
14602
14603 fi
14604
14605 # Check if the compiler supports the `long double' type. We can't use
14606 # AC_C_LONG_DOUBLE because that one does additional checks on the
14607 # constants defined in <float.h> that fail on some systems,
14608 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
14609
14610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
14611 $as_echo_n "checking for long double support in compiler... " >&6; }
14612 if ${gdb_cv_c_long_double+:} false; then :
14613 $as_echo_n "(cached) " >&6
14614 else
14615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14616 /* end confdefs.h. */
14617 long double foo;
14618 _ACEOF
14619 if ac_fn_c_try_compile "$LINENO"; then :
14620 gdb_cv_c_long_double=yes
14621 else
14622 gdb_cv_c_long_double=no
14623 fi
14624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14625 fi
14626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
14627 $as_echo "$gdb_cv_c_long_double" >&6; }
14628 if test $gdb_cv_c_long_double = yes; then
14629
14630 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
14631
14632 fi
14633
14634 # Check if the compiler and runtime support printing long doubles.
14635
14636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
14637 $as_echo_n "checking for long double support in printf... " >&6; }
14638 if ${gdb_cv_printf_has_long_double+:} false; then :
14639 $as_echo_n "(cached) " >&6
14640 else
14641 if test "$cross_compiling" = yes; then :
14642 gdb_cv_printf_has_long_double=no
14643 else
14644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14645 /* end confdefs.h. */
14646 $ac_includes_default
14647 int
14648 main ()
14649 {
14650 char buf[16];
14651 long double f = 3.141592653;
14652 sprintf (buf, "%Lg", f);
14653 return (strncmp ("3.14159", buf, 7));
14654 ;
14655 return 0;
14656 }
14657 _ACEOF
14658 if ac_fn_c_try_run "$LINENO"; then :
14659 gdb_cv_printf_has_long_double=yes
14660 else
14661 gdb_cv_printf_has_long_double=no
14662 fi
14663 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14664 conftest.$ac_objext conftest.beam conftest.$ac_ext
14665 fi
14666
14667 fi
14668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
14669 $as_echo "$gdb_cv_printf_has_long_double" >&6; }
14670 if test $gdb_cv_printf_has_long_double = yes; then
14671
14672 $as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
14673
14674 fi
14675
14676 # Check if the compiler and runtime support scanning long doubles.
14677
14678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
14679 $as_echo_n "checking for long double support in scanf... " >&6; }
14680 if ${gdb_cv_scanf_has_long_double+:} false; then :
14681 $as_echo_n "(cached) " >&6
14682 else
14683 if test "$cross_compiling" = yes; then :
14684 gdb_cv_scanf_has_long_double=no
14685 else
14686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14687 /* end confdefs.h. */
14688 #include <stdio.h>
14689 int
14690 main ()
14691 {
14692 char *buf = "3.141592653";
14693 long double f = 0;
14694 sscanf (buf, "%Lg", &f);
14695 return !(f > 3.14159 && f < 3.14160);
14696 ;
14697 return 0;
14698 }
14699 _ACEOF
14700 if ac_fn_c_try_run "$LINENO"; then :
14701 gdb_cv_scanf_has_long_double=yes
14702 else
14703 gdb_cv_scanf_has_long_double=no
14704 fi
14705 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14706 conftest.$ac_objext conftest.beam conftest.$ac_ext
14707 fi
14708
14709 fi
14710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
14711 $as_echo "$gdb_cv_scanf_has_long_double" >&6; }
14712 if test $gdb_cv_scanf_has_long_double = yes; then
14713
14714 $as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
14715
14716 fi
14717
14718 case ${host_os} in
14719 aix*)
14720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
14721 $as_echo_n "checking for -bbigtoc option... " >&6; }
14722 if ${gdb_cv_bigtoc+:} false; then :
14723 $as_echo_n "(cached) " >&6
14724 else
14725
14726 SAVE_LDFLAGS=$LDFLAGS
14727
14728 case $GCC in
14729 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
14730 *) gdb_cv_bigtoc=-bbigtoc ;;
14731 esac
14732
14733 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
14734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14735 /* end confdefs.h. */
14736
14737 int
14738 main ()
14739 {
14740 int i;
14741 ;
14742 return 0;
14743 }
14744 _ACEOF
14745 if ac_fn_c_try_link "$LINENO"; then :
14746
14747 else
14748 gdb_cv_bigtoc=
14749 fi
14750 rm -f core conftest.err conftest.$ac_objext \
14751 conftest$ac_exeext conftest.$ac_ext
14752 LDFLAGS="${SAVE_LDFLAGS}"
14753
14754 fi
14755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
14756 $as_echo "$gdb_cv_bigtoc" >&6; }
14757 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
14758 ;;
14759 esac
14760
14761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
14762 $as_echo_n "checking for the dynamic export flag... " >&6; }
14763 dynamic_list=false
14764 if test "${gdb_native}" = yes; then
14765 # The dynamically loaded libthread_db needs access to symbols in the gdb
14766 # executable. Older GNU ld supports --export-dynamic but --dynamic-list
14767 # may not be supported there.
14768 old_LDFLAGS="$LDFLAGS"
14769 # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
14770 RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
14771 LDFLAGS="$LDFLAGS $RDYNAMIC"
14772 if test "${have_libpython}" = no; then
14773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14774 /* end confdefs.h. */
14775
14776 int
14777 main ()
14778 {
14779
14780 ;
14781 return 0;
14782 }
14783 _ACEOF
14784 if ac_fn_c_try_link "$LINENO"; then :
14785 dynamic_list=true
14786 fi
14787 rm -f core conftest.err conftest.$ac_objext \
14788 conftest$ac_exeext conftest.$ac_ext
14789 else
14790 # Workaround http://bugs.python.org/issue4434 where static
14791 # libpythonX.Y.a would get its symbols required for
14792 # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
14793 # Problem does not happen for the recommended libpythonX.Y.so linkage.
14794
14795 # Note the workaround for Python
14796 # http://bugs.python.org/issue10112 earlier has removed
14797 # -export-dynamic from PYTHON_LIBS. That's exactly what we want
14798 # here too, as otherwise it'd make this -Wl,--dynamic-list test
14799 # always pass.
14800 old_CFLAGS="$CFLAGS"
14801 CFLAGS="$CFLAGS $PYTHON_CFLAGS"
14802 old_LIBS="$LIBS"
14803 LIBS="$LIBS $PYTHON_LIBS"
14804 old_CPPFLAGS="$CPPFLAGS"
14805 CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
14806 if test "$cross_compiling" = yes; then :
14807 true
14808 else
14809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14810 /* end confdefs.h. */
14811 #include "Python.h"
14812 int
14813 main ()
14814 {
14815 int err;
14816 Py_Initialize ();
14817 err = PyRun_SimpleString ("import itertools\n");
14818 Py_Finalize ();
14819 return err == 0 ? 0 : 1;
14820 ;
14821 return 0;
14822 }
14823 _ACEOF
14824 if ac_fn_c_try_run "$LINENO"; then :
14825 dynamic_list=true
14826 fi
14827 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14828 conftest.$ac_objext conftest.beam conftest.$ac_ext
14829 fi
14830
14831 LIBS="$old_LIBS"
14832 CFLAGS="$old_CFLAGS"
14833 CPPFLAGS="$old_CPPFLAGS"
14834 fi
14835 LDFLAGS="$old_LDFLAGS"
14836 fi
14837 if $dynamic_list; then
14838 found="-Wl,--dynamic-list"
14839 RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
14840 else
14841 found="-rdynamic"
14842 RDYNAMIC="-rdynamic"
14843 fi
14844
14845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
14846 $as_echo "$found" >&6; }
14847
14848
14849 if test ${build} = ${host} -a ${host} = ${target} ; then
14850 case ${host_os} in
14851 aix*)
14852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
14853 $as_echo_n "checking for AiX thread debugging library... " >&6; }
14854 if ${gdb_cv_have_aix_thread_debug+:} false; then :
14855 $as_echo_n "(cached) " >&6
14856 else
14857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14858 /* end confdefs.h. */
14859 #include <sys/pthdebug.h>
14860 int
14861 main ()
14862 {
14863 #ifndef PTHDB_VERSION_3
14864 #error
14865 #endif
14866 ;
14867 return 0;
14868 }
14869 _ACEOF
14870 if ac_fn_c_try_compile "$LINENO"; then :
14871 gdb_cv_have_aix_thread_debug=yes
14872 else
14873 gdb_cv_have_aix_thread_debug=no
14874 fi
14875 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14876 fi
14877
14878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
14879 $as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
14880 if test $gdb_cv_have_aix_thread_debug = yes; then
14881 CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
14882 CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
14883 LIBS="$LIBS -lpthdebug"
14884
14885 # Older versions of AIX do not provide the declaration for
14886 # the getthrds function (it appears that it was introduced
14887 # with AIX 6.x).
14888 ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
14889 "
14890 if test "x$ac_cv_have_decl_getthrds" = xyes; then :
14891 ac_have_decl=1
14892 else
14893 ac_have_decl=0
14894 fi
14895
14896 cat >>confdefs.h <<_ACEOF
14897 #define HAVE_DECL_GETTHRDS $ac_have_decl
14898 _ACEOF
14899
14900 fi
14901 ;;
14902 esac
14903
14904 fi
14905
14906 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
14907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
14908 $as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
14909 if ${gdb_cv_thread_db_h_has_td_notalloc+:} false; then :
14910 $as_echo_n "(cached) " >&6
14911 else
14912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14913 /* end confdefs.h. */
14914 #include <thread_db.h>
14915 int
14916 main ()
14917 {
14918 int i = TD_NOTALLOC;
14919 ;
14920 return 0;
14921 }
14922 _ACEOF
14923 if ac_fn_c_try_compile "$LINENO"; then :
14924 gdb_cv_thread_db_h_has_td_notalloc=yes
14925 else
14926 gdb_cv_thread_db_h_has_td_notalloc=no
14927
14928 fi
14929 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14930
14931 fi
14932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
14933 $as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
14934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
14935 $as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
14936 if ${gdb_cv_thread_db_h_has_td_version+:} false; then :
14937 $as_echo_n "(cached) " >&6
14938 else
14939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14940 /* end confdefs.h. */
14941 #include <thread_db.h>
14942 int
14943 main ()
14944 {
14945 int i = TD_VERSION;
14946 ;
14947 return 0;
14948 }
14949 _ACEOF
14950 if ac_fn_c_try_compile "$LINENO"; then :
14951 gdb_cv_thread_db_h_has_td_version=yes
14952 else
14953 gdb_cv_thread_db_h_has_td_version=no
14954
14955 fi
14956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14957
14958 fi
14959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
14960 $as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
14961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
14962 $as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
14963 if ${gdb_cv_thread_db_h_has_td_notls+:} false; then :
14964 $as_echo_n "(cached) " >&6
14965 else
14966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14967 /* end confdefs.h. */
14968 #include <thread_db.h>
14969 int
14970 main ()
14971 {
14972 int i = TD_NOTLS;
14973 ;
14974 return 0;
14975 }
14976 _ACEOF
14977 if ac_fn_c_try_compile "$LINENO"; then :
14978 gdb_cv_thread_db_h_has_td_notls=yes
14979 else
14980 gdb_cv_thread_db_h_has_td_notls=no
14981
14982 fi
14983 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14984
14985 fi
14986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
14987 $as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
14988 fi
14989 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
14990
14991 $as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
14992
14993 fi
14994 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
14995
14996 $as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
14997
14998 fi
14999 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
15000
15001 $as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
15002
15003 fi
15004
15005 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
15006 "
15007 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
15008 ac_have_decl=1
15009 else
15010 ac_have_decl=0
15011 fi
15012
15013 cat >>confdefs.h <<_ACEOF
15014 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
15015 _ACEOF
15016
15017
15018 if test "$cross_compiling" = yes; then :
15019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15020 /* end confdefs.h. */
15021 #include <sys/personality.h>
15022 int
15023 main ()
15024 {
15025
15026 # if !HAVE_DECL_ADDR_NO_RANDOMIZE
15027 # define ADDR_NO_RANDOMIZE 0x0040000
15028 # endif
15029 /* Test the flag could be set and stays set. */
15030 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
15031 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
15032 return 1
15033 ;
15034 return 0;
15035 }
15036 _ACEOF
15037 if ac_fn_c_try_link "$LINENO"; then :
15038 have_personality=true
15039 else
15040 have_personality=false
15041 fi
15042 rm -f core conftest.err conftest.$ac_objext \
15043 conftest$ac_exeext conftest.$ac_ext
15044 else
15045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15046 /* end confdefs.h. */
15047 #include <sys/personality.h>
15048 int
15049 main ()
15050 {
15051
15052 # if !HAVE_DECL_ADDR_NO_RANDOMIZE
15053 # define ADDR_NO_RANDOMIZE 0x0040000
15054 # endif
15055 /* Test the flag could be set and stays set. */
15056 personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
15057 if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
15058 return 1
15059 ;
15060 return 0;
15061 }
15062 _ACEOF
15063 if ac_fn_c_try_run "$LINENO"; then :
15064 have_personality=true
15065 else
15066 have_personality=false
15067 fi
15068 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15069 conftest.$ac_objext conftest.beam conftest.$ac_ext
15070 fi
15071
15072 if $have_personality
15073 then
15074
15075 $as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
15076
15077 fi
15078
15079 case $host_os in
15080 go32* | *djgpp*)
15081 gdbinit=gdb.ini
15082 ;;
15083 *)
15084 gdbinit=.gdbinit
15085 ;;
15086 esac
15087
15088 cat >>confdefs.h <<_ACEOF
15089 #define GDBINIT "$gdbinit"
15090 _ACEOF
15091
15092
15093
15094 # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
15095 # except that the argument to --with-sysroot is optional.
15096 # --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
15097 if test "x$with_sysroot" = xyes; then
15098 with_sysroot="${exec_prefix}/${target_alias}/sys-root"
15099 fi
15100
15101 # Check whether --with-sysroot was given.
15102 if test "${with_sysroot+set}" = set; then :
15103 withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
15104 else
15105 TARGET_SYSTEM_ROOT=
15106 fi
15107
15108
15109 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
15110 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15111 ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
15112 ac_define_dir=`eval echo $ac_define_dir`
15113
15114 cat >>confdefs.h <<_ACEOF
15115 #define TARGET_SYSTEM_ROOT "$ac_define_dir"
15116 _ACEOF
15117
15118
15119
15120
15121 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
15122 if test "x$prefix" = xNONE; then
15123 test_prefix=/usr/local
15124 else
15125 test_prefix=$prefix
15126 fi
15127 else
15128 test_prefix=$exec_prefix
15129 fi
15130 value=0
15131 case ${ac_define_dir} in
15132 "${test_prefix}"|"${test_prefix}/"*|\
15133 '${exec_prefix}'|'${exec_prefix}/'*)
15134 value=1
15135 ;;
15136 esac
15137
15138 cat >>confdefs.h <<_ACEOF
15139 #define TARGET_SYSTEM_ROOT_RELOCATABLE $value
15140 _ACEOF
15141
15142
15143
15144
15145
15146 # Check whether --with-system-gdbinit was given.
15147 if test "${with_system_gdbinit+set}" = set; then :
15148 withval=$with_system_gdbinit;
15149 SYSTEM_GDBINIT=$withval
15150 else
15151 SYSTEM_GDBINIT=
15152 fi
15153
15154
15155 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
15156 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15157 ac_define_dir=`eval echo $SYSTEM_GDBINIT`
15158 ac_define_dir=`eval echo $ac_define_dir`
15159
15160 cat >>confdefs.h <<_ACEOF
15161 #define SYSTEM_GDBINIT "$ac_define_dir"
15162 _ACEOF
15163
15164
15165
15166
15167 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
15168 if test "x$prefix" = xNONE; then
15169 test_prefix=/usr/local
15170 else
15171 test_prefix=$prefix
15172 fi
15173 else
15174 test_prefix=$exec_prefix
15175 fi
15176 value=0
15177 case ${ac_define_dir} in
15178 "${test_prefix}"|"${test_prefix}/"*|\
15179 '${exec_prefix}'|'${exec_prefix}/'*)
15180 value=1
15181 ;;
15182 esac
15183
15184 cat >>confdefs.h <<_ACEOF
15185 #define SYSTEM_GDBINIT_RELOCATABLE $value
15186 _ACEOF
15187
15188
15189
15190
15191
15192 # Check whether --with-system-gdbinit-dir was given.
15193 if test "${with_system_gdbinit_dir+set}" = set; then :
15194 withval=$with_system_gdbinit_dir;
15195 SYSTEM_GDBINIT_DIR=$withval
15196 else
15197 SYSTEM_GDBINIT_DIR=
15198 fi
15199
15200
15201 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
15202 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15203 ac_define_dir=`eval echo $SYSTEM_GDBINIT_DIR`
15204 ac_define_dir=`eval echo $ac_define_dir`
15205
15206 cat >>confdefs.h <<_ACEOF
15207 #define SYSTEM_GDBINIT_DIR "$ac_define_dir"
15208 _ACEOF
15209
15210
15211
15212
15213 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
15214 if test "x$prefix" = xNONE; then
15215 test_prefix=/usr/local
15216 else
15217 test_prefix=$prefix
15218 fi
15219 else
15220 test_prefix=$exec_prefix
15221 fi
15222 value=0
15223 case ${ac_define_dir} in
15224 "${test_prefix}"|"${test_prefix}/"*|\
15225 '${exec_prefix}'|'${exec_prefix}/'*)
15226 value=1
15227 ;;
15228 esac
15229
15230 cat >>confdefs.h <<_ACEOF
15231 #define SYSTEM_GDBINIT_DIR_RELOCATABLE $value
15232 _ACEOF
15233
15234
15235
15236
15237
15238 # Check whether --enable-werror was given.
15239 if test "${enable_werror+set}" = set; then :
15240 enableval=$enable_werror; case "${enableval}" in
15241 yes | y) ERROR_ON_WARNING="yes" ;;
15242 no | n) ERROR_ON_WARNING="no" ;;
15243 *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
15244 esac
15245 fi
15246
15247
15248 # Enable -Werror by default when using gcc. Turn it off for releases.
15249 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
15250 ERROR_ON_WARNING=yes
15251 fi
15252
15253 WERROR_CFLAGS=""
15254 if test "${ERROR_ON_WARNING}" = yes ; then
15255 WERROR_CFLAGS="-Werror"
15256 fi
15257
15258 # The options we'll try to enable.
15259 build_warnings="-Wall -Wpointer-arith \
15260 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
15261 -Wno-switch -Wno-char-subscripts \
15262 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
15263 -Wno-sign-compare -Wno-error=maybe-uninitialized \
15264 -Wno-mismatched-tags \
15265 -Wno-error=deprecated-register \
15266 -Wsuggest-override \
15267 -Wimplicit-fallthrough=3 \
15268 -Wduplicated-cond \
15269 -Wshadow=local \
15270 -Wdeprecated-copy \
15271 -Wdeprecated-copy-dtor \
15272 -Wredundant-move"
15273
15274 case "${host}" in
15275 *-*-mingw32*)
15276 # Enable -Wno-format by default when using gcc on mingw since many
15277 # GCC versions complain about %I64.
15278 build_warnings="$build_warnings -Wno-format" ;;
15279 *-*-solaris*)
15280 # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
15281 # doesn't understand.
15282 build_warnings="$build_warnings -Wno-unknown-pragmas"
15283 # Solaris 11 <unistd.h> marks vfork deprecated.
15284 build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
15285 *)
15286 # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
15287 # but there's a special case for this below.
15288 build_warnings="$build_warnings -Wformat-nonliteral" ;;
15289 esac
15290
15291 # Check whether --enable-build-warnings was given.
15292 if test "${enable_build_warnings+set}" = set; then :
15293 enableval=$enable_build_warnings; case "${enableval}" in
15294 yes) ;;
15295 no) build_warnings="-w";;
15296 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
15297 build_warnings="${build_warnings} ${t}";;
15298 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
15299 build_warnings="${t} ${build_warnings}";;
15300 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
15301 esac
15302 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
15303 echo "Setting compiler warning flags = $build_warnings" 6>&1
15304 fi
15305 fi
15306 # Check whether --enable-gdb-build-warnings was given.
15307 if test "${enable_gdb_build_warnings+set}" = set; then :
15308 enableval=$enable_gdb_build_warnings; case "${enableval}" in
15309 yes) ;;
15310 no) build_warnings="-w";;
15311 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
15312 build_warnings="${build_warnings} ${t}";;
15313 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
15314 build_warnings="${t} ${build_warnings}";;
15315 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
15316 esac
15317 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
15318 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
15319 fi
15320 fi
15321
15322 # The set of warnings supported by a C++ compiler is not the same as
15323 # of the C compiler.
15324 ac_ext=cpp
15325 ac_cpp='$CXXCPP $CPPFLAGS'
15326 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15327 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15328 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
15329
15330
15331 WARN_CFLAGS=""
15332 if test "x${build_warnings}" != x -a "x$GCC" = xyes
15333 then
15334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
15335 $as_echo_n "checking compiler warning flags... " >&6; }
15336 # Separate out the -Werror flag as some files just cannot be
15337 # compiled with it enabled.
15338 for w in ${build_warnings}; do
15339 # GCC does not complain about -Wno-unknown-warning. Invert
15340 # and test -Wunknown-warning instead.
15341 case $w in
15342 -Wno-*)
15343 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
15344 -Wformat-nonliteral)
15345 # gcc requires -Wformat before -Wformat-nonliteral
15346 # will work, so stick them together.
15347 w="-Wformat $w"
15348 wtest="$w"
15349 ;;
15350 *)
15351 wtest=$w ;;
15352 esac
15353
15354 case $w in
15355 -Werr*) WERROR_CFLAGS=-Werror ;;
15356 *)
15357 # Check whether GCC accepts it.
15358 saved_CFLAGS="$CFLAGS"
15359 CFLAGS="$CFLAGS -Werror $wtest"
15360 saved_CXXFLAGS="$CXXFLAGS"
15361 CXXFLAGS="$CXXFLAGS -Werror $wtest"
15362 if test "x$w" = "x-Wunused-variable"; then
15363 # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
15364 # fixed in GCC 4.9. This test is derived from the gdb
15365 # source code that triggered this bug in GCC.
15366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15367 /* end confdefs.h. */
15368 struct scoped_restore_base {};
15369 struct scoped_restore_tmpl : public scoped_restore_base {
15370 ~scoped_restore_tmpl() {}
15371 };
15372 int
15373 main ()
15374 {
15375 const scoped_restore_base &b = scoped_restore_tmpl();
15376 ;
15377 return 0;
15378 }
15379 _ACEOF
15380 if ac_fn_cxx_try_compile "$LINENO"; then :
15381 WARN_CFLAGS="${WARN_CFLAGS} $w"
15382 fi
15383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15384 else
15385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15386 /* end confdefs.h. */
15387
15388 int
15389 main ()
15390 {
15391
15392 ;
15393 return 0;
15394 }
15395 _ACEOF
15396 if ac_fn_cxx_try_compile "$LINENO"; then :
15397 WARN_CFLAGS="${WARN_CFLAGS} $w"
15398 fi
15399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15400 fi
15401 CFLAGS="$saved_CFLAGS"
15402 CXXFLAGS="$saved_CXXFLAGS"
15403 esac
15404 done
15405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
15406 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
15407 fi
15408
15409
15410
15411 ac_ext=c
15412 ac_cpp='$CPP $CPPFLAGS'
15413 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15414 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15415 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15416
15417
15418
15419 # Check whether --enable-ubsan was given.
15420 if test "${enable_ubsan+set}" = set; then :
15421 enableval=$enable_ubsan;
15422 else
15423 enable_ubsan=no
15424 fi
15425
15426 if test "x$enable_ubsan" = xauto; then
15427 if $development; then
15428 enable_ubsan=yes
15429 fi
15430 fi
15431 ac_ext=cpp
15432 ac_cpp='$CXXCPP $CPPFLAGS'
15433 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15434 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15435 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
15436
15437 if test "x$enable_ubsan" = xyes; then
15438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fsanitize=undefined is accepted" >&5
15439 $as_echo_n "checking whether -fsanitize=undefined is accepted... " >&6; }
15440 saved_CXXFLAGS="$CXXFLAGS"
15441 CXXFLAGS="$CXXFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
15442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15443 /* end confdefs.h. */
15444
15445 int
15446 main ()
15447 {
15448
15449 ;
15450 return 0;
15451 }
15452 _ACEOF
15453 if ac_fn_cxx_try_link "$LINENO"; then :
15454 enable_ubsan=yes
15455 else
15456 enable_ubsan=no
15457 fi
15458 rm -f core conftest.err conftest.$ac_objext \
15459 conftest$ac_exeext conftest.$ac_ext
15460 CXXFLAGS="$saved_CXXFLAGS"
15461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_ubsan" >&5
15462 $as_echo "$enable_ubsan" >&6; }
15463 if test "x$enable_ubsan" = xyes; then
15464 WARN_CFLAGS="$WARN_CFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
15465 CONFIG_LDFLAGS="$CONFIG_LDFLAGS -fsanitize=undefined"
15466 fi
15467 fi
15468 ac_ext=c
15469 ac_cpp='$CPP $CPPFLAGS'
15470 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15471 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15472 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15473
15474
15475
15476 # In the Cygwin environment, we need some additional flags.
15477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
15478 $as_echo_n "checking for cygwin... " >&6; }
15479 if ${gdb_cv_os_cygwin+:} false; then :
15480 $as_echo_n "(cached) " >&6
15481 else
15482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15483 /* end confdefs.h. */
15484
15485 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
15486 lose
15487 #endif
15488 _ACEOF
15489 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15490 $EGREP "^lose$" >/dev/null 2>&1; then :
15491 gdb_cv_os_cygwin=yes
15492 else
15493 gdb_cv_os_cygwin=no
15494 fi
15495 rm -f conftest*
15496
15497 fi
15498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
15499 $as_echo "$gdb_cv_os_cygwin" >&6; }
15500
15501
15502 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
15503 case ${host} in
15504 *go32* ) SER_HARDWIRE=ser-go32.o ;;
15505 *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
15506 *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
15507 *) SER_HARDWIRE="$SER_HARDWIRE ser-uds.o" ;;
15508 esac
15509
15510
15511 # libreadline needs libuser32.a in a cygwin environment
15512 WIN32LIBS=
15513 if test x$gdb_cv_os_cygwin = xyes; then
15514 WIN32LIBS="-luser32"
15515 case "${target}" in
15516 *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
15517 ;;
15518 esac
15519 fi
15520
15521 # The ser-tcp.c module requires sockets.
15522 case ${host} in
15523 *mingw32*)
15524
15525 $as_echo "#define USE_WIN32API 1" >>confdefs.h
15526
15527 WIN32LIBS="$WIN32LIBS -lws2_32"
15528 ;;
15529 esac
15530
15531
15532 # Add ELF support to GDB, but only if BFD includes ELF support.
15533
15534 OLD_CFLAGS=$CFLAGS
15535 OLD_LDFLAGS=$LDFLAGS
15536 OLD_LIBS=$LIBS
15537 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
15538 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
15539 # always want our bfd.
15540 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
15541 ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
15542 LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
15543 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
15544 LIBS="-lbfd -liberty -lz $intl $LIBS"
15545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
15546 $as_echo_n "checking for ELF support in BFD... " >&6; }
15547 if ${gdb_cv_var_elf+:} false; then :
15548 $as_echo_n "(cached) " >&6
15549 else
15550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15551 /* end confdefs.h. */
15552 #include <stdlib.h>
15553 #include "bfd.h"
15554 #include "elf-bfd.h"
15555
15556 int
15557 main ()
15558 {
15559 return bfd_get_elf_phdr_upper_bound (NULL);
15560 ;
15561 return 0;
15562 }
15563 _ACEOF
15564 if ac_fn_c_try_link "$LINENO"; then :
15565 gdb_cv_var_elf=yes
15566 else
15567 gdb_cv_var_elf=no
15568 fi
15569 rm -f core conftest.err conftest.$ac_objext \
15570 conftest$ac_exeext conftest.$ac_ext
15571 fi
15572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
15573 $as_echo "$gdb_cv_var_elf" >&6; }
15574 CFLAGS=$OLD_CFLAGS
15575 LDFLAGS=$OLD_LDFLAGS
15576 LIBS=$OLD_LIBS
15577 if test $gdb_cv_var_elf = yes; then
15578 CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o dtrace-probe.o"
15579
15580 $as_echo "#define HAVE_ELF 1" >>confdefs.h
15581
15582 # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
15583 if test "$plugins" = "yes"; then
15584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
15585 $as_echo_n "checking for library containing dlopen... " >&6; }
15586 if ${ac_cv_search_dlopen+:} false; then :
15587 $as_echo_n "(cached) " >&6
15588 else
15589 ac_func_search_save_LIBS=$LIBS
15590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15591 /* end confdefs.h. */
15592
15593 /* Override any GCC internal prototype to avoid an error.
15594 Use char because int might match the return type of a GCC
15595 builtin and then its argument prototype would still apply. */
15596 #ifdef __cplusplus
15597 extern "C"
15598 #endif
15599 char dlopen ();
15600 int
15601 main ()
15602 {
15603 return dlopen ();
15604 ;
15605 return 0;
15606 }
15607 _ACEOF
15608 for ac_lib in '' dl; do
15609 if test -z "$ac_lib"; then
15610 ac_res="none required"
15611 else
15612 ac_res=-l$ac_lib
15613 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15614 fi
15615 if ac_fn_c_try_link "$LINENO"; then :
15616 ac_cv_search_dlopen=$ac_res
15617 fi
15618 rm -f core conftest.err conftest.$ac_objext \
15619 conftest$ac_exeext
15620 if ${ac_cv_search_dlopen+:} false; then :
15621 break
15622 fi
15623 done
15624 if ${ac_cv_search_dlopen+:} false; then :
15625
15626 else
15627 ac_cv_search_dlopen=no
15628 fi
15629 rm conftest.$ac_ext
15630 LIBS=$ac_func_search_save_LIBS
15631 fi
15632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
15633 $as_echo "$ac_cv_search_dlopen" >&6; }
15634 ac_res=$ac_cv_search_dlopen
15635 if test "$ac_res" != no; then :
15636 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15637
15638 fi
15639
15640 fi
15641 fi
15642
15643 # Add macho support to GDB, but only if BFD includes it.
15644
15645 OLD_CFLAGS=$CFLAGS
15646 OLD_LDFLAGS=$LDFLAGS
15647 OLD_LIBS=$LIBS
15648 # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
15649 # points somewhere with bfd, with -I/foo/lib and -L/foo/lib. We
15650 # always want our bfd.
15651 CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
15652 ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
15653 LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
15654 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
15655 LIBS="-lbfd -liberty -lz $intl $LIBS"
15656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mach-O support in BFD" >&5
15657 $as_echo_n "checking for Mach-O support in BFD... " >&6; }
15658 if ${gdb_cv_var_macho+:} false; then :
15659 $as_echo_n "(cached) " >&6
15660 else
15661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15662 /* end confdefs.h. */
15663 #include <stdlib.h>
15664 #include "bfd.h"
15665 #include "mach-o.h"
15666
15667 int
15668 main ()
15669 {
15670 return bfd_mach_o_lookup_command (NULL, 0, NULL);
15671 ;
15672 return 0;
15673 }
15674 _ACEOF
15675 if ac_fn_c_try_link "$LINENO"; then :
15676 gdb_cv_var_macho=yes
15677 else
15678 gdb_cv_var_macho=no
15679 fi
15680 rm -f core conftest.err conftest.$ac_objext \
15681 conftest$ac_exeext conftest.$ac_ext
15682 fi
15683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_macho" >&5
15684 $as_echo "$gdb_cv_var_macho" >&6; }
15685 CFLAGS=$OLD_CFLAGS
15686 LDFLAGS=$OLD_LDFLAGS
15687 LIBS=$OLD_LIBS
15688 if test $gdb_cv_var_macho = yes; then
15689 CONFIG_OBS="$CONFIG_OBS machoread.o"
15690 fi
15691
15692 # Add any host-specific objects to GDB.
15693 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
15694
15695 # If building on ELF, look for lzma support for embedded compressed debug info.
15696 if test $gdb_cv_var_elf = yes; then
15697
15698 # Check whether --with-lzma was given.
15699 if test "${with_lzma+set}" = set; then :
15700 withval=$with_lzma;
15701 else
15702 with_lzma=auto
15703 fi
15704
15705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
15706 $as_echo_n "checking whether to use lzma... " >&6; }
15707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
15708 $as_echo "$with_lzma" >&6; }
15709
15710 if test "${with_lzma}" != no; then
15711
15712
15713
15714
15715
15716
15717
15718
15719 use_additional=yes
15720
15721 acl_save_prefix="$prefix"
15722 prefix="$acl_final_prefix"
15723 acl_save_exec_prefix="$exec_prefix"
15724 exec_prefix="$acl_final_exec_prefix"
15725
15726 eval additional_includedir=\"$includedir\"
15727 eval additional_libdir=\"$libdir\"
15728
15729 exec_prefix="$acl_save_exec_prefix"
15730 prefix="$acl_save_prefix"
15731
15732
15733 # Check whether --with-liblzma-prefix was given.
15734 if test "${with_liblzma_prefix+set}" = set; then :
15735 withval=$with_liblzma_prefix;
15736 if test "X$withval" = "Xno"; then
15737 use_additional=no
15738 else
15739 if test "X$withval" = "X"; then
15740
15741 acl_save_prefix="$prefix"
15742 prefix="$acl_final_prefix"
15743 acl_save_exec_prefix="$exec_prefix"
15744 exec_prefix="$acl_final_exec_prefix"
15745
15746 eval additional_includedir=\"$includedir\"
15747 eval additional_libdir=\"$libdir\"
15748
15749 exec_prefix="$acl_save_exec_prefix"
15750 prefix="$acl_save_prefix"
15751
15752 else
15753 additional_includedir="$withval/include"
15754 additional_libdir="$withval/lib"
15755 fi
15756 fi
15757
15758 fi
15759
15760 LIBLZMA=
15761 LTLIBLZMA=
15762 INCLZMA=
15763 rpathdirs=
15764 ltrpathdirs=
15765 names_already_handled=
15766 names_next_round='lzma '
15767 while test -n "$names_next_round"; do
15768 names_this_round="$names_next_round"
15769 names_next_round=
15770 for name in $names_this_round; do
15771 already_handled=
15772 for n in $names_already_handled; do
15773 if test "$n" = "$name"; then
15774 already_handled=yes
15775 break
15776 fi
15777 done
15778 if test -z "$already_handled"; then
15779 names_already_handled="$names_already_handled $name"
15780 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
15781 eval value=\"\$HAVE_LIB$uppername\"
15782 if test -n "$value"; then
15783 if test "$value" = yes; then
15784 eval value=\"\$LIB$uppername\"
15785 test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
15786 eval value=\"\$LTLIB$uppername\"
15787 test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
15788 else
15789 :
15790 fi
15791 else
15792 found_dir=
15793 found_la=
15794 found_so=
15795 found_a=
15796 if test $use_additional = yes; then
15797 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
15798 found_dir="$additional_libdir"
15799 found_so="$additional_libdir/lib$name.$shlibext"
15800 if test -f "$additional_libdir/lib$name.la"; then
15801 found_la="$additional_libdir/lib$name.la"
15802 fi
15803 else
15804 if test -f "$additional_libdir/lib$name.$libext"; then
15805 found_dir="$additional_libdir"
15806 found_a="$additional_libdir/lib$name.$libext"
15807 if test -f "$additional_libdir/lib$name.la"; then
15808 found_la="$additional_libdir/lib$name.la"
15809 fi
15810 fi
15811 fi
15812 fi
15813 if test "X$found_dir" = "X"; then
15814 for x in $LDFLAGS $LTLIBLZMA; do
15815
15816 acl_save_prefix="$prefix"
15817 prefix="$acl_final_prefix"
15818 acl_save_exec_prefix="$exec_prefix"
15819 exec_prefix="$acl_final_exec_prefix"
15820 eval x=\"$x\"
15821 exec_prefix="$acl_save_exec_prefix"
15822 prefix="$acl_save_prefix"
15823
15824 case "$x" in
15825 -L*)
15826 dir=`echo "X$x" | sed -e 's/^X-L//'`
15827 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
15828 found_dir="$dir"
15829 found_so="$dir/lib$name.$shlibext"
15830 if test -f "$dir/lib$name.la"; then
15831 found_la="$dir/lib$name.la"
15832 fi
15833 else
15834 if test -f "$dir/lib$name.$libext"; then
15835 found_dir="$dir"
15836 found_a="$dir/lib$name.$libext"
15837 if test -f "$dir/lib$name.la"; then
15838 found_la="$dir/lib$name.la"
15839 fi
15840 fi
15841 fi
15842 ;;
15843 esac
15844 if test "X$found_dir" != "X"; then
15845 break
15846 fi
15847 done
15848 fi
15849 if test "X$found_dir" != "X"; then
15850 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
15851 if test "X$found_so" != "X"; then
15852 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
15853 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15854 else
15855 haveit=
15856 for x in $ltrpathdirs; do
15857 if test "X$x" = "X$found_dir"; then
15858 haveit=yes
15859 break
15860 fi
15861 done
15862 if test -z "$haveit"; then
15863 ltrpathdirs="$ltrpathdirs $found_dir"
15864 fi
15865 if test "$hardcode_direct" = yes; then
15866 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15867 else
15868 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
15869 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15870 haveit=
15871 for x in $rpathdirs; do
15872 if test "X$x" = "X$found_dir"; then
15873 haveit=yes
15874 break
15875 fi
15876 done
15877 if test -z "$haveit"; then
15878 rpathdirs="$rpathdirs $found_dir"
15879 fi
15880 else
15881 haveit=
15882 for x in $LDFLAGS $LIBLZMA; do
15883
15884 acl_save_prefix="$prefix"
15885 prefix="$acl_final_prefix"
15886 acl_save_exec_prefix="$exec_prefix"
15887 exec_prefix="$acl_final_exec_prefix"
15888 eval x=\"$x\"
15889 exec_prefix="$acl_save_exec_prefix"
15890 prefix="$acl_save_prefix"
15891
15892 if test "X$x" = "X-L$found_dir"; then
15893 haveit=yes
15894 break
15895 fi
15896 done
15897 if test -z "$haveit"; then
15898 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
15899 fi
15900 if test "$hardcode_minus_L" != no; then
15901 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15902 else
15903 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
15904 fi
15905 fi
15906 fi
15907 fi
15908 else
15909 if test "X$found_a" != "X"; then
15910 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
15911 else
15912 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
15913 fi
15914 fi
15915 additional_includedir=
15916 case "$found_dir" in
15917 */lib | */lib/)
15918 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
15919 additional_includedir="$basedir/include"
15920 ;;
15921 esac
15922 if test "X$additional_includedir" != "X"; then
15923 if test "X$additional_includedir" != "X/usr/include"; then
15924 haveit=
15925 if test "X$additional_includedir" = "X/usr/local/include"; then
15926 if test -n "$GCC"; then
15927 case $host_os in
15928 linux*) haveit=yes;;
15929 esac
15930 fi
15931 fi
15932 if test -z "$haveit"; then
15933 for x in $CPPFLAGS $INCLZMA; do
15934
15935 acl_save_prefix="$prefix"
15936 prefix="$acl_final_prefix"
15937 acl_save_exec_prefix="$exec_prefix"
15938 exec_prefix="$acl_final_exec_prefix"
15939 eval x=\"$x\"
15940 exec_prefix="$acl_save_exec_prefix"
15941 prefix="$acl_save_prefix"
15942
15943 if test "X$x" = "X-I$additional_includedir"; then
15944 haveit=yes
15945 break
15946 fi
15947 done
15948 if test -z "$haveit"; then
15949 if test -d "$additional_includedir"; then
15950 INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
15951 fi
15952 fi
15953 fi
15954 fi
15955 fi
15956 if test -n "$found_la"; then
15957 save_libdir="$libdir"
15958 case "$found_la" in
15959 */* | *\\*) . "$found_la" ;;
15960 *) . "./$found_la" ;;
15961 esac
15962 libdir="$save_libdir"
15963 for dep in $dependency_libs; do
15964 case "$dep" in
15965 -L*)
15966 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
15967 if test "X$additional_libdir" != "X/usr/lib"; then
15968 haveit=
15969 if test "X$additional_libdir" = "X/usr/local/lib"; then
15970 if test -n "$GCC"; then
15971 case $host_os in
15972 linux*) haveit=yes;;
15973 esac
15974 fi
15975 fi
15976 if test -z "$haveit"; then
15977 haveit=
15978 for x in $LDFLAGS $LIBLZMA; do
15979
15980 acl_save_prefix="$prefix"
15981 prefix="$acl_final_prefix"
15982 acl_save_exec_prefix="$exec_prefix"
15983 exec_prefix="$acl_final_exec_prefix"
15984 eval x=\"$x\"
15985 exec_prefix="$acl_save_exec_prefix"
15986 prefix="$acl_save_prefix"
15987
15988 if test "X$x" = "X-L$additional_libdir"; then
15989 haveit=yes
15990 break
15991 fi
15992 done
15993 if test -z "$haveit"; then
15994 if test -d "$additional_libdir"; then
15995 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
15996 fi
15997 fi
15998 haveit=
15999 for x in $LDFLAGS $LTLIBLZMA; do
16000
16001 acl_save_prefix="$prefix"
16002 prefix="$acl_final_prefix"
16003 acl_save_exec_prefix="$exec_prefix"
16004 exec_prefix="$acl_final_exec_prefix"
16005 eval x=\"$x\"
16006 exec_prefix="$acl_save_exec_prefix"
16007 prefix="$acl_save_prefix"
16008
16009 if test "X$x" = "X-L$additional_libdir"; then
16010 haveit=yes
16011 break
16012 fi
16013 done
16014 if test -z "$haveit"; then
16015 if test -d "$additional_libdir"; then
16016 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
16017 fi
16018 fi
16019 fi
16020 fi
16021 ;;
16022 -R*)
16023 dir=`echo "X$dep" | sed -e 's/^X-R//'`
16024 if test "$enable_rpath" != no; then
16025 haveit=
16026 for x in $rpathdirs; do
16027 if test "X$x" = "X$dir"; then
16028 haveit=yes
16029 break
16030 fi
16031 done
16032 if test -z "$haveit"; then
16033 rpathdirs="$rpathdirs $dir"
16034 fi
16035 haveit=
16036 for x in $ltrpathdirs; do
16037 if test "X$x" = "X$dir"; then
16038 haveit=yes
16039 break
16040 fi
16041 done
16042 if test -z "$haveit"; then
16043 ltrpathdirs="$ltrpathdirs $dir"
16044 fi
16045 fi
16046 ;;
16047 -l*)
16048 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
16049 ;;
16050 *.la)
16051 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
16052 ;;
16053 *)
16054 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
16055 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
16056 ;;
16057 esac
16058 done
16059 fi
16060 else
16061 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
16062 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
16063 fi
16064 fi
16065 fi
16066 done
16067 done
16068 if test "X$rpathdirs" != "X"; then
16069 if test -n "$hardcode_libdir_separator"; then
16070 alldirs=
16071 for found_dir in $rpathdirs; do
16072 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
16073 done
16074 acl_save_libdir="$libdir"
16075 libdir="$alldirs"
16076 eval flag=\"$hardcode_libdir_flag_spec\"
16077 libdir="$acl_save_libdir"
16078 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
16079 else
16080 for found_dir in $rpathdirs; do
16081 acl_save_libdir="$libdir"
16082 libdir="$found_dir"
16083 eval flag=\"$hardcode_libdir_flag_spec\"
16084 libdir="$acl_save_libdir"
16085 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
16086 done
16087 fi
16088 fi
16089 if test "X$ltrpathdirs" != "X"; then
16090 for found_dir in $ltrpathdirs; do
16091 LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
16092 done
16093 fi
16094
16095
16096 ac_save_CPPFLAGS="$CPPFLAGS"
16097
16098 for element in $INCLZMA; do
16099 haveit=
16100 for x in $CPPFLAGS; do
16101
16102 acl_save_prefix="$prefix"
16103 prefix="$acl_final_prefix"
16104 acl_save_exec_prefix="$exec_prefix"
16105 exec_prefix="$acl_final_exec_prefix"
16106 eval x=\"$x\"
16107 exec_prefix="$acl_save_exec_prefix"
16108 prefix="$acl_save_prefix"
16109
16110 if test "X$x" = "X$element"; then
16111 haveit=yes
16112 break
16113 fi
16114 done
16115 if test -z "$haveit"; then
16116 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
16117 fi
16118 done
16119
16120
16121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
16122 $as_echo_n "checking for liblzma... " >&6; }
16123 if ${ac_cv_liblzma+:} false; then :
16124 $as_echo_n "(cached) " >&6
16125 else
16126
16127 ac_save_LIBS="$LIBS"
16128 LIBS="$LIBS $LIBLZMA"
16129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16130 /* end confdefs.h. */
16131 #include "lzma.h"
16132 int
16133 main ()
16134 {
16135 lzma_index_iter iter;
16136 lzma_index_iter_init (&iter, 0);
16137 lzma_mf_is_supported (LZMA_MF_HC3);
16138 ;
16139 return 0;
16140 }
16141 _ACEOF
16142 if ac_fn_c_try_link "$LINENO"; then :
16143 ac_cv_liblzma=yes
16144 else
16145 ac_cv_liblzma=no
16146 fi
16147 rm -f core conftest.err conftest.$ac_objext \
16148 conftest$ac_exeext conftest.$ac_ext
16149 LIBS="$ac_save_LIBS"
16150
16151 fi
16152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
16153 $as_echo "$ac_cv_liblzma" >&6; }
16154 if test "$ac_cv_liblzma" = yes; then
16155 HAVE_LIBLZMA=yes
16156
16157 $as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
16158
16159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
16160 $as_echo_n "checking how to link with liblzma... " >&6; }
16161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
16162 $as_echo "$LIBLZMA" >&6; }
16163 else
16164 HAVE_LIBLZMA=no
16165 CPPFLAGS="$ac_save_CPPFLAGS"
16166 LIBLZMA=
16167 LTLIBLZMA=
16168 fi
16169
16170
16171
16172
16173
16174
16175 if test "$HAVE_LIBLZMA" != yes; then
16176 if test "$with_lzma" = yes; then
16177 as_fn_error $? "missing liblzma for --with-lzma" "$LINENO" 5
16178 fi
16179 fi
16180 fi
16181 fi
16182
16183 LIBGUI="../libgui/src/libgui.a"
16184 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
16185
16186
16187
16188 WIN32LDAPP=
16189
16190
16191
16192 case "${host}" in
16193 *-*-cygwin* | *-*-mingw* )
16194 configdir="win"
16195 ;;
16196 *)
16197 configdir="unix"
16198 ;;
16199 esac
16200
16201 GDBTKLIBS=
16202 if test "${enable_gdbtk}" = "yes"; then
16203
16204 # Gdbtk must have an absolute path to srcdir in order to run
16205 # properly when not installed.
16206 here=`pwd`
16207 cd ${srcdir}
16208 GDBTK_SRC_DIR=`pwd`
16209 cd $here
16210
16211
16212 #
16213 # Ok, lets find the tcl configuration
16214 # First, look for one uninstalled.
16215 # the alternative search directory is invoked by --with-tcl
16216 #
16217
16218 if test x"${no_tcl}" = x ; then
16219 # we reset no_tcl in case something fails here
16220 no_tcl=true
16221
16222 # Check whether --with-tcl was given.
16223 if test "${with_tcl+set}" = set; then :
16224 withval=$with_tcl; with_tclconfig=${withval}
16225 fi
16226
16227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
16228 $as_echo_n "checking for Tcl configuration... " >&6; }
16229 if ${ac_cv_c_tclconfig+:} false; then :
16230 $as_echo_n "(cached) " >&6
16231 else
16232
16233
16234 # First check to see if --with-tcl was specified.
16235 case "${host}" in
16236 *-*-cygwin*) platDir="win" ;;
16237 *) platDir="unix" ;;
16238 esac
16239 if test x"${with_tclconfig}" != x ; then
16240 if test -f "${with_tclconfig}/tclConfig.sh" ; then
16241 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
16242 else
16243 as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
16244 fi
16245 fi
16246
16247 # then check for a private Tcl installation
16248 if test x"${ac_cv_c_tclconfig}" = x ; then
16249 for i in \
16250 ../tcl \
16251 `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16252 `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
16253 `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
16254 ../../tcl \
16255 `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16256 `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
16257 `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
16258 ../../../tcl \
16259 `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16260 `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
16261 `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
16262 if test -f "$i/$platDir/tclConfig.sh" ; then
16263 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
16264 break
16265 fi
16266 done
16267 fi
16268
16269 # on Darwin, check in Framework installation locations
16270 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
16271 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
16272 `ls -d /Library/Frameworks 2>/dev/null` \
16273 `ls -d /Network/Library/Frameworks 2>/dev/null` \
16274 `ls -d /System/Library/Frameworks 2>/dev/null` \
16275 ; do
16276 if test -f "$i/Tcl.framework/tclConfig.sh" ; then
16277 ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
16278 break
16279 fi
16280 done
16281 fi
16282
16283 # check in a few common install locations
16284 if test x"${ac_cv_c_tclconfig}" = x ; then
16285 for i in `ls -d ${libdir} 2>/dev/null` \
16286 `ls -d ${exec_prefix}/lib 2>/dev/null` \
16287 `ls -d ${prefix}/lib 2>/dev/null` \
16288 `ls -d /usr/local/lib 2>/dev/null` \
16289 `ls -d /usr/contrib/lib 2>/dev/null` \
16290 `ls -d /usr/lib 2>/dev/null` \
16291 ; do
16292 if test -f "$i/tclConfig.sh" ; then
16293 ac_cv_c_tclconfig=`(cd $i; pwd)`
16294 break
16295 fi
16296 done
16297 fi
16298
16299 # check in a few other private locations
16300 if test x"${ac_cv_c_tclconfig}" = x ; then
16301 for i in \
16302 ${srcdir}/../tcl \
16303 `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16304 `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
16305 `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
16306 if test -f "$i/$platDir/tclConfig.sh" ; then
16307 ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
16308 break
16309 fi
16310 done
16311 fi
16312
16313 fi
16314
16315
16316 if test x"${ac_cv_c_tclconfig}" = x ; then
16317 TCL_BIN_DIR="# no Tcl configs found"
16318 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
16319 $as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
16320 else
16321 no_tcl=
16322 TCL_BIN_DIR=${ac_cv_c_tclconfig}
16323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
16324 $as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
16325 fi
16326 fi
16327
16328
16329 # If $no_tk is nonempty, then we can't do Tk, and there is no
16330 # point to doing Tcl.
16331
16332 #
16333 # Ok, lets find the tk configuration
16334 # First, look for one uninstalled.
16335 # the alternative search directory is invoked by --with-tk
16336 #
16337
16338 if test x"${no_tk}" = x ; then
16339 # we reset no_tk in case something fails here
16340 no_tk=true
16341
16342 # Check whether --with-tk was given.
16343 if test "${with_tk+set}" = set; then :
16344 withval=$with_tk; with_tkconfig=${withval}
16345 fi
16346
16347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
16348 $as_echo_n "checking for Tk configuration... " >&6; }
16349 if ${ac_cv_c_tkconfig+:} false; then :
16350 $as_echo_n "(cached) " >&6
16351 else
16352
16353
16354 # First check to see if --with-tkconfig was specified.
16355 if test x"${with_tkconfig}" != x ; then
16356 if test -f "${with_tkconfig}/tkConfig.sh" ; then
16357 ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
16358 else
16359 as_fn_error $? "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
16360 fi
16361 fi
16362
16363 # then check for a private Tk library
16364 case "${host}" in
16365 *-*-cygwin*) platDir="win" ;;
16366 *) platDir="unix" ;;
16367 esac
16368 if test x"${ac_cv_c_tkconfig}" = x ; then
16369 for i in \
16370 ../tk \
16371 `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16372 `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
16373 `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
16374 ../../tk \
16375 `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16376 `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
16377 `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
16378 ../../../tk \
16379 `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16380 `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
16381 `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
16382 if test -f "$i/$platDir/tkConfig.sh" ; then
16383 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
16384 break
16385 fi
16386 done
16387 fi
16388
16389 # on Darwin, check in Framework installation locations
16390 if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
16391 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
16392 `ls -d /Library/Frameworks 2>/dev/null` \
16393 `ls -d /Network/Library/Frameworks 2>/dev/null` \
16394 `ls -d /System/Library/Frameworks 2>/dev/null` \
16395 ; do
16396 if test -f "$i/Tk.framework/tkConfig.sh" ; then
16397 ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
16398 break
16399 fi
16400 done
16401 fi
16402
16403 # check in a few common install locations
16404 if test x"${ac_cv_c_tkconfig}" = x ; then
16405 for i in `ls -d ${libdir} 2>/dev/null` \
16406 `ls -d ${exec_prefix}/lib 2>/dev/null` \
16407 `ls -d ${prefix}/lib 2>/dev/null` \
16408 `ls -d /usr/local/lib 2>/dev/null` \
16409 `ls -d /usr/contrib/lib 2>/dev/null` \
16410 `ls -d /usr/lib 2>/dev/null` \
16411 ; do
16412 if test -f "$i/tkConfig.sh" ; then
16413 ac_cv_c_tkconfig=`(cd $i; pwd)`
16414 break
16415 fi
16416 done
16417 fi
16418 # check in a few other private locations
16419 if test x"${ac_cv_c_tkconfig}" = x ; then
16420 for i in \
16421 ${srcdir}/../tk \
16422 `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16423 `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
16424 `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
16425 if test -f "$i/$platDir/tkConfig.sh" ; then
16426 ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
16427 break
16428 fi
16429 done
16430 fi
16431
16432 fi
16433
16434
16435 if test x"${ac_cv_c_tkconfig}" = x ; then
16436 TK_BIN_DIR="# no Tk configs found"
16437 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
16438 $as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
16439 else
16440 no_tk=
16441 TK_BIN_DIR=${ac_cv_c_tkconfig}
16442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
16443 $as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
16444 fi
16445 fi
16446
16447
16448 if test -z "${no_tcl}" -a -z "${no_tk}"; then
16449
16450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
16451 $as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
16452
16453 if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
16454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
16455 $as_echo "loading" >&6; }
16456 . ${TCL_BIN_DIR}/tclConfig.sh
16457 else
16458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
16459 $as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
16460 fi
16461
16462 # eval is required to do the TCL_DBGX substitution
16463 eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
16464 eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
16465
16466 # If the TCL_BIN_DIR is the build directory (not the install directory),
16467 # then set the common variable name to the value of the build variables.
16468 # For example, the variable TCL_LIB_SPEC will be set to the value
16469 # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
16470 # instead of TCL_BUILD_LIB_SPEC since it will work with both an
16471 # installed and uninstalled version of Tcl.
16472 if test -f "${TCL_BIN_DIR}/Makefile" ; then
16473 TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
16474 TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
16475 TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
16476 elif test "`uname -s`" = "Darwin"; then
16477 # If Tcl was built as a framework, attempt to use the libraries
16478 # from the framework at the given location so that linking works
16479 # against Tcl.framework installed in an arbitrary location.
16480 case ${TCL_DEFS} in
16481 *TCL_FRAMEWORK*)
16482 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
16483 for i in "`cd ${TCL_BIN_DIR}; pwd`" \
16484 "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
16485 if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
16486 TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
16487 break
16488 fi
16489 done
16490 fi
16491 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
16492 TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
16493 TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
16494 fi
16495 ;;
16496 esac
16497 fi
16498
16499 # eval is required to do the TCL_DBGX substitution
16500 eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
16501 eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
16502 eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
16503 eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
16504
16505
16506
16507
16508
16509
16510
16511
16512
16513
16514
16515
16516
16517
16518
16519 # Check for in-tree tcl
16520 here=`pwd`
16521 cd ${srcdir}/..
16522 topdir=`pwd`
16523 cd ${here}
16524
16525 intree="no"
16526 if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
16527 intree="yes"
16528 fi
16529
16530 # Find Tcl private headers
16531 if test x"${intree}" = xno; then
16532
16533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
16534 $as_echo_n "checking for Tcl private headers... " >&6; }
16535 private_dir=""
16536 dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
16537 if test -f ${dir}/tclInt.h ; then
16538 private_dir=${dir}
16539 fi
16540
16541 if test x"${private_dir}" = x; then
16542 as_fn_error $? "could not find private Tcl headers" "$LINENO" 5
16543 else
16544 TCL_PRIVATE_INCLUDE="-I${private_dir}"
16545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
16546 $as_echo "${private_dir}" >&6; }
16547 fi
16548
16549 TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
16550 TCL_LIBRARY="${TCL_LIB_SPEC}"
16551 TCL_DEPS=""
16552 else
16553 # If building tcl in the same src tree, private headers
16554 # are not needed, but we need to be sure to use the right
16555 # headers library
16556 TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
16557 TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
16558 TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
16559 fi
16560
16561
16562
16563
16564
16565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
16566 $as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
16567
16568 if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
16569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
16570 $as_echo "loading" >&6; }
16571 . ${TK_BIN_DIR}/tkConfig.sh
16572 else
16573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
16574 $as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
16575 fi
16576
16577 # eval is required to do the TK_DBGX substitution
16578 eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
16579 eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
16580
16581 # If the TK_BIN_DIR is the build directory (not the install directory),
16582 # then set the common variable name to the value of the build variables.
16583 # For example, the variable TK_LIB_SPEC will be set to the value
16584 # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
16585 # instead of TK_BUILD_LIB_SPEC since it will work with both an
16586 # installed and uninstalled version of Tcl.
16587 if test -f "${TK_BIN_DIR}/Makefile" ; then
16588 TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
16589 TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
16590 TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
16591 elif test "`uname -s`" = "Darwin"; then
16592 # If Tk was built as a framework, attempt to use the libraries
16593 # from the framework at the given location so that linking works
16594 # against Tk.framework installed in an arbitrary location.
16595 case ${TK_DEFS} in
16596 *TK_FRAMEWORK*)
16597 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
16598 for i in "`cd ${TK_BIN_DIR}; pwd`" \
16599 "`cd ${TK_BIN_DIR}/../..; pwd`"; do
16600 if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
16601 TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
16602 break
16603 fi
16604 done
16605 fi
16606 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
16607 TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
16608 TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
16609 fi
16610 ;;
16611 esac
16612 fi
16613
16614 # eval is required to do the TK_DBGX substitution
16615 eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
16616 eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
16617 eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
16618 eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
16619
16620
16621
16622
16623
16624
16625
16626
16627
16628
16629
16630
16631
16632
16633 # Check for in-tree Tk
16634 intree="no"
16635 if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
16636 intree="yes"
16637 fi
16638
16639 # Find Tk private headers
16640 if test x"${intree}" = xno; then
16641
16642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
16643 $as_echo_n "checking for Tk private headers... " >&6; }
16644 private_dir=""
16645 dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
16646 if test -f ${dir}/tkInt.h; then
16647 private_dir=${dir}
16648 fi
16649
16650 if test x"${private_dir}" = x; then
16651 as_fn_error $? "could not find Tk private headers" "$LINENO" 5
16652 else
16653 TK_PRIVATE_INCLUDE="-I${private_dir}"
16654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
16655 $as_echo "${private_dir}" >&6; }
16656 fi
16657
16658 TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
16659 TK_LIBRARY=${TK_LIB_SPEC}
16660 TK_DEPS=""
16661 else
16662 TK_INCLUDE="-I${TK_SRC_DIR}/generic"
16663 TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
16664 TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
16665 fi
16666
16667
16668
16669
16670
16671 ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
16672
16673 # Include some libraries that Tcl and Tk want.
16674 TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
16675 # Yes, the ordering seems wrong here. But it isn't.
16676 # TK_LIBS is the list of libraries that need to be linked
16677 # after Tcl/Tk. Note that this isn't put into LIBS. If it
16678 # were in LIBS then any link tests after this point would
16679 # try to include things like `$(LIBGUI)', which wouldn't work.
16680 GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
16681
16682 CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
16683 CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
16684 CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
16685 CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
16686 CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
16687 CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
16688 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
16689
16690 if test x$gdb_cv_os_cygwin = xyes; then
16691 WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
16692 WIN32LDAPP="-Wl,--subsystem,console"
16693 CONFIG_OBS="${CONFIG_OBS} gdbres.o"
16694 fi
16695
16696 subdirs="$subdirs gdbtk"
16697
16698 fi
16699 fi
16700
16701
16702
16703
16704
16705
16706
16707
16708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
16709 $as_echo_n "checking for X... " >&6; }
16710
16711
16712 # Check whether --with-x was given.
16713 if test "${with_x+set}" = set; then :
16714 withval=$with_x;
16715 fi
16716
16717 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
16718 if test "x$with_x" = xno; then
16719 # The user explicitly disabled X.
16720 have_x=disabled
16721 else
16722 case $x_includes,$x_libraries in #(
16723 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
16724 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
16725 $as_echo_n "(cached) " >&6
16726 else
16727 # One or both of the vars are not set, and there is no cached value.
16728 ac_x_includes=no ac_x_libraries=no
16729 rm -f -r conftest.dir
16730 if mkdir conftest.dir; then
16731 cd conftest.dir
16732 cat >Imakefile <<'_ACEOF'
16733 incroot:
16734 @echo incroot='${INCROOT}'
16735 usrlibdir:
16736 @echo usrlibdir='${USRLIBDIR}'
16737 libdir:
16738 @echo libdir='${LIBDIR}'
16739 _ACEOF
16740 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
16741 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
16742 for ac_var in incroot usrlibdir libdir; do
16743 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
16744 done
16745 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
16746 for ac_extension in a so sl dylib la dll; do
16747 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
16748 test -f "$ac_im_libdir/libX11.$ac_extension"; then
16749 ac_im_usrlibdir=$ac_im_libdir; break
16750 fi
16751 done
16752 # Screen out bogus values from the imake configuration. They are
16753 # bogus both because they are the default anyway, and because
16754 # using them would break gcc on systems where it needs fixed includes.
16755 case $ac_im_incroot in
16756 /usr/include) ac_x_includes= ;;
16757 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
16758 esac
16759 case $ac_im_usrlibdir in
16760 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
16761 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
16762 esac
16763 fi
16764 cd ..
16765 rm -f -r conftest.dir
16766 fi
16767
16768 # Standard set of common directories for X headers.
16769 # Check X11 before X11Rn because it is often a symlink to the current release.
16770 ac_x_header_dirs='
16771 /usr/X11/include
16772 /usr/X11R7/include
16773 /usr/X11R6/include
16774 /usr/X11R5/include
16775 /usr/X11R4/include
16776
16777 /usr/include/X11
16778 /usr/include/X11R7
16779 /usr/include/X11R6
16780 /usr/include/X11R5
16781 /usr/include/X11R4
16782
16783 /usr/local/X11/include
16784 /usr/local/X11R7/include
16785 /usr/local/X11R6/include
16786 /usr/local/X11R5/include
16787 /usr/local/X11R4/include
16788
16789 /usr/local/include/X11
16790 /usr/local/include/X11R7
16791 /usr/local/include/X11R6
16792 /usr/local/include/X11R5
16793 /usr/local/include/X11R4
16794
16795 /usr/X386/include
16796 /usr/x386/include
16797 /usr/XFree86/include/X11
16798
16799 /usr/include
16800 /usr/local/include
16801 /usr/unsupported/include
16802 /usr/athena/include
16803 /usr/local/x11r5/include
16804 /usr/lpp/Xamples/include
16805
16806 /usr/openwin/include
16807 /usr/openwin/share/include'
16808
16809 if test "$ac_x_includes" = no; then
16810 # Guess where to find include files, by looking for Xlib.h.
16811 # First, try using that file with no special directory specified.
16812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16813 /* end confdefs.h. */
16814 #include <X11/Xlib.h>
16815 _ACEOF
16816 if ac_fn_c_try_cpp "$LINENO"; then :
16817 # We can compile using X headers with no special include directory.
16818 ac_x_includes=
16819 else
16820 for ac_dir in $ac_x_header_dirs; do
16821 if test -r "$ac_dir/X11/Xlib.h"; then
16822 ac_x_includes=$ac_dir
16823 break
16824 fi
16825 done
16826 fi
16827 rm -f conftest.err conftest.i conftest.$ac_ext
16828 fi # $ac_x_includes = no
16829
16830 if test "$ac_x_libraries" = no; then
16831 # Check for the libraries.
16832 # See if we find them without any special options.
16833 # Don't add to $LIBS permanently.
16834 ac_save_LIBS=$LIBS
16835 LIBS="-lX11 $LIBS"
16836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16837 /* end confdefs.h. */
16838 #include <X11/Xlib.h>
16839 int
16840 main ()
16841 {
16842 XrmInitialize ()
16843 ;
16844 return 0;
16845 }
16846 _ACEOF
16847 if ac_fn_c_try_link "$LINENO"; then :
16848 LIBS=$ac_save_LIBS
16849 # We can link X programs with no special library path.
16850 ac_x_libraries=
16851 else
16852 LIBS=$ac_save_LIBS
16853 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
16854 do
16855 # Don't even attempt the hair of trying to link an X program!
16856 for ac_extension in a so sl dylib la dll; do
16857 if test -r "$ac_dir/libX11.$ac_extension"; then
16858 ac_x_libraries=$ac_dir
16859 break 2
16860 fi
16861 done
16862 done
16863 fi
16864 rm -f core conftest.err conftest.$ac_objext \
16865 conftest$ac_exeext conftest.$ac_ext
16866 fi # $ac_x_libraries = no
16867
16868 case $ac_x_includes,$ac_x_libraries in #(
16869 no,* | *,no | *\'*)
16870 # Didn't find X, or a directory has "'" in its name.
16871 ac_cv_have_x="have_x=no";; #(
16872 *)
16873 # Record where we found X for the cache.
16874 ac_cv_have_x="have_x=yes\
16875 ac_x_includes='$ac_x_includes'\
16876 ac_x_libraries='$ac_x_libraries'"
16877 esac
16878 fi
16879 ;; #(
16880 *) have_x=yes;;
16881 esac
16882 eval "$ac_cv_have_x"
16883 fi # $with_x != no
16884
16885 if test "$have_x" != yes; then
16886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
16887 $as_echo "$have_x" >&6; }
16888 no_x=yes
16889 else
16890 # If each of the values was on the command line, it overrides each guess.
16891 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
16892 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
16893 # Update the cache value to reflect the command line values.
16894 ac_cv_have_x="have_x=yes\
16895 ac_x_includes='$x_includes'\
16896 ac_x_libraries='$x_libraries'"
16897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
16898 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
16899 fi
16900
16901
16902 # Unlike the sim directory, whether a simulator is linked is controlled by
16903 # presence of a gdb_sim definition in the target configure.tgt entry.
16904 # This code just checks for a few cases where we'd like to ignore those
16905 # definitions, even when they're present in the '.mt' file. These cases
16906 # are when --disable-sim is specified, or if the simulator directory is
16907 # not part of the source tree.
16908 #
16909 # Check whether --enable-sim was given.
16910 if test "${enable_sim+set}" = set; then :
16911 enableval=$enable_sim; echo "enable_sim = $enable_sim";
16912 echo "enableval = ${enableval}";
16913 case "${enableval}" in
16914 yes) ignore_sim=false ;;
16915 no) ignore_sim=true ;;
16916 *) ignore_sim=false ;;
16917 esac
16918 else
16919 ignore_sim=false
16920 fi
16921
16922
16923 if test ! -d "${srcdir}/../sim"; then
16924 ignore_sim=true
16925 fi
16926
16927 SIM=
16928 SIM_OBS=
16929 if test "${ignore_sim}" = "false"; then
16930 if test x"${gdb_sim}" != x ; then
16931 SIM="${gdb_sim}"
16932 SIM_OBS="remote-sim.o"
16933
16934 $as_echo "#define WITH_SIM 1" >>confdefs.h
16935
16936
16937 # Some tdep code should only be compiled in when the ppc sim is
16938 # built. PR sim/13418.
16939 case $target in
16940 powerpc*-*-*)
16941
16942 $as_echo "#define WITH_PPC_SIM 1" >>confdefs.h
16943
16944 ;;
16945 esac
16946 fi
16947 fi
16948
16949
16950
16951
16952
16953
16954
16955
16956
16957
16958
16959
16960
16961
16962 # List of host floatformats.
16963
16964 cat >>confdefs.h <<_ACEOF
16965 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
16966 _ACEOF
16967
16968
16969 cat >>confdefs.h <<_ACEOF
16970 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
16971 _ACEOF
16972
16973
16974 cat >>confdefs.h <<_ACEOF
16975 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
16976 _ACEOF
16977
16978
16979 # target_subdir is used by the testsuite to find the target libraries.
16980 target_subdir=
16981 if test "${host}" != "${target}"; then
16982 target_subdir="${target_alias}/"
16983 fi
16984
16985
16986 # Import nat definitions.
16987 nat_makefile_frag=/dev/null
16988 if test "${gdb_native}" = "yes"; then
16989 . ${srcdir}/configure.nat
16990 nativefile=$NAT_FILE
16991 fi
16992
16993
16994
16995
16996
16997
16998
16999
17000
17001
17002
17003 if test x"${gdb_osabi}" != x ; then
17004
17005 cat >>confdefs.h <<_ACEOF
17006 #define GDB_OSABI_DEFAULT $gdb_osabi
17007 _ACEOF
17008
17009 fi
17010
17011 # Check whether --enable-gdbserver was given.
17012 if test "${enable_gdbserver+set}" = set; then :
17013 enableval=$enable_gdbserver; case "${enableval}" in
17014 yes| no|auto) ;;
17015 *) as_fn_error $? "bad value ${enableval} for --enable-gdbserver option" "$LINENO" 5 ;;
17016 esac
17017 else
17018 enable_gdbserver=auto
17019 fi
17020
17021
17022 # We only build gdbserver automatically in a native configuration, and
17023 # only if the user did not explicitly disable its build.
17024 if test "$gdb_native" = "yes" -a "$enable_gdbserver" != "no"; then
17025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gdbserver is supported on this host" >&5
17026 $as_echo_n "checking whether gdbserver is supported on this host... " >&6; }
17027 if test "x$build_gdbserver" = xyes; then
17028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17029 $as_echo "yes" >&6; }
17030 subdirs="$subdirs gdbserver"
17031
17032 gdbserver_build_enabled=yes
17033 else
17034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17035 $as_echo "no" >&6; }
17036 fi
17037 fi
17038
17039 # If the user explicitly request the gdbserver to be built, verify that
17040 # we were in fact able to enable it.
17041 if test "$enable_gdbserver" = "yes" -a "$gdbserver_build_enabled" != "yes"; then
17042 as_fn_error $? "Automatic gdbserver build is not supported for this configuration" "$LINENO" 5
17043 fi
17044
17045 # Check for babeltrace and babeltrace-ctf
17046
17047 # Check whether --with-babeltrace was given.
17048 if test "${with_babeltrace+set}" = set; then :
17049 withval=$with_babeltrace;
17050 else
17051 with_babeltrace=auto
17052 fi
17053
17054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use babeltrace" >&5
17055 $as_echo_n "checking whether to use babeltrace... " >&6; }
17056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_babeltrace" >&5
17057 $as_echo "$with_babeltrace" >&6; }
17058
17059 if test "x$with_babeltrace" = "xno"; then
17060 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&5
17061 $as_echo "$as_me: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&2;}
17062 else
17063 # Append -Werror to CFLAGS so that configure can catch the warning
17064 # "assignment from incompatible pointer type", which is related to
17065 # the babeltrace change from 1.0.3 to 1.1.0. Babeltrace 1.1.0 works
17066 # in GDB, while babeltrace 1.0.3 is broken.
17067 # AC_LIB_HAVE_LINKFLAGS may modify CPPFLAGS in it, so it should be
17068 # safe to save and restore CFLAGS here.
17069 saved_CFLAGS=$CFLAGS
17070 CFLAGS="$CFLAGS -Werror"
17071
17072
17073
17074
17075
17076
17077
17078
17079 use_additional=yes
17080
17081 acl_save_prefix="$prefix"
17082 prefix="$acl_final_prefix"
17083 acl_save_exec_prefix="$exec_prefix"
17084 exec_prefix="$acl_final_exec_prefix"
17085
17086 eval additional_includedir=\"$includedir\"
17087 eval additional_libdir=\"$libdir\"
17088
17089 exec_prefix="$acl_save_exec_prefix"
17090 prefix="$acl_save_prefix"
17091
17092
17093 # Check whether --with-libbabeltrace-prefix was given.
17094 if test "${with_libbabeltrace_prefix+set}" = set; then :
17095 withval=$with_libbabeltrace_prefix;
17096 if test "X$withval" = "Xno"; then
17097 use_additional=no
17098 else
17099 if test "X$withval" = "X"; then
17100
17101 acl_save_prefix="$prefix"
17102 prefix="$acl_final_prefix"
17103 acl_save_exec_prefix="$exec_prefix"
17104 exec_prefix="$acl_final_exec_prefix"
17105
17106 eval additional_includedir=\"$includedir\"
17107 eval additional_libdir=\"$libdir\"
17108
17109 exec_prefix="$acl_save_exec_prefix"
17110 prefix="$acl_save_prefix"
17111
17112 else
17113 additional_includedir="$withval/include"
17114 additional_libdir="$withval/lib"
17115 fi
17116 fi
17117
17118 fi
17119
17120 LIBBABELTRACE=
17121 LTLIBBABELTRACE=
17122 INCBABELTRACE=
17123 rpathdirs=
17124 ltrpathdirs=
17125 names_already_handled=
17126 names_next_round='babeltrace babeltrace-ctf'
17127 while test -n "$names_next_round"; do
17128 names_this_round="$names_next_round"
17129 names_next_round=
17130 for name in $names_this_round; do
17131 already_handled=
17132 for n in $names_already_handled; do
17133 if test "$n" = "$name"; then
17134 already_handled=yes
17135 break
17136 fi
17137 done
17138 if test -z "$already_handled"; then
17139 names_already_handled="$names_already_handled $name"
17140 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
17141 eval value=\"\$HAVE_LIB$uppername\"
17142 if test -n "$value"; then
17143 if test "$value" = yes; then
17144 eval value=\"\$LIB$uppername\"
17145 test -z "$value" || LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$value"
17146 eval value=\"\$LTLIB$uppername\"
17147 test -z "$value" || LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$value"
17148 else
17149 :
17150 fi
17151 else
17152 found_dir=
17153 found_la=
17154 found_so=
17155 found_a=
17156 if test $use_additional = yes; then
17157 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
17158 found_dir="$additional_libdir"
17159 found_so="$additional_libdir/lib$name.$shlibext"
17160 if test -f "$additional_libdir/lib$name.la"; then
17161 found_la="$additional_libdir/lib$name.la"
17162 fi
17163 else
17164 if test -f "$additional_libdir/lib$name.$libext"; then
17165 found_dir="$additional_libdir"
17166 found_a="$additional_libdir/lib$name.$libext"
17167 if test -f "$additional_libdir/lib$name.la"; then
17168 found_la="$additional_libdir/lib$name.la"
17169 fi
17170 fi
17171 fi
17172 fi
17173 if test "X$found_dir" = "X"; then
17174 for x in $LDFLAGS $LTLIBBABELTRACE; do
17175
17176 acl_save_prefix="$prefix"
17177 prefix="$acl_final_prefix"
17178 acl_save_exec_prefix="$exec_prefix"
17179 exec_prefix="$acl_final_exec_prefix"
17180 eval x=\"$x\"
17181 exec_prefix="$acl_save_exec_prefix"
17182 prefix="$acl_save_prefix"
17183
17184 case "$x" in
17185 -L*)
17186 dir=`echo "X$x" | sed -e 's/^X-L//'`
17187 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
17188 found_dir="$dir"
17189 found_so="$dir/lib$name.$shlibext"
17190 if test -f "$dir/lib$name.la"; then
17191 found_la="$dir/lib$name.la"
17192 fi
17193 else
17194 if test -f "$dir/lib$name.$libext"; then
17195 found_dir="$dir"
17196 found_a="$dir/lib$name.$libext"
17197 if test -f "$dir/lib$name.la"; then
17198 found_la="$dir/lib$name.la"
17199 fi
17200 fi
17201 fi
17202 ;;
17203 esac
17204 if test "X$found_dir" != "X"; then
17205 break
17206 fi
17207 done
17208 fi
17209 if test "X$found_dir" != "X"; then
17210 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$found_dir -l$name"
17211 if test "X$found_so" != "X"; then
17212 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
17213 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17214 else
17215 haveit=
17216 for x in $ltrpathdirs; do
17217 if test "X$x" = "X$found_dir"; then
17218 haveit=yes
17219 break
17220 fi
17221 done
17222 if test -z "$haveit"; then
17223 ltrpathdirs="$ltrpathdirs $found_dir"
17224 fi
17225 if test "$hardcode_direct" = yes; then
17226 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17227 else
17228 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
17229 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17230 haveit=
17231 for x in $rpathdirs; do
17232 if test "X$x" = "X$found_dir"; then
17233 haveit=yes
17234 break
17235 fi
17236 done
17237 if test -z "$haveit"; then
17238 rpathdirs="$rpathdirs $found_dir"
17239 fi
17240 else
17241 haveit=
17242 for x in $LDFLAGS $LIBBABELTRACE; do
17243
17244 acl_save_prefix="$prefix"
17245 prefix="$acl_final_prefix"
17246 acl_save_exec_prefix="$exec_prefix"
17247 exec_prefix="$acl_final_exec_prefix"
17248 eval x=\"$x\"
17249 exec_prefix="$acl_save_exec_prefix"
17250 prefix="$acl_save_prefix"
17251
17252 if test "X$x" = "X-L$found_dir"; then
17253 haveit=yes
17254 break
17255 fi
17256 done
17257 if test -z "$haveit"; then
17258 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir"
17259 fi
17260 if test "$hardcode_minus_L" != no; then
17261 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17262 else
17263 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
17264 fi
17265 fi
17266 fi
17267 fi
17268 else
17269 if test "X$found_a" != "X"; then
17270 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_a"
17271 else
17272 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir -l$name"
17273 fi
17274 fi
17275 additional_includedir=
17276 case "$found_dir" in
17277 */lib | */lib/)
17278 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
17279 additional_includedir="$basedir/include"
17280 ;;
17281 esac
17282 if test "X$additional_includedir" != "X"; then
17283 if test "X$additional_includedir" != "X/usr/include"; then
17284 haveit=
17285 if test "X$additional_includedir" = "X/usr/local/include"; then
17286 if test -n "$GCC"; then
17287 case $host_os in
17288 linux*) haveit=yes;;
17289 esac
17290 fi
17291 fi
17292 if test -z "$haveit"; then
17293 for x in $CPPFLAGS $INCBABELTRACE; do
17294
17295 acl_save_prefix="$prefix"
17296 prefix="$acl_final_prefix"
17297 acl_save_exec_prefix="$exec_prefix"
17298 exec_prefix="$acl_final_exec_prefix"
17299 eval x=\"$x\"
17300 exec_prefix="$acl_save_exec_prefix"
17301 prefix="$acl_save_prefix"
17302
17303 if test "X$x" = "X-I$additional_includedir"; then
17304 haveit=yes
17305 break
17306 fi
17307 done
17308 if test -z "$haveit"; then
17309 if test -d "$additional_includedir"; then
17310 INCBABELTRACE="${INCBABELTRACE}${INCBABELTRACE:+ }-I$additional_includedir"
17311 fi
17312 fi
17313 fi
17314 fi
17315 fi
17316 if test -n "$found_la"; then
17317 save_libdir="$libdir"
17318 case "$found_la" in
17319 */* | *\\*) . "$found_la" ;;
17320 *) . "./$found_la" ;;
17321 esac
17322 libdir="$save_libdir"
17323 for dep in $dependency_libs; do
17324 case "$dep" in
17325 -L*)
17326 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
17327 if test "X$additional_libdir" != "X/usr/lib"; then
17328 haveit=
17329 if test "X$additional_libdir" = "X/usr/local/lib"; then
17330 if test -n "$GCC"; then
17331 case $host_os in
17332 linux*) haveit=yes;;
17333 esac
17334 fi
17335 fi
17336 if test -z "$haveit"; then
17337 haveit=
17338 for x in $LDFLAGS $LIBBABELTRACE; do
17339
17340 acl_save_prefix="$prefix"
17341 prefix="$acl_final_prefix"
17342 acl_save_exec_prefix="$exec_prefix"
17343 exec_prefix="$acl_final_exec_prefix"
17344 eval x=\"$x\"
17345 exec_prefix="$acl_save_exec_prefix"
17346 prefix="$acl_save_prefix"
17347
17348 if test "X$x" = "X-L$additional_libdir"; then
17349 haveit=yes
17350 break
17351 fi
17352 done
17353 if test -z "$haveit"; then
17354 if test -d "$additional_libdir"; then
17355 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$additional_libdir"
17356 fi
17357 fi
17358 haveit=
17359 for x in $LDFLAGS $LTLIBBABELTRACE; do
17360
17361 acl_save_prefix="$prefix"
17362 prefix="$acl_final_prefix"
17363 acl_save_exec_prefix="$exec_prefix"
17364 exec_prefix="$acl_final_exec_prefix"
17365 eval x=\"$x\"
17366 exec_prefix="$acl_save_exec_prefix"
17367 prefix="$acl_save_prefix"
17368
17369 if test "X$x" = "X-L$additional_libdir"; then
17370 haveit=yes
17371 break
17372 fi
17373 done
17374 if test -z "$haveit"; then
17375 if test -d "$additional_libdir"; then
17376 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$additional_libdir"
17377 fi
17378 fi
17379 fi
17380 fi
17381 ;;
17382 -R*)
17383 dir=`echo "X$dep" | sed -e 's/^X-R//'`
17384 if test "$enable_rpath" != no; then
17385 haveit=
17386 for x in $rpathdirs; do
17387 if test "X$x" = "X$dir"; then
17388 haveit=yes
17389 break
17390 fi
17391 done
17392 if test -z "$haveit"; then
17393 rpathdirs="$rpathdirs $dir"
17394 fi
17395 haveit=
17396 for x in $ltrpathdirs; do
17397 if test "X$x" = "X$dir"; then
17398 haveit=yes
17399 break
17400 fi
17401 done
17402 if test -z "$haveit"; then
17403 ltrpathdirs="$ltrpathdirs $dir"
17404 fi
17405 fi
17406 ;;
17407 -l*)
17408 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
17409 ;;
17410 *.la)
17411 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
17412 ;;
17413 *)
17414 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$dep"
17415 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$dep"
17416 ;;
17417 esac
17418 done
17419 fi
17420 else
17421 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
17422 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l$name"
17423 fi
17424 fi
17425 fi
17426 done
17427 done
17428 if test "X$rpathdirs" != "X"; then
17429 if test -n "$hardcode_libdir_separator"; then
17430 alldirs=
17431 for found_dir in $rpathdirs; do
17432 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
17433 done
17434 acl_save_libdir="$libdir"
17435 libdir="$alldirs"
17436 eval flag=\"$hardcode_libdir_flag_spec\"
17437 libdir="$acl_save_libdir"
17438 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
17439 else
17440 for found_dir in $rpathdirs; do
17441 acl_save_libdir="$libdir"
17442 libdir="$found_dir"
17443 eval flag=\"$hardcode_libdir_flag_spec\"
17444 libdir="$acl_save_libdir"
17445 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
17446 done
17447 fi
17448 fi
17449 if test "X$ltrpathdirs" != "X"; then
17450 for found_dir in $ltrpathdirs; do
17451 LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-R$found_dir"
17452 done
17453 fi
17454
17455
17456 ac_save_CPPFLAGS="$CPPFLAGS"
17457
17458 for element in $INCBABELTRACE; do
17459 haveit=
17460 for x in $CPPFLAGS; do
17461
17462 acl_save_prefix="$prefix"
17463 prefix="$acl_final_prefix"
17464 acl_save_exec_prefix="$exec_prefix"
17465 exec_prefix="$acl_final_exec_prefix"
17466 eval x=\"$x\"
17467 exec_prefix="$acl_save_exec_prefix"
17468 prefix="$acl_save_prefix"
17469
17470 if test "X$x" = "X$element"; then
17471 haveit=yes
17472 break
17473 fi
17474 done
17475 if test -z "$haveit"; then
17476 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
17477 fi
17478 done
17479
17480
17481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbabeltrace" >&5
17482 $as_echo_n "checking for libbabeltrace... " >&6; }
17483 if ${ac_cv_libbabeltrace+:} false; then :
17484 $as_echo_n "(cached) " >&6
17485 else
17486
17487 ac_save_LIBS="$LIBS"
17488 LIBS="$LIBS $LIBBABELTRACE"
17489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17490 /* end confdefs.h. */
17491 #include <babeltrace/babeltrace.h>
17492 #include <babeltrace/ctf/events.h>
17493 #include <babeltrace/ctf/iterator.h>
17494 int
17495 main ()
17496 {
17497 struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL));
17498 struct bt_ctf_event *event = NULL;
17499 const struct bt_definition *scope;
17500
17501 pos->type = BT_SEEK_BEGIN;
17502 bt_iter_set_pos (bt_ctf_get_iter (NULL), pos);
17503 scope = bt_ctf_get_top_level_scope (event,
17504 BT_STREAM_EVENT_HEADER);
17505 bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));
17506
17507 ;
17508 return 0;
17509 }
17510 _ACEOF
17511 if ac_fn_c_try_link "$LINENO"; then :
17512 ac_cv_libbabeltrace=yes
17513 else
17514 ac_cv_libbabeltrace=no
17515 fi
17516 rm -f core conftest.err conftest.$ac_objext \
17517 conftest$ac_exeext conftest.$ac_ext
17518 LIBS="$ac_save_LIBS"
17519
17520 fi
17521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libbabeltrace" >&5
17522 $as_echo "$ac_cv_libbabeltrace" >&6; }
17523 if test "$ac_cv_libbabeltrace" = yes; then
17524 HAVE_LIBBABELTRACE=yes
17525
17526 $as_echo "#define HAVE_LIBBABELTRACE 1" >>confdefs.h
17527
17528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libbabeltrace" >&5
17529 $as_echo_n "checking how to link with libbabeltrace... " >&6; }
17530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBBABELTRACE" >&5
17531 $as_echo "$LIBBABELTRACE" >&6; }
17532 else
17533 HAVE_LIBBABELTRACE=no
17534 CPPFLAGS="$ac_save_CPPFLAGS"
17535 LIBBABELTRACE=
17536 LTLIBBABELTRACE=
17537 fi
17538
17539
17540
17541
17542
17543
17544 CFLAGS=$saved_CFLAGS
17545
17546 if test "$HAVE_LIBBABELTRACE" != yes; then
17547 if test "$with_babeltrace" = yes; then
17548 as_fn_error $? "babeltrace is missing or unusable" "$LINENO" 5
17549 else
17550 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&5
17551 $as_echo "$as_me: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&2;}
17552 fi
17553 fi
17554 fi
17555
17556 # Check for xxhash
17557
17558 # Check whether --with-xxhash was given.
17559 if test "${with_xxhash+set}" = set; then :
17560 withval=$with_xxhash;
17561 else
17562 with_xxhash=auto
17563 fi
17564
17565
17566 if test "x$with_xxhash" != "xno"; then
17567
17568
17569
17570
17571
17572
17573
17574
17575 use_additional=yes
17576
17577 acl_save_prefix="$prefix"
17578 prefix="$acl_final_prefix"
17579 acl_save_exec_prefix="$exec_prefix"
17580 exec_prefix="$acl_final_exec_prefix"
17581
17582 eval additional_includedir=\"$includedir\"
17583 eval additional_libdir=\"$libdir\"
17584
17585 exec_prefix="$acl_save_exec_prefix"
17586 prefix="$acl_save_prefix"
17587
17588
17589 # Check whether --with-libxxhash-prefix was given.
17590 if test "${with_libxxhash_prefix+set}" = set; then :
17591 withval=$with_libxxhash_prefix;
17592 if test "X$withval" = "Xno"; then
17593 use_additional=no
17594 else
17595 if test "X$withval" = "X"; then
17596
17597 acl_save_prefix="$prefix"
17598 prefix="$acl_final_prefix"
17599 acl_save_exec_prefix="$exec_prefix"
17600 exec_prefix="$acl_final_exec_prefix"
17601
17602 eval additional_includedir=\"$includedir\"
17603 eval additional_libdir=\"$libdir\"
17604
17605 exec_prefix="$acl_save_exec_prefix"
17606 prefix="$acl_save_prefix"
17607
17608 else
17609 additional_includedir="$withval/include"
17610 additional_libdir="$withval/lib"
17611 fi
17612 fi
17613
17614 fi
17615
17616 LIBXXHASH=
17617 LTLIBXXHASH=
17618 INCXXHASH=
17619 rpathdirs=
17620 ltrpathdirs=
17621 names_already_handled=
17622 names_next_round='xxhash '
17623 while test -n "$names_next_round"; do
17624 names_this_round="$names_next_round"
17625 names_next_round=
17626 for name in $names_this_round; do
17627 already_handled=
17628 for n in $names_already_handled; do
17629 if test "$n" = "$name"; then
17630 already_handled=yes
17631 break
17632 fi
17633 done
17634 if test -z "$already_handled"; then
17635 names_already_handled="$names_already_handled $name"
17636 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
17637 eval value=\"\$HAVE_LIB$uppername\"
17638 if test -n "$value"; then
17639 if test "$value" = yes; then
17640 eval value=\"\$LIB$uppername\"
17641 test -z "$value" || LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$value"
17642 eval value=\"\$LTLIB$uppername\"
17643 test -z "$value" || LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$value"
17644 else
17645 :
17646 fi
17647 else
17648 found_dir=
17649 found_la=
17650 found_so=
17651 found_a=
17652 if test $use_additional = yes; then
17653 if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
17654 found_dir="$additional_libdir"
17655 found_so="$additional_libdir/lib$name.$shlibext"
17656 if test -f "$additional_libdir/lib$name.la"; then
17657 found_la="$additional_libdir/lib$name.la"
17658 fi
17659 else
17660 if test -f "$additional_libdir/lib$name.$libext"; then
17661 found_dir="$additional_libdir"
17662 found_a="$additional_libdir/lib$name.$libext"
17663 if test -f "$additional_libdir/lib$name.la"; then
17664 found_la="$additional_libdir/lib$name.la"
17665 fi
17666 fi
17667 fi
17668 fi
17669 if test "X$found_dir" = "X"; then
17670 for x in $LDFLAGS $LTLIBXXHASH; do
17671
17672 acl_save_prefix="$prefix"
17673 prefix="$acl_final_prefix"
17674 acl_save_exec_prefix="$exec_prefix"
17675 exec_prefix="$acl_final_exec_prefix"
17676 eval x=\"$x\"
17677 exec_prefix="$acl_save_exec_prefix"
17678 prefix="$acl_save_prefix"
17679
17680 case "$x" in
17681 -L*)
17682 dir=`echo "X$x" | sed -e 's/^X-L//'`
17683 if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
17684 found_dir="$dir"
17685 found_so="$dir/lib$name.$shlibext"
17686 if test -f "$dir/lib$name.la"; then
17687 found_la="$dir/lib$name.la"
17688 fi
17689 else
17690 if test -f "$dir/lib$name.$libext"; then
17691 found_dir="$dir"
17692 found_a="$dir/lib$name.$libext"
17693 if test -f "$dir/lib$name.la"; then
17694 found_la="$dir/lib$name.la"
17695 fi
17696 fi
17697 fi
17698 ;;
17699 esac
17700 if test "X$found_dir" != "X"; then
17701 break
17702 fi
17703 done
17704 fi
17705 if test "X$found_dir" != "X"; then
17706 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$found_dir -l$name"
17707 if test "X$found_so" != "X"; then
17708 if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
17709 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
17710 else
17711 haveit=
17712 for x in $ltrpathdirs; do
17713 if test "X$x" = "X$found_dir"; then
17714 haveit=yes
17715 break
17716 fi
17717 done
17718 if test -z "$haveit"; then
17719 ltrpathdirs="$ltrpathdirs $found_dir"
17720 fi
17721 if test "$hardcode_direct" = yes; then
17722 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
17723 else
17724 if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
17725 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
17726 haveit=
17727 for x in $rpathdirs; do
17728 if test "X$x" = "X$found_dir"; then
17729 haveit=yes
17730 break
17731 fi
17732 done
17733 if test -z "$haveit"; then
17734 rpathdirs="$rpathdirs $found_dir"
17735 fi
17736 else
17737 haveit=
17738 for x in $LDFLAGS $LIBXXHASH; do
17739
17740 acl_save_prefix="$prefix"
17741 prefix="$acl_final_prefix"
17742 acl_save_exec_prefix="$exec_prefix"
17743 exec_prefix="$acl_final_exec_prefix"
17744 eval x=\"$x\"
17745 exec_prefix="$acl_save_exec_prefix"
17746 prefix="$acl_save_prefix"
17747
17748 if test "X$x" = "X-L$found_dir"; then
17749 haveit=yes
17750 break
17751 fi
17752 done
17753 if test -z "$haveit"; then
17754 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir"
17755 fi
17756 if test "$hardcode_minus_L" != no; then
17757 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_so"
17758 else
17759 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
17760 fi
17761 fi
17762 fi
17763 fi
17764 else
17765 if test "X$found_a" != "X"; then
17766 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$found_a"
17767 else
17768 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$found_dir -l$name"
17769 fi
17770 fi
17771 additional_includedir=
17772 case "$found_dir" in
17773 */lib | */lib/)
17774 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
17775 additional_includedir="$basedir/include"
17776 ;;
17777 esac
17778 if test "X$additional_includedir" != "X"; then
17779 if test "X$additional_includedir" != "X/usr/include"; then
17780 haveit=
17781 if test "X$additional_includedir" = "X/usr/local/include"; then
17782 if test -n "$GCC"; then
17783 case $host_os in
17784 linux*) haveit=yes;;
17785 esac
17786 fi
17787 fi
17788 if test -z "$haveit"; then
17789 for x in $CPPFLAGS $INCXXHASH; do
17790
17791 acl_save_prefix="$prefix"
17792 prefix="$acl_final_prefix"
17793 acl_save_exec_prefix="$exec_prefix"
17794 exec_prefix="$acl_final_exec_prefix"
17795 eval x=\"$x\"
17796 exec_prefix="$acl_save_exec_prefix"
17797 prefix="$acl_save_prefix"
17798
17799 if test "X$x" = "X-I$additional_includedir"; then
17800 haveit=yes
17801 break
17802 fi
17803 done
17804 if test -z "$haveit"; then
17805 if test -d "$additional_includedir"; then
17806 INCXXHASH="${INCXXHASH}${INCXXHASH:+ }-I$additional_includedir"
17807 fi
17808 fi
17809 fi
17810 fi
17811 fi
17812 if test -n "$found_la"; then
17813 save_libdir="$libdir"
17814 case "$found_la" in
17815 */* | *\\*) . "$found_la" ;;
17816 *) . "./$found_la" ;;
17817 esac
17818 libdir="$save_libdir"
17819 for dep in $dependency_libs; do
17820 case "$dep" in
17821 -L*)
17822 additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
17823 if test "X$additional_libdir" != "X/usr/lib"; then
17824 haveit=
17825 if test "X$additional_libdir" = "X/usr/local/lib"; then
17826 if test -n "$GCC"; then
17827 case $host_os in
17828 linux*) haveit=yes;;
17829 esac
17830 fi
17831 fi
17832 if test -z "$haveit"; then
17833 haveit=
17834 for x in $LDFLAGS $LIBXXHASH; do
17835
17836 acl_save_prefix="$prefix"
17837 prefix="$acl_final_prefix"
17838 acl_save_exec_prefix="$exec_prefix"
17839 exec_prefix="$acl_final_exec_prefix"
17840 eval x=\"$x\"
17841 exec_prefix="$acl_save_exec_prefix"
17842 prefix="$acl_save_prefix"
17843
17844 if test "X$x" = "X-L$additional_libdir"; then
17845 haveit=yes
17846 break
17847 fi
17848 done
17849 if test -z "$haveit"; then
17850 if test -d "$additional_libdir"; then
17851 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-L$additional_libdir"
17852 fi
17853 fi
17854 haveit=
17855 for x in $LDFLAGS $LTLIBXXHASH; do
17856
17857 acl_save_prefix="$prefix"
17858 prefix="$acl_final_prefix"
17859 acl_save_exec_prefix="$exec_prefix"
17860 exec_prefix="$acl_final_exec_prefix"
17861 eval x=\"$x\"
17862 exec_prefix="$acl_save_exec_prefix"
17863 prefix="$acl_save_prefix"
17864
17865 if test "X$x" = "X-L$additional_libdir"; then
17866 haveit=yes
17867 break
17868 fi
17869 done
17870 if test -z "$haveit"; then
17871 if test -d "$additional_libdir"; then
17872 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-L$additional_libdir"
17873 fi
17874 fi
17875 fi
17876 fi
17877 ;;
17878 -R*)
17879 dir=`echo "X$dep" | sed -e 's/^X-R//'`
17880 if test "$enable_rpath" != no; then
17881 haveit=
17882 for x in $rpathdirs; do
17883 if test "X$x" = "X$dir"; then
17884 haveit=yes
17885 break
17886 fi
17887 done
17888 if test -z "$haveit"; then
17889 rpathdirs="$rpathdirs $dir"
17890 fi
17891 haveit=
17892 for x in $ltrpathdirs; do
17893 if test "X$x" = "X$dir"; then
17894 haveit=yes
17895 break
17896 fi
17897 done
17898 if test -z "$haveit"; then
17899 ltrpathdirs="$ltrpathdirs $dir"
17900 fi
17901 fi
17902 ;;
17903 -l*)
17904 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
17905 ;;
17906 *.la)
17907 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
17908 ;;
17909 *)
17910 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$dep"
17911 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }$dep"
17912 ;;
17913 esac
17914 done
17915 fi
17916 else
17917 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }-l$name"
17918 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-l$name"
17919 fi
17920 fi
17921 fi
17922 done
17923 done
17924 if test "X$rpathdirs" != "X"; then
17925 if test -n "$hardcode_libdir_separator"; then
17926 alldirs=
17927 for found_dir in $rpathdirs; do
17928 alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
17929 done
17930 acl_save_libdir="$libdir"
17931 libdir="$alldirs"
17932 eval flag=\"$hardcode_libdir_flag_spec\"
17933 libdir="$acl_save_libdir"
17934 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
17935 else
17936 for found_dir in $rpathdirs; do
17937 acl_save_libdir="$libdir"
17938 libdir="$found_dir"
17939 eval flag=\"$hardcode_libdir_flag_spec\"
17940 libdir="$acl_save_libdir"
17941 LIBXXHASH="${LIBXXHASH}${LIBXXHASH:+ }$flag"
17942 done
17943 fi
17944 fi
17945 if test "X$ltrpathdirs" != "X"; then
17946 for found_dir in $ltrpathdirs; do
17947 LTLIBXXHASH="${LTLIBXXHASH}${LTLIBXXHASH:+ }-R$found_dir"
17948 done
17949 fi
17950
17951
17952 ac_save_CPPFLAGS="$CPPFLAGS"
17953
17954 for element in $INCXXHASH; do
17955 haveit=
17956 for x in $CPPFLAGS; do
17957
17958 acl_save_prefix="$prefix"
17959 prefix="$acl_final_prefix"
17960 acl_save_exec_prefix="$exec_prefix"
17961 exec_prefix="$acl_final_exec_prefix"
17962 eval x=\"$x\"
17963 exec_prefix="$acl_save_exec_prefix"
17964 prefix="$acl_save_prefix"
17965
17966 if test "X$x" = "X$element"; then
17967 haveit=yes
17968 break
17969 fi
17970 done
17971 if test -z "$haveit"; then
17972 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
17973 fi
17974 done
17975
17976
17977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxxhash" >&5
17978 $as_echo_n "checking for libxxhash... " >&6; }
17979 if ${ac_cv_libxxhash+:} false; then :
17980 $as_echo_n "(cached) " >&6
17981 else
17982
17983 ac_save_LIBS="$LIBS"
17984 LIBS="$LIBS $LIBXXHASH"
17985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17986 /* end confdefs.h. */
17987 #include <xxhash.h>
17988 int
17989 main ()
17990 {
17991 XXH32("foo", 3, 0);
17992
17993 ;
17994 return 0;
17995 }
17996 _ACEOF
17997 if ac_fn_c_try_link "$LINENO"; then :
17998 ac_cv_libxxhash=yes
17999 else
18000 ac_cv_libxxhash=no
18001 fi
18002 rm -f core conftest.err conftest.$ac_objext \
18003 conftest$ac_exeext conftest.$ac_ext
18004 LIBS="$ac_save_LIBS"
18005
18006 fi
18007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libxxhash" >&5
18008 $as_echo "$ac_cv_libxxhash" >&6; }
18009 if test "$ac_cv_libxxhash" = yes; then
18010 HAVE_LIBXXHASH=yes
18011
18012 $as_echo "#define HAVE_LIBXXHASH 1" >>confdefs.h
18013
18014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libxxhash" >&5
18015 $as_echo_n "checking how to link with libxxhash... " >&6; }
18016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXXHASH" >&5
18017 $as_echo "$LIBXXHASH" >&6; }
18018 else
18019 HAVE_LIBXXHASH=no
18020 CPPFLAGS="$ac_save_CPPFLAGS"
18021 LIBXXHASH=
18022 LTLIBXXHASH=
18023 fi
18024
18025
18026
18027
18028
18029
18030 if test "$HAVE_LIBXXHASH" != yes; then
18031 if test "$with_xxhash" = yes; then
18032 as_fn_error $? "xxhash is missing or unusable" "$LINENO" 5
18033 fi
18034 fi
18035 if test "x$with_xxhash" = "xauto"; then
18036 with_xxhash="$HAVE_LIBXXHASH"
18037 fi
18038 fi
18039
18040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use xxhash" >&5
18041 $as_echo_n "checking whether to use xxhash... " >&6; }
18042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_xxhash" >&5
18043 $as_echo "$with_xxhash" >&6; }
18044
18045 NM_H=
18046 rm -f nm.h
18047 if test "${nativefile}" != ""; then
18048 case "${nativefile}" in
18049 nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
18050 * ) GDB_NM_FILE="${nativefile}"
18051 esac
18052 ac_config_links="$ac_config_links nm.h:$GDB_NM_FILE"
18053
18054
18055 cat >>confdefs.h <<_ACEOF
18056 #define GDB_NM_FILE "${GDB_NM_FILE}"
18057 _ACEOF
18058
18059 NM_H=nm.h
18060 fi
18061
18062
18063
18064 for ac_prog in xsltproc
18065 do
18066 # Extract the first word of "$ac_prog", so it can be a program name with args.
18067 set dummy $ac_prog; ac_word=$2
18068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18069 $as_echo_n "checking for $ac_word... " >&6; }
18070 if ${ac_cv_path_XSLTPROC+:} false; then :
18071 $as_echo_n "(cached) " >&6
18072 else
18073 case $XSLTPROC in
18074 [\\/]* | ?:[\\/]*)
18075 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
18076 ;;
18077 *)
18078 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18079 for as_dir in $PATH
18080 do
18081 IFS=$as_save_IFS
18082 test -z "$as_dir" && as_dir=.
18083 for ac_exec_ext in '' $ac_executable_extensions; do
18084 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18085 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
18086 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18087 break 2
18088 fi
18089 done
18090 done
18091 IFS=$as_save_IFS
18092
18093 ;;
18094 esac
18095 fi
18096 XSLTPROC=$ac_cv_path_XSLTPROC
18097 if test -n "$XSLTPROC"; then
18098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18099 $as_echo "$XSLTPROC" >&6; }
18100 else
18101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18102 $as_echo "no" >&6; }
18103 fi
18104
18105
18106 test -n "$XSLTPROC" && break
18107 done
18108 test -n "$XSLTPROC" || XSLTPROC="missing"
18109
18110 if test "x$USE_MAINTAINER_MODE" = xyes; then
18111 if test "${XSLTPROC}" = missing; then
18112 as_fn_error $? "unable to find xsltproc. maintainer-mode requires xsltproc." "$LINENO" 5
18113 fi
18114 fi
18115
18116
18117
18118
18119
18120 $as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
18121
18122
18123
18124 # Check whether we will enable the inclusion of unit tests when
18125 # compiling GDB.
18126 #
18127 # The default value of this option changes depending whether we're on
18128 # development mode (in which case it's "true") or not (in which case
18129 # it's "false").
18130 # Check whether --enable-unit-tests was given.
18131 if test "${enable_unit_tests+set}" = set; then :
18132 enableval=$enable_unit_tests; case "${enableval}" in
18133 yes) enable_unittests=true ;;
18134 no) enable_unittests=false ;;
18135 *) as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
18136 esac
18137 else
18138 enable_unittests=$development
18139 fi
18140
18141
18142 if $enable_unittests; then
18143
18144 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
18145
18146
18147 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_UNITTESTS_OBS) gdbsupport/selftest.o selftest-arch.o"
18148 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_UNITTESTS_SRCS) gdbsupport/selftest.c selftest-arch.c"
18149
18150 fi
18151
18152
18153
18154 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
18155 GDB_TRANSFORM_NAME=`echo gdb | sed -e "$gdb_ac_transform"`
18156 if test "x$GDB_TRANSFORM_NAME" = x; then
18157 GDB_TRANSFORM_NAME=gdb
18158 fi
18159
18160
18161
18162 gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
18163 GCORE_TRANSFORM_NAME=`echo gcore | sed -e "$gdb_ac_transform"`
18164 if test "x$GCORE_TRANSFORM_NAME" = x; then
18165 GCORE_TRANSFORM_NAME=gcore
18166 fi
18167
18168
18169 ac_config_files="$ac_config_files gcore"
18170
18171 ac_config_files="$ac_config_files Makefile gdb-gdb.gdb gdb-gdb.py doc/Makefile data-directory/Makefile"
18172
18173
18174 cat >confcache <<\_ACEOF
18175 # This file is a shell script that caches the results of configure
18176 # tests run on this system so they can be shared between configure
18177 # scripts and configure runs, see configure's option --config-cache.
18178 # It is not useful on other systems. If it contains results you don't
18179 # want to keep, you may remove or edit it.
18180 #
18181 # config.status only pays attention to the cache file if you give it
18182 # the --recheck option to rerun configure.
18183 #
18184 # `ac_cv_env_foo' variables (set or unset) will be overridden when
18185 # loading this file, other *unset* `ac_cv_foo' will be assigned the
18186 # following values.
18187
18188 _ACEOF
18189
18190 # The following way of writing the cache mishandles newlines in values,
18191 # but we know of no workaround that is simple, portable, and efficient.
18192 # So, we kill variables containing newlines.
18193 # Ultrix sh set writes to stderr and can't be redirected directly,
18194 # and sets the high bit in the cache file unless we assign to the vars.
18195 (
18196 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
18197 eval ac_val=\$$ac_var
18198 case $ac_val in #(
18199 *${as_nl}*)
18200 case $ac_var in #(
18201 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
18202 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
18203 esac
18204 case $ac_var in #(
18205 _ | IFS | as_nl) ;; #(
18206 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
18207 *) { eval $ac_var=; unset $ac_var;} ;;
18208 esac ;;
18209 esac
18210 done
18211
18212 (set) 2>&1 |
18213 case $as_nl`(ac_space=' '; set) 2>&1` in #(
18214 *${as_nl}ac_space=\ *)
18215 # `set' does not quote correctly, so add quotes: double-quote
18216 # substitution turns \\\\ into \\, and sed turns \\ into \.
18217 sed -n \
18218 "s/'/'\\\\''/g;
18219 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18220 ;; #(
18221 *)
18222 # `set' quotes correctly as required by POSIX, so do not add quotes.
18223 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
18224 ;;
18225 esac |
18226 sort
18227 ) |
18228 sed '
18229 /^ac_cv_env_/b end
18230 t clear
18231 :clear
18232 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18233 t end
18234 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18235 :end' >>confcache
18236 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
18237 if test -w "$cache_file"; then
18238 if test "x$cache_file" != "x/dev/null"; then
18239 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
18240 $as_echo "$as_me: updating cache $cache_file" >&6;}
18241 if test ! -f "$cache_file" || test -h "$cache_file"; then
18242 cat confcache >"$cache_file"
18243 else
18244 case $cache_file in #(
18245 */* | ?:*)
18246 mv -f confcache "$cache_file"$$ &&
18247 mv -f "$cache_file"$$ "$cache_file" ;; #(
18248 *)
18249 mv -f confcache "$cache_file" ;;
18250 esac
18251 fi
18252 fi
18253 else
18254 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
18255 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
18256 fi
18257 fi
18258 rm -f confcache
18259
18260 test "x$prefix" = xNONE && prefix=$ac_default_prefix
18261 # Let make expand exec_prefix.
18262 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18263
18264 DEFS=-DHAVE_CONFIG_H
18265
18266 ac_libobjs=
18267 ac_ltlibobjs=
18268 U=
18269 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18270 # 1. Remove the extension, and $U if already installed.
18271 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
18272 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
18273 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
18274 # will be set to the directory where LIBOBJS objects are built.
18275 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
18276 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
18277 done
18278 LIBOBJS=$ac_libobjs
18279
18280 LTLIBOBJS=$ac_ltlibobjs
18281
18282
18283 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
18284 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
18285 Usually this means the macro was only invoked conditionally." "$LINENO" 5
18286 fi
18287 if test -z "${HAVE_PYTHON_TRUE}" && test -z "${HAVE_PYTHON_FALSE}"; then
18288 as_fn_error $? "conditional \"HAVE_PYTHON\" was never defined.
18289 Usually this means the macro was only invoked conditionally." "$LINENO" 5
18290 fi
18291 if test -z "${HAVE_GUILE_TRUE}" && test -z "${HAVE_GUILE_FALSE}"; then
18292 as_fn_error $? "conditional \"HAVE_GUILE\" was never defined.
18293 Usually this means the macro was only invoked conditionally." "$LINENO" 5
18294 fi
18295
18296
18297 : "${CONFIG_STATUS=./config.status}"
18298 ac_write_fail=0
18299 ac_clean_files_save=$ac_clean_files
18300 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
18301 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
18302 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
18303 as_write_fail=0
18304 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
18305 #! $SHELL
18306 # Generated by $as_me.
18307 # Run this file to recreate the current configuration.
18308 # Compiler output produced by configure, useful for debugging
18309 # configure, is in config.log if it exists.
18310
18311 debug=false
18312 ac_cs_recheck=false
18313 ac_cs_silent=false
18314
18315 SHELL=\${CONFIG_SHELL-$SHELL}
18316 export SHELL
18317 _ASEOF
18318 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
18319 ## -------------------- ##
18320 ## M4sh Initialization. ##
18321 ## -------------------- ##
18322
18323 # Be more Bourne compatible
18324 DUALCASE=1; export DUALCASE # for MKS sh
18325 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18326 emulate sh
18327 NULLCMD=:
18328 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
18329 # is contrary to our usage. Disable this feature.
18330 alias -g '${1+"$@"}'='"$@"'
18331 setopt NO_GLOB_SUBST
18332 else
18333 case `(set -o) 2>/dev/null` in #(
18334 *posix*) :
18335 set -o posix ;; #(
18336 *) :
18337 ;;
18338 esac
18339 fi
18340
18341
18342 as_nl='
18343 '
18344 export as_nl
18345 # Printing a long string crashes Solaris 7 /usr/bin/printf.
18346 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
18347 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
18348 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
18349 # Prefer a ksh shell builtin over an external printf program on Solaris,
18350 # but without wasting forks for bash or zsh.
18351 if test -z "$BASH_VERSION$ZSH_VERSION" \
18352 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
18353 as_echo='print -r --'
18354 as_echo_n='print -rn --'
18355 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
18356 as_echo='printf %s\n'
18357 as_echo_n='printf %s'
18358 else
18359 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
18360 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
18361 as_echo_n='/usr/ucb/echo -n'
18362 else
18363 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
18364 as_echo_n_body='eval
18365 arg=$1;
18366 case $arg in #(
18367 *"$as_nl"*)
18368 expr "X$arg" : "X\\(.*\\)$as_nl";
18369 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
18370 esac;
18371 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
18372 '
18373 export as_echo_n_body
18374 as_echo_n='sh -c $as_echo_n_body as_echo'
18375 fi
18376 export as_echo_body
18377 as_echo='sh -c $as_echo_body as_echo'
18378 fi
18379
18380 # The user is always right.
18381 if test "${PATH_SEPARATOR+set}" != set; then
18382 PATH_SEPARATOR=:
18383 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
18384 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
18385 PATH_SEPARATOR=';'
18386 }
18387 fi
18388
18389
18390 # IFS
18391 # We need space, tab and new line, in precisely that order. Quoting is
18392 # there to prevent editors from complaining about space-tab.
18393 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
18394 # splitting by setting IFS to empty value.)
18395 IFS=" "" $as_nl"
18396
18397 # Find who we are. Look in the path if we contain no directory separator.
18398 as_myself=
18399 case $0 in #((
18400 *[\\/]* ) as_myself=$0 ;;
18401 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18402 for as_dir in $PATH
18403 do
18404 IFS=$as_save_IFS
18405 test -z "$as_dir" && as_dir=.
18406 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18407 done
18408 IFS=$as_save_IFS
18409
18410 ;;
18411 esac
18412 # We did not find ourselves, most probably we were run as `sh COMMAND'
18413 # in which case we are not to be found in the path.
18414 if test "x$as_myself" = x; then
18415 as_myself=$0
18416 fi
18417 if test ! -f "$as_myself"; then
18418 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
18419 exit 1
18420 fi
18421
18422 # Unset variables that we do not need and which cause bugs (e.g. in
18423 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
18424 # suppresses any "Segmentation fault" message there. '((' could
18425 # trigger a bug in pdksh 5.2.14.
18426 for as_var in BASH_ENV ENV MAIL MAILPATH
18427 do eval test x\${$as_var+set} = xset \
18428 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
18429 done
18430 PS1='$ '
18431 PS2='> '
18432 PS4='+ '
18433
18434 # NLS nuisances.
18435 LC_ALL=C
18436 export LC_ALL
18437 LANGUAGE=C
18438 export LANGUAGE
18439
18440 # CDPATH.
18441 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
18442
18443
18444 # as_fn_error STATUS ERROR [LINENO LOG_FD]
18445 # ----------------------------------------
18446 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
18447 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
18448 # script with STATUS, using 1 if that was 0.
18449 as_fn_error ()
18450 {
18451 as_status=$1; test $as_status -eq 0 && as_status=1
18452 if test "$4"; then
18453 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
18454 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
18455 fi
18456 $as_echo "$as_me: error: $2" >&2
18457 as_fn_exit $as_status
18458 } # as_fn_error
18459
18460
18461 # as_fn_set_status STATUS
18462 # -----------------------
18463 # Set $? to STATUS, without forking.
18464 as_fn_set_status ()
18465 {
18466 return $1
18467 } # as_fn_set_status
18468
18469 # as_fn_exit STATUS
18470 # -----------------
18471 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
18472 as_fn_exit ()
18473 {
18474 set +e
18475 as_fn_set_status $1
18476 exit $1
18477 } # as_fn_exit
18478
18479 # as_fn_unset VAR
18480 # ---------------
18481 # Portably unset VAR.
18482 as_fn_unset ()
18483 {
18484 { eval $1=; unset $1;}
18485 }
18486 as_unset=as_fn_unset
18487 # as_fn_append VAR VALUE
18488 # ----------------------
18489 # Append the text in VALUE to the end of the definition contained in VAR. Take
18490 # advantage of any shell optimizations that allow amortized linear growth over
18491 # repeated appends, instead of the typical quadratic growth present in naive
18492 # implementations.
18493 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
18494 eval 'as_fn_append ()
18495 {
18496 eval $1+=\$2
18497 }'
18498 else
18499 as_fn_append ()
18500 {
18501 eval $1=\$$1\$2
18502 }
18503 fi # as_fn_append
18504
18505 # as_fn_arith ARG...
18506 # ------------------
18507 # Perform arithmetic evaluation on the ARGs, and store the result in the
18508 # global $as_val. Take advantage of shells that can avoid forks. The arguments
18509 # must be portable across $(()) and expr.
18510 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
18511 eval 'as_fn_arith ()
18512 {
18513 as_val=$(( $* ))
18514 }'
18515 else
18516 as_fn_arith ()
18517 {
18518 as_val=`expr "$@" || test $? -eq 1`
18519 }
18520 fi # as_fn_arith
18521
18522
18523 if expr a : '\(a\)' >/dev/null 2>&1 &&
18524 test "X`expr 00001 : '.*\(...\)'`" = X001; then
18525 as_expr=expr
18526 else
18527 as_expr=false
18528 fi
18529
18530 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
18531 as_basename=basename
18532 else
18533 as_basename=false
18534 fi
18535
18536 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
18537 as_dirname=dirname
18538 else
18539 as_dirname=false
18540 fi
18541
18542 as_me=`$as_basename -- "$0" ||
18543 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18544 X"$0" : 'X\(//\)$' \| \
18545 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
18546 $as_echo X/"$0" |
18547 sed '/^.*\/\([^/][^/]*\)\/*$/{
18548 s//\1/
18549 q
18550 }
18551 /^X\/\(\/\/\)$/{
18552 s//\1/
18553 q
18554 }
18555 /^X\/\(\/\).*/{
18556 s//\1/
18557 q
18558 }
18559 s/.*/./; q'`
18560
18561 # Avoid depending upon Character Ranges.
18562 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18563 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18564 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18565 as_cr_digits='0123456789'
18566 as_cr_alnum=$as_cr_Letters$as_cr_digits
18567
18568 ECHO_C= ECHO_N= ECHO_T=
18569 case `echo -n x` in #(((((
18570 -n*)
18571 case `echo 'xy\c'` in
18572 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
18573 xy) ECHO_C='\c';;
18574 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
18575 ECHO_T=' ';;
18576 esac;;
18577 *)
18578 ECHO_N='-n';;
18579 esac
18580
18581 rm -f conf$$ conf$$.exe conf$$.file
18582 if test -d conf$$.dir; then
18583 rm -f conf$$.dir/conf$$.file
18584 else
18585 rm -f conf$$.dir
18586 mkdir conf$$.dir 2>/dev/null
18587 fi
18588 if (echo >conf$$.file) 2>/dev/null; then
18589 if ln -s conf$$.file conf$$ 2>/dev/null; then
18590 as_ln_s='ln -s'
18591 # ... but there are two gotchas:
18592 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
18593 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
18594 # In both cases, we have to default to `cp -pR'.
18595 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
18596 as_ln_s='cp -pR'
18597 elif ln conf$$.file conf$$ 2>/dev/null; then
18598 as_ln_s=ln
18599 else
18600 as_ln_s='cp -pR'
18601 fi
18602 else
18603 as_ln_s='cp -pR'
18604 fi
18605 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
18606 rmdir conf$$.dir 2>/dev/null
18607
18608
18609 # as_fn_mkdir_p
18610 # -------------
18611 # Create "$as_dir" as a directory, including parents if necessary.
18612 as_fn_mkdir_p ()
18613 {
18614
18615 case $as_dir in #(
18616 -*) as_dir=./$as_dir;;
18617 esac
18618 test -d "$as_dir" || eval $as_mkdir_p || {
18619 as_dirs=
18620 while :; do
18621 case $as_dir in #(
18622 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
18623 *) as_qdir=$as_dir;;
18624 esac
18625 as_dirs="'$as_qdir' $as_dirs"
18626 as_dir=`$as_dirname -- "$as_dir" ||
18627 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18628 X"$as_dir" : 'X\(//\)[^/]' \| \
18629 X"$as_dir" : 'X\(//\)$' \| \
18630 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
18631 $as_echo X"$as_dir" |
18632 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18633 s//\1/
18634 q
18635 }
18636 /^X\(\/\/\)[^/].*/{
18637 s//\1/
18638 q
18639 }
18640 /^X\(\/\/\)$/{
18641 s//\1/
18642 q
18643 }
18644 /^X\(\/\).*/{
18645 s//\1/
18646 q
18647 }
18648 s/.*/./; q'`
18649 test -d "$as_dir" && break
18650 done
18651 test -z "$as_dirs" || eval "mkdir $as_dirs"
18652 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
18653
18654
18655 } # as_fn_mkdir_p
18656 if mkdir -p . 2>/dev/null; then
18657 as_mkdir_p='mkdir -p "$as_dir"'
18658 else
18659 test -d ./-p && rmdir ./-p
18660 as_mkdir_p=false
18661 fi
18662
18663
18664 # as_fn_executable_p FILE
18665 # -----------------------
18666 # Test if FILE is an executable regular file.
18667 as_fn_executable_p ()
18668 {
18669 test -f "$1" && test -x "$1"
18670 } # as_fn_executable_p
18671 as_test_x='test -x'
18672 as_executable_p=as_fn_executable_p
18673
18674 # Sed expression to map a string onto a valid CPP name.
18675 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
18676
18677 # Sed expression to map a string onto a valid variable name.
18678 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
18679
18680
18681 exec 6>&1
18682 ## ----------------------------------- ##
18683 ## Main body of $CONFIG_STATUS script. ##
18684 ## ----------------------------------- ##
18685 _ASEOF
18686 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
18687
18688 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18689 # Save the log message, to keep $0 and so on meaningful, and to
18690 # report actual input values of CONFIG_FILES etc. instead of their
18691 # values after options handling.
18692 ac_log="
18693 This file was extended by $as_me, which was
18694 generated by GNU Autoconf 2.69. Invocation command line was
18695
18696 CONFIG_FILES = $CONFIG_FILES
18697 CONFIG_HEADERS = $CONFIG_HEADERS
18698 CONFIG_LINKS = $CONFIG_LINKS
18699 CONFIG_COMMANDS = $CONFIG_COMMANDS
18700 $ $0 $@
18701
18702 on `(hostname || uname -n) 2>/dev/null | sed 1q`
18703 "
18704
18705 _ACEOF
18706
18707 case $ac_config_files in *"
18708 "*) set x $ac_config_files; shift; ac_config_files=$*;;
18709 esac
18710
18711 case $ac_config_headers in *"
18712 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
18713 esac
18714
18715
18716 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18717 # Files that config.status was made for.
18718 config_files="$ac_config_files"
18719 config_headers="$ac_config_headers"
18720 config_links="$ac_config_links"
18721 config_commands="$ac_config_commands"
18722
18723 _ACEOF
18724
18725 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18726 ac_cs_usage="\
18727 \`$as_me' instantiates files and other configuration actions
18728 from templates according to the current configuration. Unless the files
18729 and actions are specified as TAGs, all are instantiated by default.
18730
18731 Usage: $0 [OPTION]... [TAG]...
18732
18733 -h, --help print this help, then exit
18734 -V, --version print version number and configuration settings, then exit
18735 --config print configuration, then exit
18736 -q, --quiet, --silent
18737 do not print progress messages
18738 -d, --debug don't remove temporary files
18739 --recheck update $as_me by reconfiguring in the same conditions
18740 --file=FILE[:TEMPLATE]
18741 instantiate the configuration file FILE
18742 --header=FILE[:TEMPLATE]
18743 instantiate the configuration header FILE
18744
18745 Configuration files:
18746 $config_files
18747
18748 Configuration headers:
18749 $config_headers
18750
18751 Configuration links:
18752 $config_links
18753
18754 Configuration commands:
18755 $config_commands
18756
18757 Report bugs to the package provider."
18758
18759 _ACEOF
18760 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18761 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
18762 ac_cs_version="\\
18763 config.status
18764 configured by $0, generated by GNU Autoconf 2.69,
18765 with options \\"\$ac_cs_config\\"
18766
18767 Copyright (C) 2012 Free Software Foundation, Inc.
18768 This config.status script is free software; the Free Software Foundation
18769 gives unlimited permission to copy, distribute and modify it."
18770
18771 ac_pwd='$ac_pwd'
18772 srcdir='$srcdir'
18773 INSTALL='$INSTALL'
18774 AWK='$AWK'
18775 test -n "\$AWK" || AWK=awk
18776 _ACEOF
18777
18778 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18779 # The default lists apply if the user does not specify any file.
18780 ac_need_defaults=:
18781 while test $# != 0
18782 do
18783 case $1 in
18784 --*=?*)
18785 ac_option=`expr "X$1" : 'X\([^=]*\)='`
18786 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
18787 ac_shift=:
18788 ;;
18789 --*=)
18790 ac_option=`expr "X$1" : 'X\([^=]*\)='`
18791 ac_optarg=
18792 ac_shift=:
18793 ;;
18794 *)
18795 ac_option=$1
18796 ac_optarg=$2
18797 ac_shift=shift
18798 ;;
18799 esac
18800
18801 case $ac_option in
18802 # Handling of the options.
18803 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18804 ac_cs_recheck=: ;;
18805 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
18806 $as_echo "$ac_cs_version"; exit ;;
18807 --config | --confi | --conf | --con | --co | --c )
18808 $as_echo "$ac_cs_config"; exit ;;
18809 --debug | --debu | --deb | --de | --d | -d )
18810 debug=: ;;
18811 --file | --fil | --fi | --f )
18812 $ac_shift
18813 case $ac_optarg in
18814 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18815 '') as_fn_error $? "missing file argument" ;;
18816 esac
18817 as_fn_append CONFIG_FILES " '$ac_optarg'"
18818 ac_need_defaults=false;;
18819 --header | --heade | --head | --hea )
18820 $ac_shift
18821 case $ac_optarg in
18822 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18823 esac
18824 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
18825 ac_need_defaults=false;;
18826 --he | --h)
18827 # Conflict between --help and --header
18828 as_fn_error $? "ambiguous option: \`$1'
18829 Try \`$0 --help' for more information.";;
18830 --help | --hel | -h )
18831 $as_echo "$ac_cs_usage"; exit ;;
18832 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18833 | -silent | --silent | --silen | --sile | --sil | --si | --s)
18834 ac_cs_silent=: ;;
18835
18836 # This is an error.
18837 -*) as_fn_error $? "unrecognized option: \`$1'
18838 Try \`$0 --help' for more information." ;;
18839
18840 *) as_fn_append ac_config_targets " $1"
18841 ac_need_defaults=false ;;
18842
18843 esac
18844 shift
18845 done
18846
18847 ac_configure_extra_args=
18848
18849 if $ac_cs_silent; then
18850 exec 6>/dev/null
18851 ac_configure_extra_args="$ac_configure_extra_args --silent"
18852 fi
18853
18854 _ACEOF
18855 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18856 if \$ac_cs_recheck; then
18857 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18858 shift
18859 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
18860 CONFIG_SHELL='$SHELL'
18861 export CONFIG_SHELL
18862 exec "\$@"
18863 fi
18864
18865 _ACEOF
18866 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18867 exec 5>>config.log
18868 {
18869 echo
18870 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18871 ## Running $as_me. ##
18872 _ASBOX
18873 $as_echo "$ac_log"
18874 } >&5
18875
18876 _ACEOF
18877 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18878 #
18879 # INIT-COMMANDS
18880 #
18881 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
18882 GDB_NM_FILE=$GDB_NM_FILE
18883
18884 _ACEOF
18885
18886 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18887
18888 # Handling of arguments.
18889 for ac_config_target in $ac_config_targets
18890 do
18891 case $ac_config_target in
18892 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
18893 "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
18894 "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
18895 "nm.h") CONFIG_LINKS="$CONFIG_LINKS nm.h:$GDB_NM_FILE" ;;
18896 "gcore") CONFIG_FILES="$CONFIG_FILES gcore" ;;
18897 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18898 "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
18899 "gdb-gdb.py") CONFIG_FILES="$CONFIG_FILES gdb-gdb.py" ;;
18900 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
18901 "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
18902
18903 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
18904 esac
18905 done
18906
18907
18908 # If the user did not use the arguments to specify the items to instantiate,
18909 # then the envvar interface is used. Set only those that are not.
18910 # We use the long form for the default assignment because of an extremely
18911 # bizarre bug on SunOS 4.1.3.
18912 if $ac_need_defaults; then
18913 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18914 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18915 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
18916 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
18917 fi
18918
18919 # Have a temporary directory for convenience. Make it in the build tree
18920 # simply because there is no reason against having it here, and in addition,
18921 # creating and moving files from /tmp can sometimes cause problems.
18922 # Hook for its removal unless debugging.
18923 # Note that there is a small window in which the directory will not be cleaned:
18924 # after its creation but before its name has been assigned to `$tmp'.
18925 $debug ||
18926 {
18927 tmp= ac_tmp=
18928 trap 'exit_status=$?
18929 : "${ac_tmp:=$tmp}"
18930 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
18931 ' 0
18932 trap 'as_fn_exit 1' 1 2 13 15
18933 }
18934 # Create a (secure) tmp directory for tmp files.
18935
18936 {
18937 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
18938 test -d "$tmp"
18939 } ||
18940 {
18941 tmp=./conf$$-$RANDOM
18942 (umask 077 && mkdir "$tmp")
18943 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
18944 ac_tmp=$tmp
18945
18946 # Set up the scripts for CONFIG_FILES section.
18947 # No need to generate them if there are no CONFIG_FILES.
18948 # This happens for instance with `./config.status config.h'.
18949 if test -n "$CONFIG_FILES"; then
18950
18951 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
18952 ac_cs_awk_getline=:
18953 ac_cs_awk_pipe_init=
18954 ac_cs_awk_read_file='
18955 while ((getline aline < (F[key])) > 0)
18956 print(aline)
18957 close(F[key])'
18958 ac_cs_awk_pipe_fini=
18959 else
18960 ac_cs_awk_getline=false
18961 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
18962 ac_cs_awk_read_file='
18963 print "|#_!!_#|"
18964 print "cat " F[key] " &&"
18965 '$ac_cs_awk_pipe_init
18966 # The final `:' finishes the AND list.
18967 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
18968 fi
18969 ac_cr=`echo X | tr X '\015'`
18970 # On cygwin, bash can eat \r inside `` if the user requested igncr.
18971 # But we know of no other shell where ac_cr would be empty at this
18972 # point, so we can use a bashism as a fallback.
18973 if test "x$ac_cr" = x; then
18974 eval ac_cr=\$\'\\r\'
18975 fi
18976 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
18977 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
18978 ac_cs_awk_cr='\\r'
18979 else
18980 ac_cs_awk_cr=$ac_cr
18981 fi
18982
18983 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
18984 _ACEOF
18985
18986 # Create commands to substitute file output variables.
18987 {
18988 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
18989 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
18990 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
18991 echo "_ACAWK" &&
18992 echo "_ACEOF"
18993 } >conf$$files.sh &&
18994 . ./conf$$files.sh ||
18995 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18996 rm -f conf$$files.sh
18997
18998 {
18999 echo "cat >conf$$subs.awk <<_ACEOF" &&
19000 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
19001 echo "_ACEOF"
19002 } >conf$$subs.sh ||
19003 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19004 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
19005 ac_delim='%!_!# '
19006 for ac_last_try in false false false false false :; do
19007 . ./conf$$subs.sh ||
19008 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19009
19010 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
19011 if test $ac_delim_n = $ac_delim_num; then
19012 break
19013 elif $ac_last_try; then
19014 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19015 else
19016 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19017 fi
19018 done
19019 rm -f conf$$subs.sh
19020
19021 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19022 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
19023 _ACEOF
19024 sed -n '
19025 h
19026 s/^/S["/; s/!.*/"]=/
19027 p
19028 g
19029 s/^[^!]*!//
19030 :repl
19031 t repl
19032 s/'"$ac_delim"'$//
19033 t delim
19034 :nl
19035 h
19036 s/\(.\{148\}\)..*/\1/
19037 t more1
19038 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
19039 p
19040 n
19041 b repl
19042 :more1
19043 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19044 p
19045 g
19046 s/.\{148\}//
19047 t nl
19048 :delim
19049 h
19050 s/\(.\{148\}\)..*/\1/
19051 t more2
19052 s/["\\]/\\&/g; s/^/"/; s/$/"/
19053 p
19054 b
19055 :more2
19056 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19057 p
19058 g
19059 s/.\{148\}//
19060 t delim
19061 ' <conf$$subs.awk | sed '
19062 /^[^""]/{
19063 N
19064 s/\n//
19065 }
19066 ' >>$CONFIG_STATUS || ac_write_fail=1
19067 rm -f conf$$subs.awk
19068 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19069 _ACAWK
19070 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
19071 for (key in S) S_is_set[key] = 1
19072 FS = "\a"
19073 \$ac_cs_awk_pipe_init
19074 }
19075 {
19076 line = $ 0
19077 nfields = split(line, field, "@")
19078 substed = 0
19079 len = length(field[1])
19080 for (i = 2; i < nfields; i++) {
19081 key = field[i]
19082 keylen = length(key)
19083 if (S_is_set[key]) {
19084 value = S[key]
19085 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
19086 len += length(value) + length(field[++i])
19087 substed = 1
19088 } else
19089 len += 1 + keylen
19090 }
19091 if (nfields == 3 && !substed) {
19092 key = field[2]
19093 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
19094 \$ac_cs_awk_read_file
19095 next
19096 }
19097 }
19098 print line
19099 }
19100 \$ac_cs_awk_pipe_fini
19101 _ACAWK
19102 _ACEOF
19103 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19104 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
19105 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
19106 else
19107 cat
19108 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
19109 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
19110 _ACEOF
19111
19112 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
19113 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
19114 # trailing colons and then remove the whole line if VPATH becomes empty
19115 # (actually we leave an empty line to preserve line numbers).
19116 if test "x$srcdir" = x.; then
19117 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
19118 h
19119 s///
19120 s/^/:/
19121 s/[ ]*$/:/
19122 s/:\$(srcdir):/:/g
19123 s/:\${srcdir}:/:/g
19124 s/:@srcdir@:/:/g
19125 s/^:*//
19126 s/:*$//
19127 x
19128 s/\(=[ ]*\).*/\1/
19129 G
19130 s/\n//
19131 s/^[^=]*=[ ]*$//
19132 }'
19133 fi
19134
19135 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19136 fi # test -n "$CONFIG_FILES"
19137
19138 # Set up the scripts for CONFIG_HEADERS section.
19139 # No need to generate them if there are no CONFIG_HEADERS.
19140 # This happens for instance with `./config.status Makefile'.
19141 if test -n "$CONFIG_HEADERS"; then
19142 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
19143 BEGIN {
19144 _ACEOF
19145
19146 # Transform confdefs.h into an awk script `defines.awk', embedded as
19147 # here-document in config.status, that substitutes the proper values into
19148 # config.h.in to produce config.h.
19149
19150 # Create a delimiter string that does not exist in confdefs.h, to ease
19151 # handling of long lines.
19152 ac_delim='%!_!# '
19153 for ac_last_try in false false :; do
19154 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
19155 if test -z "$ac_tt"; then
19156 break
19157 elif $ac_last_try; then
19158 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
19159 else
19160 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19161 fi
19162 done
19163
19164 # For the awk script, D is an array of macro values keyed by name,
19165 # likewise P contains macro parameters if any. Preserve backslash
19166 # newline sequences.
19167
19168 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
19169 sed -n '
19170 s/.\{148\}/&'"$ac_delim"'/g
19171 t rset
19172 :rset
19173 s/^[ ]*#[ ]*define[ ][ ]*/ /
19174 t def
19175 d
19176 :def
19177 s/\\$//
19178 t bsnl
19179 s/["\\]/\\&/g
19180 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
19181 D["\1"]=" \3"/p
19182 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
19183 d
19184 :bsnl
19185 s/["\\]/\\&/g
19186 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
19187 D["\1"]=" \3\\\\\\n"\\/p
19188 t cont
19189 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
19190 t cont
19191 d
19192 :cont
19193 n
19194 s/.\{148\}/&'"$ac_delim"'/g
19195 t clear
19196 :clear
19197 s/\\$//
19198 t bsnlc
19199 s/["\\]/\\&/g; s/^/"/; s/$/"/p
19200 d
19201 :bsnlc
19202 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
19203 b cont
19204 ' <confdefs.h | sed '
19205 s/'"$ac_delim"'/"\\\
19206 "/g' >>$CONFIG_STATUS || ac_write_fail=1
19207
19208 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19209 for (key in D) D_is_set[key] = 1
19210 FS = "\a"
19211 }
19212 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
19213 line = \$ 0
19214 split(line, arg, " ")
19215 if (arg[1] == "#") {
19216 defundef = arg[2]
19217 mac1 = arg[3]
19218 } else {
19219 defundef = substr(arg[1], 2)
19220 mac1 = arg[2]
19221 }
19222 split(mac1, mac2, "(") #)
19223 macro = mac2[1]
19224 prefix = substr(line, 1, index(line, defundef) - 1)
19225 if (D_is_set[macro]) {
19226 # Preserve the white space surrounding the "#".
19227 print prefix "define", macro P[macro] D[macro]
19228 next
19229 } else {
19230 # Replace #undef with comments. This is necessary, for example,
19231 # in the case of _POSIX_SOURCE, which is predefined and required
19232 # on some systems where configure will not decide to define it.
19233 if (defundef == "undef") {
19234 print "/*", prefix defundef, macro, "*/"
19235 next
19236 }
19237 }
19238 }
19239 { print }
19240 _ACAWK
19241 _ACEOF
19242 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19243 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
19244 fi # test -n "$CONFIG_HEADERS"
19245
19246
19247 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
19248 shift
19249 for ac_tag
19250 do
19251 case $ac_tag in
19252 :[FHLC]) ac_mode=$ac_tag; continue;;
19253 esac
19254 case $ac_mode$ac_tag in
19255 :[FHL]*:*);;
19256 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
19257 :[FH]-) ac_tag=-:-;;
19258 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
19259 esac
19260 ac_save_IFS=$IFS
19261 IFS=:
19262 set x $ac_tag
19263 IFS=$ac_save_IFS
19264 shift
19265 ac_file=$1
19266 shift
19267
19268 case $ac_mode in
19269 :L) ac_source=$1;;
19270 :[FH])
19271 ac_file_inputs=
19272 for ac_f
19273 do
19274 case $ac_f in
19275 -) ac_f="$ac_tmp/stdin";;
19276 *) # Look for the file first in the build tree, then in the source tree
19277 # (if the path is not absolute). The absolute path cannot be DOS-style,
19278 # because $ac_f cannot contain `:'.
19279 test -f "$ac_f" ||
19280 case $ac_f in
19281 [\\/$]*) false;;
19282 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
19283 esac ||
19284 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
19285 esac
19286 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
19287 as_fn_append ac_file_inputs " '$ac_f'"
19288 done
19289
19290 # Let's still pretend it is `configure' which instantiates (i.e., don't
19291 # use $as_me), people would be surprised to read:
19292 # /* config.h. Generated by config.status. */
19293 configure_input='Generated from '`
19294 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
19295 `' by configure.'
19296 if test x"$ac_file" != x-; then
19297 configure_input="$ac_file. $configure_input"
19298 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
19299 $as_echo "$as_me: creating $ac_file" >&6;}
19300 fi
19301 # Neutralize special characters interpreted by sed in replacement strings.
19302 case $configure_input in #(
19303 *\&* | *\|* | *\\* )
19304 ac_sed_conf_input=`$as_echo "$configure_input" |
19305 sed 's/[\\\\&|]/\\\\&/g'`;; #(
19306 *) ac_sed_conf_input=$configure_input;;
19307 esac
19308
19309 case $ac_tag in
19310 *:-:* | *:-) cat >"$ac_tmp/stdin" \
19311 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
19312 esac
19313 ;;
19314 esac
19315
19316 ac_dir=`$as_dirname -- "$ac_file" ||
19317 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19318 X"$ac_file" : 'X\(//\)[^/]' \| \
19319 X"$ac_file" : 'X\(//\)$' \| \
19320 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
19321 $as_echo X"$ac_file" |
19322 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19323 s//\1/
19324 q
19325 }
19326 /^X\(\/\/\)[^/].*/{
19327 s//\1/
19328 q
19329 }
19330 /^X\(\/\/\)$/{
19331 s//\1/
19332 q
19333 }
19334 /^X\(\/\).*/{
19335 s//\1/
19336 q
19337 }
19338 s/.*/./; q'`
19339 as_dir="$ac_dir"; as_fn_mkdir_p
19340 ac_builddir=.
19341
19342 case "$ac_dir" in
19343 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
19344 *)
19345 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
19346 # A ".." for each directory in $ac_dir_suffix.
19347 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
19348 case $ac_top_builddir_sub in
19349 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
19350 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
19351 esac ;;
19352 esac
19353 ac_abs_top_builddir=$ac_pwd
19354 ac_abs_builddir=$ac_pwd$ac_dir_suffix
19355 # for backward compatibility:
19356 ac_top_builddir=$ac_top_build_prefix
19357
19358 case $srcdir in
19359 .) # We are building in place.
19360 ac_srcdir=.
19361 ac_top_srcdir=$ac_top_builddir_sub
19362 ac_abs_top_srcdir=$ac_pwd ;;
19363 [\\/]* | ?:[\\/]* ) # Absolute name.
19364 ac_srcdir=$srcdir$ac_dir_suffix;
19365 ac_top_srcdir=$srcdir
19366 ac_abs_top_srcdir=$srcdir ;;
19367 *) # Relative name.
19368 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
19369 ac_top_srcdir=$ac_top_build_prefix$srcdir
19370 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
19371 esac
19372 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
19373
19374
19375 case $ac_mode in
19376 :F)
19377 #
19378 # CONFIG_FILE
19379 #
19380
19381 case $INSTALL in
19382 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
19383 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
19384 esac
19385 _ACEOF
19386
19387 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19388 # If the template does not know about datarootdir, expand it.
19389 # FIXME: This hack should be removed a few years after 2.60.
19390 ac_datarootdir_hack=; ac_datarootdir_seen=
19391 ac_sed_dataroot='
19392 /datarootdir/ {
19393 p
19394 q
19395 }
19396 /@datadir@/p
19397 /@docdir@/p
19398 /@infodir@/p
19399 /@localedir@/p
19400 /@mandir@/p'
19401 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
19402 *datarootdir*) ac_datarootdir_seen=yes;;
19403 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
19404 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
19405 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
19406 _ACEOF
19407 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19408 ac_datarootdir_hack='
19409 s&@datadir@&$datadir&g
19410 s&@docdir@&$docdir&g
19411 s&@infodir@&$infodir&g
19412 s&@localedir@&$localedir&g
19413 s&@mandir@&$mandir&g
19414 s&\\\${datarootdir}&$datarootdir&g' ;;
19415 esac
19416 _ACEOF
19417
19418 # Neutralize VPATH when `$srcdir' = `.'.
19419 # Shell code in configure.ac might set extrasub.
19420 # FIXME: do we really want to maintain this feature?
19421 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19422 ac_sed_extra="$ac_vpsub
19423 $extrasub
19424 _ACEOF
19425 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19426 :t
19427 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
19428 s|@configure_input@|$ac_sed_conf_input|;t t
19429 s&@top_builddir@&$ac_top_builddir_sub&;t t
19430 s&@top_build_prefix@&$ac_top_build_prefix&;t t
19431 s&@srcdir@&$ac_srcdir&;t t
19432 s&@abs_srcdir@&$ac_abs_srcdir&;t t
19433 s&@top_srcdir@&$ac_top_srcdir&;t t
19434 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
19435 s&@builddir@&$ac_builddir&;t t
19436 s&@abs_builddir@&$ac_abs_builddir&;t t
19437 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
19438 s&@INSTALL@&$ac_INSTALL&;t t
19439 $ac_datarootdir_hack
19440 "
19441 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
19442 if $ac_cs_awk_getline; then
19443 $AWK -f "$ac_tmp/subs.awk"
19444 else
19445 $AWK -f "$ac_tmp/subs.awk" | $SHELL
19446 fi \
19447 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19448
19449 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
19450 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
19451 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
19452 "$ac_tmp/out"`; test -z "$ac_out"; } &&
19453 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19454 which seems to be undefined. Please make sure it is defined" >&5
19455 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19456 which seems to be undefined. Please make sure it is defined" >&2;}
19457
19458 rm -f "$ac_tmp/stdin"
19459 case $ac_file in
19460 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
19461 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
19462 esac \
19463 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19464 ;;
19465 :H)
19466 #
19467 # CONFIG_HEADER
19468 #
19469 if test x"$ac_file" != x-; then
19470 {
19471 $as_echo "/* $configure_input */" \
19472 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
19473 } >"$ac_tmp/config.h" \
19474 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19475 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
19476 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
19477 $as_echo "$as_me: $ac_file is unchanged" >&6;}
19478 else
19479 rm -f "$ac_file"
19480 mv "$ac_tmp/config.h" "$ac_file" \
19481 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19482 fi
19483 else
19484 $as_echo "/* $configure_input */" \
19485 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
19486 || as_fn_error $? "could not create -" "$LINENO" 5
19487 fi
19488 ;;
19489 :L)
19490 #
19491 # CONFIG_LINK
19492 #
19493
19494 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
19495 :
19496 else
19497 # Prefer the file from the source tree if names are identical.
19498 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
19499 ac_source=$srcdir/$ac_source
19500 fi
19501
19502 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
19503 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
19504
19505 if test ! -r "$ac_source"; then
19506 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
19507 fi
19508 rm -f "$ac_file"
19509
19510 # Try a relative symlink, then a hard link, then a copy.
19511 case $ac_source in
19512 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
19513 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
19514 esac
19515 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
19516 ln "$ac_source" "$ac_file" 2>/dev/null ||
19517 cp -p "$ac_source" "$ac_file" ||
19518 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
19519 fi
19520 ;;
19521 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
19522 $as_echo "$as_me: executing $ac_file commands" >&6;}
19523 ;;
19524 esac
19525
19526
19527 case $ac_file$ac_mode in
19528 "config.h":H) echo > stamp-h ;;
19529 "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
19530 "nm.h":L) echo > stamp-nmh ;;
19531 "gcore":F) chmod +x gcore ;;
19532
19533 esac
19534 done # for ac_tag
19535
19536
19537 as_fn_exit 0
19538 _ACEOF
19539 ac_clean_files=$ac_clean_files_save
19540
19541 test $ac_write_fail = 0 ||
19542 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
19543
19544
19545 # configure is writing to config.log, and then calls config.status.
19546 # config.status does its own redirection, appending to config.log.
19547 # Unfortunately, on DOS this fails, as config.log is still kept open
19548 # by configure, so config.status won't be able to write to it; its
19549 # output is simply discarded. So we exec the FD to /dev/null,
19550 # effectively closing config.log, so it can be properly (re)opened and
19551 # appended to by config.status. When coming back to configure, we
19552 # need to make the FD available again.
19553 if test "$no_create" != yes; then
19554 ac_cs_success=:
19555 ac_config_status_args=
19556 test "$silent" = yes &&
19557 ac_config_status_args="$ac_config_status_args --quiet"
19558 exec 5>/dev/null
19559 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
19560 exec 5>>config.log
19561 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19562 # would make configure fail if this is the last instruction.
19563 $ac_cs_success || as_fn_exit 1
19564 fi
19565
19566 #
19567 # CONFIG_SUBDIRS section.
19568 #
19569 if test "$no_recursion" != yes; then
19570
19571 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
19572 # so they do not pile up.
19573 ac_sub_configure_args=
19574 ac_prev=
19575 eval "set x $ac_configure_args"
19576 shift
19577 for ac_arg
19578 do
19579 if test -n "$ac_prev"; then
19580 ac_prev=
19581 continue
19582 fi
19583 case $ac_arg in
19584 -cache-file | --cache-file | --cache-fil | --cache-fi \
19585 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
19586 ac_prev=cache_file ;;
19587 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
19588 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
19589 | --c=*)
19590 ;;
19591 --config-cache | -C)
19592 ;;
19593 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
19594 ac_prev=srcdir ;;
19595 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
19596 ;;
19597 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
19598 ac_prev=prefix ;;
19599 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
19600 ;;
19601 --disable-option-checking)
19602 ;;
19603 *)
19604 case $ac_arg in
19605 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
19606 esac
19607 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
19608 esac
19609 done
19610
19611 # Always prepend --prefix to ensure using the same prefix
19612 # in subdir configurations.
19613 ac_arg="--prefix=$prefix"
19614 case $ac_arg in
19615 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
19616 esac
19617 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
19618
19619 # Pass --silent
19620 if test "$silent" = yes; then
19621 ac_sub_configure_args="--silent $ac_sub_configure_args"
19622 fi
19623
19624 # Always prepend --disable-option-checking to silence warnings, since
19625 # different subdirs can have different --enable and --with options.
19626 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
19627
19628 ac_popdir=`pwd`
19629 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
19630
19631 # Do not complain, so a configure script can configure whichever
19632 # parts of a large source tree are present.
19633 test -d "$srcdir/$ac_dir" || continue
19634
19635 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
19636 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
19637 $as_echo "$ac_msg" >&6
19638 as_dir="$ac_dir"; as_fn_mkdir_p
19639 ac_builddir=.
19640
19641 case "$ac_dir" in
19642 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
19643 *)
19644 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
19645 # A ".." for each directory in $ac_dir_suffix.
19646 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
19647 case $ac_top_builddir_sub in
19648 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
19649 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
19650 esac ;;
19651 esac
19652 ac_abs_top_builddir=$ac_pwd
19653 ac_abs_builddir=$ac_pwd$ac_dir_suffix
19654 # for backward compatibility:
19655 ac_top_builddir=$ac_top_build_prefix
19656
19657 case $srcdir in
19658 .) # We are building in place.
19659 ac_srcdir=.
19660 ac_top_srcdir=$ac_top_builddir_sub
19661 ac_abs_top_srcdir=$ac_pwd ;;
19662 [\\/]* | ?:[\\/]* ) # Absolute name.
19663 ac_srcdir=$srcdir$ac_dir_suffix;
19664 ac_top_srcdir=$srcdir
19665 ac_abs_top_srcdir=$srcdir ;;
19666 *) # Relative name.
19667 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
19668 ac_top_srcdir=$ac_top_build_prefix$srcdir
19669 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
19670 esac
19671 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
19672
19673
19674 cd "$ac_dir"
19675
19676 # Check for guested configure; otherwise get Cygnus style configure.
19677 if test -f "$ac_srcdir/configure.gnu"; then
19678 ac_sub_configure=$ac_srcdir/configure.gnu
19679 elif test -f "$ac_srcdir/configure"; then
19680 ac_sub_configure=$ac_srcdir/configure
19681 elif test -f "$ac_srcdir/configure.in"; then
19682 # This should be Cygnus configure.
19683 ac_sub_configure=$ac_aux_dir/configure
19684 else
19685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
19686 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
19687 ac_sub_configure=
19688 fi
19689
19690 # The recursion is here.
19691 if test -n "$ac_sub_configure"; then
19692 # Make the cache file name correct relative to the subdirectory.
19693 case $cache_file in
19694 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
19695 *) # Relative name.
19696 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
19697 esac
19698
19699 { $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
19700 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
19701 # The eval makes quoting arguments work.
19702 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
19703 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
19704 as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
19705 fi
19706
19707 cd "$ac_popdir"
19708 done
19709 fi
19710 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
19711 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
19712 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
19713 fi
19714