gdb/
[platform/upstream/binutils.git] / gdb / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.64.
4 #
5 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
7 # Foundation, Inc.
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 case $0 in #((
91   *[\\/]* ) as_myself=$0 ;;
92   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93 for as_dir in $PATH
94 do
95   IFS=$as_save_IFS
96   test -z "$as_dir" && as_dir=.
97     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
98   done
99 IFS=$as_save_IFS
100
101      ;;
102 esac
103 # We did not find ourselves, most probably we were run as `sh COMMAND'
104 # in which case we are not to be found in the path.
105 if test "x$as_myself" = x; then
106   as_myself=$0
107 fi
108 if test ! -f "$as_myself"; then
109   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
110   exit 1
111 fi
112
113 # Unset variables that we do not need and which cause bugs (e.g. in
114 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
115 # suppresses any "Segmentation fault" message there.  '((' could
116 # trigger a bug in pdksh 5.2.14.
117 for as_var in BASH_ENV ENV MAIL MAILPATH
118 do eval test x\${$as_var+set} = xset \
119   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
120 done
121 PS1='$ '
122 PS2='> '
123 PS4='+ '
124
125 # NLS nuisances.
126 LC_ALL=C
127 export LC_ALL
128 LANGUAGE=C
129 export LANGUAGE
130
131 # CDPATH.
132 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
133
134 if test "x$CONFIG_SHELL" = x; then
135   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
136   emulate sh
137   NULLCMD=:
138   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
139   # is contrary to our usage.  Disable this feature.
140   alias -g '\${1+\"\$@\"}'='\"\$@\"'
141   setopt NO_GLOB_SUBST
142 else
143   case \`(set -o) 2>/dev/null\` in #(
144   *posix*) :
145     set -o posix ;; #(
146   *) :
147      ;;
148 esac
149 fi
150 "
151   as_required="as_fn_return () { (exit \$1); }
152 as_fn_success () { as_fn_return 0; }
153 as_fn_failure () { as_fn_return 1; }
154 as_fn_ret_success () { return 0; }
155 as_fn_ret_failure () { return 1; }
156
157 exitcode=0
158 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
159 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
160 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
161 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
162 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
163
164 else
165   exitcode=1; echo positional parameters were not saved.
166 fi
167 test x\$exitcode = x0 || exit 1"
168   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
169   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
170   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
171   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
172 test \$(( 1 + 1 )) = 2 || exit 1"
173   if (eval "$as_required") 2>/dev/null; then :
174   as_have_required=yes
175 else
176   as_have_required=no
177 fi
178   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
179
180 else
181   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
182 as_found=false
183 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
184 do
185   IFS=$as_save_IFS
186   test -z "$as_dir" && as_dir=.
187   as_found=:
188   case $as_dir in #(
189          /*)
190            for as_base in sh bash ksh sh5; do
191              # Try only shells that exist, to save several forks.
192              as_shell=$as_dir/$as_base
193              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
194                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
195   CONFIG_SHELL=$as_shell as_have_required=yes
196                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
197   break 2
198 fi
199 fi
200            done;;
201        esac
202   as_found=false
203 done
204 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
205               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
206   CONFIG_SHELL=$SHELL as_have_required=yes
207 fi; }
208 IFS=$as_save_IFS
209
210
211       if test "x$CONFIG_SHELL" != x; then :
212   # We cannot yet assume a decent shell, so we have to provide a
213         # neutralization value for shells without unset; and this also
214         # works around shells that cannot unset nonexistent variables.
215         BASH_ENV=/dev/null
216         ENV=/dev/null
217         (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
218         export CONFIG_SHELL
219         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
220 fi
221
222     if test x$as_have_required = xno; then :
223   $as_echo "$0: This script requires a shell more modern than all"
224   $as_echo "$0: the shells that I found on your system."
225   if test x${ZSH_VERSION+set} = xset ; then
226     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
227     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
228   else
229     $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
230 $0: including any error possibly output before this
231 $0: message. Then install a modern shell, or manually run
232 $0: the script under such a shell if you do have one."
233   fi
234   exit 1
235 fi
236 fi
237 fi
238 SHELL=${CONFIG_SHELL-/bin/sh}
239 export SHELL
240 # Unset more variables known to interfere with behavior of common tools.
241 CLICOLOR_FORCE= GREP_OPTIONS=
242 unset CLICOLOR_FORCE GREP_OPTIONS
243
244 ## --------------------- ##
245 ## M4sh Shell Functions. ##
246 ## --------------------- ##
247 # as_fn_unset VAR
248 # ---------------
249 # Portably unset VAR.
250 as_fn_unset ()
251 {
252   { eval $1=; unset $1;}
253 }
254 as_unset=as_fn_unset
255
256 # as_fn_set_status STATUS
257 # -----------------------
258 # Set $? to STATUS, without forking.
259 as_fn_set_status ()
260 {
261   return $1
262 } # as_fn_set_status
263
264 # as_fn_exit STATUS
265 # -----------------
266 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
267 as_fn_exit ()
268 {
269   set +e
270   as_fn_set_status $1
271   exit $1
272 } # as_fn_exit
273
274 # as_fn_mkdir_p
275 # -------------
276 # Create "$as_dir" as a directory, including parents if necessary.
277 as_fn_mkdir_p ()
278 {
279
280   case $as_dir in #(
281   -*) as_dir=./$as_dir;;
282   esac
283   test -d "$as_dir" || eval $as_mkdir_p || {
284     as_dirs=
285     while :; do
286       case $as_dir in #(
287       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
288       *) as_qdir=$as_dir;;
289       esac
290       as_dirs="'$as_qdir' $as_dirs"
291       as_dir=`$as_dirname -- "$as_dir" ||
292 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
293          X"$as_dir" : 'X\(//\)[^/]' \| \
294          X"$as_dir" : 'X\(//\)$' \| \
295          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
296 $as_echo X"$as_dir" |
297     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
298             s//\1/
299             q
300           }
301           /^X\(\/\/\)[^/].*/{
302             s//\1/
303             q
304           }
305           /^X\(\/\/\)$/{
306             s//\1/
307             q
308           }
309           /^X\(\/\).*/{
310             s//\1/
311             q
312           }
313           s/.*/./; q'`
314       test -d "$as_dir" && break
315     done
316     test -z "$as_dirs" || eval "mkdir $as_dirs"
317   } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
318
319
320 } # as_fn_mkdir_p
321 # as_fn_append VAR VALUE
322 # ----------------------
323 # Append the text in VALUE to the end of the definition contained in VAR. Take
324 # advantage of any shell optimizations that allow amortized linear growth over
325 # repeated appends, instead of the typical quadratic growth present in naive
326 # implementations.
327 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
328   eval 'as_fn_append ()
329   {
330     eval $1+=\$2
331   }'
332 else
333   as_fn_append ()
334   {
335     eval $1=\$$1\$2
336   }
337 fi # as_fn_append
338
339 # as_fn_arith ARG...
340 # ------------------
341 # Perform arithmetic evaluation on the ARGs, and store the result in the
342 # global $as_val. Take advantage of shells that can avoid forks. The arguments
343 # must be portable across $(()) and expr.
344 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
345   eval 'as_fn_arith ()
346   {
347     as_val=$(( $* ))
348   }'
349 else
350   as_fn_arith ()
351   {
352     as_val=`expr "$@" || test $? -eq 1`
353   }
354 fi # as_fn_arith
355
356
357 # as_fn_error ERROR [LINENO LOG_FD]
358 # ---------------------------------
359 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
360 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
361 # script with status $?, using 1 if that was 0.
362 as_fn_error ()
363 {
364   as_status=$?; test $as_status -eq 0 && as_status=1
365   if test "$3"; then
366     as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
367     $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
368   fi
369   $as_echo "$as_me: error: $1" >&2
370   as_fn_exit $as_status
371 } # as_fn_error
372
373 if expr a : '\(a\)' >/dev/null 2>&1 &&
374    test "X`expr 00001 : '.*\(...\)'`" = X001; then
375   as_expr=expr
376 else
377   as_expr=false
378 fi
379
380 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
381   as_basename=basename
382 else
383   as_basename=false
384 fi
385
386 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
387   as_dirname=dirname
388 else
389   as_dirname=false
390 fi
391
392 as_me=`$as_basename -- "$0" ||
393 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
394          X"$0" : 'X\(//\)$' \| \
395          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
396 $as_echo X/"$0" |
397     sed '/^.*\/\([^/][^/]*\)\/*$/{
398             s//\1/
399             q
400           }
401           /^X\/\(\/\/\)$/{
402             s//\1/
403             q
404           }
405           /^X\/\(\/\).*/{
406             s//\1/
407             q
408           }
409           s/.*/./; q'`
410
411 # Avoid depending upon Character Ranges.
412 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
413 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
414 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
415 as_cr_digits='0123456789'
416 as_cr_alnum=$as_cr_Letters$as_cr_digits
417
418
419   as_lineno_1=$LINENO as_lineno_1a=$LINENO
420   as_lineno_2=$LINENO as_lineno_2a=$LINENO
421   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
422   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
423   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
424   sed -n '
425     p
426     /[$]LINENO/=
427   ' <$as_myself |
428     sed '
429       s/[$]LINENO.*/&-/
430       t lineno
431       b
432       :lineno
433       N
434       :loop
435       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
436       t loop
437       s/-\n.*//
438     ' >$as_me.lineno &&
439   chmod +x "$as_me.lineno" ||
440     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
441
442   # Don't try to exec as it changes $[0], causing all sort of problems
443   # (the dirname of $[0] is not the place where we might find the
444   # original and so on.  Autoconf is especially sensitive to this).
445   . "./$as_me.lineno"
446   # Exit status is that of the last command.
447   exit
448 }
449
450 ECHO_C= ECHO_N= ECHO_T=
451 case `echo -n x` in #(((((
452 -n*)
453   case `echo 'xy\c'` in
454   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
455   xy)  ECHO_C='\c';;
456   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
457        ECHO_T=' ';;
458   esac;;
459 *)
460   ECHO_N='-n';;
461 esac
462
463 rm -f conf$$ conf$$.exe conf$$.file
464 if test -d conf$$.dir; then
465   rm -f conf$$.dir/conf$$.file
466 else
467   rm -f conf$$.dir
468   mkdir conf$$.dir 2>/dev/null
469 fi
470 if (echo >conf$$.file) 2>/dev/null; then
471   if ln -s conf$$.file conf$$ 2>/dev/null; then
472     as_ln_s='ln -s'
473     # ... but there are two gotchas:
474     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
475     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
476     # In both cases, we have to default to `cp -p'.
477     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
478       as_ln_s='cp -p'
479   elif ln conf$$.file conf$$ 2>/dev/null; then
480     as_ln_s=ln
481   else
482     as_ln_s='cp -p'
483   fi
484 else
485   as_ln_s='cp -p'
486 fi
487 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
488 rmdir conf$$.dir 2>/dev/null
489
490 if mkdir -p . 2>/dev/null; then
491   as_mkdir_p='mkdir -p "$as_dir"'
492 else
493   test -d ./-p && rmdir ./-p
494   as_mkdir_p=false
495 fi
496
497 if test -x / >/dev/null 2>&1; then
498   as_test_x='test -x'
499 else
500   if ls -dL / >/dev/null 2>&1; then
501     as_ls_L_option=L
502   else
503     as_ls_L_option=
504   fi
505   as_test_x='
506     eval sh -c '\''
507       if test -d "$1"; then
508         test -d "$1/.";
509       else
510         case $1 in #(
511         -*)set "./$1";;
512         esac;
513         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
514         ???[sx]*):;;*)false;;esac;fi
515     '\'' sh
516   '
517 fi
518 as_executable_p=$as_test_x
519
520 # Sed expression to map a string onto a valid CPP name.
521 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
522
523 # Sed expression to map a string onto a valid variable name.
524 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
525
526
527 exec 7<&0 </dev/null 6>&1
528
529 # Name of the host.
530 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
531 # so uname gets run too.
532 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
533
534 #
535 # Initializations.
536 #
537 ac_default_prefix=/usr/local
538 ac_clean_files=
539 ac_config_libobj_dir=.
540 LIBOBJS=
541 cross_compiling=no
542 subdirs=
543 MFLAGS=
544 MAKEFLAGS=
545
546 # Identity of this package.
547 PACKAGE_NAME=
548 PACKAGE_TARNAME=
549 PACKAGE_VERSION=
550 PACKAGE_STRING=
551 PACKAGE_BUGREPORT=
552 PACKAGE_URL=
553
554 ac_unique_file="main.c"
555 # Factoring default headers for most tests.
556 ac_includes_default="\
557 #include <stdio.h>
558 #ifdef HAVE_SYS_TYPES_H
559 # include <sys/types.h>
560 #endif
561 #ifdef HAVE_SYS_STAT_H
562 # include <sys/stat.h>
563 #endif
564 #ifdef STDC_HEADERS
565 # include <stdlib.h>
566 # include <stddef.h>
567 #else
568 # ifdef HAVE_STDLIB_H
569 #  include <stdlib.h>
570 # endif
571 #endif
572 #ifdef HAVE_STRING_H
573 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
574 #  include <memory.h>
575 # endif
576 # include <string.h>
577 #endif
578 #ifdef HAVE_STRINGS_H
579 # include <strings.h>
580 #endif
581 #ifdef HAVE_INTTYPES_H
582 # include <inttypes.h>
583 #endif
584 #ifdef HAVE_STDINT_H
585 # include <stdint.h>
586 #endif
587 #ifdef HAVE_UNISTD_H
588 # include <unistd.h>
589 #endif"
590
591 enable_option_checking=no
592 ac_subst_vars='LTLIBOBJS
593 LIBOBJS
594 GDB_NM_FILE
595 LTLIBBABELTRACE
596 LIBBABELTRACE
597 HAVE_LIBBABELTRACE
598 frags
599 target_subdir
600 CONFIG_UNINSTALL
601 CONFIG_INSTALL
602 CONFIG_CLEAN
603 CONFIG_ALL
604 CONFIG_SRCS
605 CONFIG_DEPS
606 CONFIG_OBS
607 PROFILE_CFLAGS
608 ENABLE_CFLAGS
609 SIM_OBS
610 SIM
611 XMKMF
612 GDBTK_SRC_DIR
613 GDBTK_CFLAGS
614 GDBTKLIBS
615 X_LIBS
616 X_LDFLAGS
617 X_CFLAGS
618 TK_XINCLUDES
619 TK_DEPS
620 TK_LIBRARY
621 TK_INCLUDE
622 TK_STUB_LIB_SPEC
623 TK_STUB_LIB_FLAG
624 TK_STUB_LIB_FILE
625 TK_LIB_SPEC
626 TK_LIB_FLAG
627 TK_LIB_FILE
628 TK_SRC_DIR
629 TK_BIN_DIR
630 TK_VERSION
631 TCL_DEPS
632 TCL_LIBRARY
633 TCL_INCLUDE
634 TCL_STUB_LIB_SPEC
635 TCL_STUB_LIB_FLAG
636 TCL_STUB_LIB_FILE
637 TCL_LIB_SPEC
638 TCL_LIB_FLAG
639 TCL_LIB_FILE
640 TCL_SRC_DIR
641 TCL_BIN_DIR
642 TCL_PATCH_LEVEL
643 TCL_VERSION
644 WIN32LDAPP
645 GUI_CFLAGS_X
646 LIBGUI
647 LTLIBLZMA
648 LIBLZMA
649 HAVE_LIBLZMA
650 WIN32LIBS
651 SER_HARDWIRE
652 WERROR_CFLAGS
653 WARN_CFLAGS
654 SYSTEM_GDBINIT
655 TARGET_SYSTEM_ROOT
656 CONFIG_LDFLAGS
657 RDYNAMIC
658 ALLOCA
659 PYTHON_LIBS
660 PYTHON_CPPFLAGS
661 PYTHON_CFLAGS
662 python_prog_path
663 LTLIBEXPAT
664 LIBEXPAT
665 HAVE_LIBEXPAT
666 JIT_READER_DIR
667 TARGET_PTR
668 READLINE_TEXI_INCFLAG
669 READLINE_CFLAGS
670 READLINE_DEPS
671 READLINE
672 MIG
673 WINDRES
674 DLLTOOL
675 AR
676 YFLAGS
677 YACC
678 RANLIB
679 LN_S
680 INSTALL_DATA
681 INSTALL_SCRIPT
682 INSTALL_PROGRAM
683 AWK
684 REPORT_BUGS_TEXI
685 REPORT_BUGS_TO
686 PKGVERSION
687 TARGET_OBS
688 subdirs
689 GDB_DATADIR
690 DEBUGDIR
691 MAKEINFO_EXTRA_FLAGS
692 MAKEINFOFLAGS
693 MAKEINFO
694 PACKAGE
695 GNULIB_STDINT_H
696 CATOBJEXT
697 GENCAT
698 INSTOBJEXT
699 DATADIRNAME
700 CATALOGS
701 POSUB
702 GMSGFMT
703 XGETTEXT
704 INCINTL
705 LIBINTL_DEP
706 LIBINTL
707 USE_NLS
708 SET_MAKE
709 GMAKE_FALSE
710 GMAKE_TRUE
711 MAKE
712 CCDEPMODE
713 DEPDIR
714 am__leading_dot
715 target_os
716 target_vendor
717 target_cpu
718 target
719 host_os
720 host_vendor
721 host_cpu
722 host
723 build_os
724 build_vendor
725 build_cpu
726 build
727 EGREP
728 GREP
729 CPP
730 OBJEXT
731 EXEEXT
732 ac_ct_CC
733 CPPFLAGS
734 LDFLAGS
735 CFLAGS
736 CC
737 MAINT
738 MAINTAINER_MODE_FALSE
739 MAINTAINER_MODE_TRUE
740 target_alias
741 host_alias
742 build_alias
743 LIBS
744 ECHO_T
745 ECHO_N
746 ECHO_C
747 DEFS
748 mandir
749 localedir
750 libdir
751 psdir
752 pdfdir
753 dvidir
754 htmldir
755 infodir
756 docdir
757 oldincludedir
758 includedir
759 localstatedir
760 sharedstatedir
761 sysconfdir
762 datadir
763 datarootdir
764 libexecdir
765 sbindir
766 bindir
767 program_transform_name
768 prefix
769 exec_prefix
770 PACKAGE_URL
771 PACKAGE_BUGREPORT
772 PACKAGE_STRING
773 PACKAGE_VERSION
774 PACKAGE_TARNAME
775 PACKAGE_NAME
776 PATH_SEPARATOR
777 SHELL'
778 ac_subst_files='host_makefile_frag'
779 ac_user_opts='
780 enable_option_checking
781 enable_maintainer_mode
782 enable_plugins
783 enable_largefile
784 with_separate_debug_dir
785 with_gdb_datadir
786 with_relocated_sources
787 with_auto_load_dir
788 with_auto_load_safe_path
789 enable_targets
790 enable_64_bit_bfd
791 enable_gdbcli
792 enable_gdbmi
793 enable_tui
794 enable_gdbtk
795 with_libunwind_ia64
796 with_curses
797 enable_profiling
798 with_pkgversion
799 with_bugurl
800 with_zlib
801 with_libiconv_prefix
802 with_iconv_bin
803 with_system_readline
804 with_jit_reader_dir
805 with_expat
806 with_gnu_ld
807 enable_rpath
808 with_libexpat_prefix
809 with_python
810 enable_libmcheck
811 with_included_regex
812 with_sysroot
813 with_system_gdbinit
814 enable_werror
815 enable_build_warnings
816 enable_gdb_build_warnings
817 with_lzma
818 with_liblzma_prefix
819 with_tcl
820 with_tk
821 with_x
822 enable_sim
823 enable_multi_ice
824 enable_gdbserver
825 with_babeltrace
826 with_libbabeltrace_prefix
827 '
828       ac_precious_vars='build_alias
829 host_alias
830 target_alias
831 CC
832 CFLAGS
833 LDFLAGS
834 LIBS
835 CPPFLAGS
836 CPP
837 MAKEINFO
838 MAKEINFOFLAGS
839 YACC
840 YFLAGS
841 XMKMF'
842 ac_subdirs_all='testsuite
843 gdbtk
844 multi-ice
845 gdbserver'
846
847 # Initialize some variables set by options.
848 ac_init_help=
849 ac_init_version=false
850 ac_unrecognized_opts=
851 ac_unrecognized_sep=
852 # The variables have the same names as the options, with
853 # dashes changed to underlines.
854 cache_file=/dev/null
855 exec_prefix=NONE
856 no_create=
857 no_recursion=
858 prefix=NONE
859 program_prefix=NONE
860 program_suffix=NONE
861 program_transform_name=s,x,x,
862 silent=
863 site=
864 srcdir=
865 verbose=
866 x_includes=NONE
867 x_libraries=NONE
868
869 # Installation directory options.
870 # These are left unexpanded so users can "make install exec_prefix=/foo"
871 # and all the variables that are supposed to be based on exec_prefix
872 # by default will actually change.
873 # Use braces instead of parens because sh, perl, etc. also accept them.
874 # (The list follows the same order as the GNU Coding Standards.)
875 bindir='${exec_prefix}/bin'
876 sbindir='${exec_prefix}/sbin'
877 libexecdir='${exec_prefix}/libexec'
878 datarootdir='${prefix}/share'
879 datadir='${datarootdir}'
880 sysconfdir='${prefix}/etc'
881 sharedstatedir='${prefix}/com'
882 localstatedir='${prefix}/var'
883 includedir='${prefix}/include'
884 oldincludedir='/usr/include'
885 docdir='${datarootdir}/doc/${PACKAGE}'
886 infodir='${datarootdir}/info'
887 htmldir='${docdir}'
888 dvidir='${docdir}'
889 pdfdir='${docdir}'
890 psdir='${docdir}'
891 libdir='${exec_prefix}/lib'
892 localedir='${datarootdir}/locale'
893 mandir='${datarootdir}/man'
894
895 ac_prev=
896 ac_dashdash=
897 for ac_option
898 do
899   # If the previous option needs an argument, assign it.
900   if test -n "$ac_prev"; then
901     eval $ac_prev=\$ac_option
902     ac_prev=
903     continue
904   fi
905
906   case $ac_option in
907   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
908   *)    ac_optarg=yes ;;
909   esac
910
911   # Accept the important Cygnus configure options, so we can diagnose typos.
912
913   case $ac_dashdash$ac_option in
914   --)
915     ac_dashdash=yes ;;
916
917   -bindir | --bindir | --bindi | --bind | --bin | --bi)
918     ac_prev=bindir ;;
919   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
920     bindir=$ac_optarg ;;
921
922   -build | --build | --buil | --bui | --bu)
923     ac_prev=build_alias ;;
924   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
925     build_alias=$ac_optarg ;;
926
927   -cache-file | --cache-file | --cache-fil | --cache-fi \
928   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
929     ac_prev=cache_file ;;
930   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
931   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
932     cache_file=$ac_optarg ;;
933
934   --config-cache | -C)
935     cache_file=config.cache ;;
936
937   -datadir | --datadir | --datadi | --datad)
938     ac_prev=datadir ;;
939   -datadir=* | --datadir=* | --datadi=* | --datad=*)
940     datadir=$ac_optarg ;;
941
942   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
943   | --dataroo | --dataro | --datar)
944     ac_prev=datarootdir ;;
945   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
946   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
947     datarootdir=$ac_optarg ;;
948
949   -disable-* | --disable-*)
950     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
951     # Reject names that are not valid shell variable names.
952     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
953       as_fn_error "invalid feature name: $ac_useropt"
954     ac_useropt_orig=$ac_useropt
955     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
956     case $ac_user_opts in
957       *"
958 "enable_$ac_useropt"
959 "*) ;;
960       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
961          ac_unrecognized_sep=', ';;
962     esac
963     eval enable_$ac_useropt=no ;;
964
965   -docdir | --docdir | --docdi | --doc | --do)
966     ac_prev=docdir ;;
967   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
968     docdir=$ac_optarg ;;
969
970   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
971     ac_prev=dvidir ;;
972   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
973     dvidir=$ac_optarg ;;
974
975   -enable-* | --enable-*)
976     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
977     # Reject names that are not valid shell variable names.
978     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
979       as_fn_error "invalid feature name: $ac_useropt"
980     ac_useropt_orig=$ac_useropt
981     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
982     case $ac_user_opts in
983       *"
984 "enable_$ac_useropt"
985 "*) ;;
986       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
987          ac_unrecognized_sep=', ';;
988     esac
989     eval enable_$ac_useropt=\$ac_optarg ;;
990
991   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
992   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
993   | --exec | --exe | --ex)
994     ac_prev=exec_prefix ;;
995   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
996   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
997   | --exec=* | --exe=* | --ex=*)
998     exec_prefix=$ac_optarg ;;
999
1000   -gas | --gas | --ga | --g)
1001     # Obsolete; use --with-gas.
1002     with_gas=yes ;;
1003
1004   -help | --help | --hel | --he | -h)
1005     ac_init_help=long ;;
1006   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1007     ac_init_help=recursive ;;
1008   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1009     ac_init_help=short ;;
1010
1011   -host | --host | --hos | --ho)
1012     ac_prev=host_alias ;;
1013   -host=* | --host=* | --hos=* | --ho=*)
1014     host_alias=$ac_optarg ;;
1015
1016   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1017     ac_prev=htmldir ;;
1018   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1019   | --ht=*)
1020     htmldir=$ac_optarg ;;
1021
1022   -includedir | --includedir | --includedi | --included | --include \
1023   | --includ | --inclu | --incl | --inc)
1024     ac_prev=includedir ;;
1025   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1026   | --includ=* | --inclu=* | --incl=* | --inc=*)
1027     includedir=$ac_optarg ;;
1028
1029   -infodir | --infodir | --infodi | --infod | --info | --inf)
1030     ac_prev=infodir ;;
1031   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1032     infodir=$ac_optarg ;;
1033
1034   -libdir | --libdir | --libdi | --libd)
1035     ac_prev=libdir ;;
1036   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1037     libdir=$ac_optarg ;;
1038
1039   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1040   | --libexe | --libex | --libe)
1041     ac_prev=libexecdir ;;
1042   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1043   | --libexe=* | --libex=* | --libe=*)
1044     libexecdir=$ac_optarg ;;
1045
1046   -localedir | --localedir | --localedi | --localed | --locale)
1047     ac_prev=localedir ;;
1048   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1049     localedir=$ac_optarg ;;
1050
1051   -localstatedir | --localstatedir | --localstatedi | --localstated \
1052   | --localstate | --localstat | --localsta | --localst | --locals)
1053     ac_prev=localstatedir ;;
1054   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1055   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1056     localstatedir=$ac_optarg ;;
1057
1058   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1059     ac_prev=mandir ;;
1060   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1061     mandir=$ac_optarg ;;
1062
1063   -nfp | --nfp | --nf)
1064     # Obsolete; use --without-fp.
1065     with_fp=no ;;
1066
1067   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1068   | --no-cr | --no-c | -n)
1069     no_create=yes ;;
1070
1071   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1072   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1073     no_recursion=yes ;;
1074
1075   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1076   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1077   | --oldin | --oldi | --old | --ol | --o)
1078     ac_prev=oldincludedir ;;
1079   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1080   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1081   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1082     oldincludedir=$ac_optarg ;;
1083
1084   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1085     ac_prev=prefix ;;
1086   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1087     prefix=$ac_optarg ;;
1088
1089   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1090   | --program-pre | --program-pr | --program-p)
1091     ac_prev=program_prefix ;;
1092   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1093   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1094     program_prefix=$ac_optarg ;;
1095
1096   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1097   | --program-suf | --program-su | --program-s)
1098     ac_prev=program_suffix ;;
1099   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1100   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1101     program_suffix=$ac_optarg ;;
1102
1103   -program-transform-name | --program-transform-name \
1104   | --program-transform-nam | --program-transform-na \
1105   | --program-transform-n | --program-transform- \
1106   | --program-transform | --program-transfor \
1107   | --program-transfo | --program-transf \
1108   | --program-trans | --program-tran \
1109   | --progr-tra | --program-tr | --program-t)
1110     ac_prev=program_transform_name ;;
1111   -program-transform-name=* | --program-transform-name=* \
1112   | --program-transform-nam=* | --program-transform-na=* \
1113   | --program-transform-n=* | --program-transform-=* \
1114   | --program-transform=* | --program-transfor=* \
1115   | --program-transfo=* | --program-transf=* \
1116   | --program-trans=* | --program-tran=* \
1117   | --progr-tra=* | --program-tr=* | --program-t=*)
1118     program_transform_name=$ac_optarg ;;
1119
1120   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1121     ac_prev=pdfdir ;;
1122   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1123     pdfdir=$ac_optarg ;;
1124
1125   -psdir | --psdir | --psdi | --psd | --ps)
1126     ac_prev=psdir ;;
1127   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1128     psdir=$ac_optarg ;;
1129
1130   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1131   | -silent | --silent | --silen | --sile | --sil)
1132     silent=yes ;;
1133
1134   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1135     ac_prev=sbindir ;;
1136   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1137   | --sbi=* | --sb=*)
1138     sbindir=$ac_optarg ;;
1139
1140   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1141   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1142   | --sharedst | --shareds | --shared | --share | --shar \
1143   | --sha | --sh)
1144     ac_prev=sharedstatedir ;;
1145   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1146   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1147   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1148   | --sha=* | --sh=*)
1149     sharedstatedir=$ac_optarg ;;
1150
1151   -site | --site | --sit)
1152     ac_prev=site ;;
1153   -site=* | --site=* | --sit=*)
1154     site=$ac_optarg ;;
1155
1156   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1157     ac_prev=srcdir ;;
1158   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1159     srcdir=$ac_optarg ;;
1160
1161   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1162   | --syscon | --sysco | --sysc | --sys | --sy)
1163     ac_prev=sysconfdir ;;
1164   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1165   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1166     sysconfdir=$ac_optarg ;;
1167
1168   -target | --target | --targe | --targ | --tar | --ta | --t)
1169     ac_prev=target_alias ;;
1170   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1171     target_alias=$ac_optarg ;;
1172
1173   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1174     verbose=yes ;;
1175
1176   -version | --version | --versio | --versi | --vers | -V)
1177     ac_init_version=: ;;
1178
1179   -with-* | --with-*)
1180     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1181     # Reject names that are not valid shell variable names.
1182     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1183       as_fn_error "invalid package name: $ac_useropt"
1184     ac_useropt_orig=$ac_useropt
1185     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1186     case $ac_user_opts in
1187       *"
1188 "with_$ac_useropt"
1189 "*) ;;
1190       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1191          ac_unrecognized_sep=', ';;
1192     esac
1193     eval with_$ac_useropt=\$ac_optarg ;;
1194
1195   -without-* | --without-*)
1196     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1197     # Reject names that are not valid shell variable names.
1198     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1199       as_fn_error "invalid package name: $ac_useropt"
1200     ac_useropt_orig=$ac_useropt
1201     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1202     case $ac_user_opts in
1203       *"
1204 "with_$ac_useropt"
1205 "*) ;;
1206       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1207          ac_unrecognized_sep=', ';;
1208     esac
1209     eval with_$ac_useropt=no ;;
1210
1211   --x)
1212     # Obsolete; use --with-x.
1213     with_x=yes ;;
1214
1215   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1216   | --x-incl | --x-inc | --x-in | --x-i)
1217     ac_prev=x_includes ;;
1218   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1219   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1220     x_includes=$ac_optarg ;;
1221
1222   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1223   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1224     ac_prev=x_libraries ;;
1225   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1226   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1227     x_libraries=$ac_optarg ;;
1228
1229   -*) as_fn_error "unrecognized option: \`$ac_option'
1230 Try \`$0 --help' for more information."
1231     ;;
1232
1233   *=*)
1234     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1235     # Reject names that are not valid shell variable names.
1236     case $ac_envvar in #(
1237       '' | [0-9]* | *[!_$as_cr_alnum]* )
1238       as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1239     esac
1240     eval $ac_envvar=\$ac_optarg
1241     export $ac_envvar ;;
1242
1243   *)
1244     # FIXME: should be removed in autoconf 3.0.
1245     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1246     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1247       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1248     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1249     ;;
1250
1251   esac
1252 done
1253
1254 if test -n "$ac_prev"; then
1255   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1256   as_fn_error "missing argument to $ac_option"
1257 fi
1258
1259 if test -n "$ac_unrecognized_opts"; then
1260   case $enable_option_checking in
1261     no) ;;
1262     fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1263     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1264   esac
1265 fi
1266
1267 # Check all directory arguments for consistency.
1268 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1269                 datadir sysconfdir sharedstatedir localstatedir includedir \
1270                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1271                 libdir localedir mandir
1272 do
1273   eval ac_val=\$$ac_var
1274   # Remove trailing slashes.
1275   case $ac_val in
1276     */ )
1277       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1278       eval $ac_var=\$ac_val;;
1279   esac
1280   # Be sure to have absolute directory names.
1281   case $ac_val in
1282     [\\/$]* | ?:[\\/]* )  continue;;
1283     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1284   esac
1285   as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1286 done
1287
1288 # There might be people who depend on the old broken behavior: `$host'
1289 # used to hold the argument of --host etc.
1290 # FIXME: To remove some day.
1291 build=$build_alias
1292 host=$host_alias
1293 target=$target_alias
1294
1295 # FIXME: To remove some day.
1296 if test "x$host_alias" != x; then
1297   if test "x$build_alias" = x; then
1298     cross_compiling=maybe
1299     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1300     If a cross compiler is detected then cross compile mode will be used." >&2
1301   elif test "x$build_alias" != "x$host_alias"; then
1302     cross_compiling=yes
1303   fi
1304 fi
1305
1306 ac_tool_prefix=
1307 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1308
1309 test "$silent" = yes && exec 6>/dev/null
1310
1311
1312 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1313 ac_ls_di=`ls -di .` &&
1314 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1315   as_fn_error "working directory cannot be determined"
1316 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1317   as_fn_error "pwd does not report name of working directory"
1318
1319
1320 # Find the source files, if location was not specified.
1321 if test -z "$srcdir"; then
1322   ac_srcdir_defaulted=yes
1323   # Try the directory containing this script, then the parent directory.
1324   ac_confdir=`$as_dirname -- "$as_myself" ||
1325 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1326          X"$as_myself" : 'X\(//\)[^/]' \| \
1327          X"$as_myself" : 'X\(//\)$' \| \
1328          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1329 $as_echo X"$as_myself" |
1330     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1331             s//\1/
1332             q
1333           }
1334           /^X\(\/\/\)[^/].*/{
1335             s//\1/
1336             q
1337           }
1338           /^X\(\/\/\)$/{
1339             s//\1/
1340             q
1341           }
1342           /^X\(\/\).*/{
1343             s//\1/
1344             q
1345           }
1346           s/.*/./; q'`
1347   srcdir=$ac_confdir
1348   if test ! -r "$srcdir/$ac_unique_file"; then
1349     srcdir=..
1350   fi
1351 else
1352   ac_srcdir_defaulted=no
1353 fi
1354 if test ! -r "$srcdir/$ac_unique_file"; then
1355   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1356   as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1357 fi
1358 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1359 ac_abs_confdir=`(
1360         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1361         pwd)`
1362 # When building in place, set srcdir=.
1363 if test "$ac_abs_confdir" = "$ac_pwd"; then
1364   srcdir=.
1365 fi
1366 # Remove unnecessary trailing slashes from srcdir.
1367 # Double slashes in file names in object file debugging info
1368 # mess up M-x gdb in Emacs.
1369 case $srcdir in
1370 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1371 esac
1372 for ac_var in $ac_precious_vars; do
1373   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1374   eval ac_env_${ac_var}_value=\$${ac_var}
1375   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1376   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1377 done
1378
1379 #
1380 # Report the --help message.
1381 #
1382 if test "$ac_init_help" = "long"; then
1383   # Omit some internal or obsolete options to make the list less imposing.
1384   # This message is too long to be a string in the A/UX 3.1 sh.
1385   cat <<_ACEOF
1386 \`configure' configures this package to adapt to many kinds of systems.
1387
1388 Usage: $0 [OPTION]... [VAR=VALUE]...
1389
1390 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1391 VAR=VALUE.  See below for descriptions of some of the useful variables.
1392
1393 Defaults for the options are specified in brackets.
1394
1395 Configuration:
1396   -h, --help              display this help and exit
1397       --help=short        display options specific to this package
1398       --help=recursive    display the short help of all the included packages
1399   -V, --version           display version information and exit
1400   -q, --quiet, --silent   do not print \`checking...' messages
1401       --cache-file=FILE   cache test results in FILE [disabled]
1402   -C, --config-cache      alias for \`--cache-file=config.cache'
1403   -n, --no-create         do not create output files
1404       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1405
1406 Installation directories:
1407   --prefix=PREFIX         install architecture-independent files in PREFIX
1408                           [$ac_default_prefix]
1409   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1410                           [PREFIX]
1411
1412 By default, \`make install' will install all the files in
1413 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1414 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1415 for instance \`--prefix=\$HOME'.
1416
1417 For better control, use the options below.
1418
1419 Fine tuning of the installation directories:
1420   --bindir=DIR            user executables [EPREFIX/bin]
1421   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1422   --libexecdir=DIR        program executables [EPREFIX/libexec]
1423   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1424   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1425   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1426   --libdir=DIR            object code libraries [EPREFIX/lib]
1427   --includedir=DIR        C header files [PREFIX/include]
1428   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1429   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1430   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1431   --infodir=DIR           info documentation [DATAROOTDIR/info]
1432   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1433   --mandir=DIR            man documentation [DATAROOTDIR/man]
1434   --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
1435   --htmldir=DIR           html documentation [DOCDIR]
1436   --dvidir=DIR            dvi documentation [DOCDIR]
1437   --pdfdir=DIR            pdf documentation [DOCDIR]
1438   --psdir=DIR             ps documentation [DOCDIR]
1439 _ACEOF
1440
1441   cat <<\_ACEOF
1442
1443 Program names:
1444   --program-prefix=PREFIX            prepend PREFIX to installed program names
1445   --program-suffix=SUFFIX            append SUFFIX to installed program names
1446   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1447
1448 X features:
1449   --x-includes=DIR    X include files are in DIR
1450   --x-libraries=DIR   X library files are in DIR
1451
1452 System types:
1453   --build=BUILD     configure for building on BUILD [guessed]
1454   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1455   --target=TARGET   configure for building compilers for TARGET [HOST]
1456 _ACEOF
1457 fi
1458
1459 if test -n "$ac_init_help"; then
1460
1461   cat <<\_ACEOF
1462
1463 Optional Features:
1464   --disable-option-checking  ignore unrecognized --enable/--with options
1465   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1466   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1467   --enable-maintainer-mode  enable make rules and dependencies not useful
1468                           (and sometimes confusing) to the casual installer
1469   --enable-plugins        Enable support for plugins (defaults no)
1470   --disable-largefile     omit support for large files
1471   --enable-targets=TARGETS
1472                           alternative target configurations
1473   --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
1474   --disable-gdbcli        disable command-line interface (CLI)
1475   --disable-gdbmi         disable machine-interface (MI)
1476   --enable-tui            enable full-screen terminal user interface (TUI)
1477   --enable-gdbtk          enable gdbtk graphical user interface (GUI)
1478   --enable-profiling      enable profiling of GDB
1479   --disable-rpath         do not hardcode runtime library paths
1480   --enable-libmcheck      Try building GDB with -lmcheck if available
1481   --enable-werror         treat compile warnings as errors
1482   --enable-build-warnings enable build-time compiler warnings if gcc is used
1483   --enable-gdb-build-warnings
1484                           enable GDB specific build-time compiler warnings if
1485                           gcc is used
1486   --enable-sim            link gdb with simulator
1487   --enable-multi-ice      build the multi-ice-gdb-server
1488   --enable-gdbserver      automatically build gdbserver (yes/no/auto, default
1489                           is auto)
1490
1491 Optional Packages:
1492   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1493   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1494   --with-separate-debug-dir=PATH
1495                           look for global separate debug info in this path
1496                           [LIBDIR/debug]
1497   --with-gdb-datadir=PATH look for global separate data files in this path
1498                           [DATADIR/gdb]
1499   --with-relocated-sources=PATH
1500                           automatically relocate this path for source files
1501   --with-auto-load-dir=PATH
1502                           directories from which to load auto-loaded scripts
1503                           [$debugdir:$datadir/auto-load]
1504   --with-auto-load-safe-path=PATH
1505                           directories safe to hold auto-loaded files
1506                           [--with-auto-load-dir]
1507   --without-auto-load-safe-path
1508                           do not restrict auto-loaded files locations
1509   --with-libunwind-ia64   use libunwind frame unwinding for ia64 targets
1510   --with-curses           use the curses library instead of the termcap
1511                           library
1512   --with-pkgversion=PKG   Use PKG in the version string in place of "GDB"
1513   --with-bugurl=URL       Direct users to URL to report a bug
1514   --with-zlib             include zlib support (auto/yes/no) default=auto
1515   --with-libiconv-prefix=DIR
1516                           search for libiconv in DIR/include and DIR/lib
1517   --with-iconv-bin=PATH   specify where to find the iconv program
1518   --with-system-readline  use installed readline library
1519   --with-jit-reader-dir=PATH
1520                           directory to load the JIT readers from
1521   --with-expat            include expat support (auto/yes/no)
1522   --with-gnu-ld           assume the C compiler uses GNU ld default=no
1523   --with-libexpat-prefix[=DIR]  search for libexpat in DIR/include and DIR/lib
1524   --without-libexpat-prefix     don't search for libexpat in includedir and libdir
1525   --with-python[=PYTHON]  include python support
1526                           (auto/yes/no/<python-program>)
1527   --without-included-regex
1528                           don't use included regex; this is the default on
1529                           systems with version 2 of the GNU C library (use
1530                           with caution on other system)
1531   --with-sysroot[=DIR]    search for usr/lib et al within DIR
1532   --with-system-gdbinit=PATH
1533                           automatically load a system-wide gdbinit file
1534   --with-lzma             support lzma compression (auto/yes/no)
1535   --with-liblzma-prefix[=DIR]  search for liblzma in DIR/include and DIR/lib
1536   --without-liblzma-prefix     don't search for liblzma in includedir and libdir
1537   --with-tcl              directory containing tcl configuration (tclConfig.sh)
1538   --with-tk               directory containing tk configuration (tkConfig.sh)
1539   --with-x                use the X Window System
1540   --with-babeltrace       include babeltrace support (auto/yes/no)
1541   --with-libbabeltrace-prefix[=DIR]  search for libbabeltrace in DIR/include and DIR/lib
1542   --without-libbabeltrace-prefix     don't search for libbabeltrace in includedir and libdir
1543
1544 Some influential environment variables:
1545   CC          C compiler command
1546   CFLAGS      C compiler flags
1547   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1548               nonstandard directory <lib dir>
1549   LIBS        libraries to pass to the linker, e.g. -l<library>
1550   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1551               you have headers in a nonstandard directory <include dir>
1552   CPP         C preprocessor
1553   MAKEINFO    Parent configure detects if it is of sufficient version.
1554   MAKEINFOFLAGS
1555               Parameters for MAKEINFO.
1556   YACC        The `Yet Another C Compiler' implementation to use. Defaults to
1557               the first program found out of: `bison -y', `byacc', `yacc'.
1558   YFLAGS      The list of arguments that will be passed by default to $YACC.
1559               This script will default YFLAGS to the empty string to avoid a
1560               default value of `-d' given by some make applications.
1561   XMKMF       Path to xmkmf, Makefile generator for X Window System
1562
1563 Use these variables to override the choices made by `configure' or to help
1564 it to find libraries and programs with nonstandard names/locations.
1565
1566 Report bugs to the package provider.
1567 _ACEOF
1568 ac_status=$?
1569 fi
1570
1571 if test "$ac_init_help" = "recursive"; then
1572   # If there are subdirs, report their specific --help.
1573   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1574     test -d "$ac_dir" ||
1575       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1576       continue
1577     ac_builddir=.
1578
1579 case "$ac_dir" in
1580 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1581 *)
1582   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1583   # A ".." for each directory in $ac_dir_suffix.
1584   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1585   case $ac_top_builddir_sub in
1586   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1587   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1588   esac ;;
1589 esac
1590 ac_abs_top_builddir=$ac_pwd
1591 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1592 # for backward compatibility:
1593 ac_top_builddir=$ac_top_build_prefix
1594
1595 case $srcdir in
1596   .)  # We are building in place.
1597     ac_srcdir=.
1598     ac_top_srcdir=$ac_top_builddir_sub
1599     ac_abs_top_srcdir=$ac_pwd ;;
1600   [\\/]* | ?:[\\/]* )  # Absolute name.
1601     ac_srcdir=$srcdir$ac_dir_suffix;
1602     ac_top_srcdir=$srcdir
1603     ac_abs_top_srcdir=$srcdir ;;
1604   *) # Relative name.
1605     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1606     ac_top_srcdir=$ac_top_build_prefix$srcdir
1607     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1608 esac
1609 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1610
1611     cd "$ac_dir" || { ac_status=$?; continue; }
1612     # Check for guested configure.
1613     if test -f "$ac_srcdir/configure.gnu"; then
1614       echo &&
1615       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1616     elif test -f "$ac_srcdir/configure"; then
1617       echo &&
1618       $SHELL "$ac_srcdir/configure" --help=recursive
1619     else
1620       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1621     fi || ac_status=$?
1622     cd "$ac_pwd" || { ac_status=$?; break; }
1623   done
1624 fi
1625
1626 test -n "$ac_init_help" && exit $ac_status
1627 if $ac_init_version; then
1628   cat <<\_ACEOF
1629 configure
1630 generated by GNU Autoconf 2.64
1631
1632 Copyright (C) 2009 Free Software Foundation, Inc.
1633 This configure script is free software; the Free Software Foundation
1634 gives unlimited permission to copy, distribute and modify it.
1635 _ACEOF
1636   exit
1637 fi
1638
1639 ## ------------------------ ##
1640 ## Autoconf initialization. ##
1641 ## ------------------------ ##
1642
1643 # ac_fn_c_try_compile LINENO
1644 # --------------------------
1645 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1646 ac_fn_c_try_compile ()
1647 {
1648   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1649   rm -f conftest.$ac_objext
1650   if { { ac_try="$ac_compile"
1651 case "(($ac_try" in
1652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1653   *) ac_try_echo=$ac_try;;
1654 esac
1655 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1656 $as_echo "$ac_try_echo"; } >&5
1657   (eval "$ac_compile") 2>conftest.err
1658   ac_status=$?
1659   if test -s conftest.err; then
1660     grep -v '^ *+' conftest.err >conftest.er1
1661     cat conftest.er1 >&5
1662     mv -f conftest.er1 conftest.err
1663   fi
1664   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1665   test $ac_status = 0; } && {
1666          test -z "$ac_c_werror_flag" ||
1667          test ! -s conftest.err
1668        } && test -s conftest.$ac_objext; then :
1669   ac_retval=0
1670 else
1671   $as_echo "$as_me: failed program was:" >&5
1672 sed 's/^/| /' conftest.$ac_ext >&5
1673
1674         ac_retval=1
1675 fi
1676   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1677   return $ac_retval
1678
1679 } # ac_fn_c_try_compile
1680
1681 # ac_fn_c_try_cpp LINENO
1682 # ----------------------
1683 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1684 ac_fn_c_try_cpp ()
1685 {
1686   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1687   if { { ac_try="$ac_cpp conftest.$ac_ext"
1688 case "(($ac_try" in
1689   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1690   *) ac_try_echo=$ac_try;;
1691 esac
1692 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1693 $as_echo "$ac_try_echo"; } >&5
1694   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1695   ac_status=$?
1696   if test -s conftest.err; then
1697     grep -v '^ *+' conftest.err >conftest.er1
1698     cat conftest.er1 >&5
1699     mv -f conftest.er1 conftest.err
1700   fi
1701   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1702   test $ac_status = 0; } >/dev/null && {
1703          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1704          test ! -s conftest.err
1705        }; then :
1706   ac_retval=0
1707 else
1708   $as_echo "$as_me: failed program was:" >&5
1709 sed 's/^/| /' conftest.$ac_ext >&5
1710
1711     ac_retval=1
1712 fi
1713   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1714   return $ac_retval
1715
1716 } # ac_fn_c_try_cpp
1717
1718 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1719 # -------------------------------------------------------
1720 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1721 # the include files in INCLUDES and setting the cache variable VAR
1722 # accordingly.
1723 ac_fn_c_check_header_mongrel ()
1724 {
1725   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1726   if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1727   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1728 $as_echo_n "checking for $2... " >&6; }
1729 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1730   $as_echo_n "(cached) " >&6
1731 fi
1732 eval ac_res=\$$3
1733                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1734 $as_echo "$ac_res" >&6; }
1735 else
1736   # Is the header compilable?
1737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1738 $as_echo_n "checking $2 usability... " >&6; }
1739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1740 /* end confdefs.h.  */
1741 $4
1742 #include <$2>
1743 _ACEOF
1744 if ac_fn_c_try_compile "$LINENO"; then :
1745   ac_header_compiler=yes
1746 else
1747   ac_header_compiler=no
1748 fi
1749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1751 $as_echo "$ac_header_compiler" >&6; }
1752
1753 # Is the header present?
1754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1755 $as_echo_n "checking $2 presence... " >&6; }
1756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1757 /* end confdefs.h.  */
1758 #include <$2>
1759 _ACEOF
1760 if ac_fn_c_try_cpp "$LINENO"; then :
1761   ac_header_preproc=yes
1762 else
1763   ac_header_preproc=no
1764 fi
1765 rm -f conftest.err conftest.$ac_ext
1766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1767 $as_echo "$ac_header_preproc" >&6; }
1768
1769 # So?  What about this header?
1770 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1771   yes:no: )
1772     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1773 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1774     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1775 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1776     ;;
1777   no:yes:* )
1778     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1779 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1780     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1781 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1782     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1783 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1784     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1785 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1786     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1787 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1788     ;;
1789 esac
1790   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1791 $as_echo_n "checking for $2... " >&6; }
1792 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1793   $as_echo_n "(cached) " >&6
1794 else
1795   eval "$3=\$ac_header_compiler"
1796 fi
1797 eval ac_res=\$$3
1798                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1799 $as_echo "$ac_res" >&6; }
1800 fi
1801   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1802
1803 } # ac_fn_c_check_header_mongrel
1804
1805 # ac_fn_c_try_run LINENO
1806 # ----------------------
1807 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1808 # that executables *can* be run.
1809 ac_fn_c_try_run ()
1810 {
1811   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1812   if { { ac_try="$ac_link"
1813 case "(($ac_try" in
1814   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1815   *) ac_try_echo=$ac_try;;
1816 esac
1817 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1818 $as_echo "$ac_try_echo"; } >&5
1819   (eval "$ac_link") 2>&5
1820   ac_status=$?
1821   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1822   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1823   { { case "(($ac_try" in
1824   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1825   *) ac_try_echo=$ac_try;;
1826 esac
1827 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1828 $as_echo "$ac_try_echo"; } >&5
1829   (eval "$ac_try") 2>&5
1830   ac_status=$?
1831   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1832   test $ac_status = 0; }; }; then :
1833   ac_retval=0
1834 else
1835   $as_echo "$as_me: program exited with status $ac_status" >&5
1836        $as_echo "$as_me: failed program was:" >&5
1837 sed 's/^/| /' conftest.$ac_ext >&5
1838
1839        ac_retval=$ac_status
1840 fi
1841   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1842   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1843   return $ac_retval
1844
1845 } # ac_fn_c_try_run
1846
1847 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1848 # -------------------------------------------------------
1849 # Tests whether HEADER exists and can be compiled using the include files in
1850 # INCLUDES, setting the cache variable VAR accordingly.
1851 ac_fn_c_check_header_compile ()
1852 {
1853   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1854   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1855 $as_echo_n "checking for $2... " >&6; }
1856 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1857   $as_echo_n "(cached) " >&6
1858 else
1859   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1860 /* end confdefs.h.  */
1861 $4
1862 #include <$2>
1863 _ACEOF
1864 if ac_fn_c_try_compile "$LINENO"; then :
1865   eval "$3=yes"
1866 else
1867   eval "$3=no"
1868 fi
1869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1870 fi
1871 eval ac_res=\$$3
1872                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1873 $as_echo "$ac_res" >&6; }
1874   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1875
1876 } # ac_fn_c_check_header_compile
1877
1878 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1879 # --------------------------------------------
1880 # Tries to find the compile-time value of EXPR in a program that includes
1881 # INCLUDES, setting VAR accordingly. Returns whether the value could be
1882 # computed
1883 ac_fn_c_compute_int ()
1884 {
1885   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1886   if test "$cross_compiling" = yes; then
1887     # Depending upon the size, compute the lo and hi bounds.
1888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1889 /* end confdefs.h.  */
1890 $4
1891 int
1892 main ()
1893 {
1894 static int test_array [1 - 2 * !(($2) >= 0)];
1895 test_array [0] = 0
1896
1897   ;
1898   return 0;
1899 }
1900 _ACEOF
1901 if ac_fn_c_try_compile "$LINENO"; then :
1902   ac_lo=0 ac_mid=0
1903   while :; do
1904     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1905 /* end confdefs.h.  */
1906 $4
1907 int
1908 main ()
1909 {
1910 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1911 test_array [0] = 0
1912
1913   ;
1914   return 0;
1915 }
1916 _ACEOF
1917 if ac_fn_c_try_compile "$LINENO"; then :
1918   ac_hi=$ac_mid; break
1919 else
1920   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1921                         if test $ac_lo -le $ac_mid; then
1922                           ac_lo= ac_hi=
1923                           break
1924                         fi
1925                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1926 fi
1927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1928   done
1929 else
1930   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1931 /* end confdefs.h.  */
1932 $4
1933 int
1934 main ()
1935 {
1936 static int test_array [1 - 2 * !(($2) < 0)];
1937 test_array [0] = 0
1938
1939   ;
1940   return 0;
1941 }
1942 _ACEOF
1943 if ac_fn_c_try_compile "$LINENO"; then :
1944   ac_hi=-1 ac_mid=-1
1945   while :; do
1946     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1947 /* end confdefs.h.  */
1948 $4
1949 int
1950 main ()
1951 {
1952 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
1953 test_array [0] = 0
1954
1955   ;
1956   return 0;
1957 }
1958 _ACEOF
1959 if ac_fn_c_try_compile "$LINENO"; then :
1960   ac_lo=$ac_mid; break
1961 else
1962   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1963                         if test $ac_mid -le $ac_hi; then
1964                           ac_lo= ac_hi=
1965                           break
1966                         fi
1967                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1968 fi
1969 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1970   done
1971 else
1972   ac_lo= ac_hi=
1973 fi
1974 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1975 fi
1976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1977 # Binary search between lo and hi bounds.
1978 while test "x$ac_lo" != "x$ac_hi"; do
1979   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1980   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1981 /* end confdefs.h.  */
1982 $4
1983 int
1984 main ()
1985 {
1986 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1987 test_array [0] = 0
1988
1989   ;
1990   return 0;
1991 }
1992 _ACEOF
1993 if ac_fn_c_try_compile "$LINENO"; then :
1994   ac_hi=$ac_mid
1995 else
1996   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1997 fi
1998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1999 done
2000 case $ac_lo in #((
2001 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2002 '') ac_retval=1 ;;
2003 esac
2004   else
2005     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2006 /* end confdefs.h.  */
2007 $4
2008 static long int longval () { return $2; }
2009 static unsigned long int ulongval () { return $2; }
2010 #include <stdio.h>
2011 #include <stdlib.h>
2012 int
2013 main ()
2014 {
2015
2016   FILE *f = fopen ("conftest.val", "w");
2017   if (! f)
2018     return 1;
2019   if (($2) < 0)
2020     {
2021       long int i = longval ();
2022       if (i != ($2))
2023         return 1;
2024       fprintf (f, "%ld", i);
2025     }
2026   else
2027     {
2028       unsigned long int i = ulongval ();
2029       if (i != ($2))
2030         return 1;
2031       fprintf (f, "%lu", i);
2032     }
2033   /* Do not output a trailing newline, as this causes \r\n confusion
2034      on some platforms.  */
2035   return ferror (f) || fclose (f) != 0;
2036
2037   ;
2038   return 0;
2039 }
2040 _ACEOF
2041 if ac_fn_c_try_run "$LINENO"; then :
2042   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2043 else
2044   ac_retval=1
2045 fi
2046 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2047   conftest.$ac_objext conftest.beam conftest.$ac_ext
2048 rm -f conftest.val
2049
2050   fi
2051   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2052   return $ac_retval
2053
2054 } # ac_fn_c_compute_int
2055
2056 # ac_fn_c_try_link LINENO
2057 # -----------------------
2058 # Try to link conftest.$ac_ext, and return whether this succeeded.
2059 ac_fn_c_try_link ()
2060 {
2061   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2062   rm -f conftest.$ac_objext conftest$ac_exeext
2063   if { { ac_try="$ac_link"
2064 case "(($ac_try" in
2065   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2066   *) ac_try_echo=$ac_try;;
2067 esac
2068 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2069 $as_echo "$ac_try_echo"; } >&5
2070   (eval "$ac_link") 2>conftest.err
2071   ac_status=$?
2072   if test -s conftest.err; then
2073     grep -v '^ *+' conftest.err >conftest.er1
2074     cat conftest.er1 >&5
2075     mv -f conftest.er1 conftest.err
2076   fi
2077   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2078   test $ac_status = 0; } && {
2079          test -z "$ac_c_werror_flag" ||
2080          test ! -s conftest.err
2081        } && test -s conftest$ac_exeext && {
2082          test "$cross_compiling" = yes ||
2083          $as_test_x conftest$ac_exeext
2084        }; then :
2085   ac_retval=0
2086 else
2087   $as_echo "$as_me: failed program was:" >&5
2088 sed 's/^/| /' conftest.$ac_ext >&5
2089
2090         ac_retval=1
2091 fi
2092   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2093   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2094   # interfere with the next link command; also delete a directory that is
2095   # left behind by Apple's compiler.  We do this before executing the actions.
2096   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2097   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2098   return $ac_retval
2099
2100 } # ac_fn_c_try_link
2101
2102 # ac_fn_c_check_func LINENO FUNC VAR
2103 # ----------------------------------
2104 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2105 ac_fn_c_check_func ()
2106 {
2107   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2108   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2109 $as_echo_n "checking for $2... " >&6; }
2110 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2111   $as_echo_n "(cached) " >&6
2112 else
2113   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2114 /* end confdefs.h.  */
2115 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2116    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2117 #define $2 innocuous_$2
2118
2119 /* System header to define __stub macros and hopefully few prototypes,
2120     which can conflict with char $2 (); below.
2121     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2122     <limits.h> exists even on freestanding compilers.  */
2123
2124 #ifdef __STDC__
2125 # include <limits.h>
2126 #else
2127 # include <assert.h>
2128 #endif
2129
2130 #undef $2
2131
2132 /* Override any GCC internal prototype to avoid an error.
2133    Use char because int might match the return type of a GCC
2134    builtin and then its argument prototype would still apply.  */
2135 #ifdef __cplusplus
2136 extern "C"
2137 #endif
2138 char $2 ();
2139 /* The GNU C library defines this for functions which it implements
2140     to always fail with ENOSYS.  Some functions are actually named
2141     something starting with __ and the normal name is an alias.  */
2142 #if defined __stub_$2 || defined __stub___$2
2143 choke me
2144 #endif
2145
2146 int
2147 main ()
2148 {
2149 return $2 ();
2150   ;
2151   return 0;
2152 }
2153 _ACEOF
2154 if ac_fn_c_try_link "$LINENO"; then :
2155   eval "$3=yes"
2156 else
2157   eval "$3=no"
2158 fi
2159 rm -f core conftest.err conftest.$ac_objext \
2160     conftest$ac_exeext conftest.$ac_ext
2161 fi
2162 eval ac_res=\$$3
2163                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2164 $as_echo "$ac_res" >&6; }
2165   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2166
2167 } # ac_fn_c_check_func
2168
2169 # ac_fn_c_check_decl LINENO SYMBOL VAR
2170 # ------------------------------------
2171 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2172 ac_fn_c_check_decl ()
2173 {
2174   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2175   as_decl_name=`echo $2|sed 's/ *(.*//'`
2176   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2177   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2178 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2179 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2180   $as_echo_n "(cached) " >&6
2181 else
2182   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2183 /* end confdefs.h.  */
2184 $4
2185 int
2186 main ()
2187 {
2188 #ifndef $as_decl_name
2189 #ifdef __cplusplus
2190   (void) $as_decl_use;
2191 #else
2192   (void) $as_decl_name;
2193 #endif
2194 #endif
2195
2196   ;
2197   return 0;
2198 }
2199 _ACEOF
2200 if ac_fn_c_try_compile "$LINENO"; then :
2201   eval "$3=yes"
2202 else
2203   eval "$3=no"
2204 fi
2205 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2206 fi
2207 eval ac_res=\$$3
2208                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2209 $as_echo "$ac_res" >&6; }
2210   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2211
2212 } # ac_fn_c_check_decl
2213
2214 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2215 # ----------------------------------------------------
2216 # Tries to find if the field MEMBER exists in type AGGR, after including
2217 # INCLUDES, setting cache variable VAR accordingly.
2218 ac_fn_c_check_member ()
2219 {
2220   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2221   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2222 $as_echo_n "checking for $2.$3... " >&6; }
2223 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2224   $as_echo_n "(cached) " >&6
2225 else
2226   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2227 /* end confdefs.h.  */
2228 $5
2229 int
2230 main ()
2231 {
2232 static $2 ac_aggr;
2233 if (ac_aggr.$3)
2234 return 0;
2235   ;
2236   return 0;
2237 }
2238 _ACEOF
2239 if ac_fn_c_try_compile "$LINENO"; then :
2240   eval "$4=yes"
2241 else
2242   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2243 /* end confdefs.h.  */
2244 $5
2245 int
2246 main ()
2247 {
2248 static $2 ac_aggr;
2249 if (sizeof ac_aggr.$3)
2250 return 0;
2251   ;
2252   return 0;
2253 }
2254 _ACEOF
2255 if ac_fn_c_try_compile "$LINENO"; then :
2256   eval "$4=yes"
2257 else
2258   eval "$4=no"
2259 fi
2260 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2261 fi
2262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2263 fi
2264 eval ac_res=\$$4
2265                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2266 $as_echo "$ac_res" >&6; }
2267   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2268
2269 } # ac_fn_c_check_member
2270
2271 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2272 # -------------------------------------------
2273 # Tests whether TYPE exists after having included INCLUDES, setting cache
2274 # variable VAR accordingly.
2275 ac_fn_c_check_type ()
2276 {
2277   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2278   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2279 $as_echo_n "checking for $2... " >&6; }
2280 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2281   $as_echo_n "(cached) " >&6
2282 else
2283   eval "$3=no"
2284   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2285 /* end confdefs.h.  */
2286 $4
2287 int
2288 main ()
2289 {
2290 if (sizeof ($2))
2291          return 0;
2292   ;
2293   return 0;
2294 }
2295 _ACEOF
2296 if ac_fn_c_try_compile "$LINENO"; then :
2297   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2298 /* end confdefs.h.  */
2299 $4
2300 int
2301 main ()
2302 {
2303 if (sizeof (($2)))
2304             return 0;
2305   ;
2306   return 0;
2307 }
2308 _ACEOF
2309 if ac_fn_c_try_compile "$LINENO"; then :
2310
2311 else
2312   eval "$3=yes"
2313 fi
2314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2315 fi
2316 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2317 fi
2318 eval ac_res=\$$3
2319                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2320 $as_echo "$ac_res" >&6; }
2321   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2322
2323 } # ac_fn_c_check_type
2324 cat >config.log <<_ACEOF
2325 This file contains any messages produced by compilers while
2326 running configure, to aid debugging if configure makes a mistake.
2327
2328 It was created by $as_me, which was
2329 generated by GNU Autoconf 2.64.  Invocation command line was
2330
2331   $ $0 $@
2332
2333 _ACEOF
2334 exec 5>>config.log
2335 {
2336 cat <<_ASUNAME
2337 ## --------- ##
2338 ## Platform. ##
2339 ## --------- ##
2340
2341 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2342 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2343 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2344 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2345 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2346
2347 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2348 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2349
2350 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2351 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2352 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2353 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2354 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2355 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2356 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2357
2358 _ASUNAME
2359
2360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2361 for as_dir in $PATH
2362 do
2363   IFS=$as_save_IFS
2364   test -z "$as_dir" && as_dir=.
2365     $as_echo "PATH: $as_dir"
2366   done
2367 IFS=$as_save_IFS
2368
2369 } >&5
2370
2371 cat >&5 <<_ACEOF
2372
2373
2374 ## ----------- ##
2375 ## Core tests. ##
2376 ## ----------- ##
2377
2378 _ACEOF
2379
2380
2381 # Keep a trace of the command line.
2382 # Strip out --no-create and --no-recursion so they do not pile up.
2383 # Strip out --silent because we don't want to record it for future runs.
2384 # Also quote any args containing shell meta-characters.
2385 # Make two passes to allow for proper duplicate-argument suppression.
2386 ac_configure_args=
2387 ac_configure_args0=
2388 ac_configure_args1=
2389 ac_must_keep_next=false
2390 for ac_pass in 1 2
2391 do
2392   for ac_arg
2393   do
2394     case $ac_arg in
2395     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2396     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2397     | -silent | --silent | --silen | --sile | --sil)
2398       continue ;;
2399     *\'*)
2400       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2401     esac
2402     case $ac_pass in
2403     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2404     2)
2405       as_fn_append ac_configure_args1 " '$ac_arg'"
2406       if test $ac_must_keep_next = true; then
2407         ac_must_keep_next=false # Got value, back to normal.
2408       else
2409         case $ac_arg in
2410           *=* | --config-cache | -C | -disable-* | --disable-* \
2411           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2412           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2413           | -with-* | --with-* | -without-* | --without-* | --x)
2414             case "$ac_configure_args0 " in
2415               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2416             esac
2417             ;;
2418           -* ) ac_must_keep_next=true ;;
2419         esac
2420       fi
2421       as_fn_append ac_configure_args " '$ac_arg'"
2422       ;;
2423     esac
2424   done
2425 done
2426 { ac_configure_args0=; unset ac_configure_args0;}
2427 { ac_configure_args1=; unset ac_configure_args1;}
2428
2429 # When interrupted or exit'd, cleanup temporary files, and complete
2430 # config.log.  We remove comments because anyway the quotes in there
2431 # would cause problems or look ugly.
2432 # WARNING: Use '\'' to represent an apostrophe within the trap.
2433 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2434 trap 'exit_status=$?
2435   # Save into config.log some information that might help in debugging.
2436   {
2437     echo
2438
2439     cat <<\_ASBOX
2440 ## ---------------- ##
2441 ## Cache variables. ##
2442 ## ---------------- ##
2443 _ASBOX
2444     echo
2445     # The following way of writing the cache mishandles newlines in values,
2446 (
2447   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2448     eval ac_val=\$$ac_var
2449     case $ac_val in #(
2450     *${as_nl}*)
2451       case $ac_var in #(
2452       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2453 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2454       esac
2455       case $ac_var in #(
2456       _ | IFS | as_nl) ;; #(
2457       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2458       *) { eval $ac_var=; unset $ac_var;} ;;
2459       esac ;;
2460     esac
2461   done
2462   (set) 2>&1 |
2463     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2464     *${as_nl}ac_space=\ *)
2465       sed -n \
2466         "s/'\''/'\''\\\\'\'''\''/g;
2467           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2468       ;; #(
2469     *)
2470       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2471       ;;
2472     esac |
2473     sort
2474 )
2475     echo
2476
2477     cat <<\_ASBOX
2478 ## ----------------- ##
2479 ## Output variables. ##
2480 ## ----------------- ##
2481 _ASBOX
2482     echo
2483     for ac_var in $ac_subst_vars
2484     do
2485       eval ac_val=\$$ac_var
2486       case $ac_val in
2487       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2488       esac
2489       $as_echo "$ac_var='\''$ac_val'\''"
2490     done | sort
2491     echo
2492
2493     if test -n "$ac_subst_files"; then
2494       cat <<\_ASBOX
2495 ## ------------------- ##
2496 ## File substitutions. ##
2497 ## ------------------- ##
2498 _ASBOX
2499       echo
2500       for ac_var in $ac_subst_files
2501       do
2502         eval ac_val=\$$ac_var
2503         case $ac_val in
2504         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2505         esac
2506         $as_echo "$ac_var='\''$ac_val'\''"
2507       done | sort
2508       echo
2509     fi
2510
2511     if test -s confdefs.h; then
2512       cat <<\_ASBOX
2513 ## ----------- ##
2514 ## confdefs.h. ##
2515 ## ----------- ##
2516 _ASBOX
2517       echo
2518       cat confdefs.h
2519       echo
2520     fi
2521     test "$ac_signal" != 0 &&
2522       $as_echo "$as_me: caught signal $ac_signal"
2523     $as_echo "$as_me: exit $exit_status"
2524   } >&5
2525   rm -f core *.core core.conftest.* &&
2526     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2527     exit $exit_status
2528 ' 0
2529 for ac_signal in 1 2 13 15; do
2530   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2531 done
2532 ac_signal=0
2533
2534 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2535 rm -f -r conftest* confdefs.h
2536
2537 $as_echo "/* confdefs.h */" > confdefs.h
2538
2539 # Predefined preprocessor variables.
2540
2541 cat >>confdefs.h <<_ACEOF
2542 #define PACKAGE_NAME "$PACKAGE_NAME"
2543 _ACEOF
2544
2545 cat >>confdefs.h <<_ACEOF
2546 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2547 _ACEOF
2548
2549 cat >>confdefs.h <<_ACEOF
2550 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2551 _ACEOF
2552
2553 cat >>confdefs.h <<_ACEOF
2554 #define PACKAGE_STRING "$PACKAGE_STRING"
2555 _ACEOF
2556
2557 cat >>confdefs.h <<_ACEOF
2558 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2559 _ACEOF
2560
2561 cat >>confdefs.h <<_ACEOF
2562 #define PACKAGE_URL "$PACKAGE_URL"
2563 _ACEOF
2564
2565
2566 # Let the site file select an alternate cache file if it wants to.
2567 # Prefer an explicitly selected file to automatically selected ones.
2568 ac_site_file1=NONE
2569 ac_site_file2=NONE
2570 if test -n "$CONFIG_SITE"; then
2571   ac_site_file1=$CONFIG_SITE
2572 elif test "x$prefix" != xNONE; then
2573   ac_site_file1=$prefix/share/config.site
2574   ac_site_file2=$prefix/etc/config.site
2575 else
2576   ac_site_file1=$ac_default_prefix/share/config.site
2577   ac_site_file2=$ac_default_prefix/etc/config.site
2578 fi
2579 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2580 do
2581   test "x$ac_site_file" = xNONE && continue
2582   if test -r "$ac_site_file"; then
2583     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2584 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2585     sed 's/^/| /' "$ac_site_file" >&5
2586     . "$ac_site_file"
2587   fi
2588 done
2589
2590 if test -r "$cache_file"; then
2591   # Some versions of bash will fail to source /dev/null (special
2592   # files actually), so we avoid doing that.
2593   if test -f "$cache_file"; then
2594     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2595 $as_echo "$as_me: loading cache $cache_file" >&6;}
2596     case $cache_file in
2597       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2598       *)                      . "./$cache_file";;
2599     esac
2600   fi
2601 else
2602   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2603 $as_echo "$as_me: creating cache $cache_file" >&6;}
2604   >$cache_file
2605 fi
2606
2607 # Check that the precious variables saved in the cache have kept the same
2608 # value.
2609 ac_cache_corrupted=false
2610 for ac_var in $ac_precious_vars; do
2611   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2612   eval ac_new_set=\$ac_env_${ac_var}_set
2613   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2614   eval ac_new_val=\$ac_env_${ac_var}_value
2615   case $ac_old_set,$ac_new_set in
2616     set,)
2617       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2618 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2619       ac_cache_corrupted=: ;;
2620     ,set)
2621       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2622 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2623       ac_cache_corrupted=: ;;
2624     ,);;
2625     *)
2626       if test "x$ac_old_val" != "x$ac_new_val"; then
2627         # differences in whitespace do not lead to failure.
2628         ac_old_val_w=`echo x $ac_old_val`
2629         ac_new_val_w=`echo x $ac_new_val`
2630         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2631           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2632 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2633           ac_cache_corrupted=:
2634         else
2635           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2636 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2637           eval $ac_var=\$ac_old_val
2638         fi
2639         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2640 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2641         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2642 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2643       fi;;
2644   esac
2645   # Pass precious variables to config.status.
2646   if test "$ac_new_set" = set; then
2647     case $ac_new_val in
2648     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2649     *) ac_arg=$ac_var=$ac_new_val ;;
2650     esac
2651     case " $ac_configure_args " in
2652       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2653       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2654     esac
2655   fi
2656 done
2657 if $ac_cache_corrupted; then
2658   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2659 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2660   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2661 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2662   as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2663 fi
2664 ## -------------------- ##
2665 ## Main body of script. ##
2666 ## -------------------- ##
2667
2668 ac_ext=c
2669 ac_cpp='$CPP $CPPFLAGS'
2670 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2671 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2672 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2673
2674
2675
2676
2677
2678 ac_config_headers="$ac_config_headers config.h:config.in"
2679
2680
2681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2682 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2683     # Check whether --enable-maintainer-mode was given.
2684 if test "${enable_maintainer_mode+set}" = set; then :
2685   enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2686 else
2687   USE_MAINTAINER_MODE=no
2688 fi
2689
2690   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2691 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2692    if test $USE_MAINTAINER_MODE = yes; then
2693   MAINTAINER_MODE_TRUE=
2694   MAINTAINER_MODE_FALSE='#'
2695 else
2696   MAINTAINER_MODE_TRUE='#'
2697   MAINTAINER_MODE_FALSE=
2698 fi
2699
2700   MAINT=$MAINTAINER_MODE_TRUE
2701
2702
2703
2704 # Provide more thorough testing by -lmcheck.
2705 # Set it to 'true' for development snapshots, 'false' for releases or
2706 # pre-releases.
2707 development=true
2708
2709 ac_ext=c
2710 ac_cpp='$CPP $CPPFLAGS'
2711 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2712 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2713 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2714 if test -n "$ac_tool_prefix"; then
2715   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2716 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2718 $as_echo_n "checking for $ac_word... " >&6; }
2719 if test "${ac_cv_prog_CC+set}" = set; then :
2720   $as_echo_n "(cached) " >&6
2721 else
2722   if test -n "$CC"; then
2723   ac_cv_prog_CC="$CC" # Let the user override the test.
2724 else
2725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2726 for as_dir in $PATH
2727 do
2728   IFS=$as_save_IFS
2729   test -z "$as_dir" && as_dir=.
2730     for ac_exec_ext in '' $ac_executable_extensions; do
2731   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2732     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2733     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2734     break 2
2735   fi
2736 done
2737   done
2738 IFS=$as_save_IFS
2739
2740 fi
2741 fi
2742 CC=$ac_cv_prog_CC
2743 if test -n "$CC"; then
2744   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2745 $as_echo "$CC" >&6; }
2746 else
2747   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2748 $as_echo "no" >&6; }
2749 fi
2750
2751
2752 fi
2753 if test -z "$ac_cv_prog_CC"; then
2754   ac_ct_CC=$CC
2755   # Extract the first word of "gcc", so it can be a program name with args.
2756 set dummy gcc; ac_word=$2
2757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2758 $as_echo_n "checking for $ac_word... " >&6; }
2759 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2760   $as_echo_n "(cached) " >&6
2761 else
2762   if test -n "$ac_ct_CC"; then
2763   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2764 else
2765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2766 for as_dir in $PATH
2767 do
2768   IFS=$as_save_IFS
2769   test -z "$as_dir" && as_dir=.
2770     for ac_exec_ext in '' $ac_executable_extensions; do
2771   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2772     ac_cv_prog_ac_ct_CC="gcc"
2773     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2774     break 2
2775   fi
2776 done
2777   done
2778 IFS=$as_save_IFS
2779
2780 fi
2781 fi
2782 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2783 if test -n "$ac_ct_CC"; then
2784   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2785 $as_echo "$ac_ct_CC" >&6; }
2786 else
2787   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2788 $as_echo "no" >&6; }
2789 fi
2790
2791   if test "x$ac_ct_CC" = x; then
2792     CC=""
2793   else
2794     case $cross_compiling:$ac_tool_warned in
2795 yes:)
2796 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2797 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2798 ac_tool_warned=yes ;;
2799 esac
2800     CC=$ac_ct_CC
2801   fi
2802 else
2803   CC="$ac_cv_prog_CC"
2804 fi
2805
2806 if test -z "$CC"; then
2807           if test -n "$ac_tool_prefix"; then
2808     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2809 set dummy ${ac_tool_prefix}cc; ac_word=$2
2810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2811 $as_echo_n "checking for $ac_word... " >&6; }
2812 if test "${ac_cv_prog_CC+set}" = set; then :
2813   $as_echo_n "(cached) " >&6
2814 else
2815   if test -n "$CC"; then
2816   ac_cv_prog_CC="$CC" # Let the user override the test.
2817 else
2818 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2819 for as_dir in $PATH
2820 do
2821   IFS=$as_save_IFS
2822   test -z "$as_dir" && as_dir=.
2823     for ac_exec_ext in '' $ac_executable_extensions; do
2824   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2825     ac_cv_prog_CC="${ac_tool_prefix}cc"
2826     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2827     break 2
2828   fi
2829 done
2830   done
2831 IFS=$as_save_IFS
2832
2833 fi
2834 fi
2835 CC=$ac_cv_prog_CC
2836 if test -n "$CC"; then
2837   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2838 $as_echo "$CC" >&6; }
2839 else
2840   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2841 $as_echo "no" >&6; }
2842 fi
2843
2844
2845   fi
2846 fi
2847 if test -z "$CC"; then
2848   # Extract the first word of "cc", so it can be a program name with args.
2849 set dummy cc; ac_word=$2
2850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2851 $as_echo_n "checking for $ac_word... " >&6; }
2852 if test "${ac_cv_prog_CC+set}" = set; then :
2853   $as_echo_n "(cached) " >&6
2854 else
2855   if test -n "$CC"; then
2856   ac_cv_prog_CC="$CC" # Let the user override the test.
2857 else
2858   ac_prog_rejected=no
2859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2860 for as_dir in $PATH
2861 do
2862   IFS=$as_save_IFS
2863   test -z "$as_dir" && as_dir=.
2864     for ac_exec_ext in '' $ac_executable_extensions; do
2865   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2866     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2867        ac_prog_rejected=yes
2868        continue
2869      fi
2870     ac_cv_prog_CC="cc"
2871     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2872     break 2
2873   fi
2874 done
2875   done
2876 IFS=$as_save_IFS
2877
2878 if test $ac_prog_rejected = yes; then
2879   # We found a bogon in the path, so make sure we never use it.
2880   set dummy $ac_cv_prog_CC
2881   shift
2882   if test $# != 0; then
2883     # We chose a different compiler from the bogus one.
2884     # However, it has the same basename, so the bogon will be chosen
2885     # first if we set CC to just the basename; use the full file name.
2886     shift
2887     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2888   fi
2889 fi
2890 fi
2891 fi
2892 CC=$ac_cv_prog_CC
2893 if test -n "$CC"; then
2894   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2895 $as_echo "$CC" >&6; }
2896 else
2897   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2898 $as_echo "no" >&6; }
2899 fi
2900
2901
2902 fi
2903 if test -z "$CC"; then
2904   if test -n "$ac_tool_prefix"; then
2905   for ac_prog in cl.exe
2906   do
2907     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2908 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2910 $as_echo_n "checking for $ac_word... " >&6; }
2911 if test "${ac_cv_prog_CC+set}" = set; then :
2912   $as_echo_n "(cached) " >&6
2913 else
2914   if test -n "$CC"; then
2915   ac_cv_prog_CC="$CC" # Let the user override the test.
2916 else
2917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2918 for as_dir in $PATH
2919 do
2920   IFS=$as_save_IFS
2921   test -z "$as_dir" && as_dir=.
2922     for ac_exec_ext in '' $ac_executable_extensions; do
2923   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2924     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2925     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2926     break 2
2927   fi
2928 done
2929   done
2930 IFS=$as_save_IFS
2931
2932 fi
2933 fi
2934 CC=$ac_cv_prog_CC
2935 if test -n "$CC"; then
2936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2937 $as_echo "$CC" >&6; }
2938 else
2939   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2940 $as_echo "no" >&6; }
2941 fi
2942
2943
2944     test -n "$CC" && break
2945   done
2946 fi
2947 if test -z "$CC"; then
2948   ac_ct_CC=$CC
2949   for ac_prog in cl.exe
2950 do
2951   # Extract the first word of "$ac_prog", so it can be a program name with args.
2952 set dummy $ac_prog; 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 test "${ac_cv_prog_ac_ct_CC+set}" = set; 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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2968     ac_cv_prog_ac_ct_CC="$ac_prog"
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
2988   test -n "$ac_ct_CC" && break
2989 done
2990
2991   if test "x$ac_ct_CC" = x; then
2992     CC=""
2993   else
2994     case $cross_compiling:$ac_tool_warned in
2995 yes:)
2996 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2997 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2998 ac_tool_warned=yes ;;
2999 esac
3000     CC=$ac_ct_CC
3001   fi
3002 fi
3003
3004 fi
3005
3006
3007 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3008 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3009 as_fn_error "no acceptable C compiler found in \$PATH
3010 See \`config.log' for more details." "$LINENO" 5; }
3011
3012 # Provide some information about the compiler.
3013 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3014 set X $ac_compile
3015 ac_compiler=$2
3016 for ac_option in --version -v -V -qversion; do
3017   { { ac_try="$ac_compiler $ac_option >&5"
3018 case "(($ac_try" in
3019   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3020   *) ac_try_echo=$ac_try;;
3021 esac
3022 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3023 $as_echo "$ac_try_echo"; } >&5
3024   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3025   ac_status=$?
3026   if test -s conftest.err; then
3027     sed '10a\
3028 ... rest of stderr output deleted ...
3029          10q' conftest.err >conftest.er1
3030     cat conftest.er1 >&5
3031     rm -f conftest.er1 conftest.err
3032   fi
3033   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3034   test $ac_status = 0; }
3035 done
3036
3037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3038 /* end confdefs.h.  */
3039
3040 int
3041 main ()
3042 {
3043
3044   ;
3045   return 0;
3046 }
3047 _ACEOF
3048 ac_clean_files_save=$ac_clean_files
3049 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
3050 # Try to create an executable without -o first, disregard a.out.
3051 # It will help us diagnose broken compilers, and finding out an intuition
3052 # of exeext.
3053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3054 $as_echo_n "checking for C compiler default output file name... " >&6; }
3055 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3056
3057 # The possible output files:
3058 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3059
3060 ac_rmfiles=
3061 for ac_file in $ac_files
3062 do
3063   case $ac_file in
3064     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3065     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3066   esac
3067 done
3068 rm -f $ac_rmfiles
3069
3070 if { { ac_try="$ac_link_default"
3071 case "(($ac_try" in
3072   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3073   *) ac_try_echo=$ac_try;;
3074 esac
3075 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3076 $as_echo "$ac_try_echo"; } >&5
3077   (eval "$ac_link_default") 2>&5
3078   ac_status=$?
3079   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3080   test $ac_status = 0; }; then :
3081   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3082 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3083 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3084 # so that the user can short-circuit this test for compilers unknown to
3085 # Autoconf.
3086 for ac_file in $ac_files ''
3087 do
3088   test -f "$ac_file" || continue
3089   case $ac_file in
3090     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3091         ;;
3092     [ab].out )
3093         # We found the default executable, but exeext='' is most
3094         # certainly right.
3095         break;;
3096     *.* )
3097         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3098         then :; else
3099            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3100         fi
3101         # We set ac_cv_exeext here because the later test for it is not
3102         # safe: cross compilers may not add the suffix if given an `-o'
3103         # argument, so we may need to know it at that point already.
3104         # Even if this section looks crufty: it has the advantage of
3105         # actually working.
3106         break;;
3107     * )
3108         break;;
3109   esac
3110 done
3111 test "$ac_cv_exeext" = no && ac_cv_exeext=
3112
3113 else
3114   ac_file=''
3115 fi
3116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3117 $as_echo "$ac_file" >&6; }
3118 if test -z "$ac_file"; then :
3119   $as_echo "$as_me: failed program was:" >&5
3120 sed 's/^/| /' conftest.$ac_ext >&5
3121
3122 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3123 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3124 { as_fn_set_status 77
3125 as_fn_error "C compiler cannot create executables
3126 See \`config.log' for more details." "$LINENO" 5; }; }
3127 fi
3128 ac_exeext=$ac_cv_exeext
3129
3130 # Check that the compiler produces executables we can run.  If not, either
3131 # the compiler is broken, or we cross compile.
3132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3133 $as_echo_n "checking whether the C compiler works... " >&6; }
3134 # If not cross compiling, check that we can run a simple program.
3135 if test "$cross_compiling" != yes; then
3136   if { ac_try='./$ac_file'
3137   { { case "(($ac_try" in
3138   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3139   *) ac_try_echo=$ac_try;;
3140 esac
3141 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3142 $as_echo "$ac_try_echo"; } >&5
3143   (eval "$ac_try") 2>&5
3144   ac_status=$?
3145   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3146   test $ac_status = 0; }; }; then
3147     cross_compiling=no
3148   else
3149     if test "$cross_compiling" = maybe; then
3150         cross_compiling=yes
3151     else
3152         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3153 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3154 as_fn_error "cannot run C compiled programs.
3155 If you meant to cross compile, use \`--host'.
3156 See \`config.log' for more details." "$LINENO" 5; }
3157     fi
3158   fi
3159 fi
3160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3161 $as_echo "yes" >&6; }
3162
3163 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
3164 ac_clean_files=$ac_clean_files_save
3165 # Check that the compiler produces executables we can run.  If not, either
3166 # the compiler is broken, or we cross compile.
3167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3168 $as_echo_n "checking whether we are cross compiling... " >&6; }
3169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3170 $as_echo "$cross_compiling" >&6; }
3171
3172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3173 $as_echo_n "checking for suffix of executables... " >&6; }
3174 if { { ac_try="$ac_link"
3175 case "(($ac_try" in
3176   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3177   *) ac_try_echo=$ac_try;;
3178 esac
3179 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3180 $as_echo "$ac_try_echo"; } >&5
3181   (eval "$ac_link") 2>&5
3182   ac_status=$?
3183   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3184   test $ac_status = 0; }; then :
3185   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3186 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3187 # work properly (i.e., refer to `conftest.exe'), while it won't with
3188 # `rm'.
3189 for ac_file in conftest.exe conftest conftest.*; do
3190   test -f "$ac_file" || continue
3191   case $ac_file in
3192     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3193     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3194           break;;
3195     * ) break;;
3196   esac
3197 done
3198 else
3199   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3200 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3201 as_fn_error "cannot compute suffix of executables: cannot compile and link
3202 See \`config.log' for more details." "$LINENO" 5; }
3203 fi
3204 rm -f conftest$ac_cv_exeext
3205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3206 $as_echo "$ac_cv_exeext" >&6; }
3207
3208 rm -f conftest.$ac_ext
3209 EXEEXT=$ac_cv_exeext
3210 ac_exeext=$EXEEXT
3211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3212 $as_echo_n "checking for suffix of object files... " >&6; }
3213 if test "${ac_cv_objext+set}" = set; then :
3214   $as_echo_n "(cached) " >&6
3215 else
3216   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3217 /* end confdefs.h.  */
3218
3219 int
3220 main ()
3221 {
3222
3223   ;
3224   return 0;
3225 }
3226 _ACEOF
3227 rm -f conftest.o conftest.obj
3228 if { { ac_try="$ac_compile"
3229 case "(($ac_try" in
3230   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3231   *) ac_try_echo=$ac_try;;
3232 esac
3233 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3234 $as_echo "$ac_try_echo"; } >&5
3235   (eval "$ac_compile") 2>&5
3236   ac_status=$?
3237   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3238   test $ac_status = 0; }; then :
3239   for ac_file in conftest.o conftest.obj conftest.*; do
3240   test -f "$ac_file" || continue;
3241   case $ac_file in
3242     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3243     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3244        break;;
3245   esac
3246 done
3247 else
3248   $as_echo "$as_me: failed program was:" >&5
3249 sed 's/^/| /' conftest.$ac_ext >&5
3250
3251 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3252 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3253 as_fn_error "cannot compute suffix of object files: cannot compile
3254 See \`config.log' for more details." "$LINENO" 5; }
3255 fi
3256 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3257 fi
3258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3259 $as_echo "$ac_cv_objext" >&6; }
3260 OBJEXT=$ac_cv_objext
3261 ac_objext=$OBJEXT
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3263 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3264 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3265   $as_echo_n "(cached) " >&6
3266 else
3267   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3268 /* end confdefs.h.  */
3269
3270 int
3271 main ()
3272 {
3273 #ifndef __GNUC__
3274        choke me
3275 #endif
3276
3277   ;
3278   return 0;
3279 }
3280 _ACEOF
3281 if ac_fn_c_try_compile "$LINENO"; then :
3282   ac_compiler_gnu=yes
3283 else
3284   ac_compiler_gnu=no
3285 fi
3286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3287 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3288
3289 fi
3290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3291 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3292 if test $ac_compiler_gnu = yes; then
3293   GCC=yes
3294 else
3295   GCC=
3296 fi
3297 ac_test_CFLAGS=${CFLAGS+set}
3298 ac_save_CFLAGS=$CFLAGS
3299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3300 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3301 if test "${ac_cv_prog_cc_g+set}" = set; then :
3302   $as_echo_n "(cached) " >&6
3303 else
3304   ac_save_c_werror_flag=$ac_c_werror_flag
3305    ac_c_werror_flag=yes
3306    ac_cv_prog_cc_g=no
3307    CFLAGS="-g"
3308    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3309 /* end confdefs.h.  */
3310
3311 int
3312 main ()
3313 {
3314
3315   ;
3316   return 0;
3317 }
3318 _ACEOF
3319 if ac_fn_c_try_compile "$LINENO"; then :
3320   ac_cv_prog_cc_g=yes
3321 else
3322   CFLAGS=""
3323       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3324 /* end confdefs.h.  */
3325
3326 int
3327 main ()
3328 {
3329
3330   ;
3331   return 0;
3332 }
3333 _ACEOF
3334 if ac_fn_c_try_compile "$LINENO"; then :
3335
3336 else
3337   ac_c_werror_flag=$ac_save_c_werror_flag
3338          CFLAGS="-g"
3339          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3340 /* end confdefs.h.  */
3341
3342 int
3343 main ()
3344 {
3345
3346   ;
3347   return 0;
3348 }
3349 _ACEOF
3350 if ac_fn_c_try_compile "$LINENO"; then :
3351   ac_cv_prog_cc_g=yes
3352 fi
3353 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3354 fi
3355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3356 fi
3357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3358    ac_c_werror_flag=$ac_save_c_werror_flag
3359 fi
3360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3361 $as_echo "$ac_cv_prog_cc_g" >&6; }
3362 if test "$ac_test_CFLAGS" = set; then
3363   CFLAGS=$ac_save_CFLAGS
3364 elif test $ac_cv_prog_cc_g = yes; then
3365   if test "$GCC" = yes; then
3366     CFLAGS="-g -O2"
3367   else
3368     CFLAGS="-g"
3369   fi
3370 else
3371   if test "$GCC" = yes; then
3372     CFLAGS="-O2"
3373   else
3374     CFLAGS=
3375   fi
3376 fi
3377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3378 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3379 if test "${ac_cv_prog_cc_c89+set}" = set; then :
3380   $as_echo_n "(cached) " >&6
3381 else
3382   ac_cv_prog_cc_c89=no
3383 ac_save_CC=$CC
3384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3385 /* end confdefs.h.  */
3386 #include <stdarg.h>
3387 #include <stdio.h>
3388 #include <sys/types.h>
3389 #include <sys/stat.h>
3390 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3391 struct buf { int x; };
3392 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3393 static char *e (p, i)
3394      char **p;
3395      int i;
3396 {
3397   return p[i];
3398 }
3399 static char *f (char * (*g) (char **, int), char **p, ...)
3400 {
3401   char *s;
3402   va_list v;
3403   va_start (v,p);
3404   s = g (p, va_arg (v,int));
3405   va_end (v);
3406   return s;
3407 }
3408
3409 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3410    function prototypes and stuff, but not '\xHH' hex character constants.
3411    These don't provoke an error unfortunately, instead are silently treated
3412    as 'x'.  The following induces an error, until -std is added to get
3413    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3414    array size at least.  It's necessary to write '\x00'==0 to get something
3415    that's true only with -std.  */
3416 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3417
3418 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3419    inside strings and character constants.  */
3420 #define FOO(x) 'x'
3421 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3422
3423 int test (int i, double x);
3424 struct s1 {int (*f) (int a);};
3425 struct s2 {int (*f) (double a);};
3426 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3427 int argc;
3428 char **argv;
3429 int
3430 main ()
3431 {
3432 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3433   ;
3434   return 0;
3435 }
3436 _ACEOF
3437 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3438         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3439 do
3440   CC="$ac_save_CC $ac_arg"
3441   if ac_fn_c_try_compile "$LINENO"; then :
3442   ac_cv_prog_cc_c89=$ac_arg
3443 fi
3444 rm -f core conftest.err conftest.$ac_objext
3445   test "x$ac_cv_prog_cc_c89" != "xno" && break
3446 done
3447 rm -f conftest.$ac_ext
3448 CC=$ac_save_CC
3449
3450 fi
3451 # AC_CACHE_VAL
3452 case "x$ac_cv_prog_cc_c89" in
3453   x)
3454     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3455 $as_echo "none needed" >&6; } ;;
3456   xno)
3457     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3458 $as_echo "unsupported" >&6; } ;;
3459   *)
3460     CC="$CC $ac_cv_prog_cc_c89"
3461     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3462 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3463 esac
3464 if test "x$ac_cv_prog_cc_c89" != xno; then :
3465
3466 fi
3467
3468 ac_ext=c
3469 ac_cpp='$CPP $CPPFLAGS'
3470 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3471 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3472 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3473
3474
3475 ac_ext=c
3476 ac_cpp='$CPP $CPPFLAGS'
3477 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3478 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3479 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3481 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3482 # On Suns, sometimes $CPP names a directory.
3483 if test -n "$CPP" && test -d "$CPP"; then
3484   CPP=
3485 fi
3486 if test -z "$CPP"; then
3487   if test "${ac_cv_prog_CPP+set}" = set; then :
3488   $as_echo_n "(cached) " >&6
3489 else
3490       # Double quotes because CPP needs to be expanded
3491     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3492     do
3493       ac_preproc_ok=false
3494 for ac_c_preproc_warn_flag in '' yes
3495 do
3496   # Use a header file that comes with gcc, so configuring glibc
3497   # with a fresh cross-compiler works.
3498   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3499   # <limits.h> exists even on freestanding compilers.
3500   # On the NeXT, cc -E runs the code through the compiler's parser,
3501   # not just through cpp. "Syntax error" is here to catch this case.
3502   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3503 /* end confdefs.h.  */
3504 #ifdef __STDC__
3505 # include <limits.h>
3506 #else
3507 # include <assert.h>
3508 #endif
3509                      Syntax error
3510 _ACEOF
3511 if ac_fn_c_try_cpp "$LINENO"; then :
3512
3513 else
3514   # Broken: fails on valid input.
3515 continue
3516 fi
3517 rm -f conftest.err conftest.$ac_ext
3518
3519   # OK, works on sane cases.  Now check whether nonexistent headers
3520   # can be detected and how.
3521   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3522 /* end confdefs.h.  */
3523 #include <ac_nonexistent.h>
3524 _ACEOF
3525 if ac_fn_c_try_cpp "$LINENO"; then :
3526   # Broken: success on invalid input.
3527 continue
3528 else
3529   # Passes both tests.
3530 ac_preproc_ok=:
3531 break
3532 fi
3533 rm -f conftest.err conftest.$ac_ext
3534
3535 done
3536 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3537 rm -f conftest.err conftest.$ac_ext
3538 if $ac_preproc_ok; then :
3539   break
3540 fi
3541
3542     done
3543     ac_cv_prog_CPP=$CPP
3544
3545 fi
3546   CPP=$ac_cv_prog_CPP
3547 else
3548   ac_cv_prog_CPP=$CPP
3549 fi
3550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3551 $as_echo "$CPP" >&6; }
3552 ac_preproc_ok=false
3553 for ac_c_preproc_warn_flag in '' yes
3554 do
3555   # Use a header file that comes with gcc, so configuring glibc
3556   # with a fresh cross-compiler works.
3557   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3558   # <limits.h> exists even on freestanding compilers.
3559   # On the NeXT, cc -E runs the code through the compiler's parser,
3560   # not just through cpp. "Syntax error" is here to catch this case.
3561   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3562 /* end confdefs.h.  */
3563 #ifdef __STDC__
3564 # include <limits.h>
3565 #else
3566 # include <assert.h>
3567 #endif
3568                      Syntax error
3569 _ACEOF
3570 if ac_fn_c_try_cpp "$LINENO"; then :
3571
3572 else
3573   # Broken: fails on valid input.
3574 continue
3575 fi
3576 rm -f conftest.err conftest.$ac_ext
3577
3578   # OK, works on sane cases.  Now check whether nonexistent headers
3579   # can be detected and how.
3580   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3581 /* end confdefs.h.  */
3582 #include <ac_nonexistent.h>
3583 _ACEOF
3584 if ac_fn_c_try_cpp "$LINENO"; then :
3585   # Broken: success on invalid input.
3586 continue
3587 else
3588   # Passes both tests.
3589 ac_preproc_ok=:
3590 break
3591 fi
3592 rm -f conftest.err conftest.$ac_ext
3593
3594 done
3595 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3596 rm -f conftest.err conftest.$ac_ext
3597 if $ac_preproc_ok; then :
3598
3599 else
3600   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3601 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3602 as_fn_error "C preprocessor \"$CPP\" fails sanity check
3603 See \`config.log' for more details." "$LINENO" 5; }
3604 fi
3605
3606 ac_ext=c
3607 ac_cpp='$CPP $CPPFLAGS'
3608 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3609 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3610 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3611
3612
3613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3614 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3615 if test "${ac_cv_path_GREP+set}" = set; then :
3616   $as_echo_n "(cached) " >&6
3617 else
3618   if test -z "$GREP"; then
3619   ac_path_GREP_found=false
3620   # Loop through the user's path and test for each of PROGNAME-LIST
3621   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3622 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3623 do
3624   IFS=$as_save_IFS
3625   test -z "$as_dir" && as_dir=.
3626     for ac_prog in grep ggrep; do
3627     for ac_exec_ext in '' $ac_executable_extensions; do
3628       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3629       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3630 # Check for GNU ac_path_GREP and select it if it is found.
3631   # Check for GNU $ac_path_GREP
3632 case `"$ac_path_GREP" --version 2>&1` in
3633 *GNU*)
3634   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3635 *)
3636   ac_count=0
3637   $as_echo_n 0123456789 >"conftest.in"
3638   while :
3639   do
3640     cat "conftest.in" "conftest.in" >"conftest.tmp"
3641     mv "conftest.tmp" "conftest.in"
3642     cp "conftest.in" "conftest.nl"
3643     $as_echo 'GREP' >> "conftest.nl"
3644     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3645     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3646     as_fn_arith $ac_count + 1 && ac_count=$as_val
3647     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3648       # Best one so far, save it but keep looking for a better one
3649       ac_cv_path_GREP="$ac_path_GREP"
3650       ac_path_GREP_max=$ac_count
3651     fi
3652     # 10*(2^10) chars as input seems more than enough
3653     test $ac_count -gt 10 && break
3654   done
3655   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3656 esac
3657
3658       $ac_path_GREP_found && break 3
3659     done
3660   done
3661   done
3662 IFS=$as_save_IFS
3663   if test -z "$ac_cv_path_GREP"; then
3664     as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3665   fi
3666 else
3667   ac_cv_path_GREP=$GREP
3668 fi
3669
3670 fi
3671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3672 $as_echo "$ac_cv_path_GREP" >&6; }
3673  GREP="$ac_cv_path_GREP"
3674
3675
3676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3677 $as_echo_n "checking for egrep... " >&6; }
3678 if test "${ac_cv_path_EGREP+set}" = set; then :
3679   $as_echo_n "(cached) " >&6
3680 else
3681   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3682    then ac_cv_path_EGREP="$GREP -E"
3683    else
3684      if test -z "$EGREP"; then
3685   ac_path_EGREP_found=false
3686   # Loop through the user's path and test for each of PROGNAME-LIST
3687   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3688 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3689 do
3690   IFS=$as_save_IFS
3691   test -z "$as_dir" && as_dir=.
3692     for ac_prog in egrep; do
3693     for ac_exec_ext in '' $ac_executable_extensions; do
3694       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3695       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3696 # Check for GNU ac_path_EGREP and select it if it is found.
3697   # Check for GNU $ac_path_EGREP
3698 case `"$ac_path_EGREP" --version 2>&1` in
3699 *GNU*)
3700   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3701 *)
3702   ac_count=0
3703   $as_echo_n 0123456789 >"conftest.in"
3704   while :
3705   do
3706     cat "conftest.in" "conftest.in" >"conftest.tmp"
3707     mv "conftest.tmp" "conftest.in"
3708     cp "conftest.in" "conftest.nl"
3709     $as_echo 'EGREP' >> "conftest.nl"
3710     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3711     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3712     as_fn_arith $ac_count + 1 && ac_count=$as_val
3713     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3714       # Best one so far, save it but keep looking for a better one
3715       ac_cv_path_EGREP="$ac_path_EGREP"
3716       ac_path_EGREP_max=$ac_count
3717     fi
3718     # 10*(2^10) chars as input seems more than enough
3719     test $ac_count -gt 10 && break
3720   done
3721   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3722 esac
3723
3724       $ac_path_EGREP_found && break 3
3725     done
3726   done
3727   done
3728 IFS=$as_save_IFS
3729   if test -z "$ac_cv_path_EGREP"; then
3730     as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3731   fi
3732 else
3733   ac_cv_path_EGREP=$EGREP
3734 fi
3735
3736    fi
3737 fi
3738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3739 $as_echo "$ac_cv_path_EGREP" >&6; }
3740  EGREP="$ac_cv_path_EGREP"
3741
3742
3743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3744 $as_echo_n "checking for ANSI C header files... " >&6; }
3745 if test "${ac_cv_header_stdc+set}" = set; then :
3746   $as_echo_n "(cached) " >&6
3747 else
3748   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3749 /* end confdefs.h.  */
3750 #include <stdlib.h>
3751 #include <stdarg.h>
3752 #include <string.h>
3753 #include <float.h>
3754
3755 int
3756 main ()
3757 {
3758
3759   ;
3760   return 0;
3761 }
3762 _ACEOF
3763 if ac_fn_c_try_compile "$LINENO"; then :
3764   ac_cv_header_stdc=yes
3765 else
3766   ac_cv_header_stdc=no
3767 fi
3768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3769
3770 if test $ac_cv_header_stdc = yes; then
3771   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3772   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3773 /* end confdefs.h.  */
3774 #include <string.h>
3775
3776 _ACEOF
3777 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3778   $EGREP "memchr" >/dev/null 2>&1; then :
3779
3780 else
3781   ac_cv_header_stdc=no
3782 fi
3783 rm -f conftest*
3784
3785 fi
3786
3787 if test $ac_cv_header_stdc = yes; then
3788   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3789   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3790 /* end confdefs.h.  */
3791 #include <stdlib.h>
3792
3793 _ACEOF
3794 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3795   $EGREP "free" >/dev/null 2>&1; then :
3796
3797 else
3798   ac_cv_header_stdc=no
3799 fi
3800 rm -f conftest*
3801
3802 fi
3803
3804 if test $ac_cv_header_stdc = yes; then
3805   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3806   if test "$cross_compiling" = yes; then :
3807   :
3808 else
3809   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3810 /* end confdefs.h.  */
3811 #include <ctype.h>
3812 #include <stdlib.h>
3813 #if ((' ' & 0x0FF) == 0x020)
3814 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3815 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3816 #else
3817 # define ISLOWER(c) \
3818                    (('a' <= (c) && (c) <= 'i') \
3819                      || ('j' <= (c) && (c) <= 'r') \
3820                      || ('s' <= (c) && (c) <= 'z'))
3821 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3822 #endif
3823
3824 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3825 int
3826 main ()
3827 {
3828   int i;
3829   for (i = 0; i < 256; i++)
3830     if (XOR (islower (i), ISLOWER (i))
3831         || toupper (i) != TOUPPER (i))
3832       return 2;
3833   return 0;
3834 }
3835 _ACEOF
3836 if ac_fn_c_try_run "$LINENO"; then :
3837
3838 else
3839   ac_cv_header_stdc=no
3840 fi
3841 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3842   conftest.$ac_objext conftest.beam conftest.$ac_ext
3843 fi
3844
3845 fi
3846 fi
3847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
3848 $as_echo "$ac_cv_header_stdc" >&6; }
3849 if test $ac_cv_header_stdc = yes; then
3850
3851 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
3852
3853 fi
3854
3855 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
3856 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3857                   inttypes.h stdint.h unistd.h
3858 do :
3859   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
3860 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
3861 "
3862 eval as_val=\$$as_ac_Header
3863    if test "x$as_val" = x""yes; then :
3864   cat >>confdefs.h <<_ACEOF
3865 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
3866 _ACEOF
3867
3868 fi
3869
3870 done
3871
3872
3873
3874   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
3875 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
3876   MINIX=yes
3877 else
3878   MINIX=
3879 fi
3880
3881
3882   if test "$MINIX" = yes; then
3883
3884 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
3885
3886
3887 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
3888
3889
3890 $as_echo "#define _MINIX 1" >>confdefs.h
3891
3892   fi
3893
3894
3895   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
3896 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
3897 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
3898   $as_echo_n "(cached) " >&6
3899 else
3900   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3901 /* end confdefs.h.  */
3902
3903 #         define __EXTENSIONS__ 1
3904           $ac_includes_default
3905 int
3906 main ()
3907 {
3908
3909   ;
3910   return 0;
3911 }
3912 _ACEOF
3913 if ac_fn_c_try_compile "$LINENO"; then :
3914   ac_cv_safe_to_define___extensions__=yes
3915 else
3916   ac_cv_safe_to_define___extensions__=no
3917 fi
3918 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3919 fi
3920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
3921 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
3922   test $ac_cv_safe_to_define___extensions__ = yes &&
3923     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
3924
3925   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
3926
3927   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
3928
3929   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
3930
3931   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
3932
3933
3934 ac_aux_dir=
3935 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3936   for ac_t in install-sh install.sh shtool; do
3937     if test -f "$ac_dir/$ac_t"; then
3938       ac_aux_dir=$ac_dir
3939       ac_install_sh="$ac_aux_dir/$ac_t -c"
3940       break 2
3941     fi
3942   done
3943 done
3944 if test -z "$ac_aux_dir"; then
3945   as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3946 fi
3947
3948 # These three variables are undocumented and unsupported,
3949 # and are intended to be withdrawn in a future Autoconf release.
3950 # They can cause serious problems if a builder's source tree is in a directory
3951 # whose full name contains unusual characters.
3952 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3953 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3954 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3955
3956
3957 # Make sure we can run config.sub.
3958 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3959   as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3960
3961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3962 $as_echo_n "checking build system type... " >&6; }
3963 if test "${ac_cv_build+set}" = set; then :
3964   $as_echo_n "(cached) " >&6
3965 else
3966   ac_build_alias=$build_alias
3967 test "x$ac_build_alias" = x &&
3968   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3969 test "x$ac_build_alias" = x &&
3970   as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
3971 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3972   as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3973
3974 fi
3975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3976 $as_echo "$ac_cv_build" >&6; }
3977 case $ac_cv_build in
3978 *-*-*) ;;
3979 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
3980 esac
3981 build=$ac_cv_build
3982 ac_save_IFS=$IFS; IFS='-'
3983 set x $ac_cv_build
3984 shift
3985 build_cpu=$1
3986 build_vendor=$2
3987 shift; shift
3988 # Remember, the first character of IFS is used to create $*,
3989 # except with old shells:
3990 build_os=$*
3991 IFS=$ac_save_IFS
3992 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3993
3994
3995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3996 $as_echo_n "checking host system type... " >&6; }
3997 if test "${ac_cv_host+set}" = set; then :
3998   $as_echo_n "(cached) " >&6
3999 else
4000   if test "x$host_alias" = x; then
4001   ac_cv_host=$ac_cv_build
4002 else
4003   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4004     as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4005 fi
4006
4007 fi
4008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4009 $as_echo "$ac_cv_host" >&6; }
4010 case $ac_cv_host in
4011 *-*-*) ;;
4012 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4013 esac
4014 host=$ac_cv_host
4015 ac_save_IFS=$IFS; IFS='-'
4016 set x $ac_cv_host
4017 shift
4018 host_cpu=$1
4019 host_vendor=$2
4020 shift; shift
4021 # Remember, the first character of IFS is used to create $*,
4022 # except with old shells:
4023 host_os=$*
4024 IFS=$ac_save_IFS
4025 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4026
4027
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4029 $as_echo_n "checking target system type... " >&6; }
4030 if test "${ac_cv_target+set}" = set; then :
4031   $as_echo_n "(cached) " >&6
4032 else
4033   if test "x$target_alias" = x; then
4034   ac_cv_target=$ac_cv_host
4035 else
4036   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4037     as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4038 fi
4039
4040 fi
4041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4042 $as_echo "$ac_cv_target" >&6; }
4043 case $ac_cv_target in
4044 *-*-*) ;;
4045 *) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
4046 esac
4047 target=$ac_cv_target
4048 ac_save_IFS=$IFS; IFS='-'
4049 set x $ac_cv_target
4050 shift
4051 target_cpu=$1
4052 target_vendor=$2
4053 shift; shift
4054 # Remember, the first character of IFS is used to create $*,
4055 # except with old shells:
4056 target_os=$*
4057 IFS=$ac_save_IFS
4058 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4059
4060
4061 # The aliases save the names the user supplied, while $host etc.
4062 # will get canonicalized.
4063 test -n "$target_alias" &&
4064   test "$program_prefix$program_suffix$program_transform_name" = \
4065     NONENONEs,x,x, &&
4066   program_prefix=${target_alias}-
4067
4068 # The tests for host and target for $enable_largefile require
4069 # canonical names.
4070
4071
4072
4073 # As the $enable_largefile decision depends on --enable-plugins we must set it
4074 # even in directories otherwise not depending on the $plugins option.
4075
4076
4077 # Check whether --enable-plugins was given.
4078 if test "${enable_plugins+set}" = set; then :
4079   enableval=$enable_plugins; case "${enableval}" in
4080   yes | "") plugins=yes ;;
4081   no) plugins=no ;;
4082   *) plugins=yes ;;
4083  esac
4084 else
4085   plugins=no
4086 fi
4087
4088
4089
4090 case "${host}" in
4091   sparc-*-solaris*|i[3-7]86-*-solaris*)
4092     # On native 32bit sparc and ia32 solaris, large-file and procfs support
4093     # are mutually exclusive; and without procfs support, the bfd/ elf module
4094     # cannot provide certain routines such as elfcore_write_prpsinfo
4095     # or elfcore_write_prstatus.  So unless the user explicitly requested
4096     # large-file support through the --enable-largefile switch, disable
4097     # large-file support in favor of procfs support.
4098     test "${target}" = "${host}" -a "x$plugins" = xno \
4099       && : ${enable_largefile="no"}
4100     ;;
4101 esac
4102
4103 # Check whether --enable-largefile was given.
4104 if test "${enable_largefile+set}" = set; then :
4105   enableval=$enable_largefile;
4106 fi
4107
4108 if test "$enable_largefile" != no; then
4109
4110   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4111 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4112 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
4113   $as_echo_n "(cached) " >&6
4114 else
4115   ac_cv_sys_largefile_CC=no
4116      if test "$GCC" != yes; then
4117        ac_save_CC=$CC
4118        while :; do
4119          # IRIX 6.2 and later do not support large files by default,
4120          # so use the C compiler's -n32 option if that helps.
4121          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4122 /* end confdefs.h.  */
4123 #include <sys/types.h>
4124  /* Check that off_t can represent 2**63 - 1 correctly.
4125     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4126     since some C++ compilers masquerading as C compilers
4127     incorrectly reject 9223372036854775807.  */
4128 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4129   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4130                        && LARGE_OFF_T % 2147483647 == 1)
4131                       ? 1 : -1];
4132 int
4133 main ()
4134 {
4135
4136   ;
4137   return 0;
4138 }
4139 _ACEOF
4140          if ac_fn_c_try_compile "$LINENO"; then :
4141   break
4142 fi
4143 rm -f core conftest.err conftest.$ac_objext
4144          CC="$CC -n32"
4145          if ac_fn_c_try_compile "$LINENO"; then :
4146   ac_cv_sys_largefile_CC=' -n32'; break
4147 fi
4148 rm -f core conftest.err conftest.$ac_objext
4149          break
4150        done
4151        CC=$ac_save_CC
4152        rm -f conftest.$ac_ext
4153     fi
4154 fi
4155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4156 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4157   if test "$ac_cv_sys_largefile_CC" != no; then
4158     CC=$CC$ac_cv_sys_largefile_CC
4159   fi
4160
4161   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4162 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4163 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
4164   $as_echo_n "(cached) " >&6
4165 else
4166   while :; do
4167   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4168 /* end confdefs.h.  */
4169 #include <sys/types.h>
4170  /* Check that off_t can represent 2**63 - 1 correctly.
4171     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4172     since some C++ compilers masquerading as C compilers
4173     incorrectly reject 9223372036854775807.  */
4174 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4175   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4176                        && LARGE_OFF_T % 2147483647 == 1)
4177                       ? 1 : -1];
4178 int
4179 main ()
4180 {
4181
4182   ;
4183   return 0;
4184 }
4185 _ACEOF
4186 if ac_fn_c_try_compile "$LINENO"; then :
4187   ac_cv_sys_file_offset_bits=no; break
4188 fi
4189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4190   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4191 /* end confdefs.h.  */
4192 #define _FILE_OFFSET_BITS 64
4193 #include <sys/types.h>
4194  /* Check that off_t can represent 2**63 - 1 correctly.
4195     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4196     since some C++ compilers masquerading as C compilers
4197     incorrectly reject 9223372036854775807.  */
4198 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4199   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4200                        && LARGE_OFF_T % 2147483647 == 1)
4201                       ? 1 : -1];
4202 int
4203 main ()
4204 {
4205
4206   ;
4207   return 0;
4208 }
4209 _ACEOF
4210 if ac_fn_c_try_compile "$LINENO"; then :
4211   ac_cv_sys_file_offset_bits=64; break
4212 fi
4213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4214   ac_cv_sys_file_offset_bits=unknown
4215   break
4216 done
4217 fi
4218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4219 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4220 case $ac_cv_sys_file_offset_bits in #(
4221   no | unknown) ;;
4222   *)
4223 cat >>confdefs.h <<_ACEOF
4224 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4225 _ACEOF
4226 ;;
4227 esac
4228 rm -rf conftest*
4229   if test $ac_cv_sys_file_offset_bits = unknown; then
4230     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4231 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4232 if test "${ac_cv_sys_large_files+set}" = set; then :
4233   $as_echo_n "(cached) " >&6
4234 else
4235   while :; do
4236   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4237 /* end confdefs.h.  */
4238 #include <sys/types.h>
4239  /* Check that off_t can represent 2**63 - 1 correctly.
4240     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4241     since some C++ compilers masquerading as C compilers
4242     incorrectly reject 9223372036854775807.  */
4243 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4244   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4245                        && LARGE_OFF_T % 2147483647 == 1)
4246                       ? 1 : -1];
4247 int
4248 main ()
4249 {
4250
4251   ;
4252   return 0;
4253 }
4254 _ACEOF
4255 if ac_fn_c_try_compile "$LINENO"; then :
4256   ac_cv_sys_large_files=no; break
4257 fi
4258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4259   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4260 /* end confdefs.h.  */
4261 #define _LARGE_FILES 1
4262 #include <sys/types.h>
4263  /* Check that off_t can represent 2**63 - 1 correctly.
4264     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4265     since some C++ compilers masquerading as C compilers
4266     incorrectly reject 9223372036854775807.  */
4267 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4268   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4269                        && LARGE_OFF_T % 2147483647 == 1)
4270                       ? 1 : -1];
4271 int
4272 main ()
4273 {
4274
4275   ;
4276   return 0;
4277 }
4278 _ACEOF
4279 if ac_fn_c_try_compile "$LINENO"; then :
4280   ac_cv_sys_large_files=1; break
4281 fi
4282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4283   ac_cv_sys_large_files=unknown
4284   break
4285 done
4286 fi
4287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4288 $as_echo "$ac_cv_sys_large_files" >&6; }
4289 case $ac_cv_sys_large_files in #(
4290   no | unknown) ;;
4291   *)
4292 cat >>confdefs.h <<_ACEOF
4293 #define _LARGE_FILES $ac_cv_sys_large_files
4294 _ACEOF
4295 ;;
4296 esac
4297 rm -rf conftest*
4298   fi
4299 fi
4300
4301
4302
4303
4304
4305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${CC-cc} option to accept ANSI C" >&5
4306 $as_echo_n "checking for ${CC-cc} option to accept ANSI C... " >&6; }
4307 if test "${am_cv_prog_cc_stdc+set}" = set; then :
4308   $as_echo_n "(cached) " >&6
4309 else
4310   am_cv_prog_cc_stdc=no
4311 ac_save_CC="$CC"
4312 # Don't try gcc -ansi; that turns off useful extensions and
4313 # breaks some systems' header files.
4314 # AIX                   -qlanglvl=ansi
4315 # Ultrix and OSF/1      -std1
4316 # HP-UX 10.20 and later -Ae
4317 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4318 # SVR4                  -Xc -D__EXTENSIONS__
4319 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4320 do
4321   CC="$ac_save_CC $ac_arg"
4322   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4323 /* end confdefs.h.  */
4324 #include <stdarg.h>
4325 #include <stdio.h>
4326 #include <sys/types.h>
4327 #include <sys/stat.h>
4328 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4329 struct buf { int x; };
4330 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4331 static char *e (p, i)
4332      char **p;
4333      int i;
4334 {
4335   return p[i];
4336 }
4337 static char *f (char * (*g) (char **, int), char **p, ...)
4338 {
4339   char *s;
4340   va_list v;
4341   va_start (v,p);
4342   s = g (p, va_arg (v,int));
4343   va_end (v);
4344   return s;
4345 }
4346 int test (int i, double x);
4347 struct s1 {int (*f) (int a);};
4348 struct s2 {int (*f) (double a);};
4349 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4350 int argc;
4351 char **argv;
4352
4353 int
4354 main ()
4355 {
4356
4357 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4358
4359   ;
4360   return 0;
4361 }
4362 _ACEOF
4363 if ac_fn_c_try_compile "$LINENO"; then :
4364   am_cv_prog_cc_stdc="$ac_arg"; break
4365 fi
4366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4367 done
4368 CC="$ac_save_CC"
4369
4370 fi
4371
4372 if test -z "$am_cv_prog_cc_stdc"; then
4373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4374 $as_echo "none needed" >&6; }
4375 else
4376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_stdc" >&5
4377 $as_echo "$am_cv_prog_cc_stdc" >&6; }
4378 fi
4379 case "x$am_cv_prog_cc_stdc" in
4380   x|xno) ;;
4381   *) CC="$CC $am_cv_prog_cc_stdc" ;;
4382 esac
4383
4384
4385 ac_aux_dir=
4386 for ac_dir in .. "$srcdir"/..; do
4387   for ac_t in install-sh install.sh shtool; do
4388     if test -f "$ac_dir/$ac_t"; then
4389       ac_aux_dir=$ac_dir
4390       ac_install_sh="$ac_aux_dir/$ac_t -c"
4391       break 2
4392     fi
4393   done
4394 done
4395 if test -z "$ac_aux_dir"; then
4396   as_fn_error "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
4397 fi
4398
4399 # These three variables are undocumented and unsupported,
4400 # and are intended to be withdrawn in a future Autoconf release.
4401 # They can cause serious problems if a builder's source tree is in a directory
4402 # whose full name contains unusual characters.
4403 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
4404 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
4405 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
4406
4407
4408
4409 test "$program_prefix" != NONE &&
4410   program_transform_name="s&^&$program_prefix&;$program_transform_name"
4411 # Use a double $ so make ignores it.
4412 test "$program_suffix" != NONE &&
4413   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
4414 # Double any \ or $.
4415 # By default was `s,x,x', remove it if useless.
4416 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
4417 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
4418
4419
4420 # Dependency checking.
4421 rm -rf .tst 2>/dev/null
4422 mkdir .tst 2>/dev/null
4423 if test -d .tst; then
4424   am__leading_dot=.
4425 else
4426   am__leading_dot=_
4427 fi
4428 rmdir .tst 2>/dev/null
4429
4430 DEPDIR="${am__leading_dot}deps"
4431
4432 ac_config_commands="$ac_config_commands depdir"
4433
4434
4435 depcc="$CC"   am_compiler_list=
4436
4437 am_depcomp=$ac_aux_dir/depcomp
4438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4439 $as_echo_n "checking dependency style of $depcc... " >&6; }
4440 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
4441   $as_echo_n "(cached) " >&6
4442 else
4443   if test -f "$am_depcomp"; then
4444   # We make a subdir and do the tests there.  Otherwise we can end up
4445   # making bogus files that we don't know about and never remove.  For
4446   # instance it was reported that on HP-UX the gcc test will end up
4447   # making a dummy file named `D' -- because `-MD' means `put the output
4448   # in D'.
4449   mkdir conftest.dir
4450   # Copy depcomp to subdir because otherwise we won't find it if we're
4451   # using a relative directory.
4452   cp "$am_depcomp" conftest.dir
4453   cd conftest.dir
4454   # We will build objects and dependencies in a subdirectory because
4455   # it helps to detect inapplicable dependency modes.  For instance
4456   # both Tru64's cc and ICC support -MD to output dependencies as a
4457   # side effect of compilation, but ICC will put the dependencies in
4458   # the current directory while Tru64 will put them in the object
4459   # directory.
4460   mkdir sub
4461
4462   am_cv_CC_dependencies_compiler_type=none
4463   if test "$am_compiler_list" = ""; then
4464      am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4465   fi
4466   for depmode in $am_compiler_list; do
4467     if test $depmode = none; then break; fi
4468
4469     $as_echo "$as_me:$LINENO: trying $depmode" >&5
4470     # Setup a source with many dependencies, because some compilers
4471     # like to wrap large dependency lists on column 80 (with \), and
4472     # we should not choose a depcomp mode which is confused by this.
4473     #
4474     # We need to recreate these files for each test, as the compiler may
4475     # overwrite some of them when testing with obscure command lines.
4476     # This happens at least with the AIX C compiler.
4477     : > sub/conftest.c
4478     for i in 1 2 3 4 5 6; do
4479       echo '#include "conftst'$i'.h"' >> sub/conftest.c
4480       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4481       # Solaris 8's {/usr,}/bin/sh.
4482       touch sub/conftst$i.h
4483     done
4484     echo "include sub/conftest.Po" > confmf
4485
4486     # We check with `-c' and `-o' for the sake of the "dashmstdout"
4487     # mode.  It turns out that the SunPro C++ compiler does not properly
4488     # handle `-M -o', and we need to detect this.
4489     depcmd="depmode=$depmode \
4490        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
4491        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4492        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
4493     echo "| $depcmd" | sed -e 's/  */ /g' >&5
4494     if env $depcmd > conftest.err 2>&1 &&
4495        grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
4496        grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
4497        ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
4498       # icc doesn't choke on unknown options, it will just issue warnings
4499       # or remarks (even with -Werror).  So we grep stderr for any message
4500       # that says an option was ignored or not supported.
4501       # When given -MP, icc 7.0 and 7.1 complain thusly:
4502       #   icc: Command line warning: ignoring option '-M'; no argument required
4503       # The diagnosis changed in icc 8.0:
4504       #   icc: Command line remark: option '-MP' not supported
4505       if (grep 'ignoring option' conftest.err ||
4506           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4507         am_cv_CC_dependencies_compiler_type=$depmode
4508         $as_echo "$as_me:$LINENO: success" >&5
4509         break
4510       fi
4511     fi
4512     $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
4513     sed -e 's/^/| /' < conftest.err >&5
4514   done
4515
4516   cd ..
4517   rm -rf conftest.dir
4518 else
4519   am_cv_CC_dependencies_compiler_type=none
4520 fi
4521
4522 fi
4523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4524 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4525 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
4526 then as_fn_error "no usable dependency style found" "$LINENO" 5
4527 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4528
4529 fi
4530
4531
4532 # Check for the 'make' the user wants to use.
4533 for ac_prog in make
4534 do
4535   # Extract the first word of "$ac_prog", so it can be a program name with args.
4536 set dummy $ac_prog; ac_word=$2
4537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4538 $as_echo_n "checking for $ac_word... " >&6; }
4539 if test "${ac_cv_prog_MAKE+set}" = set; then :
4540   $as_echo_n "(cached) " >&6
4541 else
4542   if test -n "$MAKE"; then
4543   ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
4544 else
4545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4546 for as_dir in $PATH
4547 do
4548   IFS=$as_save_IFS
4549   test -z "$as_dir" && as_dir=.
4550     for ac_exec_ext in '' $ac_executable_extensions; do
4551   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4552     ac_cv_prog_MAKE="$ac_prog"
4553     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4554     break 2
4555   fi
4556 done
4557   done
4558 IFS=$as_save_IFS
4559
4560 fi
4561 fi
4562 MAKE=$ac_cv_prog_MAKE
4563 if test -n "$MAKE"; then
4564   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
4565 $as_echo "$MAKE" >&6; }
4566 else
4567   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4568 $as_echo "no" >&6; }
4569 fi
4570
4571
4572   test -n "$MAKE" && break
4573 done
4574
4575 MAKE_IS_GNU=
4576 case "`$MAKE --version 2>&1 | sed 1q`" in
4577   *GNU*)
4578     MAKE_IS_GNU=yes
4579     ;;
4580 esac
4581  if test "$MAKE_IS_GNU" = yes; then
4582   GMAKE_TRUE=
4583   GMAKE_FALSE='#'
4584 else
4585   GMAKE_TRUE='#'
4586   GMAKE_FALSE=
4587 fi
4588
4589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
4590 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
4591 set x ${MAKE-make}
4592 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
4593 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
4594   $as_echo_n "(cached) " >&6
4595 else
4596   cat >conftest.make <<\_ACEOF
4597 SHELL = /bin/sh
4598 all:
4599         @echo '@@@%%%=$(MAKE)=@@@%%%'
4600 _ACEOF
4601 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
4602 case `${MAKE-make} -f conftest.make 2>/dev/null` in
4603   *@@@%%%=?*=@@@%%%*)
4604     eval ac_cv_prog_make_${ac_make}_set=yes;;
4605   *)
4606     eval ac_cv_prog_make_${ac_make}_set=no;;
4607 esac
4608 rm -f conftest.make
4609 fi
4610 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
4611   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4612 $as_echo "yes" >&6; }
4613   SET_MAKE=
4614 else
4615   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4616 $as_echo "no" >&6; }
4617   SET_MAKE="MAKE=${MAKE-make}"
4618 fi
4619
4620
4621 # Configure gnulib.  We need to build gnulib under some other
4622 # directory not "gnulib", to avoid the problem of both GDB and
4623 # GDBserver wanting to build it in the same directory, when building
4624 # in the source dir.
4625
4626   in_src="gnulib"
4627   in_build="build-gnulib"
4628
4629   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
4630   # so they do not pile up.
4631   ac_sub_configure_args=
4632   ac_prev=
4633   eval "set x $ac_configure_args"
4634   shift
4635   for ac_arg
4636   do
4637     if test -n "$ac_prev"; then
4638       ac_prev=
4639       continue
4640     fi
4641     case $ac_arg in
4642     -cache-file | --cache-file | --cache-fil | --cache-fi \
4643     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
4644       ac_prev=cache_file ;;
4645     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
4646     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
4647     | --c=*)
4648       ;;
4649     --config-cache | -C)
4650       ;;
4651     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
4652       ac_prev=srcdir ;;
4653     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
4654       ;;
4655     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
4656       ac_prev=prefix ;;
4657     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
4658       ;;
4659     --disable-option-checking)
4660       ;;
4661     *)
4662       case $ac_arg in
4663       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
4664       esac
4665       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
4666     esac
4667   done
4668
4669   # Always prepend --prefix to ensure using the same prefix
4670   # in subdir configurations.
4671   ac_arg="--prefix=$prefix"
4672   case $ac_arg in
4673   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
4674   esac
4675   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
4676
4677   # Pass --silent
4678   if test "$silent" = yes; then
4679     ac_sub_configure_args="--silent $ac_sub_configure_args"
4680   fi
4681
4682   # Always prepend --disable-option-checking to silence warnings, since
4683   # different subdirs can have different --enable and --with options.
4684   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
4685
4686   ac_popdir=`pwd`
4687   ac_dir=$in_build
4688
4689   ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
4690   $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
4691   $as_echo "$ac_msg" >&6
4692   as_dir="$ac_dir"; as_fn_mkdir_p
4693
4694   case $srcdir in
4695   [\\/]* | ?:[\\/]* )
4696     ac_srcdir=$srcdir/$in_src ;;
4697   *) # Relative name.
4698     ac_srcdir=../$srcdir/$in_src ;;
4699   esac
4700
4701   cd "$ac_dir"
4702
4703   ac_sub_configure=$ac_srcdir/configure
4704
4705   # Make the cache file name correct relative to the subdirectory.
4706   case $cache_file in
4707   [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
4708   *) # Relative name.
4709     ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
4710   esac
4711
4712   { $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
4713 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
4714   # The eval makes quoting arguments work.
4715   eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
4716        --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
4717     as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
4718
4719   cd "$ac_popdir"
4720
4721
4722
4723 CONFIG_OBS=
4724 CONFIG_DEPS=
4725 CONFIG_SRCS=
4726 ENABLE_CFLAGS=
4727
4728 CONFIG_ALL=
4729 CONFIG_CLEAN=
4730 CONFIG_INSTALL=
4731 CONFIG_UNINSTALL=
4732
4733 # If we haven't got the data from the intl directory,
4734 # assume NLS is disabled.
4735 USE_NLS=no
4736 LIBINTL=
4737 LIBINTL_DEP=
4738 INCINTL=
4739 XGETTEXT=
4740 GMSGFMT=
4741 POSUB=
4742
4743 if test -f  ../intl/config.intl; then
4744   .  ../intl/config.intl
4745 fi
4746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
4747 $as_echo_n "checking whether NLS is requested... " >&6; }
4748 if test x"$USE_NLS" != xyes; then
4749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4750 $as_echo "no" >&6; }
4751 else
4752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4753 $as_echo "yes" >&6; }
4754
4755 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
4756
4757
4758   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
4759 $as_echo_n "checking for catalogs to be installed... " >&6; }
4760   # Look for .po and .gmo files in the source directory.
4761   CATALOGS=
4762   XLINGUAS=
4763   for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
4764     # If there aren't any .gmo files the shell will give us the
4765     # literal string "../path/to/srcdir/po/*.gmo" which has to be
4766     # weeded out.
4767     case "$cat" in *\**)
4768       continue;;
4769     esac
4770     # The quadruple backslash is collapsed to a double backslash
4771     # by the backticks, then collapsed again by the double quotes,
4772     # leaving us with one backslash in the sed expression (right
4773     # before the dot that mustn't act as a wildcard).
4774     cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
4775     lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
4776     # The user is allowed to set LINGUAS to a list of languages to
4777     # install catalogs for.  If it's empty that means "all of them."
4778     if test "x$LINGUAS" = x; then
4779       CATALOGS="$CATALOGS $cat"
4780       XLINGUAS="$XLINGUAS $lang"
4781     else
4782       case "$LINGUAS" in *$lang*)
4783         CATALOGS="$CATALOGS $cat"
4784         XLINGUAS="$XLINGUAS $lang"
4785         ;;
4786       esac
4787     fi
4788   done
4789   LINGUAS="$XLINGUAS"
4790   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
4791 $as_echo "$LINGUAS" >&6; }
4792
4793
4794     DATADIRNAME=share
4795
4796   INSTOBJEXT=.mo
4797
4798   GENCAT=gencat
4799
4800   CATOBJEXT=.gmo
4801
4802 fi
4803
4804 localedir='${datadir}/locale'
4805
4806
4807 if test x"$USE_NLS" = xyes; then
4808    CONFIG_ALL="$CONFIG_ALL all-po"
4809    CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
4810    CONFIG_INSTALL="$CONFIG_INSTALL install-po"
4811    CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
4812 fi
4813
4814 GNULIB=build-gnulib/import
4815
4816 # For Makefile dependencies.
4817 GNULIB_STDINT_H=
4818 if test x"$STDINT_H" != x; then
4819   GNULIB_STDINT_H=$GNULIB/$STDINT_H
4820 fi
4821
4822
4823 PACKAGE=gdb
4824
4825 cat >>confdefs.h <<_ACEOF
4826 #define PACKAGE "$PACKAGE"
4827 _ACEOF
4828
4829
4830
4831 # We never need to detect it in this sub-configure.
4832 # But preserve it for config.status --recheck.
4833
4834
4835
4836 MAKEINFO_EXTRA_FLAGS=""
4837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
4838 $as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
4839 if test "${gdb_cv_have_makeinfo_click+set}" = set; then :
4840   $as_echo_n "(cached) " >&6
4841 else
4842   echo '@clicksequence{a @click{} b}' >conftest.texinfo
4843   if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
4844     gdb_cv_have_makeinfo_click=yes
4845   else
4846     gdb_cv_have_makeinfo_click=no
4847   fi
4848 fi
4849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
4850 $as_echo "$gdb_cv_have_makeinfo_click" >&6; }
4851 if test x"$gdb_cv_have_makeinfo_click" = xyes; then
4852   MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
4853 fi
4854
4855
4856
4857
4858 # Check whether --with-separate-debug-dir was given.
4859 if test "${with_separate_debug_dir+set}" = set; then :
4860   withval=$with_separate_debug_dir;
4861     DEBUGDIR=$withval
4862 else
4863   DEBUGDIR=${libdir}/debug
4864 fi
4865
4866
4867   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4868   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4869   ac_define_dir=`eval echo $DEBUGDIR`
4870   ac_define_dir=`eval echo $ac_define_dir`
4871
4872 cat >>confdefs.h <<_ACEOF
4873 #define DEBUGDIR "$ac_define_dir"
4874 _ACEOF
4875
4876
4877
4878
4879   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
4880      if test "x$prefix" = xNONE; then
4881         test_prefix=/usr/local
4882      else
4883         test_prefix=$prefix
4884      fi
4885   else
4886      test_prefix=$exec_prefix
4887   fi
4888   value=0
4889   case ${ac_define_dir} in
4890      "${test_prefix}"|"${test_prefix}/"*|\
4891         '${exec_prefix}'|'${exec_prefix}/'*)
4892      value=1
4893      ;;
4894   esac
4895
4896 cat >>confdefs.h <<_ACEOF
4897 #define DEBUGDIR_RELOCATABLE $value
4898 _ACEOF
4899
4900
4901
4902
4903 # We can't pass paths as command line arguments.
4904 # Mingw32 tries to be clever and will convert the paths for us.
4905 # For example -DBINDIR="/usr/local/bin" passed on the command line may get
4906 # converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
4907 # This breaks GDB's relocatable path conversions since paths passed in
4908 # config.h would not get so translated, the path prefixes no longer match.
4909
4910   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4911   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4912   ac_define_dir=`eval echo $bindir`
4913   ac_define_dir=`eval echo $ac_define_dir`
4914
4915 cat >>confdefs.h <<_ACEOF
4916 #define BINDIR "$ac_define_dir"
4917 _ACEOF
4918
4919
4920
4921 # GDB's datadir relocation
4922
4923
4924
4925 # Check whether --with-gdb-datadir was given.
4926 if test "${with_gdb_datadir+set}" = set; then :
4927   withval=$with_gdb_datadir;
4928     GDB_DATADIR=$withval
4929 else
4930   GDB_DATADIR=${datadir}/gdb
4931 fi
4932
4933
4934   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4935   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4936   ac_define_dir=`eval echo $GDB_DATADIR`
4937   ac_define_dir=`eval echo $ac_define_dir`
4938
4939 cat >>confdefs.h <<_ACEOF
4940 #define GDB_DATADIR "$ac_define_dir"
4941 _ACEOF
4942
4943
4944
4945
4946   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
4947      if test "x$prefix" = xNONE; then
4948         test_prefix=/usr/local
4949      else
4950         test_prefix=$prefix
4951      fi
4952   else
4953      test_prefix=$exec_prefix
4954   fi
4955   value=0
4956   case ${ac_define_dir} in
4957      "${test_prefix}"|"${test_prefix}/"*|\
4958         '${exec_prefix}'|'${exec_prefix}/'*)
4959      value=1
4960      ;;
4961   esac
4962
4963 cat >>confdefs.h <<_ACEOF
4964 #define GDB_DATADIR_RELOCATABLE $value
4965 _ACEOF
4966
4967
4968
4969
4970
4971 # Check whether --with-relocated-sources was given.
4972 if test "${with_relocated_sources+set}" = set; then :
4973   withval=$with_relocated_sources; reloc_srcdir="${withval}"
4974
4975   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4976   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4977   ac_define_dir=`eval echo $reloc_srcdir`
4978   ac_define_dir=`eval echo $ac_define_dir`
4979
4980 cat >>confdefs.h <<_ACEOF
4981 #define RELOC_SRCDIR "$ac_define_dir"
4982 _ACEOF
4983
4984
4985
4986 fi
4987
4988
4989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
4990 $as_echo_n "checking for default auto-load directory... " >&6; }
4991
4992 # Check whether --with-auto-load-dir was given.
4993 if test "${with_auto_load_dir+set}" = set; then :
4994   withval=$with_auto_load_dir;
4995 else
4996   with_auto_load_dir='$debugdir:$datadir/auto-load'
4997 fi
4998
4999 escape_dir=`echo $with_auto_load_dir | sed 's/[$]\(datadir\|debugdir\)\>/\\\\\\\\\\\\&/g'`
5000
5001   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
5002   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5003   ac_define_dir=`eval echo $escape_dir`
5004   ac_define_dir=`eval echo $ac_define_dir`
5005
5006 cat >>confdefs.h <<_ACEOF
5007 #define AUTO_LOAD_DIR "$ac_define_dir"
5008 _ACEOF
5009
5010
5011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
5012 $as_echo "$with_auto_load_dir" >&6; }
5013
5014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
5015 $as_echo_n "checking for default auto-load safe-path... " >&6; }
5016
5017 # Check whether --with-auto-load-safe-path was given.
5018 if test "${with_auto_load_safe_path+set}" = set; then :
5019   withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
5020      with_auto_load_safe_path="/"
5021      fi
5022 else
5023   with_auto_load_safe_path="$with_auto_load_dir"
5024 fi
5025
5026 escape_dir=`echo $with_auto_load_safe_path | sed 's/[$]\(datadir\|debugdir\)\>/\\\\\\\\\\\\&/g'`
5027
5028   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
5029   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5030   ac_define_dir=`eval echo $escape_dir`
5031   ac_define_dir=`eval echo $ac_define_dir`
5032
5033 cat >>confdefs.h <<_ACEOF
5034 #define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
5035 _ACEOF
5036
5037
5038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
5039 $as_echo "$with_auto_load_safe_path" >&6; }
5040
5041
5042
5043 subdirs="$subdirs testsuite"
5044
5045
5046 # Check whether to support alternative target configurations
5047 # Check whether --enable-targets was given.
5048 if test "${enable_targets+set}" = set; then :
5049   enableval=$enable_targets; case "${enableval}" in
5050   yes | "") as_fn_error "enable-targets option must specify target names or 'all'" "$LINENO" 5
5051             ;;
5052   no)       enable_targets= ;;
5053   *)        enable_targets=$enableval ;;
5054 esac
5055 fi
5056
5057
5058 # Check whether to enable 64-bit support on 32-bit hosts
5059 # Check whether --enable-64-bit-bfd was given.
5060 if test "${enable_64_bit_bfd+set}" = set; then :
5061   enableval=$enable_64_bit_bfd; case "${enableval}" in
5062   yes)  want64=true  ;;
5063   no)   want64=false ;;
5064   *)    as_fn_error "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
5065 esac
5066 else
5067   want64=false
5068 fi
5069
5070 # Provide defaults for some variables set by the per-host and per-target
5071 # configuration.
5072 gdb_host_obs=posix-hdep.o
5073
5074 if test "${target}" = "${host}"; then
5075   gdb_native=yes
5076 else
5077   gdb_native=no
5078 fi
5079
5080 . $srcdir/configure.host
5081
5082 # Accumulate some settings from configure.tgt over all enabled targets
5083
5084 TARGET_OBS=
5085 all_targets=
5086
5087 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
5088 do
5089   if test "$targ_alias" = "all"; then
5090     all_targets=true
5091   else
5092     # Canonicalize the secondary target names.
5093     result=`$ac_config_sub $targ_alias 2>/dev/null`
5094     if test -n "$result"; then
5095         targ=$result
5096     else
5097         targ=$targ_alias
5098     fi
5099
5100     . ${srcdir}/configure.tgt
5101
5102     if test -z "${gdb_target_obs}"; then :
5103   as_fn_error "configuration ${targ} is unsupported." "$LINENO" 5
5104 fi
5105
5106     # Target-specific object files
5107     for i in ${gdb_target_obs}; do
5108         case " $TARGET_OBS " in
5109         *" ${i} "*) ;;
5110         *)
5111           TARGET_OBS="$TARGET_OBS ${i}"
5112           ;;
5113         esac
5114     done
5115
5116     # Check whether this target needs 64-bit CORE_ADDR
5117     if test x${want64} = xfalse; then
5118       . ${srcdir}/../bfd/config.bfd
5119     fi
5120   fi
5121 done
5122
5123 if test x${all_targets} = xtrue; then
5124
5125   # We want all 64-bit targets if we either:
5126   #  - run on a 64-bit host  or
5127   #  - already require 64-bit support for some other target  or
5128   #  - the --enable-64-bit-bfd option was supplied
5129   # Otherwise we only support all 32-bit targets.
5130   #
5131   # NOTE: This test must be in sync with the corresponding
5132   #       tests in BFD!
5133
5134   if test x${want64} = xfalse; then
5135     # The cast to long int works around a bug in the HP C Compiler
5136 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5137 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5138 # This bug is HP SR number 8606223364.
5139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
5140 $as_echo_n "checking size of long... " >&6; }
5141 if test "${ac_cv_sizeof_long+set}" = set; then :
5142   $as_echo_n "(cached) " >&6
5143 else
5144   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
5145
5146 else
5147   if test "$ac_cv_type_long" = yes; then
5148      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5149 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5150 { as_fn_set_status 77
5151 as_fn_error "cannot compute sizeof (long)
5152 See \`config.log' for more details." "$LINENO" 5; }; }
5153    else
5154      ac_cv_sizeof_long=0
5155    fi
5156 fi
5157
5158 fi
5159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
5160 $as_echo "$ac_cv_sizeof_long" >&6; }
5161
5162
5163
5164 cat >>confdefs.h <<_ACEOF
5165 #define SIZEOF_LONG $ac_cv_sizeof_long
5166 _ACEOF
5167
5168
5169     if test "x${ac_cv_sizeof_long}" = "x8"; then
5170       want64=true
5171     fi
5172   fi
5173   if test x${want64} = xtrue; then
5174     TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
5175   else
5176     TARGET_OBS='$(ALL_TARGET_OBS)'
5177   fi
5178 fi
5179
5180
5181
5182 # For other settings, only the main target counts.
5183 gdb_sim=
5184 gdb_osabi=
5185 build_gdbserver=
5186 targ=$target; . ${srcdir}/configure.tgt
5187
5188 # Fetch the default architecture and default target vector from BFD.
5189 targ=$target; . $srcdir/../bfd/config.bfd
5190
5191 # We only want the first architecture, so strip off the others if
5192 # there is more than one.
5193 targ_archs=`echo $targ_archs | sed 's/ .*//'`
5194
5195 if test "x$targ_archs" != x; then
5196
5197 cat >>confdefs.h <<_ACEOF
5198 #define DEFAULT_BFD_ARCH $targ_archs
5199 _ACEOF
5200
5201 fi
5202 if test "x$targ_defvec" != x; then
5203
5204 cat >>confdefs.h <<_ACEOF
5205 #define DEFAULT_BFD_VEC $targ_defvec
5206 _ACEOF
5207
5208 fi
5209
5210 # The CLI cannot be disabled yet, but may be in the future.
5211
5212 # Enable CLI.
5213 # Check whether --enable-gdbcli was given.
5214 if test "${enable_gdbcli+set}" = set; then :
5215   enableval=$enable_gdbcli; case $enableval in
5216     yes)
5217       ;;
5218     no)
5219       as_fn_error "the command-line interface cannot be disabled yet" "$LINENO" 5 ;;
5220     *)
5221       as_fn_error "bad value $enableval for --enable-gdbcli" "$LINENO" 5 ;;
5222   esac
5223 else
5224   enable_gdbcli=yes
5225 fi
5226
5227 if test x"$enable_gdbcli" = xyes; then
5228   if test -d $srcdir/cli; then
5229     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_CLI_OBS)"
5230     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_CLI_DEPS)"
5231     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_CLI_SRCS)"
5232     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_CLI_CFLAGS)"
5233   fi
5234 fi
5235
5236 # Enable MI.
5237 # Check whether --enable-gdbmi was given.
5238 if test "${enable_gdbmi+set}" = set; then :
5239   enableval=$enable_gdbmi; case $enableval in
5240     yes | no)
5241       ;;
5242     *)
5243       as_fn_error "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
5244   esac
5245 else
5246   enable_gdbmi=yes
5247 fi
5248
5249 if test x"$enable_gdbmi" = xyes; then
5250   if test -d $srcdir/mi; then
5251     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
5252     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
5253     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
5254     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
5255   fi
5256 fi
5257
5258 # Enable TUI.
5259 # Check whether --enable-tui was given.
5260 if test "${enable_tui+set}" = set; then :
5261   enableval=$enable_tui; case $enableval in
5262     yes | no | auto)
5263       ;;
5264     *)
5265       as_fn_error "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
5266   esac
5267 else
5268   enable_tui=auto
5269 fi
5270
5271
5272 # Enable gdbtk.
5273 # Check whether --enable-gdbtk was given.
5274 if test "${enable_gdbtk+set}" = set; then :
5275   enableval=$enable_gdbtk; case $enableval in
5276     yes | no)
5277       ;;
5278     *)
5279       as_fn_error "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
5280   esac
5281 else
5282   if test -d $srcdir/gdbtk; then
5283     enable_gdbtk=yes
5284   else
5285     enable_gdbtk=no
5286   fi
5287 fi
5288
5289 # We unconditionally disable gdbtk tests on selected platforms.
5290 case $host_os in
5291   go32* | windows*)
5292     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
5293 $as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
5294     enable_gdbtk=no ;;
5295 esac
5296
5297 # Libunwind support for ia64.
5298
5299
5300 # Check whether --with-libunwind-ia64 was given.
5301 if test "${with_libunwind_ia64+set}" = set; then :
5302   withval=$with_libunwind_ia64;
5303 else
5304   with_libunwind_ia64=auto
5305 fi
5306
5307
5308 # Backward compatibility option.
5309 if test "${with_libunwind+set}" = set; then
5310   if test x"$with_libunwind_ia64" != xauto; then
5311     as_fn_error "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
5312   fi
5313   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
5314 $as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
5315   with_libunwind_ia64="$with_libunwind"
5316 fi
5317
5318 case "$with_libunwind_ia64" in
5319   yes | no)
5320     ;;
5321   auto)
5322     for ac_header in libunwind-ia64.h
5323 do :
5324   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
5325 if test "x$ac_cv_header_libunwind_ia64_h" = x""yes; then :
5326   cat >>confdefs.h <<_ACEOF
5327 #define HAVE_LIBUNWIND_IA64_H 1
5328 _ACEOF
5329
5330 fi
5331
5332 done
5333
5334     with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
5335     ;;
5336   *)
5337     as_fn_error "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
5338     ;;
5339 esac
5340
5341 if test x"$with_libunwind_ia64" = xyes; then
5342   for ac_header in libunwind-ia64.h
5343 do :
5344   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
5345 if test "x$ac_cv_header_libunwind_ia64_h" = x""yes; then :
5346   cat >>confdefs.h <<_ACEOF
5347 #define HAVE_LIBUNWIND_IA64_H 1
5348 _ACEOF
5349
5350 fi
5351
5352 done
5353
5354   if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
5355     as_fn_error "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
5356   fi
5357   CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
5358   CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
5359   CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
5360 fi
5361
5362 opt_curses=no
5363
5364 # Check whether --with-curses was given.
5365 if test "${with_curses+set}" = set; then :
5366   withval=$with_curses; opt_curses=$withval
5367 fi
5368
5369
5370 prefer_curses=no
5371 if test "$opt_curses" = "yes"; then
5372   prefer_curses=yes
5373 fi
5374
5375 # Profiling support.
5376 # Check whether --enable-profiling was given.
5377 if test "${enable_profiling+set}" = set; then :
5378   enableval=$enable_profiling; case $enableval in
5379     yes | no)
5380       ;;
5381     *)
5382       as_fn_error "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
5383   esac
5384 else
5385   enable_profiling=no
5386 fi
5387
5388
5389 for ac_func in monstartup _mcleanup
5390 do :
5391   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
5392 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
5393 eval as_val=\$$as_ac_var
5394    if test "x$as_val" = x""yes; then :
5395   cat >>confdefs.h <<_ACEOF
5396 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
5397 _ACEOF
5398
5399 fi
5400 done
5401
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
5403 $as_echo_n "checking for _etext... " >&6; }
5404 if test "${ac_cv_var__etext+set}" = set; then :
5405   $as_echo_n "(cached) " >&6
5406 else
5407   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5408 /* end confdefs.h.  */
5409 #include <stdlib.h>
5410 extern char _etext;
5411
5412 int
5413 main ()
5414 {
5415 free (&_etext);
5416   ;
5417   return 0;
5418 }
5419 _ACEOF
5420 if ac_fn_c_try_link "$LINENO"; then :
5421   ac_cv_var__etext=yes
5422 else
5423   ac_cv_var__etext=no
5424 fi
5425 rm -f core conftest.err conftest.$ac_objext \
5426     conftest$ac_exeext conftest.$ac_ext
5427 fi
5428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
5429 $as_echo "$ac_cv_var__etext" >&6; }
5430 if test $ac_cv_var__etext = yes; then
5431
5432 $as_echo "#define HAVE__ETEXT 1" >>confdefs.h
5433
5434 fi
5435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
5436 $as_echo_n "checking for etext... " >&6; }
5437 if test "${ac_cv_var_etext+set}" = set; then :
5438   $as_echo_n "(cached) " >&6
5439 else
5440   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5441 /* end confdefs.h.  */
5442 #include <stdlib.h>
5443 extern char etext;
5444
5445 int
5446 main ()
5447 {
5448 free (&etext);
5449   ;
5450   return 0;
5451 }
5452 _ACEOF
5453 if ac_fn_c_try_link "$LINENO"; then :
5454   ac_cv_var_etext=yes
5455 else
5456   ac_cv_var_etext=no
5457 fi
5458 rm -f core conftest.err conftest.$ac_objext \
5459     conftest$ac_exeext conftest.$ac_ext
5460 fi
5461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
5462 $as_echo "$ac_cv_var_etext" >&6; }
5463 if test $ac_cv_var_etext = yes; then
5464
5465 $as_echo "#define HAVE_ETEXT 1" >>confdefs.h
5466
5467 fi
5468 if test "$enable_profiling" = yes ; then
5469   if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
5470     as_fn_error "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
5471   fi
5472   PROFILE_CFLAGS=-pg
5473   OLD_CFLAGS="$CFLAGS"
5474   CFLAGS="$CFLAGS $PROFILE_CFLAGS"
5475
5476   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
5477 $as_echo_n "checking whether $CC supports -pg... " >&6; }
5478 if test "${ac_cv_cc_supports_pg+set}" = set; then :
5479   $as_echo_n "(cached) " >&6
5480 else
5481   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5482 /* end confdefs.h.  */
5483
5484 int
5485 main ()
5486 {
5487 int x;
5488   ;
5489   return 0;
5490 }
5491 _ACEOF
5492 if ac_fn_c_try_compile "$LINENO"; then :
5493   ac_cv_cc_supports_pg=yes
5494 else
5495   ac_cv_cc_supports_pg=no
5496 fi
5497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5498 fi
5499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
5500 $as_echo "$ac_cv_cc_supports_pg" >&6; }
5501
5502   if test $ac_cv_cc_supports_pg = no; then
5503     as_fn_error "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
5504   fi
5505
5506   CFLAGS="$OLD_CFLAGS"
5507 fi
5508
5509
5510
5511 # Check whether --with-pkgversion was given.
5512 if test "${with_pkgversion+set}" = set; then :
5513   withval=$with_pkgversion; case "$withval" in
5514       yes) as_fn_error "package version not specified" "$LINENO" 5 ;;
5515       no)  PKGVERSION= ;;
5516       *)   PKGVERSION="($withval) " ;;
5517      esac
5518 else
5519   PKGVERSION="(GDB) "
5520
5521 fi
5522
5523
5524
5525
5526
5527 # Check whether --with-bugurl was given.
5528 if test "${with_bugurl+set}" = set; then :
5529   withval=$with_bugurl; case "$withval" in
5530       yes) as_fn_error "bug URL not specified" "$LINENO" 5 ;;
5531       no)  BUGURL=
5532            ;;
5533       *)   BUGURL="$withval"
5534            ;;
5535      esac
5536 else
5537   BUGURL="http://www.gnu.org/software/gdb/bugs/"
5538
5539 fi
5540
5541   case ${BUGURL} in
5542   "")
5543     REPORT_BUGS_TO=
5544     REPORT_BUGS_TEXI=
5545     ;;
5546   *)
5547     REPORT_BUGS_TO="<$BUGURL>"
5548     REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
5549     ;;
5550   esac;
5551
5552
5553
5554
5555 cat >>confdefs.h <<_ACEOF
5556 #define PKGVERSION "$PKGVERSION"
5557 _ACEOF
5558
5559
5560 cat >>confdefs.h <<_ACEOF
5561 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
5562 _ACEOF
5563
5564
5565 # --------------------- #
5566 # Checks for programs.  #
5567 # --------------------- #
5568
5569 for ac_prog in gawk mawk nawk awk
5570 do
5571   # Extract the first word of "$ac_prog", so it can be a program name with args.
5572 set dummy $ac_prog; ac_word=$2
5573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5574 $as_echo_n "checking for $ac_word... " >&6; }
5575 if test "${ac_cv_prog_AWK+set}" = set; then :
5576   $as_echo_n "(cached) " >&6
5577 else
5578   if test -n "$AWK"; then
5579   ac_cv_prog_AWK="$AWK" # Let the user override the test.
5580 else
5581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5582 for as_dir in $PATH
5583 do
5584   IFS=$as_save_IFS
5585   test -z "$as_dir" && as_dir=.
5586     for ac_exec_ext in '' $ac_executable_extensions; do
5587   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5588     ac_cv_prog_AWK="$ac_prog"
5589     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5590     break 2
5591   fi
5592 done
5593   done
5594 IFS=$as_save_IFS
5595
5596 fi
5597 fi
5598 AWK=$ac_cv_prog_AWK
5599 if test -n "$AWK"; then
5600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
5601 $as_echo "$AWK" >&6; }
5602 else
5603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5604 $as_echo "no" >&6; }
5605 fi
5606
5607
5608   test -n "$AWK" && break
5609 done
5610
5611 # Find a good install program.  We prefer a C program (faster),
5612 # so one script is as good as another.  But avoid the broken or
5613 # incompatible versions:
5614 # SysV /etc/install, /usr/sbin/install
5615 # SunOS /usr/etc/install
5616 # IRIX /sbin/install
5617 # AIX /bin/install
5618 # AmigaOS /C/install, which installs bootblocks on floppy discs
5619 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
5620 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
5621 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
5622 # OS/2's system install, which has a completely different semantic
5623 # ./install, which can be erroneously created by make from ./install.sh.
5624 # Reject install programs that cannot install multiple files.
5625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
5626 $as_echo_n "checking for a BSD-compatible install... " >&6; }
5627 if test -z "$INSTALL"; then
5628 if test "${ac_cv_path_install+set}" = set; then :
5629   $as_echo_n "(cached) " >&6
5630 else
5631   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5632 for as_dir in $PATH
5633 do
5634   IFS=$as_save_IFS
5635   test -z "$as_dir" && as_dir=.
5636     # Account for people who put trailing slashes in PATH elements.
5637 case $as_dir/ in #((
5638   ./ | .// | /[cC]/* | \
5639   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5640   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
5641   /usr/ucb/* ) ;;
5642   *)
5643     # OSF1 and SCO ODT 3.0 have their own names for install.
5644     # Don't use installbsd from OSF since it installs stuff as root
5645     # by default.
5646     for ac_prog in ginstall scoinst install; do
5647       for ac_exec_ext in '' $ac_executable_extensions; do
5648         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
5649           if test $ac_prog = install &&
5650             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5651             # AIX install.  It has an incompatible calling convention.
5652             :
5653           elif test $ac_prog = install &&
5654             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5655             # program-specific install script used by HP pwplus--don't use.
5656             :
5657           else
5658             rm -rf conftest.one conftest.two conftest.dir
5659             echo one > conftest.one
5660             echo two > conftest.two
5661             mkdir conftest.dir
5662             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5663               test -s conftest.one && test -s conftest.two &&
5664               test -s conftest.dir/conftest.one &&
5665               test -s conftest.dir/conftest.two
5666             then
5667               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5668               break 3
5669             fi
5670           fi
5671         fi
5672       done
5673     done
5674     ;;
5675 esac
5676
5677   done
5678 IFS=$as_save_IFS
5679
5680 rm -rf conftest.one conftest.two conftest.dir
5681
5682 fi
5683   if test "${ac_cv_path_install+set}" = set; then
5684     INSTALL=$ac_cv_path_install
5685   else
5686     # As a last resort, use the slow shell script.  Don't cache a
5687     # value for INSTALL within a source directory, because that will
5688     # break other packages using the cache if that directory is
5689     # removed, or if the value is a relative name.
5690     INSTALL=$ac_install_sh
5691   fi
5692 fi
5693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5694 $as_echo "$INSTALL" >&6; }
5695
5696 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5697 # It thinks the first close brace ends the variable substitution.
5698 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5699
5700 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5701
5702 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5703
5704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5705 $as_echo_n "checking whether ln -s works... " >&6; }
5706 LN_S=$as_ln_s
5707 if test "$LN_S" = "ln -s"; then
5708   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5709 $as_echo "yes" >&6; }
5710 else
5711   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5712 $as_echo "no, using $LN_S" >&6; }
5713 fi
5714
5715 if test -n "$ac_tool_prefix"; then
5716   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5717 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5719 $as_echo_n "checking for $ac_word... " >&6; }
5720 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5721   $as_echo_n "(cached) " >&6
5722 else
5723   if test -n "$RANLIB"; then
5724   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5725 else
5726 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5727 for as_dir in $PATH
5728 do
5729   IFS=$as_save_IFS
5730   test -z "$as_dir" && as_dir=.
5731     for ac_exec_ext in '' $ac_executable_extensions; do
5732   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5733     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5734     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5735     break 2
5736   fi
5737 done
5738   done
5739 IFS=$as_save_IFS
5740
5741 fi
5742 fi
5743 RANLIB=$ac_cv_prog_RANLIB
5744 if test -n "$RANLIB"; then
5745   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5746 $as_echo "$RANLIB" >&6; }
5747 else
5748   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5749 $as_echo "no" >&6; }
5750 fi
5751
5752
5753 fi
5754 if test -z "$ac_cv_prog_RANLIB"; then
5755   ac_ct_RANLIB=$RANLIB
5756   # Extract the first word of "ranlib", so it can be a program name with args.
5757 set dummy ranlib; ac_word=$2
5758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5759 $as_echo_n "checking for $ac_word... " >&6; }
5760 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5761   $as_echo_n "(cached) " >&6
5762 else
5763   if test -n "$ac_ct_RANLIB"; then
5764   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5765 else
5766 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5767 for as_dir in $PATH
5768 do
5769   IFS=$as_save_IFS
5770   test -z "$as_dir" && as_dir=.
5771     for ac_exec_ext in '' $ac_executable_extensions; do
5772   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5773     ac_cv_prog_ac_ct_RANLIB="ranlib"
5774     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5775     break 2
5776   fi
5777 done
5778   done
5779 IFS=$as_save_IFS
5780
5781 fi
5782 fi
5783 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5784 if test -n "$ac_ct_RANLIB"; then
5785   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5786 $as_echo "$ac_ct_RANLIB" >&6; }
5787 else
5788   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5789 $as_echo "no" >&6; }
5790 fi
5791
5792   if test "x$ac_ct_RANLIB" = x; then
5793     RANLIB=":"
5794   else
5795     case $cross_compiling:$ac_tool_warned in
5796 yes:)
5797 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5798 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5799 ac_tool_warned=yes ;;
5800 esac
5801     RANLIB=$ac_ct_RANLIB
5802   fi
5803 else
5804   RANLIB="$ac_cv_prog_RANLIB"
5805 fi
5806
5807 for ac_prog in 'bison -y' byacc
5808 do
5809   # Extract the first word of "$ac_prog", so it can be a program name with args.
5810 set dummy $ac_prog; ac_word=$2
5811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5812 $as_echo_n "checking for $ac_word... " >&6; }
5813 if test "${ac_cv_prog_YACC+set}" = set; then :
5814   $as_echo_n "(cached) " >&6
5815 else
5816   if test -n "$YACC"; then
5817   ac_cv_prog_YACC="$YACC" # Let the user override the test.
5818 else
5819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5820 for as_dir in $PATH
5821 do
5822   IFS=$as_save_IFS
5823   test -z "$as_dir" && as_dir=.
5824     for ac_exec_ext in '' $ac_executable_extensions; do
5825   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5826     ac_cv_prog_YACC="$ac_prog"
5827     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5828     break 2
5829   fi
5830 done
5831   done
5832 IFS=$as_save_IFS
5833
5834 fi
5835 fi
5836 YACC=$ac_cv_prog_YACC
5837 if test -n "$YACC"; then
5838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
5839 $as_echo "$YACC" >&6; }
5840 else
5841   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5842 $as_echo "no" >&6; }
5843 fi
5844
5845
5846   test -n "$YACC" && break
5847 done
5848 test -n "$YACC" || YACC="yacc"
5849
5850
5851 if test -n "$ac_tool_prefix"; then
5852   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5853 set dummy ${ac_tool_prefix}ar; ac_word=$2
5854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5855 $as_echo_n "checking for $ac_word... " >&6; }
5856 if test "${ac_cv_prog_AR+set}" = set; then :
5857   $as_echo_n "(cached) " >&6
5858 else
5859   if test -n "$AR"; then
5860   ac_cv_prog_AR="$AR" # Let the user override the test.
5861 else
5862 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5863 for as_dir in $PATH
5864 do
5865   IFS=$as_save_IFS
5866   test -z "$as_dir" && as_dir=.
5867     for ac_exec_ext in '' $ac_executable_extensions; do
5868   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5869     ac_cv_prog_AR="${ac_tool_prefix}ar"
5870     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5871     break 2
5872   fi
5873 done
5874   done
5875 IFS=$as_save_IFS
5876
5877 fi
5878 fi
5879 AR=$ac_cv_prog_AR
5880 if test -n "$AR"; then
5881   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5882 $as_echo "$AR" >&6; }
5883 else
5884   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5885 $as_echo "no" >&6; }
5886 fi
5887
5888
5889 fi
5890 if test -z "$ac_cv_prog_AR"; then
5891   ac_ct_AR=$AR
5892   # Extract the first word of "ar", so it can be a program name with args.
5893 set dummy ar; ac_word=$2
5894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5895 $as_echo_n "checking for $ac_word... " >&6; }
5896 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
5897   $as_echo_n "(cached) " >&6
5898 else
5899   if test -n "$ac_ct_AR"; then
5900   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5901 else
5902 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5903 for as_dir in $PATH
5904 do
5905   IFS=$as_save_IFS
5906   test -z "$as_dir" && as_dir=.
5907     for ac_exec_ext in '' $ac_executable_extensions; do
5908   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5909     ac_cv_prog_ac_ct_AR="ar"
5910     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5911     break 2
5912   fi
5913 done
5914   done
5915 IFS=$as_save_IFS
5916
5917 fi
5918 fi
5919 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5920 if test -n "$ac_ct_AR"; then
5921   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5922 $as_echo "$ac_ct_AR" >&6; }
5923 else
5924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5925 $as_echo "no" >&6; }
5926 fi
5927
5928   if test "x$ac_ct_AR" = x; then
5929     AR=""
5930   else
5931     case $cross_compiling:$ac_tool_warned in
5932 yes:)
5933 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5934 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5935 ac_tool_warned=yes ;;
5936 esac
5937     AR=$ac_ct_AR
5938   fi
5939 else
5940   AR="$ac_cv_prog_AR"
5941 fi
5942
5943 if test -n "$ac_tool_prefix"; then
5944   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5945 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5947 $as_echo_n "checking for $ac_word... " >&6; }
5948 if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
5949   $as_echo_n "(cached) " >&6
5950 else
5951   if test -n "$DLLTOOL"; then
5952   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5953 else
5954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5955 for as_dir in $PATH
5956 do
5957   IFS=$as_save_IFS
5958   test -z "$as_dir" && as_dir=.
5959     for ac_exec_ext in '' $ac_executable_extensions; do
5960   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5961     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5962     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5963     break 2
5964   fi
5965 done
5966   done
5967 IFS=$as_save_IFS
5968
5969 fi
5970 fi
5971 DLLTOOL=$ac_cv_prog_DLLTOOL
5972 if test -n "$DLLTOOL"; then
5973   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
5974 $as_echo "$DLLTOOL" >&6; }
5975 else
5976   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5977 $as_echo "no" >&6; }
5978 fi
5979
5980
5981 fi
5982 if test -z "$ac_cv_prog_DLLTOOL"; then
5983   ac_ct_DLLTOOL=$DLLTOOL
5984   # Extract the first word of "dlltool", so it can be a program name with args.
5985 set dummy dlltool; ac_word=$2
5986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5987 $as_echo_n "checking for $ac_word... " >&6; }
5988 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
5989   $as_echo_n "(cached) " >&6
5990 else
5991   if test -n "$ac_ct_DLLTOOL"; then
5992   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5993 else
5994 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5995 for as_dir in $PATH
5996 do
5997   IFS=$as_save_IFS
5998   test -z "$as_dir" && as_dir=.
5999     for ac_exec_ext in '' $ac_executable_extensions; do
6000   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6001     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6002     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6003     break 2
6004   fi
6005 done
6006   done
6007 IFS=$as_save_IFS
6008
6009 fi
6010 fi
6011 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6012 if test -n "$ac_ct_DLLTOOL"; then
6013   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
6014 $as_echo "$ac_ct_DLLTOOL" >&6; }
6015 else
6016   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6017 $as_echo "no" >&6; }
6018 fi
6019
6020   if test "x$ac_ct_DLLTOOL" = x; then
6021     DLLTOOL=""
6022   else
6023     case $cross_compiling:$ac_tool_warned in
6024 yes:)
6025 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6026 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6027 ac_tool_warned=yes ;;
6028 esac
6029     DLLTOOL=$ac_ct_DLLTOOL
6030   fi
6031 else
6032   DLLTOOL="$ac_cv_prog_DLLTOOL"
6033 fi
6034
6035 if test -n "$ac_tool_prefix"; then
6036   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6037 set dummy ${ac_tool_prefix}windres; ac_word=$2
6038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6039 $as_echo_n "checking for $ac_word... " >&6; }
6040 if test "${ac_cv_prog_WINDRES+set}" = set; then :
6041   $as_echo_n "(cached) " >&6
6042 else
6043   if test -n "$WINDRES"; then
6044   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6045 else
6046 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6047 for as_dir in $PATH
6048 do
6049   IFS=$as_save_IFS
6050   test -z "$as_dir" && as_dir=.
6051     for ac_exec_ext in '' $ac_executable_extensions; do
6052   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6053     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6054     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6055     break 2
6056   fi
6057 done
6058   done
6059 IFS=$as_save_IFS
6060
6061 fi
6062 fi
6063 WINDRES=$ac_cv_prog_WINDRES
6064 if test -n "$WINDRES"; then
6065   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
6066 $as_echo "$WINDRES" >&6; }
6067 else
6068   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6069 $as_echo "no" >&6; }
6070 fi
6071
6072
6073 fi
6074 if test -z "$ac_cv_prog_WINDRES"; then
6075   ac_ct_WINDRES=$WINDRES
6076   # Extract the first word of "windres", so it can be a program name with args.
6077 set dummy windres; ac_word=$2
6078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6079 $as_echo_n "checking for $ac_word... " >&6; }
6080 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
6081   $as_echo_n "(cached) " >&6
6082 else
6083   if test -n "$ac_ct_WINDRES"; then
6084   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6085 else
6086 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6087 for as_dir in $PATH
6088 do
6089   IFS=$as_save_IFS
6090   test -z "$as_dir" && as_dir=.
6091     for ac_exec_ext in '' $ac_executable_extensions; do
6092   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6093     ac_cv_prog_ac_ct_WINDRES="windres"
6094     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6095     break 2
6096   fi
6097 done
6098   done
6099 IFS=$as_save_IFS
6100
6101 fi
6102 fi
6103 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6104 if test -n "$ac_ct_WINDRES"; then
6105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
6106 $as_echo "$ac_ct_WINDRES" >&6; }
6107 else
6108   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6109 $as_echo "no" >&6; }
6110 fi
6111
6112   if test "x$ac_ct_WINDRES" = x; then
6113     WINDRES=""
6114   else
6115     case $cross_compiling:$ac_tool_warned in
6116 yes:)
6117 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6118 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6119 ac_tool_warned=yes ;;
6120 esac
6121     WINDRES=$ac_ct_WINDRES
6122   fi
6123 else
6124   WINDRES="$ac_cv_prog_WINDRES"
6125 fi
6126
6127
6128 # Needed for GNU/Hurd.
6129 if test -n "$ac_tool_prefix"; then
6130   # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
6131 set dummy ${ac_tool_prefix}mig; ac_word=$2
6132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6133 $as_echo_n "checking for $ac_word... " >&6; }
6134 if test "${ac_cv_prog_MIG+set}" = set; then :
6135   $as_echo_n "(cached) " >&6
6136 else
6137   if test -n "$MIG"; then
6138   ac_cv_prog_MIG="$MIG" # Let the user override the test.
6139 else
6140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6141 for as_dir in $PATH
6142 do
6143   IFS=$as_save_IFS
6144   test -z "$as_dir" && as_dir=.
6145     for ac_exec_ext in '' $ac_executable_extensions; do
6146   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6147     ac_cv_prog_MIG="${ac_tool_prefix}mig"
6148     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6149     break 2
6150   fi
6151 done
6152   done
6153 IFS=$as_save_IFS
6154
6155 fi
6156 fi
6157 MIG=$ac_cv_prog_MIG
6158 if test -n "$MIG"; then
6159   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
6160 $as_echo "$MIG" >&6; }
6161 else
6162   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6163 $as_echo "no" >&6; }
6164 fi
6165
6166
6167 fi
6168 if test -z "$ac_cv_prog_MIG"; then
6169   ac_ct_MIG=$MIG
6170   # Extract the first word of "mig", so it can be a program name with args.
6171 set dummy mig; ac_word=$2
6172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6173 $as_echo_n "checking for $ac_word... " >&6; }
6174 if test "${ac_cv_prog_ac_ct_MIG+set}" = set; then :
6175   $as_echo_n "(cached) " >&6
6176 else
6177   if test -n "$ac_ct_MIG"; then
6178   ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
6179 else
6180 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6181 for as_dir in $PATH
6182 do
6183   IFS=$as_save_IFS
6184   test -z "$as_dir" && as_dir=.
6185     for ac_exec_ext in '' $ac_executable_extensions; do
6186   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6187     ac_cv_prog_ac_ct_MIG="mig"
6188     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6189     break 2
6190   fi
6191 done
6192   done
6193 IFS=$as_save_IFS
6194
6195 fi
6196 fi
6197 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
6198 if test -n "$ac_ct_MIG"; then
6199   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
6200 $as_echo "$ac_ct_MIG" >&6; }
6201 else
6202   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6203 $as_echo "no" >&6; }
6204 fi
6205
6206   if test "x$ac_ct_MIG" = x; then
6207     MIG=""
6208   else
6209     case $cross_compiling:$ac_tool_warned in
6210 yes:)
6211 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6212 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6213 ac_tool_warned=yes ;;
6214 esac
6215     MIG=$ac_ct_MIG
6216   fi
6217 else
6218   MIG="$ac_cv_prog_MIG"
6219 fi
6220
6221
6222 # ---------------------- #
6223 # Checks for libraries.  #
6224 # ---------------------- #
6225
6226 # We might need to link with -lm; most simulators need it.
6227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
6228 $as_echo_n "checking for main in -lm... " >&6; }
6229 if test "${ac_cv_lib_m_main+set}" = set; then :
6230   $as_echo_n "(cached) " >&6
6231 else
6232   ac_check_lib_save_LIBS=$LIBS
6233 LIBS="-lm  $LIBS"
6234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6235 /* end confdefs.h.  */
6236
6237
6238 int
6239 main ()
6240 {
6241 return main ();
6242   ;
6243   return 0;
6244 }
6245 _ACEOF
6246 if ac_fn_c_try_link "$LINENO"; then :
6247   ac_cv_lib_m_main=yes
6248 else
6249   ac_cv_lib_m_main=no
6250 fi
6251 rm -f core conftest.err conftest.$ac_objext \
6252     conftest$ac_exeext conftest.$ac_ext
6253 LIBS=$ac_check_lib_save_LIBS
6254 fi
6255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
6256 $as_echo "$ac_cv_lib_m_main" >&6; }
6257 if test "x$ac_cv_lib_m_main" = x""yes; then :
6258   cat >>confdefs.h <<_ACEOF
6259 #define HAVE_LIBM 1
6260 _ACEOF
6261
6262   LIBS="-lm $LIBS"
6263
6264 fi
6265
6266
6267 # We need to link with -lw to get `wctype' on Solaris before Solaris
6268 # 2.6.  Solaris 2.6 and beyond have this function in libc, and have a
6269 # libw that some versions of the GNU linker cannot hanle (GNU ld 2.9.1
6270 # is known to have this problem).  Therefore we avoid libw if we can.
6271 ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype"
6272 if test "x$ac_cv_func_wctype" = x""yes; then :
6273
6274 else
6275   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype in -lw" >&5
6276 $as_echo_n "checking for wctype in -lw... " >&6; }
6277 if test "${ac_cv_lib_w_wctype+set}" = set; then :
6278   $as_echo_n "(cached) " >&6
6279 else
6280   ac_check_lib_save_LIBS=$LIBS
6281 LIBS="-lw  $LIBS"
6282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6283 /* end confdefs.h.  */
6284
6285 /* Override any GCC internal prototype to avoid an error.
6286    Use char because int might match the return type of a GCC
6287    builtin and then its argument prototype would still apply.  */
6288 #ifdef __cplusplus
6289 extern "C"
6290 #endif
6291 char wctype ();
6292 int
6293 main ()
6294 {
6295 return wctype ();
6296   ;
6297   return 0;
6298 }
6299 _ACEOF
6300 if ac_fn_c_try_link "$LINENO"; then :
6301   ac_cv_lib_w_wctype=yes
6302 else
6303   ac_cv_lib_w_wctype=no
6304 fi
6305 rm -f core conftest.err conftest.$ac_objext \
6306     conftest$ac_exeext conftest.$ac_ext
6307 LIBS=$ac_check_lib_save_LIBS
6308 fi
6309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_w_wctype" >&5
6310 $as_echo "$ac_cv_lib_w_wctype" >&6; }
6311 if test "x$ac_cv_lib_w_wctype" = x""yes; then :
6312   cat >>confdefs.h <<_ACEOF
6313 #define HAVE_LIBW 1
6314 _ACEOF
6315
6316   LIBS="-lw $LIBS"
6317
6318 fi
6319
6320 fi
6321
6322
6323 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
6324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
6325 $as_echo_n "checking for library containing gethostbyname... " >&6; }
6326 if test "${ac_cv_search_gethostbyname+set}" = set; then :
6327   $as_echo_n "(cached) " >&6
6328 else
6329   ac_func_search_save_LIBS=$LIBS
6330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6331 /* end confdefs.h.  */
6332
6333 /* Override any GCC internal prototype to avoid an error.
6334    Use char because int might match the return type of a GCC
6335    builtin and then its argument prototype would still apply.  */
6336 #ifdef __cplusplus
6337 extern "C"
6338 #endif
6339 char gethostbyname ();
6340 int
6341 main ()
6342 {
6343 return gethostbyname ();
6344   ;
6345   return 0;
6346 }
6347 _ACEOF
6348 for ac_lib in '' nsl; do
6349   if test -z "$ac_lib"; then
6350     ac_res="none required"
6351   else
6352     ac_res=-l$ac_lib
6353     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6354   fi
6355   if ac_fn_c_try_link "$LINENO"; then :
6356   ac_cv_search_gethostbyname=$ac_res
6357 fi
6358 rm -f core conftest.err conftest.$ac_objext \
6359     conftest$ac_exeext
6360   if test "${ac_cv_search_gethostbyname+set}" = set; then :
6361   break
6362 fi
6363 done
6364 if test "${ac_cv_search_gethostbyname+set}" = set; then :
6365
6366 else
6367   ac_cv_search_gethostbyname=no
6368 fi
6369 rm conftest.$ac_ext
6370 LIBS=$ac_func_search_save_LIBS
6371 fi
6372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
6373 $as_echo "$ac_cv_search_gethostbyname" >&6; }
6374 ac_res=$ac_cv_search_gethostbyname
6375 if test "$ac_res" != no; then :
6376   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6377
6378 fi
6379
6380
6381 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
6382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
6383 $as_echo_n "checking for library containing socketpair... " >&6; }
6384 if test "${ac_cv_search_socketpair+set}" = set; then :
6385   $as_echo_n "(cached) " >&6
6386 else
6387   ac_func_search_save_LIBS=$LIBS
6388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6389 /* end confdefs.h.  */
6390
6391 /* Override any GCC internal prototype to avoid an error.
6392    Use char because int might match the return type of a GCC
6393    builtin and then its argument prototype would still apply.  */
6394 #ifdef __cplusplus
6395 extern "C"
6396 #endif
6397 char socketpair ();
6398 int
6399 main ()
6400 {
6401 return socketpair ();
6402   ;
6403   return 0;
6404 }
6405 _ACEOF
6406 for ac_lib in '' socket; do
6407   if test -z "$ac_lib"; then
6408     ac_res="none required"
6409   else
6410     ac_res=-l$ac_lib
6411     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6412   fi
6413   if ac_fn_c_try_link "$LINENO"; then :
6414   ac_cv_search_socketpair=$ac_res
6415 fi
6416 rm -f core conftest.err conftest.$ac_objext \
6417     conftest$ac_exeext
6418   if test "${ac_cv_search_socketpair+set}" = set; then :
6419   break
6420 fi
6421 done
6422 if test "${ac_cv_search_socketpair+set}" = set; then :
6423
6424 else
6425   ac_cv_search_socketpair=no
6426 fi
6427 rm conftest.$ac_ext
6428 LIBS=$ac_func_search_save_LIBS
6429 fi
6430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
6431 $as_echo "$ac_cv_search_socketpair" >&6; }
6432 ac_res=$ac_cv_search_socketpair
6433 if test "$ac_res" != no; then :
6434   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6435
6436 fi
6437
6438
6439 # Link in zlib if we can.  This allows us to read compressed debug sections.
6440
6441   # See if the user specified whether he wants zlib support or not.
6442
6443 # Check whether --with-zlib was given.
6444 if test "${with_zlib+set}" = set; then :
6445   withval=$with_zlib;
6446 else
6447   with_zlib=auto
6448 fi
6449
6450
6451   if test "$with_zlib" != "no"; then
6452     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing zlibVersion" >&5
6453 $as_echo_n "checking for library containing zlibVersion... " >&6; }
6454 if test "${ac_cv_search_zlibVersion+set}" = set; then :
6455   $as_echo_n "(cached) " >&6
6456 else
6457   ac_func_search_save_LIBS=$LIBS
6458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6459 /* end confdefs.h.  */
6460
6461 /* Override any GCC internal prototype to avoid an error.
6462    Use char because int might match the return type of a GCC
6463    builtin and then its argument prototype would still apply.  */
6464 #ifdef __cplusplus
6465 extern "C"
6466 #endif
6467 char zlibVersion ();
6468 int
6469 main ()
6470 {
6471 return zlibVersion ();
6472   ;
6473   return 0;
6474 }
6475 _ACEOF
6476 for ac_lib in '' z; do
6477   if test -z "$ac_lib"; then
6478     ac_res="none required"
6479   else
6480     ac_res=-l$ac_lib
6481     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6482   fi
6483   if ac_fn_c_try_link "$LINENO"; then :
6484   ac_cv_search_zlibVersion=$ac_res
6485 fi
6486 rm -f core conftest.err conftest.$ac_objext \
6487     conftest$ac_exeext
6488   if test "${ac_cv_search_zlibVersion+set}" = set; then :
6489   break
6490 fi
6491 done
6492 if test "${ac_cv_search_zlibVersion+set}" = set; then :
6493
6494 else
6495   ac_cv_search_zlibVersion=no
6496 fi
6497 rm conftest.$ac_ext
6498 LIBS=$ac_func_search_save_LIBS
6499 fi
6500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_zlibVersion" >&5
6501 $as_echo "$ac_cv_search_zlibVersion" >&6; }
6502 ac_res=$ac_cv_search_zlibVersion
6503 if test "$ac_res" != no; then :
6504   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6505   for ac_header in zlib.h
6506 do :
6507   ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
6508 if test "x$ac_cv_header_zlib_h" = x""yes; then :
6509   cat >>confdefs.h <<_ACEOF
6510 #define HAVE_ZLIB_H 1
6511 _ACEOF
6512
6513 fi
6514
6515 done
6516
6517 fi
6518
6519     if test "$with_zlib" = "yes" -a "$ac_cv_header_zlib_h" != "yes"; then
6520       as_fn_error "zlib (libz) library was explicitly requested but not found" "$LINENO" 5
6521     fi
6522   fi
6523
6524
6525 # On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
6526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlgetmodinfo" >&5
6527 $as_echo_n "checking for library containing dlgetmodinfo... " >&6; }
6528 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6529   $as_echo_n "(cached) " >&6
6530 else
6531   ac_func_search_save_LIBS=$LIBS
6532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6533 /* end confdefs.h.  */
6534
6535 /* Override any GCC internal prototype to avoid an error.
6536    Use char because int might match the return type of a GCC
6537    builtin and then its argument prototype would still apply.  */
6538 #ifdef __cplusplus
6539 extern "C"
6540 #endif
6541 char dlgetmodinfo ();
6542 int
6543 main ()
6544 {
6545 return dlgetmodinfo ();
6546   ;
6547   return 0;
6548 }
6549 _ACEOF
6550 for ac_lib in '' dl xpdl; do
6551   if test -z "$ac_lib"; then
6552     ac_res="none required"
6553   else
6554     ac_res=-l$ac_lib
6555     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6556   fi
6557   if ac_fn_c_try_link "$LINENO"; then :
6558   ac_cv_search_dlgetmodinfo=$ac_res
6559 fi
6560 rm -f core conftest.err conftest.$ac_objext \
6561     conftest$ac_exeext
6562   if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6563   break
6564 fi
6565 done
6566 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6567
6568 else
6569   ac_cv_search_dlgetmodinfo=no
6570 fi
6571 rm conftest.$ac_ext
6572 LIBS=$ac_func_search_save_LIBS
6573 fi
6574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlgetmodinfo" >&5
6575 $as_echo "$ac_cv_search_dlgetmodinfo" >&6; }
6576 ac_res=$ac_cv_search_dlgetmodinfo
6577 if test "$ac_res" != no; then :
6578   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6579
6580 fi
6581
6582
6583
6584
6585
6586 # Check whether --with-libiconv-prefix was given.
6587 if test "${with_libiconv_prefix+set}" = set; then :
6588   withval=$with_libiconv_prefix;
6589     for dir in `echo "$withval" | tr : ' '`; do
6590       if test -d $dir/include; then LIBICONV_INCLUDE="-I$dir/include"; fi
6591       if test -d $dir/lib; then LIBICONV_LIBDIR="-L$dir/lib"; fi
6592     done
6593
6594 fi
6595
6596
6597   BUILD_LIBICONV_LIBDIRS="../libiconv/lib/.libs ../libiconv/lib/_libs"
6598   BUILD_LIBICONV_INCLUDE="-I../libiconv/include"
6599
6600   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
6601 $as_echo_n "checking for iconv... " >&6; }
6602 if test "${am_cv_func_iconv+set}" = set; then :
6603   $as_echo_n "(cached) " >&6
6604 else
6605
6606     am_cv_func_iconv="no, consider installing GNU libiconv"
6607     am_cv_lib_iconv=no
6608     am_cv_use_build_libiconv=no
6609     am_cv_build_libiconv_path=
6610
6611     # If libiconv is part of the build tree, then try using it over
6612     # any system iconv.
6613     if test -d ../libiconv; then
6614       for lib_dir in $BUILD_LIBICONV_LIBDIRS; do
6615         am_save_LIBS="$LIBS"
6616         am_save_CPPFLAGS="$CPPFLAGS"
6617         LIBS="$LIBS $lib_dir/libiconv.a"
6618         CPPFLAGS="$CPPFLAGS $BUILD_LIBICONV_INCLUDE"
6619         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6620 /* end confdefs.h.  */
6621 #include <stdlib.h>
6622 #include <iconv.h>
6623 int
6624 main ()
6625 {
6626 iconv_t cd = iconv_open("","");
6627            iconv(cd,NULL,NULL,NULL,NULL);
6628            iconv_close(cd);
6629   ;
6630   return 0;
6631 }
6632 _ACEOF
6633 if ac_fn_c_try_link "$LINENO"; then :
6634   am_cv_use_build_libiconv=yes
6635           am_cv_build_libiconv_path=$lib_dir/libiconv.a
6636           am_cv_lib_iconv=yes
6637           am_cv_func_iconv=yes
6638 fi
6639 rm -f core conftest.err conftest.$ac_objext \
6640     conftest$ac_exeext conftest.$ac_ext
6641         LIBS="$am_save_LIBS"
6642         CPPFLAGS="$am_save_CPPFLAGS"
6643         if test "$am_cv_use_build_libiconv" = "yes"; then
6644           break
6645         fi
6646       done
6647     fi
6648
6649     # Next, try to find iconv in libc.
6650     if test "$am_cv_func_iconv" != yes; then
6651       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6652 /* end confdefs.h.  */
6653 #include <stdlib.h>
6654 #include <iconv.h>
6655 int
6656 main ()
6657 {
6658 iconv_t cd = iconv_open("","");
6659          iconv(cd,NULL,NULL,NULL,NULL);
6660          iconv_close(cd);
6661   ;
6662   return 0;
6663 }
6664 _ACEOF
6665 if ac_fn_c_try_link "$LINENO"; then :
6666   am_cv_func_iconv=yes
6667 fi
6668 rm -f core conftest.err conftest.$ac_objext \
6669     conftest$ac_exeext conftest.$ac_ext
6670     fi
6671
6672     # If iconv was not in libc, try -liconv.  In this case, arrange to
6673     # look in the libiconv prefix, if it was specified by the user.
6674     if test "$am_cv_func_iconv" != yes; then
6675       am_save_CPPFLAGS="$CPPFLAGS"
6676       am_save_LIBS="$LIBS"
6677       if test -n "$LIBICONV_INCLUDE"; then
6678         CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
6679         LIBS="$LIBS $LIBICONV_LIBDIR"
6680       fi
6681       LIBS="$LIBS -liconv"
6682       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6683 /* end confdefs.h.  */
6684 #include <stdlib.h>
6685 #include <iconv.h>
6686 int
6687 main ()
6688 {
6689 iconv_t cd = iconv_open("","");
6690          iconv(cd,NULL,NULL,NULL,NULL);
6691          iconv_close(cd);
6692   ;
6693   return 0;
6694 }
6695 _ACEOF
6696 if ac_fn_c_try_link "$LINENO"; then :
6697   am_cv_lib_iconv=yes
6698         am_cv_func_iconv=yes
6699 fi
6700 rm -f core conftest.err conftest.$ac_objext \
6701     conftest$ac_exeext conftest.$ac_ext
6702       LIBS="$am_save_LIBS"
6703       CPPFLAGS="$am_save_CPPFLAGS"
6704     fi
6705
6706 fi
6707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
6708 $as_echo "$am_cv_func_iconv" >&6; }
6709
6710   # Set the various flags based on the cache variables.  We can't rely
6711   # on the flags to remain set from the above code, due to caching.
6712   LIBICONV=
6713   if test "$am_cv_lib_iconv" = yes; then
6714     LIBICONV="-liconv"
6715   else
6716     LIBICONV_LIBDIR=
6717     LIBICONV_INCLUDE=
6718   fi
6719   if test "$am_cv_use_build_libiconv" = yes; then
6720     LIBICONV="$am_cv_build_libiconv_path"
6721     LIBICONV_LIBDIR=""
6722     LIBICONV_INCLUDE="$BUILD_LIBICONV_INCLUDE"
6723   fi
6724   CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
6725   LIBS="$LIBS $LIBICONV_LIBDIR $LIBICONV"
6726
6727   if test "$am_cv_func_iconv" = yes; then
6728
6729 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
6730
6731     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
6732 $as_echo_n "checking for iconv declaration... " >&6; }
6733     if test "${am_cv_proto_iconv+set}" = set; then :
6734   $as_echo_n "(cached) " >&6
6735 else
6736
6737       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6738 /* end confdefs.h.  */
6739
6740 #include <stdlib.h>
6741 #include <iconv.h>
6742 extern
6743 #ifdef __cplusplus
6744 "C"
6745 #endif
6746 #if defined(__STDC__) || defined(__cplusplus)
6747 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
6748 #else
6749 size_t iconv();
6750 #endif
6751
6752 int
6753 main ()
6754 {
6755
6756   ;
6757   return 0;
6758 }
6759 _ACEOF
6760 if ac_fn_c_try_compile "$LINENO"; then :
6761   am_cv_proto_iconv_arg1=""
6762 else
6763   am_cv_proto_iconv_arg1="const"
6764 fi
6765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6766       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);"
6767 fi
6768
6769     am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
6770     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
6771          }$am_cv_proto_iconv" >&5
6772 $as_echo "${ac_t:-
6773          }$am_cv_proto_iconv" >&6; }
6774
6775 cat >>confdefs.h <<_ACEOF
6776 #define ICONV_CONST $am_cv_proto_iconv_arg1
6777 _ACEOF
6778
6779   fi
6780
6781
6782 # GDB may fork/exec the iconv program to get the list of supported character
6783 # sets.  Allow the user to specify where to find it.
6784 # There are several factors affecting the choice of option name:
6785 # - There is already --with-libiconv-prefix but we can't use it, it specifies
6786 #   the build-time location of libiconv files.
6787 # - The program we need to find is iconv, which comes with glibc.  The user
6788 #   doesn't necessarily have libiconv installed.  Therefore naming this
6789 #   --with-libiconv-foo feels wrong.
6790 # - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
6791 #   defined to work on directories not files (though it really doesn't know
6792 #   the difference).
6793 # - Calling this --with-iconv-prefix is perceived to cause too much confusion
6794 #   with --with-libiconv-prefix.
6795 # Putting these together is why the option name is --with-iconv-bin.
6796
6797
6798 # Check whether --with-iconv-bin was given.
6799 if test "${with_iconv_bin+set}" = set; then :
6800   withval=$with_iconv_bin; iconv_bin="${withval}"
6801
6802 cat >>confdefs.h <<_ACEOF
6803 #define ICONV_BIN "${iconv_bin}"
6804 _ACEOF
6805
6806
6807   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6808      if test "x$prefix" = xNONE; then
6809         test_prefix=/usr/local
6810      else
6811         test_prefix=$prefix
6812      fi
6813   else
6814      test_prefix=$exec_prefix
6815   fi
6816   value=0
6817   case ${iconv_bin} in
6818      "${test_prefix}"|"${test_prefix}/"*|\
6819         '${exec_prefix}'|'${exec_prefix}/'*)
6820      value=1
6821      ;;
6822   esac
6823
6824 cat >>confdefs.h <<_ACEOF
6825 #define ICONV_BIN_RELOCATABLE $value
6826 _ACEOF
6827
6828
6829
6830 fi
6831
6832
6833 # On alpha-osf, it appears that libtermcap and libcurses are not compatible.
6834 # There is a very specific comment in /usr/include/curses.h explaining that
6835 # termcap routines built into libcurses must not be used.
6836 #
6837 # The symptoms we observed so far is GDB unexpectedly changing
6838 # the terminal settings when tgetent is called - this is particularly
6839 # visible as the output is missing carriage returns, and so rapidly
6840 # becomes very hard to read.
6841 #
6842 # The readline configure script has already decided that libtermcap
6843 # was enough for its purposes, and so decided to build readline using
6844 # libtermcap.  Since the TUI mode requires curses, building GDB with
6845 # TUI enabled results in both libraries to be used at the same time,
6846 # which is not allowed.  This basically means that GDB with TUI is
6847 # broken on alpha-osf.
6848
6849 case $host_os in
6850   osf* )
6851     if test x"$enable_tui" = xyes; then
6852       as_fn_error "Building GDB with TUI mode is not supported on this host" "$LINENO" 5
6853     fi
6854     if test x"$enable_tui" = xauto; then
6855       enable_tui=no
6856     fi
6857     ;;
6858 esac
6859
6860 # For the TUI, we need enhanced curses functionality.
6861 if test x"$enable_tui" != xno; then
6862   prefer_curses=yes
6863 fi
6864
6865 curses_found=no
6866 if test x"$prefer_curses" = xyes; then
6867   # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
6868   # curses library because the latter might not provide all the
6869   # functionality we need.  However, this leads to problems on systems
6870   # where the linker searches /usr/local/lib, but the compiler doesn't
6871   # search /usr/local/include, if ncurses is installed in /usr/local.  A
6872   # default installation of ncurses on alpha*-dec-osf* will lead to such
6873   # a situation.
6874   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
6875 $as_echo_n "checking for library containing waddstr... " >&6; }
6876 if test "${ac_cv_search_waddstr+set}" = set; then :
6877   $as_echo_n "(cached) " >&6
6878 else
6879   ac_func_search_save_LIBS=$LIBS
6880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6881 /* end confdefs.h.  */
6882
6883 /* Override any GCC internal prototype to avoid an error.
6884    Use char because int might match the return type of a GCC
6885    builtin and then its argument prototype would still apply.  */
6886 #ifdef __cplusplus
6887 extern "C"
6888 #endif
6889 char waddstr ();
6890 int
6891 main ()
6892 {
6893 return waddstr ();
6894   ;
6895   return 0;
6896 }
6897 _ACEOF
6898 for ac_lib in '' ncurses cursesX curses; do
6899   if test -z "$ac_lib"; then
6900     ac_res="none required"
6901   else
6902     ac_res=-l$ac_lib
6903     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6904   fi
6905   if ac_fn_c_try_link "$LINENO"; then :
6906   ac_cv_search_waddstr=$ac_res
6907 fi
6908 rm -f core conftest.err conftest.$ac_objext \
6909     conftest$ac_exeext
6910   if test "${ac_cv_search_waddstr+set}" = set; then :
6911   break
6912 fi
6913 done
6914 if test "${ac_cv_search_waddstr+set}" = set; then :
6915
6916 else
6917   ac_cv_search_waddstr=no
6918 fi
6919 rm conftest.$ac_ext
6920 LIBS=$ac_func_search_save_LIBS
6921 fi
6922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
6923 $as_echo "$ac_cv_search_waddstr" >&6; }
6924 ac_res=$ac_cv_search_waddstr
6925 if test "$ac_res" != no; then :
6926   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6927
6928 fi
6929
6930
6931   if test "$ac_cv_search_waddstr" != no; then
6932     curses_found=yes
6933   fi
6934 fi
6935
6936 # Check whether we should enable the TUI, but only do so if we really
6937 # can.
6938 if test x"$enable_tui" != xno; then
6939   if test -d $srcdir/tui; then
6940     if test "$curses_found" != no; then
6941       CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
6942       CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
6943       CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
6944       ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
6945     else
6946       if test x"$enable_tui" = xyes; then
6947         as_fn_error "no enhanced curses library found; disable TUI" "$LINENO" 5
6948       else
6949         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
6950 $as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
6951       fi
6952     fi
6953   fi
6954 fi
6955
6956 # Since GDB uses Readline, we need termcap functionality.  In many
6957 # cases this will be provided by the curses library, but some systems
6958 # have a seperate termcap library, or no curses library at all.
6959
6960 case $host_os in
6961   cygwin*)
6962     if test -d $srcdir/libtermcap; then
6963       LIBS="../libtermcap/libtermcap.a $LIBS"
6964       ac_cv_search_tgetent="../libtermcap/libtermcap.a"
6965     fi ;;
6966   go32* | *djgpp*)
6967     ac_cv_search_tgetent="none required"
6968     ;;
6969   *mingw32*)
6970     ac_cv_search_tgetent="none required"
6971     CONFIG_OBS="$CONFIG_OBS windows-termcap.o"
6972     ;;
6973 esac
6974
6975 # These are the libraries checked by Readline.
6976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
6977 $as_echo_n "checking for library containing tgetent... " >&6; }
6978 if test "${ac_cv_search_tgetent+set}" = set; then :
6979   $as_echo_n "(cached) " >&6
6980 else
6981   ac_func_search_save_LIBS=$LIBS
6982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6983 /* end confdefs.h.  */
6984
6985 /* Override any GCC internal prototype to avoid an error.
6986    Use char because int might match the return type of a GCC
6987    builtin and then its argument prototype would still apply.  */
6988 #ifdef __cplusplus
6989 extern "C"
6990 #endif
6991 char tgetent ();
6992 int
6993 main ()
6994 {
6995 return tgetent ();
6996   ;
6997   return 0;
6998 }
6999 _ACEOF
7000 for ac_lib in '' termcap tinfo curses ncurses; do
7001   if test -z "$ac_lib"; then
7002     ac_res="none required"
7003   else
7004     ac_res=-l$ac_lib
7005     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7006   fi
7007   if ac_fn_c_try_link "$LINENO"; then :
7008   ac_cv_search_tgetent=$ac_res
7009 fi
7010 rm -f core conftest.err conftest.$ac_objext \
7011     conftest$ac_exeext
7012   if test "${ac_cv_search_tgetent+set}" = set; then :
7013   break
7014 fi
7015 done
7016 if test "${ac_cv_search_tgetent+set}" = set; then :
7017
7018 else
7019   ac_cv_search_tgetent=no
7020 fi
7021 rm conftest.$ac_ext
7022 LIBS=$ac_func_search_save_LIBS
7023 fi
7024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
7025 $as_echo "$ac_cv_search_tgetent" >&6; }
7026 ac_res=$ac_cv_search_tgetent
7027 if test "$ac_res" != no; then :
7028   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7029
7030 fi
7031
7032
7033 if test "$ac_cv_search_tgetent" = no; then
7034   as_fn_error "no termcap library found" "$LINENO" 5
7035 fi
7036
7037
7038 # Check whether --with-system-readline was given.
7039 if test "${with_system_readline+set}" = set; then :
7040   withval=$with_system_readline;
7041 fi
7042
7043
7044 if test "$with_system_readline" = yes; then
7045   READLINE=-lreadline
7046   READLINE_DEPS=
7047   READLINE_CFLAGS=
7048   READLINE_TEXI_INCFLAG=
7049 else
7050   READLINE='$(READLINE_DIR)/libreadline.a'
7051   READLINE_DEPS='$(READLINE)'
7052   READLINE_CFLAGS='-I$(READLINE_SRC)/..'
7053   READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
7054 fi
7055
7056
7057
7058
7059
7060 # Generate jit-reader.h
7061
7062 # This is typedeffed to GDB_CORE_ADDR in jit-reader.h
7063 TARGET_PTR=
7064
7065 # The cast to long int works around a bug in the HP C Compiler
7066 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7067 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7068 # This bug is HP SR number 8606223364.
7069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
7070 $as_echo_n "checking size of unsigned long long... " >&6; }
7071 if test "${ac_cv_sizeof_unsigned_long_long+set}" = set; then :
7072   $as_echo_n "(cached) " >&6
7073 else
7074   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long"        "$ac_includes_default"; then :
7075
7076 else
7077   if test "$ac_cv_type_unsigned_long_long" = yes; then
7078      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7079 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7080 { as_fn_set_status 77
7081 as_fn_error "cannot compute sizeof (unsigned long long)
7082 See \`config.log' for more details." "$LINENO" 5; }; }
7083    else
7084      ac_cv_sizeof_unsigned_long_long=0
7085    fi
7086 fi
7087
7088 fi
7089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
7090 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
7091
7092
7093
7094 cat >>confdefs.h <<_ACEOF
7095 #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
7096 _ACEOF
7097
7098
7099 # The cast to long int works around a bug in the HP C Compiler
7100 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7101 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7102 # This bug is HP SR number 8606223364.
7103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
7104 $as_echo_n "checking size of unsigned long... " >&6; }
7105 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then :
7106   $as_echo_n "(cached) " >&6
7107 else
7108   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long"        "$ac_includes_default"; then :
7109
7110 else
7111   if test "$ac_cv_type_unsigned_long" = yes; then
7112      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7113 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7114 { as_fn_set_status 77
7115 as_fn_error "cannot compute sizeof (unsigned long)
7116 See \`config.log' for more details." "$LINENO" 5; }; }
7117    else
7118      ac_cv_sizeof_unsigned_long=0
7119    fi
7120 fi
7121
7122 fi
7123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
7124 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
7125
7126
7127
7128 cat >>confdefs.h <<_ACEOF
7129 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
7130 _ACEOF
7131
7132
7133 # The cast to long int works around a bug in the HP C Compiler
7134 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7135 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7136 # This bug is HP SR number 8606223364.
7137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
7138 $as_echo_n "checking size of unsigned __int128... " >&6; }
7139 if test "${ac_cv_sizeof_unsigned___int128+set}" = set; then :
7140   $as_echo_n "(cached) " >&6
7141 else
7142   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128"        "$ac_includes_default"; then :
7143
7144 else
7145   if test "$ac_cv_type_unsigned___int128" = yes; then
7146      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7147 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7148 { as_fn_set_status 77
7149 as_fn_error "cannot compute sizeof (unsigned __int128)
7150 See \`config.log' for more details." "$LINENO" 5; }; }
7151    else
7152      ac_cv_sizeof_unsigned___int128=0
7153    fi
7154 fi
7155
7156 fi
7157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
7158 $as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
7159
7160
7161
7162 cat >>confdefs.h <<_ACEOF
7163 #define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
7164 _ACEOF
7165
7166
7167
7168 if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
7169   TARGET_PTR="unsigned long"
7170 elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
7171   TARGET_PTR="unsigned long long"
7172 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
7173   TARGET_PTR="unsigned __int128"
7174 else
7175   TARGET_PTR="unsigned long"
7176 fi
7177
7178
7179 ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
7180
7181
7182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
7183 $as_echo_n "checking for library containing dlopen... " >&6; }
7184 if test "${ac_cv_search_dlopen+set}" = set; then :
7185   $as_echo_n "(cached) " >&6
7186 else
7187   ac_func_search_save_LIBS=$LIBS
7188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7189 /* end confdefs.h.  */
7190
7191 /* Override any GCC internal prototype to avoid an error.
7192    Use char because int might match the return type of a GCC
7193    builtin and then its argument prototype would still apply.  */
7194 #ifdef __cplusplus
7195 extern "C"
7196 #endif
7197 char dlopen ();
7198 int
7199 main ()
7200 {
7201 return dlopen ();
7202   ;
7203   return 0;
7204 }
7205 _ACEOF
7206 for ac_lib in '' dl; do
7207   if test -z "$ac_lib"; then
7208     ac_res="none required"
7209   else
7210     ac_res=-l$ac_lib
7211     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7212   fi
7213   if ac_fn_c_try_link "$LINENO"; then :
7214   ac_cv_search_dlopen=$ac_res
7215 fi
7216 rm -f core conftest.err conftest.$ac_objext \
7217     conftest$ac_exeext
7218   if test "${ac_cv_search_dlopen+set}" = set; then :
7219   break
7220 fi
7221 done
7222 if test "${ac_cv_search_dlopen+set}" = set; then :
7223
7224 else
7225   ac_cv_search_dlopen=no
7226 fi
7227 rm conftest.$ac_ext
7228 LIBS=$ac_func_search_save_LIBS
7229 fi
7230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
7231 $as_echo "$ac_cv_search_dlopen" >&6; }
7232 ac_res=$ac_cv_search_dlopen
7233 if test "$ac_res" != no; then :
7234   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7235
7236 fi
7237
7238
7239
7240
7241 # Check whether --with-jit-reader-dir was given.
7242 if test "${with_jit_reader_dir+set}" = set; then :
7243   withval=$with_jit_reader_dir;
7244     JIT_READER_DIR=$withval
7245 else
7246   JIT_READER_DIR=${libdir}/gdb
7247 fi
7248
7249
7250   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7251   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7252   ac_define_dir=`eval echo $JIT_READER_DIR`
7253   ac_define_dir=`eval echo $ac_define_dir`
7254
7255 cat >>confdefs.h <<_ACEOF
7256 #define JIT_READER_DIR "$ac_define_dir"
7257 _ACEOF
7258
7259
7260
7261
7262   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
7263      if test "x$prefix" = xNONE; then
7264         test_prefix=/usr/local
7265      else
7266         test_prefix=$prefix
7267      fi
7268   else
7269      test_prefix=$exec_prefix
7270   fi
7271   value=0
7272   case ${ac_define_dir} in
7273      "${test_prefix}"|"${test_prefix}/"*|\
7274         '${exec_prefix}'|'${exec_prefix}/'*)
7275      value=1
7276      ;;
7277   esac
7278
7279 cat >>confdefs.h <<_ACEOF
7280 #define JIT_READER_DIR_RELOCATABLE $value
7281 _ACEOF
7282
7283
7284
7285
7286
7287 # Check whether --with-expat was given.
7288 if test "${with_expat+set}" = set; then :
7289   withval=$with_expat;
7290 else
7291   with_expat=auto
7292 fi
7293
7294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
7295 $as_echo_n "checking whether to use expat... " >&6; }
7296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
7297 $as_echo "$with_expat" >&6; }
7298
7299 if test "${with_expat}" = no; then
7300   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
7301 $as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
7302   HAVE_LIBEXPAT=no
7303 else
7304
7305       if test "X$prefix" = "XNONE"; then
7306     acl_final_prefix="$ac_default_prefix"
7307   else
7308     acl_final_prefix="$prefix"
7309   fi
7310   if test "X$exec_prefix" = "XNONE"; then
7311     acl_final_exec_prefix='${prefix}'
7312   else
7313     acl_final_exec_prefix="$exec_prefix"
7314   fi
7315   acl_save_prefix="$prefix"
7316   prefix="$acl_final_prefix"
7317   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
7318   prefix="$acl_save_prefix"
7319
7320
7321 # Check whether --with-gnu-ld was given.
7322 if test "${with_gnu_ld+set}" = set; then :
7323   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
7324 else
7325   with_gnu_ld=no
7326 fi
7327
7328 # Prepare PATH_SEPARATOR.
7329 # The user is always right.
7330 if test "${PATH_SEPARATOR+set}" != set; then
7331   echo "#! /bin/sh" >conf$$.sh
7332   echo  "exit 0"   >>conf$$.sh
7333   chmod +x conf$$.sh
7334   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
7335     PATH_SEPARATOR=';'
7336   else
7337     PATH_SEPARATOR=:
7338   fi
7339   rm -f conf$$.sh
7340 fi
7341 ac_prog=ld
7342 if test "$GCC" = yes; then
7343   # Check if gcc -print-prog-name=ld gives a path.
7344   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
7345 $as_echo_n "checking for ld used by GCC... " >&6; }
7346   case $host in
7347   *-*-mingw*)
7348     # gcc leaves a trailing carriage return which upsets mingw
7349     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7350   *)
7351     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7352   esac
7353   case $ac_prog in
7354     # Accept absolute paths.
7355     [\\/]* | [A-Za-z]:[\\/]*)
7356       re_direlt='/[^/][^/]*/\.\./'
7357       # Canonicalize the path of ld
7358       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
7359       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
7360         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
7361       done
7362       test -z "$LD" && LD="$ac_prog"
7363       ;;
7364   "")
7365     # If it fails, then pretend we aren't using GCC.
7366     ac_prog=ld
7367     ;;
7368   *)
7369     # If it is relative, then search for the first ld in PATH.
7370     with_gnu_ld=unknown
7371     ;;
7372   esac
7373 elif test "$with_gnu_ld" = yes; then
7374   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7375 $as_echo_n "checking for GNU ld... " >&6; }
7376 else
7377   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7378 $as_echo_n "checking for non-GNU ld... " >&6; }
7379 fi
7380 if test "${acl_cv_path_LD+set}" = set; then :
7381   $as_echo_n "(cached) " >&6
7382 else
7383   if test -z "$LD"; then
7384   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
7385   for ac_dir in $PATH; do
7386     test -z "$ac_dir" && ac_dir=.
7387     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7388       acl_cv_path_LD="$ac_dir/$ac_prog"
7389       # Check to see if the program is GNU ld.  I'd rather use --version,
7390       # but apparently some GNU ld's only accept -v.
7391       # Break only if it was the GNU/non-GNU ld that we prefer.
7392       if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
7393         test "$with_gnu_ld" != no && break
7394       else
7395         test "$with_gnu_ld" != yes && break
7396       fi
7397     fi
7398   done
7399   IFS="$ac_save_ifs"
7400 else
7401   acl_cv_path_LD="$LD" # Let the user override the test with a path.
7402 fi
7403 fi
7404
7405 LD="$acl_cv_path_LD"
7406 if test -n "$LD"; then
7407   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7408 $as_echo "$LD" >&6; }
7409 else
7410   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7411 $as_echo "no" >&6; }
7412 fi
7413 test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
7414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7415 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7416 if test "${acl_cv_prog_gnu_ld+set}" = set; then :
7417   $as_echo_n "(cached) " >&6
7418 else
7419   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
7420 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
7421   acl_cv_prog_gnu_ld=yes
7422 else
7423   acl_cv_prog_gnu_ld=no
7424 fi
7425 fi
7426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
7427 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
7428 with_gnu_ld=$acl_cv_prog_gnu_ld
7429
7430
7431
7432                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
7433 $as_echo_n "checking for shared library run path origin... " >&6; }
7434 if test "${acl_cv_rpath+set}" = set; then :
7435   $as_echo_n "(cached) " >&6
7436 else
7437
7438     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
7439     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
7440     . ./conftest.sh
7441     rm -f ./conftest.sh
7442     acl_cv_rpath=done
7443
7444 fi
7445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
7446 $as_echo "$acl_cv_rpath" >&6; }
7447   wl="$acl_cv_wl"
7448   libext="$acl_cv_libext"
7449   shlibext="$acl_cv_shlibext"
7450   hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
7451   hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
7452   hardcode_direct="$acl_cv_hardcode_direct"
7453   hardcode_minus_L="$acl_cv_hardcode_minus_L"
7454     # Check whether --enable-rpath was given.
7455 if test "${enable_rpath+set}" = set; then :
7456   enableval=$enable_rpath; :
7457 else
7458   enable_rpath=yes
7459 fi
7460
7461
7462
7463
7464
7465
7466
7467
7468
7469
7470     use_additional=yes
7471
7472   acl_save_prefix="$prefix"
7473   prefix="$acl_final_prefix"
7474   acl_save_exec_prefix="$exec_prefix"
7475   exec_prefix="$acl_final_exec_prefix"
7476
7477     eval additional_includedir=\"$includedir\"
7478     eval additional_libdir=\"$libdir\"
7479
7480   exec_prefix="$acl_save_exec_prefix"
7481   prefix="$acl_save_prefix"
7482
7483
7484 # Check whether --with-libexpat-prefix was given.
7485 if test "${with_libexpat_prefix+set}" = set; then :
7486   withval=$with_libexpat_prefix;
7487     if test "X$withval" = "Xno"; then
7488       use_additional=no
7489     else
7490       if test "X$withval" = "X"; then
7491
7492   acl_save_prefix="$prefix"
7493   prefix="$acl_final_prefix"
7494   acl_save_exec_prefix="$exec_prefix"
7495   exec_prefix="$acl_final_exec_prefix"
7496
7497           eval additional_includedir=\"$includedir\"
7498           eval additional_libdir=\"$libdir\"
7499
7500   exec_prefix="$acl_save_exec_prefix"
7501   prefix="$acl_save_prefix"
7502
7503       else
7504         additional_includedir="$withval/include"
7505         additional_libdir="$withval/lib"
7506       fi
7507     fi
7508
7509 fi
7510
7511       LIBEXPAT=
7512   LTLIBEXPAT=
7513   INCEXPAT=
7514   rpathdirs=
7515   ltrpathdirs=
7516   names_already_handled=
7517   names_next_round='expat '
7518   while test -n "$names_next_round"; do
7519     names_this_round="$names_next_round"
7520     names_next_round=
7521     for name in $names_this_round; do
7522       already_handled=
7523       for n in $names_already_handled; do
7524         if test "$n" = "$name"; then
7525           already_handled=yes
7526           break
7527         fi
7528       done
7529       if test -z "$already_handled"; then
7530         names_already_handled="$names_already_handled $name"
7531                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
7532         eval value=\"\$HAVE_LIB$uppername\"
7533         if test -n "$value"; then
7534           if test "$value" = yes; then
7535             eval value=\"\$LIB$uppername\"
7536             test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
7537             eval value=\"\$LTLIB$uppername\"
7538             test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
7539           else
7540                                     :
7541           fi
7542         else
7543                               found_dir=
7544           found_la=
7545           found_so=
7546           found_a=
7547           if test $use_additional = yes; then
7548             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
7549               found_dir="$additional_libdir"
7550               found_so="$additional_libdir/lib$name.$shlibext"
7551               if test -f "$additional_libdir/lib$name.la"; then
7552                 found_la="$additional_libdir/lib$name.la"
7553               fi
7554             else
7555               if test -f "$additional_libdir/lib$name.$libext"; then
7556                 found_dir="$additional_libdir"
7557                 found_a="$additional_libdir/lib$name.$libext"
7558                 if test -f "$additional_libdir/lib$name.la"; then
7559                   found_la="$additional_libdir/lib$name.la"
7560                 fi
7561               fi
7562             fi
7563           fi
7564           if test "X$found_dir" = "X"; then
7565             for x in $LDFLAGS $LTLIBEXPAT; do
7566
7567   acl_save_prefix="$prefix"
7568   prefix="$acl_final_prefix"
7569   acl_save_exec_prefix="$exec_prefix"
7570   exec_prefix="$acl_final_exec_prefix"
7571   eval x=\"$x\"
7572   exec_prefix="$acl_save_exec_prefix"
7573   prefix="$acl_save_prefix"
7574
7575               case "$x" in
7576                 -L*)
7577                   dir=`echo "X$x" | sed -e 's/^X-L//'`
7578                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
7579                     found_dir="$dir"
7580                     found_so="$dir/lib$name.$shlibext"
7581                     if test -f "$dir/lib$name.la"; then
7582                       found_la="$dir/lib$name.la"
7583                     fi
7584                   else
7585                     if test -f "$dir/lib$name.$libext"; then
7586                       found_dir="$dir"
7587                       found_a="$dir/lib$name.$libext"
7588                       if test -f "$dir/lib$name.la"; then
7589                         found_la="$dir/lib$name.la"
7590                       fi
7591                     fi
7592                   fi
7593                   ;;
7594               esac
7595               if test "X$found_dir" != "X"; then
7596                 break
7597               fi
7598             done
7599           fi
7600           if test "X$found_dir" != "X"; then
7601                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
7602             if test "X$found_so" != "X"; then
7603                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
7604                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7605               else
7606                                                                                 haveit=
7607                 for x in $ltrpathdirs; do
7608                   if test "X$x" = "X$found_dir"; then
7609                     haveit=yes
7610                     break
7611                   fi
7612                 done
7613                 if test -z "$haveit"; then
7614                   ltrpathdirs="$ltrpathdirs $found_dir"
7615                 fi
7616                                 if test "$hardcode_direct" = yes; then
7617                                                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7618                 else
7619                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
7620                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7621                                                             haveit=
7622                     for x in $rpathdirs; do
7623                       if test "X$x" = "X$found_dir"; then
7624                         haveit=yes
7625                         break
7626                       fi
7627                     done
7628                     if test -z "$haveit"; then
7629                       rpathdirs="$rpathdirs $found_dir"
7630                     fi
7631                   else
7632                                                                                 haveit=
7633                     for x in $LDFLAGS $LIBEXPAT; do
7634
7635   acl_save_prefix="$prefix"
7636   prefix="$acl_final_prefix"
7637   acl_save_exec_prefix="$exec_prefix"
7638   exec_prefix="$acl_final_exec_prefix"
7639   eval x=\"$x\"
7640   exec_prefix="$acl_save_exec_prefix"
7641   prefix="$acl_save_prefix"
7642
7643                       if test "X$x" = "X-L$found_dir"; then
7644                         haveit=yes
7645                         break
7646                       fi
7647                     done
7648                     if test -z "$haveit"; then
7649                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
7650                     fi
7651                     if test "$hardcode_minus_L" != no; then
7652                                                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7653                     else
7654                                                                                                                                                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
7655                     fi
7656                   fi
7657                 fi
7658               fi
7659             else
7660               if test "X$found_a" != "X"; then
7661                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
7662               else
7663                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
7664               fi
7665             fi
7666                         additional_includedir=
7667             case "$found_dir" in
7668               */lib | */lib/)
7669                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
7670                 additional_includedir="$basedir/include"
7671                 ;;
7672             esac
7673             if test "X$additional_includedir" != "X"; then
7674                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
7675                 haveit=
7676                 if test "X$additional_includedir" = "X/usr/local/include"; then
7677                   if test -n "$GCC"; then
7678                     case $host_os in
7679                       linux*) haveit=yes;;
7680                     esac
7681                   fi
7682                 fi
7683                 if test -z "$haveit"; then
7684                   for x in $CPPFLAGS $INCEXPAT; do
7685
7686   acl_save_prefix="$prefix"
7687   prefix="$acl_final_prefix"
7688   acl_save_exec_prefix="$exec_prefix"
7689   exec_prefix="$acl_final_exec_prefix"
7690   eval x=\"$x\"
7691   exec_prefix="$acl_save_exec_prefix"
7692   prefix="$acl_save_prefix"
7693
7694                     if test "X$x" = "X-I$additional_includedir"; then
7695                       haveit=yes
7696                       break
7697                     fi
7698                   done
7699                   if test -z "$haveit"; then
7700                     if test -d "$additional_includedir"; then
7701                                             INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
7702                     fi
7703                   fi
7704                 fi
7705               fi
7706             fi
7707                         if test -n "$found_la"; then
7708                                                         save_libdir="$libdir"
7709               case "$found_la" in
7710                 */* | *\\*) . "$found_la" ;;
7711                 *) . "./$found_la" ;;
7712               esac
7713               libdir="$save_libdir"
7714                             for dep in $dependency_libs; do
7715                 case "$dep" in
7716                   -L*)
7717                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
7718                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
7719                       haveit=
7720                       if test "X$additional_libdir" = "X/usr/local/lib"; then
7721                         if test -n "$GCC"; then
7722                           case $host_os in
7723                             linux*) haveit=yes;;
7724                           esac
7725                         fi
7726                       fi
7727                       if test -z "$haveit"; then
7728                         haveit=
7729                         for x in $LDFLAGS $LIBEXPAT; do
7730
7731   acl_save_prefix="$prefix"
7732   prefix="$acl_final_prefix"
7733   acl_save_exec_prefix="$exec_prefix"
7734   exec_prefix="$acl_final_exec_prefix"
7735   eval x=\"$x\"
7736   exec_prefix="$acl_save_exec_prefix"
7737   prefix="$acl_save_prefix"
7738
7739                           if test "X$x" = "X-L$additional_libdir"; then
7740                             haveit=yes
7741                             break
7742                           fi
7743                         done
7744                         if test -z "$haveit"; then
7745                           if test -d "$additional_libdir"; then
7746                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
7747                           fi
7748                         fi
7749                         haveit=
7750                         for x in $LDFLAGS $LTLIBEXPAT; do
7751
7752   acl_save_prefix="$prefix"
7753   prefix="$acl_final_prefix"
7754   acl_save_exec_prefix="$exec_prefix"
7755   exec_prefix="$acl_final_exec_prefix"
7756   eval x=\"$x\"
7757   exec_prefix="$acl_save_exec_prefix"
7758   prefix="$acl_save_prefix"
7759
7760                           if test "X$x" = "X-L$additional_libdir"; then
7761                             haveit=yes
7762                             break
7763                           fi
7764                         done
7765                         if test -z "$haveit"; then
7766                           if test -d "$additional_libdir"; then
7767                                                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
7768                           fi
7769                         fi
7770                       fi
7771                     fi
7772                     ;;
7773                   -R*)
7774                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
7775                     if test "$enable_rpath" != no; then
7776                                                                   haveit=
7777                       for x in $rpathdirs; do
7778                         if test "X$x" = "X$dir"; then
7779                           haveit=yes
7780                           break
7781                         fi
7782                       done
7783                       if test -z "$haveit"; then
7784                         rpathdirs="$rpathdirs $dir"
7785                       fi
7786                                                                   haveit=
7787                       for x in $ltrpathdirs; do
7788                         if test "X$x" = "X$dir"; then
7789                           haveit=yes
7790                           break
7791                         fi
7792                       done
7793                       if test -z "$haveit"; then
7794                         ltrpathdirs="$ltrpathdirs $dir"
7795                       fi
7796                     fi
7797                     ;;
7798                   -l*)
7799                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
7800                     ;;
7801                   *.la)
7802                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
7803                     ;;
7804                   *)
7805                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
7806                     LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
7807                     ;;
7808                 esac
7809               done
7810             fi
7811           else
7812                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
7813             LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
7814           fi
7815         fi
7816       fi
7817     done
7818   done
7819   if test "X$rpathdirs" != "X"; then
7820     if test -n "$hardcode_libdir_separator"; then
7821                         alldirs=
7822       for found_dir in $rpathdirs; do
7823         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
7824       done
7825             acl_save_libdir="$libdir"
7826       libdir="$alldirs"
7827       eval flag=\"$hardcode_libdir_flag_spec\"
7828       libdir="$acl_save_libdir"
7829       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
7830     else
7831             for found_dir in $rpathdirs; do
7832         acl_save_libdir="$libdir"
7833         libdir="$found_dir"
7834         eval flag=\"$hardcode_libdir_flag_spec\"
7835         libdir="$acl_save_libdir"
7836         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
7837       done
7838     fi
7839   fi
7840   if test "X$ltrpathdirs" != "X"; then
7841             for found_dir in $ltrpathdirs; do
7842       LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
7843     done
7844   fi
7845
7846
7847         ac_save_CPPFLAGS="$CPPFLAGS"
7848
7849   for element in $INCEXPAT; do
7850     haveit=
7851     for x in $CPPFLAGS; do
7852
7853   acl_save_prefix="$prefix"
7854   prefix="$acl_final_prefix"
7855   acl_save_exec_prefix="$exec_prefix"
7856   exec_prefix="$acl_final_exec_prefix"
7857   eval x=\"$x\"
7858   exec_prefix="$acl_save_exec_prefix"
7859   prefix="$acl_save_prefix"
7860
7861       if test "X$x" = "X$element"; then
7862         haveit=yes
7863         break
7864       fi
7865     done
7866     if test -z "$haveit"; then
7867       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
7868     fi
7869   done
7870
7871
7872   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
7873 $as_echo_n "checking for libexpat... " >&6; }
7874 if test "${ac_cv_libexpat+set}" = set; then :
7875   $as_echo_n "(cached) " >&6
7876 else
7877
7878     ac_save_LIBS="$LIBS"
7879     LIBS="$LIBS $LIBEXPAT"
7880     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7881 /* end confdefs.h.  */
7882 #include "expat.h"
7883 int
7884 main ()
7885 {
7886 XML_Parser p = XML_ParserCreate (0);
7887   ;
7888   return 0;
7889 }
7890 _ACEOF
7891 if ac_fn_c_try_link "$LINENO"; then :
7892   ac_cv_libexpat=yes
7893 else
7894   ac_cv_libexpat=no
7895 fi
7896 rm -f core conftest.err conftest.$ac_objext \
7897     conftest$ac_exeext conftest.$ac_ext
7898     LIBS="$ac_save_LIBS"
7899
7900 fi
7901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
7902 $as_echo "$ac_cv_libexpat" >&6; }
7903   if test "$ac_cv_libexpat" = yes; then
7904     HAVE_LIBEXPAT=yes
7905
7906 $as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
7907
7908     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
7909 $as_echo_n "checking how to link with libexpat... " >&6; }
7910     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
7911 $as_echo "$LIBEXPAT" >&6; }
7912   else
7913     HAVE_LIBEXPAT=no
7914             CPPFLAGS="$ac_save_CPPFLAGS"
7915     LIBEXPAT=
7916     LTLIBEXPAT=
7917   fi
7918
7919
7920
7921
7922
7923
7924   if test "$HAVE_LIBEXPAT" != yes; then
7925     if test "$with_expat" = yes; then
7926       as_fn_error "expat is missing or unusable" "$LINENO" 5
7927     else
7928       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
7929 $as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
7930     fi
7931   else
7932     save_LIBS=$LIBS
7933     LIBS="$LIBS $LIBEXPAT"
7934     for ac_func in XML_StopParser
7935 do :
7936   ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
7937 if test "x$ac_cv_func_XML_StopParser" = x""yes; then :
7938   cat >>confdefs.h <<_ACEOF
7939 #define HAVE_XML_STOPPARSER 1
7940 _ACEOF
7941
7942 fi
7943 done
7944
7945     LIBS=$save_LIBS
7946   fi
7947 fi
7948
7949
7950
7951
7952
7953
7954 # Check whether --with-python was given.
7955 if test "${with_python+set}" = set; then :
7956   withval=$with_python;
7957 else
7958   with_python=auto
7959 fi
7960
7961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
7962 $as_echo_n "checking whether to use python... " >&6; }
7963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
7964 $as_echo "$with_python" >&6; }
7965
7966 if test "${with_python}" = no; then
7967   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
7968 $as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
7969   have_libpython=no
7970 else
7971   case "${with_python}" in
7972   [\\/]* | ?:[\\/]*)
7973     if test -d ${with_python}; then
7974       # Assume the python binary is ${with_python}/bin/python.
7975       python_prog="${with_python}/bin/python"
7976       python_prefix=
7977       # If python does not exit ${with_python}/bin, then try in
7978       # ${with_python}.  On Windows/MinGW, this is where the Python
7979       # executable is.
7980       if test ! -x "${python_prog}"; then
7981         python_prog="${with_python}/python"
7982         python_prefix=
7983       fi
7984       if test ! -x "${python_prog}"; then
7985         # Fall back to gdb 7.0/7.1 behaviour.
7986         python_prog=missing
7987         python_prefix=${with_python}
7988       fi
7989     elif test -x "${with_python}"; then
7990       # While we can't run python compiled for $host (unless host == build),
7991       # the user could write a script that provides the needed information,
7992       # so we support that.
7993       python_prog=${with_python}
7994       python_prefix=
7995     else
7996       as_fn_error "invalid value for --with-python" "$LINENO" 5
7997     fi
7998     ;;
7999   */*)
8000     # Disallow --with-python=foo/bar.
8001     as_fn_error "invalid value for --with-python" "$LINENO" 5
8002     ;;
8003   *)
8004     # The user has either specified auto, yes, or the name of the python
8005     # program assumed to be in $PATH.
8006     python_prefix=
8007     case "${with_python}" in
8008     yes | auto)
8009       if test ${build} = ${host}; then
8010         # Extract the first word of "python", so it can be a program name with args.
8011 set dummy python; ac_word=$2
8012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8013 $as_echo_n "checking for $ac_word... " >&6; }
8014 if test "${ac_cv_path_python_prog_path+set}" = set; then :
8015   $as_echo_n "(cached) " >&6
8016 else
8017   case $python_prog_path in
8018   [\\/]* | ?:[\\/]*)
8019   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
8020   ;;
8021   *)
8022   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8023 for as_dir in $PATH
8024 do
8025   IFS=$as_save_IFS
8026   test -z "$as_dir" && as_dir=.
8027     for ac_exec_ext in '' $ac_executable_extensions; do
8028   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8029     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
8030     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8031     break 2
8032   fi
8033 done
8034   done
8035 IFS=$as_save_IFS
8036
8037   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
8038   ;;
8039 esac
8040 fi
8041 python_prog_path=$ac_cv_path_python_prog_path
8042 if test -n "$python_prog_path"; then
8043   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
8044 $as_echo "$python_prog_path" >&6; }
8045 else
8046   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8047 $as_echo "no" >&6; }
8048 fi
8049
8050
8051         if test "${python_prog_path}" = missing; then
8052           python_prog=missing
8053         else
8054           python_prog=${python_prog_path}
8055         fi
8056       else
8057         # Not much we can do except assume the cross-compiler will find the
8058         # right files.
8059         python_prog=missing
8060       fi
8061       ;;
8062     *)
8063       # While we can't run python compiled for $host (unless host == build),
8064       # the user could write a script that provides the needed information,
8065       # so we support that.
8066       python_prog="${with_python}"
8067       # Extract the first word of "${python_prog}", so it can be a program name with args.
8068 set dummy ${python_prog}; ac_word=$2
8069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8070 $as_echo_n "checking for $ac_word... " >&6; }
8071 if test "${ac_cv_path_python_prog_path+set}" = set; then :
8072   $as_echo_n "(cached) " >&6
8073 else
8074   case $python_prog_path in
8075   [\\/]* | ?:[\\/]*)
8076   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
8077   ;;
8078   *)
8079   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8080 for as_dir in $PATH
8081 do
8082   IFS=$as_save_IFS
8083   test -z "$as_dir" && as_dir=.
8084     for ac_exec_ext in '' $ac_executable_extensions; do
8085   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8086     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
8087     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8088     break 2
8089   fi
8090 done
8091   done
8092 IFS=$as_save_IFS
8093
8094   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
8095   ;;
8096 esac
8097 fi
8098 python_prog_path=$ac_cv_path_python_prog_path
8099 if test -n "$python_prog_path"; then
8100   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
8101 $as_echo "$python_prog_path" >&6; }
8102 else
8103   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8104 $as_echo "no" >&6; }
8105 fi
8106
8107
8108       if test "${python_prog_path}" = missing; then
8109         as_fn_error "unable to find python program ${python_prog}" "$LINENO" 5
8110       fi
8111       ;;
8112     esac
8113   esac
8114
8115   if test "${python_prog}" != missing; then
8116     # We have a python program to use, but it may be too old.
8117     # Don't flag an error for --with-python=auto (the default).
8118     have_python_config=yes
8119     python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
8120     if test $? != 0; then
8121       have_python_config=failed
8122       if test "${with_python}" != auto; then
8123         as_fn_error "failure running python-config --includes" "$LINENO" 5
8124       fi
8125     fi
8126     python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
8127     if test $? != 0; then
8128       have_python_config=failed
8129       if test "${with_python}" != auto; then
8130         as_fn_error "failure running python-config --ldflags" "$LINENO" 5
8131       fi
8132     fi
8133     python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
8134     if test $? != 0; then
8135       have_python_config=failed
8136       if test "${with_python}" != auto; then
8137         as_fn_error "failure running python-config --exec-prefix" "$LINENO" 5
8138       fi
8139     fi
8140   else
8141     # We do not have a python executable we can use to determine where
8142     # to find the Python headers and libs.  We cannot guess the include
8143     # path from the python_prefix either, because that include path
8144     # depends on the Python version.  So, there is nothing much we can
8145     # do except assume that the compiler will be able to find those files.
8146     python_includes=
8147     python_libs=
8148     have_python_config=no
8149   fi
8150
8151   # If we have python-config, only try the configuration it provides.
8152   # Otherwise fallback on the old way of trying different versions of
8153   # python in turn.
8154
8155   have_libpython=no
8156   if test "${have_python_config}" = yes; then
8157     # Determine the Python version by extracting "-lpython<version>"
8158     # part of the python_libs. <version> is usually X.Y with X and Y
8159     # being decimal numbers, but can also be XY (seen on Windows).
8160     #
8161     # The extraction is performed using sed with a regular expression.
8162     # Initially, the regexp used was using the '?' quantifier to make
8163     # the dot in the version number optional.  Unfortunately, this
8164     # does not work with non-GNU versions of sed because, because of
8165     # what looks like a limitation (the '?' quantifier does not work
8166     # with back-references).  We work around this limitation by using
8167     # the '*' quantifier instead.  It means that, in theory, we might
8168     # match unexpected version strings such as "-lpython2..7", but
8169     # this seems unlikely in practice.  And even if that happens,
8170     # an error will be triggered later on, when checking that version
8171     # number.
8172     python_version=`echo " ${python_libs} " \
8173                          | sed -e 's,^.* -l\(python[0-9]*[.]*[0-9]*\).*$,\1,'`
8174     case "${python_version}" in
8175     python*)
8176
8177   version=${python_version}
8178
8179   new_CPPFLAGS=${python_includes}
8180   new_LIBS=${python_libs}
8181   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8182 $as_echo_n "checking for ${version}... " >&6; }
8183   save_CPPFLAGS=$CPPFLAGS
8184   save_LIBS=$LIBS
8185   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8186   LIBS="$LIBS $new_LIBS"
8187   found_usable_python=no
8188   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8189 /* end confdefs.h.  */
8190 #include "Python.h"
8191 int
8192 main ()
8193 {
8194 Py_Initialize ();
8195   ;
8196   return 0;
8197 }
8198 _ACEOF
8199 if ac_fn_c_try_link "$LINENO"; then :
8200   have_libpython=${version}
8201                   found_usable_python=yes
8202                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8203                   PYTHON_LIBS=$new_LIBS
8204 fi
8205 rm -f core conftest.err conftest.$ac_objext \
8206     conftest$ac_exeext conftest.$ac_ext
8207   CPPFLAGS=$save_CPPFLAGS
8208   LIBS=$save_LIBS
8209   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8210 $as_echo "${found_usable_python}" >&6; }
8211
8212       ;;
8213     *)
8214       as_fn_error "unable to determine python version from ${python_libs}" "$LINENO" 5
8215       ;;
8216     esac
8217   elif test "${have_python_config}" != failed; then
8218     if test "${have_libpython}" = no; then
8219
8220   version=python2.7
8221
8222   new_CPPFLAGS=${python_includes}
8223   new_LIBS="${python_libs} -lpython2.7"
8224   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8225 $as_echo_n "checking for ${version}... " >&6; }
8226   save_CPPFLAGS=$CPPFLAGS
8227   save_LIBS=$LIBS
8228   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8229   LIBS="$LIBS $new_LIBS"
8230   found_usable_python=no
8231   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8232 /* end confdefs.h.  */
8233 #include "Python.h"
8234 int
8235 main ()
8236 {
8237 Py_Initialize ();
8238   ;
8239   return 0;
8240 }
8241 _ACEOF
8242 if ac_fn_c_try_link "$LINENO"; then :
8243   have_libpython=${version}
8244                   found_usable_python=yes
8245                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8246                   PYTHON_LIBS=$new_LIBS
8247 fi
8248 rm -f core conftest.err conftest.$ac_objext \
8249     conftest$ac_exeext conftest.$ac_ext
8250   CPPFLAGS=$save_CPPFLAGS
8251   LIBS=$save_LIBS
8252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8253 $as_echo "${found_usable_python}" >&6; }
8254
8255     fi
8256     if test "${have_libpython}" = no; then
8257
8258   version=python2.6
8259
8260   new_CPPFLAGS=${python_includes}
8261   new_LIBS="${python_libs} -lpython2.6"
8262   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8263 $as_echo_n "checking for ${version}... " >&6; }
8264   save_CPPFLAGS=$CPPFLAGS
8265   save_LIBS=$LIBS
8266   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8267   LIBS="$LIBS $new_LIBS"
8268   found_usable_python=no
8269   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8270 /* end confdefs.h.  */
8271 #include "Python.h"
8272 int
8273 main ()
8274 {
8275 Py_Initialize ();
8276   ;
8277   return 0;
8278 }
8279 _ACEOF
8280 if ac_fn_c_try_link "$LINENO"; then :
8281   have_libpython=${version}
8282                   found_usable_python=yes
8283                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8284                   PYTHON_LIBS=$new_LIBS
8285 fi
8286 rm -f core conftest.err conftest.$ac_objext \
8287     conftest$ac_exeext conftest.$ac_ext
8288   CPPFLAGS=$save_CPPFLAGS
8289   LIBS=$save_LIBS
8290   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8291 $as_echo "${found_usable_python}" >&6; }
8292
8293     fi
8294     if test ${have_libpython} = no; then
8295
8296   version=python2.5
8297
8298   new_CPPFLAGS=${python_includes}
8299   new_LIBS="${python_libs} -lpython2.5"
8300   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8301 $as_echo_n "checking for ${version}... " >&6; }
8302   save_CPPFLAGS=$CPPFLAGS
8303   save_LIBS=$LIBS
8304   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8305   LIBS="$LIBS $new_LIBS"
8306   found_usable_python=no
8307   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8308 /* end confdefs.h.  */
8309 #include "Python.h"
8310 int
8311 main ()
8312 {
8313 Py_Initialize ();
8314   ;
8315   return 0;
8316 }
8317 _ACEOF
8318 if ac_fn_c_try_link "$LINENO"; then :
8319   have_libpython=${version}
8320                   found_usable_python=yes
8321                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8322                   PYTHON_LIBS=$new_LIBS
8323 fi
8324 rm -f core conftest.err conftest.$ac_objext \
8325     conftest$ac_exeext conftest.$ac_ext
8326   CPPFLAGS=$save_CPPFLAGS
8327   LIBS=$save_LIBS
8328   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8329 $as_echo "${found_usable_python}" >&6; }
8330
8331     fi
8332     if test ${have_libpython} = no; then
8333
8334   version=python2.4
8335
8336   new_CPPFLAGS=${python_includes}
8337   new_LIBS="${python_libs} -lpython2.4"
8338   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8339 $as_echo_n "checking for ${version}... " >&6; }
8340   save_CPPFLAGS=$CPPFLAGS
8341   save_LIBS=$LIBS
8342   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8343   LIBS="$LIBS $new_LIBS"
8344   found_usable_python=no
8345   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8346 /* end confdefs.h.  */
8347 #include "Python.h"
8348 int
8349 main ()
8350 {
8351 Py_Initialize ();
8352   ;
8353   return 0;
8354 }
8355 _ACEOF
8356 if ac_fn_c_try_link "$LINENO"; then :
8357   have_libpython=${version}
8358                   found_usable_python=yes
8359                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8360                   PYTHON_LIBS=$new_LIBS
8361 fi
8362 rm -f core conftest.err conftest.$ac_objext \
8363     conftest$ac_exeext conftest.$ac_ext
8364   CPPFLAGS=$save_CPPFLAGS
8365   LIBS=$save_LIBS
8366   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8367 $as_echo "${found_usable_python}" >&6; }
8368
8369     fi
8370   fi
8371   if test "${have_libpython}" = python2.7 -o "${have_libpython}" = python27; then
8372
8373 $as_echo "#define HAVE_LIBPYTHON2_7 1" >>confdefs.h
8374
8375   elif test "${have_libpython}" = python2.6 -o "${have_libpython}" = python26; then
8376
8377 $as_echo "#define HAVE_LIBPYTHON2_6 1" >>confdefs.h
8378
8379   elif test "${have_libpython}" = python2.5 -o "${have_libpython}" = python25; then
8380
8381 $as_echo "#define HAVE_LIBPYTHON2_5 1" >>confdefs.h
8382
8383   elif test "${have_libpython}" = python2.4 -o "${have_libpython}" = python24; then
8384
8385 $as_echo "#define HAVE_LIBPYTHON2_4 1" >>confdefs.h
8386
8387   fi
8388
8389   if test "${have_libpython}" = no; then
8390     case "${with_python}" in
8391     yes)
8392       as_fn_error "python is missing or unusable" "$LINENO" 5
8393       ;;
8394     auto)
8395       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
8396 $as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
8397       ;;
8398     *)
8399       as_fn_error "no usable python found at ${with_python}" "$LINENO" 5
8400       ;;
8401     esac
8402   else
8403     if test -n "${python_prefix}"; then
8404
8405 cat >>confdefs.h <<_ACEOF
8406 #define WITH_PYTHON_PATH "${python_prefix}"
8407 _ACEOF
8408
8409
8410   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
8411      if test "x$prefix" = xNONE; then
8412         test_prefix=/usr/local
8413      else
8414         test_prefix=$prefix
8415      fi
8416   else
8417      test_prefix=$exec_prefix
8418   fi
8419   value=0
8420   case ${python_prefix} in
8421      "${test_prefix}"|"${test_prefix}/"*|\
8422         '${exec_prefix}'|'${exec_prefix}/'*)
8423      value=1
8424      ;;
8425   esac
8426
8427 cat >>confdefs.h <<_ACEOF
8428 #define PYTHON_PATH_RELOCATABLE $value
8429 _ACEOF
8430
8431
8432     fi
8433   fi
8434 fi
8435
8436 if test "${have_libpython}" != no; then
8437
8438 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
8439
8440   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
8441   CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
8442   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
8443   CONFIG_INSTALL="$CONFIG_INSTALL install-python"
8444   ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
8445
8446   # Flags needed to compile Python code (taken from python-config --cflags).
8447   # We cannot call python-config directly because it will output whatever was
8448   # used when compiling the Python interpreter itself, including flags which
8449   # would make the python-related objects be compiled differently from the
8450   # rest of GDB (e.g., -O2 and -fPIC).
8451   if test "${GCC}" = yes; then
8452     tentative_python_cflags="-fno-strict-aliasing -DNDEBUG -fwrapv"
8453   fi
8454
8455   if test "x${tentative_python_cflags}" != x; then
8456     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
8457 $as_echo_n "checking compiler flags for python code... " >&6; }
8458     for flag in ${tentative_python_cflags}; do
8459       # Check that the compiler accepts it
8460       saved_CFLAGS="$CFLAGS"
8461       CFLAGS="$CFLAGS $flag"
8462       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8463 /* end confdefs.h.  */
8464
8465 int
8466 main ()
8467 {
8468
8469   ;
8470   return 0;
8471 }
8472 _ACEOF
8473 if ac_fn_c_try_compile "$LINENO"; then :
8474   PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
8475 fi
8476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8477       CFLAGS="$saved_CFLAGS"
8478     done
8479     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
8480 $as_echo "${PYTHON_CFLAGS}" >&6; }
8481   fi
8482
8483   # On IRIX, type siginfo is not defined.  Instead, sys/siginfo.h provides:
8484   #    #if _SGIAPI
8485   #    #define siginfo __siginfo
8486   #    #endif
8487   # The problem is that including Python causes some XOPEN macros to be
8488   # unilaterally defined, and that in turn causes _SGIAPI to evaluate
8489   # to false.  So, we work around this issue by defining siginfo ourself
8490   # though the command-line.
8491   #
8492   # On x64 Windows, Python's include headers, and pyconfig.h in
8493   # particular, rely on MS_WIN64 macro to detect that it's a 64bit
8494   # version of Windows.  Unfortunately, MS_WIN64 is only defined if
8495   # _MSC_VER, a Microsoft-specific macro, is defined.  So, when
8496   # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
8497   # The issue was reported to the Python community, but still isn't
8498   # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
8499
8500   case "$gdb_host" in
8501     irix*) if test "${GCC}" = yes; then
8502              CPPFLAGS="$CPPFLAGS -Dsiginfo=__siginfo"
8503            fi
8504            ;;
8505     mingw64)
8506            if test "${GCC}" = yes; then
8507              CPPFLAGS="$CPPFLAGS -DMS_WIN64"
8508            fi
8509            ;;
8510   esac
8511
8512   # Note that "python -m threading" cannot be used to check for
8513   # threading support due to a bug in Python 2.7.3
8514   # (http://bugs.python.org/issue15567).
8515   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether python supports threads" >&5
8516 $as_echo_n "checking whether python supports threads... " >&6; }
8517   saved_CPPFLAGS="${CPPFLAGS}"
8518   CPPFLAGS="${PYTHON_CPPFLAGS}"
8519   # Note that the test is reversed so that python_has_threads=yes on
8520   # unexpected failures.
8521   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8522 /* end confdefs.h.  */
8523
8524 #include <Python.h>
8525 #ifdef WITH_THREAD
8526 # error
8527 #endif
8528
8529 _ACEOF
8530 if ac_fn_c_try_cpp "$LINENO"; then :
8531   python_has_threads=no
8532 else
8533   python_has_threads=yes
8534 fi
8535 rm -f conftest.err conftest.$ac_ext
8536   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_has_threads}" >&5
8537 $as_echo "${python_has_threads}" >&6; }
8538   CPPFLAGS="${saved_CPPFLAGS}"
8539 else
8540   # Even if Python support is not compiled in, we need to have these files
8541   # included.
8542   CONFIG_OBS="$CONFIG_OBS python.o py-value.o py-prettyprint.o py-auto-load.o"
8543   CONFIG_SRCS="$CONFIG_SRCS python/python.c python/py-value.c \
8544         python/py-prettyprint.c python/py-auto-load.c"
8545 fi
8546
8547
8548
8549
8550 # Provide a --enable-libmcheck/--disable-libmcheck set of options
8551 # allowing a user to enable this option even when building releases,
8552 # or to disable it when building a snapshot.
8553 # Check whether --enable-libmcheck was given.
8554 if test "${enable_libmcheck+set}" = set; then :
8555   enableval=$enable_libmcheck; case "${enableval}" in
8556      yes | y) ENABLE_LIBMCHECK="yes" ;;
8557      no | n)  ENABLE_LIBMCHECK="no" ;;
8558      *) as_fn_error "bad value ${enableval} for --enable-libmcheck" "$LINENO" 5 ;;
8559    esac
8560 fi
8561
8562
8563 # Enable -lmcheck by default (it provides cheap-enough memory mangling),
8564 # but turn it off if Python is enabled with threads, since -lmcheck is
8565 # not thread safe (http://sourceware.org/bugzilla/show_bug.cgi?id=9939),
8566 # and for releases.
8567 if test -z "${ENABLE_LIBMCHECK}" \
8568         -a \( "${have_libpython}" = "no" \
8569              -o "${python_has_threads}" = "no" \) \
8570     && $development; then
8571   ENABLE_LIBMCHECK=yes
8572 fi
8573
8574 if test "$ENABLE_LIBMCHECK" = "yes" ; then
8575   if test "${have_libpython}" != "no" -a "${python_has_threads}" = "yes" ; then
8576     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&5
8577 $as_echo "$as_me: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&2;}
8578   fi
8579   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lmcheck" >&5
8580 $as_echo_n "checking for main in -lmcheck... " >&6; }
8581 if test "${ac_cv_lib_mcheck_main+set}" = set; then :
8582   $as_echo_n "(cached) " >&6
8583 else
8584   ac_check_lib_save_LIBS=$LIBS
8585 LIBS="-lmcheck  $LIBS"
8586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8587 /* end confdefs.h.  */
8588
8589
8590 int
8591 main ()
8592 {
8593 return main ();
8594   ;
8595   return 0;
8596 }
8597 _ACEOF
8598 if ac_fn_c_try_link "$LINENO"; then :
8599   ac_cv_lib_mcheck_main=yes
8600 else
8601   ac_cv_lib_mcheck_main=no
8602 fi
8603 rm -f core conftest.err conftest.$ac_objext \
8604     conftest$ac_exeext conftest.$ac_ext
8605 LIBS=$ac_check_lib_save_LIBS
8606 fi
8607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mcheck_main" >&5
8608 $as_echo "$ac_cv_lib_mcheck_main" >&6; }
8609 if test "x$ac_cv_lib_mcheck_main" = x""yes; then :
8610   cat >>confdefs.h <<_ACEOF
8611 #define HAVE_LIBMCHECK 1
8612 _ACEOF
8613
8614   LIBS="-lmcheck $LIBS"
8615
8616 fi
8617
8618 fi
8619
8620 # ------------------------- #
8621 # Checks for header files.  #
8622 # ------------------------- #
8623
8624 ac_header_dirent=no
8625 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
8626   as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
8627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
8628 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
8629 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then :
8630   $as_echo_n "(cached) " >&6
8631 else
8632   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8633 /* end confdefs.h.  */
8634 #include <sys/types.h>
8635 #include <$ac_hdr>
8636
8637 int
8638 main ()
8639 {
8640 if ((DIR *) 0)
8641 return 0;
8642   ;
8643   return 0;
8644 }
8645 _ACEOF
8646 if ac_fn_c_try_compile "$LINENO"; then :
8647   eval "$as_ac_Header=yes"
8648 else
8649   eval "$as_ac_Header=no"
8650 fi
8651 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8652 fi
8653 eval ac_res=\$$as_ac_Header
8654                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8655 $as_echo "$ac_res" >&6; }
8656 eval as_val=\$$as_ac_Header
8657    if test "x$as_val" = x""yes; then :
8658   cat >>confdefs.h <<_ACEOF
8659 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
8660 _ACEOF
8661
8662 ac_header_dirent=$ac_hdr; break
8663 fi
8664
8665 done
8666 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
8667 if test $ac_header_dirent = dirent.h; then
8668   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8669 $as_echo_n "checking for library containing opendir... " >&6; }
8670 if test "${ac_cv_search_opendir+set}" = set; then :
8671   $as_echo_n "(cached) " >&6
8672 else
8673   ac_func_search_save_LIBS=$LIBS
8674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8675 /* end confdefs.h.  */
8676
8677 /* Override any GCC internal prototype to avoid an error.
8678    Use char because int might match the return type of a GCC
8679    builtin and then its argument prototype would still apply.  */
8680 #ifdef __cplusplus
8681 extern "C"
8682 #endif
8683 char opendir ();
8684 int
8685 main ()
8686 {
8687 return opendir ();
8688   ;
8689   return 0;
8690 }
8691 _ACEOF
8692 for ac_lib in '' dir; do
8693   if test -z "$ac_lib"; then
8694     ac_res="none required"
8695   else
8696     ac_res=-l$ac_lib
8697     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8698   fi
8699   if ac_fn_c_try_link "$LINENO"; then :
8700   ac_cv_search_opendir=$ac_res
8701 fi
8702 rm -f core conftest.err conftest.$ac_objext \
8703     conftest$ac_exeext
8704   if test "${ac_cv_search_opendir+set}" = set; then :
8705   break
8706 fi
8707 done
8708 if test "${ac_cv_search_opendir+set}" = set; then :
8709
8710 else
8711   ac_cv_search_opendir=no
8712 fi
8713 rm conftest.$ac_ext
8714 LIBS=$ac_func_search_save_LIBS
8715 fi
8716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8717 $as_echo "$ac_cv_search_opendir" >&6; }
8718 ac_res=$ac_cv_search_opendir
8719 if test "$ac_res" != no; then :
8720   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8721
8722 fi
8723
8724 else
8725   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8726 $as_echo_n "checking for library containing opendir... " >&6; }
8727 if test "${ac_cv_search_opendir+set}" = set; then :
8728   $as_echo_n "(cached) " >&6
8729 else
8730   ac_func_search_save_LIBS=$LIBS
8731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8732 /* end confdefs.h.  */
8733
8734 /* Override any GCC internal prototype to avoid an error.
8735    Use char because int might match the return type of a GCC
8736    builtin and then its argument prototype would still apply.  */
8737 #ifdef __cplusplus
8738 extern "C"
8739 #endif
8740 char opendir ();
8741 int
8742 main ()
8743 {
8744 return opendir ();
8745   ;
8746   return 0;
8747 }
8748 _ACEOF
8749 for ac_lib in '' x; do
8750   if test -z "$ac_lib"; then
8751     ac_res="none required"
8752   else
8753     ac_res=-l$ac_lib
8754     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8755   fi
8756   if ac_fn_c_try_link "$LINENO"; then :
8757   ac_cv_search_opendir=$ac_res
8758 fi
8759 rm -f core conftest.err conftest.$ac_objext \
8760     conftest$ac_exeext
8761   if test "${ac_cv_search_opendir+set}" = set; then :
8762   break
8763 fi
8764 done
8765 if test "${ac_cv_search_opendir+set}" = set; then :
8766
8767 else
8768   ac_cv_search_opendir=no
8769 fi
8770 rm conftest.$ac_ext
8771 LIBS=$ac_func_search_save_LIBS
8772 fi
8773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8774 $as_echo "$ac_cv_search_opendir" >&6; }
8775 ac_res=$ac_cv_search_opendir
8776 if test "$ac_res" != no; then :
8777   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8778
8779 fi
8780
8781 fi
8782
8783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
8784 $as_echo_n "checking for ANSI C header files... " >&6; }
8785 if test "${ac_cv_header_stdc+set}" = set; then :
8786   $as_echo_n "(cached) " >&6
8787 else
8788   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8789 /* end confdefs.h.  */
8790 #include <stdlib.h>
8791 #include <stdarg.h>
8792 #include <string.h>
8793 #include <float.h>
8794
8795 int
8796 main ()
8797 {
8798
8799   ;
8800   return 0;
8801 }
8802 _ACEOF
8803 if ac_fn_c_try_compile "$LINENO"; then :
8804   ac_cv_header_stdc=yes
8805 else
8806   ac_cv_header_stdc=no
8807 fi
8808 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8809
8810 if test $ac_cv_header_stdc = yes; then
8811   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8812   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8813 /* end confdefs.h.  */
8814 #include <string.h>
8815
8816 _ACEOF
8817 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8818   $EGREP "memchr" >/dev/null 2>&1; then :
8819
8820 else
8821   ac_cv_header_stdc=no
8822 fi
8823 rm -f conftest*
8824
8825 fi
8826
8827 if test $ac_cv_header_stdc = yes; then
8828   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8829   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8830 /* end confdefs.h.  */
8831 #include <stdlib.h>
8832
8833 _ACEOF
8834 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8835   $EGREP "free" >/dev/null 2>&1; then :
8836
8837 else
8838   ac_cv_header_stdc=no
8839 fi
8840 rm -f conftest*
8841
8842 fi
8843
8844 if test $ac_cv_header_stdc = yes; then
8845   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8846   if test "$cross_compiling" = yes; then :
8847   :
8848 else
8849   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8850 /* end confdefs.h.  */
8851 #include <ctype.h>
8852 #include <stdlib.h>
8853 #if ((' ' & 0x0FF) == 0x020)
8854 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8855 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8856 #else
8857 # define ISLOWER(c) \
8858                    (('a' <= (c) && (c) <= 'i') \
8859                      || ('j' <= (c) && (c) <= 'r') \
8860                      || ('s' <= (c) && (c) <= 'z'))
8861 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8862 #endif
8863
8864 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8865 int
8866 main ()
8867 {
8868   int i;
8869   for (i = 0; i < 256; i++)
8870     if (XOR (islower (i), ISLOWER (i))
8871         || toupper (i) != TOUPPER (i))
8872       return 2;
8873   return 0;
8874 }
8875 _ACEOF
8876 if ac_fn_c_try_run "$LINENO"; then :
8877
8878 else
8879   ac_cv_header_stdc=no
8880 fi
8881 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8882   conftest.$ac_objext conftest.beam conftest.$ac_ext
8883 fi
8884
8885 fi
8886 fi
8887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8888 $as_echo "$ac_cv_header_stdc" >&6; }
8889 if test $ac_cv_header_stdc = yes; then
8890
8891 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
8892
8893 fi
8894
8895 # elf_hp.h is for HP/UX 64-bit shared library support.
8896 for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
8897                   thread_db.h signal.h stddef.h \
8898                   stdlib.h string.h memory.h strings.h sys/fault.h \
8899                   sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
8900                   sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
8901                   sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
8902                   sys/types.h sys/wait.h wait.h termios.h termio.h \
8903                   sgtty.h unistd.h elf_hp.h locale.h \
8904                   dlfcn.h sys/socket.h sys/un.h linux/perf_event.h
8905 do :
8906   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8907 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8908 eval as_val=\$$as_ac_Header
8909    if test "x$as_val" = x""yes; then :
8910   cat >>confdefs.h <<_ACEOF
8911 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8912 _ACEOF
8913
8914 fi
8915
8916 done
8917
8918 for ac_header in link.h
8919 do :
8920   ac_fn_c_check_header_compile "$LINENO" "link.h" "ac_cv_header_link_h" "#if HAVE_SYS_TYPES_H
8921 # include <sys/types.h>
8922 #endif
8923 #if HAVE_NLIST_H
8924 # include <nlist.h>
8925 #endif
8926
8927 "
8928 if test "x$ac_cv_header_link_h" = x""yes; then :
8929   cat >>confdefs.h <<_ACEOF
8930 #define HAVE_LINK_H 1
8931 _ACEOF
8932
8933 fi
8934
8935 done
8936
8937 for ac_header in sys/proc.h
8938 do :
8939   ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" "#if HAVE_SYS_PARAM_H
8940 # include <sys/param.h>
8941 #endif
8942
8943 "
8944 if test "x$ac_cv_header_sys_proc_h" = x""yes; then :
8945   cat >>confdefs.h <<_ACEOF
8946 #define HAVE_SYS_PROC_H 1
8947 _ACEOF
8948
8949 fi
8950
8951 done
8952
8953 for ac_header in sys/user.h
8954 do :
8955   ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
8956 # include <sys/param.h>
8957 #endif
8958
8959 "
8960 if test "x$ac_cv_header_sys_user_h" = x""yes; then :
8961   cat >>confdefs.h <<_ACEOF
8962 #define HAVE_SYS_USER_H 1
8963 _ACEOF
8964
8965 fi
8966
8967 done
8968
8969
8970 # On Solaris 2.[789], we need to define _MSE_INT_H to avoid a clash
8971 # between <widec.h> and <wchar.h> that would cause AC_CHECK_HEADERS to
8972 # think that we don't have <curses.h> if we're using GCC.
8973 case $host_os in
8974   solaris2.[789])
8975     if test "$GCC" = yes; then
8976
8977 $as_echo "#define _MSE_INT_H 1" >>confdefs.h
8978
8979     fi ;;
8980 esac
8981 for ac_header in curses.h cursesX.h ncurses.h ncurses/ncurses.h ncurses/term.h
8982 do :
8983   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8984 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8985 eval as_val=\$$as_ac_Header
8986    if test "x$as_val" = x""yes; then :
8987   cat >>confdefs.h <<_ACEOF
8988 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8989 _ACEOF
8990
8991 fi
8992
8993 done
8994
8995 for ac_header in term.h
8996 do :
8997   ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
8998 # include <curses.h>
8999 #endif
9000
9001 "
9002 if test "x$ac_cv_header_term_h" = x""yes; then :
9003   cat >>confdefs.h <<_ACEOF
9004 #define HAVE_TERM_H 1
9005 _ACEOF
9006
9007 fi
9008
9009 done
9010
9011
9012 # ------------------------- #
9013 # Checks for declarations.  #
9014 # ------------------------- #
9015
9016 ac_fn_c_check_decl "$LINENO" "free" "ac_cv_have_decl_free" "$ac_includes_default"
9017 if test "x$ac_cv_have_decl_free" = x""yes; then :
9018   ac_have_decl=1
9019 else
9020   ac_have_decl=0
9021 fi
9022
9023 cat >>confdefs.h <<_ACEOF
9024 #define HAVE_DECL_FREE $ac_have_decl
9025 _ACEOF
9026 ac_fn_c_check_decl "$LINENO" "malloc" "ac_cv_have_decl_malloc" "$ac_includes_default"
9027 if test "x$ac_cv_have_decl_malloc" = x""yes; then :
9028   ac_have_decl=1
9029 else
9030   ac_have_decl=0
9031 fi
9032
9033 cat >>confdefs.h <<_ACEOF
9034 #define HAVE_DECL_MALLOC $ac_have_decl
9035 _ACEOF
9036 ac_fn_c_check_decl "$LINENO" "realloc" "ac_cv_have_decl_realloc" "$ac_includes_default"
9037 if test "x$ac_cv_have_decl_realloc" = x""yes; then :
9038   ac_have_decl=1
9039 else
9040   ac_have_decl=0
9041 fi
9042
9043 cat >>confdefs.h <<_ACEOF
9044 #define HAVE_DECL_REALLOC $ac_have_decl
9045 _ACEOF
9046 ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
9047 if test "x$ac_cv_have_decl_strerror" = x""yes; then :
9048   ac_have_decl=1
9049 else
9050   ac_have_decl=0
9051 fi
9052
9053 cat >>confdefs.h <<_ACEOF
9054 #define HAVE_DECL_STRERROR $ac_have_decl
9055 _ACEOF
9056 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
9057 if test "x$ac_cv_have_decl_strstr" = x""yes; then :
9058   ac_have_decl=1
9059 else
9060   ac_have_decl=0
9061 fi
9062
9063 cat >>confdefs.h <<_ACEOF
9064 #define HAVE_DECL_STRSTR $ac_have_decl
9065 _ACEOF
9066 ac_fn_c_check_decl "$LINENO" "getopt" "ac_cv_have_decl_getopt" "$ac_includes_default"
9067 if test "x$ac_cv_have_decl_getopt" = x""yes; then :
9068   ac_have_decl=1
9069 else
9070   ac_have_decl=0
9071 fi
9072
9073 cat >>confdefs.h <<_ACEOF
9074 #define HAVE_DECL_GETOPT $ac_have_decl
9075 _ACEOF
9076 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
9077 if test "x$ac_cv_have_decl_snprintf" = x""yes; then :
9078   ac_have_decl=1
9079 else
9080   ac_have_decl=0
9081 fi
9082
9083 cat >>confdefs.h <<_ACEOF
9084 #define HAVE_DECL_SNPRINTF $ac_have_decl
9085 _ACEOF
9086 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
9087 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then :
9088   ac_have_decl=1
9089 else
9090   ac_have_decl=0
9091 fi
9092
9093 cat >>confdefs.h <<_ACEOF
9094 #define HAVE_DECL_VSNPRINTF $ac_have_decl
9095 _ACEOF
9096
9097
9098   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
9099 $as_echo_n "checking for LC_MESSAGES... " >&6; }
9100 if test "${am_cv_val_LC_MESSAGES+set}" = set; then :
9101   $as_echo_n "(cached) " >&6
9102 else
9103   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9104 /* end confdefs.h.  */
9105 #include <locale.h>
9106 int
9107 main ()
9108 {
9109 return LC_MESSAGES
9110   ;
9111   return 0;
9112 }
9113 _ACEOF
9114 if ac_fn_c_try_link "$LINENO"; then :
9115   am_cv_val_LC_MESSAGES=yes
9116 else
9117   am_cv_val_LC_MESSAGES=no
9118 fi
9119 rm -f core conftest.err conftest.$ac_objext \
9120     conftest$ac_exeext conftest.$ac_ext
9121 fi
9122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
9123 $as_echo "$am_cv_val_LC_MESSAGES" >&6; }
9124   if test $am_cv_val_LC_MESSAGES = yes; then
9125
9126 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
9127
9128   fi
9129
9130
9131 # ----------------------- #
9132 # Checks for structures.  #
9133 # ----------------------- #
9134
9135 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
9136 if test "x$ac_cv_member_struct_stat_st_blocks" = x""yes; then :
9137
9138 cat >>confdefs.h <<_ACEOF
9139 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
9140 _ACEOF
9141
9142
9143 fi
9144 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
9145 if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then :
9146
9147 cat >>confdefs.h <<_ACEOF
9148 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
9149 _ACEOF
9150
9151
9152 fi
9153
9154
9155 # ------------------ #
9156 # Checks for types.  #
9157 # ------------------ #
9158
9159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
9160 $as_echo_n "checking return type of signal handlers... " >&6; }
9161 if test "${ac_cv_type_signal+set}" = set; then :
9162   $as_echo_n "(cached) " >&6
9163 else
9164   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9165 /* end confdefs.h.  */
9166 #include <sys/types.h>
9167 #include <signal.h>
9168
9169 int
9170 main ()
9171 {
9172 return *(signal (0, 0)) (0) == 1;
9173   ;
9174   return 0;
9175 }
9176 _ACEOF
9177 if ac_fn_c_try_compile "$LINENO"; then :
9178   ac_cv_type_signal=int
9179 else
9180   ac_cv_type_signal=void
9181 fi
9182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9183 fi
9184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
9185 $as_echo "$ac_cv_type_signal" >&6; }
9186
9187 cat >>confdefs.h <<_ACEOF
9188 #define RETSIGTYPE $ac_cv_type_signal
9189 _ACEOF
9190
9191
9192 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
9193 #include <sys/socket.h>
9194
9195 "
9196 if test "x$ac_cv_type_socklen_t" = x""yes; then :
9197
9198 cat >>confdefs.h <<_ACEOF
9199 #define HAVE_SOCKLEN_T 1
9200 _ACEOF
9201
9202
9203 fi
9204
9205
9206 # ------------------------------------- #
9207 # Checks for compiler characteristics.  #
9208 # ------------------------------------- #
9209
9210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
9211 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
9212 if test "${ac_cv_c_const+set}" = set; then :
9213   $as_echo_n "(cached) " >&6
9214 else
9215   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9216 /* end confdefs.h.  */
9217
9218 int
9219 main ()
9220 {
9221 /* FIXME: Include the comments suggested by Paul. */
9222 #ifndef __cplusplus
9223   /* Ultrix mips cc rejects this.  */
9224   typedef int charset[2];
9225   const charset cs;
9226   /* SunOS 4.1.1 cc rejects this.  */
9227   char const *const *pcpcc;
9228   char **ppc;
9229   /* NEC SVR4.0.2 mips cc rejects this.  */
9230   struct point {int x, y;};
9231   static struct point const zero = {0,0};
9232   /* AIX XL C 1.02.0.0 rejects this.
9233      It does not let you subtract one const X* pointer from another in
9234      an arm of an if-expression whose if-part is not a constant
9235      expression */
9236   const char *g = "string";
9237   pcpcc = &g + (g ? g-g : 0);
9238   /* HPUX 7.0 cc rejects these. */
9239   ++pcpcc;
9240   ppc = (char**) pcpcc;
9241   pcpcc = (char const *const *) ppc;
9242   { /* SCO 3.2v4 cc rejects this.  */
9243     char *t;
9244     char const *s = 0 ? (char *) 0 : (char const *) 0;
9245
9246     *t++ = 0;
9247     if (s) return 0;
9248   }
9249   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9250     int x[] = {25, 17};
9251     const int *foo = &x[0];
9252     ++foo;
9253   }
9254   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9255     typedef const int *iptr;
9256     iptr p = 0;
9257     ++p;
9258   }
9259   { /* AIX XL C 1.02.0.0 rejects this saying
9260        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9261     struct s { int j; const int *ap[3]; };
9262     struct s *b; b->j = 5;
9263   }
9264   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9265     const int foo = 10;
9266     if (!foo) return 0;
9267   }
9268   return !cs[0] && !zero.x;
9269 #endif
9270
9271   ;
9272   return 0;
9273 }
9274 _ACEOF
9275 if ac_fn_c_try_compile "$LINENO"; then :
9276   ac_cv_c_const=yes
9277 else
9278   ac_cv_c_const=no
9279 fi
9280 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9281 fi
9282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
9283 $as_echo "$ac_cv_c_const" >&6; }
9284 if test $ac_cv_c_const = no; then
9285
9286 $as_echo "#define const /**/" >>confdefs.h
9287
9288 fi
9289
9290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
9291 $as_echo_n "checking for inline... " >&6; }
9292 if test "${ac_cv_c_inline+set}" = set; then :
9293   $as_echo_n "(cached) " >&6
9294 else
9295   ac_cv_c_inline=no
9296 for ac_kw in inline __inline__ __inline; do
9297   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9298 /* end confdefs.h.  */
9299 #ifndef __cplusplus
9300 typedef int foo_t;
9301 static $ac_kw foo_t static_foo () {return 0; }
9302 $ac_kw foo_t foo () {return 0; }
9303 #endif
9304
9305 _ACEOF
9306 if ac_fn_c_try_compile "$LINENO"; then :
9307   ac_cv_c_inline=$ac_kw
9308 fi
9309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9310   test "$ac_cv_c_inline" != no && break
9311 done
9312
9313 fi
9314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
9315 $as_echo "$ac_cv_c_inline" >&6; }
9316
9317 case $ac_cv_c_inline in
9318   inline | yes) ;;
9319   *)
9320     case $ac_cv_c_inline in
9321       no) ac_val=;;
9322       *) ac_val=$ac_cv_c_inline;;
9323     esac
9324     cat >>confdefs.h <<_ACEOF
9325 #ifndef __cplusplus
9326 #define inline $ac_val
9327 #endif
9328 _ACEOF
9329     ;;
9330 esac
9331
9332  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9333 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
9334 if test "${ac_cv_c_bigendian+set}" = set; then :
9335   $as_echo_n "(cached) " >&6
9336 else
9337   ac_cv_c_bigendian=unknown
9338     # See if we're dealing with a universal compiler.
9339     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9340 /* end confdefs.h.  */
9341 #ifndef __APPLE_CC__
9342                not a universal capable compiler
9343              #endif
9344              typedef int dummy;
9345
9346 _ACEOF
9347 if ac_fn_c_try_compile "$LINENO"; then :
9348
9349         # Check for potential -arch flags.  It is not universal unless
9350         # there are at least two -arch flags with different values.
9351         ac_arch=
9352         ac_prev=
9353         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9354          if test -n "$ac_prev"; then
9355            case $ac_word in
9356              i?86 | x86_64 | ppc | ppc64)
9357                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9358                  ac_arch=$ac_word
9359                else
9360                  ac_cv_c_bigendian=universal
9361                  break
9362                fi
9363                ;;
9364            esac
9365            ac_prev=
9366          elif test "x$ac_word" = "x-arch"; then
9367            ac_prev=arch
9368          fi
9369        done
9370 fi
9371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9372     if test $ac_cv_c_bigendian = unknown; then
9373       # See if sys/param.h defines the BYTE_ORDER macro.
9374       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9375 /* end confdefs.h.  */
9376 #include <sys/types.h>
9377              #include <sys/param.h>
9378
9379 int
9380 main ()
9381 {
9382 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9383                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9384                      && LITTLE_ENDIAN)
9385               bogus endian macros
9386              #endif
9387
9388   ;
9389   return 0;
9390 }
9391 _ACEOF
9392 if ac_fn_c_try_compile "$LINENO"; then :
9393   # It does; now see whether it defined to BIG_ENDIAN or not.
9394          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9395 /* end confdefs.h.  */
9396 #include <sys/types.h>
9397                 #include <sys/param.h>
9398
9399 int
9400 main ()
9401 {
9402 #if BYTE_ORDER != BIG_ENDIAN
9403                  not big endian
9404                 #endif
9405
9406   ;
9407   return 0;
9408 }
9409 _ACEOF
9410 if ac_fn_c_try_compile "$LINENO"; then :
9411   ac_cv_c_bigendian=yes
9412 else
9413   ac_cv_c_bigendian=no
9414 fi
9415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9416 fi
9417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9418     fi
9419     if test $ac_cv_c_bigendian = unknown; then
9420       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9421       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9422 /* end confdefs.h.  */
9423 #include <limits.h>
9424
9425 int
9426 main ()
9427 {
9428 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9429               bogus endian macros
9430              #endif
9431
9432   ;
9433   return 0;
9434 }
9435 _ACEOF
9436 if ac_fn_c_try_compile "$LINENO"; then :
9437   # It does; now see whether it defined to _BIG_ENDIAN or not.
9438          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9439 /* end confdefs.h.  */
9440 #include <limits.h>
9441
9442 int
9443 main ()
9444 {
9445 #ifndef _BIG_ENDIAN
9446                  not big endian
9447                 #endif
9448
9449   ;
9450   return 0;
9451 }
9452 _ACEOF
9453 if ac_fn_c_try_compile "$LINENO"; then :
9454   ac_cv_c_bigendian=yes
9455 else
9456   ac_cv_c_bigendian=no
9457 fi
9458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9459 fi
9460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9461     fi
9462     if test $ac_cv_c_bigendian = unknown; then
9463       # Compile a test program.
9464       if test "$cross_compiling" = yes; then :
9465   # Try to guess by grepping values from an object file.
9466          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9467 /* end confdefs.h.  */
9468 short int ascii_mm[] =
9469                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9470                 short int ascii_ii[] =
9471                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9472                 int use_ascii (int i) {
9473                   return ascii_mm[i] + ascii_ii[i];
9474                 }
9475                 short int ebcdic_ii[] =
9476                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9477                 short int ebcdic_mm[] =
9478                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9479                 int use_ebcdic (int i) {
9480                   return ebcdic_mm[i] + ebcdic_ii[i];
9481                 }
9482                 extern int foo;
9483
9484 int
9485 main ()
9486 {
9487 return use_ascii (foo) == use_ebcdic (foo);
9488   ;
9489   return 0;
9490 }
9491 _ACEOF
9492 if ac_fn_c_try_compile "$LINENO"; then :
9493   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9494               ac_cv_c_bigendian=yes
9495             fi
9496             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9497               if test "$ac_cv_c_bigendian" = unknown; then
9498                 ac_cv_c_bigendian=no
9499               else
9500                 # finding both strings is unlikely to happen, but who knows?
9501                 ac_cv_c_bigendian=unknown
9502               fi
9503             fi
9504 fi
9505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9506 else
9507   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9508 /* end confdefs.h.  */
9509 $ac_includes_default
9510 int
9511 main ()
9512 {
9513
9514              /* Are we little or big endian?  From Harbison&Steele.  */
9515              union
9516              {
9517                long int l;
9518                char c[sizeof (long int)];
9519              } u;
9520              u.l = 1;
9521              return u.c[sizeof (long int) - 1] == 1;
9522
9523   ;
9524   return 0;
9525 }
9526 _ACEOF
9527 if ac_fn_c_try_run "$LINENO"; then :
9528   ac_cv_c_bigendian=no
9529 else
9530   ac_cv_c_bigendian=yes
9531 fi
9532 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9533   conftest.$ac_objext conftest.beam conftest.$ac_ext
9534 fi
9535
9536     fi
9537 fi
9538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9539 $as_echo "$ac_cv_c_bigendian" >&6; }
9540  case $ac_cv_c_bigendian in #(
9541    yes)
9542      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9543 ;; #(
9544    no)
9545       ;; #(
9546    universal)
9547
9548 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9549
9550      ;; #(
9551    *)
9552      as_fn_error "unknown endianness
9553  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9554  esac
9555
9556
9557 # ------------------------------ #
9558 # Checks for library functions.  #
9559 # ------------------------------ #
9560
9561 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
9562 # for constant arguments.  Useless!
9563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
9564 $as_echo_n "checking for working alloca.h... " >&6; }
9565 if test "${ac_cv_working_alloca_h+set}" = set; then :
9566   $as_echo_n "(cached) " >&6
9567 else
9568   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9569 /* end confdefs.h.  */
9570 #include <alloca.h>
9571 int
9572 main ()
9573 {
9574 char *p = (char *) alloca (2 * sizeof (int));
9575                           if (p) return 0;
9576   ;
9577   return 0;
9578 }
9579 _ACEOF
9580 if ac_fn_c_try_link "$LINENO"; then :
9581   ac_cv_working_alloca_h=yes
9582 else
9583   ac_cv_working_alloca_h=no
9584 fi
9585 rm -f core conftest.err conftest.$ac_objext \
9586     conftest$ac_exeext conftest.$ac_ext
9587 fi
9588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
9589 $as_echo "$ac_cv_working_alloca_h" >&6; }
9590 if test $ac_cv_working_alloca_h = yes; then
9591
9592 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
9593
9594 fi
9595
9596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
9597 $as_echo_n "checking for alloca... " >&6; }
9598 if test "${ac_cv_func_alloca_works+set}" = set; then :
9599   $as_echo_n "(cached) " >&6
9600 else
9601   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9602 /* end confdefs.h.  */
9603 #ifdef __GNUC__
9604 # define alloca __builtin_alloca
9605 #else
9606 # ifdef _MSC_VER
9607 #  include <malloc.h>
9608 #  define alloca _alloca
9609 # else
9610 #  ifdef HAVE_ALLOCA_H
9611 #   include <alloca.h>
9612 #  else
9613 #   ifdef _AIX
9614  #pragma alloca
9615 #   else
9616 #    ifndef alloca /* predefined by HP cc +Olibcalls */
9617 char *alloca ();
9618 #    endif
9619 #   endif
9620 #  endif
9621 # endif
9622 #endif
9623
9624 int
9625 main ()
9626 {
9627 char *p = (char *) alloca (1);
9628                                     if (p) return 0;
9629   ;
9630   return 0;
9631 }
9632 _ACEOF
9633 if ac_fn_c_try_link "$LINENO"; then :
9634   ac_cv_func_alloca_works=yes
9635 else
9636   ac_cv_func_alloca_works=no
9637 fi
9638 rm -f core conftest.err conftest.$ac_objext \
9639     conftest$ac_exeext conftest.$ac_ext
9640 fi
9641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
9642 $as_echo "$ac_cv_func_alloca_works" >&6; }
9643
9644 if test $ac_cv_func_alloca_works = yes; then
9645
9646 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
9647
9648 else
9649   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
9650 # that cause trouble.  Some versions do not even contain alloca or
9651 # contain a buggy version.  If you still want to use their alloca,
9652 # use ar to extract alloca.o from them instead of compiling alloca.c.
9653
9654 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
9655
9656 $as_echo "#define C_ALLOCA 1" >>confdefs.h
9657
9658
9659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
9660 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
9661 if test "${ac_cv_os_cray+set}" = set; then :
9662   $as_echo_n "(cached) " >&6
9663 else
9664   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9665 /* end confdefs.h.  */
9666 #if defined CRAY && ! defined CRAY2
9667 webecray
9668 #else
9669 wenotbecray
9670 #endif
9671
9672 _ACEOF
9673 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9674   $EGREP "webecray" >/dev/null 2>&1; then :
9675   ac_cv_os_cray=yes
9676 else
9677   ac_cv_os_cray=no
9678 fi
9679 rm -f conftest*
9680
9681 fi
9682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
9683 $as_echo "$ac_cv_os_cray" >&6; }
9684 if test $ac_cv_os_cray = yes; then
9685   for ac_func in _getb67 GETB67 getb67; do
9686     as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9687 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9688 eval as_val=\$$as_ac_var
9689    if test "x$as_val" = x""yes; then :
9690
9691 cat >>confdefs.h <<_ACEOF
9692 #define CRAY_STACKSEG_END $ac_func
9693 _ACEOF
9694
9695     break
9696 fi
9697
9698   done
9699 fi
9700
9701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
9702 $as_echo_n "checking stack direction for C alloca... " >&6; }
9703 if test "${ac_cv_c_stack_direction+set}" = set; then :
9704   $as_echo_n "(cached) " >&6
9705 else
9706   if test "$cross_compiling" = yes; then :
9707   ac_cv_c_stack_direction=0
9708 else
9709   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9710 /* end confdefs.h.  */
9711 $ac_includes_default
9712 int
9713 find_stack_direction ()
9714 {
9715   static char *addr = 0;
9716   auto char dummy;
9717   if (addr == 0)
9718     {
9719       addr = &dummy;
9720       return find_stack_direction ();
9721     }
9722   else
9723     return (&dummy > addr) ? 1 : -1;
9724 }
9725
9726 int
9727 main ()
9728 {
9729   return find_stack_direction () < 0;
9730 }
9731 _ACEOF
9732 if ac_fn_c_try_run "$LINENO"; then :
9733   ac_cv_c_stack_direction=1
9734 else
9735   ac_cv_c_stack_direction=-1
9736 fi
9737 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9738   conftest.$ac_objext conftest.beam conftest.$ac_ext
9739 fi
9740
9741 fi
9742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
9743 $as_echo "$ac_cv_c_stack_direction" >&6; }
9744 cat >>confdefs.h <<_ACEOF
9745 #define STACK_DIRECTION $ac_cv_c_stack_direction
9746 _ACEOF
9747
9748
9749 fi
9750
9751 for ac_header in stdlib.h unistd.h
9752 do :
9753   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9754 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9755 eval as_val=\$$as_ac_Header
9756    if test "x$as_val" = x""yes; then :
9757   cat >>confdefs.h <<_ACEOF
9758 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9759 _ACEOF
9760
9761 fi
9762
9763 done
9764
9765 for ac_func in getpagesize
9766 do :
9767   ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9768 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9769   cat >>confdefs.h <<_ACEOF
9770 #define HAVE_GETPAGESIZE 1
9771 _ACEOF
9772
9773 fi
9774 done
9775
9776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9777 $as_echo_n "checking for working mmap... " >&6; }
9778 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9779   $as_echo_n "(cached) " >&6
9780 else
9781   if test "$cross_compiling" = yes; then :
9782   ac_cv_func_mmap_fixed_mapped=no
9783 else
9784   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9785 /* end confdefs.h.  */
9786 $ac_includes_default
9787 /* malloc might have been renamed as rpl_malloc. */
9788 #undef malloc
9789
9790 /* Thanks to Mike Haertel and Jim Avera for this test.
9791    Here is a matrix of mmap possibilities:
9792         mmap private not fixed
9793         mmap private fixed at somewhere currently unmapped
9794         mmap private fixed at somewhere already mapped
9795         mmap shared not fixed
9796         mmap shared fixed at somewhere currently unmapped
9797         mmap shared fixed at somewhere already mapped
9798    For private mappings, we should verify that changes cannot be read()
9799    back from the file, nor mmap's back from the file at a different
9800    address.  (There have been systems where private was not correctly
9801    implemented like the infamous i386 svr4.0, and systems where the
9802    VM page cache was not coherent with the file system buffer cache
9803    like early versions of FreeBSD and possibly contemporary NetBSD.)
9804    For shared mappings, we should conversely verify that changes get
9805    propagated back to all the places they're supposed to be.
9806
9807    Grep wants private fixed already mapped.
9808    The main things grep needs to know about mmap are:
9809    * does it exist and is it safe to write into the mmap'd area
9810    * how to use it (BSD variants)  */
9811
9812 #include <fcntl.h>
9813 #include <sys/mman.h>
9814
9815 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9816 char *malloc ();
9817 #endif
9818
9819 /* This mess was copied from the GNU getpagesize.h.  */
9820 #ifndef HAVE_GETPAGESIZE
9821 /* Assume that all systems that can run configure have sys/param.h.  */
9822 # ifndef HAVE_SYS_PARAM_H
9823 #  define HAVE_SYS_PARAM_H 1
9824 # endif
9825
9826 # ifdef _SC_PAGESIZE
9827 #  define getpagesize() sysconf(_SC_PAGESIZE)
9828 # else /* no _SC_PAGESIZE */
9829 #  ifdef HAVE_SYS_PARAM_H
9830 #   include <sys/param.h>
9831 #   ifdef EXEC_PAGESIZE
9832 #    define getpagesize() EXEC_PAGESIZE
9833 #   else /* no EXEC_PAGESIZE */
9834 #    ifdef NBPG
9835 #     define getpagesize() NBPG * CLSIZE
9836 #     ifndef CLSIZE
9837 #      define CLSIZE 1
9838 #     endif /* no CLSIZE */
9839 #    else /* no NBPG */
9840 #     ifdef NBPC
9841 #      define getpagesize() NBPC
9842 #     else /* no NBPC */
9843 #      ifdef PAGESIZE
9844 #       define getpagesize() PAGESIZE
9845 #      endif /* PAGESIZE */
9846 #     endif /* no NBPC */
9847 #    endif /* no NBPG */
9848 #   endif /* no EXEC_PAGESIZE */
9849 #  else /* no HAVE_SYS_PARAM_H */
9850 #   define getpagesize() 8192   /* punt totally */
9851 #  endif /* no HAVE_SYS_PARAM_H */
9852 # endif /* no _SC_PAGESIZE */
9853
9854 #endif /* no HAVE_GETPAGESIZE */
9855
9856 int
9857 main ()
9858 {
9859   char *data, *data2, *data3;
9860   int i, pagesize;
9861   int fd;
9862
9863   pagesize = getpagesize ();
9864
9865   /* First, make a file with some known garbage in it. */
9866   data = (char *) malloc (pagesize);
9867   if (!data)
9868     return 1;
9869   for (i = 0; i < pagesize; ++i)
9870     *(data + i) = rand ();
9871   umask (0);
9872   fd = creat ("conftest.mmap", 0600);
9873   if (fd < 0)
9874     return 1;
9875   if (write (fd, data, pagesize) != pagesize)
9876     return 1;
9877   close (fd);
9878
9879   /* Next, try to mmap the file at a fixed address which already has
9880      something else allocated at it.  If we can, also make sure that
9881      we see the same garbage.  */
9882   fd = open ("conftest.mmap", O_RDWR);
9883   if (fd < 0)
9884     return 1;
9885   data2 = (char *) malloc (2 * pagesize);
9886   if (!data2)
9887     return 1;
9888   data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1);
9889   if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9890                      MAP_PRIVATE | MAP_FIXED, fd, 0L))
9891     return 1;
9892   for (i = 0; i < pagesize; ++i)
9893     if (*(data + i) != *(data2 + i))
9894       return 1;
9895
9896   /* Finally, make sure that changes to the mapped area do not
9897      percolate back to the file as seen by read().  (This is a bug on
9898      some variants of i386 svr4.0.)  */
9899   for (i = 0; i < pagesize; ++i)
9900     *(data2 + i) = *(data2 + i) + 1;
9901   data3 = (char *) malloc (pagesize);
9902   if (!data3)
9903     return 1;
9904   if (read (fd, data3, pagesize) != pagesize)
9905     return 1;
9906   for (i = 0; i < pagesize; ++i)
9907     if (*(data + i) != *(data3 + i))
9908       return 1;
9909   close (fd);
9910   return 0;
9911 }
9912 _ACEOF
9913 if ac_fn_c_try_run "$LINENO"; then :
9914   ac_cv_func_mmap_fixed_mapped=yes
9915 else
9916   ac_cv_func_mmap_fixed_mapped=no
9917 fi
9918 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9919   conftest.$ac_objext conftest.beam conftest.$ac_ext
9920 fi
9921
9922 fi
9923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9924 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9925 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9926
9927 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9928
9929 fi
9930 rm -f conftest.mmap
9931
9932 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
9933 if test "x$ac_cv_type_pid_t" = x""yes; then :
9934
9935 else
9936
9937 cat >>confdefs.h <<_ACEOF
9938 #define pid_t int
9939 _ACEOF
9940
9941 fi
9942
9943 for ac_header in vfork.h
9944 do :
9945   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
9946 if test "x$ac_cv_header_vfork_h" = x""yes; then :
9947   cat >>confdefs.h <<_ACEOF
9948 #define HAVE_VFORK_H 1
9949 _ACEOF
9950
9951 fi
9952
9953 done
9954
9955 for ac_func in fork vfork
9956 do :
9957   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9958 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9959 eval as_val=\$$as_ac_var
9960    if test "x$as_val" = x""yes; then :
9961   cat >>confdefs.h <<_ACEOF
9962 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9963 _ACEOF
9964
9965 fi
9966 done
9967
9968 if test "x$ac_cv_func_fork" = xyes; then
9969   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
9970 $as_echo_n "checking for working fork... " >&6; }
9971 if test "${ac_cv_func_fork_works+set}" = set; then :
9972   $as_echo_n "(cached) " >&6
9973 else
9974   if test "$cross_compiling" = yes; then :
9975   ac_cv_func_fork_works=cross
9976 else
9977   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9978 /* end confdefs.h.  */
9979 $ac_includes_default
9980 int
9981 main ()
9982 {
9983
9984           /* By Ruediger Kuhlmann. */
9985           return fork () < 0;
9986
9987   ;
9988   return 0;
9989 }
9990 _ACEOF
9991 if ac_fn_c_try_run "$LINENO"; then :
9992   ac_cv_func_fork_works=yes
9993 else
9994   ac_cv_func_fork_works=no
9995 fi
9996 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9997   conftest.$ac_objext conftest.beam conftest.$ac_ext
9998 fi
9999
10000 fi
10001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
10002 $as_echo "$ac_cv_func_fork_works" >&6; }
10003
10004 else
10005   ac_cv_func_fork_works=$ac_cv_func_fork
10006 fi
10007 if test "x$ac_cv_func_fork_works" = xcross; then
10008   case $host in
10009     *-*-amigaos* | *-*-msdosdjgpp*)
10010       # Override, as these systems have only a dummy fork() stub
10011       ac_cv_func_fork_works=no
10012       ;;
10013     *)
10014       ac_cv_func_fork_works=yes
10015       ;;
10016   esac
10017   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
10018 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
10019 fi
10020 ac_cv_func_vfork_works=$ac_cv_func_vfork
10021 if test "x$ac_cv_func_vfork" = xyes; then
10022   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
10023 $as_echo_n "checking for working vfork... " >&6; }
10024 if test "${ac_cv_func_vfork_works+set}" = set; then :
10025   $as_echo_n "(cached) " >&6
10026 else
10027   if test "$cross_compiling" = yes; then :
10028   ac_cv_func_vfork_works=cross
10029 else
10030   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10031 /* end confdefs.h.  */
10032 /* Thanks to Paul Eggert for this test.  */
10033 $ac_includes_default
10034 #include <sys/wait.h>
10035 #ifdef HAVE_VFORK_H
10036 # include <vfork.h>
10037 #endif
10038 /* On some sparc systems, changes by the child to local and incoming
10039    argument registers are propagated back to the parent.  The compiler
10040    is told about this with #include <vfork.h>, but some compilers
10041    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
10042    static variable whose address is put into a register that is
10043    clobbered by the vfork.  */
10044 static void
10045 #ifdef __cplusplus
10046 sparc_address_test (int arg)
10047 # else
10048 sparc_address_test (arg) int arg;
10049 #endif
10050 {
10051   static pid_t child;
10052   if (!child) {
10053     child = vfork ();
10054     if (child < 0) {
10055       perror ("vfork");
10056       _exit(2);
10057     }
10058     if (!child) {
10059       arg = getpid();
10060       write(-1, "", 0);
10061       _exit (arg);
10062     }
10063   }
10064 }
10065
10066 int
10067 main ()
10068 {
10069   pid_t parent = getpid ();
10070   pid_t child;
10071
10072   sparc_address_test (0);
10073
10074   child = vfork ();
10075
10076   if (child == 0) {
10077     /* Here is another test for sparc vfork register problems.  This
10078        test uses lots of local variables, at least as many local
10079        variables as main has allocated so far including compiler
10080        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
10081        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
10082        reuse the register of parent for one of the local variables,
10083        since it will think that parent can't possibly be used any more
10084        in this routine.  Assigning to the local variable will thus
10085        munge parent in the parent process.  */
10086     pid_t
10087       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
10088       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
10089     /* Convince the compiler that p..p7 are live; otherwise, it might
10090        use the same hardware register for all 8 local variables.  */
10091     if (p != p1 || p != p2 || p != p3 || p != p4
10092         || p != p5 || p != p6 || p != p7)
10093       _exit(1);
10094
10095     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
10096        from child file descriptors.  If the child closes a descriptor
10097        before it execs or exits, this munges the parent's descriptor
10098        as well.  Test for this by closing stdout in the child.  */
10099     _exit(close(fileno(stdout)) != 0);
10100   } else {
10101     int status;
10102     struct stat st;
10103
10104     while (wait(&status) != child)
10105       ;
10106     return (
10107          /* Was there some problem with vforking?  */
10108          child < 0
10109
10110          /* Did the child fail?  (This shouldn't happen.)  */
10111          || status
10112
10113          /* Did the vfork/compiler bug occur?  */
10114          || parent != getpid()
10115
10116          /* Did the file descriptor bug occur?  */
10117          || fstat(fileno(stdout), &st) != 0
10118          );
10119   }
10120 }
10121 _ACEOF
10122 if ac_fn_c_try_run "$LINENO"; then :
10123   ac_cv_func_vfork_works=yes
10124 else
10125   ac_cv_func_vfork_works=no
10126 fi
10127 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10128   conftest.$ac_objext conftest.beam conftest.$ac_ext
10129 fi
10130
10131 fi
10132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
10133 $as_echo "$ac_cv_func_vfork_works" >&6; }
10134
10135 fi;
10136 if test "x$ac_cv_func_fork_works" = xcross; then
10137   ac_cv_func_vfork_works=$ac_cv_func_vfork
10138   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
10139 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
10140 fi
10141
10142 if test "x$ac_cv_func_vfork_works" = xyes; then
10143
10144 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
10145
10146 else
10147
10148 $as_echo "#define vfork fork" >>confdefs.h
10149
10150 fi
10151 if test "x$ac_cv_func_fork_works" = xyes; then
10152
10153 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
10154
10155 fi
10156
10157 for ac_func in canonicalize_file_name realpath getrusage getuid getgid \
10158                 pipe poll pread pread64 pwrite readlink resize_term \
10159                 sbrk setpgid setpgrp setsid \
10160                 sigaction sigprocmask sigsetmask socketpair syscall \
10161                 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
10162                 setrlimit getrlimit posix_madvise waitpid lstat
10163 do :
10164   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10165 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10166 eval as_val=\$$as_ac_var
10167    if test "x$as_val" = x""yes; then :
10168   cat >>confdefs.h <<_ACEOF
10169 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10170 _ACEOF
10171
10172 fi
10173 done
10174
10175
10176   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
10177 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
10178 if test "${am_cv_langinfo_codeset+set}" = set; then :
10179   $as_echo_n "(cached) " >&6
10180 else
10181   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10182 /* end confdefs.h.  */
10183 #include <langinfo.h>
10184 int
10185 main ()
10186 {
10187 char* cs = nl_langinfo(CODESET);
10188   ;
10189   return 0;
10190 }
10191 _ACEOF
10192 if ac_fn_c_try_link "$LINENO"; then :
10193   am_cv_langinfo_codeset=yes
10194 else
10195   am_cv_langinfo_codeset=no
10196 fi
10197 rm -f core conftest.err conftest.$ac_objext \
10198     conftest$ac_exeext conftest.$ac_ext
10199
10200 fi
10201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
10202 $as_echo "$am_cv_langinfo_codeset" >&6; }
10203   if test $am_cv_langinfo_codeset = yes; then
10204
10205 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
10206
10207   fi
10208
10209
10210 # Check the return and argument types of ptrace.  No canned test for
10211 # this, so roll our own.
10212 gdb_ptrace_headers='
10213 #if HAVE_SYS_TYPES_H
10214 # include <sys/types.h>
10215 #endif
10216 #if HAVE_SYS_PTRACE_H
10217 # include <sys/ptrace.h>
10218 #endif
10219 #if HAVE_UNISTD_H
10220 # include <unistd.h>
10221 #endif
10222 '
10223 # There is no point in checking if we don't have a prototype.
10224 ac_fn_c_check_decl "$LINENO" "ptrace" "ac_cv_have_decl_ptrace" "$gdb_ptrace_headers
10225 "
10226 if test "x$ac_cv_have_decl_ptrace" = x""yes; then :
10227   ac_have_decl=1
10228 else
10229   ac_have_decl=0
10230 fi
10231
10232 cat >>confdefs.h <<_ACEOF
10233 #define HAVE_DECL_PTRACE $ac_have_decl
10234 _ACEOF
10235 if test $ac_have_decl = 1; then :
10236
10237 else
10238
10239   : ${gdb_cv_func_ptrace_ret='int'}
10240   : ${gdb_cv_func_ptrace_args='int,int,long,long'}
10241
10242 fi
10243
10244 # Check return type.  Varargs (used on GNU/Linux) conflict with the
10245 # empty argument list, so check for that explicitly.
10246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
10247 $as_echo_n "checking return type of ptrace... " >&6; }
10248 if test "${gdb_cv_func_ptrace_ret+set}" = set; then :
10249   $as_echo_n "(cached) " >&6
10250 else
10251   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10252 /* end confdefs.h.  */
10253 $gdb_ptrace_headers
10254 int
10255 main ()
10256 {
10257 extern long ptrace (enum __ptrace_request, ...);
10258   ;
10259   return 0;
10260 }
10261 _ACEOF
10262 if ac_fn_c_try_compile "$LINENO"; then :
10263   gdb_cv_func_ptrace_ret='long'
10264 else
10265   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10266 /* end confdefs.h.  */
10267 $gdb_ptrace_headers
10268 int
10269 main ()
10270 {
10271 extern int ptrace ();
10272   ;
10273   return 0;
10274 }
10275 _ACEOF
10276 if ac_fn_c_try_compile "$LINENO"; then :
10277   gdb_cv_func_ptrace_ret='int'
10278 else
10279   gdb_cv_func_ptrace_ret='long'
10280 fi
10281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10282 fi
10283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10284 fi
10285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
10286 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
10287
10288 cat >>confdefs.h <<_ACEOF
10289 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
10290 _ACEOF
10291
10292 # Check argument types.
10293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
10294 $as_echo_n "checking types of arguments for ptrace... " >&6; }
10295 if test "${gdb_cv_func_ptrace_args+set}" = set; then :
10296   $as_echo_n "(cached) " >&6
10297 else
10298
10299   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10300 /* end confdefs.h.  */
10301 $gdb_ptrace_headers
10302 int
10303 main ()
10304 {
10305 extern long ptrace (enum __ptrace_request, ...);
10306   ;
10307   return 0;
10308 }
10309 _ACEOF
10310 if ac_fn_c_try_compile "$LINENO"; then :
10311   gdb_cv_func_ptrace_args='int,int,long,long'
10312 else
10313
10314 for gdb_arg1 in 'int' 'long'; do
10315  for gdb_arg2 in 'pid_t' 'int' 'long'; do
10316   for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
10317    for gdb_arg4 in 'int' 'long'; do
10318      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10319 /* end confdefs.h.  */
10320 $gdb_ptrace_headers
10321 int
10322 main ()
10323 {
10324
10325 extern $gdb_cv_func_ptrace_ret
10326   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
10327
10328   ;
10329   return 0;
10330 }
10331 _ACEOF
10332 if ac_fn_c_try_compile "$LINENO"; then :
10333   gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
10334     break 4;
10335 fi
10336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10337     for gdb_arg5 in 'int *' 'int' 'long'; do
10338      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10339 /* end confdefs.h.  */
10340 $gdb_ptrace_headers
10341 int
10342 main ()
10343 {
10344
10345 extern $gdb_cv_func_ptrace_ret
10346   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
10347
10348   ;
10349   return 0;
10350 }
10351 _ACEOF
10352 if ac_fn_c_try_compile "$LINENO"; then :
10353
10354 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
10355     break 5;
10356 fi
10357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10358     done
10359    done
10360   done
10361  done
10362 done
10363 # Provide a safe default value.
10364 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
10365
10366 fi
10367 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10368 fi
10369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
10370 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
10371 ac_save_IFS=$IFS; IFS=','
10372 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
10373 IFS=$ac_save_IFS
10374 shift
10375
10376 cat >>confdefs.h <<_ACEOF
10377 #define PTRACE_TYPE_ARG3 $3
10378 _ACEOF
10379
10380 if test -n "$5"; then
10381
10382 cat >>confdefs.h <<_ACEOF
10383 #define PTRACE_TYPE_ARG5 $5
10384 _ACEOF
10385
10386 fi
10387
10388 if test "$cross_compiling" = no; then
10389   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
10390 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
10391 if test "${ac_cv_func_setpgrp_void+set}" = set; then :
10392   $as_echo_n "(cached) " >&6
10393 else
10394   if test "$cross_compiling" = yes; then :
10395   as_fn_error "cannot check setpgrp when cross compiling" "$LINENO" 5
10396 else
10397   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10398 /* end confdefs.h.  */
10399 $ac_includes_default
10400 int
10401 main ()
10402 {
10403 /* If this system has a BSD-style setpgrp which takes arguments,
10404   setpgrp(1, 1) will fail with ESRCH and return -1, in that case
10405   exit successfully. */
10406   return setpgrp (1,1) != -1;
10407   ;
10408   return 0;
10409 }
10410 _ACEOF
10411 if ac_fn_c_try_run "$LINENO"; then :
10412   ac_cv_func_setpgrp_void=no
10413 else
10414   ac_cv_func_setpgrp_void=yes
10415 fi
10416 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10417   conftest.$ac_objext conftest.beam conftest.$ac_ext
10418 fi
10419
10420 fi
10421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
10422 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
10423 if test $ac_cv_func_setpgrp_void = yes; then
10424
10425 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
10426
10427 fi
10428
10429 else
10430   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
10431 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
10432 if test "${ac_cv_func_setpgrp_void+set}" = set; then :
10433   $as_echo_n "(cached) " >&6
10434 else
10435   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10436 /* end confdefs.h.  */
10437
10438 #include <unistd.h>
10439
10440 int
10441 main ()
10442 {
10443
10444   if (setpgrp(1,1) == -1)
10445     exit (0);
10446   else
10447     exit (1);
10448
10449   ;
10450   return 0;
10451 }
10452 _ACEOF
10453 if ac_fn_c_try_compile "$LINENO"; then :
10454   ac_cv_func_setpgrp_void=no
10455 else
10456   ac_cv_func_setpgrp_void=yes
10457 fi
10458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10459 fi
10460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
10461 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
10462 if test $ac_cv_func_setpgrp_void = yes; then
10463   $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
10464
10465 fi
10466 fi
10467
10468 # Check if sigsetjmp is available.  Using AC_CHECK_FUNCS won't do
10469 # since sigsetjmp might only be defined as a macro.
10470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
10471 $as_echo_n "checking for sigsetjmp... " >&6; }
10472 if test "${gdb_cv_func_sigsetjmp+set}" = set; then :
10473   $as_echo_n "(cached) " >&6
10474 else
10475   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10476 /* end confdefs.h.  */
10477
10478 #include <setjmp.h>
10479
10480 int
10481 main ()
10482 {
10483 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
10484   ;
10485   return 0;
10486 }
10487 _ACEOF
10488 if ac_fn_c_try_compile "$LINENO"; then :
10489   gdb_cv_func_sigsetjmp=yes
10490 else
10491   gdb_cv_func_sigsetjmp=no
10492 fi
10493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10494 fi
10495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
10496 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
10497 if test $gdb_cv_func_sigsetjmp = yes; then
10498
10499 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
10500
10501 fi
10502
10503 # Assume we'll default to using the included libiberty regex.
10504 gdb_use_included_regex=yes
10505
10506 # However, if the system regex is GNU regex, then default to *not*
10507 # using the included regex.
10508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
10509 $as_echo_n "checking for GNU regex... " >&6; }
10510 if test "${gdb_cv_have_gnu_regex+set}" = set; then :
10511   $as_echo_n "(cached) " >&6
10512 else
10513   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10514 /* end confdefs.h.  */
10515 #include <gnu-versions.h>
10516 int
10517 main ()
10518 {
10519 #define REGEX_INTERFACE_VERSION 1
10520 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
10521 # error "Version mismatch"
10522 #endif
10523   ;
10524   return 0;
10525 }
10526 _ACEOF
10527 if ac_fn_c_try_compile "$LINENO"; then :
10528   gdb_cv_have_gnu_regex=yes
10529 else
10530   gdb_cv_have_gnu_regex=no
10531 fi
10532 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10533 fi
10534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
10535 $as_echo "$gdb_cv_have_gnu_regex" >&6; }
10536 if test $gdb_cv_have_gnu_regex = yes; then
10537   gdb_use_included_regex=no
10538 fi
10539
10540
10541 # Check whether --with-included-regex was given.
10542 if test "${with_included_regex+set}" = set; then :
10543   withval=$with_included_regex; gdb_with_regex=$withval
10544 else
10545   gdb_with_regex=$gdb_use_included_regex
10546 fi
10547
10548 if test "$gdb_with_regex" = yes; then
10549
10550 $as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
10551
10552 fi
10553
10554 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
10555 ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
10556 #include <sys/proc.h>
10557
10558 "
10559 if test "x$ac_cv_member_struct_thread_td_pcb" = x""yes; then :
10560
10561 cat >>confdefs.h <<_ACEOF
10562 #define HAVE_STRUCT_THREAD_TD_PCB 1
10563 _ACEOF
10564
10565
10566 fi
10567
10568
10569 # See if <sys/lwp.h> defines `struct lwp`.
10570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
10571 $as_echo_n "checking for struct lwp... " >&6; }
10572 if test "${gdb_cv_struct_lwp+set}" = set; then :
10573   $as_echo_n "(cached) " >&6
10574 else
10575   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10576 /* end confdefs.h.  */
10577 #include <sys/param.h>
10578 #include <sys/lwp.h>
10579 int
10580 main ()
10581 {
10582 struct lwp l;
10583   ;
10584   return 0;
10585 }
10586 _ACEOF
10587 if ac_fn_c_try_compile "$LINENO"; then :
10588   gdb_cv_struct_lwp=yes
10589 else
10590   gdb_cv_struct_lwp=no
10591 fi
10592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10593 fi
10594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
10595 $as_echo "$gdb_cv_struct_lwp" >&6; }
10596 if test $gdb_cv_struct_lwp = yes; then
10597
10598 $as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
10599
10600 fi
10601
10602 # See if <machine/reg.h> degines `struct reg'.
10603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
10604 $as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
10605 if test "${gdb_cv_struct_reg+set}" = set; then :
10606   $as_echo_n "(cached) " >&6
10607 else
10608   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10609 /* end confdefs.h.  */
10610 #include <sys/types.h>
10611 #include <machine/reg.h>
10612 int
10613 main ()
10614 {
10615 struct reg r;
10616   ;
10617   return 0;
10618 }
10619 _ACEOF
10620 if ac_fn_c_try_compile "$LINENO"; then :
10621   gdb_cv_struct_reg=yes
10622 else
10623   gdb_cv_struct_reg=no
10624 fi
10625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10626 fi
10627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
10628 $as_echo "$gdb_cv_struct_reg" >&6; }
10629 if test $gdb_cv_struct_reg = yes; then
10630
10631 $as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
10632
10633 fi
10634
10635 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
10636 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
10637 ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <machine/reg.h>
10638 "
10639 if test "x$ac_cv_member_struct_reg_r_fs" = x""yes; then :
10640
10641 cat >>confdefs.h <<_ACEOF
10642 #define HAVE_STRUCT_REG_R_FS 1
10643 _ACEOF
10644
10645
10646 fi
10647 ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <machine/reg.h>
10648 "
10649 if test "x$ac_cv_member_struct_reg_r_gs" = x""yes; then :
10650
10651 cat >>confdefs.h <<_ACEOF
10652 #define HAVE_STRUCT_REG_R_GS 1
10653 _ACEOF
10654
10655
10656 fi
10657
10658
10659 # See if <sys/user.h> supports the %fs_base and %gs_bas amd64 segment registers.
10660 # Older amd64 Linux's don't have the fs_base and gs_base members of
10661 # `struct user_regs_struct'.
10662 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "fs_base" "ac_cv_member_struct_user_regs_struct_fs_base" "#include <sys/user.h>
10663 "
10664 if test "x$ac_cv_member_struct_user_regs_struct_fs_base" = x""yes; then :
10665
10666 cat >>confdefs.h <<_ACEOF
10667 #define HAVE_STRUCT_USER_REGS_STRUCT_FS_BASE 1
10668 _ACEOF
10669
10670
10671 fi
10672 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "gs_base" "ac_cv_member_struct_user_regs_struct_gs_base" "#include <sys/user.h>
10673 "
10674 if test "x$ac_cv_member_struct_user_regs_struct_gs_base" = x""yes; then :
10675
10676 cat >>confdefs.h <<_ACEOF
10677 #define HAVE_STRUCT_USER_REGS_STRUCT_GS_BASE 1
10678 _ACEOF
10679
10680
10681 fi
10682
10683
10684 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
10685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
10686 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
10687 if test "${gdb_cv_have_ptrace_getregs+set}" = set; then :
10688   $as_echo_n "(cached) " >&6
10689 else
10690   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10691 /* end confdefs.h.  */
10692 #include <sys/ptrace.h>
10693 int
10694 main ()
10695 {
10696 PTRACE_GETREGS;
10697   ;
10698   return 0;
10699 }
10700 _ACEOF
10701 if ac_fn_c_try_compile "$LINENO"; then :
10702   gdb_cv_have_ptrace_getregs=yes
10703 else
10704   gdb_cv_have_ptrace_getregs=no
10705 fi
10706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10707 fi
10708
10709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
10710 $as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
10711 if test $gdb_cv_have_ptrace_getregs = yes; then
10712
10713 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
10714
10715 fi
10716
10717 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
10718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
10719 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
10720 if test "${gdb_cv_have_ptrace_getfpxregs+set}" = set; then :
10721   $as_echo_n "(cached) " >&6
10722 else
10723   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10724 /* end confdefs.h.  */
10725 #include <sys/ptrace.h>
10726 int
10727 main ()
10728 {
10729 PTRACE_GETFPXREGS;
10730   ;
10731   return 0;
10732 }
10733 _ACEOF
10734 if ac_fn_c_try_compile "$LINENO"; then :
10735   gdb_cv_have_ptrace_getfpxregs=yes
10736 else
10737   gdb_cv_have_ptrace_getfpxregs=no
10738 fi
10739 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10740 fi
10741
10742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
10743 $as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
10744 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
10745
10746 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
10747
10748 fi
10749
10750 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
10751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
10752 $as_echo_n "checking for PT_GETDBREGS... " >&6; }
10753 if test "${gdb_cv_have_pt_getdbregs+set}" = set; then :
10754   $as_echo_n "(cached) " >&6
10755 else
10756   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10757 /* end confdefs.h.  */
10758 #include <sys/types.h>
10759 #include <sys/ptrace.h>
10760 int
10761 main ()
10762 {
10763 PT_GETDBREGS;
10764   ;
10765   return 0;
10766 }
10767 _ACEOF
10768 if ac_fn_c_try_compile "$LINENO"; then :
10769   gdb_cv_have_pt_getdbregs=yes
10770 else
10771   gdb_cv_have_pt_getdbregs=no
10772 fi
10773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10774 fi
10775
10776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
10777 $as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
10778 if test $gdb_cv_have_pt_getdbregs = yes; then
10779
10780 $as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
10781
10782 fi
10783
10784 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
10785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
10786 $as_echo_n "checking for PT_GETXMMREGS... " >&6; }
10787 if test "${gdb_cv_have_pt_getxmmregs+set}" = set; then :
10788   $as_echo_n "(cached) " >&6
10789 else
10790   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10791 /* end confdefs.h.  */
10792 #include <sys/types.h>
10793 #include <sys/ptrace.h>
10794 int
10795 main ()
10796 {
10797 PT_GETXMMREGS;
10798   ;
10799   return 0;
10800 }
10801 _ACEOF
10802 if ac_fn_c_try_compile "$LINENO"; then :
10803   gdb_cv_have_pt_getxmmregs=yes
10804 else
10805   gdb_cv_have_pt_getxmmregs=no
10806 fi
10807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10808 fi
10809
10810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
10811 $as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
10812 if test $gdb_cv_have_pt_getxmmregs = yes; then
10813
10814 $as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
10815
10816 fi
10817
10818 # Detect which type of /proc is in use, such as for Solaris.
10819
10820 if test "${target}" = "${host}"; then
10821   case "${host}" in
10822   *-*-sysv4.2* | *-*-sysv5* | *-*-interix* )
10823
10824 $as_echo "#define NEW_PROC_API 1" >>confdefs.h
10825
10826       ;;
10827   *-*-solaris2.[6789] | *-*-solaris2.1[0-9]*)
10828
10829 $as_echo "#define NEW_PROC_API 1" >>confdefs.h
10830
10831       ;;
10832   mips-sgi-irix5*)
10833       # Work around <sys/proc.h> needing _KMEMUSER problem on IRIX 5.
10834
10835 $as_echo "#define _KMEMUSER 1" >>confdefs.h
10836
10837       ;;
10838   esac
10839 fi
10840
10841 if test "$ac_cv_header_sys_procfs_h" = yes; then
10842   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pstatus_t in sys/procfs.h" >&5
10843 $as_echo_n "checking for pstatus_t in sys/procfs.h... " >&6; }
10844  if test "${bfd_cv_have_sys_procfs_type_pstatus_t+set}" = set; then :
10845   $as_echo_n "(cached) " >&6
10846 else
10847   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10848 /* end confdefs.h.  */
10849
10850 #define _SYSCALL32
10851 /* Needed for new procfs interface on sparc-solaris.  */
10852 #define _STRUCTURED_PROC 1
10853 #include <sys/procfs.h>
10854 int
10855 main ()
10856 {
10857 pstatus_t avar
10858   ;
10859   return 0;
10860 }
10861 _ACEOF
10862 if ac_fn_c_try_compile "$LINENO"; then :
10863   bfd_cv_have_sys_procfs_type_pstatus_t=yes
10864 else
10865   bfd_cv_have_sys_procfs_type_pstatus_t=no
10866
10867 fi
10868 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10869 fi
10870
10871  if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
10872
10873 $as_echo "#define HAVE_PSTATUS_T 1" >>confdefs.h
10874
10875  fi
10876  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pstatus_t" >&5
10877 $as_echo "$bfd_cv_have_sys_procfs_type_pstatus_t" >&6; }
10878
10879   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prrun_t in sys/procfs.h" >&5
10880 $as_echo_n "checking for prrun_t in sys/procfs.h... " >&6; }
10881  if test "${bfd_cv_have_sys_procfs_type_prrun_t+set}" = set; then :
10882   $as_echo_n "(cached) " >&6
10883 else
10884   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10885 /* end confdefs.h.  */
10886
10887 #define _SYSCALL32
10888 /* Needed for new procfs interface on sparc-solaris.  */
10889 #define _STRUCTURED_PROC 1
10890 #include <sys/procfs.h>
10891 int
10892 main ()
10893 {
10894 prrun_t avar
10895   ;
10896   return 0;
10897 }
10898 _ACEOF
10899 if ac_fn_c_try_compile "$LINENO"; then :
10900   bfd_cv_have_sys_procfs_type_prrun_t=yes
10901 else
10902   bfd_cv_have_sys_procfs_type_prrun_t=no
10903
10904 fi
10905 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10906 fi
10907
10908  if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then
10909
10910 $as_echo "#define HAVE_PRRUN_T 1" >>confdefs.h
10911
10912  fi
10913  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prrun_t" >&5
10914 $as_echo "$bfd_cv_have_sys_procfs_type_prrun_t" >&6; }
10915
10916   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
10917 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
10918  if test "${bfd_cv_have_sys_procfs_type_gregset_t+set}" = set; then :
10919   $as_echo_n "(cached) " >&6
10920 else
10921   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10922 /* end confdefs.h.  */
10923
10924 #define _SYSCALL32
10925 /* Needed for new procfs interface on sparc-solaris.  */
10926 #define _STRUCTURED_PROC 1
10927 #include <sys/procfs.h>
10928 int
10929 main ()
10930 {
10931 gregset_t avar
10932   ;
10933   return 0;
10934 }
10935 _ACEOF
10936 if ac_fn_c_try_compile "$LINENO"; then :
10937   bfd_cv_have_sys_procfs_type_gregset_t=yes
10938 else
10939   bfd_cv_have_sys_procfs_type_gregset_t=no
10940
10941 fi
10942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10943 fi
10944
10945  if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
10946
10947 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
10948
10949  fi
10950  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
10951 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
10952
10953   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
10954 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
10955  if test "${bfd_cv_have_sys_procfs_type_fpregset_t+set}" = set; then :
10956   $as_echo_n "(cached) " >&6
10957 else
10958   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10959 /* end confdefs.h.  */
10960
10961 #define _SYSCALL32
10962 /* Needed for new procfs interface on sparc-solaris.  */
10963 #define _STRUCTURED_PROC 1
10964 #include <sys/procfs.h>
10965 int
10966 main ()
10967 {
10968 fpregset_t avar
10969   ;
10970   return 0;
10971 }
10972 _ACEOF
10973 if ac_fn_c_try_compile "$LINENO"; then :
10974   bfd_cv_have_sys_procfs_type_fpregset_t=yes
10975 else
10976   bfd_cv_have_sys_procfs_type_fpregset_t=no
10977
10978 fi
10979 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10980 fi
10981
10982  if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
10983
10984 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
10985
10986  fi
10987  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
10988 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
10989
10990   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
10991 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
10992  if test "${bfd_cv_have_sys_procfs_type_prgregset_t+set}" = set; then :
10993   $as_echo_n "(cached) " >&6
10994 else
10995   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10996 /* end confdefs.h.  */
10997
10998 #define _SYSCALL32
10999 /* Needed for new procfs interface on sparc-solaris.  */
11000 #define _STRUCTURED_PROC 1
11001 #include <sys/procfs.h>
11002 int
11003 main ()
11004 {
11005 prgregset_t avar
11006   ;
11007   return 0;
11008 }
11009 _ACEOF
11010 if ac_fn_c_try_compile "$LINENO"; then :
11011   bfd_cv_have_sys_procfs_type_prgregset_t=yes
11012 else
11013   bfd_cv_have_sys_procfs_type_prgregset_t=no
11014
11015 fi
11016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11017 fi
11018
11019  if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
11020
11021 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
11022
11023  fi
11024  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
11025 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
11026
11027   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
11028 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
11029  if test "${bfd_cv_have_sys_procfs_type_prfpregset_t+set}" = set; then :
11030   $as_echo_n "(cached) " >&6
11031 else
11032   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11033 /* end confdefs.h.  */
11034
11035 #define _SYSCALL32
11036 /* Needed for new procfs interface on sparc-solaris.  */
11037 #define _STRUCTURED_PROC 1
11038 #include <sys/procfs.h>
11039 int
11040 main ()
11041 {
11042 prfpregset_t avar
11043   ;
11044   return 0;
11045 }
11046 _ACEOF
11047 if ac_fn_c_try_compile "$LINENO"; then :
11048   bfd_cv_have_sys_procfs_type_prfpregset_t=yes
11049 else
11050   bfd_cv_have_sys_procfs_type_prfpregset_t=no
11051
11052 fi
11053 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11054 fi
11055
11056  if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
11057
11058 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
11059
11060  fi
11061  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
11062 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
11063
11064   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
11065 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
11066  if test "${bfd_cv_have_sys_procfs_type_prgregset32_t+set}" = set; then :
11067   $as_echo_n "(cached) " >&6
11068 else
11069   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11070 /* end confdefs.h.  */
11071
11072 #define _SYSCALL32
11073 /* Needed for new procfs interface on sparc-solaris.  */
11074 #define _STRUCTURED_PROC 1
11075 #include <sys/procfs.h>
11076 int
11077 main ()
11078 {
11079 prgregset32_t avar
11080   ;
11081   return 0;
11082 }
11083 _ACEOF
11084 if ac_fn_c_try_compile "$LINENO"; then :
11085   bfd_cv_have_sys_procfs_type_prgregset32_t=yes
11086 else
11087   bfd_cv_have_sys_procfs_type_prgregset32_t=no
11088
11089 fi
11090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11091 fi
11092
11093  if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
11094
11095 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
11096
11097  fi
11098  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
11099 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
11100
11101   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset32_t in sys/procfs.h" >&5
11102 $as_echo_n "checking for prfpregset32_t in sys/procfs.h... " >&6; }
11103  if test "${bfd_cv_have_sys_procfs_type_prfpregset32_t+set}" = set; then :
11104   $as_echo_n "(cached) " >&6
11105 else
11106   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11107 /* end confdefs.h.  */
11108
11109 #define _SYSCALL32
11110 /* Needed for new procfs interface on sparc-solaris.  */
11111 #define _STRUCTURED_PROC 1
11112 #include <sys/procfs.h>
11113 int
11114 main ()
11115 {
11116 prfpregset32_t avar
11117   ;
11118   return 0;
11119 }
11120 _ACEOF
11121 if ac_fn_c_try_compile "$LINENO"; then :
11122   bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
11123 else
11124   bfd_cv_have_sys_procfs_type_prfpregset32_t=no
11125
11126 fi
11127 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11128 fi
11129
11130  if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then
11131
11132 $as_echo "#define HAVE_PRFPREGSET32_T 1" >>confdefs.h
11133
11134  fi
11135  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset32_t" >&5
11136 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset32_t" >&6; }
11137
11138   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
11139 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
11140  if test "${bfd_cv_have_sys_procfs_type_lwpid_t+set}" = set; then :
11141   $as_echo_n "(cached) " >&6
11142 else
11143   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11144 /* end confdefs.h.  */
11145
11146 #define _SYSCALL32
11147 /* Needed for new procfs interface on sparc-solaris.  */
11148 #define _STRUCTURED_PROC 1
11149 #include <sys/procfs.h>
11150 int
11151 main ()
11152 {
11153 lwpid_t avar
11154   ;
11155   return 0;
11156 }
11157 _ACEOF
11158 if ac_fn_c_try_compile "$LINENO"; then :
11159   bfd_cv_have_sys_procfs_type_lwpid_t=yes
11160 else
11161   bfd_cv_have_sys_procfs_type_lwpid_t=no
11162
11163 fi
11164 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11165 fi
11166
11167  if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
11168
11169 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
11170
11171  fi
11172  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
11173 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
11174
11175   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
11176 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
11177  if test "${bfd_cv_have_sys_procfs_type_psaddr_t+set}" = set; then :
11178   $as_echo_n "(cached) " >&6
11179 else
11180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11181 /* end confdefs.h.  */
11182
11183 #define _SYSCALL32
11184 /* Needed for new procfs interface on sparc-solaris.  */
11185 #define _STRUCTURED_PROC 1
11186 #include <sys/procfs.h>
11187 int
11188 main ()
11189 {
11190 psaddr_t avar
11191   ;
11192   return 0;
11193 }
11194 _ACEOF
11195 if ac_fn_c_try_compile "$LINENO"; then :
11196   bfd_cv_have_sys_procfs_type_psaddr_t=yes
11197 else
11198   bfd_cv_have_sys_procfs_type_psaddr_t=no
11199
11200 fi
11201 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11202 fi
11203
11204  if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
11205
11206 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
11207
11208  fi
11209  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
11210 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
11211
11212   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prsysent_t in sys/procfs.h" >&5
11213 $as_echo_n "checking for prsysent_t in sys/procfs.h... " >&6; }
11214  if test "${bfd_cv_have_sys_procfs_type_prsysent_t+set}" = set; then :
11215   $as_echo_n "(cached) " >&6
11216 else
11217   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11218 /* end confdefs.h.  */
11219
11220 #define _SYSCALL32
11221 /* Needed for new procfs interface on sparc-solaris.  */
11222 #define _STRUCTURED_PROC 1
11223 #include <sys/procfs.h>
11224 int
11225 main ()
11226 {
11227 prsysent_t avar
11228   ;
11229   return 0;
11230 }
11231 _ACEOF
11232 if ac_fn_c_try_compile "$LINENO"; then :
11233   bfd_cv_have_sys_procfs_type_prsysent_t=yes
11234 else
11235   bfd_cv_have_sys_procfs_type_prsysent_t=no
11236
11237 fi
11238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11239 fi
11240
11241  if test $bfd_cv_have_sys_procfs_type_prsysent_t = yes; then
11242
11243 $as_echo "#define HAVE_PRSYSENT_T 1" >>confdefs.h
11244
11245  fi
11246  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prsysent_t" >&5
11247 $as_echo "$bfd_cv_have_sys_procfs_type_prsysent_t" >&6; }
11248
11249   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigset_t in sys/procfs.h" >&5
11250 $as_echo_n "checking for pr_sigset_t in sys/procfs.h... " >&6; }
11251  if test "${bfd_cv_have_sys_procfs_type_pr_sigset_t+set}" = set; then :
11252   $as_echo_n "(cached) " >&6
11253 else
11254   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11255 /* end confdefs.h.  */
11256
11257 #define _SYSCALL32
11258 /* Needed for new procfs interface on sparc-solaris.  */
11259 #define _STRUCTURED_PROC 1
11260 #include <sys/procfs.h>
11261 int
11262 main ()
11263 {
11264 pr_sigset_t avar
11265   ;
11266   return 0;
11267 }
11268 _ACEOF
11269 if ac_fn_c_try_compile "$LINENO"; then :
11270   bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
11271 else
11272   bfd_cv_have_sys_procfs_type_pr_sigset_t=no
11273
11274 fi
11275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11276 fi
11277
11278  if test $bfd_cv_have_sys_procfs_type_pr_sigset_t = yes; then
11279
11280 $as_echo "#define HAVE_PR_SIGSET_T 1" >>confdefs.h
11281
11282  fi
11283  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigset_t" >&5
11284 $as_echo "$bfd_cv_have_sys_procfs_type_pr_sigset_t" >&6; }
11285
11286   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigaction64_t in sys/procfs.h" >&5
11287 $as_echo_n "checking for pr_sigaction64_t in sys/procfs.h... " >&6; }
11288  if test "${bfd_cv_have_sys_procfs_type_pr_sigaction64_t+set}" = set; then :
11289   $as_echo_n "(cached) " >&6
11290 else
11291   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11292 /* end confdefs.h.  */
11293
11294 #define _SYSCALL32
11295 /* Needed for new procfs interface on sparc-solaris.  */
11296 #define _STRUCTURED_PROC 1
11297 #include <sys/procfs.h>
11298 int
11299 main ()
11300 {
11301 pr_sigaction64_t avar
11302   ;
11303   return 0;
11304 }
11305 _ACEOF
11306 if ac_fn_c_try_compile "$LINENO"; then :
11307   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
11308 else
11309   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=no
11310
11311 fi
11312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11313 fi
11314
11315  if test $bfd_cv_have_sys_procfs_type_pr_sigaction64_t = yes; then
11316
11317 $as_echo "#define HAVE_PR_SIGACTION64_T 1" >>confdefs.h
11318
11319  fi
11320  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&5
11321 $as_echo "$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&6; }
11322
11323   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_siginfo64_t in sys/procfs.h" >&5
11324 $as_echo_n "checking for pr_siginfo64_t in sys/procfs.h... " >&6; }
11325  if test "${bfd_cv_have_sys_procfs_type_pr_siginfo64_t+set}" = set; then :
11326   $as_echo_n "(cached) " >&6
11327 else
11328   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11329 /* end confdefs.h.  */
11330
11331 #define _SYSCALL32
11332 /* Needed for new procfs interface on sparc-solaris.  */
11333 #define _STRUCTURED_PROC 1
11334 #include <sys/procfs.h>
11335 int
11336 main ()
11337 {
11338 pr_siginfo64_t avar
11339   ;
11340   return 0;
11341 }
11342 _ACEOF
11343 if ac_fn_c_try_compile "$LINENO"; then :
11344   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
11345 else
11346   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=no
11347
11348 fi
11349 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11350 fi
11351
11352  if test $bfd_cv_have_sys_procfs_type_pr_siginfo64_t = yes; then
11353
11354 $as_echo "#define HAVE_PR_SIGINFO64_T 1" >>confdefs.h
11355
11356  fi
11357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&5
11358 $as_echo "$bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&6; }
11359
11360
11361
11362
11363
11364   if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
11365     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether prfpregset_t type is broken" >&5
11366 $as_echo_n "checking whether prfpregset_t type is broken... " >&6; }
11367     if test "${gdb_cv_prfpregset_t_broken+set}" = set; then :
11368   $as_echo_n "(cached) " >&6
11369 else
11370   if test "$cross_compiling" = yes; then :
11371   gdb_cv_prfpregset_t_broken=yes
11372 else
11373   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11374 /* end confdefs.h.  */
11375 #include <sys/procfs.h>
11376        int main ()
11377        {
11378          if (sizeof (prfpregset_t) == sizeof (void *))
11379            return 1;
11380          return 0;
11381        }
11382 _ACEOF
11383 if ac_fn_c_try_run "$LINENO"; then :
11384   gdb_cv_prfpregset_t_broken=no
11385 else
11386   gdb_cv_prfpregset_t_broken=yes
11387 fi
11388 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11389   conftest.$ac_objext conftest.beam conftest.$ac_ext
11390 fi
11391
11392 fi
11393
11394     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_prfpregset_t_broken" >&5
11395 $as_echo "$gdb_cv_prfpregset_t_broken" >&6; }
11396     if test $gdb_cv_prfpregset_t_broken = yes; then
11397
11398 $as_echo "#define PRFPREGSET_T_BROKEN 1" >>confdefs.h
11399
11400     fi
11401   fi
11402
11403
11404   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
11405 $as_echo_n "checking for PIOCSET ioctl entry in sys/procfs.h... " >&6; }
11406   if test "${gdb_cv_have_procfs_piocset+set}" = set; then :
11407   $as_echo_n "(cached) " >&6
11408 else
11409   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11410 /* end confdefs.h.  */
11411 #include <unistd.h>
11412 #include <sys/types.h>
11413 #include <sys/procfs.h>
11414
11415 int
11416 main ()
11417 {
11418
11419     int dummy;;
11420     dummy = ioctl(0, PIOCSET, &dummy);
11421
11422   ;
11423   return 0;
11424 }
11425 _ACEOF
11426 if ac_fn_c_try_compile "$LINENO"; then :
11427   gdb_cv_have_procfs_piocset=yes
11428 else
11429   gdb_cv_have_procfs_piocset=no
11430 fi
11431 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11432 fi
11433
11434   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_procfs_piocset" >&5
11435 $as_echo "$gdb_cv_have_procfs_piocset" >&6; }
11436   if test $gdb_cv_have_procfs_piocset = yes; then
11437
11438 $as_echo "#define HAVE_PROCFS_PIOCSET 1" >>confdefs.h
11439
11440   fi
11441 fi
11442
11443 if test ${host} = ${target} ; then
11444
11445   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member l_addr in struct link_map" >&5
11446 $as_echo_n "checking for member l_addr in struct link_map... " >&6; }
11447   if test "${gdb_cv_have_struct_link_map_with_l_members+set}" = set; then :
11448   $as_echo_n "(cached) " >&6
11449 else
11450   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11451 /* end confdefs.h.  */
11452 #include <link.h>
11453 int
11454 main ()
11455 {
11456 struct link_map lm; (void) lm.l_addr;
11457   ;
11458   return 0;
11459 }
11460 _ACEOF
11461 if ac_fn_c_try_compile "$LINENO"; then :
11462   gdb_cv_have_struct_link_map_with_l_members=yes
11463 else
11464   gdb_cv_have_struct_link_map_with_l_members=no
11465 fi
11466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11467 fi
11468
11469   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_l_members" >&5
11470 $as_echo "$gdb_cv_have_struct_link_map_with_l_members" >&6; }
11471   if test $gdb_cv_have_struct_link_map_with_l_members = yes; then
11472
11473 $as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_L_MEMBERS 1" >>confdefs.h
11474
11475   fi
11476
11477
11478   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member lm_addr in struct link_map" >&5
11479 $as_echo_n "checking for member lm_addr in struct link_map... " >&6; }
11480   if test "${gdb_cv_have_struct_link_map_with_lm_members+set}" = set; then :
11481   $as_echo_n "(cached) " >&6
11482 else
11483   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11484 /* end confdefs.h.  */
11485 #include <sys/types.h>
11486 #include <link.h>
11487 int
11488 main ()
11489 {
11490 struct link_map lm; (void) lm.lm_addr;
11491   ;
11492   return 0;
11493 }
11494 _ACEOF
11495 if ac_fn_c_try_compile "$LINENO"; then :
11496   gdb_cv_have_struct_link_map_with_lm_members=yes
11497 else
11498   gdb_cv_have_struct_link_map_with_lm_members=no
11499 fi
11500 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11501 fi
11502
11503   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_lm_members" >&5
11504 $as_echo "$gdb_cv_have_struct_link_map_with_lm_members" >&6; }
11505   if test $gdb_cv_have_struct_link_map_with_lm_members = yes; then
11506
11507 $as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_LM_MEMBERS 1" >>confdefs.h
11508
11509   fi
11510
11511
11512   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member som_addr in struct so_map" >&5
11513 $as_echo_n "checking for member som_addr in struct so_map... " >&6; }
11514   if test "${gdb_cv_have_struct_so_map_with_som_members+set}" = set; then :
11515   $as_echo_n "(cached) " >&6
11516 else
11517   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11518 /* end confdefs.h.  */
11519 #include <sys/types.h>
11520 #ifdef HAVE_NLIST_H
11521 #include <nlist.h>
11522 #endif
11523 #include <link.h>
11524 int
11525 main ()
11526 {
11527 struct so_map lm; (void) lm.som_addr;
11528   ;
11529   return 0;
11530 }
11531 _ACEOF
11532 if ac_fn_c_try_compile "$LINENO"; then :
11533   gdb_cv_have_struct_so_map_with_som_members=yes
11534 else
11535   gdb_cv_have_struct_so_map_with_som_members=no
11536 fi
11537 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11538 fi
11539
11540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_so_map_with_som_members" >&5
11541 $as_echo "$gdb_cv_have_struct_so_map_with_som_members" >&6; }
11542   if test $gdb_cv_have_struct_so_map_with_som_members = yes; then
11543
11544 $as_echo "#define HAVE_STRUCT_SO_MAP_WITH_SOM_MEMBERS 1" >>confdefs.h
11545
11546   fi
11547
11548
11549   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct link_map32 in sys/link.h" >&5
11550 $as_echo_n "checking for struct link_map32 in sys/link.h... " >&6; }
11551   if test "${gdb_cv_have_struct_link_map32+set}" = set; then :
11552   $as_echo_n "(cached) " >&6
11553 else
11554   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11555 /* end confdefs.h.  */
11556 #define _SYSCALL32
11557 #include <sys/link.h>
11558 int
11559 main ()
11560 {
11561 struct link_map32 l;
11562   ;
11563   return 0;
11564 }
11565 _ACEOF
11566 if ac_fn_c_try_compile "$LINENO"; then :
11567   gdb_cv_have_struct_link_map32=yes
11568 else
11569   gdb_cv_have_struct_link_map32=no
11570 fi
11571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11572 fi
11573
11574   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map32" >&5
11575 $as_echo "$gdb_cv_have_struct_link_map32" >&6; }
11576   if test $gdb_cv_have_struct_link_map32 = yes; then
11577
11578 $as_echo "#define HAVE_STRUCT_LINK_MAP32 1" >>confdefs.h
11579
11580
11581 $as_echo "#define _SYSCALL32 1" >>confdefs.h
11582
11583   fi
11584 fi
11585
11586 # Check if the compiler supports the `long long' type.
11587
11588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
11589 $as_echo_n "checking for long long support in compiler... " >&6; }
11590 if test "${gdb_cv_c_long_long+set}" = set; then :
11591   $as_echo_n "(cached) " >&6
11592 else
11593   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11594 /* end confdefs.h.  */
11595 extern long long foo;
11596 int
11597 main ()
11598 {
11599 switch (foo & 2) { case 0: return 1; }
11600   ;
11601   return 0;
11602 }
11603 _ACEOF
11604 if ac_fn_c_try_compile "$LINENO"; then :
11605   gdb_cv_c_long_long=yes
11606 else
11607   gdb_cv_c_long_long=no
11608 fi
11609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11610 fi
11611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
11612 $as_echo "$gdb_cv_c_long_long" >&6; }
11613 if test $gdb_cv_c_long_long != yes; then
11614   # libdecnumber requires long long.
11615   as_fn_error "Compiler must support long long for GDB." "$LINENO" 5
11616 fi
11617
11618 # Check if the compiler and runtime support printing long longs.
11619
11620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
11621 $as_echo_n "checking for long long support in printf... " >&6; }
11622 if test "${gdb_cv_printf_has_long_long+set}" = set; then :
11623   $as_echo_n "(cached) " >&6
11624 else
11625   if test "$cross_compiling" = yes; then :
11626   gdb_cv_printf_has_long_long=no
11627 else
11628   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11629 /* end confdefs.h.  */
11630 $ac_includes_default
11631 int
11632 main ()
11633 {
11634 char buf[32];
11635   long long l = 0;
11636   l = (l << 16) + 0x0123;
11637   l = (l << 16) + 0x4567;
11638   l = (l << 16) + 0x89ab;
11639   l = (l << 16) + 0xcdef;
11640   sprintf (buf, "0x%016llx", l);
11641   return (strcmp ("0x0123456789abcdef", buf));
11642   ;
11643   return 0;
11644 }
11645 _ACEOF
11646 if ac_fn_c_try_run "$LINENO"; then :
11647   gdb_cv_printf_has_long_long=yes
11648 else
11649   gdb_cv_printf_has_long_long=no
11650 fi
11651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11652   conftest.$ac_objext conftest.beam conftest.$ac_ext
11653 fi
11654
11655 fi
11656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
11657 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
11658 if test $gdb_cv_printf_has_long_long = yes; then
11659
11660 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
11661
11662 fi
11663
11664 # Check if the compiler and runtime support printing decfloats.
11665
11666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
11667 $as_echo_n "checking for decfloat support in printf... " >&6; }
11668 if test "${gdb_cv_printf_has_decfloat+set}" = set; then :
11669   $as_echo_n "(cached) " >&6
11670 else
11671   if test "$cross_compiling" = yes; then :
11672   gdb_cv_printf_has_decfloat=no
11673 else
11674   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11675 /* end confdefs.h.  */
11676 $ac_includes_default
11677 int
11678 main ()
11679 {
11680 char buf[64];
11681   _Decimal32 d32 = 1.2345df;
11682   _Decimal64 d64 = 1.2345dd;
11683   _Decimal128 d128 = 1.2345dl;
11684   sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
11685   return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
11686   ;
11687   return 0;
11688 }
11689 _ACEOF
11690 if ac_fn_c_try_run "$LINENO"; then :
11691   gdb_cv_printf_has_decfloat=yes
11692 else
11693   gdb_cv_printf_has_decfloat=no
11694 fi
11695 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11696   conftest.$ac_objext conftest.beam conftest.$ac_ext
11697 fi
11698
11699 fi
11700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
11701 $as_echo "$gdb_cv_printf_has_decfloat" >&6; }
11702 if test $gdb_cv_printf_has_decfloat = yes; then
11703
11704 $as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
11705
11706 fi
11707
11708 # Check if the compiler supports the `long double' type.  We can't use
11709 # AC_C_LONG_DOUBLE because that one does additional checks on the
11710 # constants defined in <float.h> that fail on some systems,
11711 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
11712
11713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
11714 $as_echo_n "checking for long double support in compiler... " >&6; }
11715 if test "${gdb_cv_c_long_double+set}" = set; then :
11716   $as_echo_n "(cached) " >&6
11717 else
11718   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11719 /* end confdefs.h.  */
11720 long double foo;
11721 _ACEOF
11722 if ac_fn_c_try_compile "$LINENO"; then :
11723   gdb_cv_c_long_double=yes
11724 else
11725   gdb_cv_c_long_double=no
11726 fi
11727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11728 fi
11729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
11730 $as_echo "$gdb_cv_c_long_double" >&6; }
11731 if test $gdb_cv_c_long_double = yes; then
11732
11733 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
11734
11735 fi
11736
11737 # Check if the compiler and runtime support printing long doubles.
11738
11739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
11740 $as_echo_n "checking for long double support in printf... " >&6; }
11741 if test "${gdb_cv_printf_has_long_double+set}" = set; then :
11742   $as_echo_n "(cached) " >&6
11743 else
11744   if test "$cross_compiling" = yes; then :
11745   gdb_cv_printf_has_long_double=no
11746 else
11747   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11748 /* end confdefs.h.  */
11749 $ac_includes_default
11750 int
11751 main ()
11752 {
11753 char buf[16];
11754   long double f = 3.141592653;
11755   sprintf (buf, "%Lg", f);
11756   return (strncmp ("3.14159", buf, 7));
11757   ;
11758   return 0;
11759 }
11760 _ACEOF
11761 if ac_fn_c_try_run "$LINENO"; then :
11762   gdb_cv_printf_has_long_double=yes
11763 else
11764   gdb_cv_printf_has_long_double=no
11765 fi
11766 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11767   conftest.$ac_objext conftest.beam conftest.$ac_ext
11768 fi
11769
11770 fi
11771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
11772 $as_echo "$gdb_cv_printf_has_long_double" >&6; }
11773 if test $gdb_cv_printf_has_long_double = yes; then
11774
11775 $as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
11776
11777 fi
11778
11779 # Check if the compiler and runtime support scanning long doubles.
11780
11781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
11782 $as_echo_n "checking for long double support in scanf... " >&6; }
11783 if test "${gdb_cv_scanf_has_long_double+set}" = set; then :
11784   $as_echo_n "(cached) " >&6
11785 else
11786   if test "$cross_compiling" = yes; then :
11787   gdb_cv_scanf_has_long_double=no
11788 else
11789   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11790 /* end confdefs.h.  */
11791 #include <stdio.h>
11792 int
11793 main ()
11794 {
11795 char *buf = "3.141592653";
11796   long double f = 0;
11797   sscanf (buf, "%Lg", &f);
11798   return !(f > 3.14159 && f < 3.14160);
11799   ;
11800   return 0;
11801 }
11802 _ACEOF
11803 if ac_fn_c_try_run "$LINENO"; then :
11804   gdb_cv_scanf_has_long_double=yes
11805 else
11806   gdb_cv_scanf_has_long_double=no
11807 fi
11808 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11809   conftest.$ac_objext conftest.beam conftest.$ac_ext
11810 fi
11811
11812 fi
11813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
11814 $as_echo "$gdb_cv_scanf_has_long_double" >&6; }
11815 if test $gdb_cv_scanf_has_long_double = yes; then
11816
11817 $as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
11818
11819 fi
11820
11821 case ${host_os} in
11822 aix*)
11823   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
11824 $as_echo_n "checking for -bbigtoc option... " >&6; }
11825 if test "${gdb_cv_bigtoc+set}" = set; then :
11826   $as_echo_n "(cached) " >&6
11827 else
11828
11829     SAVE_LDFLAGS=$LDFLAGS
11830
11831     case $GCC in
11832     yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
11833     *) gdb_cv_bigtoc=-bbigtoc ;;
11834     esac
11835
11836     LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
11837     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11838 /* end confdefs.h.  */
11839
11840 int
11841 main ()
11842 {
11843 int i;
11844   ;
11845   return 0;
11846 }
11847 _ACEOF
11848 if ac_fn_c_try_link "$LINENO"; then :
11849
11850 else
11851   gdb_cv_bigtoc=
11852 fi
11853 rm -f core conftest.err conftest.$ac_objext \
11854     conftest$ac_exeext conftest.$ac_ext
11855     LDFLAGS="${SAVE_LDFLAGS}"
11856
11857 fi
11858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
11859 $as_echo "$gdb_cv_bigtoc" >&6; }
11860   CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
11861   ;;
11862 esac
11863
11864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
11865 $as_echo_n "checking for the dynamic export flag... " >&6; }
11866 dynamic_list=false
11867 if test "${gdb_native}" = yes; then
11868    # The dynamically loaded libthread_db needs access to symbols in the gdb
11869    # executable.  Older GNU ld supports --export-dynamic but --dynamic-list
11870    # may not be supported there.
11871    old_LDFLAGS="$LDFLAGS"
11872    # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
11873    RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
11874    LDFLAGS="$LDFLAGS $RDYNAMIC"
11875    if test "${have_libpython}" = no; then
11876      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11877 /* end confdefs.h.  */
11878
11879 int
11880 main ()
11881 {
11882
11883   ;
11884   return 0;
11885 }
11886 _ACEOF
11887 if ac_fn_c_try_link "$LINENO"; then :
11888   dynamic_list=true
11889 fi
11890 rm -f core conftest.err conftest.$ac_objext \
11891     conftest$ac_exeext conftest.$ac_ext
11892    else
11893      # Workaround http://bugs.python.org/issue4434 where static
11894      # libpythonX.Y.a would get its symbols required for
11895      # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
11896      # Problem does not happen for the recommended libpythonX.Y.so linkage.
11897      old_CFLAGS="$CFLAGS"
11898      CFLAGS="$CFLAGS $PYTHON_CFLAGS"
11899      old_LIBS="$LIBS"
11900      LIBS="$LIBS $PYTHON_LIBS"
11901      if test "$cross_compiling" = yes; then :
11902   true
11903 else
11904   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11905 /* end confdefs.h.  */
11906 #include "${have_libpython}/Python.h"
11907 int
11908 main ()
11909 {
11910 int err;
11911           Py_Initialize ();
11912           err = PyRun_SimpleString ("import itertools\n");
11913           Py_Finalize ();
11914           return err == 0 ? 0 : 1;
11915   ;
11916   return 0;
11917 }
11918 _ACEOF
11919 if ac_fn_c_try_run "$LINENO"; then :
11920   dynamic_list=true
11921 fi
11922 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11923   conftest.$ac_objext conftest.beam conftest.$ac_ext
11924 fi
11925
11926      LIBS="$old_LIBS"
11927      CFLAGS="$old_CFLAGS"
11928    fi
11929    LDFLAGS="$old_LDFLAGS"
11930 fi
11931 if $dynamic_list; then
11932   found="-Wl,--dynamic-list"
11933   RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
11934 else
11935   found="-rdynamic"
11936   RDYNAMIC="-rdynamic"
11937 fi
11938
11939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
11940 $as_echo "$found" >&6; }
11941
11942
11943 if test ${build} = ${host} -a ${host} = ${target} ; then
11944    case ${host_os} in
11945    solaris*)
11946       # See if thread_db library is around for Solaris thread debugging.
11947       # Note that we must explicitly test for version 1 of the library
11948       # because version 0 (present on Solaris 2.4 or earlier) doesn't have
11949       # the same API.
11950       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris thread debugging library" >&5
11951 $as_echo_n "checking for Solaris thread debugging library... " >&6; }
11952       if test -f /usr/lib/libthread_db.so.1 ; then
11953          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11954 $as_echo "yes" >&6; }
11955
11956 $as_echo "#define HAVE_THREAD_DB_LIB 1" >>confdefs.h
11957
11958          CONFIG_OBS="${CONFIG_OBS} sol-thread.o"
11959          CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
11960          # On SPARC CPUs, we also need to build sparc-sol-thread.
11961          case ${host_cpu} in
11962            sparc*)
11963              CONFIG_OBS="${CONFIG_OBS} sparc-sol-thread.o"
11964              CONFIG_SRCS="${CONFIG_SRCS} sparc-sol-thread.c"
11965              ;;
11966          esac
11967          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11968 $as_echo_n "checking for dlopen in -ldl... " >&6; }
11969 if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
11970   $as_echo_n "(cached) " >&6
11971 else
11972   ac_check_lib_save_LIBS=$LIBS
11973 LIBS="-ldl  $LIBS"
11974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11975 /* end confdefs.h.  */
11976
11977 /* Override any GCC internal prototype to avoid an error.
11978    Use char because int might match the return type of a GCC
11979    builtin and then its argument prototype would still apply.  */
11980 #ifdef __cplusplus
11981 extern "C"
11982 #endif
11983 char dlopen ();
11984 int
11985 main ()
11986 {
11987 return dlopen ();
11988   ;
11989   return 0;
11990 }
11991 _ACEOF
11992 if ac_fn_c_try_link "$LINENO"; then :
11993   ac_cv_lib_dl_dlopen=yes
11994 else
11995   ac_cv_lib_dl_dlopen=no
11996 fi
11997 rm -f core conftest.err conftest.$ac_objext \
11998     conftest$ac_exeext conftest.$ac_ext
11999 LIBS=$ac_check_lib_save_LIBS
12000 fi
12001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
12002 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
12003 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
12004   cat >>confdefs.h <<_ACEOF
12005 #define HAVE_LIBDL 1
12006 _ACEOF
12007
12008   LIBS="-ldl $LIBS"
12009
12010 fi
12011
12012          CONFIG_LDFLAGS="${CONFIG_LDFLAGS} $RDYNAMIC"
12013          # Sun randomly tweaked the prototypes in <proc_service.h>
12014          # at one point.
12015          { $as_echo "$as_me:${as_lineno-$LINENO}: checking if <proc_service.h> is old" >&5
12016 $as_echo_n "checking if <proc_service.h> is old... " >&6; }
12017          if test "${gdb_cv_proc_service_is_old+set}" = set; then :
12018   $as_echo_n "(cached) " >&6
12019 else
12020
12021             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12022 /* end confdefs.h.  */
12023
12024                 #include <proc_service.h>
12025                 ps_err_e ps_pdwrite
12026                     (struct ps_prochandle*, psaddr_t, const void*, size_t);
12027
12028 int
12029 main ()
12030 {
12031
12032   ;
12033   return 0;
12034 }
12035 _ACEOF
12036 if ac_fn_c_try_compile "$LINENO"; then :
12037   gdb_cv_proc_service_is_old=no
12038 else
12039   gdb_cv_proc_service_is_old=yes
12040 fi
12041 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12042
12043 fi
12044
12045          { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_proc_service_is_old" >&5
12046 $as_echo "$gdb_cv_proc_service_is_old" >&6; }
12047          if test $gdb_cv_proc_service_is_old = yes; then
12048
12049 $as_echo "#define PROC_SERVICE_IS_OLD 1" >>confdefs.h
12050
12051          fi
12052       else
12053          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12054 $as_echo "no" >&6; }
12055       fi
12056       ;;
12057    aix*)
12058       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
12059 $as_echo_n "checking for AiX thread debugging library... " >&6; }
12060       if test "${gdb_cv_have_aix_thread_debug+set}" = set; then :
12061   $as_echo_n "(cached) " >&6
12062 else
12063   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12064 /* end confdefs.h.  */
12065 #include <sys/pthdebug.h>
12066 int
12067 main ()
12068 {
12069 #ifndef PTHDB_VERSION_3
12070                                     #error
12071                                     #endif
12072   ;
12073   return 0;
12074 }
12075 _ACEOF
12076 if ac_fn_c_try_compile "$LINENO"; then :
12077   gdb_cv_have_aix_thread_debug=yes
12078 else
12079   gdb_cv_have_aix_thread_debug=no
12080 fi
12081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12082 fi
12083
12084       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
12085 $as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
12086       if test $gdb_cv_have_aix_thread_debug = yes; then
12087          CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
12088          CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
12089          LIBS="$LIBS -lpthdebug"
12090
12091          # Older versions of AIX do not provide the declaration for
12092          # the getthrds function (it appears that it was introduced
12093          # with AIX 6.x).
12094          ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
12095 "
12096 if test "x$ac_cv_have_decl_getthrds" = x""yes; then :
12097   ac_have_decl=1
12098 else
12099   ac_have_decl=0
12100 fi
12101
12102 cat >>confdefs.h <<_ACEOF
12103 #define HAVE_DECL_GETTHRDS $ac_have_decl
12104 _ACEOF
12105
12106       fi
12107       ;;
12108    esac
12109
12110 fi
12111
12112 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
12113    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
12114 $as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
12115 if test "${gdb_cv_thread_db_h_has_td_notalloc+set}" = set; then :
12116   $as_echo_n "(cached) " >&6
12117 else
12118   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12119 /* end confdefs.h.  */
12120 #include <thread_db.h>
12121 int
12122 main ()
12123 {
12124 int i = TD_NOTALLOC;
12125   ;
12126   return 0;
12127 }
12128 _ACEOF
12129 if ac_fn_c_try_compile "$LINENO"; then :
12130   gdb_cv_thread_db_h_has_td_notalloc=yes
12131 else
12132   gdb_cv_thread_db_h_has_td_notalloc=no
12133
12134 fi
12135 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12136
12137 fi
12138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
12139 $as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
12140    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
12141 $as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
12142 if test "${gdb_cv_thread_db_h_has_td_version+set}" = set; then :
12143   $as_echo_n "(cached) " >&6
12144 else
12145   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12146 /* end confdefs.h.  */
12147 #include <thread_db.h>
12148 int
12149 main ()
12150 {
12151 int i = TD_VERSION;
12152   ;
12153   return 0;
12154 }
12155 _ACEOF
12156 if ac_fn_c_try_compile "$LINENO"; then :
12157   gdb_cv_thread_db_h_has_td_version=yes
12158 else
12159   gdb_cv_thread_db_h_has_td_version=no
12160
12161 fi
12162 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12163
12164 fi
12165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
12166 $as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
12167    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
12168 $as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
12169 if test "${gdb_cv_thread_db_h_has_td_notls+set}" = set; then :
12170   $as_echo_n "(cached) " >&6
12171 else
12172   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12173 /* end confdefs.h.  */
12174 #include <thread_db.h>
12175 int
12176 main ()
12177 {
12178 int i = TD_NOTLS;
12179   ;
12180   return 0;
12181 }
12182 _ACEOF
12183 if ac_fn_c_try_compile "$LINENO"; then :
12184   gdb_cv_thread_db_h_has_td_notls=yes
12185 else
12186   gdb_cv_thread_db_h_has_td_notls=no
12187
12188 fi
12189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12190
12191 fi
12192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
12193 $as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
12194 fi
12195 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
12196
12197 $as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
12198
12199 fi
12200 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
12201
12202 $as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
12203
12204 fi
12205 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
12206
12207 $as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
12208
12209 fi
12210
12211 if test "x$ac_cv_header_sys_syscall_h" = "xyes"; then
12212    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/syscall.h> has __NR_tkill" >&5
12213 $as_echo_n "checking whether <sys/syscall.h> has __NR_tkill... " >&6; }
12214 if test "${gdb_cv_sys_syscall_h_has_tkill+set}" = set; then :
12215   $as_echo_n "(cached) " >&6
12216 else
12217   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12218 /* end confdefs.h.  */
12219 #include <sys/syscall.h>
12220 int
12221 main ()
12222 {
12223 int i = __NR_tkill;
12224   ;
12225   return 0;
12226 }
12227 _ACEOF
12228 if ac_fn_c_try_compile "$LINENO"; then :
12229   gdb_cv_sys_syscall_h_has_tkill=yes
12230 else
12231   gdb_cv_sys_syscall_h_has_tkill=no
12232
12233 fi
12234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12235
12236 fi
12237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_sys_syscall_h_has_tkill" >&5
12238 $as_echo "$gdb_cv_sys_syscall_h_has_tkill" >&6; }
12239 fi
12240 if test "x$gdb_cv_sys_syscall_h_has_tkill" = "xyes" && test "x$ac_cv_func_syscall" = "xyes"; then
12241
12242 $as_echo "#define HAVE_TKILL_SYSCALL 1" >>confdefs.h
12243
12244 fi
12245
12246 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
12247 "
12248 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = x""yes; then :
12249   ac_have_decl=1
12250 else
12251   ac_have_decl=0
12252 fi
12253
12254 cat >>confdefs.h <<_ACEOF
12255 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
12256 _ACEOF
12257
12258
12259 if test "$cross_compiling" = yes; then :
12260   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12261 /* end confdefs.h.  */
12262 #include <sys/personality.h>
12263 int
12264 main ()
12265 {
12266
12267 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
12268 #       define ADDR_NO_RANDOMIZE 0x0040000
12269 #      endif
12270        /* Test the flag could be set and stays set.  */
12271        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
12272        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
12273            return 1
12274   ;
12275   return 0;
12276 }
12277 _ACEOF
12278 if ac_fn_c_try_link "$LINENO"; then :
12279   have_personality=true
12280 else
12281   have_personality=false
12282 fi
12283 rm -f core conftest.err conftest.$ac_objext \
12284     conftest$ac_exeext conftest.$ac_ext
12285 else
12286   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12287 /* end confdefs.h.  */
12288 #include <sys/personality.h>
12289 int
12290 main ()
12291 {
12292
12293 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
12294 #       define ADDR_NO_RANDOMIZE 0x0040000
12295 #      endif
12296        /* Test the flag could be set and stays set.  */
12297        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
12298        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
12299            return 1
12300   ;
12301   return 0;
12302 }
12303 _ACEOF
12304 if ac_fn_c_try_run "$LINENO"; then :
12305   have_personality=true
12306 else
12307   have_personality=false
12308 fi
12309 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12310   conftest.$ac_objext conftest.beam conftest.$ac_ext
12311 fi
12312
12313 if $have_personality
12314 then
12315
12316 $as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
12317
12318 fi
12319
12320
12321 # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
12322 # except that the argument to --with-sysroot is optional.
12323 # --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
12324 if test "x$with_sysroot" = xyes; then
12325   with_sysroot="${exec_prefix}/${target_alias}/sys-root"
12326 fi
12327
12328 # Check whether --with-sysroot was given.
12329 if test "${with_sysroot+set}" = set; then :
12330   withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
12331 else
12332   TARGET_SYSTEM_ROOT=
12333 fi
12334
12335
12336   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
12337   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12338   ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
12339   ac_define_dir=`eval echo $ac_define_dir`
12340
12341 cat >>confdefs.h <<_ACEOF
12342 #define TARGET_SYSTEM_ROOT "$ac_define_dir"
12343 _ACEOF
12344
12345
12346
12347
12348   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
12349      if test "x$prefix" = xNONE; then
12350         test_prefix=/usr/local
12351      else
12352         test_prefix=$prefix
12353      fi
12354   else
12355      test_prefix=$exec_prefix
12356   fi
12357   value=0
12358   case ${ac_define_dir} in
12359      "${test_prefix}"|"${test_prefix}/"*|\
12360         '${exec_prefix}'|'${exec_prefix}/'*)
12361      value=1
12362      ;;
12363   esac
12364
12365 cat >>confdefs.h <<_ACEOF
12366 #define TARGET_SYSTEM_ROOT_RELOCATABLE $value
12367 _ACEOF
12368
12369
12370
12371
12372
12373 # Check whether --with-system-gdbinit was given.
12374 if test "${with_system_gdbinit+set}" = set; then :
12375   withval=$with_system_gdbinit;
12376     SYSTEM_GDBINIT=$withval
12377 else
12378   SYSTEM_GDBINIT=
12379 fi
12380
12381
12382   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
12383   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12384   ac_define_dir=`eval echo $SYSTEM_GDBINIT`
12385   ac_define_dir=`eval echo $ac_define_dir`
12386
12387 cat >>confdefs.h <<_ACEOF
12388 #define SYSTEM_GDBINIT "$ac_define_dir"
12389 _ACEOF
12390
12391
12392
12393
12394   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
12395      if test "x$prefix" = xNONE; then
12396         test_prefix=/usr/local
12397      else
12398         test_prefix=$prefix
12399      fi
12400   else
12401      test_prefix=$exec_prefix
12402   fi
12403   value=0
12404   case ${ac_define_dir} in
12405      "${test_prefix}"|"${test_prefix}/"*|\
12406         '${exec_prefix}'|'${exec_prefix}/'*)
12407      value=1
12408      ;;
12409   esac
12410
12411 cat >>confdefs.h <<_ACEOF
12412 #define SYSTEM_GDBINIT_RELOCATABLE $value
12413 _ACEOF
12414
12415
12416
12417
12418 # Check whether --enable-werror was given.
12419 if test "${enable_werror+set}" = set; then :
12420   enableval=$enable_werror; case "${enableval}" in
12421      yes | y) ERROR_ON_WARNING="yes" ;;
12422      no | n)  ERROR_ON_WARNING="no" ;;
12423      *) as_fn_error "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
12424    esac
12425 fi
12426
12427
12428 # Enable -Werror by default when using gcc.  Turn it off for releases.
12429 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
12430     ERROR_ON_WARNING=yes
12431 fi
12432
12433 WERROR_CFLAGS=""
12434 if test "${ERROR_ON_WARNING}" = yes ; then
12435     WERROR_CFLAGS="-Werror"
12436 fi
12437
12438 # The entries after -Wno-pointer-sign are disabled warnings which may
12439 # be enabled in the future, which can not currently be used to build
12440 # GDB.
12441 # NOTE: If you change this list, remember to update
12442 # gdb/doc/gdbint.texinfo.
12443 build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
12444 -Wformat-nonliteral -Wno-pointer-sign \
12445 -Wno-unused -Wunused-value -Wunused-function \
12446 -Wno-switch -Wno-char-subscripts -Wmissing-prototypes \
12447 -Wdeclaration-after-statement -Wempty-body"
12448
12449 # Enable -Wno-format by default when using gcc on mingw since many
12450 # GCC versions complain about %I64.
12451 case "${host}" in
12452   *-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
12453 esac
12454
12455 # Check whether --enable-build-warnings was given.
12456 if test "${enable_build_warnings+set}" = set; then :
12457   enableval=$enable_build_warnings; case "${enableval}" in
12458   yes)  ;;
12459   no)   build_warnings="-w";;
12460   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12461         build_warnings="${build_warnings} ${t}";;
12462   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12463         build_warnings="${t} ${build_warnings}";;
12464   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
12465 esac
12466 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
12467   echo "Setting compiler warning flags = $build_warnings" 6>&1
12468 fi
12469 fi
12470 # Check whether --enable-gdb-build-warnings was given.
12471 if test "${enable_gdb_build_warnings+set}" = set; then :
12472   enableval=$enable_gdb_build_warnings; case "${enableval}" in
12473   yes)  ;;
12474   no)   build_warnings="-w";;
12475   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12476         build_warnings="${build_warnings} ${t}";;
12477   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12478         build_warnings="${t} ${build_warnings}";;
12479   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
12480 esac
12481 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
12482   echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
12483 fi
12484 fi
12485 WARN_CFLAGS=""
12486 if test "x${build_warnings}" != x -a "x$GCC" = xyes
12487 then
12488     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
12489 $as_echo_n "checking compiler warning flags... " >&6; }
12490     # Separate out the -Werror flag as some files just cannot be
12491     # compiled with it enabled.
12492     for w in ${build_warnings}; do
12493         case $w in
12494         -Werr*) WERROR_CFLAGS=-Werror ;;
12495         *) # Check that GCC accepts it
12496             saved_CFLAGS="$CFLAGS"
12497             CFLAGS="$CFLAGS $w"
12498             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12499 /* end confdefs.h.  */
12500
12501 int
12502 main ()
12503 {
12504
12505   ;
12506   return 0;
12507 }
12508 _ACEOF
12509 if ac_fn_c_try_compile "$LINENO"; then :
12510   WARN_CFLAGS="${WARN_CFLAGS} $w"
12511 fi
12512 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12513             CFLAGS="$saved_CFLAGS"
12514         esac
12515     done
12516     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
12517 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
12518 fi
12519
12520
12521
12522 # In the Cygwin environment, we need some additional flags.
12523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
12524 $as_echo_n "checking for cygwin... " >&6; }
12525 if test "${gdb_cv_os_cygwin+set}" = set; then :
12526   $as_echo_n "(cached) " >&6
12527 else
12528   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12529 /* end confdefs.h.  */
12530
12531 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
12532 lose
12533 #endif
12534 _ACEOF
12535 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12536   $EGREP "lose" >/dev/null 2>&1; then :
12537   gdb_cv_os_cygwin=yes
12538 else
12539   gdb_cv_os_cygwin=no
12540 fi
12541 rm -f conftest*
12542
12543 fi
12544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
12545 $as_echo "$gdb_cv_os_cygwin" >&6; }
12546
12547
12548 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
12549 case ${host} in
12550   *go32* ) SER_HARDWIRE=ser-go32.o ;;
12551   *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
12552   *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
12553 esac
12554
12555
12556 # libreadline needs libuser32.a in a cygwin environment
12557 WIN32LIBS=
12558 if test x$gdb_cv_os_cygwin = xyes; then
12559     WIN32LIBS="-luser32"
12560     case "${target}" in
12561         *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
12562         ;;
12563     esac
12564 fi
12565
12566 # The ser-tcp.c module requires sockets.
12567 case ${host} in
12568   *mingw32*)
12569
12570 $as_echo "#define USE_WIN32API 1" >>confdefs.h
12571
12572     WIN32LIBS="$WIN32LIBS -lws2_32"
12573     ;;
12574 esac
12575
12576
12577 # Add ELF support to GDB, but only if BFD includes ELF support.
12578
12579   OLD_CFLAGS=$CFLAGS
12580   OLD_LDFLAGS=$LDFLAGS
12581   OLD_LIBS=$LIBS
12582   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
12583   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
12584   # always want our bfd.
12585   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
12586   LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
12587   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
12588   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12589   if test "$plugins" = "yes"; then
12590     LIBS="-ldl $LIBS"
12591   fi
12592   LIBS="-lbfd -liberty $intl $LIBS"
12593   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
12594 $as_echo_n "checking for ELF support in BFD... " >&6; }
12595 if test "${gdb_cv_var_elf+set}" = set; then :
12596   $as_echo_n "(cached) " >&6
12597 else
12598   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12599 /* end confdefs.h.  */
12600 #include <stdlib.h>
12601   #include "bfd.h"
12602   #include "elf-bfd.h"
12603
12604 int
12605 main ()
12606 {
12607 return bfd_get_elf_phdr_upper_bound (NULL);
12608   ;
12609   return 0;
12610 }
12611 _ACEOF
12612 if ac_fn_c_try_link "$LINENO"; then :
12613   gdb_cv_var_elf=yes
12614 else
12615   gdb_cv_var_elf=no
12616 fi
12617 rm -f core conftest.err conftest.$ac_objext \
12618     conftest$ac_exeext conftest.$ac_ext
12619 fi
12620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
12621 $as_echo "$gdb_cv_var_elf" >&6; }
12622   CFLAGS=$OLD_CFLAGS
12623   LDFLAGS=$OLD_LDFLAGS
12624   LIBS=$OLD_LIBS
12625 if test $gdb_cv_var_elf = yes; then
12626   CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o"
12627
12628 $as_echo "#define HAVE_ELF 1" >>confdefs.h
12629
12630   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12631   if test "$plugins" = "yes"; then
12632     LIBS="-ldl $LIBS"
12633   fi
12634 fi
12635
12636 # Add macho support to GDB, but only if BFD includes it.
12637
12638   OLD_CFLAGS=$CFLAGS
12639   OLD_LDFLAGS=$LDFLAGS
12640   OLD_LIBS=$LIBS
12641   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
12642   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
12643   # always want our bfd.
12644   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
12645   LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
12646   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
12647   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12648   if test "$plugins" = "yes"; then
12649     LIBS="-ldl $LIBS"
12650   fi
12651   LIBS="-lbfd -liberty $intl $LIBS"
12652   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mach-O support in BFD" >&5
12653 $as_echo_n "checking for Mach-O support in BFD... " >&6; }
12654 if test "${gdb_cv_var_macho+set}" = set; then :
12655   $as_echo_n "(cached) " >&6
12656 else
12657   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12658 /* end confdefs.h.  */
12659 #include <stdlib.h>
12660   #include "bfd.h"
12661   #include "mach-o.h"
12662
12663 int
12664 main ()
12665 {
12666 return bfd_mach_o_lookup_command (NULL, 0, NULL);
12667   ;
12668   return 0;
12669 }
12670 _ACEOF
12671 if ac_fn_c_try_link "$LINENO"; then :
12672   gdb_cv_var_macho=yes
12673 else
12674   gdb_cv_var_macho=no
12675 fi
12676 rm -f core conftest.err conftest.$ac_objext \
12677     conftest$ac_exeext conftest.$ac_ext
12678 fi
12679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_macho" >&5
12680 $as_echo "$gdb_cv_var_macho" >&6; }
12681   CFLAGS=$OLD_CFLAGS
12682   LDFLAGS=$OLD_LDFLAGS
12683   LIBS=$OLD_LIBS
12684 if test $gdb_cv_var_macho = yes; then
12685   CONFIG_OBS="$CONFIG_OBS machoread.o"
12686 fi
12687
12688 # Add SOM support to GDB, but only if BFD includes it.
12689
12690   OLD_CFLAGS=$CFLAGS
12691   OLD_LDFLAGS=$LDFLAGS
12692   OLD_LIBS=$LIBS
12693   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
12694   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
12695   # always want our bfd.
12696   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
12697   LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
12698   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
12699   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12700   if test "$plugins" = "yes"; then
12701     LIBS="-ldl $LIBS"
12702   fi
12703   LIBS="-lbfd -liberty $intl $LIBS"
12704   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SOM support in BFD" >&5
12705 $as_echo_n "checking for SOM support in BFD... " >&6; }
12706 if test "${gdb_cv_var_som+set}" = set; then :
12707   $as_echo_n "(cached) " >&6
12708 else
12709   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12710 /* end confdefs.h.  */
12711 #include <stdlib.h>
12712   #include "bfd.h"
12713   #include "som.h"
12714
12715 int
12716 main ()
12717 {
12718 return bfd_som_attach_aux_hdr (NULL, 0, NULL);
12719   ;
12720   return 0;
12721 }
12722 _ACEOF
12723 if ac_fn_c_try_link "$LINENO"; then :
12724   gdb_cv_var_som=yes
12725 else
12726   gdb_cv_var_som=no
12727 fi
12728 rm -f core conftest.err conftest.$ac_objext \
12729     conftest$ac_exeext conftest.$ac_ext
12730 fi
12731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_som" >&5
12732 $as_echo "$gdb_cv_var_som" >&6; }
12733   CFLAGS=$OLD_CFLAGS
12734   LDFLAGS=$OLD_LDFLAGS
12735   LIBS=$OLD_LIBS
12736 if test $gdb_cv_var_som = yes; then
12737   CONFIG_OBS="$CONFIG_OBS somread.o"
12738 fi
12739
12740 # Add any host-specific objects to GDB.
12741 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
12742
12743 # If building on ELF, look for lzma support for embedded compressed debug info.
12744 if test $gdb_cv_var_elf = yes; then
12745
12746 # Check whether --with-lzma was given.
12747 if test "${with_lzma+set}" = set; then :
12748   withval=$with_lzma;
12749 else
12750   with_lzma=auto
12751 fi
12752
12753   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
12754 $as_echo_n "checking whether to use lzma... " >&6; }
12755   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
12756 $as_echo "$with_lzma" >&6; }
12757
12758   if test "${with_lzma}" != no; then
12759
12760
12761
12762
12763
12764
12765
12766
12767     use_additional=yes
12768
12769   acl_save_prefix="$prefix"
12770   prefix="$acl_final_prefix"
12771   acl_save_exec_prefix="$exec_prefix"
12772   exec_prefix="$acl_final_exec_prefix"
12773
12774     eval additional_includedir=\"$includedir\"
12775     eval additional_libdir=\"$libdir\"
12776
12777   exec_prefix="$acl_save_exec_prefix"
12778   prefix="$acl_save_prefix"
12779
12780
12781 # Check whether --with-liblzma-prefix was given.
12782 if test "${with_liblzma_prefix+set}" = set; then :
12783   withval=$with_liblzma_prefix;
12784     if test "X$withval" = "Xno"; then
12785       use_additional=no
12786     else
12787       if test "X$withval" = "X"; then
12788
12789   acl_save_prefix="$prefix"
12790   prefix="$acl_final_prefix"
12791   acl_save_exec_prefix="$exec_prefix"
12792   exec_prefix="$acl_final_exec_prefix"
12793
12794           eval additional_includedir=\"$includedir\"
12795           eval additional_libdir=\"$libdir\"
12796
12797   exec_prefix="$acl_save_exec_prefix"
12798   prefix="$acl_save_prefix"
12799
12800       else
12801         additional_includedir="$withval/include"
12802         additional_libdir="$withval/lib"
12803       fi
12804     fi
12805
12806 fi
12807
12808       LIBLZMA=
12809   LTLIBLZMA=
12810   INCLZMA=
12811   rpathdirs=
12812   ltrpathdirs=
12813   names_already_handled=
12814   names_next_round='lzma '
12815   while test -n "$names_next_round"; do
12816     names_this_round="$names_next_round"
12817     names_next_round=
12818     for name in $names_this_round; do
12819       already_handled=
12820       for n in $names_already_handled; do
12821         if test "$n" = "$name"; then
12822           already_handled=yes
12823           break
12824         fi
12825       done
12826       if test -z "$already_handled"; then
12827         names_already_handled="$names_already_handled $name"
12828                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
12829         eval value=\"\$HAVE_LIB$uppername\"
12830         if test -n "$value"; then
12831           if test "$value" = yes; then
12832             eval value=\"\$LIB$uppername\"
12833             test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
12834             eval value=\"\$LTLIB$uppername\"
12835             test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
12836           else
12837                                     :
12838           fi
12839         else
12840                               found_dir=
12841           found_la=
12842           found_so=
12843           found_a=
12844           if test $use_additional = yes; then
12845             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
12846               found_dir="$additional_libdir"
12847               found_so="$additional_libdir/lib$name.$shlibext"
12848               if test -f "$additional_libdir/lib$name.la"; then
12849                 found_la="$additional_libdir/lib$name.la"
12850               fi
12851             else
12852               if test -f "$additional_libdir/lib$name.$libext"; then
12853                 found_dir="$additional_libdir"
12854                 found_a="$additional_libdir/lib$name.$libext"
12855                 if test -f "$additional_libdir/lib$name.la"; then
12856                   found_la="$additional_libdir/lib$name.la"
12857                 fi
12858               fi
12859             fi
12860           fi
12861           if test "X$found_dir" = "X"; then
12862             for x in $LDFLAGS $LTLIBLZMA; do
12863
12864   acl_save_prefix="$prefix"
12865   prefix="$acl_final_prefix"
12866   acl_save_exec_prefix="$exec_prefix"
12867   exec_prefix="$acl_final_exec_prefix"
12868   eval x=\"$x\"
12869   exec_prefix="$acl_save_exec_prefix"
12870   prefix="$acl_save_prefix"
12871
12872               case "$x" in
12873                 -L*)
12874                   dir=`echo "X$x" | sed -e 's/^X-L//'`
12875                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
12876                     found_dir="$dir"
12877                     found_so="$dir/lib$name.$shlibext"
12878                     if test -f "$dir/lib$name.la"; then
12879                       found_la="$dir/lib$name.la"
12880                     fi
12881                   else
12882                     if test -f "$dir/lib$name.$libext"; then
12883                       found_dir="$dir"
12884                       found_a="$dir/lib$name.$libext"
12885                       if test -f "$dir/lib$name.la"; then
12886                         found_la="$dir/lib$name.la"
12887                       fi
12888                     fi
12889                   fi
12890                   ;;
12891               esac
12892               if test "X$found_dir" != "X"; then
12893                 break
12894               fi
12895             done
12896           fi
12897           if test "X$found_dir" != "X"; then
12898                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
12899             if test "X$found_so" != "X"; then
12900                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
12901                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12902               else
12903                                                                                 haveit=
12904                 for x in $ltrpathdirs; do
12905                   if test "X$x" = "X$found_dir"; then
12906                     haveit=yes
12907                     break
12908                   fi
12909                 done
12910                 if test -z "$haveit"; then
12911                   ltrpathdirs="$ltrpathdirs $found_dir"
12912                 fi
12913                                 if test "$hardcode_direct" = yes; then
12914                                                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12915                 else
12916                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
12917                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12918                                                             haveit=
12919                     for x in $rpathdirs; do
12920                       if test "X$x" = "X$found_dir"; then
12921                         haveit=yes
12922                         break
12923                       fi
12924                     done
12925                     if test -z "$haveit"; then
12926                       rpathdirs="$rpathdirs $found_dir"
12927                     fi
12928                   else
12929                                                                                 haveit=
12930                     for x in $LDFLAGS $LIBLZMA; do
12931
12932   acl_save_prefix="$prefix"
12933   prefix="$acl_final_prefix"
12934   acl_save_exec_prefix="$exec_prefix"
12935   exec_prefix="$acl_final_exec_prefix"
12936   eval x=\"$x\"
12937   exec_prefix="$acl_save_exec_prefix"
12938   prefix="$acl_save_prefix"
12939
12940                       if test "X$x" = "X-L$found_dir"; then
12941                         haveit=yes
12942                         break
12943                       fi
12944                     done
12945                     if test -z "$haveit"; then
12946                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
12947                     fi
12948                     if test "$hardcode_minus_L" != no; then
12949                                                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12950                     else
12951                                                                                                                                                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
12952                     fi
12953                   fi
12954                 fi
12955               fi
12956             else
12957               if test "X$found_a" != "X"; then
12958                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
12959               else
12960                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
12961               fi
12962             fi
12963                         additional_includedir=
12964             case "$found_dir" in
12965               */lib | */lib/)
12966                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
12967                 additional_includedir="$basedir/include"
12968                 ;;
12969             esac
12970             if test "X$additional_includedir" != "X"; then
12971                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
12972                 haveit=
12973                 if test "X$additional_includedir" = "X/usr/local/include"; then
12974                   if test -n "$GCC"; then
12975                     case $host_os in
12976                       linux*) haveit=yes;;
12977                     esac
12978                   fi
12979                 fi
12980                 if test -z "$haveit"; then
12981                   for x in $CPPFLAGS $INCLZMA; do
12982
12983   acl_save_prefix="$prefix"
12984   prefix="$acl_final_prefix"
12985   acl_save_exec_prefix="$exec_prefix"
12986   exec_prefix="$acl_final_exec_prefix"
12987   eval x=\"$x\"
12988   exec_prefix="$acl_save_exec_prefix"
12989   prefix="$acl_save_prefix"
12990
12991                     if test "X$x" = "X-I$additional_includedir"; then
12992                       haveit=yes
12993                       break
12994                     fi
12995                   done
12996                   if test -z "$haveit"; then
12997                     if test -d "$additional_includedir"; then
12998                                             INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
12999                     fi
13000                   fi
13001                 fi
13002               fi
13003             fi
13004                         if test -n "$found_la"; then
13005                                                         save_libdir="$libdir"
13006               case "$found_la" in
13007                 */* | *\\*) . "$found_la" ;;
13008                 *) . "./$found_la" ;;
13009               esac
13010               libdir="$save_libdir"
13011                             for dep in $dependency_libs; do
13012                 case "$dep" in
13013                   -L*)
13014                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
13015                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
13016                       haveit=
13017                       if test "X$additional_libdir" = "X/usr/local/lib"; then
13018                         if test -n "$GCC"; then
13019                           case $host_os in
13020                             linux*) haveit=yes;;
13021                           esac
13022                         fi
13023                       fi
13024                       if test -z "$haveit"; then
13025                         haveit=
13026                         for x in $LDFLAGS $LIBLZMA; do
13027
13028   acl_save_prefix="$prefix"
13029   prefix="$acl_final_prefix"
13030   acl_save_exec_prefix="$exec_prefix"
13031   exec_prefix="$acl_final_exec_prefix"
13032   eval x=\"$x\"
13033   exec_prefix="$acl_save_exec_prefix"
13034   prefix="$acl_save_prefix"
13035
13036                           if test "X$x" = "X-L$additional_libdir"; then
13037                             haveit=yes
13038                             break
13039                           fi
13040                         done
13041                         if test -z "$haveit"; then
13042                           if test -d "$additional_libdir"; then
13043                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
13044                           fi
13045                         fi
13046                         haveit=
13047                         for x in $LDFLAGS $LTLIBLZMA; do
13048
13049   acl_save_prefix="$prefix"
13050   prefix="$acl_final_prefix"
13051   acl_save_exec_prefix="$exec_prefix"
13052   exec_prefix="$acl_final_exec_prefix"
13053   eval x=\"$x\"
13054   exec_prefix="$acl_save_exec_prefix"
13055   prefix="$acl_save_prefix"
13056
13057                           if test "X$x" = "X-L$additional_libdir"; then
13058                             haveit=yes
13059                             break
13060                           fi
13061                         done
13062                         if test -z "$haveit"; then
13063                           if test -d "$additional_libdir"; then
13064                                                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
13065                           fi
13066                         fi
13067                       fi
13068                     fi
13069                     ;;
13070                   -R*)
13071                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
13072                     if test "$enable_rpath" != no; then
13073                                                                   haveit=
13074                       for x in $rpathdirs; do
13075                         if test "X$x" = "X$dir"; then
13076                           haveit=yes
13077                           break
13078                         fi
13079                       done
13080                       if test -z "$haveit"; then
13081                         rpathdirs="$rpathdirs $dir"
13082                       fi
13083                                                                   haveit=
13084                       for x in $ltrpathdirs; do
13085                         if test "X$x" = "X$dir"; then
13086                           haveit=yes
13087                           break
13088                         fi
13089                       done
13090                       if test -z "$haveit"; then
13091                         ltrpathdirs="$ltrpathdirs $dir"
13092                       fi
13093                     fi
13094                     ;;
13095                   -l*)
13096                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
13097                     ;;
13098                   *.la)
13099                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
13100                     ;;
13101                   *)
13102                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
13103                     LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
13104                     ;;
13105                 esac
13106               done
13107             fi
13108           else
13109                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
13110             LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
13111           fi
13112         fi
13113       fi
13114     done
13115   done
13116   if test "X$rpathdirs" != "X"; then
13117     if test -n "$hardcode_libdir_separator"; then
13118                         alldirs=
13119       for found_dir in $rpathdirs; do
13120         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
13121       done
13122             acl_save_libdir="$libdir"
13123       libdir="$alldirs"
13124       eval flag=\"$hardcode_libdir_flag_spec\"
13125       libdir="$acl_save_libdir"
13126       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
13127     else
13128             for found_dir in $rpathdirs; do
13129         acl_save_libdir="$libdir"
13130         libdir="$found_dir"
13131         eval flag=\"$hardcode_libdir_flag_spec\"
13132         libdir="$acl_save_libdir"
13133         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
13134       done
13135     fi
13136   fi
13137   if test "X$ltrpathdirs" != "X"; then
13138             for found_dir in $ltrpathdirs; do
13139       LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
13140     done
13141   fi
13142
13143
13144         ac_save_CPPFLAGS="$CPPFLAGS"
13145
13146   for element in $INCLZMA; do
13147     haveit=
13148     for x in $CPPFLAGS; do
13149
13150   acl_save_prefix="$prefix"
13151   prefix="$acl_final_prefix"
13152   acl_save_exec_prefix="$exec_prefix"
13153   exec_prefix="$acl_final_exec_prefix"
13154   eval x=\"$x\"
13155   exec_prefix="$acl_save_exec_prefix"
13156   prefix="$acl_save_prefix"
13157
13158       if test "X$x" = "X$element"; then
13159         haveit=yes
13160         break
13161       fi
13162     done
13163     if test -z "$haveit"; then
13164       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
13165     fi
13166   done
13167
13168
13169   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
13170 $as_echo_n "checking for liblzma... " >&6; }
13171 if test "${ac_cv_liblzma+set}" = set; then :
13172   $as_echo_n "(cached) " >&6
13173 else
13174
13175     ac_save_LIBS="$LIBS"
13176     LIBS="$LIBS $LIBLZMA"
13177     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13178 /* end confdefs.h.  */
13179 #include "lzma.h"
13180 int
13181 main ()
13182 {
13183 lzma_index_iter iter;
13184                            lzma_index_iter_init (&iter, 0);
13185                            lzma_mf_is_supported (LZMA_MF_HC3);
13186   ;
13187   return 0;
13188 }
13189 _ACEOF
13190 if ac_fn_c_try_link "$LINENO"; then :
13191   ac_cv_liblzma=yes
13192 else
13193   ac_cv_liblzma=no
13194 fi
13195 rm -f core conftest.err conftest.$ac_objext \
13196     conftest$ac_exeext conftest.$ac_ext
13197     LIBS="$ac_save_LIBS"
13198
13199 fi
13200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
13201 $as_echo "$ac_cv_liblzma" >&6; }
13202   if test "$ac_cv_liblzma" = yes; then
13203     HAVE_LIBLZMA=yes
13204
13205 $as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
13206
13207     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
13208 $as_echo_n "checking how to link with liblzma... " >&6; }
13209     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
13210 $as_echo "$LIBLZMA" >&6; }
13211   else
13212     HAVE_LIBLZMA=no
13213             CPPFLAGS="$ac_save_CPPFLAGS"
13214     LIBLZMA=
13215     LTLIBLZMA=
13216   fi
13217
13218
13219
13220
13221
13222
13223     if test "$HAVE_LIBLZMA" != yes; then
13224       if test "$with_lzma" = yes; then
13225         as_fn_error "missing liblzma for --with-lzma" "$LINENO" 5
13226       fi
13227     fi
13228   fi
13229 fi
13230
13231 LIBGUI="../libgui/src/libgui.a"
13232 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
13233
13234
13235
13236 WIN32LDAPP=
13237
13238
13239
13240 case "${host}" in
13241 *-*-cygwin* | *-*-mingw* )
13242     configdir="win"
13243     ;;
13244 *)
13245     configdir="unix"
13246     ;;
13247 esac
13248
13249 GDBTKLIBS=
13250 if test "${enable_gdbtk}" = "yes"; then
13251
13252     # Gdbtk must have an absolute path to srcdir in order to run
13253     # properly when not installed.
13254     here=`pwd`
13255     cd ${srcdir}
13256     GDBTK_SRC_DIR=`pwd`
13257     cd $here
13258
13259
13260     #
13261     # Ok, lets find the tcl configuration
13262     # First, look for one uninstalled.
13263     # the alternative search directory is invoked by --with-tcl
13264     #
13265
13266     if test x"${no_tcl}" = x ; then
13267         # we reset no_tcl in case something fails here
13268         no_tcl=true
13269
13270 # Check whether --with-tcl was given.
13271 if test "${with_tcl+set}" = set; then :
13272   withval=$with_tcl; with_tclconfig=${withval}
13273 fi
13274
13275         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
13276 $as_echo_n "checking for Tcl configuration... " >&6; }
13277         if test "${ac_cv_c_tclconfig+set}" = set; then :
13278   $as_echo_n "(cached) " >&6
13279 else
13280
13281
13282             # First check to see if --with-tcl was specified.
13283             case "${host}" in
13284                 *-*-cygwin*) platDir="win" ;;
13285                 *) platDir="unix" ;;
13286             esac
13287             if test x"${with_tclconfig}" != x ; then
13288                 if test -f "${with_tclconfig}/tclConfig.sh" ; then
13289                     ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
13290                 else
13291                     as_fn_error "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
13292                 fi
13293             fi
13294
13295             # then check for a private Tcl installation
13296             if test x"${ac_cv_c_tclconfig}" = x ; then
13297                 for i in \
13298                         ../tcl \
13299                         `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13300                         `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
13301                         `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
13302                         ../../tcl \
13303                         `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13304                         `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
13305                         `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
13306                         ../../../tcl \
13307                         `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13308                         `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
13309                         `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
13310                     if test -f "$i/$platDir/tclConfig.sh" ; then
13311                         ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
13312                         break
13313                     fi
13314                 done
13315             fi
13316
13317             # on Darwin, check in Framework installation locations
13318             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
13319                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
13320                         `ls -d /Library/Frameworks 2>/dev/null` \
13321                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
13322                         `ls -d /System/Library/Frameworks 2>/dev/null` \
13323                         ; do
13324                     if test -f "$i/Tcl.framework/tclConfig.sh" ; then
13325                         ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
13326                         break
13327                     fi
13328                 done
13329             fi
13330
13331             # check in a few common install locations
13332             if test x"${ac_cv_c_tclconfig}" = x ; then
13333                 for i in `ls -d ${libdir} 2>/dev/null` \
13334                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
13335                         `ls -d ${prefix}/lib 2>/dev/null` \
13336                         `ls -d /usr/local/lib 2>/dev/null` \
13337                         `ls -d /usr/contrib/lib 2>/dev/null` \
13338                         `ls -d /usr/lib 2>/dev/null` \
13339                         ; do
13340                     if test -f "$i/tclConfig.sh" ; then
13341                         ac_cv_c_tclconfig=`(cd $i; pwd)`
13342                         break
13343                     fi
13344                 done
13345             fi
13346
13347             # check in a few other private locations
13348             if test x"${ac_cv_c_tclconfig}" = x ; then
13349                 for i in \
13350                         ${srcdir}/../tcl \
13351                         `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13352                         `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
13353                         `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
13354                     if test -f "$i/$platDir/tclConfig.sh" ; then
13355                     ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
13356                     break
13357                 fi
13358                 done
13359             fi
13360
13361 fi
13362
13363
13364         if test x"${ac_cv_c_tclconfig}" = x ; then
13365             TCL_BIN_DIR="# no Tcl configs found"
13366             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
13367 $as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
13368         else
13369             no_tcl=
13370             TCL_BIN_DIR=${ac_cv_c_tclconfig}
13371             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
13372 $as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
13373         fi
13374     fi
13375
13376
13377     # If $no_tk is nonempty, then we can't do Tk, and there is no
13378     # point to doing Tcl.
13379
13380     #
13381     # Ok, lets find the tk configuration
13382     # First, look for one uninstalled.
13383     # the alternative search directory is invoked by --with-tk
13384     #
13385
13386     if test x"${no_tk}" = x ; then
13387         # we reset no_tk in case something fails here
13388         no_tk=true
13389
13390 # Check whether --with-tk was given.
13391 if test "${with_tk+set}" = set; then :
13392   withval=$with_tk; with_tkconfig=${withval}
13393 fi
13394
13395         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
13396 $as_echo_n "checking for Tk configuration... " >&6; }
13397         if test "${ac_cv_c_tkconfig+set}" = set; then :
13398   $as_echo_n "(cached) " >&6
13399 else
13400
13401
13402             # First check to see if --with-tkconfig was specified.
13403             if test x"${with_tkconfig}" != x ; then
13404                 if test -f "${with_tkconfig}/tkConfig.sh" ; then
13405                     ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
13406                 else
13407                     as_fn_error "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
13408                 fi
13409             fi
13410
13411             # then check for a private Tk library
13412             case "${host}" in
13413                 *-*-cygwin*) platDir="win" ;;
13414                 *) platDir="unix" ;;
13415             esac
13416             if test x"${ac_cv_c_tkconfig}" = x ; then
13417                 for i in \
13418                         ../tk \
13419                         `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13420                         `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
13421                         `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
13422                         ../../tk \
13423                         `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13424                         `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
13425                         `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
13426                         ../../../tk \
13427                         `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13428                         `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
13429                         `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
13430                     if test -f "$i/$platDir/tkConfig.sh" ; then
13431                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
13432                         break
13433                     fi
13434                 done
13435             fi
13436
13437             # on Darwin, check in Framework installation locations
13438             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
13439                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
13440                         `ls -d /Library/Frameworks 2>/dev/null` \
13441                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
13442                         `ls -d /System/Library/Frameworks 2>/dev/null` \
13443                         ; do
13444                     if test -f "$i/Tk.framework/tkConfig.sh" ; then
13445                         ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
13446                         break
13447                     fi
13448                 done
13449             fi
13450
13451             # check in a few common install locations
13452             if test x"${ac_cv_c_tkconfig}" = x ; then
13453                 for i in `ls -d ${libdir} 2>/dev/null` \
13454                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
13455                         `ls -d ${prefix}/lib 2>/dev/null` \
13456                         `ls -d /usr/local/lib 2>/dev/null` \
13457                         `ls -d /usr/contrib/lib 2>/dev/null` \
13458                         `ls -d /usr/lib 2>/dev/null` \
13459                         ; do
13460                     if test -f "$i/tkConfig.sh" ; then
13461                         ac_cv_c_tkconfig=`(cd $i; pwd)`
13462                         break
13463                     fi
13464                 done
13465             fi
13466             # check in a few other private locations
13467             if test x"${ac_cv_c_tkconfig}" = x ; then
13468                 for i in \
13469                         ${srcdir}/../tk \
13470                         `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13471                         `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
13472                         `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
13473                     if test -f "$i/$platDir/tkConfig.sh" ; then
13474                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
13475                         break
13476                     fi
13477                 done
13478             fi
13479
13480 fi
13481
13482
13483         if test x"${ac_cv_c_tkconfig}" = x ; then
13484             TK_BIN_DIR="# no Tk configs found"
13485             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
13486 $as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
13487         else
13488             no_tk=
13489             TK_BIN_DIR=${ac_cv_c_tkconfig}
13490             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
13491 $as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
13492         fi
13493     fi
13494
13495
13496     if test -z "${no_tcl}" -a -z "${no_tk}"; then
13497
13498     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
13499 $as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
13500
13501     if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
13502         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
13503 $as_echo "loading" >&6; }
13504         . ${TCL_BIN_DIR}/tclConfig.sh
13505     else
13506         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
13507 $as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
13508     fi
13509
13510     # eval is required to do the TCL_DBGX substitution
13511     eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
13512     eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
13513
13514     # If the TCL_BIN_DIR is the build directory (not the install directory),
13515     # then set the common variable name to the value of the build variables.
13516     # For example, the variable TCL_LIB_SPEC will be set to the value
13517     # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
13518     # instead of TCL_BUILD_LIB_SPEC since it will work with both an
13519     # installed and uninstalled version of Tcl.
13520     if test -f "${TCL_BIN_DIR}/Makefile" ; then
13521         TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
13522         TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
13523         TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
13524     elif test "`uname -s`" = "Darwin"; then
13525         # If Tcl was built as a framework, attempt to use the libraries
13526         # from the framework at the given location so that linking works
13527         # against Tcl.framework installed in an arbitrary location.
13528         case ${TCL_DEFS} in
13529             *TCL_FRAMEWORK*)
13530                 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
13531                     for i in "`cd ${TCL_BIN_DIR}; pwd`" \
13532                              "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
13533                         if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
13534                             TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
13535                             break
13536                         fi
13537                     done
13538                 fi
13539                 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
13540                     TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
13541                     TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
13542                 fi
13543                 ;;
13544         esac
13545     fi
13546
13547     # eval is required to do the TCL_DBGX substitution
13548     eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
13549     eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
13550     eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
13551     eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
13552
13553
13554
13555
13556
13557
13558
13559
13560
13561
13562
13563
13564
13565
13566
13567         # Check for in-tree tcl
13568         here=`pwd`
13569         cd ${srcdir}/..
13570         topdir=`pwd`
13571         cd ${here}
13572
13573         intree="no"
13574         if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
13575           intree="yes"
13576         fi
13577
13578         # Find Tcl private headers
13579         if test x"${intree}" = xno; then
13580
13581   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
13582 $as_echo_n "checking for Tcl private headers... " >&6; }
13583   private_dir=""
13584   dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
13585   if test -f ${dir}/tclInt.h ; then
13586     private_dir=${dir}
13587   fi
13588
13589   if test x"${private_dir}" = x; then
13590     as_fn_error "could not find private Tcl headers" "$LINENO" 5
13591   else
13592     TCL_PRIVATE_INCLUDE="-I${private_dir}"
13593     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
13594 $as_echo "${private_dir}" >&6; }
13595   fi
13596
13597           TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
13598           TCL_LIBRARY="${TCL_LIB_SPEC}"
13599           TCL_DEPS=""
13600         else
13601           # If building tcl in the same src tree, private headers
13602           # are not needed, but we need to be sure to use the right
13603           # headers library
13604           TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
13605           TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
13606           TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
13607         fi
13608
13609
13610
13611
13612
13613     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
13614 $as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
13615
13616     if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
13617         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
13618 $as_echo "loading" >&6; }
13619         . ${TK_BIN_DIR}/tkConfig.sh
13620     else
13621         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
13622 $as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
13623     fi
13624
13625     # eval is required to do the TK_DBGX substitution
13626     eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
13627     eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
13628
13629     # If the TK_BIN_DIR is the build directory (not the install directory),
13630     # then set the common variable name to the value of the build variables.
13631     # For example, the variable TK_LIB_SPEC will be set to the value
13632     # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
13633     # instead of TK_BUILD_LIB_SPEC since it will work with both an
13634     # installed and uninstalled version of Tcl.
13635     if test -f "${TK_BIN_DIR}/Makefile" ; then
13636         TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
13637         TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
13638         TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
13639     elif test "`uname -s`" = "Darwin"; then
13640         # If Tk was built as a framework, attempt to use the libraries
13641         # from the framework at the given location so that linking works
13642         # against Tk.framework installed in an arbitrary location.
13643         case ${TK_DEFS} in
13644             *TK_FRAMEWORK*)
13645                 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
13646                     for i in "`cd ${TK_BIN_DIR}; pwd`" \
13647                              "`cd ${TK_BIN_DIR}/../..; pwd`"; do
13648                         if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
13649                             TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
13650                             break
13651                         fi
13652                     done
13653                 fi
13654                 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
13655                     TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
13656                     TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
13657                 fi
13658                 ;;
13659         esac
13660     fi
13661
13662     # eval is required to do the TK_DBGX substitution
13663     eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
13664     eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
13665     eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
13666     eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
13667
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679
13680
13681         # Check for in-tree Tk
13682         intree="no"
13683         if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
13684           intree="yes"
13685         fi
13686
13687         # Find Tk private headers
13688         if test x"${intree}" = xno; then
13689
13690   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
13691 $as_echo_n "checking for Tk private headers... " >&6; }
13692   private_dir=""
13693   dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
13694   if test -f ${dir}/tkInt.h; then
13695     private_dir=${dir}
13696   fi
13697
13698   if test x"${private_dir}" = x; then
13699     as_fn_error "could not find Tk private headers" "$LINENO" 5
13700   else
13701     TK_PRIVATE_INCLUDE="-I${private_dir}"
13702     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
13703 $as_echo "${private_dir}" >&6; }
13704   fi
13705
13706           TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
13707           TK_LIBRARY=${TK_LIB_SPEC}
13708           TK_DEPS=""
13709         else
13710           TK_INCLUDE="-I${TK_SRC_DIR}/generic"
13711           TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
13712           TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
13713         fi
13714
13715
13716
13717
13718
13719         ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
13720
13721         # Include some libraries that Tcl and Tk want.
13722         TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
13723         # Yes, the ordering seems wrong here.  But it isn't.
13724         # TK_LIBS is the list of libraries that need to be linked
13725         # after Tcl/Tk.  Note that this isn't put into LIBS.  If it
13726         # were in LIBS then any link tests after this point would
13727         # try to include things like `$(LIBGUI)', which wouldn't work.
13728         GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
13729
13730         CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
13731         CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
13732         CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
13733         CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
13734         CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
13735         CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
13736         CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
13737
13738         if test x$gdb_cv_os_cygwin = xyes; then
13739           WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
13740           WIN32LDAPP="-Wl,--subsystem,console"
13741           CONFIG_OBS="${CONFIG_OBS} gdbres.o"
13742         fi
13743
13744         subdirs="$subdirs gdbtk"
13745
13746     fi
13747 fi
13748
13749
13750
13751
13752
13753
13754
13755
13756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
13757 $as_echo_n "checking for X... " >&6; }
13758
13759
13760 # Check whether --with-x was given.
13761 if test "${with_x+set}" = set; then :
13762   withval=$with_x;
13763 fi
13764
13765 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
13766 if test "x$with_x" = xno; then
13767   # The user explicitly disabled X.
13768   have_x=disabled
13769 else
13770   case $x_includes,$x_libraries in #(
13771     *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
13772     *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
13773   $as_echo_n "(cached) " >&6
13774 else
13775   # One or both of the vars are not set, and there is no cached value.
13776 ac_x_includes=no ac_x_libraries=no
13777 rm -f -r conftest.dir
13778 if mkdir conftest.dir; then
13779   cd conftest.dir
13780   cat >Imakefile <<'_ACEOF'
13781 incroot:
13782         @echo incroot='${INCROOT}'
13783 usrlibdir:
13784         @echo usrlibdir='${USRLIBDIR}'
13785 libdir:
13786         @echo libdir='${LIBDIR}'
13787 _ACEOF
13788   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
13789     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
13790     for ac_var in incroot usrlibdir libdir; do
13791       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
13792     done
13793     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
13794     for ac_extension in a so sl dylib la dll; do
13795       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
13796          test -f "$ac_im_libdir/libX11.$ac_extension"; then
13797         ac_im_usrlibdir=$ac_im_libdir; break
13798       fi
13799     done
13800     # Screen out bogus values from the imake configuration.  They are
13801     # bogus both because they are the default anyway, and because
13802     # using them would break gcc on systems where it needs fixed includes.
13803     case $ac_im_incroot in
13804         /usr/include) ac_x_includes= ;;
13805         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
13806     esac
13807     case $ac_im_usrlibdir in
13808         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
13809         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
13810     esac
13811   fi
13812   cd ..
13813   rm -f -r conftest.dir
13814 fi
13815
13816 # Standard set of common directories for X headers.
13817 # Check X11 before X11Rn because it is often a symlink to the current release.
13818 ac_x_header_dirs='
13819 /usr/X11/include
13820 /usr/X11R7/include
13821 /usr/X11R6/include
13822 /usr/X11R5/include
13823 /usr/X11R4/include
13824
13825 /usr/include/X11
13826 /usr/include/X11R7
13827 /usr/include/X11R6
13828 /usr/include/X11R5
13829 /usr/include/X11R4
13830
13831 /usr/local/X11/include
13832 /usr/local/X11R7/include
13833 /usr/local/X11R6/include
13834 /usr/local/X11R5/include
13835 /usr/local/X11R4/include
13836
13837 /usr/local/include/X11
13838 /usr/local/include/X11R7
13839 /usr/local/include/X11R6
13840 /usr/local/include/X11R5
13841 /usr/local/include/X11R4
13842
13843 /usr/X386/include
13844 /usr/x386/include
13845 /usr/XFree86/include/X11
13846
13847 /usr/include
13848 /usr/local/include
13849 /usr/unsupported/include
13850 /usr/athena/include
13851 /usr/local/x11r5/include
13852 /usr/lpp/Xamples/include
13853
13854 /usr/openwin/include
13855 /usr/openwin/share/include'
13856
13857 if test "$ac_x_includes" = no; then
13858   # Guess where to find include files, by looking for Xlib.h.
13859   # First, try using that file with no special directory specified.
13860   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13861 /* end confdefs.h.  */
13862 #include <X11/Xlib.h>
13863 _ACEOF
13864 if ac_fn_c_try_cpp "$LINENO"; then :
13865   # We can compile using X headers with no special include directory.
13866 ac_x_includes=
13867 else
13868   for ac_dir in $ac_x_header_dirs; do
13869   if test -r "$ac_dir/X11/Xlib.h"; then
13870     ac_x_includes=$ac_dir
13871     break
13872   fi
13873 done
13874 fi
13875 rm -f conftest.err conftest.$ac_ext
13876 fi # $ac_x_includes = no
13877
13878 if test "$ac_x_libraries" = no; then
13879   # Check for the libraries.
13880   # See if we find them without any special options.
13881   # Don't add to $LIBS permanently.
13882   ac_save_LIBS=$LIBS
13883   LIBS="-lX11 $LIBS"
13884   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13885 /* end confdefs.h.  */
13886 #include <X11/Xlib.h>
13887 int
13888 main ()
13889 {
13890 XrmInitialize ()
13891   ;
13892   return 0;
13893 }
13894 _ACEOF
13895 if ac_fn_c_try_link "$LINENO"; then :
13896   LIBS=$ac_save_LIBS
13897 # We can link X programs with no special library path.
13898 ac_x_libraries=
13899 else
13900   LIBS=$ac_save_LIBS
13901 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
13902 do
13903   # Don't even attempt the hair of trying to link an X program!
13904   for ac_extension in a so sl dylib la dll; do
13905     if test -r "$ac_dir/libX11.$ac_extension"; then
13906       ac_x_libraries=$ac_dir
13907       break 2
13908     fi
13909   done
13910 done
13911 fi
13912 rm -f core conftest.err conftest.$ac_objext \
13913     conftest$ac_exeext conftest.$ac_ext
13914 fi # $ac_x_libraries = no
13915
13916 case $ac_x_includes,$ac_x_libraries in #(
13917   no,* | *,no | *\'*)
13918     # Didn't find X, or a directory has "'" in its name.
13919     ac_cv_have_x="have_x=no";; #(
13920   *)
13921     # Record where we found X for the cache.
13922     ac_cv_have_x="have_x=yes\
13923         ac_x_includes='$ac_x_includes'\
13924         ac_x_libraries='$ac_x_libraries'"
13925 esac
13926 fi
13927 ;; #(
13928     *) have_x=yes;;
13929   esac
13930   eval "$ac_cv_have_x"
13931 fi # $with_x != no
13932
13933 if test "$have_x" != yes; then
13934   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
13935 $as_echo "$have_x" >&6; }
13936   no_x=yes
13937 else
13938   # If each of the values was on the command line, it overrides each guess.
13939   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
13940   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
13941   # Update the cache value to reflect the command line values.
13942   ac_cv_have_x="have_x=yes\
13943         ac_x_includes='$x_includes'\
13944         ac_x_libraries='$x_libraries'"
13945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
13946 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
13947 fi
13948
13949
13950 # Unlike the sim directory, whether a simulator is linked is controlled by
13951 # presence of a gdb_sim definition in the target configure.tgt entry.
13952 # This code just checks for a few cases where we'd like to ignore those
13953 # definitions, even when they're present in the '.mt' file.  These cases
13954 # are when --disable-sim is specified, or if the simulator directory is
13955 # not part of the source tree.
13956 #
13957 # Check whether --enable-sim was given.
13958 if test "${enable_sim+set}" = set; then :
13959   enableval=$enable_sim; echo "enable_sim = $enable_sim";
13960  echo "enableval = ${enableval}";
13961  case "${enableval}" in
13962   yes) ignore_sim=false ;;
13963   no)  ignore_sim=true ;;
13964   *)   ignore_sim=false ;;
13965  esac
13966 else
13967   ignore_sim=false
13968 fi
13969
13970
13971 if test ! -d "${srcdir}/../sim"; then
13972   ignore_sim=true
13973 fi
13974
13975 SIM=
13976 SIM_OBS=
13977 if test "${ignore_sim}" = "false"; then
13978   if test x"${gdb_sim}" != x ; then
13979     SIM="${gdb_sim}"
13980     SIM_OBS="remote-sim.o"
13981
13982 $as_echo "#define WITH_SIM 1" >>confdefs.h
13983
13984   fi
13985 fi
13986
13987
13988
13989
13990
13991
13992
13993
13994
13995
13996
13997
13998
13999
14000 # List of host floatformats.
14001
14002 cat >>confdefs.h <<_ACEOF
14003 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
14004 _ACEOF
14005
14006
14007 cat >>confdefs.h <<_ACEOF
14008 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
14009 _ACEOF
14010
14011
14012 cat >>confdefs.h <<_ACEOF
14013 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
14014 _ACEOF
14015
14016
14017 # target_subdir is used by the testsuite to find the target libraries.
14018 target_subdir=
14019 if test "${host}" != "${target}"; then
14020     target_subdir="${target_alias}/"
14021 fi
14022
14023
14024 frags=
14025 if test "${gdb_native}" = "yes"; then
14026   host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
14027   if test ! -f ${host_makefile_frag}; then
14028     as_fn_error "\"*** Gdb does not support native target ${host}\"" "$LINENO" 5
14029   fi
14030   frags="$frags $host_makefile_frag"
14031 else
14032   host_makefile_frag=/dev/null
14033 fi
14034
14035
14036
14037
14038 if test "${gdb_native}" = "yes"; then
14039 # We pick this up from the host configuration file (.mh) because we
14040 # do not have a native configuration Makefile fragment.
14041 nativefile=`sed -n '
14042 s/NAT_FILE[     ]*=[    ]*\([^  ]*\)/\1/p
14043 ' ${host_makefile_frag}`
14044 fi
14045
14046
14047 if test x"${gdb_osabi}" != x ; then
14048
14049 cat >>confdefs.h <<_ACEOF
14050 #define GDB_OSABI_DEFAULT $gdb_osabi
14051 _ACEOF
14052
14053 fi
14054
14055 # Enable multi-ice-gdb-server.
14056 # Check whether --enable-multi-ice was given.
14057 if test "${enable_multi_ice+set}" = set; then :
14058   enableval=$enable_multi_ice; case $enableval in
14059     yes | no)
14060       ;;
14061     *) as_fn_error "bad value $enableval for --enable-multi-ice" "$LINENO" 5 ;;
14062   esac
14063 fi
14064
14065 if test "x$enable_multi_ice" = xyes; then
14066    subdirs="$subdirs multi-ice"
14067
14068 fi
14069
14070 # Check whether --enable-gdbserver was given.
14071 if test "${enable_gdbserver+set}" = set; then :
14072   enableval=$enable_gdbserver; case "${enableval}" in
14073   yes| no|auto) ;;
14074   *) as_fn_error "bad value ${enableval} for --enable-gdbserver option" "$LINENO" 5 ;;
14075 esac
14076 else
14077   enable_gdbserver=auto
14078 fi
14079
14080
14081 # We only build gdbserver automatically in a native configuration, and
14082 # only if the user did not explicitly disable its build.
14083 if test "$gdb_native" = "yes" -a "$enable_gdbserver" != "no"; then
14084   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gdbserver is supported on this host" >&5
14085 $as_echo_n "checking whether gdbserver is supported on this host... " >&6; }
14086   if test "x$build_gdbserver" = xyes; then
14087     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14088 $as_echo "yes" >&6; }
14089     subdirs="$subdirs gdbserver"
14090
14091     gdbserver_build_enabled=yes
14092   else
14093     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14094 $as_echo "no" >&6; }
14095   fi
14096 fi
14097
14098 # If the user explicitly request the gdbserver to be built, verify that
14099 # we were in fact able to enable it.
14100 if test "$enable_gdbserver" = "yes" -a "$gdbserver_build_enabled" != "yes"; then
14101   as_fn_error "Automatic gdbserver build is not supported for this configuration" "$LINENO" 5
14102 fi
14103
14104 # Check for babeltrace and babeltrace-ctf
14105
14106 # Check whether --with-babeltrace was given.
14107 if test "${with_babeltrace+set}" = set; then :
14108   withval=$with_babeltrace;
14109 else
14110   with_babeltrace=auto
14111 fi
14112
14113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use babeltrace" >&5
14114 $as_echo_n "checking whether to use babeltrace... " >&6; }
14115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_babeltrace" >&5
14116 $as_echo "$with_babeltrace" >&6; }
14117
14118 if test "x$with_babeltrace" = "xno"; then
14119   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&5
14120 $as_echo "$as_me: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&2;}
14121 else
14122   # Append -Werror to CFLAGS so that configure can catch the warning
14123   # "assignment from incompatible pointer type", which is related to
14124   # the babeltrace change from 1.0.3 to 1.1.0.  Babeltrace 1.1.0 works
14125   # in GDB, while babeltrace 1.0.3 is broken.
14126   # AC_LIB_HAVE_LINKFLAGS may modify CPPFLAGS in it, so it should be
14127   # safe to save and restore CFLAGS here.
14128   saved_CFLAGS=$CFLAGS
14129   CFLAGS="$CFLAGS -Werror"
14130
14131
14132
14133
14134
14135
14136
14137
14138     use_additional=yes
14139
14140   acl_save_prefix="$prefix"
14141   prefix="$acl_final_prefix"
14142   acl_save_exec_prefix="$exec_prefix"
14143   exec_prefix="$acl_final_exec_prefix"
14144
14145     eval additional_includedir=\"$includedir\"
14146     eval additional_libdir=\"$libdir\"
14147
14148   exec_prefix="$acl_save_exec_prefix"
14149   prefix="$acl_save_prefix"
14150
14151
14152 # Check whether --with-libbabeltrace-prefix was given.
14153 if test "${with_libbabeltrace_prefix+set}" = set; then :
14154   withval=$with_libbabeltrace_prefix;
14155     if test "X$withval" = "Xno"; then
14156       use_additional=no
14157     else
14158       if test "X$withval" = "X"; then
14159
14160   acl_save_prefix="$prefix"
14161   prefix="$acl_final_prefix"
14162   acl_save_exec_prefix="$exec_prefix"
14163   exec_prefix="$acl_final_exec_prefix"
14164
14165           eval additional_includedir=\"$includedir\"
14166           eval additional_libdir=\"$libdir\"
14167
14168   exec_prefix="$acl_save_exec_prefix"
14169   prefix="$acl_save_prefix"
14170
14171       else
14172         additional_includedir="$withval/include"
14173         additional_libdir="$withval/lib"
14174       fi
14175     fi
14176
14177 fi
14178
14179       LIBBABELTRACE=
14180   LTLIBBABELTRACE=
14181   INCBABELTRACE=
14182   rpathdirs=
14183   ltrpathdirs=
14184   names_already_handled=
14185   names_next_round='babeltrace babeltrace-ctf'
14186   while test -n "$names_next_round"; do
14187     names_this_round="$names_next_round"
14188     names_next_round=
14189     for name in $names_this_round; do
14190       already_handled=
14191       for n in $names_already_handled; do
14192         if test "$n" = "$name"; then
14193           already_handled=yes
14194           break
14195         fi
14196       done
14197       if test -z "$already_handled"; then
14198         names_already_handled="$names_already_handled $name"
14199                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
14200         eval value=\"\$HAVE_LIB$uppername\"
14201         if test -n "$value"; then
14202           if test "$value" = yes; then
14203             eval value=\"\$LIB$uppername\"
14204             test -z "$value" || LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$value"
14205             eval value=\"\$LTLIB$uppername\"
14206             test -z "$value" || LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$value"
14207           else
14208                                     :
14209           fi
14210         else
14211                               found_dir=
14212           found_la=
14213           found_so=
14214           found_a=
14215           if test $use_additional = yes; then
14216             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
14217               found_dir="$additional_libdir"
14218               found_so="$additional_libdir/lib$name.$shlibext"
14219               if test -f "$additional_libdir/lib$name.la"; then
14220                 found_la="$additional_libdir/lib$name.la"
14221               fi
14222             else
14223               if test -f "$additional_libdir/lib$name.$libext"; then
14224                 found_dir="$additional_libdir"
14225                 found_a="$additional_libdir/lib$name.$libext"
14226                 if test -f "$additional_libdir/lib$name.la"; then
14227                   found_la="$additional_libdir/lib$name.la"
14228                 fi
14229               fi
14230             fi
14231           fi
14232           if test "X$found_dir" = "X"; then
14233             for x in $LDFLAGS $LTLIBBABELTRACE; do
14234
14235   acl_save_prefix="$prefix"
14236   prefix="$acl_final_prefix"
14237   acl_save_exec_prefix="$exec_prefix"
14238   exec_prefix="$acl_final_exec_prefix"
14239   eval x=\"$x\"
14240   exec_prefix="$acl_save_exec_prefix"
14241   prefix="$acl_save_prefix"
14242
14243               case "$x" in
14244                 -L*)
14245                   dir=`echo "X$x" | sed -e 's/^X-L//'`
14246                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
14247                     found_dir="$dir"
14248                     found_so="$dir/lib$name.$shlibext"
14249                     if test -f "$dir/lib$name.la"; then
14250                       found_la="$dir/lib$name.la"
14251                     fi
14252                   else
14253                     if test -f "$dir/lib$name.$libext"; then
14254                       found_dir="$dir"
14255                       found_a="$dir/lib$name.$libext"
14256                       if test -f "$dir/lib$name.la"; then
14257                         found_la="$dir/lib$name.la"
14258                       fi
14259                     fi
14260                   fi
14261                   ;;
14262               esac
14263               if test "X$found_dir" != "X"; then
14264                 break
14265               fi
14266             done
14267           fi
14268           if test "X$found_dir" != "X"; then
14269                         LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$found_dir -l$name"
14270             if test "X$found_so" != "X"; then
14271                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
14272                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
14273               else
14274                                                                                 haveit=
14275                 for x in $ltrpathdirs; do
14276                   if test "X$x" = "X$found_dir"; then
14277                     haveit=yes
14278                     break
14279                   fi
14280                 done
14281                 if test -z "$haveit"; then
14282                   ltrpathdirs="$ltrpathdirs $found_dir"
14283                 fi
14284                                 if test "$hardcode_direct" = yes; then
14285                                                       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
14286                 else
14287                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
14288                                                             LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
14289                                                             haveit=
14290                     for x in $rpathdirs; do
14291                       if test "X$x" = "X$found_dir"; then
14292                         haveit=yes
14293                         break
14294                       fi
14295                     done
14296                     if test -z "$haveit"; then
14297                       rpathdirs="$rpathdirs $found_dir"
14298                     fi
14299                   else
14300                                                                                 haveit=
14301                     for x in $LDFLAGS $LIBBABELTRACE; do
14302
14303   acl_save_prefix="$prefix"
14304   prefix="$acl_final_prefix"
14305   acl_save_exec_prefix="$exec_prefix"
14306   exec_prefix="$acl_final_exec_prefix"
14307   eval x=\"$x\"
14308   exec_prefix="$acl_save_exec_prefix"
14309   prefix="$acl_save_prefix"
14310
14311                       if test "X$x" = "X-L$found_dir"; then
14312                         haveit=yes
14313                         break
14314                       fi
14315                     done
14316                     if test -z "$haveit"; then
14317                       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir"
14318                     fi
14319                     if test "$hardcode_minus_L" != no; then
14320                                                                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
14321                     else
14322                                                                                                                                                                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
14323                     fi
14324                   fi
14325                 fi
14326               fi
14327             else
14328               if test "X$found_a" != "X"; then
14329                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_a"
14330               else
14331                                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir -l$name"
14332               fi
14333             fi
14334                         additional_includedir=
14335             case "$found_dir" in
14336               */lib | */lib/)
14337                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
14338                 additional_includedir="$basedir/include"
14339                 ;;
14340             esac
14341             if test "X$additional_includedir" != "X"; then
14342                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
14343                 haveit=
14344                 if test "X$additional_includedir" = "X/usr/local/include"; then
14345                   if test -n "$GCC"; then
14346                     case $host_os in
14347                       linux*) haveit=yes;;
14348                     esac
14349                   fi
14350                 fi
14351                 if test -z "$haveit"; then
14352                   for x in $CPPFLAGS $INCBABELTRACE; do
14353
14354   acl_save_prefix="$prefix"
14355   prefix="$acl_final_prefix"
14356   acl_save_exec_prefix="$exec_prefix"
14357   exec_prefix="$acl_final_exec_prefix"
14358   eval x=\"$x\"
14359   exec_prefix="$acl_save_exec_prefix"
14360   prefix="$acl_save_prefix"
14361
14362                     if test "X$x" = "X-I$additional_includedir"; then
14363                       haveit=yes
14364                       break
14365                     fi
14366                   done
14367                   if test -z "$haveit"; then
14368                     if test -d "$additional_includedir"; then
14369                                             INCBABELTRACE="${INCBABELTRACE}${INCBABELTRACE:+ }-I$additional_includedir"
14370                     fi
14371                   fi
14372                 fi
14373               fi
14374             fi
14375                         if test -n "$found_la"; then
14376                                                         save_libdir="$libdir"
14377               case "$found_la" in
14378                 */* | *\\*) . "$found_la" ;;
14379                 *) . "./$found_la" ;;
14380               esac
14381               libdir="$save_libdir"
14382                             for dep in $dependency_libs; do
14383                 case "$dep" in
14384                   -L*)
14385                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
14386                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
14387                       haveit=
14388                       if test "X$additional_libdir" = "X/usr/local/lib"; then
14389                         if test -n "$GCC"; then
14390                           case $host_os in
14391                             linux*) haveit=yes;;
14392                           esac
14393                         fi
14394                       fi
14395                       if test -z "$haveit"; then
14396                         haveit=
14397                         for x in $LDFLAGS $LIBBABELTRACE; do
14398
14399   acl_save_prefix="$prefix"
14400   prefix="$acl_final_prefix"
14401   acl_save_exec_prefix="$exec_prefix"
14402   exec_prefix="$acl_final_exec_prefix"
14403   eval x=\"$x\"
14404   exec_prefix="$acl_save_exec_prefix"
14405   prefix="$acl_save_prefix"
14406
14407                           if test "X$x" = "X-L$additional_libdir"; then
14408                             haveit=yes
14409                             break
14410                           fi
14411                         done
14412                         if test -z "$haveit"; then
14413                           if test -d "$additional_libdir"; then
14414                                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$additional_libdir"
14415                           fi
14416                         fi
14417                         haveit=
14418                         for x in $LDFLAGS $LTLIBBABELTRACE; do
14419
14420   acl_save_prefix="$prefix"
14421   prefix="$acl_final_prefix"
14422   acl_save_exec_prefix="$exec_prefix"
14423   exec_prefix="$acl_final_exec_prefix"
14424   eval x=\"$x\"
14425   exec_prefix="$acl_save_exec_prefix"
14426   prefix="$acl_save_prefix"
14427
14428                           if test "X$x" = "X-L$additional_libdir"; then
14429                             haveit=yes
14430                             break
14431                           fi
14432                         done
14433                         if test -z "$haveit"; then
14434                           if test -d "$additional_libdir"; then
14435                                                         LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$additional_libdir"
14436                           fi
14437                         fi
14438                       fi
14439                     fi
14440                     ;;
14441                   -R*)
14442                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
14443                     if test "$enable_rpath" != no; then
14444                                                                   haveit=
14445                       for x in $rpathdirs; do
14446                         if test "X$x" = "X$dir"; then
14447                           haveit=yes
14448                           break
14449                         fi
14450                       done
14451                       if test -z "$haveit"; then
14452                         rpathdirs="$rpathdirs $dir"
14453                       fi
14454                                                                   haveit=
14455                       for x in $ltrpathdirs; do
14456                         if test "X$x" = "X$dir"; then
14457                           haveit=yes
14458                           break
14459                         fi
14460                       done
14461                       if test -z "$haveit"; then
14462                         ltrpathdirs="$ltrpathdirs $dir"
14463                       fi
14464                     fi
14465                     ;;
14466                   -l*)
14467                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
14468                     ;;
14469                   *.la)
14470                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
14471                     ;;
14472                   *)
14473                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$dep"
14474                     LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$dep"
14475                     ;;
14476                 esac
14477               done
14478             fi
14479           else
14480                                                             LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
14481             LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l$name"
14482           fi
14483         fi
14484       fi
14485     done
14486   done
14487   if test "X$rpathdirs" != "X"; then
14488     if test -n "$hardcode_libdir_separator"; then
14489                         alldirs=
14490       for found_dir in $rpathdirs; do
14491         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
14492       done
14493             acl_save_libdir="$libdir"
14494       libdir="$alldirs"
14495       eval flag=\"$hardcode_libdir_flag_spec\"
14496       libdir="$acl_save_libdir"
14497       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
14498     else
14499             for found_dir in $rpathdirs; do
14500         acl_save_libdir="$libdir"
14501         libdir="$found_dir"
14502         eval flag=\"$hardcode_libdir_flag_spec\"
14503         libdir="$acl_save_libdir"
14504         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
14505       done
14506     fi
14507   fi
14508   if test "X$ltrpathdirs" != "X"; then
14509             for found_dir in $ltrpathdirs; do
14510       LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-R$found_dir"
14511     done
14512   fi
14513
14514
14515         ac_save_CPPFLAGS="$CPPFLAGS"
14516
14517   for element in $INCBABELTRACE; do
14518     haveit=
14519     for x in $CPPFLAGS; do
14520
14521   acl_save_prefix="$prefix"
14522   prefix="$acl_final_prefix"
14523   acl_save_exec_prefix="$exec_prefix"
14524   exec_prefix="$acl_final_exec_prefix"
14525   eval x=\"$x\"
14526   exec_prefix="$acl_save_exec_prefix"
14527   prefix="$acl_save_prefix"
14528
14529       if test "X$x" = "X$element"; then
14530         haveit=yes
14531         break
14532       fi
14533     done
14534     if test -z "$haveit"; then
14535       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
14536     fi
14537   done
14538
14539
14540   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbabeltrace" >&5
14541 $as_echo_n "checking for libbabeltrace... " >&6; }
14542 if test "${ac_cv_libbabeltrace+set}" = set; then :
14543   $as_echo_n "(cached) " >&6
14544 else
14545
14546     ac_save_LIBS="$LIBS"
14547     LIBS="$LIBS $LIBBABELTRACE"
14548     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14549 /* end confdefs.h.  */
14550 #include <babeltrace/babeltrace.h>
14551                          #include <babeltrace/ctf/events.h>
14552                          #include <babeltrace/ctf/iterator.h>
14553 int
14554 main ()
14555 {
14556 struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL));
14557                         struct bt_ctf_event *event = NULL;
14558                         const struct bt_definition *scope;
14559
14560                         scope = bt_ctf_get_top_level_scope (event,
14561                                                            BT_STREAM_EVENT_HEADER);
14562                         bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));
14563
14564   ;
14565   return 0;
14566 }
14567 _ACEOF
14568 if ac_fn_c_try_link "$LINENO"; then :
14569   ac_cv_libbabeltrace=yes
14570 else
14571   ac_cv_libbabeltrace=no
14572 fi
14573 rm -f core conftest.err conftest.$ac_objext \
14574     conftest$ac_exeext conftest.$ac_ext
14575     LIBS="$ac_save_LIBS"
14576
14577 fi
14578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libbabeltrace" >&5
14579 $as_echo "$ac_cv_libbabeltrace" >&6; }
14580   if test "$ac_cv_libbabeltrace" = yes; then
14581     HAVE_LIBBABELTRACE=yes
14582
14583 $as_echo "#define HAVE_LIBBABELTRACE 1" >>confdefs.h
14584
14585     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libbabeltrace" >&5
14586 $as_echo_n "checking how to link with libbabeltrace... " >&6; }
14587     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBBABELTRACE" >&5
14588 $as_echo "$LIBBABELTRACE" >&6; }
14589   else
14590     HAVE_LIBBABELTRACE=no
14591             CPPFLAGS="$ac_save_CPPFLAGS"
14592     LIBBABELTRACE=
14593     LTLIBBABELTRACE=
14594   fi
14595
14596
14597
14598
14599
14600
14601   CFLAGS=$saved_CFLAGS
14602
14603   if test "$HAVE_LIBBABELTRACE" != yes; then
14604      if test "$with_babeltrace" = yes; then
14605        as_fn_error "babeltrace is missing or unusable" "$LINENO" 5
14606      else
14607        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&5
14608 $as_echo "$as_me: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&2;}
14609      fi
14610   fi
14611 fi
14612
14613 # If nativefile (NAT_FILE) is not set in config/*/*.m[ht] files, we link
14614 # to an empty version.
14615
14616 files=
14617 links=
14618
14619 rm -f nm.h
14620 if test "${nativefile}" != ""; then
14621     case "${nativefile}" in
14622       nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
14623       * ) GDB_NM_FILE="${nativefile}"
14624     esac
14625     files="${files} ${GDB_NM_FILE}"
14626     links="${links} nm.h"
14627
14628 cat >>confdefs.h <<_ACEOF
14629 #define GDB_NM_FILE "${GDB_NM_FILE}"
14630 _ACEOF
14631
14632 fi
14633
14634
14635 ac_sources="$files"
14636 ac_dests="$links"
14637 while test -n "$ac_sources"; do
14638   set $ac_dests; ac_dest=$1; shift; ac_dests=$*
14639   set $ac_sources; ac_source=$1; shift; ac_sources=$*
14640   ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
14641 done
14642 ac_config_links="$ac_config_links $ac_config_links_1"
14643
14644
14645
14646
14647
14648 $as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
14649
14650
14651 ac_config_files="$ac_config_files Makefile gdb-gdb.gdb doc/Makefile data-directory/Makefile"
14652
14653 ac_config_commands="$ac_config_commands default"
14654
14655 cat >confcache <<\_ACEOF
14656 # This file is a shell script that caches the results of configure
14657 # tests run on this system so they can be shared between configure
14658 # scripts and configure runs, see configure's option --config-cache.
14659 # It is not useful on other systems.  If it contains results you don't
14660 # want to keep, you may remove or edit it.
14661 #
14662 # config.status only pays attention to the cache file if you give it
14663 # the --recheck option to rerun configure.
14664 #
14665 # `ac_cv_env_foo' variables (set or unset) will be overridden when
14666 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14667 # following values.
14668
14669 _ACEOF
14670
14671 # The following way of writing the cache mishandles newlines in values,
14672 # but we know of no workaround that is simple, portable, and efficient.
14673 # So, we kill variables containing newlines.
14674 # Ultrix sh set writes to stderr and can't be redirected directly,
14675 # and sets the high bit in the cache file unless we assign to the vars.
14676 (
14677   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
14678     eval ac_val=\$$ac_var
14679     case $ac_val in #(
14680     *${as_nl}*)
14681       case $ac_var in #(
14682       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
14683 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
14684       esac
14685       case $ac_var in #(
14686       _ | IFS | as_nl) ;; #(
14687       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
14688       *) { eval $ac_var=; unset $ac_var;} ;;
14689       esac ;;
14690     esac
14691   done
14692
14693   (set) 2>&1 |
14694     case $as_nl`(ac_space=' '; set) 2>&1` in #(
14695     *${as_nl}ac_space=\ *)
14696       # `set' does not quote correctly, so add quotes: double-quote
14697       # substitution turns \\\\ into \\, and sed turns \\ into \.
14698       sed -n \
14699         "s/'/'\\\\''/g;
14700           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14701       ;; #(
14702     *)
14703       # `set' quotes correctly as required by POSIX, so do not add quotes.
14704       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
14705       ;;
14706     esac |
14707     sort
14708 ) |
14709   sed '
14710      /^ac_cv_env_/b end
14711      t clear
14712      :clear
14713      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14714      t end
14715      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14716      :end' >>confcache
14717 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
14718   if test -w "$cache_file"; then
14719     test "x$cache_file" != "x/dev/null" &&
14720       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
14721 $as_echo "$as_me: updating cache $cache_file" >&6;}
14722     cat confcache >$cache_file
14723   else
14724     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
14725 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
14726   fi
14727 fi
14728 rm -f confcache
14729
14730 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14731 # Let make expand exec_prefix.
14732 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14733
14734 DEFS=-DHAVE_CONFIG_H
14735
14736 ac_libobjs=
14737 ac_ltlibobjs=
14738 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
14739   # 1. Remove the extension, and $U if already installed.
14740   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
14741   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
14742   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
14743   #    will be set to the directory where LIBOBJS objects are built.
14744   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
14745   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
14746 done
14747 LIBOBJS=$ac_libobjs
14748
14749 LTLIBOBJS=$ac_ltlibobjs
14750
14751
14752 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
14753   as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
14754 Usually this means the macro was only invoked conditionally." "$LINENO" 5
14755 fi
14756 if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
14757   as_fn_error "conditional \"GMAKE\" was never defined.
14758 Usually this means the macro was only invoked conditionally." "$LINENO" 5
14759 fi
14760
14761
14762 : ${CONFIG_STATUS=./config.status}
14763 ac_write_fail=0
14764 ac_clean_files_save=$ac_clean_files
14765 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14766 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
14767 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
14768 as_write_fail=0
14769 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
14770 #! $SHELL
14771 # Generated by $as_me.
14772 # Run this file to recreate the current configuration.
14773 # Compiler output produced by configure, useful for debugging
14774 # configure, is in config.log if it exists.
14775
14776 debug=false
14777 ac_cs_recheck=false
14778 ac_cs_silent=false
14779
14780 SHELL=\${CONFIG_SHELL-$SHELL}
14781 export SHELL
14782 _ASEOF
14783 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
14784 ## -------------------- ##
14785 ## M4sh Initialization. ##
14786 ## -------------------- ##
14787
14788 # Be more Bourne compatible
14789 DUALCASE=1; export DUALCASE # for MKS sh
14790 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14791   emulate sh
14792   NULLCMD=:
14793   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14794   # is contrary to our usage.  Disable this feature.
14795   alias -g '${1+"$@"}'='"$@"'
14796   setopt NO_GLOB_SUBST
14797 else
14798   case `(set -o) 2>/dev/null` in #(
14799   *posix*) :
14800     set -o posix ;; #(
14801   *) :
14802      ;;
14803 esac
14804 fi
14805
14806
14807 as_nl='
14808 '
14809 export as_nl
14810 # Printing a long string crashes Solaris 7 /usr/bin/printf.
14811 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14812 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14813 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14814 # Prefer a ksh shell builtin over an external printf program on Solaris,
14815 # but without wasting forks for bash or zsh.
14816 if test -z "$BASH_VERSION$ZSH_VERSION" \
14817     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14818   as_echo='print -r --'
14819   as_echo_n='print -rn --'
14820 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14821   as_echo='printf %s\n'
14822   as_echo_n='printf %s'
14823 else
14824   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14825     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14826     as_echo_n='/usr/ucb/echo -n'
14827   else
14828     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14829     as_echo_n_body='eval
14830       arg=$1;
14831       case $arg in #(
14832       *"$as_nl"*)
14833         expr "X$arg" : "X\\(.*\\)$as_nl";
14834         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14835       esac;
14836       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14837     '
14838     export as_echo_n_body
14839     as_echo_n='sh -c $as_echo_n_body as_echo'
14840   fi
14841   export as_echo_body
14842   as_echo='sh -c $as_echo_body as_echo'
14843 fi
14844
14845 # The user is always right.
14846 if test "${PATH_SEPARATOR+set}" != set; then
14847   PATH_SEPARATOR=:
14848   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14849     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14850       PATH_SEPARATOR=';'
14851   }
14852 fi
14853
14854
14855 # IFS
14856 # We need space, tab and new line, in precisely that order.  Quoting is
14857 # there to prevent editors from complaining about space-tab.
14858 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
14859 # splitting by setting IFS to empty value.)
14860 IFS=" ""        $as_nl"
14861
14862 # Find who we are.  Look in the path if we contain no directory separator.
14863 case $0 in #((
14864   *[\\/]* ) as_myself=$0 ;;
14865   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14866 for as_dir in $PATH
14867 do
14868   IFS=$as_save_IFS
14869   test -z "$as_dir" && as_dir=.
14870     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14871   done
14872 IFS=$as_save_IFS
14873
14874      ;;
14875 esac
14876 # We did not find ourselves, most probably we were run as `sh COMMAND'
14877 # in which case we are not to be found in the path.
14878 if test "x$as_myself" = x; then
14879   as_myself=$0
14880 fi
14881 if test ! -f "$as_myself"; then
14882   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14883   exit 1
14884 fi
14885
14886 # Unset variables that we do not need and which cause bugs (e.g. in
14887 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
14888 # suppresses any "Segmentation fault" message there.  '((' could
14889 # trigger a bug in pdksh 5.2.14.
14890 for as_var in BASH_ENV ENV MAIL MAILPATH
14891 do eval test x\${$as_var+set} = xset \
14892   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14893 done
14894 PS1='$ '
14895 PS2='> '
14896 PS4='+ '
14897
14898 # NLS nuisances.
14899 LC_ALL=C
14900 export LC_ALL
14901 LANGUAGE=C
14902 export LANGUAGE
14903
14904 # CDPATH.
14905 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
14906
14907
14908 # as_fn_error ERROR [LINENO LOG_FD]
14909 # ---------------------------------
14910 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
14911 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
14912 # script with status $?, using 1 if that was 0.
14913 as_fn_error ()
14914 {
14915   as_status=$?; test $as_status -eq 0 && as_status=1
14916   if test "$3"; then
14917     as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
14918     $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
14919   fi
14920   $as_echo "$as_me: error: $1" >&2
14921   as_fn_exit $as_status
14922 } # as_fn_error
14923
14924
14925 # as_fn_set_status STATUS
14926 # -----------------------
14927 # Set $? to STATUS, without forking.
14928 as_fn_set_status ()
14929 {
14930   return $1
14931 } # as_fn_set_status
14932
14933 # as_fn_exit STATUS
14934 # -----------------
14935 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
14936 as_fn_exit ()
14937 {
14938   set +e
14939   as_fn_set_status $1
14940   exit $1
14941 } # as_fn_exit
14942
14943 # as_fn_unset VAR
14944 # ---------------
14945 # Portably unset VAR.
14946 as_fn_unset ()
14947 {
14948   { eval $1=; unset $1;}
14949 }
14950 as_unset=as_fn_unset
14951 # as_fn_append VAR VALUE
14952 # ----------------------
14953 # Append the text in VALUE to the end of the definition contained in VAR. Take
14954 # advantage of any shell optimizations that allow amortized linear growth over
14955 # repeated appends, instead of the typical quadratic growth present in naive
14956 # implementations.
14957 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
14958   eval 'as_fn_append ()
14959   {
14960     eval $1+=\$2
14961   }'
14962 else
14963   as_fn_append ()
14964   {
14965     eval $1=\$$1\$2
14966   }
14967 fi # as_fn_append
14968
14969 # as_fn_arith ARG...
14970 # ------------------
14971 # Perform arithmetic evaluation on the ARGs, and store the result in the
14972 # global $as_val. Take advantage of shells that can avoid forks. The arguments
14973 # must be portable across $(()) and expr.
14974 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
14975   eval 'as_fn_arith ()
14976   {
14977     as_val=$(( $* ))
14978   }'
14979 else
14980   as_fn_arith ()
14981   {
14982     as_val=`expr "$@" || test $? -eq 1`
14983   }
14984 fi # as_fn_arith
14985
14986
14987 if expr a : '\(a\)' >/dev/null 2>&1 &&
14988    test "X`expr 00001 : '.*\(...\)'`" = X001; then
14989   as_expr=expr
14990 else
14991   as_expr=false
14992 fi
14993
14994 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
14995   as_basename=basename
14996 else
14997   as_basename=false
14998 fi
14999
15000 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
15001   as_dirname=dirname
15002 else
15003   as_dirname=false
15004 fi
15005
15006 as_me=`$as_basename -- "$0" ||
15007 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
15008          X"$0" : 'X\(//\)$' \| \
15009          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
15010 $as_echo X/"$0" |
15011     sed '/^.*\/\([^/][^/]*\)\/*$/{
15012             s//\1/
15013             q
15014           }
15015           /^X\/\(\/\/\)$/{
15016             s//\1/
15017             q
15018           }
15019           /^X\/\(\/\).*/{
15020             s//\1/
15021             q
15022           }
15023           s/.*/./; q'`
15024
15025 # Avoid depending upon Character Ranges.
15026 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
15027 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
15028 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15029 as_cr_digits='0123456789'
15030 as_cr_alnum=$as_cr_Letters$as_cr_digits
15031
15032 ECHO_C= ECHO_N= ECHO_T=
15033 case `echo -n x` in #(((((
15034 -n*)
15035   case `echo 'xy\c'` in
15036   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
15037   xy)  ECHO_C='\c';;
15038   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
15039        ECHO_T=' ';;
15040   esac;;
15041 *)
15042   ECHO_N='-n';;
15043 esac
15044
15045 rm -f conf$$ conf$$.exe conf$$.file
15046 if test -d conf$$.dir; then
15047   rm -f conf$$.dir/conf$$.file
15048 else
15049   rm -f conf$$.dir
15050   mkdir conf$$.dir 2>/dev/null
15051 fi
15052 if (echo >conf$$.file) 2>/dev/null; then
15053   if ln -s conf$$.file conf$$ 2>/dev/null; then
15054     as_ln_s='ln -s'
15055     # ... but there are two gotchas:
15056     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
15057     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
15058     # In both cases, we have to default to `cp -p'.
15059     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
15060       as_ln_s='cp -p'
15061   elif ln conf$$.file conf$$ 2>/dev/null; then
15062     as_ln_s=ln
15063   else
15064     as_ln_s='cp -p'
15065   fi
15066 else
15067   as_ln_s='cp -p'
15068 fi
15069 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
15070 rmdir conf$$.dir 2>/dev/null
15071
15072
15073 # as_fn_mkdir_p
15074 # -------------
15075 # Create "$as_dir" as a directory, including parents if necessary.
15076 as_fn_mkdir_p ()
15077 {
15078
15079   case $as_dir in #(
15080   -*) as_dir=./$as_dir;;
15081   esac
15082   test -d "$as_dir" || eval $as_mkdir_p || {
15083     as_dirs=
15084     while :; do
15085       case $as_dir in #(
15086       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
15087       *) as_qdir=$as_dir;;
15088       esac
15089       as_dirs="'$as_qdir' $as_dirs"
15090       as_dir=`$as_dirname -- "$as_dir" ||
15091 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15092          X"$as_dir" : 'X\(//\)[^/]' \| \
15093          X"$as_dir" : 'X\(//\)$' \| \
15094          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
15095 $as_echo X"$as_dir" |
15096     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15097             s//\1/
15098             q
15099           }
15100           /^X\(\/\/\)[^/].*/{
15101             s//\1/
15102             q
15103           }
15104           /^X\(\/\/\)$/{
15105             s//\1/
15106             q
15107           }
15108           /^X\(\/\).*/{
15109             s//\1/
15110             q
15111           }
15112           s/.*/./; q'`
15113       test -d "$as_dir" && break
15114     done
15115     test -z "$as_dirs" || eval "mkdir $as_dirs"
15116   } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
15117
15118
15119 } # as_fn_mkdir_p
15120 if mkdir -p . 2>/dev/null; then
15121   as_mkdir_p='mkdir -p "$as_dir"'
15122 else
15123   test -d ./-p && rmdir ./-p
15124   as_mkdir_p=false
15125 fi
15126
15127 if test -x / >/dev/null 2>&1; then
15128   as_test_x='test -x'
15129 else
15130   if ls -dL / >/dev/null 2>&1; then
15131     as_ls_L_option=L
15132   else
15133     as_ls_L_option=
15134   fi
15135   as_test_x='
15136     eval sh -c '\''
15137       if test -d "$1"; then
15138         test -d "$1/.";
15139       else
15140         case $1 in #(
15141         -*)set "./$1";;
15142         esac;
15143         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
15144         ???[sx]*):;;*)false;;esac;fi
15145     '\'' sh
15146   '
15147 fi
15148 as_executable_p=$as_test_x
15149
15150 # Sed expression to map a string onto a valid CPP name.
15151 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
15152
15153 # Sed expression to map a string onto a valid variable name.
15154 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
15155
15156
15157 exec 6>&1
15158 ## ----------------------------------- ##
15159 ## Main body of $CONFIG_STATUS script. ##
15160 ## ----------------------------------- ##
15161 _ASEOF
15162 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
15163
15164 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15165 # Save the log message, to keep $0 and so on meaningful, and to
15166 # report actual input values of CONFIG_FILES etc. instead of their
15167 # values after options handling.
15168 ac_log="
15169 This file was extended by $as_me, which was
15170 generated by GNU Autoconf 2.64.  Invocation command line was
15171
15172   CONFIG_FILES    = $CONFIG_FILES
15173   CONFIG_HEADERS  = $CONFIG_HEADERS
15174   CONFIG_LINKS    = $CONFIG_LINKS
15175   CONFIG_COMMANDS = $CONFIG_COMMANDS
15176   $ $0 $@
15177
15178 on `(hostname || uname -n) 2>/dev/null | sed 1q`
15179 "
15180
15181 _ACEOF
15182
15183 case $ac_config_files in *"
15184 "*) set x $ac_config_files; shift; ac_config_files=$*;;
15185 esac
15186
15187 case $ac_config_headers in *"
15188 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
15189 esac
15190
15191
15192 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15193 # Files that config.status was made for.
15194 config_files="$ac_config_files"
15195 config_headers="$ac_config_headers"
15196 config_links="$ac_config_links"
15197 config_commands="$ac_config_commands"
15198
15199 _ACEOF
15200
15201 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15202 ac_cs_usage="\
15203 \`$as_me' instantiates files and other configuration actions
15204 from templates according to the current configuration.  Unless the files
15205 and actions are specified as TAGs, all are instantiated by default.
15206
15207 Usage: $0 [OPTION]... [TAG]...
15208
15209   -h, --help       print this help, then exit
15210   -V, --version    print version number and configuration settings, then exit
15211   -q, --quiet, --silent
15212                    do not print progress messages
15213   -d, --debug      don't remove temporary files
15214       --recheck    update $as_me by reconfiguring in the same conditions
15215       --file=FILE[:TEMPLATE]
15216                    instantiate the configuration file FILE
15217       --header=FILE[:TEMPLATE]
15218                    instantiate the configuration header FILE
15219
15220 Configuration files:
15221 $config_files
15222
15223 Configuration headers:
15224 $config_headers
15225
15226 Configuration links:
15227 $config_links
15228
15229 Configuration commands:
15230 $config_commands
15231
15232 Report bugs to the package provider."
15233
15234 _ACEOF
15235 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15236 ac_cs_version="\\
15237 config.status
15238 configured by $0, generated by GNU Autoconf 2.64,
15239   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
15240
15241 Copyright (C) 2009 Free Software Foundation, Inc.
15242 This config.status script is free software; the Free Software Foundation
15243 gives unlimited permission to copy, distribute and modify it."
15244
15245 ac_pwd='$ac_pwd'
15246 srcdir='$srcdir'
15247 INSTALL='$INSTALL'
15248 AWK='$AWK'
15249 test -n "\$AWK" || AWK=awk
15250 _ACEOF
15251
15252 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15253 # The default lists apply if the user does not specify any file.
15254 ac_need_defaults=:
15255 while test $# != 0
15256 do
15257   case $1 in
15258   --*=*)
15259     ac_option=`expr "X$1" : 'X\([^=]*\)='`
15260     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
15261     ac_shift=:
15262     ;;
15263   *)
15264     ac_option=$1
15265     ac_optarg=$2
15266     ac_shift=shift
15267     ;;
15268   esac
15269
15270   case $ac_option in
15271   # Handling of the options.
15272   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
15273     ac_cs_recheck=: ;;
15274   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
15275     $as_echo "$ac_cs_version"; exit ;;
15276   --debug | --debu | --deb | --de | --d | -d )
15277     debug=: ;;
15278   --file | --fil | --fi | --f )
15279     $ac_shift
15280     case $ac_optarg in
15281     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15282     esac
15283     as_fn_append CONFIG_FILES " '$ac_optarg'"
15284     ac_need_defaults=false;;
15285   --header | --heade | --head | --hea )
15286     $ac_shift
15287     case $ac_optarg in
15288     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15289     esac
15290     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
15291     ac_need_defaults=false;;
15292   --he | --h)
15293     # Conflict between --help and --header
15294     as_fn_error "ambiguous option: \`$1'
15295 Try \`$0 --help' for more information.";;
15296   --help | --hel | -h )
15297     $as_echo "$ac_cs_usage"; exit ;;
15298   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
15299   | -silent | --silent | --silen | --sile | --sil | --si | --s)
15300     ac_cs_silent=: ;;
15301
15302   # This is an error.
15303   -*) as_fn_error "unrecognized option: \`$1'
15304 Try \`$0 --help' for more information." ;;
15305
15306   *) as_fn_append ac_config_targets " $1"
15307      ac_need_defaults=false ;;
15308
15309   esac
15310   shift
15311 done
15312
15313 ac_configure_extra_args=
15314
15315 if $ac_cs_silent; then
15316   exec 6>/dev/null
15317   ac_configure_extra_args="$ac_configure_extra_args --silent"
15318 fi
15319
15320 _ACEOF
15321 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15322 if \$ac_cs_recheck; then
15323   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
15324   shift
15325   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
15326   CONFIG_SHELL='$SHELL'
15327   export CONFIG_SHELL
15328   exec "\$@"
15329 fi
15330
15331 _ACEOF
15332 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15333 exec 5>>config.log
15334 {
15335   echo
15336   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15337 ## Running $as_me. ##
15338 _ASBOX
15339   $as_echo "$ac_log"
15340 } >&5
15341
15342 _ACEOF
15343 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15344 #
15345 # INIT-COMMANDS
15346 #
15347 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
15348
15349 _ACEOF
15350
15351 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15352
15353 # Handling of arguments.
15354 for ac_config_target in $ac_config_targets
15355 do
15356   case $ac_config_target in
15357     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
15358     "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
15359     "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
15360     "$ac_config_links_1") CONFIG_LINKS="$CONFIG_LINKS $ac_config_links_1" ;;
15361     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15362     "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
15363     "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
15364     "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
15365     "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15366
15367   *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
15368   esac
15369 done
15370
15371
15372 # If the user did not use the arguments to specify the items to instantiate,
15373 # then the envvar interface is used.  Set only those that are not.
15374 # We use the long form for the default assignment because of an extremely
15375 # bizarre bug on SunOS 4.1.3.
15376 if $ac_need_defaults; then
15377   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15378   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15379   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
15380   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15381 fi
15382
15383 # Have a temporary directory for convenience.  Make it in the build tree
15384 # simply because there is no reason against having it here, and in addition,
15385 # creating and moving files from /tmp can sometimes cause problems.
15386 # Hook for its removal unless debugging.
15387 # Note that there is a small window in which the directory will not be cleaned:
15388 # after its creation but before its name has been assigned to `$tmp'.
15389 $debug ||
15390 {
15391   tmp=
15392   trap 'exit_status=$?
15393   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
15394 ' 0
15395   trap 'as_fn_exit 1' 1 2 13 15
15396 }
15397 # Create a (secure) tmp directory for tmp files.
15398
15399 {
15400   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
15401   test -n "$tmp" && test -d "$tmp"
15402 }  ||
15403 {
15404   tmp=./conf$$-$RANDOM
15405   (umask 077 && mkdir "$tmp")
15406 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
15407
15408 # Set up the scripts for CONFIG_FILES section.
15409 # No need to generate them if there are no CONFIG_FILES.
15410 # This happens for instance with `./config.status config.h'.
15411 if test -n "$CONFIG_FILES"; then
15412
15413 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
15414   ac_cs_awk_getline=:
15415   ac_cs_awk_pipe_init=
15416   ac_cs_awk_read_file='
15417       while ((getline aline < (F[key])) > 0)
15418         print(aline)
15419       close(F[key])'
15420   ac_cs_awk_pipe_fini=
15421 else
15422   ac_cs_awk_getline=false
15423   ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
15424   ac_cs_awk_read_file='
15425       print "|#_!!_#|"
15426       print "cat " F[key] " &&"
15427       '$ac_cs_awk_pipe_init
15428   # The final `:' finishes the AND list.
15429   ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
15430 fi
15431 ac_cr=`echo X | tr X '\015'`
15432 # On cygwin, bash can eat \r inside `` if the user requested igncr.
15433 # But we know of no other shell where ac_cr would be empty at this
15434 # point, so we can use a bashism as a fallback.
15435 if test "x$ac_cr" = x; then
15436   eval ac_cr=\$\'\\r\'
15437 fi
15438 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
15439 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
15440   ac_cs_awk_cr='\r'
15441 else
15442   ac_cs_awk_cr=$ac_cr
15443 fi
15444
15445 echo 'BEGIN {' >"$tmp/subs1.awk" &&
15446 _ACEOF
15447
15448 # Create commands to substitute file output variables.
15449 {
15450   echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
15451   echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
15452   echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
15453   echo "_ACAWK" &&
15454   echo "_ACEOF"
15455 } >conf$$files.sh &&
15456 . ./conf$$files.sh ||
15457   as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15458 rm -f conf$$files.sh
15459
15460 {
15461   echo "cat >conf$$subs.awk <<_ACEOF" &&
15462   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
15463   echo "_ACEOF"
15464 } >conf$$subs.sh ||
15465   as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15466 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
15467 ac_delim='%!_!# '
15468 for ac_last_try in false false false false false :; do
15469   . ./conf$$subs.sh ||
15470     as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15471
15472   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
15473   if test $ac_delim_n = $ac_delim_num; then
15474     break
15475   elif $ac_last_try; then
15476     as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15477   else
15478     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15479   fi
15480 done
15481 rm -f conf$$subs.sh
15482
15483 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15484 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
15485 _ACEOF
15486 sed -n '
15487 h
15488 s/^/S["/; s/!.*/"]=/
15489 p
15490 g
15491 s/^[^!]*!//
15492 :repl
15493 t repl
15494 s/'"$ac_delim"'$//
15495 t delim
15496 :nl
15497 h
15498 s/\(.\{148\}\).*/\1/
15499 t more1
15500 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
15501 p
15502 n
15503 b repl
15504 :more1
15505 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15506 p
15507 g
15508 s/.\{148\}//
15509 t nl
15510 :delim
15511 h
15512 s/\(.\{148\}\).*/\1/
15513 t more2
15514 s/["\\]/\\&/g; s/^/"/; s/$/"/
15515 p
15516 b
15517 :more2
15518 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15519 p
15520 g
15521 s/.\{148\}//
15522 t delim
15523 ' <conf$$subs.awk | sed '
15524 /^[^""]/{
15525   N
15526   s/\n//
15527 }
15528 ' >>$CONFIG_STATUS || ac_write_fail=1
15529 rm -f conf$$subs.awk
15530 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15531 _ACAWK
15532 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
15533   for (key in S) S_is_set[key] = 1
15534   FS = "\a"
15535   \$ac_cs_awk_pipe_init
15536 }
15537 {
15538   line = $ 0
15539   nfields = split(line, field, "@")
15540   substed = 0
15541   len = length(field[1])
15542   for (i = 2; i < nfields; i++) {
15543     key = field[i]
15544     keylen = length(key)
15545     if (S_is_set[key]) {
15546       value = S[key]
15547       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
15548       len += length(value) + length(field[++i])
15549       substed = 1
15550     } else
15551       len += 1 + keylen
15552   }
15553   if (nfields == 3 && !substed) {
15554     key = field[2]
15555     if (F[key] != "" && line ~ /^[       ]*@.*@[         ]*$/) {
15556       \$ac_cs_awk_read_file
15557       next
15558     }
15559   }
15560   print line
15561 }
15562 \$ac_cs_awk_pipe_fini
15563 _ACAWK
15564 _ACEOF
15565 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15566 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
15567   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
15568 else
15569   cat
15570 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
15571   || as_fn_error "could not setup config files machinery" "$LINENO" 5
15572 _ACEOF
15573
15574 # VPATH may cause trouble with some makes, so we remove $(srcdir),
15575 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
15576 # trailing colons and then remove the whole line if VPATH becomes empty
15577 # (actually we leave an empty line to preserve line numbers).
15578 if test "x$srcdir" = x.; then
15579   ac_vpsub='/^[  ]*VPATH[        ]*=/{
15580 s/:*\$(srcdir):*/:/
15581 s/:*\${srcdir}:*/:/
15582 s/:*@srcdir@:*/:/
15583 s/^\([^=]*=[     ]*\):*/\1/
15584 s/:*$//
15585 s/^[^=]*=[       ]*$//
15586 }'
15587 fi
15588
15589 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15590 fi # test -n "$CONFIG_FILES"
15591
15592 # Set up the scripts for CONFIG_HEADERS section.
15593 # No need to generate them if there are no CONFIG_HEADERS.
15594 # This happens for instance with `./config.status Makefile'.
15595 if test -n "$CONFIG_HEADERS"; then
15596 cat >"$tmp/defines.awk" <<\_ACAWK ||
15597 BEGIN {
15598 _ACEOF
15599
15600 # Transform confdefs.h into an awk script `defines.awk', embedded as
15601 # here-document in config.status, that substitutes the proper values into
15602 # config.h.in to produce config.h.
15603
15604 # Create a delimiter string that does not exist in confdefs.h, to ease
15605 # handling of long lines.
15606 ac_delim='%!_!# '
15607 for ac_last_try in false false :; do
15608   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
15609   if test -z "$ac_t"; then
15610     break
15611   elif $ac_last_try; then
15612     as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
15613   else
15614     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15615   fi
15616 done
15617
15618 # For the awk script, D is an array of macro values keyed by name,
15619 # likewise P contains macro parameters if any.  Preserve backslash
15620 # newline sequences.
15621
15622 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
15623 sed -n '
15624 s/.\{148\}/&'"$ac_delim"'/g
15625 t rset
15626 :rset
15627 s/^[     ]*#[    ]*define[       ][      ]*/ /
15628 t def
15629 d
15630 :def
15631 s/\\$//
15632 t bsnl
15633 s/["\\]/\\&/g
15634 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
15635 D["\1"]=" \3"/p
15636 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
15637 d
15638 :bsnl
15639 s/["\\]/\\&/g
15640 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
15641 D["\1"]=" \3\\\\\\n"\\/p
15642 t cont
15643 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
15644 t cont
15645 d
15646 :cont
15647 n
15648 s/.\{148\}/&'"$ac_delim"'/g
15649 t clear
15650 :clear
15651 s/\\$//
15652 t bsnlc
15653 s/["\\]/\\&/g; s/^/"/; s/$/"/p
15654 d
15655 :bsnlc
15656 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
15657 b cont
15658 ' <confdefs.h | sed '
15659 s/'"$ac_delim"'/"\\\
15660 "/g' >>$CONFIG_STATUS || ac_write_fail=1
15661
15662 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15663   for (key in D) D_is_set[key] = 1
15664   FS = "\a"
15665 }
15666 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
15667   line = \$ 0
15668   split(line, arg, " ")
15669   if (arg[1] == "#") {
15670     defundef = arg[2]
15671     mac1 = arg[3]
15672   } else {
15673     defundef = substr(arg[1], 2)
15674     mac1 = arg[2]
15675   }
15676   split(mac1, mac2, "(") #)
15677   macro = mac2[1]
15678   prefix = substr(line, 1, index(line, defundef) - 1)
15679   if (D_is_set[macro]) {
15680     # Preserve the white space surrounding the "#".
15681     print prefix "define", macro P[macro] D[macro]
15682     next
15683   } else {
15684     # Replace #undef with comments.  This is necessary, for example,
15685     # in the case of _POSIX_SOURCE, which is predefined and required
15686     # on some systems where configure will not decide to define it.
15687     if (defundef == "undef") {
15688       print "/*", prefix defundef, macro, "*/"
15689       next
15690     }
15691   }
15692 }
15693 { print }
15694 _ACAWK
15695 _ACEOF
15696 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15697   as_fn_error "could not setup config headers machinery" "$LINENO" 5
15698 fi # test -n "$CONFIG_HEADERS"
15699
15700
15701 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
15702 shift
15703 for ac_tag
15704 do
15705   case $ac_tag in
15706   :[FHLC]) ac_mode=$ac_tag; continue;;
15707   esac
15708   case $ac_mode$ac_tag in
15709   :[FHL]*:*);;
15710   :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
15711   :[FH]-) ac_tag=-:-;;
15712   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
15713   esac
15714   ac_save_IFS=$IFS
15715   IFS=:
15716   set x $ac_tag
15717   IFS=$ac_save_IFS
15718   shift
15719   ac_file=$1
15720   shift
15721
15722   case $ac_mode in
15723   :L) ac_source=$1;;
15724   :[FH])
15725     ac_file_inputs=
15726     for ac_f
15727     do
15728       case $ac_f in
15729       -) ac_f="$tmp/stdin";;
15730       *) # Look for the file first in the build tree, then in the source tree
15731          # (if the path is not absolute).  The absolute path cannot be DOS-style,
15732          # because $ac_f cannot contain `:'.
15733          test -f "$ac_f" ||
15734            case $ac_f in
15735            [\\/$]*) false;;
15736            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
15737            esac ||
15738            as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
15739       esac
15740       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
15741       as_fn_append ac_file_inputs " '$ac_f'"
15742     done
15743
15744     # Let's still pretend it is `configure' which instantiates (i.e., don't
15745     # use $as_me), people would be surprised to read:
15746     #    /* config.h.  Generated by config.status.  */
15747     configure_input='Generated from '`
15748           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
15749         `' by configure.'
15750     if test x"$ac_file" != x-; then
15751       configure_input="$ac_file.  $configure_input"
15752       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
15753 $as_echo "$as_me: creating $ac_file" >&6;}
15754     fi
15755     # Neutralize special characters interpreted by sed in replacement strings.
15756     case $configure_input in #(
15757     *\&* | *\|* | *\\* )
15758        ac_sed_conf_input=`$as_echo "$configure_input" |
15759        sed 's/[\\\\&|]/\\\\&/g'`;; #(
15760     *) ac_sed_conf_input=$configure_input;;
15761     esac
15762
15763     case $ac_tag in
15764     *:-:* | *:-) cat >"$tmp/stdin" \
15765       || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
15766     esac
15767     ;;
15768   esac
15769
15770   ac_dir=`$as_dirname -- "$ac_file" ||
15771 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15772          X"$ac_file" : 'X\(//\)[^/]' \| \
15773          X"$ac_file" : 'X\(//\)$' \| \
15774          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
15775 $as_echo X"$ac_file" |
15776     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15777             s//\1/
15778             q
15779           }
15780           /^X\(\/\/\)[^/].*/{
15781             s//\1/
15782             q
15783           }
15784           /^X\(\/\/\)$/{
15785             s//\1/
15786             q
15787           }
15788           /^X\(\/\).*/{
15789             s//\1/
15790             q
15791           }
15792           s/.*/./; q'`
15793   as_dir="$ac_dir"; as_fn_mkdir_p
15794   ac_builddir=.
15795
15796 case "$ac_dir" in
15797 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15798 *)
15799   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15800   # A ".." for each directory in $ac_dir_suffix.
15801   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15802   case $ac_top_builddir_sub in
15803   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15804   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15805   esac ;;
15806 esac
15807 ac_abs_top_builddir=$ac_pwd
15808 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15809 # for backward compatibility:
15810 ac_top_builddir=$ac_top_build_prefix
15811
15812 case $srcdir in
15813   .)  # We are building in place.
15814     ac_srcdir=.
15815     ac_top_srcdir=$ac_top_builddir_sub
15816     ac_abs_top_srcdir=$ac_pwd ;;
15817   [\\/]* | ?:[\\/]* )  # Absolute name.
15818     ac_srcdir=$srcdir$ac_dir_suffix;
15819     ac_top_srcdir=$srcdir
15820     ac_abs_top_srcdir=$srcdir ;;
15821   *) # Relative name.
15822     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15823     ac_top_srcdir=$ac_top_build_prefix$srcdir
15824     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15825 esac
15826 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15827
15828
15829   case $ac_mode in
15830   :F)
15831   #
15832   # CONFIG_FILE
15833   #
15834
15835   case $INSTALL in
15836   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15837   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
15838   esac
15839 _ACEOF
15840
15841 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15842 # If the template does not know about datarootdir, expand it.
15843 # FIXME: This hack should be removed a few years after 2.60.
15844 ac_datarootdir_hack=; ac_datarootdir_seen=
15845 ac_sed_dataroot='
15846 /datarootdir/ {
15847   p
15848   q
15849 }
15850 /@datadir@/p
15851 /@docdir@/p
15852 /@infodir@/p
15853 /@localedir@/p
15854 /@mandir@/p'
15855 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
15856 *datarootdir*) ac_datarootdir_seen=yes;;
15857 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
15858   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
15859 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
15860 _ACEOF
15861 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15862   ac_datarootdir_hack='
15863   s&@datadir@&$datadir&g
15864   s&@docdir@&$docdir&g
15865   s&@infodir@&$infodir&g
15866   s&@localedir@&$localedir&g
15867   s&@mandir@&$mandir&g
15868   s&\\\${datarootdir}&$datarootdir&g' ;;
15869 esac
15870 _ACEOF
15871
15872 # Neutralize VPATH when `$srcdir' = `.'.
15873 # Shell code in configure.ac might set extrasub.
15874 # FIXME: do we really want to maintain this feature?
15875 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15876 ac_sed_extra="$ac_vpsub
15877 $extrasub
15878 _ACEOF
15879 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15880 :t
15881 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15882 s|@configure_input@|$ac_sed_conf_input|;t t
15883 s&@top_builddir@&$ac_top_builddir_sub&;t t
15884 s&@top_build_prefix@&$ac_top_build_prefix&;t t
15885 s&@srcdir@&$ac_srcdir&;t t
15886 s&@abs_srcdir@&$ac_abs_srcdir&;t t
15887 s&@top_srcdir@&$ac_top_srcdir&;t t
15888 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
15889 s&@builddir@&$ac_builddir&;t t
15890 s&@abs_builddir@&$ac_abs_builddir&;t t
15891 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
15892 s&@INSTALL@&$ac_INSTALL&;t t
15893 $ac_datarootdir_hack
15894 "
15895 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
15896 if $ac_cs_awk_getline; then
15897   $AWK -f "$tmp/subs.awk"
15898 else
15899   $AWK -f "$tmp/subs.awk" | $SHELL
15900 fi >$tmp/out \
15901   || as_fn_error "could not create $ac_file" "$LINENO" 5
15902
15903 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
15904   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
15905   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
15906   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15907 which seems to be undefined.  Please make sure it is defined." >&5
15908 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15909 which seems to be undefined.  Please make sure it is defined." >&2;}
15910
15911   rm -f "$tmp/stdin"
15912   case $ac_file in
15913   -) cat "$tmp/out" && rm -f "$tmp/out";;
15914   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
15915   esac \
15916   || as_fn_error "could not create $ac_file" "$LINENO" 5
15917  ;;
15918   :H)
15919   #
15920   # CONFIG_HEADER
15921   #
15922   if test x"$ac_file" != x-; then
15923     {
15924       $as_echo "/* $configure_input  */" \
15925       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
15926     } >"$tmp/config.h" \
15927       || as_fn_error "could not create $ac_file" "$LINENO" 5
15928     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
15929       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
15930 $as_echo "$as_me: $ac_file is unchanged" >&6;}
15931     else
15932       rm -f "$ac_file"
15933       mv "$tmp/config.h" "$ac_file" \
15934         || as_fn_error "could not create $ac_file" "$LINENO" 5
15935     fi
15936   else
15937     $as_echo "/* $configure_input  */" \
15938       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
15939       || as_fn_error "could not create -" "$LINENO" 5
15940   fi
15941  ;;
15942   :L)
15943   #
15944   # CONFIG_LINK
15945   #
15946
15947   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
15948     :
15949   else
15950     # Prefer the file from the source tree if names are identical.
15951     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
15952       ac_source=$srcdir/$ac_source
15953     fi
15954
15955     { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
15956 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
15957
15958     if test ! -r "$ac_source"; then
15959       as_fn_error "$ac_source: file not found" "$LINENO" 5
15960     fi
15961     rm -f "$ac_file"
15962
15963     # Try a relative symlink, then a hard link, then a copy.
15964     case $srcdir in
15965     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
15966         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
15967     esac
15968     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
15969       ln "$ac_source" "$ac_file" 2>/dev/null ||
15970       cp -p "$ac_source" "$ac_file" ||
15971       as_fn_error "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
15972   fi
15973  ;;
15974   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
15975 $as_echo "$as_me: executing $ac_file commands" >&6;}
15976  ;;
15977   esac
15978
15979
15980   case $ac_file$ac_mode in
15981     "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
15982     "default":C)
15983 case x$CONFIG_HEADERS in
15984 xconfig.h:config.in)
15985 echo > stamp-h ;;
15986 esac
15987  ;;
15988
15989   esac
15990 done # for ac_tag
15991
15992
15993 as_fn_exit 0
15994 _ACEOF
15995 ac_clean_files=$ac_clean_files_save
15996
15997 test $ac_write_fail = 0 ||
15998   as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
15999
16000
16001 # configure is writing to config.log, and then calls config.status.
16002 # config.status does its own redirection, appending to config.log.
16003 # Unfortunately, on DOS this fails, as config.log is still kept open
16004 # by configure, so config.status won't be able to write to it; its
16005 # output is simply discarded.  So we exec the FD to /dev/null,
16006 # effectively closing config.log, so it can be properly (re)opened and
16007 # appended to by config.status.  When coming back to configure, we
16008 # need to make the FD available again.
16009 if test "$no_create" != yes; then
16010   ac_cs_success=:
16011   ac_config_status_args=
16012   test "$silent" = yes &&
16013     ac_config_status_args="$ac_config_status_args --quiet"
16014   exec 5>/dev/null
16015   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
16016   exec 5>>config.log
16017   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
16018   # would make configure fail if this is the last instruction.
16019   $ac_cs_success || as_fn_exit $?
16020 fi
16021
16022 #
16023 # CONFIG_SUBDIRS section.
16024 #
16025 if test "$no_recursion" != yes; then
16026
16027   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
16028   # so they do not pile up.
16029   ac_sub_configure_args=
16030   ac_prev=
16031   eval "set x $ac_configure_args"
16032   shift
16033   for ac_arg
16034   do
16035     if test -n "$ac_prev"; then
16036       ac_prev=
16037       continue
16038     fi
16039     case $ac_arg in
16040     -cache-file | --cache-file | --cache-fil | --cache-fi \
16041     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
16042       ac_prev=cache_file ;;
16043     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
16044     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
16045     | --c=*)
16046       ;;
16047     --config-cache | -C)
16048       ;;
16049     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
16050       ac_prev=srcdir ;;
16051     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
16052       ;;
16053     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
16054       ac_prev=prefix ;;
16055     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
16056       ;;
16057     --disable-option-checking)
16058       ;;
16059     *)
16060       case $ac_arg in
16061       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
16062       esac
16063       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
16064     esac
16065   done
16066
16067   # Always prepend --prefix to ensure using the same prefix
16068   # in subdir configurations.
16069   ac_arg="--prefix=$prefix"
16070   case $ac_arg in
16071   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
16072   esac
16073   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
16074
16075   # Pass --silent
16076   if test "$silent" = yes; then
16077     ac_sub_configure_args="--silent $ac_sub_configure_args"
16078   fi
16079
16080   # Always prepend --disable-option-checking to silence warnings, since
16081   # different subdirs can have different --enable and --with options.
16082   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
16083
16084   ac_popdir=`pwd`
16085   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
16086
16087     # Do not complain, so a configure script can configure whichever
16088     # parts of a large source tree are present.
16089     test -d "$srcdir/$ac_dir" || continue
16090
16091     ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
16092     $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
16093     $as_echo "$ac_msg" >&6
16094     as_dir="$ac_dir"; as_fn_mkdir_p
16095     ac_builddir=.
16096
16097 case "$ac_dir" in
16098 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
16099 *)
16100   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
16101   # A ".." for each directory in $ac_dir_suffix.
16102   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
16103   case $ac_top_builddir_sub in
16104   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
16105   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
16106   esac ;;
16107 esac
16108 ac_abs_top_builddir=$ac_pwd
16109 ac_abs_builddir=$ac_pwd$ac_dir_suffix
16110 # for backward compatibility:
16111 ac_top_builddir=$ac_top_build_prefix
16112
16113 case $srcdir in
16114   .)  # We are building in place.
16115     ac_srcdir=.
16116     ac_top_srcdir=$ac_top_builddir_sub
16117     ac_abs_top_srcdir=$ac_pwd ;;
16118   [\\/]* | ?:[\\/]* )  # Absolute name.
16119     ac_srcdir=$srcdir$ac_dir_suffix;
16120     ac_top_srcdir=$srcdir
16121     ac_abs_top_srcdir=$srcdir ;;
16122   *) # Relative name.
16123     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
16124     ac_top_srcdir=$ac_top_build_prefix$srcdir
16125     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
16126 esac
16127 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
16128
16129
16130     cd "$ac_dir"
16131
16132     # Check for guested configure; otherwise get Cygnus style configure.
16133     if test -f "$ac_srcdir/configure.gnu"; then
16134       ac_sub_configure=$ac_srcdir/configure.gnu
16135     elif test -f "$ac_srcdir/configure"; then
16136       ac_sub_configure=$ac_srcdir/configure
16137     elif test -f "$ac_srcdir/configure.in"; then
16138       # This should be Cygnus configure.
16139       ac_sub_configure=$ac_aux_dir/configure
16140     else
16141       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
16142 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
16143       ac_sub_configure=
16144     fi
16145
16146     # The recursion is here.
16147     if test -n "$ac_sub_configure"; then
16148       # Make the cache file name correct relative to the subdirectory.
16149       case $cache_file in
16150       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
16151       *) # Relative name.
16152         ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
16153       esac
16154
16155       { $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
16156 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
16157       # The eval makes quoting arguments work.
16158       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
16159            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
16160         as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
16161     fi
16162
16163     cd "$ac_popdir"
16164   done
16165 fi
16166 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
16167   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
16168 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
16169 fi
16170
16171
16172 exit 0