fd6519b3d4975491c98dc1849289fac508a973ee
[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 frags
596 target_subdir
597 CONFIG_UNINSTALL
598 CONFIG_INSTALL
599 CONFIG_CLEAN
600 CONFIG_ALL
601 CONFIG_SRCS
602 CONFIG_DEPS
603 CONFIG_OBS
604 PROFILE_CFLAGS
605 ENABLE_CFLAGS
606 SIM_OBS
607 SIM
608 XMKMF
609 GDBTK_SRC_DIR
610 GDBTK_CFLAGS
611 GDBTKLIBS
612 X_LIBS
613 X_LDFLAGS
614 X_CFLAGS
615 TK_XINCLUDES
616 TK_DEPS
617 TK_LIBRARY
618 TK_INCLUDE
619 TK_STUB_LIB_SPEC
620 TK_STUB_LIB_FLAG
621 TK_STUB_LIB_FILE
622 TK_LIB_SPEC
623 TK_LIB_FLAG
624 TK_LIB_FILE
625 TK_SRC_DIR
626 TK_BIN_DIR
627 TK_VERSION
628 TCL_DEPS
629 TCL_LIBRARY
630 TCL_INCLUDE
631 TCL_STUB_LIB_SPEC
632 TCL_STUB_LIB_FLAG
633 TCL_STUB_LIB_FILE
634 TCL_LIB_SPEC
635 TCL_LIB_FLAG
636 TCL_LIB_FILE
637 TCL_SRC_DIR
638 TCL_BIN_DIR
639 TCL_PATCH_LEVEL
640 TCL_VERSION
641 WIN32LDAPP
642 GUI_CFLAGS_X
643 LIBGUI
644 LTLIBLZMA
645 LIBLZMA
646 HAVE_LIBLZMA
647 WIN32LIBS
648 SER_HARDWIRE
649 WERROR_CFLAGS
650 WARN_CFLAGS
651 SYSTEM_GDBINIT
652 TARGET_SYSTEM_ROOT
653 CONFIG_LDFLAGS
654 RDYNAMIC
655 ALLOCA
656 PYTHON_LIBS
657 PYTHON_CPPFLAGS
658 PYTHON_CFLAGS
659 python_prog_path
660 LTLIBEXPAT
661 LIBEXPAT
662 HAVE_LIBEXPAT
663 JIT_READER_DIR
664 TARGET_PTR
665 READLINE_TEXI_INCFLAG
666 READLINE_CFLAGS
667 READLINE_DEPS
668 READLINE
669 MIG
670 WINDRES
671 DLLTOOL
672 AR
673 YFLAGS
674 YACC
675 RANLIB
676 LN_S
677 INSTALL_DATA
678 INSTALL_SCRIPT
679 INSTALL_PROGRAM
680 AWK
681 REPORT_BUGS_TEXI
682 REPORT_BUGS_TO
683 PKGVERSION
684 TARGET_OBS
685 subdirs
686 GDB_DATADIR
687 DEBUGDIR
688 MAKEINFO_EXTRA_FLAGS
689 MAKEINFOFLAGS
690 MAKEINFO
691 PACKAGE
692 GNULIB_STDINT_H
693 CATOBJEXT
694 GENCAT
695 INSTOBJEXT
696 DATADIRNAME
697 CATALOGS
698 POSUB
699 GMSGFMT
700 XGETTEXT
701 INCINTL
702 LIBINTL_DEP
703 LIBINTL
704 USE_NLS
705 SET_MAKE
706 GMAKE_FALSE
707 GMAKE_TRUE
708 MAKE
709 CCDEPMODE
710 DEPDIR
711 am__leading_dot
712 target_os
713 target_vendor
714 target_cpu
715 target
716 host_os
717 host_vendor
718 host_cpu
719 host
720 build_os
721 build_vendor
722 build_cpu
723 build
724 EGREP
725 GREP
726 CPP
727 OBJEXT
728 EXEEXT
729 ac_ct_CC
730 CPPFLAGS
731 LDFLAGS
732 CFLAGS
733 CC
734 MAINT
735 MAINTAINER_MODE_FALSE
736 MAINTAINER_MODE_TRUE
737 target_alias
738 host_alias
739 build_alias
740 LIBS
741 ECHO_T
742 ECHO_N
743 ECHO_C
744 DEFS
745 mandir
746 localedir
747 libdir
748 psdir
749 pdfdir
750 dvidir
751 htmldir
752 infodir
753 docdir
754 oldincludedir
755 includedir
756 localstatedir
757 sharedstatedir
758 sysconfdir
759 datadir
760 datarootdir
761 libexecdir
762 sbindir
763 bindir
764 program_transform_name
765 prefix
766 exec_prefix
767 PACKAGE_URL
768 PACKAGE_BUGREPORT
769 PACKAGE_STRING
770 PACKAGE_VERSION
771 PACKAGE_TARNAME
772 PACKAGE_NAME
773 PATH_SEPARATOR
774 SHELL'
775 ac_subst_files='host_makefile_frag'
776 ac_user_opts='
777 enable_option_checking
778 enable_maintainer_mode
779 enable_plugins
780 enable_largefile
781 with_separate_debug_dir
782 with_gdb_datadir
783 with_relocated_sources
784 with_auto_load_dir
785 with_auto_load_safe_path
786 enable_targets
787 enable_64_bit_bfd
788 enable_gdbcli
789 enable_gdbmi
790 enable_tui
791 enable_gdbtk
792 with_libunwind_ia64
793 with_curses
794 enable_profiling
795 with_pkgversion
796 with_bugurl
797 with_zlib
798 with_libiconv_prefix
799 with_iconv_bin
800 with_system_readline
801 with_jit_reader_dir
802 with_expat
803 with_gnu_ld
804 enable_rpath
805 with_libexpat_prefix
806 with_python
807 enable_libmcheck
808 with_included_regex
809 with_sysroot
810 with_system_gdbinit
811 enable_werror
812 enable_build_warnings
813 enable_gdb_build_warnings
814 with_lzma
815 with_liblzma_prefix
816 with_tcl
817 with_tk
818 with_x
819 enable_sim
820 enable_multi_ice
821 enable_gdbserver
822 '
823       ac_precious_vars='build_alias
824 host_alias
825 target_alias
826 CC
827 CFLAGS
828 LDFLAGS
829 LIBS
830 CPPFLAGS
831 CPP
832 MAKEINFO
833 MAKEINFOFLAGS
834 YACC
835 YFLAGS
836 XMKMF'
837 ac_subdirs_all='testsuite
838 gdbtk
839 multi-ice
840 gdbserver'
841
842 # Initialize some variables set by options.
843 ac_init_help=
844 ac_init_version=false
845 ac_unrecognized_opts=
846 ac_unrecognized_sep=
847 # The variables have the same names as the options, with
848 # dashes changed to underlines.
849 cache_file=/dev/null
850 exec_prefix=NONE
851 no_create=
852 no_recursion=
853 prefix=NONE
854 program_prefix=NONE
855 program_suffix=NONE
856 program_transform_name=s,x,x,
857 silent=
858 site=
859 srcdir=
860 verbose=
861 x_includes=NONE
862 x_libraries=NONE
863
864 # Installation directory options.
865 # These are left unexpanded so users can "make install exec_prefix=/foo"
866 # and all the variables that are supposed to be based on exec_prefix
867 # by default will actually change.
868 # Use braces instead of parens because sh, perl, etc. also accept them.
869 # (The list follows the same order as the GNU Coding Standards.)
870 bindir='${exec_prefix}/bin'
871 sbindir='${exec_prefix}/sbin'
872 libexecdir='${exec_prefix}/libexec'
873 datarootdir='${prefix}/share'
874 datadir='${datarootdir}'
875 sysconfdir='${prefix}/etc'
876 sharedstatedir='${prefix}/com'
877 localstatedir='${prefix}/var'
878 includedir='${prefix}/include'
879 oldincludedir='/usr/include'
880 docdir='${datarootdir}/doc/${PACKAGE}'
881 infodir='${datarootdir}/info'
882 htmldir='${docdir}'
883 dvidir='${docdir}'
884 pdfdir='${docdir}'
885 psdir='${docdir}'
886 libdir='${exec_prefix}/lib'
887 localedir='${datarootdir}/locale'
888 mandir='${datarootdir}/man'
889
890 ac_prev=
891 ac_dashdash=
892 for ac_option
893 do
894   # If the previous option needs an argument, assign it.
895   if test -n "$ac_prev"; then
896     eval $ac_prev=\$ac_option
897     ac_prev=
898     continue
899   fi
900
901   case $ac_option in
902   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
903   *)    ac_optarg=yes ;;
904   esac
905
906   # Accept the important Cygnus configure options, so we can diagnose typos.
907
908   case $ac_dashdash$ac_option in
909   --)
910     ac_dashdash=yes ;;
911
912   -bindir | --bindir | --bindi | --bind | --bin | --bi)
913     ac_prev=bindir ;;
914   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
915     bindir=$ac_optarg ;;
916
917   -build | --build | --buil | --bui | --bu)
918     ac_prev=build_alias ;;
919   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
920     build_alias=$ac_optarg ;;
921
922   -cache-file | --cache-file | --cache-fil | --cache-fi \
923   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
924     ac_prev=cache_file ;;
925   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
926   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
927     cache_file=$ac_optarg ;;
928
929   --config-cache | -C)
930     cache_file=config.cache ;;
931
932   -datadir | --datadir | --datadi | --datad)
933     ac_prev=datadir ;;
934   -datadir=* | --datadir=* | --datadi=* | --datad=*)
935     datadir=$ac_optarg ;;
936
937   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
938   | --dataroo | --dataro | --datar)
939     ac_prev=datarootdir ;;
940   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
941   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
942     datarootdir=$ac_optarg ;;
943
944   -disable-* | --disable-*)
945     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
946     # Reject names that are not valid shell variable names.
947     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
948       as_fn_error "invalid feature name: $ac_useropt"
949     ac_useropt_orig=$ac_useropt
950     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
951     case $ac_user_opts in
952       *"
953 "enable_$ac_useropt"
954 "*) ;;
955       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
956          ac_unrecognized_sep=', ';;
957     esac
958     eval enable_$ac_useropt=no ;;
959
960   -docdir | --docdir | --docdi | --doc | --do)
961     ac_prev=docdir ;;
962   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
963     docdir=$ac_optarg ;;
964
965   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
966     ac_prev=dvidir ;;
967   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
968     dvidir=$ac_optarg ;;
969
970   -enable-* | --enable-*)
971     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
972     # Reject names that are not valid shell variable names.
973     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
974       as_fn_error "invalid feature name: $ac_useropt"
975     ac_useropt_orig=$ac_useropt
976     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
977     case $ac_user_opts in
978       *"
979 "enable_$ac_useropt"
980 "*) ;;
981       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
982          ac_unrecognized_sep=', ';;
983     esac
984     eval enable_$ac_useropt=\$ac_optarg ;;
985
986   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
987   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
988   | --exec | --exe | --ex)
989     ac_prev=exec_prefix ;;
990   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
991   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
992   | --exec=* | --exe=* | --ex=*)
993     exec_prefix=$ac_optarg ;;
994
995   -gas | --gas | --ga | --g)
996     # Obsolete; use --with-gas.
997     with_gas=yes ;;
998
999   -help | --help | --hel | --he | -h)
1000     ac_init_help=long ;;
1001   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1002     ac_init_help=recursive ;;
1003   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1004     ac_init_help=short ;;
1005
1006   -host | --host | --hos | --ho)
1007     ac_prev=host_alias ;;
1008   -host=* | --host=* | --hos=* | --ho=*)
1009     host_alias=$ac_optarg ;;
1010
1011   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1012     ac_prev=htmldir ;;
1013   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1014   | --ht=*)
1015     htmldir=$ac_optarg ;;
1016
1017   -includedir | --includedir | --includedi | --included | --include \
1018   | --includ | --inclu | --incl | --inc)
1019     ac_prev=includedir ;;
1020   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1021   | --includ=* | --inclu=* | --incl=* | --inc=*)
1022     includedir=$ac_optarg ;;
1023
1024   -infodir | --infodir | --infodi | --infod | --info | --inf)
1025     ac_prev=infodir ;;
1026   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1027     infodir=$ac_optarg ;;
1028
1029   -libdir | --libdir | --libdi | --libd)
1030     ac_prev=libdir ;;
1031   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1032     libdir=$ac_optarg ;;
1033
1034   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1035   | --libexe | --libex | --libe)
1036     ac_prev=libexecdir ;;
1037   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1038   | --libexe=* | --libex=* | --libe=*)
1039     libexecdir=$ac_optarg ;;
1040
1041   -localedir | --localedir | --localedi | --localed | --locale)
1042     ac_prev=localedir ;;
1043   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1044     localedir=$ac_optarg ;;
1045
1046   -localstatedir | --localstatedir | --localstatedi | --localstated \
1047   | --localstate | --localstat | --localsta | --localst | --locals)
1048     ac_prev=localstatedir ;;
1049   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1050   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1051     localstatedir=$ac_optarg ;;
1052
1053   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1054     ac_prev=mandir ;;
1055   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1056     mandir=$ac_optarg ;;
1057
1058   -nfp | --nfp | --nf)
1059     # Obsolete; use --without-fp.
1060     with_fp=no ;;
1061
1062   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1063   | --no-cr | --no-c | -n)
1064     no_create=yes ;;
1065
1066   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1067   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1068     no_recursion=yes ;;
1069
1070   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1071   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1072   | --oldin | --oldi | --old | --ol | --o)
1073     ac_prev=oldincludedir ;;
1074   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1075   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1076   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1077     oldincludedir=$ac_optarg ;;
1078
1079   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1080     ac_prev=prefix ;;
1081   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1082     prefix=$ac_optarg ;;
1083
1084   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1085   | --program-pre | --program-pr | --program-p)
1086     ac_prev=program_prefix ;;
1087   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1088   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1089     program_prefix=$ac_optarg ;;
1090
1091   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1092   | --program-suf | --program-su | --program-s)
1093     ac_prev=program_suffix ;;
1094   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1095   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1096     program_suffix=$ac_optarg ;;
1097
1098   -program-transform-name | --program-transform-name \
1099   | --program-transform-nam | --program-transform-na \
1100   | --program-transform-n | --program-transform- \
1101   | --program-transform | --program-transfor \
1102   | --program-transfo | --program-transf \
1103   | --program-trans | --program-tran \
1104   | --progr-tra | --program-tr | --program-t)
1105     ac_prev=program_transform_name ;;
1106   -program-transform-name=* | --program-transform-name=* \
1107   | --program-transform-nam=* | --program-transform-na=* \
1108   | --program-transform-n=* | --program-transform-=* \
1109   | --program-transform=* | --program-transfor=* \
1110   | --program-transfo=* | --program-transf=* \
1111   | --program-trans=* | --program-tran=* \
1112   | --progr-tra=* | --program-tr=* | --program-t=*)
1113     program_transform_name=$ac_optarg ;;
1114
1115   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1116     ac_prev=pdfdir ;;
1117   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1118     pdfdir=$ac_optarg ;;
1119
1120   -psdir | --psdir | --psdi | --psd | --ps)
1121     ac_prev=psdir ;;
1122   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1123     psdir=$ac_optarg ;;
1124
1125   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1126   | -silent | --silent | --silen | --sile | --sil)
1127     silent=yes ;;
1128
1129   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1130     ac_prev=sbindir ;;
1131   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1132   | --sbi=* | --sb=*)
1133     sbindir=$ac_optarg ;;
1134
1135   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1136   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1137   | --sharedst | --shareds | --shared | --share | --shar \
1138   | --sha | --sh)
1139     ac_prev=sharedstatedir ;;
1140   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1141   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1142   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1143   | --sha=* | --sh=*)
1144     sharedstatedir=$ac_optarg ;;
1145
1146   -site | --site | --sit)
1147     ac_prev=site ;;
1148   -site=* | --site=* | --sit=*)
1149     site=$ac_optarg ;;
1150
1151   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1152     ac_prev=srcdir ;;
1153   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1154     srcdir=$ac_optarg ;;
1155
1156   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1157   | --syscon | --sysco | --sysc | --sys | --sy)
1158     ac_prev=sysconfdir ;;
1159   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1160   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1161     sysconfdir=$ac_optarg ;;
1162
1163   -target | --target | --targe | --targ | --tar | --ta | --t)
1164     ac_prev=target_alias ;;
1165   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1166     target_alias=$ac_optarg ;;
1167
1168   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1169     verbose=yes ;;
1170
1171   -version | --version | --versio | --versi | --vers | -V)
1172     ac_init_version=: ;;
1173
1174   -with-* | --with-*)
1175     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1176     # Reject names that are not valid shell variable names.
1177     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1178       as_fn_error "invalid package name: $ac_useropt"
1179     ac_useropt_orig=$ac_useropt
1180     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1181     case $ac_user_opts in
1182       *"
1183 "with_$ac_useropt"
1184 "*) ;;
1185       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1186          ac_unrecognized_sep=', ';;
1187     esac
1188     eval with_$ac_useropt=\$ac_optarg ;;
1189
1190   -without-* | --without-*)
1191     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1192     # Reject names that are not valid shell variable names.
1193     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1194       as_fn_error "invalid package name: $ac_useropt"
1195     ac_useropt_orig=$ac_useropt
1196     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1197     case $ac_user_opts in
1198       *"
1199 "with_$ac_useropt"
1200 "*) ;;
1201       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1202          ac_unrecognized_sep=', ';;
1203     esac
1204     eval with_$ac_useropt=no ;;
1205
1206   --x)
1207     # Obsolete; use --with-x.
1208     with_x=yes ;;
1209
1210   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1211   | --x-incl | --x-inc | --x-in | --x-i)
1212     ac_prev=x_includes ;;
1213   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1214   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1215     x_includes=$ac_optarg ;;
1216
1217   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1218   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1219     ac_prev=x_libraries ;;
1220   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1221   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1222     x_libraries=$ac_optarg ;;
1223
1224   -*) as_fn_error "unrecognized option: \`$ac_option'
1225 Try \`$0 --help' for more information."
1226     ;;
1227
1228   *=*)
1229     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1230     # Reject names that are not valid shell variable names.
1231     case $ac_envvar in #(
1232       '' | [0-9]* | *[!_$as_cr_alnum]* )
1233       as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1234     esac
1235     eval $ac_envvar=\$ac_optarg
1236     export $ac_envvar ;;
1237
1238   *)
1239     # FIXME: should be removed in autoconf 3.0.
1240     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1241     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1242       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1243     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1244     ;;
1245
1246   esac
1247 done
1248
1249 if test -n "$ac_prev"; then
1250   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1251   as_fn_error "missing argument to $ac_option"
1252 fi
1253
1254 if test -n "$ac_unrecognized_opts"; then
1255   case $enable_option_checking in
1256     no) ;;
1257     fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1258     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1259   esac
1260 fi
1261
1262 # Check all directory arguments for consistency.
1263 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1264                 datadir sysconfdir sharedstatedir localstatedir includedir \
1265                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1266                 libdir localedir mandir
1267 do
1268   eval ac_val=\$$ac_var
1269   # Remove trailing slashes.
1270   case $ac_val in
1271     */ )
1272       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1273       eval $ac_var=\$ac_val;;
1274   esac
1275   # Be sure to have absolute directory names.
1276   case $ac_val in
1277     [\\/$]* | ?:[\\/]* )  continue;;
1278     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1279   esac
1280   as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1281 done
1282
1283 # There might be people who depend on the old broken behavior: `$host'
1284 # used to hold the argument of --host etc.
1285 # FIXME: To remove some day.
1286 build=$build_alias
1287 host=$host_alias
1288 target=$target_alias
1289
1290 # FIXME: To remove some day.
1291 if test "x$host_alias" != x; then
1292   if test "x$build_alias" = x; then
1293     cross_compiling=maybe
1294     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1295     If a cross compiler is detected then cross compile mode will be used." >&2
1296   elif test "x$build_alias" != "x$host_alias"; then
1297     cross_compiling=yes
1298   fi
1299 fi
1300
1301 ac_tool_prefix=
1302 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1303
1304 test "$silent" = yes && exec 6>/dev/null
1305
1306
1307 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1308 ac_ls_di=`ls -di .` &&
1309 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1310   as_fn_error "working directory cannot be determined"
1311 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1312   as_fn_error "pwd does not report name of working directory"
1313
1314
1315 # Find the source files, if location was not specified.
1316 if test -z "$srcdir"; then
1317   ac_srcdir_defaulted=yes
1318   # Try the directory containing this script, then the parent directory.
1319   ac_confdir=`$as_dirname -- "$as_myself" ||
1320 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1321          X"$as_myself" : 'X\(//\)[^/]' \| \
1322          X"$as_myself" : 'X\(//\)$' \| \
1323          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1324 $as_echo X"$as_myself" |
1325     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1326             s//\1/
1327             q
1328           }
1329           /^X\(\/\/\)[^/].*/{
1330             s//\1/
1331             q
1332           }
1333           /^X\(\/\/\)$/{
1334             s//\1/
1335             q
1336           }
1337           /^X\(\/\).*/{
1338             s//\1/
1339             q
1340           }
1341           s/.*/./; q'`
1342   srcdir=$ac_confdir
1343   if test ! -r "$srcdir/$ac_unique_file"; then
1344     srcdir=..
1345   fi
1346 else
1347   ac_srcdir_defaulted=no
1348 fi
1349 if test ! -r "$srcdir/$ac_unique_file"; then
1350   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1351   as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1352 fi
1353 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1354 ac_abs_confdir=`(
1355         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1356         pwd)`
1357 # When building in place, set srcdir=.
1358 if test "$ac_abs_confdir" = "$ac_pwd"; then
1359   srcdir=.
1360 fi
1361 # Remove unnecessary trailing slashes from srcdir.
1362 # Double slashes in file names in object file debugging info
1363 # mess up M-x gdb in Emacs.
1364 case $srcdir in
1365 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1366 esac
1367 for ac_var in $ac_precious_vars; do
1368   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1369   eval ac_env_${ac_var}_value=\$${ac_var}
1370   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1371   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1372 done
1373
1374 #
1375 # Report the --help message.
1376 #
1377 if test "$ac_init_help" = "long"; then
1378   # Omit some internal or obsolete options to make the list less imposing.
1379   # This message is too long to be a string in the A/UX 3.1 sh.
1380   cat <<_ACEOF
1381 \`configure' configures this package to adapt to many kinds of systems.
1382
1383 Usage: $0 [OPTION]... [VAR=VALUE]...
1384
1385 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1386 VAR=VALUE.  See below for descriptions of some of the useful variables.
1387
1388 Defaults for the options are specified in brackets.
1389
1390 Configuration:
1391   -h, --help              display this help and exit
1392       --help=short        display options specific to this package
1393       --help=recursive    display the short help of all the included packages
1394   -V, --version           display version information and exit
1395   -q, --quiet, --silent   do not print \`checking...' messages
1396       --cache-file=FILE   cache test results in FILE [disabled]
1397   -C, --config-cache      alias for \`--cache-file=config.cache'
1398   -n, --no-create         do not create output files
1399       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1400
1401 Installation directories:
1402   --prefix=PREFIX         install architecture-independent files in PREFIX
1403                           [$ac_default_prefix]
1404   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1405                           [PREFIX]
1406
1407 By default, \`make install' will install all the files in
1408 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1409 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1410 for instance \`--prefix=\$HOME'.
1411
1412 For better control, use the options below.
1413
1414 Fine tuning of the installation directories:
1415   --bindir=DIR            user executables [EPREFIX/bin]
1416   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1417   --libexecdir=DIR        program executables [EPREFIX/libexec]
1418   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1419   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1420   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1421   --libdir=DIR            object code libraries [EPREFIX/lib]
1422   --includedir=DIR        C header files [PREFIX/include]
1423   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1424   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1425   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1426   --infodir=DIR           info documentation [DATAROOTDIR/info]
1427   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1428   --mandir=DIR            man documentation [DATAROOTDIR/man]
1429   --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
1430   --htmldir=DIR           html documentation [DOCDIR]
1431   --dvidir=DIR            dvi documentation [DOCDIR]
1432   --pdfdir=DIR            pdf documentation [DOCDIR]
1433   --psdir=DIR             ps documentation [DOCDIR]
1434 _ACEOF
1435
1436   cat <<\_ACEOF
1437
1438 Program names:
1439   --program-prefix=PREFIX            prepend PREFIX to installed program names
1440   --program-suffix=SUFFIX            append SUFFIX to installed program names
1441   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1442
1443 X features:
1444   --x-includes=DIR    X include files are in DIR
1445   --x-libraries=DIR   X library files are in DIR
1446
1447 System types:
1448   --build=BUILD     configure for building on BUILD [guessed]
1449   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1450   --target=TARGET   configure for building compilers for TARGET [HOST]
1451 _ACEOF
1452 fi
1453
1454 if test -n "$ac_init_help"; then
1455
1456   cat <<\_ACEOF
1457
1458 Optional Features:
1459   --disable-option-checking  ignore unrecognized --enable/--with options
1460   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1461   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1462   --enable-maintainer-mode  enable make rules and dependencies not useful
1463                           (and sometimes confusing) to the casual installer
1464   --enable-plugins        Enable support for plugins (defaults no)
1465   --disable-largefile     omit support for large files
1466   --enable-targets=TARGETS
1467                           alternative target configurations
1468   --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
1469   --disable-gdbcli        disable command-line interface (CLI)
1470   --disable-gdbmi         disable machine-interface (MI)
1471   --enable-tui            enable full-screen terminal user interface (TUI)
1472   --enable-gdbtk          enable gdbtk graphical user interface (GUI)
1473   --enable-profiling      enable profiling of GDB
1474   --disable-rpath         do not hardcode runtime library paths
1475   --enable-libmcheck      Try building GDB with -lmcheck if available
1476   --enable-werror         treat compile warnings as errors
1477   --enable-build-warnings enable build-time compiler warnings if gcc is used
1478   --enable-gdb-build-warnings
1479                           enable GDB specific build-time compiler warnings if
1480                           gcc is used
1481   --enable-sim            link gdb with simulator
1482   --enable-multi-ice      build the multi-ice-gdb-server
1483   --enable-gdbserver      automatically build gdbserver (yes/no/auto, default
1484                           is auto)
1485
1486 Optional Packages:
1487   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1488   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1489   --with-separate-debug-dir=PATH
1490                           look for global separate debug info in this path
1491                           [LIBDIR/debug]
1492   --with-gdb-datadir=PATH look for global separate data files in this path
1493                           [DATADIR/gdb]
1494   --with-relocated-sources=PATH
1495                           automatically relocate this path for source files
1496   --with-auto-load-dir=PATH
1497                           directories from which to load auto-loaded scripts
1498                           [$debugdir:$datadir/auto-load]
1499   --with-auto-load-safe-path=PATH
1500                           directories safe to hold auto-loaded files
1501                           [--with-auto-load-dir]
1502   --without-auto-load-safe-path
1503                           do not restrict auto-loaded files locations
1504   --with-libunwind-ia64   use libunwind frame unwinding for ia64 targets
1505   --with-curses           use the curses library instead of the termcap
1506                           library
1507   --with-pkgversion=PKG   Use PKG in the version string in place of "GDB"
1508   --with-bugurl=URL       Direct users to URL to report a bug
1509   --with-zlib             include zlib support (auto/yes/no) default=auto
1510   --with-libiconv-prefix=DIR
1511                           search for libiconv in DIR/include and DIR/lib
1512   --with-iconv-bin=PATH   specify where to find the iconv program
1513   --with-system-readline  use installed readline library
1514   --with-jit-reader-dir=PATH
1515                           directory to load the JIT readers from
1516   --with-expat            include expat support (auto/yes/no)
1517   --with-gnu-ld           assume the C compiler uses GNU ld default=no
1518   --with-libexpat-prefix[=DIR]  search for libexpat in DIR/include and DIR/lib
1519   --without-libexpat-prefix     don't search for libexpat in includedir and libdir
1520   --with-python[=PYTHON]  include python support
1521                           (auto/yes/no/<python-program>)
1522   --without-included-regex
1523                           don't use included regex; this is the default on
1524                           systems with version 2 of the GNU C library (use
1525                           with caution on other system)
1526   --with-sysroot[=DIR]    search for usr/lib et al within DIR
1527   --with-system-gdbinit=PATH
1528                           automatically load a system-wide gdbinit file
1529   --with-lzma             support lzma compression (auto/yes/no)
1530   --with-liblzma-prefix[=DIR]  search for liblzma in DIR/include and DIR/lib
1531   --without-liblzma-prefix     don't search for liblzma in includedir and libdir
1532   --with-tcl              directory containing tcl configuration (tclConfig.sh)
1533   --with-tk               directory containing tk configuration (tkConfig.sh)
1534   --with-x                use the X Window System
1535
1536 Some influential environment variables:
1537   CC          C compiler command
1538   CFLAGS      C compiler flags
1539   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1540               nonstandard directory <lib dir>
1541   LIBS        libraries to pass to the linker, e.g. -l<library>
1542   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1543               you have headers in a nonstandard directory <include dir>
1544   CPP         C preprocessor
1545   MAKEINFO    Parent configure detects if it is of sufficient version.
1546   MAKEINFOFLAGS
1547               Parameters for MAKEINFO.
1548   YACC        The `Yet Another C Compiler' implementation to use. Defaults to
1549               the first program found out of: `bison -y', `byacc', `yacc'.
1550   YFLAGS      The list of arguments that will be passed by default to $YACC.
1551               This script will default YFLAGS to the empty string to avoid a
1552               default value of `-d' given by some make applications.
1553   XMKMF       Path to xmkmf, Makefile generator for X Window System
1554
1555 Use these variables to override the choices made by `configure' or to help
1556 it to find libraries and programs with nonstandard names/locations.
1557
1558 Report bugs to the package provider.
1559 _ACEOF
1560 ac_status=$?
1561 fi
1562
1563 if test "$ac_init_help" = "recursive"; then
1564   # If there are subdirs, report their specific --help.
1565   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1566     test -d "$ac_dir" ||
1567       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1568       continue
1569     ac_builddir=.
1570
1571 case "$ac_dir" in
1572 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1573 *)
1574   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1575   # A ".." for each directory in $ac_dir_suffix.
1576   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1577   case $ac_top_builddir_sub in
1578   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1579   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1580   esac ;;
1581 esac
1582 ac_abs_top_builddir=$ac_pwd
1583 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1584 # for backward compatibility:
1585 ac_top_builddir=$ac_top_build_prefix
1586
1587 case $srcdir in
1588   .)  # We are building in place.
1589     ac_srcdir=.
1590     ac_top_srcdir=$ac_top_builddir_sub
1591     ac_abs_top_srcdir=$ac_pwd ;;
1592   [\\/]* | ?:[\\/]* )  # Absolute name.
1593     ac_srcdir=$srcdir$ac_dir_suffix;
1594     ac_top_srcdir=$srcdir
1595     ac_abs_top_srcdir=$srcdir ;;
1596   *) # Relative name.
1597     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1598     ac_top_srcdir=$ac_top_build_prefix$srcdir
1599     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1600 esac
1601 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1602
1603     cd "$ac_dir" || { ac_status=$?; continue; }
1604     # Check for guested configure.
1605     if test -f "$ac_srcdir/configure.gnu"; then
1606       echo &&
1607       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1608     elif test -f "$ac_srcdir/configure"; then
1609       echo &&
1610       $SHELL "$ac_srcdir/configure" --help=recursive
1611     else
1612       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1613     fi || ac_status=$?
1614     cd "$ac_pwd" || { ac_status=$?; break; }
1615   done
1616 fi
1617
1618 test -n "$ac_init_help" && exit $ac_status
1619 if $ac_init_version; then
1620   cat <<\_ACEOF
1621 configure
1622 generated by GNU Autoconf 2.64
1623
1624 Copyright (C) 2009 Free Software Foundation, Inc.
1625 This configure script is free software; the Free Software Foundation
1626 gives unlimited permission to copy, distribute and modify it.
1627 _ACEOF
1628   exit
1629 fi
1630
1631 ## ------------------------ ##
1632 ## Autoconf initialization. ##
1633 ## ------------------------ ##
1634
1635 # ac_fn_c_try_compile LINENO
1636 # --------------------------
1637 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1638 ac_fn_c_try_compile ()
1639 {
1640   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1641   rm -f conftest.$ac_objext
1642   if { { ac_try="$ac_compile"
1643 case "(($ac_try" in
1644   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1645   *) ac_try_echo=$ac_try;;
1646 esac
1647 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1648 $as_echo "$ac_try_echo"; } >&5
1649   (eval "$ac_compile") 2>conftest.err
1650   ac_status=$?
1651   if test -s conftest.err; then
1652     grep -v '^ *+' conftest.err >conftest.er1
1653     cat conftest.er1 >&5
1654     mv -f conftest.er1 conftest.err
1655   fi
1656   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1657   test $ac_status = 0; } && {
1658          test -z "$ac_c_werror_flag" ||
1659          test ! -s conftest.err
1660        } && test -s conftest.$ac_objext; then :
1661   ac_retval=0
1662 else
1663   $as_echo "$as_me: failed program was:" >&5
1664 sed 's/^/| /' conftest.$ac_ext >&5
1665
1666         ac_retval=1
1667 fi
1668   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1669   return $ac_retval
1670
1671 } # ac_fn_c_try_compile
1672
1673 # ac_fn_c_try_cpp LINENO
1674 # ----------------------
1675 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1676 ac_fn_c_try_cpp ()
1677 {
1678   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1679   if { { ac_try="$ac_cpp conftest.$ac_ext"
1680 case "(($ac_try" in
1681   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1682   *) ac_try_echo=$ac_try;;
1683 esac
1684 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1685 $as_echo "$ac_try_echo"; } >&5
1686   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1687   ac_status=$?
1688   if test -s conftest.err; then
1689     grep -v '^ *+' conftest.err >conftest.er1
1690     cat conftest.er1 >&5
1691     mv -f conftest.er1 conftest.err
1692   fi
1693   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1694   test $ac_status = 0; } >/dev/null && {
1695          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1696          test ! -s conftest.err
1697        }; then :
1698   ac_retval=0
1699 else
1700   $as_echo "$as_me: failed program was:" >&5
1701 sed 's/^/| /' conftest.$ac_ext >&5
1702
1703     ac_retval=1
1704 fi
1705   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1706   return $ac_retval
1707
1708 } # ac_fn_c_try_cpp
1709
1710 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1711 # -------------------------------------------------------
1712 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1713 # the include files in INCLUDES and setting the cache variable VAR
1714 # accordingly.
1715 ac_fn_c_check_header_mongrel ()
1716 {
1717   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1718   if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1719   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1720 $as_echo_n "checking for $2... " >&6; }
1721 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1722   $as_echo_n "(cached) " >&6
1723 fi
1724 eval ac_res=\$$3
1725                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1726 $as_echo "$ac_res" >&6; }
1727 else
1728   # Is the header compilable?
1729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1730 $as_echo_n "checking $2 usability... " >&6; }
1731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1732 /* end confdefs.h.  */
1733 $4
1734 #include <$2>
1735 _ACEOF
1736 if ac_fn_c_try_compile "$LINENO"; then :
1737   ac_header_compiler=yes
1738 else
1739   ac_header_compiler=no
1740 fi
1741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1743 $as_echo "$ac_header_compiler" >&6; }
1744
1745 # Is the header present?
1746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1747 $as_echo_n "checking $2 presence... " >&6; }
1748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1749 /* end confdefs.h.  */
1750 #include <$2>
1751 _ACEOF
1752 if ac_fn_c_try_cpp "$LINENO"; then :
1753   ac_header_preproc=yes
1754 else
1755   ac_header_preproc=no
1756 fi
1757 rm -f conftest.err conftest.$ac_ext
1758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1759 $as_echo "$ac_header_preproc" >&6; }
1760
1761 # So?  What about this header?
1762 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1763   yes:no: )
1764     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1765 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1766     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1767 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1768     ;;
1769   no:yes:* )
1770     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1771 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1772     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1773 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1774     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1775 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1776     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1777 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1778     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1779 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1780     ;;
1781 esac
1782   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1783 $as_echo_n "checking for $2... " >&6; }
1784 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1785   $as_echo_n "(cached) " >&6
1786 else
1787   eval "$3=\$ac_header_compiler"
1788 fi
1789 eval ac_res=\$$3
1790                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1791 $as_echo "$ac_res" >&6; }
1792 fi
1793   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1794
1795 } # ac_fn_c_check_header_mongrel
1796
1797 # ac_fn_c_try_run LINENO
1798 # ----------------------
1799 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1800 # that executables *can* be run.
1801 ac_fn_c_try_run ()
1802 {
1803   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1804   if { { ac_try="$ac_link"
1805 case "(($ac_try" in
1806   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1807   *) ac_try_echo=$ac_try;;
1808 esac
1809 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1810 $as_echo "$ac_try_echo"; } >&5
1811   (eval "$ac_link") 2>&5
1812   ac_status=$?
1813   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1814   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1815   { { case "(($ac_try" in
1816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1817   *) ac_try_echo=$ac_try;;
1818 esac
1819 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1820 $as_echo "$ac_try_echo"; } >&5
1821   (eval "$ac_try") 2>&5
1822   ac_status=$?
1823   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1824   test $ac_status = 0; }; }; then :
1825   ac_retval=0
1826 else
1827   $as_echo "$as_me: program exited with status $ac_status" >&5
1828        $as_echo "$as_me: failed program was:" >&5
1829 sed 's/^/| /' conftest.$ac_ext >&5
1830
1831        ac_retval=$ac_status
1832 fi
1833   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1834   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1835   return $ac_retval
1836
1837 } # ac_fn_c_try_run
1838
1839 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1840 # -------------------------------------------------------
1841 # Tests whether HEADER exists and can be compiled using the include files in
1842 # INCLUDES, setting the cache variable VAR accordingly.
1843 ac_fn_c_check_header_compile ()
1844 {
1845   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1846   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1847 $as_echo_n "checking for $2... " >&6; }
1848 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1849   $as_echo_n "(cached) " >&6
1850 else
1851   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1852 /* end confdefs.h.  */
1853 $4
1854 #include <$2>
1855 _ACEOF
1856 if ac_fn_c_try_compile "$LINENO"; then :
1857   eval "$3=yes"
1858 else
1859   eval "$3=no"
1860 fi
1861 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1862 fi
1863 eval ac_res=\$$3
1864                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1865 $as_echo "$ac_res" >&6; }
1866   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1867
1868 } # ac_fn_c_check_header_compile
1869
1870 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1871 # --------------------------------------------
1872 # Tries to find the compile-time value of EXPR in a program that includes
1873 # INCLUDES, setting VAR accordingly. Returns whether the value could be
1874 # computed
1875 ac_fn_c_compute_int ()
1876 {
1877   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1878   if test "$cross_compiling" = yes; then
1879     # Depending upon the size, compute the lo and hi bounds.
1880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1881 /* end confdefs.h.  */
1882 $4
1883 int
1884 main ()
1885 {
1886 static int test_array [1 - 2 * !(($2) >= 0)];
1887 test_array [0] = 0
1888
1889   ;
1890   return 0;
1891 }
1892 _ACEOF
1893 if ac_fn_c_try_compile "$LINENO"; then :
1894   ac_lo=0 ac_mid=0
1895   while :; do
1896     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1897 /* end confdefs.h.  */
1898 $4
1899 int
1900 main ()
1901 {
1902 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1903 test_array [0] = 0
1904
1905   ;
1906   return 0;
1907 }
1908 _ACEOF
1909 if ac_fn_c_try_compile "$LINENO"; then :
1910   ac_hi=$ac_mid; break
1911 else
1912   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1913                         if test $ac_lo -le $ac_mid; then
1914                           ac_lo= ac_hi=
1915                           break
1916                         fi
1917                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1918 fi
1919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1920   done
1921 else
1922   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1923 /* end confdefs.h.  */
1924 $4
1925 int
1926 main ()
1927 {
1928 static int test_array [1 - 2 * !(($2) < 0)];
1929 test_array [0] = 0
1930
1931   ;
1932   return 0;
1933 }
1934 _ACEOF
1935 if ac_fn_c_try_compile "$LINENO"; then :
1936   ac_hi=-1 ac_mid=-1
1937   while :; do
1938     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1939 /* end confdefs.h.  */
1940 $4
1941 int
1942 main ()
1943 {
1944 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
1945 test_array [0] = 0
1946
1947   ;
1948   return 0;
1949 }
1950 _ACEOF
1951 if ac_fn_c_try_compile "$LINENO"; then :
1952   ac_lo=$ac_mid; break
1953 else
1954   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1955                         if test $ac_mid -le $ac_hi; then
1956                           ac_lo= ac_hi=
1957                           break
1958                         fi
1959                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1960 fi
1961 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1962   done
1963 else
1964   ac_lo= ac_hi=
1965 fi
1966 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1967 fi
1968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1969 # Binary search between lo and hi bounds.
1970 while test "x$ac_lo" != "x$ac_hi"; do
1971   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1972   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1973 /* end confdefs.h.  */
1974 $4
1975 int
1976 main ()
1977 {
1978 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
1979 test_array [0] = 0
1980
1981   ;
1982   return 0;
1983 }
1984 _ACEOF
1985 if ac_fn_c_try_compile "$LINENO"; then :
1986   ac_hi=$ac_mid
1987 else
1988   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1989 fi
1990 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1991 done
1992 case $ac_lo in #((
1993 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
1994 '') ac_retval=1 ;;
1995 esac
1996   else
1997     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1998 /* end confdefs.h.  */
1999 $4
2000 static long int longval () { return $2; }
2001 static unsigned long int ulongval () { return $2; }
2002 #include <stdio.h>
2003 #include <stdlib.h>
2004 int
2005 main ()
2006 {
2007
2008   FILE *f = fopen ("conftest.val", "w");
2009   if (! f)
2010     return 1;
2011   if (($2) < 0)
2012     {
2013       long int i = longval ();
2014       if (i != ($2))
2015         return 1;
2016       fprintf (f, "%ld", i);
2017     }
2018   else
2019     {
2020       unsigned long int i = ulongval ();
2021       if (i != ($2))
2022         return 1;
2023       fprintf (f, "%lu", i);
2024     }
2025   /* Do not output a trailing newline, as this causes \r\n confusion
2026      on some platforms.  */
2027   return ferror (f) || fclose (f) != 0;
2028
2029   ;
2030   return 0;
2031 }
2032 _ACEOF
2033 if ac_fn_c_try_run "$LINENO"; then :
2034   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2035 else
2036   ac_retval=1
2037 fi
2038 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2039   conftest.$ac_objext conftest.beam conftest.$ac_ext
2040 rm -f conftest.val
2041
2042   fi
2043   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2044   return $ac_retval
2045
2046 } # ac_fn_c_compute_int
2047
2048 # ac_fn_c_try_link LINENO
2049 # -----------------------
2050 # Try to link conftest.$ac_ext, and return whether this succeeded.
2051 ac_fn_c_try_link ()
2052 {
2053   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2054   rm -f conftest.$ac_objext conftest$ac_exeext
2055   if { { ac_try="$ac_link"
2056 case "(($ac_try" in
2057   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2058   *) ac_try_echo=$ac_try;;
2059 esac
2060 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2061 $as_echo "$ac_try_echo"; } >&5
2062   (eval "$ac_link") 2>conftest.err
2063   ac_status=$?
2064   if test -s conftest.err; then
2065     grep -v '^ *+' conftest.err >conftest.er1
2066     cat conftest.er1 >&5
2067     mv -f conftest.er1 conftest.err
2068   fi
2069   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2070   test $ac_status = 0; } && {
2071          test -z "$ac_c_werror_flag" ||
2072          test ! -s conftest.err
2073        } && test -s conftest$ac_exeext && {
2074          test "$cross_compiling" = yes ||
2075          $as_test_x conftest$ac_exeext
2076        }; then :
2077   ac_retval=0
2078 else
2079   $as_echo "$as_me: failed program was:" >&5
2080 sed 's/^/| /' conftest.$ac_ext >&5
2081
2082         ac_retval=1
2083 fi
2084   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2085   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2086   # interfere with the next link command; also delete a directory that is
2087   # left behind by Apple's compiler.  We do this before executing the actions.
2088   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2089   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2090   return $ac_retval
2091
2092 } # ac_fn_c_try_link
2093
2094 # ac_fn_c_check_func LINENO FUNC VAR
2095 # ----------------------------------
2096 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2097 ac_fn_c_check_func ()
2098 {
2099   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2100   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2101 $as_echo_n "checking for $2... " >&6; }
2102 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2103   $as_echo_n "(cached) " >&6
2104 else
2105   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2106 /* end confdefs.h.  */
2107 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2108    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2109 #define $2 innocuous_$2
2110
2111 /* System header to define __stub macros and hopefully few prototypes,
2112     which can conflict with char $2 (); below.
2113     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2114     <limits.h> exists even on freestanding compilers.  */
2115
2116 #ifdef __STDC__
2117 # include <limits.h>
2118 #else
2119 # include <assert.h>
2120 #endif
2121
2122 #undef $2
2123
2124 /* Override any GCC internal prototype to avoid an error.
2125    Use char because int might match the return type of a GCC
2126    builtin and then its argument prototype would still apply.  */
2127 #ifdef __cplusplus
2128 extern "C"
2129 #endif
2130 char $2 ();
2131 /* The GNU C library defines this for functions which it implements
2132     to always fail with ENOSYS.  Some functions are actually named
2133     something starting with __ and the normal name is an alias.  */
2134 #if defined __stub_$2 || defined __stub___$2
2135 choke me
2136 #endif
2137
2138 int
2139 main ()
2140 {
2141 return $2 ();
2142   ;
2143   return 0;
2144 }
2145 _ACEOF
2146 if ac_fn_c_try_link "$LINENO"; then :
2147   eval "$3=yes"
2148 else
2149   eval "$3=no"
2150 fi
2151 rm -f core conftest.err conftest.$ac_objext \
2152     conftest$ac_exeext conftest.$ac_ext
2153 fi
2154 eval ac_res=\$$3
2155                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2156 $as_echo "$ac_res" >&6; }
2157   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2158
2159 } # ac_fn_c_check_func
2160
2161 # ac_fn_c_check_decl LINENO SYMBOL VAR
2162 # ------------------------------------
2163 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2164 ac_fn_c_check_decl ()
2165 {
2166   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2167   as_decl_name=`echo $2|sed 's/ *(.*//'`
2168   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2169   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2170 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2171 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2172   $as_echo_n "(cached) " >&6
2173 else
2174   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2175 /* end confdefs.h.  */
2176 $4
2177 int
2178 main ()
2179 {
2180 #ifndef $as_decl_name
2181 #ifdef __cplusplus
2182   (void) $as_decl_use;
2183 #else
2184   (void) $as_decl_name;
2185 #endif
2186 #endif
2187
2188   ;
2189   return 0;
2190 }
2191 _ACEOF
2192 if ac_fn_c_try_compile "$LINENO"; then :
2193   eval "$3=yes"
2194 else
2195   eval "$3=no"
2196 fi
2197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2198 fi
2199 eval ac_res=\$$3
2200                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2201 $as_echo "$ac_res" >&6; }
2202   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2203
2204 } # ac_fn_c_check_decl
2205
2206 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2207 # ----------------------------------------------------
2208 # Tries to find if the field MEMBER exists in type AGGR, after including
2209 # INCLUDES, setting cache variable VAR accordingly.
2210 ac_fn_c_check_member ()
2211 {
2212   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2213   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2214 $as_echo_n "checking for $2.$3... " >&6; }
2215 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2216   $as_echo_n "(cached) " >&6
2217 else
2218   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2219 /* end confdefs.h.  */
2220 $5
2221 int
2222 main ()
2223 {
2224 static $2 ac_aggr;
2225 if (ac_aggr.$3)
2226 return 0;
2227   ;
2228   return 0;
2229 }
2230 _ACEOF
2231 if ac_fn_c_try_compile "$LINENO"; then :
2232   eval "$4=yes"
2233 else
2234   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2235 /* end confdefs.h.  */
2236 $5
2237 int
2238 main ()
2239 {
2240 static $2 ac_aggr;
2241 if (sizeof ac_aggr.$3)
2242 return 0;
2243   ;
2244   return 0;
2245 }
2246 _ACEOF
2247 if ac_fn_c_try_compile "$LINENO"; then :
2248   eval "$4=yes"
2249 else
2250   eval "$4=no"
2251 fi
2252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2253 fi
2254 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2255 fi
2256 eval ac_res=\$$4
2257                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2258 $as_echo "$ac_res" >&6; }
2259   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2260
2261 } # ac_fn_c_check_member
2262
2263 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2264 # -------------------------------------------
2265 # Tests whether TYPE exists after having included INCLUDES, setting cache
2266 # variable VAR accordingly.
2267 ac_fn_c_check_type ()
2268 {
2269   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2270   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2271 $as_echo_n "checking for $2... " >&6; }
2272 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2273   $as_echo_n "(cached) " >&6
2274 else
2275   eval "$3=no"
2276   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2277 /* end confdefs.h.  */
2278 $4
2279 int
2280 main ()
2281 {
2282 if (sizeof ($2))
2283          return 0;
2284   ;
2285   return 0;
2286 }
2287 _ACEOF
2288 if ac_fn_c_try_compile "$LINENO"; then :
2289   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2290 /* end confdefs.h.  */
2291 $4
2292 int
2293 main ()
2294 {
2295 if (sizeof (($2)))
2296             return 0;
2297   ;
2298   return 0;
2299 }
2300 _ACEOF
2301 if ac_fn_c_try_compile "$LINENO"; then :
2302
2303 else
2304   eval "$3=yes"
2305 fi
2306 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2307 fi
2308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2309 fi
2310 eval ac_res=\$$3
2311                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2312 $as_echo "$ac_res" >&6; }
2313   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2314
2315 } # ac_fn_c_check_type
2316 cat >config.log <<_ACEOF
2317 This file contains any messages produced by compilers while
2318 running configure, to aid debugging if configure makes a mistake.
2319
2320 It was created by $as_me, which was
2321 generated by GNU Autoconf 2.64.  Invocation command line was
2322
2323   $ $0 $@
2324
2325 _ACEOF
2326 exec 5>>config.log
2327 {
2328 cat <<_ASUNAME
2329 ## --------- ##
2330 ## Platform. ##
2331 ## --------- ##
2332
2333 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2334 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2335 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2336 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2337 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2338
2339 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2340 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2341
2342 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2343 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2344 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2345 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2346 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2347 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2348 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2349
2350 _ASUNAME
2351
2352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2353 for as_dir in $PATH
2354 do
2355   IFS=$as_save_IFS
2356   test -z "$as_dir" && as_dir=.
2357     $as_echo "PATH: $as_dir"
2358   done
2359 IFS=$as_save_IFS
2360
2361 } >&5
2362
2363 cat >&5 <<_ACEOF
2364
2365
2366 ## ----------- ##
2367 ## Core tests. ##
2368 ## ----------- ##
2369
2370 _ACEOF
2371
2372
2373 # Keep a trace of the command line.
2374 # Strip out --no-create and --no-recursion so they do not pile up.
2375 # Strip out --silent because we don't want to record it for future runs.
2376 # Also quote any args containing shell meta-characters.
2377 # Make two passes to allow for proper duplicate-argument suppression.
2378 ac_configure_args=
2379 ac_configure_args0=
2380 ac_configure_args1=
2381 ac_must_keep_next=false
2382 for ac_pass in 1 2
2383 do
2384   for ac_arg
2385   do
2386     case $ac_arg in
2387     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2388     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2389     | -silent | --silent | --silen | --sile | --sil)
2390       continue ;;
2391     *\'*)
2392       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2393     esac
2394     case $ac_pass in
2395     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2396     2)
2397       as_fn_append ac_configure_args1 " '$ac_arg'"
2398       if test $ac_must_keep_next = true; then
2399         ac_must_keep_next=false # Got value, back to normal.
2400       else
2401         case $ac_arg in
2402           *=* | --config-cache | -C | -disable-* | --disable-* \
2403           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2404           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2405           | -with-* | --with-* | -without-* | --without-* | --x)
2406             case "$ac_configure_args0 " in
2407               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2408             esac
2409             ;;
2410           -* ) ac_must_keep_next=true ;;
2411         esac
2412       fi
2413       as_fn_append ac_configure_args " '$ac_arg'"
2414       ;;
2415     esac
2416   done
2417 done
2418 { ac_configure_args0=; unset ac_configure_args0;}
2419 { ac_configure_args1=; unset ac_configure_args1;}
2420
2421 # When interrupted or exit'd, cleanup temporary files, and complete
2422 # config.log.  We remove comments because anyway the quotes in there
2423 # would cause problems or look ugly.
2424 # WARNING: Use '\'' to represent an apostrophe within the trap.
2425 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2426 trap 'exit_status=$?
2427   # Save into config.log some information that might help in debugging.
2428   {
2429     echo
2430
2431     cat <<\_ASBOX
2432 ## ---------------- ##
2433 ## Cache variables. ##
2434 ## ---------------- ##
2435 _ASBOX
2436     echo
2437     # The following way of writing the cache mishandles newlines in values,
2438 (
2439   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2440     eval ac_val=\$$ac_var
2441     case $ac_val in #(
2442     *${as_nl}*)
2443       case $ac_var in #(
2444       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2445 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2446       esac
2447       case $ac_var in #(
2448       _ | IFS | as_nl) ;; #(
2449       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2450       *) { eval $ac_var=; unset $ac_var;} ;;
2451       esac ;;
2452     esac
2453   done
2454   (set) 2>&1 |
2455     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2456     *${as_nl}ac_space=\ *)
2457       sed -n \
2458         "s/'\''/'\''\\\\'\'''\''/g;
2459           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2460       ;; #(
2461     *)
2462       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2463       ;;
2464     esac |
2465     sort
2466 )
2467     echo
2468
2469     cat <<\_ASBOX
2470 ## ----------------- ##
2471 ## Output variables. ##
2472 ## ----------------- ##
2473 _ASBOX
2474     echo
2475     for ac_var in $ac_subst_vars
2476     do
2477       eval ac_val=\$$ac_var
2478       case $ac_val in
2479       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2480       esac
2481       $as_echo "$ac_var='\''$ac_val'\''"
2482     done | sort
2483     echo
2484
2485     if test -n "$ac_subst_files"; then
2486       cat <<\_ASBOX
2487 ## ------------------- ##
2488 ## File substitutions. ##
2489 ## ------------------- ##
2490 _ASBOX
2491       echo
2492       for ac_var in $ac_subst_files
2493       do
2494         eval ac_val=\$$ac_var
2495         case $ac_val in
2496         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2497         esac
2498         $as_echo "$ac_var='\''$ac_val'\''"
2499       done | sort
2500       echo
2501     fi
2502
2503     if test -s confdefs.h; then
2504       cat <<\_ASBOX
2505 ## ----------- ##
2506 ## confdefs.h. ##
2507 ## ----------- ##
2508 _ASBOX
2509       echo
2510       cat confdefs.h
2511       echo
2512     fi
2513     test "$ac_signal" != 0 &&
2514       $as_echo "$as_me: caught signal $ac_signal"
2515     $as_echo "$as_me: exit $exit_status"
2516   } >&5
2517   rm -f core *.core core.conftest.* &&
2518     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2519     exit $exit_status
2520 ' 0
2521 for ac_signal in 1 2 13 15; do
2522   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2523 done
2524 ac_signal=0
2525
2526 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2527 rm -f -r conftest* confdefs.h
2528
2529 $as_echo "/* confdefs.h */" > confdefs.h
2530
2531 # Predefined preprocessor variables.
2532
2533 cat >>confdefs.h <<_ACEOF
2534 #define PACKAGE_NAME "$PACKAGE_NAME"
2535 _ACEOF
2536
2537 cat >>confdefs.h <<_ACEOF
2538 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2539 _ACEOF
2540
2541 cat >>confdefs.h <<_ACEOF
2542 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2543 _ACEOF
2544
2545 cat >>confdefs.h <<_ACEOF
2546 #define PACKAGE_STRING "$PACKAGE_STRING"
2547 _ACEOF
2548
2549 cat >>confdefs.h <<_ACEOF
2550 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2551 _ACEOF
2552
2553 cat >>confdefs.h <<_ACEOF
2554 #define PACKAGE_URL "$PACKAGE_URL"
2555 _ACEOF
2556
2557
2558 # Let the site file select an alternate cache file if it wants to.
2559 # Prefer an explicitly selected file to automatically selected ones.
2560 ac_site_file1=NONE
2561 ac_site_file2=NONE
2562 if test -n "$CONFIG_SITE"; then
2563   ac_site_file1=$CONFIG_SITE
2564 elif test "x$prefix" != xNONE; then
2565   ac_site_file1=$prefix/share/config.site
2566   ac_site_file2=$prefix/etc/config.site
2567 else
2568   ac_site_file1=$ac_default_prefix/share/config.site
2569   ac_site_file2=$ac_default_prefix/etc/config.site
2570 fi
2571 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2572 do
2573   test "x$ac_site_file" = xNONE && continue
2574   if test -r "$ac_site_file"; then
2575     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2576 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2577     sed 's/^/| /' "$ac_site_file" >&5
2578     . "$ac_site_file"
2579   fi
2580 done
2581
2582 if test -r "$cache_file"; then
2583   # Some versions of bash will fail to source /dev/null (special
2584   # files actually), so we avoid doing that.
2585   if test -f "$cache_file"; then
2586     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2587 $as_echo "$as_me: loading cache $cache_file" >&6;}
2588     case $cache_file in
2589       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2590       *)                      . "./$cache_file";;
2591     esac
2592   fi
2593 else
2594   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2595 $as_echo "$as_me: creating cache $cache_file" >&6;}
2596   >$cache_file
2597 fi
2598
2599 # Check that the precious variables saved in the cache have kept the same
2600 # value.
2601 ac_cache_corrupted=false
2602 for ac_var in $ac_precious_vars; do
2603   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2604   eval ac_new_set=\$ac_env_${ac_var}_set
2605   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2606   eval ac_new_val=\$ac_env_${ac_var}_value
2607   case $ac_old_set,$ac_new_set in
2608     set,)
2609       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2610 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2611       ac_cache_corrupted=: ;;
2612     ,set)
2613       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2614 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2615       ac_cache_corrupted=: ;;
2616     ,);;
2617     *)
2618       if test "x$ac_old_val" != "x$ac_new_val"; then
2619         # differences in whitespace do not lead to failure.
2620         ac_old_val_w=`echo x $ac_old_val`
2621         ac_new_val_w=`echo x $ac_new_val`
2622         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2623           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2624 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2625           ac_cache_corrupted=:
2626         else
2627           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2628 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2629           eval $ac_var=\$ac_old_val
2630         fi
2631         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2632 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2633         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2634 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2635       fi;;
2636   esac
2637   # Pass precious variables to config.status.
2638   if test "$ac_new_set" = set; then
2639     case $ac_new_val in
2640     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2641     *) ac_arg=$ac_var=$ac_new_val ;;
2642     esac
2643     case " $ac_configure_args " in
2644       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2645       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2646     esac
2647   fi
2648 done
2649 if $ac_cache_corrupted; then
2650   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2651 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2652   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2653 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2654   as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2655 fi
2656 ## -------------------- ##
2657 ## Main body of script. ##
2658 ## -------------------- ##
2659
2660 ac_ext=c
2661 ac_cpp='$CPP $CPPFLAGS'
2662 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2663 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2664 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2665
2666
2667
2668
2669
2670 ac_config_headers="$ac_config_headers config.h:config.in"
2671
2672
2673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2674 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2675     # Check whether --enable-maintainer-mode was given.
2676 if test "${enable_maintainer_mode+set}" = set; then :
2677   enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2678 else
2679   USE_MAINTAINER_MODE=no
2680 fi
2681
2682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2683 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2684    if test $USE_MAINTAINER_MODE = yes; then
2685   MAINTAINER_MODE_TRUE=
2686   MAINTAINER_MODE_FALSE='#'
2687 else
2688   MAINTAINER_MODE_TRUE='#'
2689   MAINTAINER_MODE_FALSE=
2690 fi
2691
2692   MAINT=$MAINTAINER_MODE_TRUE
2693
2694
2695
2696 # Provide more thorough testing by -lmcheck.
2697 # Set it to 'true' for development snapshots, 'false' for releases or
2698 # pre-releases.
2699 development=true
2700
2701 ac_ext=c
2702 ac_cpp='$CPP $CPPFLAGS'
2703 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2704 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2705 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2706 if test -n "$ac_tool_prefix"; then
2707   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2708 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2710 $as_echo_n "checking for $ac_word... " >&6; }
2711 if test "${ac_cv_prog_CC+set}" = set; then :
2712   $as_echo_n "(cached) " >&6
2713 else
2714   if test -n "$CC"; then
2715   ac_cv_prog_CC="$CC" # Let the user override the test.
2716 else
2717 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2718 for as_dir in $PATH
2719 do
2720   IFS=$as_save_IFS
2721   test -z "$as_dir" && as_dir=.
2722     for ac_exec_ext in '' $ac_executable_extensions; do
2723   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2724     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2725     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2726     break 2
2727   fi
2728 done
2729   done
2730 IFS=$as_save_IFS
2731
2732 fi
2733 fi
2734 CC=$ac_cv_prog_CC
2735 if test -n "$CC"; then
2736   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2737 $as_echo "$CC" >&6; }
2738 else
2739   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2740 $as_echo "no" >&6; }
2741 fi
2742
2743
2744 fi
2745 if test -z "$ac_cv_prog_CC"; then
2746   ac_ct_CC=$CC
2747   # Extract the first word of "gcc", so it can be a program name with args.
2748 set dummy gcc; ac_word=$2
2749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2750 $as_echo_n "checking for $ac_word... " >&6; }
2751 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2752   $as_echo_n "(cached) " >&6
2753 else
2754   if test -n "$ac_ct_CC"; then
2755   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2756 else
2757 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2758 for as_dir in $PATH
2759 do
2760   IFS=$as_save_IFS
2761   test -z "$as_dir" && as_dir=.
2762     for ac_exec_ext in '' $ac_executable_extensions; do
2763   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2764     ac_cv_prog_ac_ct_CC="gcc"
2765     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2766     break 2
2767   fi
2768 done
2769   done
2770 IFS=$as_save_IFS
2771
2772 fi
2773 fi
2774 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2775 if test -n "$ac_ct_CC"; then
2776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2777 $as_echo "$ac_ct_CC" >&6; }
2778 else
2779   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2780 $as_echo "no" >&6; }
2781 fi
2782
2783   if test "x$ac_ct_CC" = x; then
2784     CC=""
2785   else
2786     case $cross_compiling:$ac_tool_warned in
2787 yes:)
2788 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2789 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2790 ac_tool_warned=yes ;;
2791 esac
2792     CC=$ac_ct_CC
2793   fi
2794 else
2795   CC="$ac_cv_prog_CC"
2796 fi
2797
2798 if test -z "$CC"; then
2799           if test -n "$ac_tool_prefix"; then
2800     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2801 set dummy ${ac_tool_prefix}cc; ac_word=$2
2802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2803 $as_echo_n "checking for $ac_word... " >&6; }
2804 if test "${ac_cv_prog_CC+set}" = set; then :
2805   $as_echo_n "(cached) " >&6
2806 else
2807   if test -n "$CC"; then
2808   ac_cv_prog_CC="$CC" # Let the user override the test.
2809 else
2810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2811 for as_dir in $PATH
2812 do
2813   IFS=$as_save_IFS
2814   test -z "$as_dir" && as_dir=.
2815     for ac_exec_ext in '' $ac_executable_extensions; do
2816   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2817     ac_cv_prog_CC="${ac_tool_prefix}cc"
2818     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2819     break 2
2820   fi
2821 done
2822   done
2823 IFS=$as_save_IFS
2824
2825 fi
2826 fi
2827 CC=$ac_cv_prog_CC
2828 if test -n "$CC"; then
2829   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2830 $as_echo "$CC" >&6; }
2831 else
2832   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2833 $as_echo "no" >&6; }
2834 fi
2835
2836
2837   fi
2838 fi
2839 if test -z "$CC"; then
2840   # Extract the first word of "cc", so it can be a program name with args.
2841 set dummy cc; ac_word=$2
2842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2843 $as_echo_n "checking for $ac_word... " >&6; }
2844 if test "${ac_cv_prog_CC+set}" = set; then :
2845   $as_echo_n "(cached) " >&6
2846 else
2847   if test -n "$CC"; then
2848   ac_cv_prog_CC="$CC" # Let the user override the test.
2849 else
2850   ac_prog_rejected=no
2851 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2852 for as_dir in $PATH
2853 do
2854   IFS=$as_save_IFS
2855   test -z "$as_dir" && as_dir=.
2856     for ac_exec_ext in '' $ac_executable_extensions; do
2857   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2858     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2859        ac_prog_rejected=yes
2860        continue
2861      fi
2862     ac_cv_prog_CC="cc"
2863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2864     break 2
2865   fi
2866 done
2867   done
2868 IFS=$as_save_IFS
2869
2870 if test $ac_prog_rejected = yes; then
2871   # We found a bogon in the path, so make sure we never use it.
2872   set dummy $ac_cv_prog_CC
2873   shift
2874   if test $# != 0; then
2875     # We chose a different compiler from the bogus one.
2876     # However, it has the same basename, so the bogon will be chosen
2877     # first if we set CC to just the basename; use the full file name.
2878     shift
2879     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2880   fi
2881 fi
2882 fi
2883 fi
2884 CC=$ac_cv_prog_CC
2885 if test -n "$CC"; then
2886   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2887 $as_echo "$CC" >&6; }
2888 else
2889   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2890 $as_echo "no" >&6; }
2891 fi
2892
2893
2894 fi
2895 if test -z "$CC"; then
2896   if test -n "$ac_tool_prefix"; then
2897   for ac_prog in cl.exe
2898   do
2899     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2900 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2902 $as_echo_n "checking for $ac_word... " >&6; }
2903 if test "${ac_cv_prog_CC+set}" = set; then :
2904   $as_echo_n "(cached) " >&6
2905 else
2906   if test -n "$CC"; then
2907   ac_cv_prog_CC="$CC" # Let the user override the test.
2908 else
2909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2910 for as_dir in $PATH
2911 do
2912   IFS=$as_save_IFS
2913   test -z "$as_dir" && as_dir=.
2914     for ac_exec_ext in '' $ac_executable_extensions; do
2915   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2916     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2917     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2918     break 2
2919   fi
2920 done
2921   done
2922 IFS=$as_save_IFS
2923
2924 fi
2925 fi
2926 CC=$ac_cv_prog_CC
2927 if test -n "$CC"; then
2928   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2929 $as_echo "$CC" >&6; }
2930 else
2931   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2932 $as_echo "no" >&6; }
2933 fi
2934
2935
2936     test -n "$CC" && break
2937   done
2938 fi
2939 if test -z "$CC"; then
2940   ac_ct_CC=$CC
2941   for ac_prog in cl.exe
2942 do
2943   # Extract the first word of "$ac_prog", so it can be a program name with args.
2944 set dummy $ac_prog; ac_word=$2
2945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2946 $as_echo_n "checking for $ac_word... " >&6; }
2947 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2948   $as_echo_n "(cached) " >&6
2949 else
2950   if test -n "$ac_ct_CC"; then
2951   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2952 else
2953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2954 for as_dir in $PATH
2955 do
2956   IFS=$as_save_IFS
2957   test -z "$as_dir" && as_dir=.
2958     for ac_exec_ext in '' $ac_executable_extensions; do
2959   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2960     ac_cv_prog_ac_ct_CC="$ac_prog"
2961     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2962     break 2
2963   fi
2964 done
2965   done
2966 IFS=$as_save_IFS
2967
2968 fi
2969 fi
2970 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2971 if test -n "$ac_ct_CC"; then
2972   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2973 $as_echo "$ac_ct_CC" >&6; }
2974 else
2975   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2976 $as_echo "no" >&6; }
2977 fi
2978
2979
2980   test -n "$ac_ct_CC" && break
2981 done
2982
2983   if test "x$ac_ct_CC" = x; then
2984     CC=""
2985   else
2986     case $cross_compiling:$ac_tool_warned in
2987 yes:)
2988 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2989 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2990 ac_tool_warned=yes ;;
2991 esac
2992     CC=$ac_ct_CC
2993   fi
2994 fi
2995
2996 fi
2997
2998
2999 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3000 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3001 as_fn_error "no acceptable C compiler found in \$PATH
3002 See \`config.log' for more details." "$LINENO" 5; }
3003
3004 # Provide some information about the compiler.
3005 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3006 set X $ac_compile
3007 ac_compiler=$2
3008 for ac_option in --version -v -V -qversion; do
3009   { { ac_try="$ac_compiler $ac_option >&5"
3010 case "(($ac_try" in
3011   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3012   *) ac_try_echo=$ac_try;;
3013 esac
3014 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3015 $as_echo "$ac_try_echo"; } >&5
3016   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3017   ac_status=$?
3018   if test -s conftest.err; then
3019     sed '10a\
3020 ... rest of stderr output deleted ...
3021          10q' conftest.err >conftest.er1
3022     cat conftest.er1 >&5
3023     rm -f conftest.er1 conftest.err
3024   fi
3025   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3026   test $ac_status = 0; }
3027 done
3028
3029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3030 /* end confdefs.h.  */
3031
3032 int
3033 main ()
3034 {
3035
3036   ;
3037   return 0;
3038 }
3039 _ACEOF
3040 ac_clean_files_save=$ac_clean_files
3041 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out"
3042 # Try to create an executable without -o first, disregard a.out.
3043 # It will help us diagnose broken compilers, and finding out an intuition
3044 # of exeext.
3045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3046 $as_echo_n "checking for C compiler default output file name... " >&6; }
3047 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3048
3049 # The possible output files:
3050 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3051
3052 ac_rmfiles=
3053 for ac_file in $ac_files
3054 do
3055   case $ac_file in
3056     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3057     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3058   esac
3059 done
3060 rm -f $ac_rmfiles
3061
3062 if { { ac_try="$ac_link_default"
3063 case "(($ac_try" in
3064   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3065   *) ac_try_echo=$ac_try;;
3066 esac
3067 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3068 $as_echo "$ac_try_echo"; } >&5
3069   (eval "$ac_link_default") 2>&5
3070   ac_status=$?
3071   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3072   test $ac_status = 0; }; then :
3073   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3074 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3075 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3076 # so that the user can short-circuit this test for compilers unknown to
3077 # Autoconf.
3078 for ac_file in $ac_files ''
3079 do
3080   test -f "$ac_file" || continue
3081   case $ac_file in
3082     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3083         ;;
3084     [ab].out )
3085         # We found the default executable, but exeext='' is most
3086         # certainly right.
3087         break;;
3088     *.* )
3089         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3090         then :; else
3091            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3092         fi
3093         # We set ac_cv_exeext here because the later test for it is not
3094         # safe: cross compilers may not add the suffix if given an `-o'
3095         # argument, so we may need to know it at that point already.
3096         # Even if this section looks crufty: it has the advantage of
3097         # actually working.
3098         break;;
3099     * )
3100         break;;
3101   esac
3102 done
3103 test "$ac_cv_exeext" = no && ac_cv_exeext=
3104
3105 else
3106   ac_file=''
3107 fi
3108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3109 $as_echo "$ac_file" >&6; }
3110 if test -z "$ac_file"; then :
3111   $as_echo "$as_me: failed program was:" >&5
3112 sed 's/^/| /' conftest.$ac_ext >&5
3113
3114 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3115 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3116 { as_fn_set_status 77
3117 as_fn_error "C compiler cannot create executables
3118 See \`config.log' for more details." "$LINENO" 5; }; }
3119 fi
3120 ac_exeext=$ac_cv_exeext
3121
3122 # Check that the compiler produces executables we can run.  If not, either
3123 # the compiler is broken, or we cross compile.
3124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3125 $as_echo_n "checking whether the C compiler works... " >&6; }
3126 # If not cross compiling, check that we can run a simple program.
3127 if test "$cross_compiling" != yes; then
3128   if { ac_try='./$ac_file'
3129   { { case "(($ac_try" in
3130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3131   *) ac_try_echo=$ac_try;;
3132 esac
3133 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3134 $as_echo "$ac_try_echo"; } >&5
3135   (eval "$ac_try") 2>&5
3136   ac_status=$?
3137   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3138   test $ac_status = 0; }; }; then
3139     cross_compiling=no
3140   else
3141     if test "$cross_compiling" = maybe; then
3142         cross_compiling=yes
3143     else
3144         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3145 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3146 as_fn_error "cannot run C compiled programs.
3147 If you meant to cross compile, use \`--host'.
3148 See \`config.log' for more details." "$LINENO" 5; }
3149     fi
3150   fi
3151 fi
3152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3153 $as_echo "yes" >&6; }
3154
3155 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out
3156 ac_clean_files=$ac_clean_files_save
3157 # Check that the compiler produces executables we can run.  If not, either
3158 # the compiler is broken, or we cross compile.
3159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3160 $as_echo_n "checking whether we are cross compiling... " >&6; }
3161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3162 $as_echo "$cross_compiling" >&6; }
3163
3164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3165 $as_echo_n "checking for suffix of executables... " >&6; }
3166 if { { ac_try="$ac_link"
3167 case "(($ac_try" in
3168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3169   *) ac_try_echo=$ac_try;;
3170 esac
3171 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3172 $as_echo "$ac_try_echo"; } >&5
3173   (eval "$ac_link") 2>&5
3174   ac_status=$?
3175   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3176   test $ac_status = 0; }; then :
3177   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3178 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3179 # work properly (i.e., refer to `conftest.exe'), while it won't with
3180 # `rm'.
3181 for ac_file in conftest.exe conftest conftest.*; do
3182   test -f "$ac_file" || continue
3183   case $ac_file in
3184     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3185     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3186           break;;
3187     * ) break;;
3188   esac
3189 done
3190 else
3191   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3192 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3193 as_fn_error "cannot compute suffix of executables: cannot compile and link
3194 See \`config.log' for more details." "$LINENO" 5; }
3195 fi
3196 rm -f conftest$ac_cv_exeext
3197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3198 $as_echo "$ac_cv_exeext" >&6; }
3199
3200 rm -f conftest.$ac_ext
3201 EXEEXT=$ac_cv_exeext
3202 ac_exeext=$EXEEXT
3203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3204 $as_echo_n "checking for suffix of object files... " >&6; }
3205 if test "${ac_cv_objext+set}" = set; then :
3206   $as_echo_n "(cached) " >&6
3207 else
3208   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3209 /* end confdefs.h.  */
3210
3211 int
3212 main ()
3213 {
3214
3215   ;
3216   return 0;
3217 }
3218 _ACEOF
3219 rm -f conftest.o conftest.obj
3220 if { { ac_try="$ac_compile"
3221 case "(($ac_try" in
3222   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3223   *) ac_try_echo=$ac_try;;
3224 esac
3225 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3226 $as_echo "$ac_try_echo"; } >&5
3227   (eval "$ac_compile") 2>&5
3228   ac_status=$?
3229   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3230   test $ac_status = 0; }; then :
3231   for ac_file in conftest.o conftest.obj conftest.*; do
3232   test -f "$ac_file" || continue;
3233   case $ac_file in
3234     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3235     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3236        break;;
3237   esac
3238 done
3239 else
3240   $as_echo "$as_me: failed program was:" >&5
3241 sed 's/^/| /' conftest.$ac_ext >&5
3242
3243 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3244 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3245 as_fn_error "cannot compute suffix of object files: cannot compile
3246 See \`config.log' for more details." "$LINENO" 5; }
3247 fi
3248 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3249 fi
3250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3251 $as_echo "$ac_cv_objext" >&6; }
3252 OBJEXT=$ac_cv_objext
3253 ac_objext=$OBJEXT
3254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3255 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3256 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3257   $as_echo_n "(cached) " >&6
3258 else
3259   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3260 /* end confdefs.h.  */
3261
3262 int
3263 main ()
3264 {
3265 #ifndef __GNUC__
3266        choke me
3267 #endif
3268
3269   ;
3270   return 0;
3271 }
3272 _ACEOF
3273 if ac_fn_c_try_compile "$LINENO"; then :
3274   ac_compiler_gnu=yes
3275 else
3276   ac_compiler_gnu=no
3277 fi
3278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3279 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3280
3281 fi
3282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3283 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3284 if test $ac_compiler_gnu = yes; then
3285   GCC=yes
3286 else
3287   GCC=
3288 fi
3289 ac_test_CFLAGS=${CFLAGS+set}
3290 ac_save_CFLAGS=$CFLAGS
3291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3292 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3293 if test "${ac_cv_prog_cc_g+set}" = set; then :
3294   $as_echo_n "(cached) " >&6
3295 else
3296   ac_save_c_werror_flag=$ac_c_werror_flag
3297    ac_c_werror_flag=yes
3298    ac_cv_prog_cc_g=no
3299    CFLAGS="-g"
3300    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3301 /* end confdefs.h.  */
3302
3303 int
3304 main ()
3305 {
3306
3307   ;
3308   return 0;
3309 }
3310 _ACEOF
3311 if ac_fn_c_try_compile "$LINENO"; then :
3312   ac_cv_prog_cc_g=yes
3313 else
3314   CFLAGS=""
3315       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3316 /* end confdefs.h.  */
3317
3318 int
3319 main ()
3320 {
3321
3322   ;
3323   return 0;
3324 }
3325 _ACEOF
3326 if ac_fn_c_try_compile "$LINENO"; then :
3327
3328 else
3329   ac_c_werror_flag=$ac_save_c_werror_flag
3330          CFLAGS="-g"
3331          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3332 /* end confdefs.h.  */
3333
3334 int
3335 main ()
3336 {
3337
3338   ;
3339   return 0;
3340 }
3341 _ACEOF
3342 if ac_fn_c_try_compile "$LINENO"; then :
3343   ac_cv_prog_cc_g=yes
3344 fi
3345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3346 fi
3347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3348 fi
3349 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3350    ac_c_werror_flag=$ac_save_c_werror_flag
3351 fi
3352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3353 $as_echo "$ac_cv_prog_cc_g" >&6; }
3354 if test "$ac_test_CFLAGS" = set; then
3355   CFLAGS=$ac_save_CFLAGS
3356 elif test $ac_cv_prog_cc_g = yes; then
3357   if test "$GCC" = yes; then
3358     CFLAGS="-g -O2"
3359   else
3360     CFLAGS="-g"
3361   fi
3362 else
3363   if test "$GCC" = yes; then
3364     CFLAGS="-O2"
3365   else
3366     CFLAGS=
3367   fi
3368 fi
3369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3370 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3371 if test "${ac_cv_prog_cc_c89+set}" = set; then :
3372   $as_echo_n "(cached) " >&6
3373 else
3374   ac_cv_prog_cc_c89=no
3375 ac_save_CC=$CC
3376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3377 /* end confdefs.h.  */
3378 #include <stdarg.h>
3379 #include <stdio.h>
3380 #include <sys/types.h>
3381 #include <sys/stat.h>
3382 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3383 struct buf { int x; };
3384 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3385 static char *e (p, i)
3386      char **p;
3387      int i;
3388 {
3389   return p[i];
3390 }
3391 static char *f (char * (*g) (char **, int), char **p, ...)
3392 {
3393   char *s;
3394   va_list v;
3395   va_start (v,p);
3396   s = g (p, va_arg (v,int));
3397   va_end (v);
3398   return s;
3399 }
3400
3401 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3402    function prototypes and stuff, but not '\xHH' hex character constants.
3403    These don't provoke an error unfortunately, instead are silently treated
3404    as 'x'.  The following induces an error, until -std is added to get
3405    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3406    array size at least.  It's necessary to write '\x00'==0 to get something
3407    that's true only with -std.  */
3408 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3409
3410 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3411    inside strings and character constants.  */
3412 #define FOO(x) 'x'
3413 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3414
3415 int test (int i, double x);
3416 struct s1 {int (*f) (int a);};
3417 struct s2 {int (*f) (double a);};
3418 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3419 int argc;
3420 char **argv;
3421 int
3422 main ()
3423 {
3424 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3425   ;
3426   return 0;
3427 }
3428 _ACEOF
3429 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3430         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3431 do
3432   CC="$ac_save_CC $ac_arg"
3433   if ac_fn_c_try_compile "$LINENO"; then :
3434   ac_cv_prog_cc_c89=$ac_arg
3435 fi
3436 rm -f core conftest.err conftest.$ac_objext
3437   test "x$ac_cv_prog_cc_c89" != "xno" && break
3438 done
3439 rm -f conftest.$ac_ext
3440 CC=$ac_save_CC
3441
3442 fi
3443 # AC_CACHE_VAL
3444 case "x$ac_cv_prog_cc_c89" in
3445   x)
3446     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3447 $as_echo "none needed" >&6; } ;;
3448   xno)
3449     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3450 $as_echo "unsupported" >&6; } ;;
3451   *)
3452     CC="$CC $ac_cv_prog_cc_c89"
3453     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3454 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3455 esac
3456 if test "x$ac_cv_prog_cc_c89" != xno; then :
3457
3458 fi
3459
3460 ac_ext=c
3461 ac_cpp='$CPP $CPPFLAGS'
3462 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3463 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3464 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3465
3466
3467 ac_ext=c
3468 ac_cpp='$CPP $CPPFLAGS'
3469 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3470 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3471 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3473 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3474 # On Suns, sometimes $CPP names a directory.
3475 if test -n "$CPP" && test -d "$CPP"; then
3476   CPP=
3477 fi
3478 if test -z "$CPP"; then
3479   if test "${ac_cv_prog_CPP+set}" = set; then :
3480   $as_echo_n "(cached) " >&6
3481 else
3482       # Double quotes because CPP needs to be expanded
3483     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3484     do
3485       ac_preproc_ok=false
3486 for ac_c_preproc_warn_flag in '' yes
3487 do
3488   # Use a header file that comes with gcc, so configuring glibc
3489   # with a fresh cross-compiler works.
3490   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3491   # <limits.h> exists even on freestanding compilers.
3492   # On the NeXT, cc -E runs the code through the compiler's parser,
3493   # not just through cpp. "Syntax error" is here to catch this case.
3494   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3495 /* end confdefs.h.  */
3496 #ifdef __STDC__
3497 # include <limits.h>
3498 #else
3499 # include <assert.h>
3500 #endif
3501                      Syntax error
3502 _ACEOF
3503 if ac_fn_c_try_cpp "$LINENO"; then :
3504
3505 else
3506   # Broken: fails on valid input.
3507 continue
3508 fi
3509 rm -f conftest.err conftest.$ac_ext
3510
3511   # OK, works on sane cases.  Now check whether nonexistent headers
3512   # can be detected and how.
3513   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3514 /* end confdefs.h.  */
3515 #include <ac_nonexistent.h>
3516 _ACEOF
3517 if ac_fn_c_try_cpp "$LINENO"; then :
3518   # Broken: success on invalid input.
3519 continue
3520 else
3521   # Passes both tests.
3522 ac_preproc_ok=:
3523 break
3524 fi
3525 rm -f conftest.err conftest.$ac_ext
3526
3527 done
3528 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3529 rm -f conftest.err conftest.$ac_ext
3530 if $ac_preproc_ok; then :
3531   break
3532 fi
3533
3534     done
3535     ac_cv_prog_CPP=$CPP
3536
3537 fi
3538   CPP=$ac_cv_prog_CPP
3539 else
3540   ac_cv_prog_CPP=$CPP
3541 fi
3542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3543 $as_echo "$CPP" >&6; }
3544 ac_preproc_ok=false
3545 for ac_c_preproc_warn_flag in '' yes
3546 do
3547   # Use a header file that comes with gcc, so configuring glibc
3548   # with a fresh cross-compiler works.
3549   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3550   # <limits.h> exists even on freestanding compilers.
3551   # On the NeXT, cc -E runs the code through the compiler's parser,
3552   # not just through cpp. "Syntax error" is here to catch this case.
3553   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3554 /* end confdefs.h.  */
3555 #ifdef __STDC__
3556 # include <limits.h>
3557 #else
3558 # include <assert.h>
3559 #endif
3560                      Syntax error
3561 _ACEOF
3562 if ac_fn_c_try_cpp "$LINENO"; then :
3563
3564 else
3565   # Broken: fails on valid input.
3566 continue
3567 fi
3568 rm -f conftest.err conftest.$ac_ext
3569
3570   # OK, works on sane cases.  Now check whether nonexistent headers
3571   # can be detected and how.
3572   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3573 /* end confdefs.h.  */
3574 #include <ac_nonexistent.h>
3575 _ACEOF
3576 if ac_fn_c_try_cpp "$LINENO"; then :
3577   # Broken: success on invalid input.
3578 continue
3579 else
3580   # Passes both tests.
3581 ac_preproc_ok=:
3582 break
3583 fi
3584 rm -f conftest.err conftest.$ac_ext
3585
3586 done
3587 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3588 rm -f conftest.err conftest.$ac_ext
3589 if $ac_preproc_ok; then :
3590
3591 else
3592   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3593 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3594 as_fn_error "C preprocessor \"$CPP\" fails sanity check
3595 See \`config.log' for more details." "$LINENO" 5; }
3596 fi
3597
3598 ac_ext=c
3599 ac_cpp='$CPP $CPPFLAGS'
3600 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3601 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3602 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3603
3604
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3606 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3607 if test "${ac_cv_path_GREP+set}" = set; then :
3608   $as_echo_n "(cached) " >&6
3609 else
3610   if test -z "$GREP"; then
3611   ac_path_GREP_found=false
3612   # Loop through the user's path and test for each of PROGNAME-LIST
3613   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3614 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3615 do
3616   IFS=$as_save_IFS
3617   test -z "$as_dir" && as_dir=.
3618     for ac_prog in grep ggrep; do
3619     for ac_exec_ext in '' $ac_executable_extensions; do
3620       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3621       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3622 # Check for GNU ac_path_GREP and select it if it is found.
3623   # Check for GNU $ac_path_GREP
3624 case `"$ac_path_GREP" --version 2>&1` in
3625 *GNU*)
3626   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3627 *)
3628   ac_count=0
3629   $as_echo_n 0123456789 >"conftest.in"
3630   while :
3631   do
3632     cat "conftest.in" "conftest.in" >"conftest.tmp"
3633     mv "conftest.tmp" "conftest.in"
3634     cp "conftest.in" "conftest.nl"
3635     $as_echo 'GREP' >> "conftest.nl"
3636     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3637     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3638     as_fn_arith $ac_count + 1 && ac_count=$as_val
3639     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3640       # Best one so far, save it but keep looking for a better one
3641       ac_cv_path_GREP="$ac_path_GREP"
3642       ac_path_GREP_max=$ac_count
3643     fi
3644     # 10*(2^10) chars as input seems more than enough
3645     test $ac_count -gt 10 && break
3646   done
3647   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3648 esac
3649
3650       $ac_path_GREP_found && break 3
3651     done
3652   done
3653   done
3654 IFS=$as_save_IFS
3655   if test -z "$ac_cv_path_GREP"; then
3656     as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3657   fi
3658 else
3659   ac_cv_path_GREP=$GREP
3660 fi
3661
3662 fi
3663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3664 $as_echo "$ac_cv_path_GREP" >&6; }
3665  GREP="$ac_cv_path_GREP"
3666
3667
3668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3669 $as_echo_n "checking for egrep... " >&6; }
3670 if test "${ac_cv_path_EGREP+set}" = set; then :
3671   $as_echo_n "(cached) " >&6
3672 else
3673   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3674    then ac_cv_path_EGREP="$GREP -E"
3675    else
3676      if test -z "$EGREP"; then
3677   ac_path_EGREP_found=false
3678   # Loop through the user's path and test for each of PROGNAME-LIST
3679   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3680 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3681 do
3682   IFS=$as_save_IFS
3683   test -z "$as_dir" && as_dir=.
3684     for ac_prog in egrep; do
3685     for ac_exec_ext in '' $ac_executable_extensions; do
3686       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3687       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3688 # Check for GNU ac_path_EGREP and select it if it is found.
3689   # Check for GNU $ac_path_EGREP
3690 case `"$ac_path_EGREP" --version 2>&1` in
3691 *GNU*)
3692   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3693 *)
3694   ac_count=0
3695   $as_echo_n 0123456789 >"conftest.in"
3696   while :
3697   do
3698     cat "conftest.in" "conftest.in" >"conftest.tmp"
3699     mv "conftest.tmp" "conftest.in"
3700     cp "conftest.in" "conftest.nl"
3701     $as_echo 'EGREP' >> "conftest.nl"
3702     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3703     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3704     as_fn_arith $ac_count + 1 && ac_count=$as_val
3705     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3706       # Best one so far, save it but keep looking for a better one
3707       ac_cv_path_EGREP="$ac_path_EGREP"
3708       ac_path_EGREP_max=$ac_count
3709     fi
3710     # 10*(2^10) chars as input seems more than enough
3711     test $ac_count -gt 10 && break
3712   done
3713   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3714 esac
3715
3716       $ac_path_EGREP_found && break 3
3717     done
3718   done
3719   done
3720 IFS=$as_save_IFS
3721   if test -z "$ac_cv_path_EGREP"; then
3722     as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3723   fi
3724 else
3725   ac_cv_path_EGREP=$EGREP
3726 fi
3727
3728    fi
3729 fi
3730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3731 $as_echo "$ac_cv_path_EGREP" >&6; }
3732  EGREP="$ac_cv_path_EGREP"
3733
3734
3735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3736 $as_echo_n "checking for ANSI C header files... " >&6; }
3737 if test "${ac_cv_header_stdc+set}" = set; then :
3738   $as_echo_n "(cached) " >&6
3739 else
3740   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3741 /* end confdefs.h.  */
3742 #include <stdlib.h>
3743 #include <stdarg.h>
3744 #include <string.h>
3745 #include <float.h>
3746
3747 int
3748 main ()
3749 {
3750
3751   ;
3752   return 0;
3753 }
3754 _ACEOF
3755 if ac_fn_c_try_compile "$LINENO"; then :
3756   ac_cv_header_stdc=yes
3757 else
3758   ac_cv_header_stdc=no
3759 fi
3760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3761
3762 if test $ac_cv_header_stdc = yes; then
3763   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3764   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3765 /* end confdefs.h.  */
3766 #include <string.h>
3767
3768 _ACEOF
3769 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3770   $EGREP "memchr" >/dev/null 2>&1; then :
3771
3772 else
3773   ac_cv_header_stdc=no
3774 fi
3775 rm -f conftest*
3776
3777 fi
3778
3779 if test $ac_cv_header_stdc = yes; then
3780   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3781   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3782 /* end confdefs.h.  */
3783 #include <stdlib.h>
3784
3785 _ACEOF
3786 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3787   $EGREP "free" >/dev/null 2>&1; then :
3788
3789 else
3790   ac_cv_header_stdc=no
3791 fi
3792 rm -f conftest*
3793
3794 fi
3795
3796 if test $ac_cv_header_stdc = yes; then
3797   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3798   if test "$cross_compiling" = yes; then :
3799   :
3800 else
3801   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3802 /* end confdefs.h.  */
3803 #include <ctype.h>
3804 #include <stdlib.h>
3805 #if ((' ' & 0x0FF) == 0x020)
3806 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3807 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3808 #else
3809 # define ISLOWER(c) \
3810                    (('a' <= (c) && (c) <= 'i') \
3811                      || ('j' <= (c) && (c) <= 'r') \
3812                      || ('s' <= (c) && (c) <= 'z'))
3813 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3814 #endif
3815
3816 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3817 int
3818 main ()
3819 {
3820   int i;
3821   for (i = 0; i < 256; i++)
3822     if (XOR (islower (i), ISLOWER (i))
3823         || toupper (i) != TOUPPER (i))
3824       return 2;
3825   return 0;
3826 }
3827 _ACEOF
3828 if ac_fn_c_try_run "$LINENO"; then :
3829
3830 else
3831   ac_cv_header_stdc=no
3832 fi
3833 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3834   conftest.$ac_objext conftest.beam conftest.$ac_ext
3835 fi
3836
3837 fi
3838 fi
3839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
3840 $as_echo "$ac_cv_header_stdc" >&6; }
3841 if test $ac_cv_header_stdc = yes; then
3842
3843 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
3844
3845 fi
3846
3847 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
3848 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3849                   inttypes.h stdint.h unistd.h
3850 do :
3851   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
3852 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
3853 "
3854 eval as_val=\$$as_ac_Header
3855    if test "x$as_val" = x""yes; then :
3856   cat >>confdefs.h <<_ACEOF
3857 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
3858 _ACEOF
3859
3860 fi
3861
3862 done
3863
3864
3865
3866   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
3867 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
3868   MINIX=yes
3869 else
3870   MINIX=
3871 fi
3872
3873
3874   if test "$MINIX" = yes; then
3875
3876 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
3877
3878
3879 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
3880
3881
3882 $as_echo "#define _MINIX 1" >>confdefs.h
3883
3884   fi
3885
3886
3887   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
3888 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
3889 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
3890   $as_echo_n "(cached) " >&6
3891 else
3892   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3893 /* end confdefs.h.  */
3894
3895 #         define __EXTENSIONS__ 1
3896           $ac_includes_default
3897 int
3898 main ()
3899 {
3900
3901   ;
3902   return 0;
3903 }
3904 _ACEOF
3905 if ac_fn_c_try_compile "$LINENO"; then :
3906   ac_cv_safe_to_define___extensions__=yes
3907 else
3908   ac_cv_safe_to_define___extensions__=no
3909 fi
3910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3911 fi
3912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
3913 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
3914   test $ac_cv_safe_to_define___extensions__ = yes &&
3915     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
3916
3917   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
3918
3919   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
3920
3921   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
3922
3923   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
3924
3925
3926 ac_aux_dir=
3927 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3928   for ac_t in install-sh install.sh shtool; do
3929     if test -f "$ac_dir/$ac_t"; then
3930       ac_aux_dir=$ac_dir
3931       ac_install_sh="$ac_aux_dir/$ac_t -c"
3932       break 2
3933     fi
3934   done
3935 done
3936 if test -z "$ac_aux_dir"; then
3937   as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3938 fi
3939
3940 # These three variables are undocumented and unsupported,
3941 # and are intended to be withdrawn in a future Autoconf release.
3942 # They can cause serious problems if a builder's source tree is in a directory
3943 # whose full name contains unusual characters.
3944 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3945 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3946 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3947
3948
3949 # Make sure we can run config.sub.
3950 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3951   as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3952
3953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3954 $as_echo_n "checking build system type... " >&6; }
3955 if test "${ac_cv_build+set}" = set; then :
3956   $as_echo_n "(cached) " >&6
3957 else
3958   ac_build_alias=$build_alias
3959 test "x$ac_build_alias" = x &&
3960   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3961 test "x$ac_build_alias" = x &&
3962   as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
3963 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3964   as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3965
3966 fi
3967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3968 $as_echo "$ac_cv_build" >&6; }
3969 case $ac_cv_build in
3970 *-*-*) ;;
3971 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
3972 esac
3973 build=$ac_cv_build
3974 ac_save_IFS=$IFS; IFS='-'
3975 set x $ac_cv_build
3976 shift
3977 build_cpu=$1
3978 build_vendor=$2
3979 shift; shift
3980 # Remember, the first character of IFS is used to create $*,
3981 # except with old shells:
3982 build_os=$*
3983 IFS=$ac_save_IFS
3984 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3985
3986
3987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3988 $as_echo_n "checking host system type... " >&6; }
3989 if test "${ac_cv_host+set}" = set; then :
3990   $as_echo_n "(cached) " >&6
3991 else
3992   if test "x$host_alias" = x; then
3993   ac_cv_host=$ac_cv_build
3994 else
3995   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3996     as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3997 fi
3998
3999 fi
4000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4001 $as_echo "$ac_cv_host" >&6; }
4002 case $ac_cv_host in
4003 *-*-*) ;;
4004 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4005 esac
4006 host=$ac_cv_host
4007 ac_save_IFS=$IFS; IFS='-'
4008 set x $ac_cv_host
4009 shift
4010 host_cpu=$1
4011 host_vendor=$2
4012 shift; shift
4013 # Remember, the first character of IFS is used to create $*,
4014 # except with old shells:
4015 host_os=$*
4016 IFS=$ac_save_IFS
4017 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4018
4019
4020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4021 $as_echo_n "checking target system type... " >&6; }
4022 if test "${ac_cv_target+set}" = set; then :
4023   $as_echo_n "(cached) " >&6
4024 else
4025   if test "x$target_alias" = x; then
4026   ac_cv_target=$ac_cv_host
4027 else
4028   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4029     as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4030 fi
4031
4032 fi
4033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4034 $as_echo "$ac_cv_target" >&6; }
4035 case $ac_cv_target in
4036 *-*-*) ;;
4037 *) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
4038 esac
4039 target=$ac_cv_target
4040 ac_save_IFS=$IFS; IFS='-'
4041 set x $ac_cv_target
4042 shift
4043 target_cpu=$1
4044 target_vendor=$2
4045 shift; shift
4046 # Remember, the first character of IFS is used to create $*,
4047 # except with old shells:
4048 target_os=$*
4049 IFS=$ac_save_IFS
4050 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4051
4052
4053 # The aliases save the names the user supplied, while $host etc.
4054 # will get canonicalized.
4055 test -n "$target_alias" &&
4056   test "$program_prefix$program_suffix$program_transform_name" = \
4057     NONENONEs,x,x, &&
4058   program_prefix=${target_alias}-
4059
4060 # The tests for host and target for $enable_largefile require
4061 # canonical names.
4062
4063
4064
4065 # As the $enable_largefile decision depends on --enable-plugins we must set it
4066 # even in directories otherwise not depending on the $plugins option.
4067
4068
4069 # Check whether --enable-plugins was given.
4070 if test "${enable_plugins+set}" = set; then :
4071   enableval=$enable_plugins; case "${enableval}" in
4072   yes | "") plugins=yes ;;
4073   no) plugins=no ;;
4074   *) plugins=yes ;;
4075  esac
4076 else
4077   plugins=no
4078 fi
4079
4080
4081
4082 case "${host}" in
4083   sparc-*-solaris*|i[3-7]86-*-solaris*)
4084     # On native 32bit sparc and ia32 solaris, large-file and procfs support
4085     # are mutually exclusive; and without procfs support, the bfd/ elf module
4086     # cannot provide certain routines such as elfcore_write_prpsinfo
4087     # or elfcore_write_prstatus.  So unless the user explicitly requested
4088     # large-file support through the --enable-largefile switch, disable
4089     # large-file support in favor of procfs support.
4090     test "${target}" = "${host}" -a "x$plugins" = xno \
4091       && : ${enable_largefile="no"}
4092     ;;
4093 esac
4094
4095 # Check whether --enable-largefile was given.
4096 if test "${enable_largefile+set}" = set; then :
4097   enableval=$enable_largefile;
4098 fi
4099
4100 if test "$enable_largefile" != no; then
4101
4102   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4103 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4104 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
4105   $as_echo_n "(cached) " >&6
4106 else
4107   ac_cv_sys_largefile_CC=no
4108      if test "$GCC" != yes; then
4109        ac_save_CC=$CC
4110        while :; do
4111          # IRIX 6.2 and later do not support large files by default,
4112          # so use the C compiler's -n32 option if that helps.
4113          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4114 /* end confdefs.h.  */
4115 #include <sys/types.h>
4116  /* Check that off_t can represent 2**63 - 1 correctly.
4117     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4118     since some C++ compilers masquerading as C compilers
4119     incorrectly reject 9223372036854775807.  */
4120 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4121   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4122                        && LARGE_OFF_T % 2147483647 == 1)
4123                       ? 1 : -1];
4124 int
4125 main ()
4126 {
4127
4128   ;
4129   return 0;
4130 }
4131 _ACEOF
4132          if ac_fn_c_try_compile "$LINENO"; then :
4133   break
4134 fi
4135 rm -f core conftest.err conftest.$ac_objext
4136          CC="$CC -n32"
4137          if ac_fn_c_try_compile "$LINENO"; then :
4138   ac_cv_sys_largefile_CC=' -n32'; break
4139 fi
4140 rm -f core conftest.err conftest.$ac_objext
4141          break
4142        done
4143        CC=$ac_save_CC
4144        rm -f conftest.$ac_ext
4145     fi
4146 fi
4147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4148 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4149   if test "$ac_cv_sys_largefile_CC" != no; then
4150     CC=$CC$ac_cv_sys_largefile_CC
4151   fi
4152
4153   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4154 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4155 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
4156   $as_echo_n "(cached) " >&6
4157 else
4158   while :; do
4159   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4160 /* end confdefs.h.  */
4161 #include <sys/types.h>
4162  /* Check that off_t can represent 2**63 - 1 correctly.
4163     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4164     since some C++ compilers masquerading as C compilers
4165     incorrectly reject 9223372036854775807.  */
4166 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4167   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4168                        && LARGE_OFF_T % 2147483647 == 1)
4169                       ? 1 : -1];
4170 int
4171 main ()
4172 {
4173
4174   ;
4175   return 0;
4176 }
4177 _ACEOF
4178 if ac_fn_c_try_compile "$LINENO"; then :
4179   ac_cv_sys_file_offset_bits=no; break
4180 fi
4181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4182   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4183 /* end confdefs.h.  */
4184 #define _FILE_OFFSET_BITS 64
4185 #include <sys/types.h>
4186  /* Check that off_t can represent 2**63 - 1 correctly.
4187     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4188     since some C++ compilers masquerading as C compilers
4189     incorrectly reject 9223372036854775807.  */
4190 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4191   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4192                        && LARGE_OFF_T % 2147483647 == 1)
4193                       ? 1 : -1];
4194 int
4195 main ()
4196 {
4197
4198   ;
4199   return 0;
4200 }
4201 _ACEOF
4202 if ac_fn_c_try_compile "$LINENO"; then :
4203   ac_cv_sys_file_offset_bits=64; break
4204 fi
4205 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4206   ac_cv_sys_file_offset_bits=unknown
4207   break
4208 done
4209 fi
4210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4211 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4212 case $ac_cv_sys_file_offset_bits in #(
4213   no | unknown) ;;
4214   *)
4215 cat >>confdefs.h <<_ACEOF
4216 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4217 _ACEOF
4218 ;;
4219 esac
4220 rm -rf conftest*
4221   if test $ac_cv_sys_file_offset_bits = unknown; then
4222     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4223 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4224 if test "${ac_cv_sys_large_files+set}" = set; then :
4225   $as_echo_n "(cached) " >&6
4226 else
4227   while :; do
4228   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4229 /* end confdefs.h.  */
4230 #include <sys/types.h>
4231  /* Check that off_t can represent 2**63 - 1 correctly.
4232     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4233     since some C++ compilers masquerading as C compilers
4234     incorrectly reject 9223372036854775807.  */
4235 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4236   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4237                        && LARGE_OFF_T % 2147483647 == 1)
4238                       ? 1 : -1];
4239 int
4240 main ()
4241 {
4242
4243   ;
4244   return 0;
4245 }
4246 _ACEOF
4247 if ac_fn_c_try_compile "$LINENO"; then :
4248   ac_cv_sys_large_files=no; break
4249 fi
4250 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4251   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4252 /* end confdefs.h.  */
4253 #define _LARGE_FILES 1
4254 #include <sys/types.h>
4255  /* Check that off_t can represent 2**63 - 1 correctly.
4256     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4257     since some C++ compilers masquerading as C compilers
4258     incorrectly reject 9223372036854775807.  */
4259 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4260   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4261                        && LARGE_OFF_T % 2147483647 == 1)
4262                       ? 1 : -1];
4263 int
4264 main ()
4265 {
4266
4267   ;
4268   return 0;
4269 }
4270 _ACEOF
4271 if ac_fn_c_try_compile "$LINENO"; then :
4272   ac_cv_sys_large_files=1; break
4273 fi
4274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4275   ac_cv_sys_large_files=unknown
4276   break
4277 done
4278 fi
4279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4280 $as_echo "$ac_cv_sys_large_files" >&6; }
4281 case $ac_cv_sys_large_files in #(
4282   no | unknown) ;;
4283   *)
4284 cat >>confdefs.h <<_ACEOF
4285 #define _LARGE_FILES $ac_cv_sys_large_files
4286 _ACEOF
4287 ;;
4288 esac
4289 rm -rf conftest*
4290   fi
4291 fi
4292
4293
4294
4295
4296
4297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${CC-cc} option to accept ANSI C" >&5
4298 $as_echo_n "checking for ${CC-cc} option to accept ANSI C... " >&6; }
4299 if test "${am_cv_prog_cc_stdc+set}" = set; then :
4300   $as_echo_n "(cached) " >&6
4301 else
4302   am_cv_prog_cc_stdc=no
4303 ac_save_CC="$CC"
4304 # Don't try gcc -ansi; that turns off useful extensions and
4305 # breaks some systems' header files.
4306 # AIX                   -qlanglvl=ansi
4307 # Ultrix and OSF/1      -std1
4308 # HP-UX 10.20 and later -Ae
4309 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4310 # SVR4                  -Xc -D__EXTENSIONS__
4311 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4312 do
4313   CC="$ac_save_CC $ac_arg"
4314   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4315 /* end confdefs.h.  */
4316 #include <stdarg.h>
4317 #include <stdio.h>
4318 #include <sys/types.h>
4319 #include <sys/stat.h>
4320 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4321 struct buf { int x; };
4322 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4323 static char *e (p, i)
4324      char **p;
4325      int i;
4326 {
4327   return p[i];
4328 }
4329 static char *f (char * (*g) (char **, int), char **p, ...)
4330 {
4331   char *s;
4332   va_list v;
4333   va_start (v,p);
4334   s = g (p, va_arg (v,int));
4335   va_end (v);
4336   return s;
4337 }
4338 int test (int i, double x);
4339 struct s1 {int (*f) (int a);};
4340 struct s2 {int (*f) (double a);};
4341 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4342 int argc;
4343 char **argv;
4344
4345 int
4346 main ()
4347 {
4348
4349 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4350
4351   ;
4352   return 0;
4353 }
4354 _ACEOF
4355 if ac_fn_c_try_compile "$LINENO"; then :
4356   am_cv_prog_cc_stdc="$ac_arg"; break
4357 fi
4358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4359 done
4360 CC="$ac_save_CC"
4361
4362 fi
4363
4364 if test -z "$am_cv_prog_cc_stdc"; then
4365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4366 $as_echo "none needed" >&6; }
4367 else
4368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_stdc" >&5
4369 $as_echo "$am_cv_prog_cc_stdc" >&6; }
4370 fi
4371 case "x$am_cv_prog_cc_stdc" in
4372   x|xno) ;;
4373   *) CC="$CC $am_cv_prog_cc_stdc" ;;
4374 esac
4375
4376
4377 ac_aux_dir=
4378 for ac_dir in .. "$srcdir"/..; do
4379   for ac_t in install-sh install.sh shtool; do
4380     if test -f "$ac_dir/$ac_t"; then
4381       ac_aux_dir=$ac_dir
4382       ac_install_sh="$ac_aux_dir/$ac_t -c"
4383       break 2
4384     fi
4385   done
4386 done
4387 if test -z "$ac_aux_dir"; then
4388   as_fn_error "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
4389 fi
4390
4391 # These three variables are undocumented and unsupported,
4392 # and are intended to be withdrawn in a future Autoconf release.
4393 # They can cause serious problems if a builder's source tree is in a directory
4394 # whose full name contains unusual characters.
4395 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
4396 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
4397 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
4398
4399
4400
4401 test "$program_prefix" != NONE &&
4402   program_transform_name="s&^&$program_prefix&;$program_transform_name"
4403 # Use a double $ so make ignores it.
4404 test "$program_suffix" != NONE &&
4405   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
4406 # Double any \ or $.
4407 # By default was `s,x,x', remove it if useless.
4408 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
4409 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
4410
4411
4412 # Dependency checking.
4413 rm -rf .tst 2>/dev/null
4414 mkdir .tst 2>/dev/null
4415 if test -d .tst; then
4416   am__leading_dot=.
4417 else
4418   am__leading_dot=_
4419 fi
4420 rmdir .tst 2>/dev/null
4421
4422 DEPDIR="${am__leading_dot}deps"
4423
4424 ac_config_commands="$ac_config_commands depdir"
4425
4426
4427 depcc="$CC"   am_compiler_list=
4428
4429 am_depcomp=$ac_aux_dir/depcomp
4430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4431 $as_echo_n "checking dependency style of $depcc... " >&6; }
4432 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
4433   $as_echo_n "(cached) " >&6
4434 else
4435   if test -f "$am_depcomp"; then
4436   # We make a subdir and do the tests there.  Otherwise we can end up
4437   # making bogus files that we don't know about and never remove.  For
4438   # instance it was reported that on HP-UX the gcc test will end up
4439   # making a dummy file named `D' -- because `-MD' means `put the output
4440   # in D'.
4441   mkdir conftest.dir
4442   # Copy depcomp to subdir because otherwise we won't find it if we're
4443   # using a relative directory.
4444   cp "$am_depcomp" conftest.dir
4445   cd conftest.dir
4446   # We will build objects and dependencies in a subdirectory because
4447   # it helps to detect inapplicable dependency modes.  For instance
4448   # both Tru64's cc and ICC support -MD to output dependencies as a
4449   # side effect of compilation, but ICC will put the dependencies in
4450   # the current directory while Tru64 will put them in the object
4451   # directory.
4452   mkdir sub
4453
4454   am_cv_CC_dependencies_compiler_type=none
4455   if test "$am_compiler_list" = ""; then
4456      am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4457   fi
4458   for depmode in $am_compiler_list; do
4459     if test $depmode = none; then break; fi
4460
4461     $as_echo "$as_me:$LINENO: trying $depmode" >&5
4462     # Setup a source with many dependencies, because some compilers
4463     # like to wrap large dependency lists on column 80 (with \), and
4464     # we should not choose a depcomp mode which is confused by this.
4465     #
4466     # We need to recreate these files for each test, as the compiler may
4467     # overwrite some of them when testing with obscure command lines.
4468     # This happens at least with the AIX C compiler.
4469     : > sub/conftest.c
4470     for i in 1 2 3 4 5 6; do
4471       echo '#include "conftst'$i'.h"' >> sub/conftest.c
4472       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4473       # Solaris 8's {/usr,}/bin/sh.
4474       touch sub/conftst$i.h
4475     done
4476     echo "include sub/conftest.Po" > confmf
4477
4478     # We check with `-c' and `-o' for the sake of the "dashmstdout"
4479     # mode.  It turns out that the SunPro C++ compiler does not properly
4480     # handle `-M -o', and we need to detect this.
4481     depcmd="depmode=$depmode \
4482        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
4483        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4484        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
4485     echo "| $depcmd" | sed -e 's/  */ /g' >&5
4486     if env $depcmd > conftest.err 2>&1 &&
4487        grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
4488        grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
4489        ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
4490       # icc doesn't choke on unknown options, it will just issue warnings
4491       # or remarks (even with -Werror).  So we grep stderr for any message
4492       # that says an option was ignored or not supported.
4493       # When given -MP, icc 7.0 and 7.1 complain thusly:
4494       #   icc: Command line warning: ignoring option '-M'; no argument required
4495       # The diagnosis changed in icc 8.0:
4496       #   icc: Command line remark: option '-MP' not supported
4497       if (grep 'ignoring option' conftest.err ||
4498           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4499         am_cv_CC_dependencies_compiler_type=$depmode
4500         $as_echo "$as_me:$LINENO: success" >&5
4501         break
4502       fi
4503     fi
4504     $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
4505     sed -e 's/^/| /' < conftest.err >&5
4506   done
4507
4508   cd ..
4509   rm -rf conftest.dir
4510 else
4511   am_cv_CC_dependencies_compiler_type=none
4512 fi
4513
4514 fi
4515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4516 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4517 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
4518 then as_fn_error "no usable dependency style found" "$LINENO" 5
4519 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4520
4521 fi
4522
4523
4524 # Check for the 'make' the user wants to use.
4525 for ac_prog in make
4526 do
4527   # Extract the first word of "$ac_prog", so it can be a program name with args.
4528 set dummy $ac_prog; ac_word=$2
4529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4530 $as_echo_n "checking for $ac_word... " >&6; }
4531 if test "${ac_cv_prog_MAKE+set}" = set; then :
4532   $as_echo_n "(cached) " >&6
4533 else
4534   if test -n "$MAKE"; then
4535   ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
4536 else
4537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4538 for as_dir in $PATH
4539 do
4540   IFS=$as_save_IFS
4541   test -z "$as_dir" && as_dir=.
4542     for ac_exec_ext in '' $ac_executable_extensions; do
4543   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4544     ac_cv_prog_MAKE="$ac_prog"
4545     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4546     break 2
4547   fi
4548 done
4549   done
4550 IFS=$as_save_IFS
4551
4552 fi
4553 fi
4554 MAKE=$ac_cv_prog_MAKE
4555 if test -n "$MAKE"; then
4556   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
4557 $as_echo "$MAKE" >&6; }
4558 else
4559   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4560 $as_echo "no" >&6; }
4561 fi
4562
4563
4564   test -n "$MAKE" && break
4565 done
4566
4567 MAKE_IS_GNU=
4568 case "`$MAKE --version 2>&1 | sed 1q`" in
4569   *GNU*)
4570     MAKE_IS_GNU=yes
4571     ;;
4572 esac
4573  if test "$MAKE_IS_GNU" = yes; then
4574   GMAKE_TRUE=
4575   GMAKE_FALSE='#'
4576 else
4577   GMAKE_TRUE='#'
4578   GMAKE_FALSE=
4579 fi
4580
4581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
4582 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
4583 set x ${MAKE-make}
4584 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
4585 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
4586   $as_echo_n "(cached) " >&6
4587 else
4588   cat >conftest.make <<\_ACEOF
4589 SHELL = /bin/sh
4590 all:
4591         @echo '@@@%%%=$(MAKE)=@@@%%%'
4592 _ACEOF
4593 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
4594 case `${MAKE-make} -f conftest.make 2>/dev/null` in
4595   *@@@%%%=?*=@@@%%%*)
4596     eval ac_cv_prog_make_${ac_make}_set=yes;;
4597   *)
4598     eval ac_cv_prog_make_${ac_make}_set=no;;
4599 esac
4600 rm -f conftest.make
4601 fi
4602 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
4603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4604 $as_echo "yes" >&6; }
4605   SET_MAKE=
4606 else
4607   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4608 $as_echo "no" >&6; }
4609   SET_MAKE="MAKE=${MAKE-make}"
4610 fi
4611
4612
4613 # Configure gnulib.  We need to build gnulib under some other
4614 # directory not "gnulib", to avoid the problem of both GDB and
4615 # GDBserver wanting to build it in the same directory, when building
4616 # in the source dir.
4617
4618   in_src="gnulib"
4619   in_build="build-gnulib"
4620
4621   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
4622   # so they do not pile up.
4623   ac_sub_configure_args=
4624   ac_prev=
4625   eval "set x $ac_configure_args"
4626   shift
4627   for ac_arg
4628   do
4629     if test -n "$ac_prev"; then
4630       ac_prev=
4631       continue
4632     fi
4633     case $ac_arg in
4634     -cache-file | --cache-file | --cache-fil | --cache-fi \
4635     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
4636       ac_prev=cache_file ;;
4637     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
4638     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
4639     | --c=*)
4640       ;;
4641     --config-cache | -C)
4642       ;;
4643     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
4644       ac_prev=srcdir ;;
4645     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
4646       ;;
4647     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
4648       ac_prev=prefix ;;
4649     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
4650       ;;
4651     --disable-option-checking)
4652       ;;
4653     *)
4654       case $ac_arg in
4655       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
4656       esac
4657       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
4658     esac
4659   done
4660
4661   # Always prepend --prefix to ensure using the same prefix
4662   # in subdir configurations.
4663   ac_arg="--prefix=$prefix"
4664   case $ac_arg in
4665   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
4666   esac
4667   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
4668
4669   # Pass --silent
4670   if test "$silent" = yes; then
4671     ac_sub_configure_args="--silent $ac_sub_configure_args"
4672   fi
4673
4674   # Always prepend --disable-option-checking to silence warnings, since
4675   # different subdirs can have different --enable and --with options.
4676   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
4677
4678   ac_popdir=`pwd`
4679   ac_dir=$in_build
4680
4681   ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
4682   $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
4683   $as_echo "$ac_msg" >&6
4684   as_dir="$ac_dir"; as_fn_mkdir_p
4685
4686   case $srcdir in
4687   [\\/]* | ?:[\\/]* )
4688     ac_srcdir=$srcdir/$in_src ;;
4689   *) # Relative name.
4690     ac_srcdir=../$srcdir/$in_src ;;
4691   esac
4692
4693   cd "$ac_dir"
4694
4695   ac_sub_configure=$ac_srcdir/configure
4696
4697   # Make the cache file name correct relative to the subdirectory.
4698   case $cache_file in
4699   [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
4700   *) # Relative name.
4701     ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
4702   esac
4703
4704   { $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
4705 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
4706   # The eval makes quoting arguments work.
4707   eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
4708        --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
4709     as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
4710
4711   cd "$ac_popdir"
4712
4713
4714
4715 CONFIG_OBS=
4716 CONFIG_DEPS=
4717 CONFIG_SRCS=
4718 ENABLE_CFLAGS=
4719
4720 CONFIG_ALL=
4721 CONFIG_CLEAN=
4722 CONFIG_INSTALL=
4723 CONFIG_UNINSTALL=
4724
4725 # If we haven't got the data from the intl directory,
4726 # assume NLS is disabled.
4727 USE_NLS=no
4728 LIBINTL=
4729 LIBINTL_DEP=
4730 INCINTL=
4731 XGETTEXT=
4732 GMSGFMT=
4733 POSUB=
4734
4735 if test -f  ../intl/config.intl; then
4736   .  ../intl/config.intl
4737 fi
4738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
4739 $as_echo_n "checking whether NLS is requested... " >&6; }
4740 if test x"$USE_NLS" != xyes; then
4741   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4742 $as_echo "no" >&6; }
4743 else
4744   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4745 $as_echo "yes" >&6; }
4746
4747 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
4748
4749
4750   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
4751 $as_echo_n "checking for catalogs to be installed... " >&6; }
4752   # Look for .po and .gmo files in the source directory.
4753   CATALOGS=
4754   XLINGUAS=
4755   for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
4756     # If there aren't any .gmo files the shell will give us the
4757     # literal string "../path/to/srcdir/po/*.gmo" which has to be
4758     # weeded out.
4759     case "$cat" in *\**)
4760       continue;;
4761     esac
4762     # The quadruple backslash is collapsed to a double backslash
4763     # by the backticks, then collapsed again by the double quotes,
4764     # leaving us with one backslash in the sed expression (right
4765     # before the dot that mustn't act as a wildcard).
4766     cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
4767     lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
4768     # The user is allowed to set LINGUAS to a list of languages to
4769     # install catalogs for.  If it's empty that means "all of them."
4770     if test "x$LINGUAS" = x; then
4771       CATALOGS="$CATALOGS $cat"
4772       XLINGUAS="$XLINGUAS $lang"
4773     else
4774       case "$LINGUAS" in *$lang*)
4775         CATALOGS="$CATALOGS $cat"
4776         XLINGUAS="$XLINGUAS $lang"
4777         ;;
4778       esac
4779     fi
4780   done
4781   LINGUAS="$XLINGUAS"
4782   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
4783 $as_echo "$LINGUAS" >&6; }
4784
4785
4786     DATADIRNAME=share
4787
4788   INSTOBJEXT=.mo
4789
4790   GENCAT=gencat
4791
4792   CATOBJEXT=.gmo
4793
4794 fi
4795
4796 localedir='${datadir}/locale'
4797
4798
4799 if test x"$USE_NLS" = xyes; then
4800    CONFIG_ALL="$CONFIG_ALL all-po"
4801    CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
4802    CONFIG_INSTALL="$CONFIG_INSTALL install-po"
4803    CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
4804 fi
4805
4806 GNULIB=build-gnulib/import
4807
4808 # For Makefile dependencies.
4809 GNULIB_STDINT_H=
4810 if test x"$STDINT_H" != x; then
4811   GNULIB_STDINT_H=$GNULIB/$STDINT_H
4812 fi
4813
4814
4815 PACKAGE=gdb
4816
4817 cat >>confdefs.h <<_ACEOF
4818 #define PACKAGE "$PACKAGE"
4819 _ACEOF
4820
4821
4822
4823 # We never need to detect it in this sub-configure.
4824 # But preserve it for config.status --recheck.
4825
4826
4827
4828 MAKEINFO_EXTRA_FLAGS=""
4829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
4830 $as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
4831 if test "${gdb_cv_have_makeinfo_click+set}" = set; then :
4832   $as_echo_n "(cached) " >&6
4833 else
4834   echo '@clicksequence{a @click{} b}' >conftest.texinfo
4835   if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
4836     gdb_cv_have_makeinfo_click=yes
4837   else
4838     gdb_cv_have_makeinfo_click=no
4839   fi
4840 fi
4841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
4842 $as_echo "$gdb_cv_have_makeinfo_click" >&6; }
4843 if test x"$gdb_cv_have_makeinfo_click" = xyes; then
4844   MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
4845 fi
4846
4847
4848
4849
4850 # Check whether --with-separate-debug-dir was given.
4851 if test "${with_separate_debug_dir+set}" = set; then :
4852   withval=$with_separate_debug_dir;
4853     DEBUGDIR=$withval
4854 else
4855   DEBUGDIR=${libdir}/debug
4856 fi
4857
4858
4859   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4860   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4861   ac_define_dir=`eval echo $DEBUGDIR`
4862   ac_define_dir=`eval echo $ac_define_dir`
4863
4864 cat >>confdefs.h <<_ACEOF
4865 #define DEBUGDIR "$ac_define_dir"
4866 _ACEOF
4867
4868
4869
4870
4871   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
4872      if test "x$prefix" = xNONE; then
4873         test_prefix=/usr/local
4874      else
4875         test_prefix=$prefix
4876      fi
4877   else
4878      test_prefix=$exec_prefix
4879   fi
4880   value=0
4881   case ${ac_define_dir} in
4882      "${test_prefix}"|"${test_prefix}/"*|\
4883         '${exec_prefix}'|'${exec_prefix}/'*)
4884      value=1
4885      ;;
4886   esac
4887
4888 cat >>confdefs.h <<_ACEOF
4889 #define DEBUGDIR_RELOCATABLE $value
4890 _ACEOF
4891
4892
4893
4894
4895 # We can't pass paths as command line arguments.
4896 # Mingw32 tries to be clever and will convert the paths for us.
4897 # For example -DBINDIR="/usr/local/bin" passed on the command line may get
4898 # converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
4899 # This breaks GDB's relocatable path conversions since paths passed in
4900 # config.h would not get so translated, the path prefixes no longer match.
4901
4902   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4903   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4904   ac_define_dir=`eval echo $bindir`
4905   ac_define_dir=`eval echo $ac_define_dir`
4906
4907 cat >>confdefs.h <<_ACEOF
4908 #define BINDIR "$ac_define_dir"
4909 _ACEOF
4910
4911
4912
4913 # GDB's datadir relocation
4914
4915
4916
4917 # Check whether --with-gdb-datadir was given.
4918 if test "${with_gdb_datadir+set}" = set; then :
4919   withval=$with_gdb_datadir;
4920     GDB_DATADIR=$withval
4921 else
4922   GDB_DATADIR=${datadir}/gdb
4923 fi
4924
4925
4926   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4927   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4928   ac_define_dir=`eval echo $GDB_DATADIR`
4929   ac_define_dir=`eval echo $ac_define_dir`
4930
4931 cat >>confdefs.h <<_ACEOF
4932 #define GDB_DATADIR "$ac_define_dir"
4933 _ACEOF
4934
4935
4936
4937
4938   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
4939      if test "x$prefix" = xNONE; then
4940         test_prefix=/usr/local
4941      else
4942         test_prefix=$prefix
4943      fi
4944   else
4945      test_prefix=$exec_prefix
4946   fi
4947   value=0
4948   case ${ac_define_dir} in
4949      "${test_prefix}"|"${test_prefix}/"*|\
4950         '${exec_prefix}'|'${exec_prefix}/'*)
4951      value=1
4952      ;;
4953   esac
4954
4955 cat >>confdefs.h <<_ACEOF
4956 #define GDB_DATADIR_RELOCATABLE $value
4957 _ACEOF
4958
4959
4960
4961
4962
4963 # Check whether --with-relocated-sources was given.
4964 if test "${with_relocated_sources+set}" = set; then :
4965   withval=$with_relocated_sources; reloc_srcdir="${withval}"
4966
4967   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4968   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4969   ac_define_dir=`eval echo $reloc_srcdir`
4970   ac_define_dir=`eval echo $ac_define_dir`
4971
4972 cat >>confdefs.h <<_ACEOF
4973 #define RELOC_SRCDIR "$ac_define_dir"
4974 _ACEOF
4975
4976
4977
4978 fi
4979
4980
4981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
4982 $as_echo_n "checking for default auto-load directory... " >&6; }
4983
4984 # Check whether --with-auto-load-dir was given.
4985 if test "${with_auto_load_dir+set}" = set; then :
4986   withval=$with_auto_load_dir;
4987 else
4988   with_auto_load_dir='$debugdir:$datadir/auto-load'
4989 fi
4990
4991 escape_dir=`echo $with_auto_load_dir | sed 's/[$]\(datadir\|debugdir\)\>/\\\\\\\\\\\\&/g'`
4992
4993   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
4994   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4995   ac_define_dir=`eval echo $escape_dir`
4996   ac_define_dir=`eval echo $ac_define_dir`
4997
4998 cat >>confdefs.h <<_ACEOF
4999 #define AUTO_LOAD_DIR "$ac_define_dir"
5000 _ACEOF
5001
5002
5003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
5004 $as_echo "$with_auto_load_dir" >&6; }
5005
5006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
5007 $as_echo_n "checking for default auto-load safe-path... " >&6; }
5008
5009 # Check whether --with-auto-load-safe-path was given.
5010 if test "${with_auto_load_safe_path+set}" = set; then :
5011   withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
5012      with_auto_load_safe_path="/"
5013      fi
5014 else
5015   with_auto_load_safe_path="$with_auto_load_dir"
5016 fi
5017
5018 escape_dir=`echo $with_auto_load_safe_path | sed 's/[$]\(datadir\|debugdir\)\>/\\\\\\\\\\\\&/g'`
5019
5020   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
5021   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5022   ac_define_dir=`eval echo $escape_dir`
5023   ac_define_dir=`eval echo $ac_define_dir`
5024
5025 cat >>confdefs.h <<_ACEOF
5026 #define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
5027 _ACEOF
5028
5029
5030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
5031 $as_echo "$with_auto_load_safe_path" >&6; }
5032
5033
5034
5035 subdirs="$subdirs testsuite"
5036
5037
5038 # Check whether to support alternative target configurations
5039 # Check whether --enable-targets was given.
5040 if test "${enable_targets+set}" = set; then :
5041   enableval=$enable_targets; case "${enableval}" in
5042   yes | "") as_fn_error "enable-targets option must specify target names or 'all'" "$LINENO" 5
5043             ;;
5044   no)       enable_targets= ;;
5045   *)        enable_targets=$enableval ;;
5046 esac
5047 fi
5048
5049
5050 # Check whether to enable 64-bit support on 32-bit hosts
5051 # Check whether --enable-64-bit-bfd was given.
5052 if test "${enable_64_bit_bfd+set}" = set; then :
5053   enableval=$enable_64_bit_bfd; case "${enableval}" in
5054   yes)  want64=true  ;;
5055   no)   want64=false ;;
5056   *)    as_fn_error "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
5057 esac
5058 else
5059   want64=false
5060 fi
5061
5062 # Provide defaults for some variables set by the per-host and per-target
5063 # configuration.
5064 gdb_host_obs=posix-hdep.o
5065
5066 if test "${target}" = "${host}"; then
5067   gdb_native=yes
5068 else
5069   gdb_native=no
5070 fi
5071
5072 . $srcdir/configure.host
5073
5074 # Accumulate some settings from configure.tgt over all enabled targets
5075
5076 TARGET_OBS=
5077 all_targets=
5078
5079 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
5080 do
5081   if test "$targ_alias" = "all"; then
5082     all_targets=true
5083   else
5084     # Canonicalize the secondary target names.
5085     result=`$ac_config_sub $targ_alias 2>/dev/null`
5086     if test -n "$result"; then
5087         targ=$result
5088     else
5089         targ=$targ_alias
5090     fi
5091
5092     . ${srcdir}/configure.tgt
5093
5094     if test -z "${gdb_target_obs}"; then :
5095   as_fn_error "configuration ${targ} is unsupported." "$LINENO" 5
5096 fi
5097
5098     # Target-specific object files
5099     for i in ${gdb_target_obs}; do
5100         case " $TARGET_OBS " in
5101         *" ${i} "*) ;;
5102         *)
5103           TARGET_OBS="$TARGET_OBS ${i}"
5104           ;;
5105         esac
5106     done
5107
5108     # Check whether this target needs 64-bit CORE_ADDR
5109     if test x${want64} = xfalse; then
5110       . ${srcdir}/../bfd/config.bfd
5111     fi
5112   fi
5113 done
5114
5115 if test x${all_targets} = xtrue; then
5116
5117   # We want all 64-bit targets if we either:
5118   #  - run on a 64-bit host  or
5119   #  - already require 64-bit support for some other target  or
5120   #  - the --enable-64-bit-bfd option was supplied
5121   # Otherwise we only support all 32-bit targets.
5122   #
5123   # NOTE: This test must be in sync with the corresponding
5124   #       tests in BFD!
5125
5126   if test x${want64} = xfalse; then
5127     # The cast to long int works around a bug in the HP C Compiler
5128 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5129 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5130 # This bug is HP SR number 8606223364.
5131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
5132 $as_echo_n "checking size of long... " >&6; }
5133 if test "${ac_cv_sizeof_long+set}" = set; then :
5134   $as_echo_n "(cached) " >&6
5135 else
5136   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
5137
5138 else
5139   if test "$ac_cv_type_long" = yes; then
5140      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5141 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5142 { as_fn_set_status 77
5143 as_fn_error "cannot compute sizeof (long)
5144 See \`config.log' for more details." "$LINENO" 5; }; }
5145    else
5146      ac_cv_sizeof_long=0
5147    fi
5148 fi
5149
5150 fi
5151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
5152 $as_echo "$ac_cv_sizeof_long" >&6; }
5153
5154
5155
5156 cat >>confdefs.h <<_ACEOF
5157 #define SIZEOF_LONG $ac_cv_sizeof_long
5158 _ACEOF
5159
5160
5161     if test "x${ac_cv_sizeof_long}" = "x8"; then
5162       want64=true
5163     fi
5164   fi
5165   if test x${want64} = xtrue; then
5166     TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
5167   else
5168     TARGET_OBS='$(ALL_TARGET_OBS)'
5169   fi
5170 fi
5171
5172
5173
5174 # For other settings, only the main target counts.
5175 gdb_sim=
5176 gdb_osabi=
5177 build_gdbserver=
5178 targ=$target; . ${srcdir}/configure.tgt
5179
5180 # Fetch the default architecture and default target vector from BFD.
5181 targ=$target; . $srcdir/../bfd/config.bfd
5182
5183 # We only want the first architecture, so strip off the others if
5184 # there is more than one.
5185 targ_archs=`echo $targ_archs | sed 's/ .*//'`
5186
5187 if test "x$targ_archs" != x; then
5188
5189 cat >>confdefs.h <<_ACEOF
5190 #define DEFAULT_BFD_ARCH $targ_archs
5191 _ACEOF
5192
5193 fi
5194 if test "x$targ_defvec" != x; then
5195
5196 cat >>confdefs.h <<_ACEOF
5197 #define DEFAULT_BFD_VEC $targ_defvec
5198 _ACEOF
5199
5200 fi
5201
5202 # The CLI cannot be disabled yet, but may be in the future.
5203
5204 # Enable CLI.
5205 # Check whether --enable-gdbcli was given.
5206 if test "${enable_gdbcli+set}" = set; then :
5207   enableval=$enable_gdbcli; case $enableval in
5208     yes)
5209       ;;
5210     no)
5211       as_fn_error "the command-line interface cannot be disabled yet" "$LINENO" 5 ;;
5212     *)
5213       as_fn_error "bad value $enableval for --enable-gdbcli" "$LINENO" 5 ;;
5214   esac
5215 else
5216   enable_gdbcli=yes
5217 fi
5218
5219 if test x"$enable_gdbcli" = xyes; then
5220   if test -d $srcdir/cli; then
5221     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_CLI_OBS)"
5222     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_CLI_DEPS)"
5223     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_CLI_SRCS)"
5224     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_CLI_CFLAGS)"
5225   fi
5226 fi
5227
5228 # Enable MI.
5229 # Check whether --enable-gdbmi was given.
5230 if test "${enable_gdbmi+set}" = set; then :
5231   enableval=$enable_gdbmi; case $enableval in
5232     yes | no)
5233       ;;
5234     *)
5235       as_fn_error "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
5236   esac
5237 else
5238   enable_gdbmi=yes
5239 fi
5240
5241 if test x"$enable_gdbmi" = xyes; then
5242   if test -d $srcdir/mi; then
5243     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
5244     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
5245     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
5246     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
5247   fi
5248 fi
5249
5250 # Enable TUI.
5251 # Check whether --enable-tui was given.
5252 if test "${enable_tui+set}" = set; then :
5253   enableval=$enable_tui; case $enableval in
5254     yes | no | auto)
5255       ;;
5256     *)
5257       as_fn_error "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
5258   esac
5259 else
5260   enable_tui=auto
5261 fi
5262
5263
5264 # Enable gdbtk.
5265 # Check whether --enable-gdbtk was given.
5266 if test "${enable_gdbtk+set}" = set; then :
5267   enableval=$enable_gdbtk; case $enableval in
5268     yes | no)
5269       ;;
5270     *)
5271       as_fn_error "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
5272   esac
5273 else
5274   if test -d $srcdir/gdbtk; then
5275     enable_gdbtk=yes
5276   else
5277     enable_gdbtk=no
5278   fi
5279 fi
5280
5281 # We unconditionally disable gdbtk tests on selected platforms.
5282 case $host_os in
5283   go32* | windows*)
5284     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
5285 $as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
5286     enable_gdbtk=no ;;
5287 esac
5288
5289 # Libunwind support for ia64.
5290
5291
5292 # Check whether --with-libunwind-ia64 was given.
5293 if test "${with_libunwind_ia64+set}" = set; then :
5294   withval=$with_libunwind_ia64;
5295 else
5296   with_libunwind_ia64=auto
5297 fi
5298
5299
5300 # Backward compatibility option.
5301 if test "${with_libunwind+set}" = set; then
5302   if test x"$with_libunwind_ia64" != xauto; then
5303     as_fn_error "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
5304   fi
5305   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
5306 $as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
5307   with_libunwind_ia64="$with_libunwind"
5308 fi
5309
5310 case "$with_libunwind_ia64" in
5311   yes | no)
5312     ;;
5313   auto)
5314     for ac_header in libunwind-ia64.h
5315 do :
5316   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
5317 if test "x$ac_cv_header_libunwind_ia64_h" = x""yes; then :
5318   cat >>confdefs.h <<_ACEOF
5319 #define HAVE_LIBUNWIND_IA64_H 1
5320 _ACEOF
5321
5322 fi
5323
5324 done
5325
5326     with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
5327     ;;
5328   *)
5329     as_fn_error "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
5330     ;;
5331 esac
5332
5333 if test x"$with_libunwind_ia64" = xyes; then
5334   for ac_header in libunwind-ia64.h
5335 do :
5336   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
5337 if test "x$ac_cv_header_libunwind_ia64_h" = x""yes; then :
5338   cat >>confdefs.h <<_ACEOF
5339 #define HAVE_LIBUNWIND_IA64_H 1
5340 _ACEOF
5341
5342 fi
5343
5344 done
5345
5346   if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
5347     as_fn_error "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
5348   fi
5349   CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
5350   CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
5351   CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
5352 fi
5353
5354 opt_curses=no
5355
5356 # Check whether --with-curses was given.
5357 if test "${with_curses+set}" = set; then :
5358   withval=$with_curses; opt_curses=$withval
5359 fi
5360
5361
5362 prefer_curses=no
5363 if test "$opt_curses" = "yes"; then
5364   prefer_curses=yes
5365 fi
5366
5367 # Profiling support.
5368 # Check whether --enable-profiling was given.
5369 if test "${enable_profiling+set}" = set; then :
5370   enableval=$enable_profiling; case $enableval in
5371     yes | no)
5372       ;;
5373     *)
5374       as_fn_error "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
5375   esac
5376 else
5377   enable_profiling=no
5378 fi
5379
5380
5381 for ac_func in monstartup _mcleanup
5382 do :
5383   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
5384 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
5385 eval as_val=\$$as_ac_var
5386    if test "x$as_val" = x""yes; then :
5387   cat >>confdefs.h <<_ACEOF
5388 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
5389 _ACEOF
5390
5391 fi
5392 done
5393
5394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
5395 $as_echo_n "checking for _etext... " >&6; }
5396 if test "${ac_cv_var__etext+set}" = set; then :
5397   $as_echo_n "(cached) " >&6
5398 else
5399   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5400 /* end confdefs.h.  */
5401 #include <stdlib.h>
5402 extern char _etext;
5403
5404 int
5405 main ()
5406 {
5407 free (&_etext);
5408   ;
5409   return 0;
5410 }
5411 _ACEOF
5412 if ac_fn_c_try_link "$LINENO"; then :
5413   ac_cv_var__etext=yes
5414 else
5415   ac_cv_var__etext=no
5416 fi
5417 rm -f core conftest.err conftest.$ac_objext \
5418     conftest$ac_exeext conftest.$ac_ext
5419 fi
5420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
5421 $as_echo "$ac_cv_var__etext" >&6; }
5422 if test $ac_cv_var__etext = yes; then
5423
5424 $as_echo "#define HAVE__ETEXT 1" >>confdefs.h
5425
5426 fi
5427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
5428 $as_echo_n "checking for etext... " >&6; }
5429 if test "${ac_cv_var_etext+set}" = set; then :
5430   $as_echo_n "(cached) " >&6
5431 else
5432   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5433 /* end confdefs.h.  */
5434 #include <stdlib.h>
5435 extern char etext;
5436
5437 int
5438 main ()
5439 {
5440 free (&etext);
5441   ;
5442   return 0;
5443 }
5444 _ACEOF
5445 if ac_fn_c_try_link "$LINENO"; then :
5446   ac_cv_var_etext=yes
5447 else
5448   ac_cv_var_etext=no
5449 fi
5450 rm -f core conftest.err conftest.$ac_objext \
5451     conftest$ac_exeext conftest.$ac_ext
5452 fi
5453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
5454 $as_echo "$ac_cv_var_etext" >&6; }
5455 if test $ac_cv_var_etext = yes; then
5456
5457 $as_echo "#define HAVE_ETEXT 1" >>confdefs.h
5458
5459 fi
5460 if test "$enable_profiling" = yes ; then
5461   if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
5462     as_fn_error "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
5463   fi
5464   PROFILE_CFLAGS=-pg
5465   OLD_CFLAGS="$CFLAGS"
5466   CFLAGS="$CFLAGS $PROFILE_CFLAGS"
5467
5468   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
5469 $as_echo_n "checking whether $CC supports -pg... " >&6; }
5470 if test "${ac_cv_cc_supports_pg+set}" = set; then :
5471   $as_echo_n "(cached) " >&6
5472 else
5473   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5474 /* end confdefs.h.  */
5475
5476 int
5477 main ()
5478 {
5479 int x;
5480   ;
5481   return 0;
5482 }
5483 _ACEOF
5484 if ac_fn_c_try_compile "$LINENO"; then :
5485   ac_cv_cc_supports_pg=yes
5486 else
5487   ac_cv_cc_supports_pg=no
5488 fi
5489 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5490 fi
5491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
5492 $as_echo "$ac_cv_cc_supports_pg" >&6; }
5493
5494   if test $ac_cv_cc_supports_pg = no; then
5495     as_fn_error "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
5496   fi
5497
5498   CFLAGS="$OLD_CFLAGS"
5499 fi
5500
5501
5502
5503 # Check whether --with-pkgversion was given.
5504 if test "${with_pkgversion+set}" = set; then :
5505   withval=$with_pkgversion; case "$withval" in
5506       yes) as_fn_error "package version not specified" "$LINENO" 5 ;;
5507       no)  PKGVERSION= ;;
5508       *)   PKGVERSION="($withval) " ;;
5509      esac
5510 else
5511   PKGVERSION="(GDB) "
5512
5513 fi
5514
5515
5516
5517
5518
5519 # Check whether --with-bugurl was given.
5520 if test "${with_bugurl+set}" = set; then :
5521   withval=$with_bugurl; case "$withval" in
5522       yes) as_fn_error "bug URL not specified" "$LINENO" 5 ;;
5523       no)  BUGURL=
5524            ;;
5525       *)   BUGURL="$withval"
5526            ;;
5527      esac
5528 else
5529   BUGURL="http://www.gnu.org/software/gdb/bugs/"
5530
5531 fi
5532
5533   case ${BUGURL} in
5534   "")
5535     REPORT_BUGS_TO=
5536     REPORT_BUGS_TEXI=
5537     ;;
5538   *)
5539     REPORT_BUGS_TO="<$BUGURL>"
5540     REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
5541     ;;
5542   esac;
5543
5544
5545
5546
5547 cat >>confdefs.h <<_ACEOF
5548 #define PKGVERSION "$PKGVERSION"
5549 _ACEOF
5550
5551
5552 cat >>confdefs.h <<_ACEOF
5553 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
5554 _ACEOF
5555
5556
5557 # --------------------- #
5558 # Checks for programs.  #
5559 # --------------------- #
5560
5561 for ac_prog in gawk mawk nawk awk
5562 do
5563   # Extract the first word of "$ac_prog", so it can be a program name with args.
5564 set dummy $ac_prog; ac_word=$2
5565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5566 $as_echo_n "checking for $ac_word... " >&6; }
5567 if test "${ac_cv_prog_AWK+set}" = set; then :
5568   $as_echo_n "(cached) " >&6
5569 else
5570   if test -n "$AWK"; then
5571   ac_cv_prog_AWK="$AWK" # Let the user override the test.
5572 else
5573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5574 for as_dir in $PATH
5575 do
5576   IFS=$as_save_IFS
5577   test -z "$as_dir" && as_dir=.
5578     for ac_exec_ext in '' $ac_executable_extensions; do
5579   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5580     ac_cv_prog_AWK="$ac_prog"
5581     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5582     break 2
5583   fi
5584 done
5585   done
5586 IFS=$as_save_IFS
5587
5588 fi
5589 fi
5590 AWK=$ac_cv_prog_AWK
5591 if test -n "$AWK"; then
5592   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
5593 $as_echo "$AWK" >&6; }
5594 else
5595   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5596 $as_echo "no" >&6; }
5597 fi
5598
5599
5600   test -n "$AWK" && break
5601 done
5602
5603 # Find a good install program.  We prefer a C program (faster),
5604 # so one script is as good as another.  But avoid the broken or
5605 # incompatible versions:
5606 # SysV /etc/install, /usr/sbin/install
5607 # SunOS /usr/etc/install
5608 # IRIX /sbin/install
5609 # AIX /bin/install
5610 # AmigaOS /C/install, which installs bootblocks on floppy discs
5611 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
5612 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
5613 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
5614 # OS/2's system install, which has a completely different semantic
5615 # ./install, which can be erroneously created by make from ./install.sh.
5616 # Reject install programs that cannot install multiple files.
5617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
5618 $as_echo_n "checking for a BSD-compatible install... " >&6; }
5619 if test -z "$INSTALL"; then
5620 if test "${ac_cv_path_install+set}" = set; then :
5621   $as_echo_n "(cached) " >&6
5622 else
5623   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5624 for as_dir in $PATH
5625 do
5626   IFS=$as_save_IFS
5627   test -z "$as_dir" && as_dir=.
5628     # Account for people who put trailing slashes in PATH elements.
5629 case $as_dir/ in #((
5630   ./ | .// | /[cC]/* | \
5631   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5632   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
5633   /usr/ucb/* ) ;;
5634   *)
5635     # OSF1 and SCO ODT 3.0 have their own names for install.
5636     # Don't use installbsd from OSF since it installs stuff as root
5637     # by default.
5638     for ac_prog in ginstall scoinst install; do
5639       for ac_exec_ext in '' $ac_executable_extensions; do
5640         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
5641           if test $ac_prog = install &&
5642             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5643             # AIX install.  It has an incompatible calling convention.
5644             :
5645           elif test $ac_prog = install &&
5646             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5647             # program-specific install script used by HP pwplus--don't use.
5648             :
5649           else
5650             rm -rf conftest.one conftest.two conftest.dir
5651             echo one > conftest.one
5652             echo two > conftest.two
5653             mkdir conftest.dir
5654             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5655               test -s conftest.one && test -s conftest.two &&
5656               test -s conftest.dir/conftest.one &&
5657               test -s conftest.dir/conftest.two
5658             then
5659               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5660               break 3
5661             fi
5662           fi
5663         fi
5664       done
5665     done
5666     ;;
5667 esac
5668
5669   done
5670 IFS=$as_save_IFS
5671
5672 rm -rf conftest.one conftest.two conftest.dir
5673
5674 fi
5675   if test "${ac_cv_path_install+set}" = set; then
5676     INSTALL=$ac_cv_path_install
5677   else
5678     # As a last resort, use the slow shell script.  Don't cache a
5679     # value for INSTALL within a source directory, because that will
5680     # break other packages using the cache if that directory is
5681     # removed, or if the value is a relative name.
5682     INSTALL=$ac_install_sh
5683   fi
5684 fi
5685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5686 $as_echo "$INSTALL" >&6; }
5687
5688 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5689 # It thinks the first close brace ends the variable substitution.
5690 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5691
5692 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5693
5694 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5695
5696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5697 $as_echo_n "checking whether ln -s works... " >&6; }
5698 LN_S=$as_ln_s
5699 if test "$LN_S" = "ln -s"; then
5700   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5701 $as_echo "yes" >&6; }
5702 else
5703   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5704 $as_echo "no, using $LN_S" >&6; }
5705 fi
5706
5707 if test -n "$ac_tool_prefix"; then
5708   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5709 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5711 $as_echo_n "checking for $ac_word... " >&6; }
5712 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5713   $as_echo_n "(cached) " >&6
5714 else
5715   if test -n "$RANLIB"; then
5716   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5717 else
5718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5719 for as_dir in $PATH
5720 do
5721   IFS=$as_save_IFS
5722   test -z "$as_dir" && as_dir=.
5723     for ac_exec_ext in '' $ac_executable_extensions; do
5724   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5725     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5726     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5727     break 2
5728   fi
5729 done
5730   done
5731 IFS=$as_save_IFS
5732
5733 fi
5734 fi
5735 RANLIB=$ac_cv_prog_RANLIB
5736 if test -n "$RANLIB"; then
5737   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5738 $as_echo "$RANLIB" >&6; }
5739 else
5740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5741 $as_echo "no" >&6; }
5742 fi
5743
5744
5745 fi
5746 if test -z "$ac_cv_prog_RANLIB"; then
5747   ac_ct_RANLIB=$RANLIB
5748   # Extract the first word of "ranlib", so it can be a program name with args.
5749 set dummy ranlib; ac_word=$2
5750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5751 $as_echo_n "checking for $ac_word... " >&6; }
5752 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5753   $as_echo_n "(cached) " >&6
5754 else
5755   if test -n "$ac_ct_RANLIB"; then
5756   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5757 else
5758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5759 for as_dir in $PATH
5760 do
5761   IFS=$as_save_IFS
5762   test -z "$as_dir" && as_dir=.
5763     for ac_exec_ext in '' $ac_executable_extensions; do
5764   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5765     ac_cv_prog_ac_ct_RANLIB="ranlib"
5766     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5767     break 2
5768   fi
5769 done
5770   done
5771 IFS=$as_save_IFS
5772
5773 fi
5774 fi
5775 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5776 if test -n "$ac_ct_RANLIB"; then
5777   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5778 $as_echo "$ac_ct_RANLIB" >&6; }
5779 else
5780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5781 $as_echo "no" >&6; }
5782 fi
5783
5784   if test "x$ac_ct_RANLIB" = x; then
5785     RANLIB=":"
5786   else
5787     case $cross_compiling:$ac_tool_warned in
5788 yes:)
5789 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5790 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5791 ac_tool_warned=yes ;;
5792 esac
5793     RANLIB=$ac_ct_RANLIB
5794   fi
5795 else
5796   RANLIB="$ac_cv_prog_RANLIB"
5797 fi
5798
5799 for ac_prog in 'bison -y' byacc
5800 do
5801   # Extract the first word of "$ac_prog", so it can be a program name with args.
5802 set dummy $ac_prog; ac_word=$2
5803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5804 $as_echo_n "checking for $ac_word... " >&6; }
5805 if test "${ac_cv_prog_YACC+set}" = set; then :
5806   $as_echo_n "(cached) " >&6
5807 else
5808   if test -n "$YACC"; then
5809   ac_cv_prog_YACC="$YACC" # Let the user override the test.
5810 else
5811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5812 for as_dir in $PATH
5813 do
5814   IFS=$as_save_IFS
5815   test -z "$as_dir" && as_dir=.
5816     for ac_exec_ext in '' $ac_executable_extensions; do
5817   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5818     ac_cv_prog_YACC="$ac_prog"
5819     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5820     break 2
5821   fi
5822 done
5823   done
5824 IFS=$as_save_IFS
5825
5826 fi
5827 fi
5828 YACC=$ac_cv_prog_YACC
5829 if test -n "$YACC"; then
5830   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
5831 $as_echo "$YACC" >&6; }
5832 else
5833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5834 $as_echo "no" >&6; }
5835 fi
5836
5837
5838   test -n "$YACC" && break
5839 done
5840 test -n "$YACC" || YACC="yacc"
5841
5842
5843 if test -n "$ac_tool_prefix"; then
5844   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5845 set dummy ${ac_tool_prefix}ar; ac_word=$2
5846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5847 $as_echo_n "checking for $ac_word... " >&6; }
5848 if test "${ac_cv_prog_AR+set}" = set; then :
5849   $as_echo_n "(cached) " >&6
5850 else
5851   if test -n "$AR"; then
5852   ac_cv_prog_AR="$AR" # Let the user override the test.
5853 else
5854 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5855 for as_dir in $PATH
5856 do
5857   IFS=$as_save_IFS
5858   test -z "$as_dir" && as_dir=.
5859     for ac_exec_ext in '' $ac_executable_extensions; do
5860   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5861     ac_cv_prog_AR="${ac_tool_prefix}ar"
5862     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5863     break 2
5864   fi
5865 done
5866   done
5867 IFS=$as_save_IFS
5868
5869 fi
5870 fi
5871 AR=$ac_cv_prog_AR
5872 if test -n "$AR"; then
5873   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5874 $as_echo "$AR" >&6; }
5875 else
5876   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5877 $as_echo "no" >&6; }
5878 fi
5879
5880
5881 fi
5882 if test -z "$ac_cv_prog_AR"; then
5883   ac_ct_AR=$AR
5884   # Extract the first word of "ar", so it can be a program name with args.
5885 set dummy ar; ac_word=$2
5886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5887 $as_echo_n "checking for $ac_word... " >&6; }
5888 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
5889   $as_echo_n "(cached) " >&6
5890 else
5891   if test -n "$ac_ct_AR"; then
5892   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5893 else
5894 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5895 for as_dir in $PATH
5896 do
5897   IFS=$as_save_IFS
5898   test -z "$as_dir" && as_dir=.
5899     for ac_exec_ext in '' $ac_executable_extensions; do
5900   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5901     ac_cv_prog_ac_ct_AR="ar"
5902     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5903     break 2
5904   fi
5905 done
5906   done
5907 IFS=$as_save_IFS
5908
5909 fi
5910 fi
5911 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5912 if test -n "$ac_ct_AR"; then
5913   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5914 $as_echo "$ac_ct_AR" >&6; }
5915 else
5916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5917 $as_echo "no" >&6; }
5918 fi
5919
5920   if test "x$ac_ct_AR" = x; then
5921     AR=""
5922   else
5923     case $cross_compiling:$ac_tool_warned in
5924 yes:)
5925 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5926 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5927 ac_tool_warned=yes ;;
5928 esac
5929     AR=$ac_ct_AR
5930   fi
5931 else
5932   AR="$ac_cv_prog_AR"
5933 fi
5934
5935 if test -n "$ac_tool_prefix"; then
5936   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5937 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5939 $as_echo_n "checking for $ac_word... " >&6; }
5940 if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
5941   $as_echo_n "(cached) " >&6
5942 else
5943   if test -n "$DLLTOOL"; then
5944   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5945 else
5946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5947 for as_dir in $PATH
5948 do
5949   IFS=$as_save_IFS
5950   test -z "$as_dir" && as_dir=.
5951     for ac_exec_ext in '' $ac_executable_extensions; do
5952   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5953     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5954     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5955     break 2
5956   fi
5957 done
5958   done
5959 IFS=$as_save_IFS
5960
5961 fi
5962 fi
5963 DLLTOOL=$ac_cv_prog_DLLTOOL
5964 if test -n "$DLLTOOL"; then
5965   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
5966 $as_echo "$DLLTOOL" >&6; }
5967 else
5968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5969 $as_echo "no" >&6; }
5970 fi
5971
5972
5973 fi
5974 if test -z "$ac_cv_prog_DLLTOOL"; then
5975   ac_ct_DLLTOOL=$DLLTOOL
5976   # Extract the first word of "dlltool", so it can be a program name with args.
5977 set dummy dlltool; ac_word=$2
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5979 $as_echo_n "checking for $ac_word... " >&6; }
5980 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
5981   $as_echo_n "(cached) " >&6
5982 else
5983   if test -n "$ac_ct_DLLTOOL"; then
5984   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5985 else
5986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5987 for as_dir in $PATH
5988 do
5989   IFS=$as_save_IFS
5990   test -z "$as_dir" && as_dir=.
5991     for ac_exec_ext in '' $ac_executable_extensions; do
5992   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5993     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5994     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5995     break 2
5996   fi
5997 done
5998   done
5999 IFS=$as_save_IFS
6000
6001 fi
6002 fi
6003 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6004 if test -n "$ac_ct_DLLTOOL"; then
6005   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
6006 $as_echo "$ac_ct_DLLTOOL" >&6; }
6007 else
6008   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6009 $as_echo "no" >&6; }
6010 fi
6011
6012   if test "x$ac_ct_DLLTOOL" = x; then
6013     DLLTOOL=""
6014   else
6015     case $cross_compiling:$ac_tool_warned in
6016 yes:)
6017 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6018 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6019 ac_tool_warned=yes ;;
6020 esac
6021     DLLTOOL=$ac_ct_DLLTOOL
6022   fi
6023 else
6024   DLLTOOL="$ac_cv_prog_DLLTOOL"
6025 fi
6026
6027 if test -n "$ac_tool_prefix"; then
6028   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6029 set dummy ${ac_tool_prefix}windres; ac_word=$2
6030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6031 $as_echo_n "checking for $ac_word... " >&6; }
6032 if test "${ac_cv_prog_WINDRES+set}" = set; then :
6033   $as_echo_n "(cached) " >&6
6034 else
6035   if test -n "$WINDRES"; then
6036   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6037 else
6038 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6039 for as_dir in $PATH
6040 do
6041   IFS=$as_save_IFS
6042   test -z "$as_dir" && as_dir=.
6043     for ac_exec_ext in '' $ac_executable_extensions; do
6044   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6045     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6046     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6047     break 2
6048   fi
6049 done
6050   done
6051 IFS=$as_save_IFS
6052
6053 fi
6054 fi
6055 WINDRES=$ac_cv_prog_WINDRES
6056 if test -n "$WINDRES"; then
6057   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
6058 $as_echo "$WINDRES" >&6; }
6059 else
6060   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6061 $as_echo "no" >&6; }
6062 fi
6063
6064
6065 fi
6066 if test -z "$ac_cv_prog_WINDRES"; then
6067   ac_ct_WINDRES=$WINDRES
6068   # Extract the first word of "windres", so it can be a program name with args.
6069 set dummy windres; ac_word=$2
6070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6071 $as_echo_n "checking for $ac_word... " >&6; }
6072 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
6073   $as_echo_n "(cached) " >&6
6074 else
6075   if test -n "$ac_ct_WINDRES"; then
6076   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6077 else
6078 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6079 for as_dir in $PATH
6080 do
6081   IFS=$as_save_IFS
6082   test -z "$as_dir" && as_dir=.
6083     for ac_exec_ext in '' $ac_executable_extensions; do
6084   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6085     ac_cv_prog_ac_ct_WINDRES="windres"
6086     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6087     break 2
6088   fi
6089 done
6090   done
6091 IFS=$as_save_IFS
6092
6093 fi
6094 fi
6095 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6096 if test -n "$ac_ct_WINDRES"; then
6097   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
6098 $as_echo "$ac_ct_WINDRES" >&6; }
6099 else
6100   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6101 $as_echo "no" >&6; }
6102 fi
6103
6104   if test "x$ac_ct_WINDRES" = x; then
6105     WINDRES=""
6106   else
6107     case $cross_compiling:$ac_tool_warned in
6108 yes:)
6109 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6110 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6111 ac_tool_warned=yes ;;
6112 esac
6113     WINDRES=$ac_ct_WINDRES
6114   fi
6115 else
6116   WINDRES="$ac_cv_prog_WINDRES"
6117 fi
6118
6119
6120 # Needed for GNU/Hurd.
6121 if test -n "$ac_tool_prefix"; then
6122   # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
6123 set dummy ${ac_tool_prefix}mig; ac_word=$2
6124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6125 $as_echo_n "checking for $ac_word... " >&6; }
6126 if test "${ac_cv_prog_MIG+set}" = set; then :
6127   $as_echo_n "(cached) " >&6
6128 else
6129   if test -n "$MIG"; then
6130   ac_cv_prog_MIG="$MIG" # Let the user override the test.
6131 else
6132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6133 for as_dir in $PATH
6134 do
6135   IFS=$as_save_IFS
6136   test -z "$as_dir" && as_dir=.
6137     for ac_exec_ext in '' $ac_executable_extensions; do
6138   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6139     ac_cv_prog_MIG="${ac_tool_prefix}mig"
6140     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6141     break 2
6142   fi
6143 done
6144   done
6145 IFS=$as_save_IFS
6146
6147 fi
6148 fi
6149 MIG=$ac_cv_prog_MIG
6150 if test -n "$MIG"; then
6151   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
6152 $as_echo "$MIG" >&6; }
6153 else
6154   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6155 $as_echo "no" >&6; }
6156 fi
6157
6158
6159 fi
6160 if test -z "$ac_cv_prog_MIG"; then
6161   ac_ct_MIG=$MIG
6162   # Extract the first word of "mig", so it can be a program name with args.
6163 set dummy mig; ac_word=$2
6164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6165 $as_echo_n "checking for $ac_word... " >&6; }
6166 if test "${ac_cv_prog_ac_ct_MIG+set}" = set; then :
6167   $as_echo_n "(cached) " >&6
6168 else
6169   if test -n "$ac_ct_MIG"; then
6170   ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
6171 else
6172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6173 for as_dir in $PATH
6174 do
6175   IFS=$as_save_IFS
6176   test -z "$as_dir" && as_dir=.
6177     for ac_exec_ext in '' $ac_executable_extensions; do
6178   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6179     ac_cv_prog_ac_ct_MIG="mig"
6180     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6181     break 2
6182   fi
6183 done
6184   done
6185 IFS=$as_save_IFS
6186
6187 fi
6188 fi
6189 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
6190 if test -n "$ac_ct_MIG"; then
6191   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
6192 $as_echo "$ac_ct_MIG" >&6; }
6193 else
6194   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6195 $as_echo "no" >&6; }
6196 fi
6197
6198   if test "x$ac_ct_MIG" = x; then
6199     MIG=""
6200   else
6201     case $cross_compiling:$ac_tool_warned in
6202 yes:)
6203 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6204 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6205 ac_tool_warned=yes ;;
6206 esac
6207     MIG=$ac_ct_MIG
6208   fi
6209 else
6210   MIG="$ac_cv_prog_MIG"
6211 fi
6212
6213
6214 # ---------------------- #
6215 # Checks for libraries.  #
6216 # ---------------------- #
6217
6218 # We might need to link with -lm; most simulators need it.
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
6220 $as_echo_n "checking for main in -lm... " >&6; }
6221 if test "${ac_cv_lib_m_main+set}" = set; then :
6222   $as_echo_n "(cached) " >&6
6223 else
6224   ac_check_lib_save_LIBS=$LIBS
6225 LIBS="-lm  $LIBS"
6226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6227 /* end confdefs.h.  */
6228
6229
6230 int
6231 main ()
6232 {
6233 return main ();
6234   ;
6235   return 0;
6236 }
6237 _ACEOF
6238 if ac_fn_c_try_link "$LINENO"; then :
6239   ac_cv_lib_m_main=yes
6240 else
6241   ac_cv_lib_m_main=no
6242 fi
6243 rm -f core conftest.err conftest.$ac_objext \
6244     conftest$ac_exeext conftest.$ac_ext
6245 LIBS=$ac_check_lib_save_LIBS
6246 fi
6247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
6248 $as_echo "$ac_cv_lib_m_main" >&6; }
6249 if test "x$ac_cv_lib_m_main" = x""yes; then :
6250   cat >>confdefs.h <<_ACEOF
6251 #define HAVE_LIBM 1
6252 _ACEOF
6253
6254   LIBS="-lm $LIBS"
6255
6256 fi
6257
6258
6259 # We need to link with -lw to get `wctype' on Solaris before Solaris
6260 # 2.6.  Solaris 2.6 and beyond have this function in libc, and have a
6261 # libw that some versions of the GNU linker cannot hanle (GNU ld 2.9.1
6262 # is known to have this problem).  Therefore we avoid libw if we can.
6263 ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype"
6264 if test "x$ac_cv_func_wctype" = x""yes; then :
6265
6266 else
6267   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype in -lw" >&5
6268 $as_echo_n "checking for wctype in -lw... " >&6; }
6269 if test "${ac_cv_lib_w_wctype+set}" = set; then :
6270   $as_echo_n "(cached) " >&6
6271 else
6272   ac_check_lib_save_LIBS=$LIBS
6273 LIBS="-lw  $LIBS"
6274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6275 /* end confdefs.h.  */
6276
6277 /* Override any GCC internal prototype to avoid an error.
6278    Use char because int might match the return type of a GCC
6279    builtin and then its argument prototype would still apply.  */
6280 #ifdef __cplusplus
6281 extern "C"
6282 #endif
6283 char wctype ();
6284 int
6285 main ()
6286 {
6287 return wctype ();
6288   ;
6289   return 0;
6290 }
6291 _ACEOF
6292 if ac_fn_c_try_link "$LINENO"; then :
6293   ac_cv_lib_w_wctype=yes
6294 else
6295   ac_cv_lib_w_wctype=no
6296 fi
6297 rm -f core conftest.err conftest.$ac_objext \
6298     conftest$ac_exeext conftest.$ac_ext
6299 LIBS=$ac_check_lib_save_LIBS
6300 fi
6301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_w_wctype" >&5
6302 $as_echo "$ac_cv_lib_w_wctype" >&6; }
6303 if test "x$ac_cv_lib_w_wctype" = x""yes; then :
6304   cat >>confdefs.h <<_ACEOF
6305 #define HAVE_LIBW 1
6306 _ACEOF
6307
6308   LIBS="-lw $LIBS"
6309
6310 fi
6311
6312 fi
6313
6314
6315 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
6316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
6317 $as_echo_n "checking for library containing gethostbyname... " >&6; }
6318 if test "${ac_cv_search_gethostbyname+set}" = set; then :
6319   $as_echo_n "(cached) " >&6
6320 else
6321   ac_func_search_save_LIBS=$LIBS
6322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6323 /* end confdefs.h.  */
6324
6325 /* Override any GCC internal prototype to avoid an error.
6326    Use char because int might match the return type of a GCC
6327    builtin and then its argument prototype would still apply.  */
6328 #ifdef __cplusplus
6329 extern "C"
6330 #endif
6331 char gethostbyname ();
6332 int
6333 main ()
6334 {
6335 return gethostbyname ();
6336   ;
6337   return 0;
6338 }
6339 _ACEOF
6340 for ac_lib in '' nsl; do
6341   if test -z "$ac_lib"; then
6342     ac_res="none required"
6343   else
6344     ac_res=-l$ac_lib
6345     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6346   fi
6347   if ac_fn_c_try_link "$LINENO"; then :
6348   ac_cv_search_gethostbyname=$ac_res
6349 fi
6350 rm -f core conftest.err conftest.$ac_objext \
6351     conftest$ac_exeext
6352   if test "${ac_cv_search_gethostbyname+set}" = set; then :
6353   break
6354 fi
6355 done
6356 if test "${ac_cv_search_gethostbyname+set}" = set; then :
6357
6358 else
6359   ac_cv_search_gethostbyname=no
6360 fi
6361 rm conftest.$ac_ext
6362 LIBS=$ac_func_search_save_LIBS
6363 fi
6364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
6365 $as_echo "$ac_cv_search_gethostbyname" >&6; }
6366 ac_res=$ac_cv_search_gethostbyname
6367 if test "$ac_res" != no; then :
6368   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6369
6370 fi
6371
6372
6373 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
6374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
6375 $as_echo_n "checking for library containing socketpair... " >&6; }
6376 if test "${ac_cv_search_socketpair+set}" = set; then :
6377   $as_echo_n "(cached) " >&6
6378 else
6379   ac_func_search_save_LIBS=$LIBS
6380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6381 /* end confdefs.h.  */
6382
6383 /* Override any GCC internal prototype to avoid an error.
6384    Use char because int might match the return type of a GCC
6385    builtin and then its argument prototype would still apply.  */
6386 #ifdef __cplusplus
6387 extern "C"
6388 #endif
6389 char socketpair ();
6390 int
6391 main ()
6392 {
6393 return socketpair ();
6394   ;
6395   return 0;
6396 }
6397 _ACEOF
6398 for ac_lib in '' socket; do
6399   if test -z "$ac_lib"; then
6400     ac_res="none required"
6401   else
6402     ac_res=-l$ac_lib
6403     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6404   fi
6405   if ac_fn_c_try_link "$LINENO"; then :
6406   ac_cv_search_socketpair=$ac_res
6407 fi
6408 rm -f core conftest.err conftest.$ac_objext \
6409     conftest$ac_exeext
6410   if test "${ac_cv_search_socketpair+set}" = set; then :
6411   break
6412 fi
6413 done
6414 if test "${ac_cv_search_socketpair+set}" = set; then :
6415
6416 else
6417   ac_cv_search_socketpair=no
6418 fi
6419 rm conftest.$ac_ext
6420 LIBS=$ac_func_search_save_LIBS
6421 fi
6422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
6423 $as_echo "$ac_cv_search_socketpair" >&6; }
6424 ac_res=$ac_cv_search_socketpair
6425 if test "$ac_res" != no; then :
6426   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6427
6428 fi
6429
6430
6431 # Link in zlib if we can.  This allows us to read compressed debug sections.
6432
6433   # See if the user specified whether he wants zlib support or not.
6434
6435 # Check whether --with-zlib was given.
6436 if test "${with_zlib+set}" = set; then :
6437   withval=$with_zlib;
6438 else
6439   with_zlib=auto
6440 fi
6441
6442
6443   if test "$with_zlib" != "no"; then
6444     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing zlibVersion" >&5
6445 $as_echo_n "checking for library containing zlibVersion... " >&6; }
6446 if test "${ac_cv_search_zlibVersion+set}" = set; then :
6447   $as_echo_n "(cached) " >&6
6448 else
6449   ac_func_search_save_LIBS=$LIBS
6450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6451 /* end confdefs.h.  */
6452
6453 /* Override any GCC internal prototype to avoid an error.
6454    Use char because int might match the return type of a GCC
6455    builtin and then its argument prototype would still apply.  */
6456 #ifdef __cplusplus
6457 extern "C"
6458 #endif
6459 char zlibVersion ();
6460 int
6461 main ()
6462 {
6463 return zlibVersion ();
6464   ;
6465   return 0;
6466 }
6467 _ACEOF
6468 for ac_lib in '' z; do
6469   if test -z "$ac_lib"; then
6470     ac_res="none required"
6471   else
6472     ac_res=-l$ac_lib
6473     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6474   fi
6475   if ac_fn_c_try_link "$LINENO"; then :
6476   ac_cv_search_zlibVersion=$ac_res
6477 fi
6478 rm -f core conftest.err conftest.$ac_objext \
6479     conftest$ac_exeext
6480   if test "${ac_cv_search_zlibVersion+set}" = set; then :
6481   break
6482 fi
6483 done
6484 if test "${ac_cv_search_zlibVersion+set}" = set; then :
6485
6486 else
6487   ac_cv_search_zlibVersion=no
6488 fi
6489 rm conftest.$ac_ext
6490 LIBS=$ac_func_search_save_LIBS
6491 fi
6492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_zlibVersion" >&5
6493 $as_echo "$ac_cv_search_zlibVersion" >&6; }
6494 ac_res=$ac_cv_search_zlibVersion
6495 if test "$ac_res" != no; then :
6496   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6497   for ac_header in zlib.h
6498 do :
6499   ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
6500 if test "x$ac_cv_header_zlib_h" = x""yes; then :
6501   cat >>confdefs.h <<_ACEOF
6502 #define HAVE_ZLIB_H 1
6503 _ACEOF
6504
6505 fi
6506
6507 done
6508
6509 fi
6510
6511     if test "$with_zlib" = "yes" -a "$ac_cv_header_zlib_h" != "yes"; then
6512       as_fn_error "zlib (libz) library was explicitly requested but not found" "$LINENO" 5
6513     fi
6514   fi
6515
6516
6517 # On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
6518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlgetmodinfo" >&5
6519 $as_echo_n "checking for library containing dlgetmodinfo... " >&6; }
6520 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6521   $as_echo_n "(cached) " >&6
6522 else
6523   ac_func_search_save_LIBS=$LIBS
6524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6525 /* end confdefs.h.  */
6526
6527 /* Override any GCC internal prototype to avoid an error.
6528    Use char because int might match the return type of a GCC
6529    builtin and then its argument prototype would still apply.  */
6530 #ifdef __cplusplus
6531 extern "C"
6532 #endif
6533 char dlgetmodinfo ();
6534 int
6535 main ()
6536 {
6537 return dlgetmodinfo ();
6538   ;
6539   return 0;
6540 }
6541 _ACEOF
6542 for ac_lib in '' dl xpdl; do
6543   if test -z "$ac_lib"; then
6544     ac_res="none required"
6545   else
6546     ac_res=-l$ac_lib
6547     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6548   fi
6549   if ac_fn_c_try_link "$LINENO"; then :
6550   ac_cv_search_dlgetmodinfo=$ac_res
6551 fi
6552 rm -f core conftest.err conftest.$ac_objext \
6553     conftest$ac_exeext
6554   if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6555   break
6556 fi
6557 done
6558 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then :
6559
6560 else
6561   ac_cv_search_dlgetmodinfo=no
6562 fi
6563 rm conftest.$ac_ext
6564 LIBS=$ac_func_search_save_LIBS
6565 fi
6566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlgetmodinfo" >&5
6567 $as_echo "$ac_cv_search_dlgetmodinfo" >&6; }
6568 ac_res=$ac_cv_search_dlgetmodinfo
6569 if test "$ac_res" != no; then :
6570   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6571
6572 fi
6573
6574
6575
6576
6577
6578 # Check whether --with-libiconv-prefix was given.
6579 if test "${with_libiconv_prefix+set}" = set; then :
6580   withval=$with_libiconv_prefix;
6581     for dir in `echo "$withval" | tr : ' '`; do
6582       if test -d $dir/include; then LIBICONV_INCLUDE="-I$dir/include"; fi
6583       if test -d $dir/lib; then LIBICONV_LIBDIR="-L$dir/lib"; fi
6584     done
6585
6586 fi
6587
6588
6589   BUILD_LIBICONV_LIBDIRS="../libiconv/lib/.libs ../libiconv/lib/_libs"
6590   BUILD_LIBICONV_INCLUDE="-I../libiconv/include"
6591
6592   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
6593 $as_echo_n "checking for iconv... " >&6; }
6594 if test "${am_cv_func_iconv+set}" = set; then :
6595   $as_echo_n "(cached) " >&6
6596 else
6597
6598     am_cv_func_iconv="no, consider installing GNU libiconv"
6599     am_cv_lib_iconv=no
6600     am_cv_use_build_libiconv=no
6601     am_cv_build_libiconv_path=
6602
6603     # If libiconv is part of the build tree, then try using it over
6604     # any system iconv.
6605     if test -d ../libiconv; then
6606       for lib_dir in $BUILD_LIBICONV_LIBDIRS; do
6607         am_save_LIBS="$LIBS"
6608         am_save_CPPFLAGS="$CPPFLAGS"
6609         LIBS="$LIBS $lib_dir/libiconv.a"
6610         CPPFLAGS="$CPPFLAGS $BUILD_LIBICONV_INCLUDE"
6611         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6612 /* end confdefs.h.  */
6613 #include <stdlib.h>
6614 #include <iconv.h>
6615 int
6616 main ()
6617 {
6618 iconv_t cd = iconv_open("","");
6619            iconv(cd,NULL,NULL,NULL,NULL);
6620            iconv_close(cd);
6621   ;
6622   return 0;
6623 }
6624 _ACEOF
6625 if ac_fn_c_try_link "$LINENO"; then :
6626   am_cv_use_build_libiconv=yes
6627           am_cv_build_libiconv_path=$lib_dir/libiconv.a
6628           am_cv_lib_iconv=yes
6629           am_cv_func_iconv=yes
6630 fi
6631 rm -f core conftest.err conftest.$ac_objext \
6632     conftest$ac_exeext conftest.$ac_ext
6633         LIBS="$am_save_LIBS"
6634         CPPFLAGS="$am_save_CPPFLAGS"
6635         if test "$am_cv_use_build_libiconv" = "yes"; then
6636           break
6637         fi
6638       done
6639     fi
6640
6641     # Next, try to find iconv in libc.
6642     if test "$am_cv_func_iconv" != yes; then
6643       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6644 /* end confdefs.h.  */
6645 #include <stdlib.h>
6646 #include <iconv.h>
6647 int
6648 main ()
6649 {
6650 iconv_t cd = iconv_open("","");
6651          iconv(cd,NULL,NULL,NULL,NULL);
6652          iconv_close(cd);
6653   ;
6654   return 0;
6655 }
6656 _ACEOF
6657 if ac_fn_c_try_link "$LINENO"; then :
6658   am_cv_func_iconv=yes
6659 fi
6660 rm -f core conftest.err conftest.$ac_objext \
6661     conftest$ac_exeext conftest.$ac_ext
6662     fi
6663
6664     # If iconv was not in libc, try -liconv.  In this case, arrange to
6665     # look in the libiconv prefix, if it was specified by the user.
6666     if test "$am_cv_func_iconv" != yes; then
6667       am_save_CPPFLAGS="$CPPFLAGS"
6668       am_save_LIBS="$LIBS"
6669       if test -n "$LIBICONV_INCLUDE"; then
6670         CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
6671         LIBS="$LIBS $LIBICONV_LIBDIR"
6672       fi
6673       LIBS="$LIBS -liconv"
6674       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6675 /* end confdefs.h.  */
6676 #include <stdlib.h>
6677 #include <iconv.h>
6678 int
6679 main ()
6680 {
6681 iconv_t cd = iconv_open("","");
6682          iconv(cd,NULL,NULL,NULL,NULL);
6683          iconv_close(cd);
6684   ;
6685   return 0;
6686 }
6687 _ACEOF
6688 if ac_fn_c_try_link "$LINENO"; then :
6689   am_cv_lib_iconv=yes
6690         am_cv_func_iconv=yes
6691 fi
6692 rm -f core conftest.err conftest.$ac_objext \
6693     conftest$ac_exeext conftest.$ac_ext
6694       LIBS="$am_save_LIBS"
6695       CPPFLAGS="$am_save_CPPFLAGS"
6696     fi
6697
6698 fi
6699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
6700 $as_echo "$am_cv_func_iconv" >&6; }
6701
6702   # Set the various flags based on the cache variables.  We can't rely
6703   # on the flags to remain set from the above code, due to caching.
6704   LIBICONV=
6705   if test "$am_cv_lib_iconv" = yes; then
6706     LIBICONV="-liconv"
6707   else
6708     LIBICONV_LIBDIR=
6709     LIBICONV_INCLUDE=
6710   fi
6711   if test "$am_cv_use_build_libiconv" = yes; then
6712     LIBICONV="$am_cv_build_libiconv_path"
6713     LIBICONV_LIBDIR=""
6714     LIBICONV_INCLUDE="$BUILD_LIBICONV_INCLUDE"
6715   fi
6716   CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
6717   LIBS="$LIBS $LIBICONV_LIBDIR $LIBICONV"
6718
6719   if test "$am_cv_func_iconv" = yes; then
6720
6721 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
6722
6723     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
6724 $as_echo_n "checking for iconv declaration... " >&6; }
6725     if test "${am_cv_proto_iconv+set}" = set; then :
6726   $as_echo_n "(cached) " >&6
6727 else
6728
6729       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6730 /* end confdefs.h.  */
6731
6732 #include <stdlib.h>
6733 #include <iconv.h>
6734 extern
6735 #ifdef __cplusplus
6736 "C"
6737 #endif
6738 #if defined(__STDC__) || defined(__cplusplus)
6739 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
6740 #else
6741 size_t iconv();
6742 #endif
6743
6744 int
6745 main ()
6746 {
6747
6748   ;
6749   return 0;
6750 }
6751 _ACEOF
6752 if ac_fn_c_try_compile "$LINENO"; then :
6753   am_cv_proto_iconv_arg1=""
6754 else
6755   am_cv_proto_iconv_arg1="const"
6756 fi
6757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6758       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);"
6759 fi
6760
6761     am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
6762     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
6763          }$am_cv_proto_iconv" >&5
6764 $as_echo "${ac_t:-
6765          }$am_cv_proto_iconv" >&6; }
6766
6767 cat >>confdefs.h <<_ACEOF
6768 #define ICONV_CONST $am_cv_proto_iconv_arg1
6769 _ACEOF
6770
6771   fi
6772
6773
6774 # GDB may fork/exec the iconv program to get the list of supported character
6775 # sets.  Allow the user to specify where to find it.
6776 # There are several factors affecting the choice of option name:
6777 # - There is already --with-libiconv-prefix but we can't use it, it specifies
6778 #   the build-time location of libiconv files.
6779 # - The program we need to find is iconv, which comes with glibc.  The user
6780 #   doesn't necessarily have libiconv installed.  Therefore naming this
6781 #   --with-libiconv-foo feels wrong.
6782 # - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
6783 #   defined to work on directories not files (though it really doesn't know
6784 #   the difference).
6785 # - Calling this --with-iconv-prefix is perceived to cause too much confusion
6786 #   with --with-libiconv-prefix.
6787 # Putting these together is why the option name is --with-iconv-bin.
6788
6789
6790 # Check whether --with-iconv-bin was given.
6791 if test "${with_iconv_bin+set}" = set; then :
6792   withval=$with_iconv_bin; iconv_bin="${withval}"
6793
6794 cat >>confdefs.h <<_ACEOF
6795 #define ICONV_BIN "${iconv_bin}"
6796 _ACEOF
6797
6798
6799   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6800      if test "x$prefix" = xNONE; then
6801         test_prefix=/usr/local
6802      else
6803         test_prefix=$prefix
6804      fi
6805   else
6806      test_prefix=$exec_prefix
6807   fi
6808   value=0
6809   case ${iconv_bin} in
6810      "${test_prefix}"|"${test_prefix}/"*|\
6811         '${exec_prefix}'|'${exec_prefix}/'*)
6812      value=1
6813      ;;
6814   esac
6815
6816 cat >>confdefs.h <<_ACEOF
6817 #define ICONV_BIN_RELOCATABLE $value
6818 _ACEOF
6819
6820
6821
6822 fi
6823
6824
6825 # On alpha-osf, it appears that libtermcap and libcurses are not compatible.
6826 # There is a very specific comment in /usr/include/curses.h explaining that
6827 # termcap routines built into libcurses must not be used.
6828 #
6829 # The symptoms we observed so far is GDB unexpectedly changing
6830 # the terminal settings when tgetent is called - this is particularly
6831 # visible as the output is missing carriage returns, and so rapidly
6832 # becomes very hard to read.
6833 #
6834 # The readline configure script has already decided that libtermcap
6835 # was enough for its purposes, and so decided to build readline using
6836 # libtermcap.  Since the TUI mode requires curses, building GDB with
6837 # TUI enabled results in both libraries to be used at the same time,
6838 # which is not allowed.  This basically means that GDB with TUI is
6839 # broken on alpha-osf.
6840
6841 case $host_os in
6842   osf* )
6843     if test x"$enable_tui" = xyes; then
6844       as_fn_error "Building GDB with TUI mode is not supported on this host" "$LINENO" 5
6845     fi
6846     if test x"$enable_tui" = xauto; then
6847       enable_tui=no
6848     fi
6849     ;;
6850 esac
6851
6852 # For the TUI, we need enhanced curses functionality.
6853 if test x"$enable_tui" != xno; then
6854   prefer_curses=yes
6855 fi
6856
6857 curses_found=no
6858 if test x"$prefer_curses" = xyes; then
6859   # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
6860   # curses library because the latter might not provide all the
6861   # functionality we need.  However, this leads to problems on systems
6862   # where the linker searches /usr/local/lib, but the compiler doesn't
6863   # search /usr/local/include, if ncurses is installed in /usr/local.  A
6864   # default installation of ncurses on alpha*-dec-osf* will lead to such
6865   # a situation.
6866   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
6867 $as_echo_n "checking for library containing waddstr... " >&6; }
6868 if test "${ac_cv_search_waddstr+set}" = set; then :
6869   $as_echo_n "(cached) " >&6
6870 else
6871   ac_func_search_save_LIBS=$LIBS
6872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6873 /* end confdefs.h.  */
6874
6875 /* Override any GCC internal prototype to avoid an error.
6876    Use char because int might match the return type of a GCC
6877    builtin and then its argument prototype would still apply.  */
6878 #ifdef __cplusplus
6879 extern "C"
6880 #endif
6881 char waddstr ();
6882 int
6883 main ()
6884 {
6885 return waddstr ();
6886   ;
6887   return 0;
6888 }
6889 _ACEOF
6890 for ac_lib in '' ncurses cursesX curses; do
6891   if test -z "$ac_lib"; then
6892     ac_res="none required"
6893   else
6894     ac_res=-l$ac_lib
6895     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6896   fi
6897   if ac_fn_c_try_link "$LINENO"; then :
6898   ac_cv_search_waddstr=$ac_res
6899 fi
6900 rm -f core conftest.err conftest.$ac_objext \
6901     conftest$ac_exeext
6902   if test "${ac_cv_search_waddstr+set}" = set; then :
6903   break
6904 fi
6905 done
6906 if test "${ac_cv_search_waddstr+set}" = set; then :
6907
6908 else
6909   ac_cv_search_waddstr=no
6910 fi
6911 rm conftest.$ac_ext
6912 LIBS=$ac_func_search_save_LIBS
6913 fi
6914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
6915 $as_echo "$ac_cv_search_waddstr" >&6; }
6916 ac_res=$ac_cv_search_waddstr
6917 if test "$ac_res" != no; then :
6918   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6919
6920 fi
6921
6922
6923   if test "$ac_cv_search_waddstr" != no; then
6924     curses_found=yes
6925   fi
6926 fi
6927
6928 # Check whether we should enable the TUI, but only do so if we really
6929 # can.
6930 if test x"$enable_tui" != xno; then
6931   if test -d $srcdir/tui; then
6932     if test "$curses_found" != no; then
6933       CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
6934       CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
6935       CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
6936       ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
6937     else
6938       if test x"$enable_tui" = xyes; then
6939         as_fn_error "no enhanced curses library found; disable TUI" "$LINENO" 5
6940       else
6941         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
6942 $as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
6943       fi
6944     fi
6945   fi
6946 fi
6947
6948 # Since GDB uses Readline, we need termcap functionality.  In many
6949 # cases this will be provided by the curses library, but some systems
6950 # have a seperate termcap library, or no curses library at all.
6951
6952 case $host_os in
6953   cygwin*)
6954     if test -d $srcdir/libtermcap; then
6955       LIBS="../libtermcap/libtermcap.a $LIBS"
6956       ac_cv_search_tgetent="../libtermcap/libtermcap.a"
6957     fi ;;
6958   go32* | *djgpp*)
6959     ac_cv_search_tgetent="none required"
6960     ;;
6961   *mingw32*)
6962     ac_cv_search_tgetent="none required"
6963     CONFIG_OBS="$CONFIG_OBS windows-termcap.o"
6964     ;;
6965 esac
6966
6967 # These are the libraries checked by Readline.
6968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
6969 $as_echo_n "checking for library containing tgetent... " >&6; }
6970 if test "${ac_cv_search_tgetent+set}" = set; then :
6971   $as_echo_n "(cached) " >&6
6972 else
6973   ac_func_search_save_LIBS=$LIBS
6974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6975 /* end confdefs.h.  */
6976
6977 /* Override any GCC internal prototype to avoid an error.
6978    Use char because int might match the return type of a GCC
6979    builtin and then its argument prototype would still apply.  */
6980 #ifdef __cplusplus
6981 extern "C"
6982 #endif
6983 char tgetent ();
6984 int
6985 main ()
6986 {
6987 return tgetent ();
6988   ;
6989   return 0;
6990 }
6991 _ACEOF
6992 for ac_lib in '' termcap tinfo curses ncurses; do
6993   if test -z "$ac_lib"; then
6994     ac_res="none required"
6995   else
6996     ac_res=-l$ac_lib
6997     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6998   fi
6999   if ac_fn_c_try_link "$LINENO"; then :
7000   ac_cv_search_tgetent=$ac_res
7001 fi
7002 rm -f core conftest.err conftest.$ac_objext \
7003     conftest$ac_exeext
7004   if test "${ac_cv_search_tgetent+set}" = set; then :
7005   break
7006 fi
7007 done
7008 if test "${ac_cv_search_tgetent+set}" = set; then :
7009
7010 else
7011   ac_cv_search_tgetent=no
7012 fi
7013 rm conftest.$ac_ext
7014 LIBS=$ac_func_search_save_LIBS
7015 fi
7016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
7017 $as_echo "$ac_cv_search_tgetent" >&6; }
7018 ac_res=$ac_cv_search_tgetent
7019 if test "$ac_res" != no; then :
7020   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7021
7022 fi
7023
7024
7025 if test "$ac_cv_search_tgetent" = no; then
7026   as_fn_error "no termcap library found" "$LINENO" 5
7027 fi
7028
7029
7030 # Check whether --with-system-readline was given.
7031 if test "${with_system_readline+set}" = set; then :
7032   withval=$with_system_readline;
7033 fi
7034
7035
7036 if test "$with_system_readline" = yes; then
7037   READLINE=-lreadline
7038   READLINE_DEPS=
7039   READLINE_CFLAGS=
7040   READLINE_TEXI_INCFLAG=
7041 else
7042   READLINE='$(READLINE_DIR)/libreadline.a'
7043   READLINE_DEPS='$(READLINE)'
7044   READLINE_CFLAGS='-I$(READLINE_SRC)/..'
7045   READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
7046 fi
7047
7048
7049
7050
7051
7052 # Generate jit-reader.h
7053
7054 # This is typedeffed to GDB_CORE_ADDR in jit-reader.h
7055 TARGET_PTR=
7056
7057 # The cast to long int works around a bug in the HP C Compiler
7058 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7059 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7060 # This bug is HP SR number 8606223364.
7061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
7062 $as_echo_n "checking size of unsigned long long... " >&6; }
7063 if test "${ac_cv_sizeof_unsigned_long_long+set}" = set; then :
7064   $as_echo_n "(cached) " >&6
7065 else
7066   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long"        "$ac_includes_default"; then :
7067
7068 else
7069   if test "$ac_cv_type_unsigned_long_long" = yes; then
7070      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7071 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7072 { as_fn_set_status 77
7073 as_fn_error "cannot compute sizeof (unsigned long long)
7074 See \`config.log' for more details." "$LINENO" 5; }; }
7075    else
7076      ac_cv_sizeof_unsigned_long_long=0
7077    fi
7078 fi
7079
7080 fi
7081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
7082 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
7083
7084
7085
7086 cat >>confdefs.h <<_ACEOF
7087 #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
7088 _ACEOF
7089
7090
7091 # The cast to long int works around a bug in the HP C Compiler
7092 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7093 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7094 # This bug is HP SR number 8606223364.
7095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
7096 $as_echo_n "checking size of unsigned long... " >&6; }
7097 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then :
7098   $as_echo_n "(cached) " >&6
7099 else
7100   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long"        "$ac_includes_default"; then :
7101
7102 else
7103   if test "$ac_cv_type_unsigned_long" = yes; then
7104      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7105 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7106 { as_fn_set_status 77
7107 as_fn_error "cannot compute sizeof (unsigned long)
7108 See \`config.log' for more details." "$LINENO" 5; }; }
7109    else
7110      ac_cv_sizeof_unsigned_long=0
7111    fi
7112 fi
7113
7114 fi
7115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
7116 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
7117
7118
7119
7120 cat >>confdefs.h <<_ACEOF
7121 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
7122 _ACEOF
7123
7124
7125 # The cast to long int works around a bug in the HP C Compiler
7126 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7127 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7128 # This bug is HP SR number 8606223364.
7129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
7130 $as_echo_n "checking size of unsigned __int128... " >&6; }
7131 if test "${ac_cv_sizeof_unsigned___int128+set}" = set; then :
7132   $as_echo_n "(cached) " >&6
7133 else
7134   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128"        "$ac_includes_default"; then :
7135
7136 else
7137   if test "$ac_cv_type_unsigned___int128" = yes; then
7138      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7139 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7140 { as_fn_set_status 77
7141 as_fn_error "cannot compute sizeof (unsigned __int128)
7142 See \`config.log' for more details." "$LINENO" 5; }; }
7143    else
7144      ac_cv_sizeof_unsigned___int128=0
7145    fi
7146 fi
7147
7148 fi
7149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
7150 $as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
7151
7152
7153
7154 cat >>confdefs.h <<_ACEOF
7155 #define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
7156 _ACEOF
7157
7158
7159
7160 if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
7161   TARGET_PTR="unsigned long"
7162 elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
7163   TARGET_PTR="unsigned long long"
7164 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
7165   TARGET_PTR="unsigned __int128"
7166 else
7167   TARGET_PTR="unsigned long"
7168 fi
7169
7170
7171 ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
7172
7173
7174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
7175 $as_echo_n "checking for library containing dlopen... " >&6; }
7176 if test "${ac_cv_search_dlopen+set}" = set; then :
7177   $as_echo_n "(cached) " >&6
7178 else
7179   ac_func_search_save_LIBS=$LIBS
7180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7181 /* end confdefs.h.  */
7182
7183 /* Override any GCC internal prototype to avoid an error.
7184    Use char because int might match the return type of a GCC
7185    builtin and then its argument prototype would still apply.  */
7186 #ifdef __cplusplus
7187 extern "C"
7188 #endif
7189 char dlopen ();
7190 int
7191 main ()
7192 {
7193 return dlopen ();
7194   ;
7195   return 0;
7196 }
7197 _ACEOF
7198 for ac_lib in '' dl; do
7199   if test -z "$ac_lib"; then
7200     ac_res="none required"
7201   else
7202     ac_res=-l$ac_lib
7203     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7204   fi
7205   if ac_fn_c_try_link "$LINENO"; then :
7206   ac_cv_search_dlopen=$ac_res
7207 fi
7208 rm -f core conftest.err conftest.$ac_objext \
7209     conftest$ac_exeext
7210   if test "${ac_cv_search_dlopen+set}" = set; then :
7211   break
7212 fi
7213 done
7214 if test "${ac_cv_search_dlopen+set}" = set; then :
7215
7216 else
7217   ac_cv_search_dlopen=no
7218 fi
7219 rm conftest.$ac_ext
7220 LIBS=$ac_func_search_save_LIBS
7221 fi
7222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
7223 $as_echo "$ac_cv_search_dlopen" >&6; }
7224 ac_res=$ac_cv_search_dlopen
7225 if test "$ac_res" != no; then :
7226   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7227
7228 fi
7229
7230
7231
7232
7233 # Check whether --with-jit-reader-dir was given.
7234 if test "${with_jit_reader_dir+set}" = set; then :
7235   withval=$with_jit_reader_dir;
7236     JIT_READER_DIR=$withval
7237 else
7238   JIT_READER_DIR=${libdir}/gdb
7239 fi
7240
7241
7242   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7243   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7244   ac_define_dir=`eval echo $JIT_READER_DIR`
7245   ac_define_dir=`eval echo $ac_define_dir`
7246
7247 cat >>confdefs.h <<_ACEOF
7248 #define JIT_READER_DIR "$ac_define_dir"
7249 _ACEOF
7250
7251
7252
7253
7254   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
7255      if test "x$prefix" = xNONE; then
7256         test_prefix=/usr/local
7257      else
7258         test_prefix=$prefix
7259      fi
7260   else
7261      test_prefix=$exec_prefix
7262   fi
7263   value=0
7264   case ${ac_define_dir} in
7265      "${test_prefix}"|"${test_prefix}/"*|\
7266         '${exec_prefix}'|'${exec_prefix}/'*)
7267      value=1
7268      ;;
7269   esac
7270
7271 cat >>confdefs.h <<_ACEOF
7272 #define JIT_READER_DIR_RELOCATABLE $value
7273 _ACEOF
7274
7275
7276
7277
7278
7279 # Check whether --with-expat was given.
7280 if test "${with_expat+set}" = set; then :
7281   withval=$with_expat;
7282 else
7283   with_expat=auto
7284 fi
7285
7286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
7287 $as_echo_n "checking whether to use expat... " >&6; }
7288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
7289 $as_echo "$with_expat" >&6; }
7290
7291 if test "${with_expat}" = no; then
7292   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
7293 $as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
7294   HAVE_LIBEXPAT=no
7295 else
7296
7297       if test "X$prefix" = "XNONE"; then
7298     acl_final_prefix="$ac_default_prefix"
7299   else
7300     acl_final_prefix="$prefix"
7301   fi
7302   if test "X$exec_prefix" = "XNONE"; then
7303     acl_final_exec_prefix='${prefix}'
7304   else
7305     acl_final_exec_prefix="$exec_prefix"
7306   fi
7307   acl_save_prefix="$prefix"
7308   prefix="$acl_final_prefix"
7309   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
7310   prefix="$acl_save_prefix"
7311
7312
7313 # Check whether --with-gnu-ld was given.
7314 if test "${with_gnu_ld+set}" = set; then :
7315   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
7316 else
7317   with_gnu_ld=no
7318 fi
7319
7320 # Prepare PATH_SEPARATOR.
7321 # The user is always right.
7322 if test "${PATH_SEPARATOR+set}" != set; then
7323   echo "#! /bin/sh" >conf$$.sh
7324   echo  "exit 0"   >>conf$$.sh
7325   chmod +x conf$$.sh
7326   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
7327     PATH_SEPARATOR=';'
7328   else
7329     PATH_SEPARATOR=:
7330   fi
7331   rm -f conf$$.sh
7332 fi
7333 ac_prog=ld
7334 if test "$GCC" = yes; then
7335   # Check if gcc -print-prog-name=ld gives a path.
7336   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
7337 $as_echo_n "checking for ld used by GCC... " >&6; }
7338   case $host in
7339   *-*-mingw*)
7340     # gcc leaves a trailing carriage return which upsets mingw
7341     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7342   *)
7343     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7344   esac
7345   case $ac_prog in
7346     # Accept absolute paths.
7347     [\\/]* | [A-Za-z]:[\\/]*)
7348       re_direlt='/[^/][^/]*/\.\./'
7349       # Canonicalize the path of ld
7350       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
7351       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
7352         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
7353       done
7354       test -z "$LD" && LD="$ac_prog"
7355       ;;
7356   "")
7357     # If it fails, then pretend we aren't using GCC.
7358     ac_prog=ld
7359     ;;
7360   *)
7361     # If it is relative, then search for the first ld in PATH.
7362     with_gnu_ld=unknown
7363     ;;
7364   esac
7365 elif test "$with_gnu_ld" = yes; then
7366   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7367 $as_echo_n "checking for GNU ld... " >&6; }
7368 else
7369   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7370 $as_echo_n "checking for non-GNU ld... " >&6; }
7371 fi
7372 if test "${acl_cv_path_LD+set}" = set; then :
7373   $as_echo_n "(cached) " >&6
7374 else
7375   if test -z "$LD"; then
7376   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
7377   for ac_dir in $PATH; do
7378     test -z "$ac_dir" && ac_dir=.
7379     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7380       acl_cv_path_LD="$ac_dir/$ac_prog"
7381       # Check to see if the program is GNU ld.  I'd rather use --version,
7382       # but apparently some GNU ld's only accept -v.
7383       # Break only if it was the GNU/non-GNU ld that we prefer.
7384       if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
7385         test "$with_gnu_ld" != no && break
7386       else
7387         test "$with_gnu_ld" != yes && break
7388       fi
7389     fi
7390   done
7391   IFS="$ac_save_ifs"
7392 else
7393   acl_cv_path_LD="$LD" # Let the user override the test with a path.
7394 fi
7395 fi
7396
7397 LD="$acl_cv_path_LD"
7398 if test -n "$LD"; then
7399   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7400 $as_echo "$LD" >&6; }
7401 else
7402   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7403 $as_echo "no" >&6; }
7404 fi
7405 test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
7406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7407 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7408 if test "${acl_cv_prog_gnu_ld+set}" = set; then :
7409   $as_echo_n "(cached) " >&6
7410 else
7411   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
7412 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
7413   acl_cv_prog_gnu_ld=yes
7414 else
7415   acl_cv_prog_gnu_ld=no
7416 fi
7417 fi
7418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
7419 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
7420 with_gnu_ld=$acl_cv_prog_gnu_ld
7421
7422
7423
7424                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
7425 $as_echo_n "checking for shared library run path origin... " >&6; }
7426 if test "${acl_cv_rpath+set}" = set; then :
7427   $as_echo_n "(cached) " >&6
7428 else
7429
7430     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
7431     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
7432     . ./conftest.sh
7433     rm -f ./conftest.sh
7434     acl_cv_rpath=done
7435
7436 fi
7437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
7438 $as_echo "$acl_cv_rpath" >&6; }
7439   wl="$acl_cv_wl"
7440   libext="$acl_cv_libext"
7441   shlibext="$acl_cv_shlibext"
7442   hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
7443   hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
7444   hardcode_direct="$acl_cv_hardcode_direct"
7445   hardcode_minus_L="$acl_cv_hardcode_minus_L"
7446     # Check whether --enable-rpath was given.
7447 if test "${enable_rpath+set}" = set; then :
7448   enableval=$enable_rpath; :
7449 else
7450   enable_rpath=yes
7451 fi
7452
7453
7454
7455
7456
7457
7458
7459
7460
7461
7462     use_additional=yes
7463
7464   acl_save_prefix="$prefix"
7465   prefix="$acl_final_prefix"
7466   acl_save_exec_prefix="$exec_prefix"
7467   exec_prefix="$acl_final_exec_prefix"
7468
7469     eval additional_includedir=\"$includedir\"
7470     eval additional_libdir=\"$libdir\"
7471
7472   exec_prefix="$acl_save_exec_prefix"
7473   prefix="$acl_save_prefix"
7474
7475
7476 # Check whether --with-libexpat-prefix was given.
7477 if test "${with_libexpat_prefix+set}" = set; then :
7478   withval=$with_libexpat_prefix;
7479     if test "X$withval" = "Xno"; then
7480       use_additional=no
7481     else
7482       if test "X$withval" = "X"; then
7483
7484   acl_save_prefix="$prefix"
7485   prefix="$acl_final_prefix"
7486   acl_save_exec_prefix="$exec_prefix"
7487   exec_prefix="$acl_final_exec_prefix"
7488
7489           eval additional_includedir=\"$includedir\"
7490           eval additional_libdir=\"$libdir\"
7491
7492   exec_prefix="$acl_save_exec_prefix"
7493   prefix="$acl_save_prefix"
7494
7495       else
7496         additional_includedir="$withval/include"
7497         additional_libdir="$withval/lib"
7498       fi
7499     fi
7500
7501 fi
7502
7503       LIBEXPAT=
7504   LTLIBEXPAT=
7505   INCEXPAT=
7506   rpathdirs=
7507   ltrpathdirs=
7508   names_already_handled=
7509   names_next_round='expat '
7510   while test -n "$names_next_round"; do
7511     names_this_round="$names_next_round"
7512     names_next_round=
7513     for name in $names_this_round; do
7514       already_handled=
7515       for n in $names_already_handled; do
7516         if test "$n" = "$name"; then
7517           already_handled=yes
7518           break
7519         fi
7520       done
7521       if test -z "$already_handled"; then
7522         names_already_handled="$names_already_handled $name"
7523                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
7524         eval value=\"\$HAVE_LIB$uppername\"
7525         if test -n "$value"; then
7526           if test "$value" = yes; then
7527             eval value=\"\$LIB$uppername\"
7528             test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
7529             eval value=\"\$LTLIB$uppername\"
7530             test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
7531           else
7532                                     :
7533           fi
7534         else
7535                               found_dir=
7536           found_la=
7537           found_so=
7538           found_a=
7539           if test $use_additional = yes; then
7540             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
7541               found_dir="$additional_libdir"
7542               found_so="$additional_libdir/lib$name.$shlibext"
7543               if test -f "$additional_libdir/lib$name.la"; then
7544                 found_la="$additional_libdir/lib$name.la"
7545               fi
7546             else
7547               if test -f "$additional_libdir/lib$name.$libext"; then
7548                 found_dir="$additional_libdir"
7549                 found_a="$additional_libdir/lib$name.$libext"
7550                 if test -f "$additional_libdir/lib$name.la"; then
7551                   found_la="$additional_libdir/lib$name.la"
7552                 fi
7553               fi
7554             fi
7555           fi
7556           if test "X$found_dir" = "X"; then
7557             for x in $LDFLAGS $LTLIBEXPAT; do
7558
7559   acl_save_prefix="$prefix"
7560   prefix="$acl_final_prefix"
7561   acl_save_exec_prefix="$exec_prefix"
7562   exec_prefix="$acl_final_exec_prefix"
7563   eval x=\"$x\"
7564   exec_prefix="$acl_save_exec_prefix"
7565   prefix="$acl_save_prefix"
7566
7567               case "$x" in
7568                 -L*)
7569                   dir=`echo "X$x" | sed -e 's/^X-L//'`
7570                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
7571                     found_dir="$dir"
7572                     found_so="$dir/lib$name.$shlibext"
7573                     if test -f "$dir/lib$name.la"; then
7574                       found_la="$dir/lib$name.la"
7575                     fi
7576                   else
7577                     if test -f "$dir/lib$name.$libext"; then
7578                       found_dir="$dir"
7579                       found_a="$dir/lib$name.$libext"
7580                       if test -f "$dir/lib$name.la"; then
7581                         found_la="$dir/lib$name.la"
7582                       fi
7583                     fi
7584                   fi
7585                   ;;
7586               esac
7587               if test "X$found_dir" != "X"; then
7588                 break
7589               fi
7590             done
7591           fi
7592           if test "X$found_dir" != "X"; then
7593                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
7594             if test "X$found_so" != "X"; then
7595                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
7596                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7597               else
7598                                                                                 haveit=
7599                 for x in $ltrpathdirs; do
7600                   if test "X$x" = "X$found_dir"; then
7601                     haveit=yes
7602                     break
7603                   fi
7604                 done
7605                 if test -z "$haveit"; then
7606                   ltrpathdirs="$ltrpathdirs $found_dir"
7607                 fi
7608                                 if test "$hardcode_direct" = yes; then
7609                                                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7610                 else
7611                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
7612                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7613                                                             haveit=
7614                     for x in $rpathdirs; do
7615                       if test "X$x" = "X$found_dir"; then
7616                         haveit=yes
7617                         break
7618                       fi
7619                     done
7620                     if test -z "$haveit"; then
7621                       rpathdirs="$rpathdirs $found_dir"
7622                     fi
7623                   else
7624                                                                                 haveit=
7625                     for x in $LDFLAGS $LIBEXPAT; do
7626
7627   acl_save_prefix="$prefix"
7628   prefix="$acl_final_prefix"
7629   acl_save_exec_prefix="$exec_prefix"
7630   exec_prefix="$acl_final_exec_prefix"
7631   eval x=\"$x\"
7632   exec_prefix="$acl_save_exec_prefix"
7633   prefix="$acl_save_prefix"
7634
7635                       if test "X$x" = "X-L$found_dir"; then
7636                         haveit=yes
7637                         break
7638                       fi
7639                     done
7640                     if test -z "$haveit"; then
7641                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
7642                     fi
7643                     if test "$hardcode_minus_L" != no; then
7644                                                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
7645                     else
7646                                                                                                                                                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
7647                     fi
7648                   fi
7649                 fi
7650               fi
7651             else
7652               if test "X$found_a" != "X"; then
7653                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
7654               else
7655                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
7656               fi
7657             fi
7658                         additional_includedir=
7659             case "$found_dir" in
7660               */lib | */lib/)
7661                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
7662                 additional_includedir="$basedir/include"
7663                 ;;
7664             esac
7665             if test "X$additional_includedir" != "X"; then
7666                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
7667                 haveit=
7668                 if test "X$additional_includedir" = "X/usr/local/include"; then
7669                   if test -n "$GCC"; then
7670                     case $host_os in
7671                       linux*) haveit=yes;;
7672                     esac
7673                   fi
7674                 fi
7675                 if test -z "$haveit"; then
7676                   for x in $CPPFLAGS $INCEXPAT; do
7677
7678   acl_save_prefix="$prefix"
7679   prefix="$acl_final_prefix"
7680   acl_save_exec_prefix="$exec_prefix"
7681   exec_prefix="$acl_final_exec_prefix"
7682   eval x=\"$x\"
7683   exec_prefix="$acl_save_exec_prefix"
7684   prefix="$acl_save_prefix"
7685
7686                     if test "X$x" = "X-I$additional_includedir"; then
7687                       haveit=yes
7688                       break
7689                     fi
7690                   done
7691                   if test -z "$haveit"; then
7692                     if test -d "$additional_includedir"; then
7693                                             INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
7694                     fi
7695                   fi
7696                 fi
7697               fi
7698             fi
7699                         if test -n "$found_la"; then
7700                                                         save_libdir="$libdir"
7701               case "$found_la" in
7702                 */* | *\\*) . "$found_la" ;;
7703                 *) . "./$found_la" ;;
7704               esac
7705               libdir="$save_libdir"
7706                             for dep in $dependency_libs; do
7707                 case "$dep" in
7708                   -L*)
7709                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
7710                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
7711                       haveit=
7712                       if test "X$additional_libdir" = "X/usr/local/lib"; then
7713                         if test -n "$GCC"; then
7714                           case $host_os in
7715                             linux*) haveit=yes;;
7716                           esac
7717                         fi
7718                       fi
7719                       if test -z "$haveit"; then
7720                         haveit=
7721                         for x in $LDFLAGS $LIBEXPAT; do
7722
7723   acl_save_prefix="$prefix"
7724   prefix="$acl_final_prefix"
7725   acl_save_exec_prefix="$exec_prefix"
7726   exec_prefix="$acl_final_exec_prefix"
7727   eval x=\"$x\"
7728   exec_prefix="$acl_save_exec_prefix"
7729   prefix="$acl_save_prefix"
7730
7731                           if test "X$x" = "X-L$additional_libdir"; then
7732                             haveit=yes
7733                             break
7734                           fi
7735                         done
7736                         if test -z "$haveit"; then
7737                           if test -d "$additional_libdir"; then
7738                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
7739                           fi
7740                         fi
7741                         haveit=
7742                         for x in $LDFLAGS $LTLIBEXPAT; do
7743
7744   acl_save_prefix="$prefix"
7745   prefix="$acl_final_prefix"
7746   acl_save_exec_prefix="$exec_prefix"
7747   exec_prefix="$acl_final_exec_prefix"
7748   eval x=\"$x\"
7749   exec_prefix="$acl_save_exec_prefix"
7750   prefix="$acl_save_prefix"
7751
7752                           if test "X$x" = "X-L$additional_libdir"; then
7753                             haveit=yes
7754                             break
7755                           fi
7756                         done
7757                         if test -z "$haveit"; then
7758                           if test -d "$additional_libdir"; then
7759                                                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
7760                           fi
7761                         fi
7762                       fi
7763                     fi
7764                     ;;
7765                   -R*)
7766                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
7767                     if test "$enable_rpath" != no; then
7768                                                                   haveit=
7769                       for x in $rpathdirs; do
7770                         if test "X$x" = "X$dir"; then
7771                           haveit=yes
7772                           break
7773                         fi
7774                       done
7775                       if test -z "$haveit"; then
7776                         rpathdirs="$rpathdirs $dir"
7777                       fi
7778                                                                   haveit=
7779                       for x in $ltrpathdirs; do
7780                         if test "X$x" = "X$dir"; then
7781                           haveit=yes
7782                           break
7783                         fi
7784                       done
7785                       if test -z "$haveit"; then
7786                         ltrpathdirs="$ltrpathdirs $dir"
7787                       fi
7788                     fi
7789                     ;;
7790                   -l*)
7791                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
7792                     ;;
7793                   *.la)
7794                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
7795                     ;;
7796                   *)
7797                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
7798                     LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
7799                     ;;
7800                 esac
7801               done
7802             fi
7803           else
7804                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
7805             LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
7806           fi
7807         fi
7808       fi
7809     done
7810   done
7811   if test "X$rpathdirs" != "X"; then
7812     if test -n "$hardcode_libdir_separator"; then
7813                         alldirs=
7814       for found_dir in $rpathdirs; do
7815         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
7816       done
7817             acl_save_libdir="$libdir"
7818       libdir="$alldirs"
7819       eval flag=\"$hardcode_libdir_flag_spec\"
7820       libdir="$acl_save_libdir"
7821       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
7822     else
7823             for found_dir in $rpathdirs; do
7824         acl_save_libdir="$libdir"
7825         libdir="$found_dir"
7826         eval flag=\"$hardcode_libdir_flag_spec\"
7827         libdir="$acl_save_libdir"
7828         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
7829       done
7830     fi
7831   fi
7832   if test "X$ltrpathdirs" != "X"; then
7833             for found_dir in $ltrpathdirs; do
7834       LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
7835     done
7836   fi
7837
7838
7839         ac_save_CPPFLAGS="$CPPFLAGS"
7840
7841   for element in $INCEXPAT; do
7842     haveit=
7843     for x in $CPPFLAGS; do
7844
7845   acl_save_prefix="$prefix"
7846   prefix="$acl_final_prefix"
7847   acl_save_exec_prefix="$exec_prefix"
7848   exec_prefix="$acl_final_exec_prefix"
7849   eval x=\"$x\"
7850   exec_prefix="$acl_save_exec_prefix"
7851   prefix="$acl_save_prefix"
7852
7853       if test "X$x" = "X$element"; then
7854         haveit=yes
7855         break
7856       fi
7857     done
7858     if test -z "$haveit"; then
7859       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
7860     fi
7861   done
7862
7863
7864   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
7865 $as_echo_n "checking for libexpat... " >&6; }
7866 if test "${ac_cv_libexpat+set}" = set; then :
7867   $as_echo_n "(cached) " >&6
7868 else
7869
7870     ac_save_LIBS="$LIBS"
7871     LIBS="$LIBS $LIBEXPAT"
7872     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7873 /* end confdefs.h.  */
7874 #include "expat.h"
7875 int
7876 main ()
7877 {
7878 XML_Parser p = XML_ParserCreate (0);
7879   ;
7880   return 0;
7881 }
7882 _ACEOF
7883 if ac_fn_c_try_link "$LINENO"; then :
7884   ac_cv_libexpat=yes
7885 else
7886   ac_cv_libexpat=no
7887 fi
7888 rm -f core conftest.err conftest.$ac_objext \
7889     conftest$ac_exeext conftest.$ac_ext
7890     LIBS="$ac_save_LIBS"
7891
7892 fi
7893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
7894 $as_echo "$ac_cv_libexpat" >&6; }
7895   if test "$ac_cv_libexpat" = yes; then
7896     HAVE_LIBEXPAT=yes
7897
7898 $as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
7899
7900     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
7901 $as_echo_n "checking how to link with libexpat... " >&6; }
7902     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
7903 $as_echo "$LIBEXPAT" >&6; }
7904   else
7905     HAVE_LIBEXPAT=no
7906             CPPFLAGS="$ac_save_CPPFLAGS"
7907     LIBEXPAT=
7908     LTLIBEXPAT=
7909   fi
7910
7911
7912
7913
7914
7915
7916   if test "$HAVE_LIBEXPAT" != yes; then
7917     if test "$with_expat" = yes; then
7918       as_fn_error "expat is missing or unusable" "$LINENO" 5
7919     else
7920       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
7921 $as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
7922     fi
7923   else
7924     save_LIBS=$LIBS
7925     LIBS="$LIBS $LIBEXPAT"
7926     for ac_func in XML_StopParser
7927 do :
7928   ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
7929 if test "x$ac_cv_func_XML_StopParser" = x""yes; then :
7930   cat >>confdefs.h <<_ACEOF
7931 #define HAVE_XML_STOPPARSER 1
7932 _ACEOF
7933
7934 fi
7935 done
7936
7937     LIBS=$save_LIBS
7938   fi
7939 fi
7940
7941
7942
7943
7944
7945
7946 # Check whether --with-python was given.
7947 if test "${with_python+set}" = set; then :
7948   withval=$with_python;
7949 else
7950   with_python=auto
7951 fi
7952
7953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
7954 $as_echo_n "checking whether to use python... " >&6; }
7955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
7956 $as_echo "$with_python" >&6; }
7957
7958 if test "${with_python}" = no; then
7959   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
7960 $as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
7961   have_libpython=no
7962 else
7963   case "${with_python}" in
7964   [\\/]* | ?:[\\/]*)
7965     if test -d ${with_python}; then
7966       # Assume the python binary is ${with_python}/bin/python.
7967       python_prog="${with_python}/bin/python"
7968       python_prefix=
7969       # If python does not exit ${with_python}/bin, then try in
7970       # ${with_python}.  On Windows/MinGW, this is where the Python
7971       # executable is.
7972       if test ! -x "${python_prog}"; then
7973         python_prog="${with_python}/python"
7974         python_prefix=
7975       fi
7976       if test ! -x "${python_prog}"; then
7977         # Fall back to gdb 7.0/7.1 behaviour.
7978         python_prog=missing
7979         python_prefix=${with_python}
7980       fi
7981     elif test -x "${with_python}"; then
7982       # While we can't run python compiled for $host (unless host == build),
7983       # the user could write a script that provides the needed information,
7984       # so we support that.
7985       python_prog=${with_python}
7986       python_prefix=
7987     else
7988       as_fn_error "invalid value for --with-python" "$LINENO" 5
7989     fi
7990     ;;
7991   */*)
7992     # Disallow --with-python=foo/bar.
7993     as_fn_error "invalid value for --with-python" "$LINENO" 5
7994     ;;
7995   *)
7996     # The user has either specified auto, yes, or the name of the python
7997     # program assumed to be in $PATH.
7998     python_prefix=
7999     case "${with_python}" in
8000     yes | auto)
8001       if test ${build} = ${host}; then
8002         # Extract the first word of "python", so it can be a program name with args.
8003 set dummy python; ac_word=$2
8004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8005 $as_echo_n "checking for $ac_word... " >&6; }
8006 if test "${ac_cv_path_python_prog_path+set}" = set; then :
8007   $as_echo_n "(cached) " >&6
8008 else
8009   case $python_prog_path in
8010   [\\/]* | ?:[\\/]*)
8011   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
8012   ;;
8013   *)
8014   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8015 for as_dir in $PATH
8016 do
8017   IFS=$as_save_IFS
8018   test -z "$as_dir" && as_dir=.
8019     for ac_exec_ext in '' $ac_executable_extensions; do
8020   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8021     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
8022     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8023     break 2
8024   fi
8025 done
8026   done
8027 IFS=$as_save_IFS
8028
8029   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
8030   ;;
8031 esac
8032 fi
8033 python_prog_path=$ac_cv_path_python_prog_path
8034 if test -n "$python_prog_path"; then
8035   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
8036 $as_echo "$python_prog_path" >&6; }
8037 else
8038   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8039 $as_echo "no" >&6; }
8040 fi
8041
8042
8043         if test "${python_prog_path}" = missing; then
8044           python_prog=missing
8045         else
8046           python_prog=${python_prog_path}
8047         fi
8048       else
8049         # Not much we can do except assume the cross-compiler will find the
8050         # right files.
8051         python_prog=missing
8052       fi
8053       ;;
8054     *)
8055       # While we can't run python compiled for $host (unless host == build),
8056       # the user could write a script that provides the needed information,
8057       # so we support that.
8058       python_prog="${with_python}"
8059       # Extract the first word of "${python_prog}", so it can be a program name with args.
8060 set dummy ${python_prog}; ac_word=$2
8061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8062 $as_echo_n "checking for $ac_word... " >&6; }
8063 if test "${ac_cv_path_python_prog_path+set}" = set; then :
8064   $as_echo_n "(cached) " >&6
8065 else
8066   case $python_prog_path in
8067   [\\/]* | ?:[\\/]*)
8068   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
8069   ;;
8070   *)
8071   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8072 for as_dir in $PATH
8073 do
8074   IFS=$as_save_IFS
8075   test -z "$as_dir" && as_dir=.
8076     for ac_exec_ext in '' $ac_executable_extensions; do
8077   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8078     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
8079     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8080     break 2
8081   fi
8082 done
8083   done
8084 IFS=$as_save_IFS
8085
8086   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
8087   ;;
8088 esac
8089 fi
8090 python_prog_path=$ac_cv_path_python_prog_path
8091 if test -n "$python_prog_path"; then
8092   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
8093 $as_echo "$python_prog_path" >&6; }
8094 else
8095   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8096 $as_echo "no" >&6; }
8097 fi
8098
8099
8100       if test "${python_prog_path}" = missing; then
8101         as_fn_error "unable to find python program ${python_prog}" "$LINENO" 5
8102       fi
8103       ;;
8104     esac
8105   esac
8106
8107   if test "${python_prog}" != missing; then
8108     # We have a python program to use, but it may be too old.
8109     # Don't flag an error for --with-python=auto (the default).
8110     have_python_config=yes
8111     python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
8112     if test $? != 0; then
8113       have_python_config=failed
8114       if test "${with_python}" != auto; then
8115         as_fn_error "failure running python-config --includes" "$LINENO" 5
8116       fi
8117     fi
8118     python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
8119     if test $? != 0; then
8120       have_python_config=failed
8121       if test "${with_python}" != auto; then
8122         as_fn_error "failure running python-config --ldflags" "$LINENO" 5
8123       fi
8124     fi
8125     python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
8126     if test $? != 0; then
8127       have_python_config=failed
8128       if test "${with_python}" != auto; then
8129         as_fn_error "failure running python-config --exec-prefix" "$LINENO" 5
8130       fi
8131     fi
8132   else
8133     # We do not have a python executable we can use to determine where
8134     # to find the Python headers and libs.  We cannot guess the include
8135     # path from the python_prefix either, because that include path
8136     # depends on the Python version.  So, there is nothing much we can
8137     # do except assume that the compiler will be able to find those files.
8138     python_includes=
8139     python_libs=
8140     have_python_config=no
8141   fi
8142
8143   # If we have python-config, only try the configuration it provides.
8144   # Otherwise fallback on the old way of trying different versions of
8145   # python in turn.
8146
8147   have_libpython=no
8148   if test "${have_python_config}" = yes; then
8149     # Determine the Python version by extracting "-lpython<version>"
8150     # part of the python_libs. <version> is usually X.Y with X and Y
8151     # being decimal numbers, but can also be XY (seen on Windows).
8152     #
8153     # The extraction is performed using sed with a regular expression.
8154     # Initially, the regexp used was using the '?' quantifier to make
8155     # the dot in the version number optional.  Unfortunately, this
8156     # does not work with non-GNU versions of sed because, because of
8157     # what looks like a limitation (the '?' quantifier does not work
8158     # with back-references).  We work around this limitation by using
8159     # the '*' quantifier instead.  It means that, in theory, we might
8160     # match unexpected version strings such as "-lpython2..7", but
8161     # this seems unlikely in practice.  And even if that happens,
8162     # an error will be triggered later on, when checking that version
8163     # number.
8164     python_version=`echo " ${python_libs} " \
8165                          | sed -e 's,^.* -l\(python[0-9]*[.]*[0-9]*\).*$,\1,'`
8166     case "${python_version}" in
8167     python*)
8168
8169   version=${python_version}
8170
8171   new_CPPFLAGS=${python_includes}
8172   new_LIBS=${python_libs}
8173   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8174 $as_echo_n "checking for ${version}... " >&6; }
8175   save_CPPFLAGS=$CPPFLAGS
8176   save_LIBS=$LIBS
8177   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8178   LIBS="$LIBS $new_LIBS"
8179   found_usable_python=no
8180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8181 /* end confdefs.h.  */
8182 #include "Python.h"
8183 int
8184 main ()
8185 {
8186 Py_Initialize ();
8187   ;
8188   return 0;
8189 }
8190 _ACEOF
8191 if ac_fn_c_try_link "$LINENO"; then :
8192   have_libpython=${version}
8193                   found_usable_python=yes
8194                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8195                   PYTHON_LIBS=$new_LIBS
8196 fi
8197 rm -f core conftest.err conftest.$ac_objext \
8198     conftest$ac_exeext conftest.$ac_ext
8199   CPPFLAGS=$save_CPPFLAGS
8200   LIBS=$save_LIBS
8201   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8202 $as_echo "${found_usable_python}" >&6; }
8203
8204       ;;
8205     *)
8206       as_fn_error "unable to determine python version from ${python_libs}" "$LINENO" 5
8207       ;;
8208     esac
8209   elif test "${have_python_config}" != failed; then
8210     if test "${have_libpython}" = no; then
8211
8212   version=python2.7
8213
8214   new_CPPFLAGS=${python_includes}
8215   new_LIBS="${python_libs} -lpython2.7"
8216   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8217 $as_echo_n "checking for ${version}... " >&6; }
8218   save_CPPFLAGS=$CPPFLAGS
8219   save_LIBS=$LIBS
8220   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8221   LIBS="$LIBS $new_LIBS"
8222   found_usable_python=no
8223   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8224 /* end confdefs.h.  */
8225 #include "Python.h"
8226 int
8227 main ()
8228 {
8229 Py_Initialize ();
8230   ;
8231   return 0;
8232 }
8233 _ACEOF
8234 if ac_fn_c_try_link "$LINENO"; then :
8235   have_libpython=${version}
8236                   found_usable_python=yes
8237                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8238                   PYTHON_LIBS=$new_LIBS
8239 fi
8240 rm -f core conftest.err conftest.$ac_objext \
8241     conftest$ac_exeext conftest.$ac_ext
8242   CPPFLAGS=$save_CPPFLAGS
8243   LIBS=$save_LIBS
8244   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8245 $as_echo "${found_usable_python}" >&6; }
8246
8247     fi
8248     if test "${have_libpython}" = no; then
8249
8250   version=python2.6
8251
8252   new_CPPFLAGS=${python_includes}
8253   new_LIBS="${python_libs} -lpython2.6"
8254   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8255 $as_echo_n "checking for ${version}... " >&6; }
8256   save_CPPFLAGS=$CPPFLAGS
8257   save_LIBS=$LIBS
8258   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8259   LIBS="$LIBS $new_LIBS"
8260   found_usable_python=no
8261   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8262 /* end confdefs.h.  */
8263 #include "Python.h"
8264 int
8265 main ()
8266 {
8267 Py_Initialize ();
8268   ;
8269   return 0;
8270 }
8271 _ACEOF
8272 if ac_fn_c_try_link "$LINENO"; then :
8273   have_libpython=${version}
8274                   found_usable_python=yes
8275                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8276                   PYTHON_LIBS=$new_LIBS
8277 fi
8278 rm -f core conftest.err conftest.$ac_objext \
8279     conftest$ac_exeext conftest.$ac_ext
8280   CPPFLAGS=$save_CPPFLAGS
8281   LIBS=$save_LIBS
8282   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8283 $as_echo "${found_usable_python}" >&6; }
8284
8285     fi
8286     if test ${have_libpython} = no; then
8287
8288   version=python2.5
8289
8290   new_CPPFLAGS=${python_includes}
8291   new_LIBS="${python_libs} -lpython2.5"
8292   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8293 $as_echo_n "checking for ${version}... " >&6; }
8294   save_CPPFLAGS=$CPPFLAGS
8295   save_LIBS=$LIBS
8296   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8297   LIBS="$LIBS $new_LIBS"
8298   found_usable_python=no
8299   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8300 /* end confdefs.h.  */
8301 #include "Python.h"
8302 int
8303 main ()
8304 {
8305 Py_Initialize ();
8306   ;
8307   return 0;
8308 }
8309 _ACEOF
8310 if ac_fn_c_try_link "$LINENO"; then :
8311   have_libpython=${version}
8312                   found_usable_python=yes
8313                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8314                   PYTHON_LIBS=$new_LIBS
8315 fi
8316 rm -f core conftest.err conftest.$ac_objext \
8317     conftest$ac_exeext conftest.$ac_ext
8318   CPPFLAGS=$save_CPPFLAGS
8319   LIBS=$save_LIBS
8320   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8321 $as_echo "${found_usable_python}" >&6; }
8322
8323     fi
8324     if test ${have_libpython} = no; then
8325
8326   version=python2.4
8327
8328   new_CPPFLAGS=${python_includes}
8329   new_LIBS="${python_libs} -lpython2.4"
8330   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
8331 $as_echo_n "checking for ${version}... " >&6; }
8332   save_CPPFLAGS=$CPPFLAGS
8333   save_LIBS=$LIBS
8334   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
8335   LIBS="$LIBS $new_LIBS"
8336   found_usable_python=no
8337   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8338 /* end confdefs.h.  */
8339 #include "Python.h"
8340 int
8341 main ()
8342 {
8343 Py_Initialize ();
8344   ;
8345   return 0;
8346 }
8347 _ACEOF
8348 if ac_fn_c_try_link "$LINENO"; then :
8349   have_libpython=${version}
8350                   found_usable_python=yes
8351                   PYTHON_CPPFLAGS=$new_CPPFLAGS
8352                   PYTHON_LIBS=$new_LIBS
8353 fi
8354 rm -f core conftest.err conftest.$ac_objext \
8355     conftest$ac_exeext conftest.$ac_ext
8356   CPPFLAGS=$save_CPPFLAGS
8357   LIBS=$save_LIBS
8358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
8359 $as_echo "${found_usable_python}" >&6; }
8360
8361     fi
8362   fi
8363   if test "${have_libpython}" = python2.7 -o "${have_libpython}" = python27; then
8364
8365 $as_echo "#define HAVE_LIBPYTHON2_7 1" >>confdefs.h
8366
8367   elif test "${have_libpython}" = python2.6 -o "${have_libpython}" = python26; then
8368
8369 $as_echo "#define HAVE_LIBPYTHON2_6 1" >>confdefs.h
8370
8371   elif test "${have_libpython}" = python2.5 -o "${have_libpython}" = python25; then
8372
8373 $as_echo "#define HAVE_LIBPYTHON2_5 1" >>confdefs.h
8374
8375   elif test "${have_libpython}" = python2.4 -o "${have_libpython}" = python24; then
8376
8377 $as_echo "#define HAVE_LIBPYTHON2_4 1" >>confdefs.h
8378
8379   fi
8380
8381   if test "${have_libpython}" = no; then
8382     case "${with_python}" in
8383     yes)
8384       as_fn_error "python is missing or unusable" "$LINENO" 5
8385       ;;
8386     auto)
8387       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
8388 $as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
8389       ;;
8390     *)
8391       as_fn_error "no usable python found at ${with_python}" "$LINENO" 5
8392       ;;
8393     esac
8394   else
8395     if test -n "${python_prefix}"; then
8396
8397 cat >>confdefs.h <<_ACEOF
8398 #define WITH_PYTHON_PATH "${python_prefix}"
8399 _ACEOF
8400
8401
8402   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
8403      if test "x$prefix" = xNONE; then
8404         test_prefix=/usr/local
8405      else
8406         test_prefix=$prefix
8407      fi
8408   else
8409      test_prefix=$exec_prefix
8410   fi
8411   value=0
8412   case ${python_prefix} in
8413      "${test_prefix}"|"${test_prefix}/"*|\
8414         '${exec_prefix}'|'${exec_prefix}/'*)
8415      value=1
8416      ;;
8417   esac
8418
8419 cat >>confdefs.h <<_ACEOF
8420 #define PYTHON_PATH_RELOCATABLE $value
8421 _ACEOF
8422
8423
8424     fi
8425   fi
8426 fi
8427
8428 if test "${have_libpython}" != no; then
8429
8430 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
8431
8432   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
8433   CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
8434   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
8435   CONFIG_INSTALL="$CONFIG_INSTALL install-python"
8436   ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
8437
8438   # Flags needed to compile Python code (taken from python-config --cflags).
8439   # We cannot call python-config directly because it will output whatever was
8440   # used when compiling the Python interpreter itself, including flags which
8441   # would make the python-related objects be compiled differently from the
8442   # rest of GDB (e.g., -O2 and -fPIC).
8443   if test "${GCC}" = yes; then
8444     tentative_python_cflags="-fno-strict-aliasing -DNDEBUG -fwrapv"
8445   fi
8446
8447   if test "x${tentative_python_cflags}" != x; then
8448     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
8449 $as_echo_n "checking compiler flags for python code... " >&6; }
8450     for flag in ${tentative_python_cflags}; do
8451       # Check that the compiler accepts it
8452       saved_CFLAGS="$CFLAGS"
8453       CFLAGS="$CFLAGS $flag"
8454       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8455 /* end confdefs.h.  */
8456
8457 int
8458 main ()
8459 {
8460
8461   ;
8462   return 0;
8463 }
8464 _ACEOF
8465 if ac_fn_c_try_compile "$LINENO"; then :
8466   PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
8467 fi
8468 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8469       CFLAGS="$saved_CFLAGS"
8470     done
8471     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
8472 $as_echo "${PYTHON_CFLAGS}" >&6; }
8473   fi
8474
8475   # On IRIX, type siginfo is not defined.  Instead, sys/siginfo.h provides:
8476   #    #if _SGIAPI
8477   #    #define siginfo __siginfo
8478   #    #endif
8479   # The problem is that including Python causes some XOPEN macros to be
8480   # unilaterally defined, and that in turn causes _SGIAPI to evaluate
8481   # to false.  So, we work around this issue by defining siginfo ourself
8482   # though the command-line.
8483   #
8484   # On x64 Windows, Python's include headers, and pyconfig.h in
8485   # particular, rely on MS_WIN64 macro to detect that it's a 64bit
8486   # version of Windows.  Unfortunately, MS_WIN64 is only defined if
8487   # _MSC_VER, a Microsoft-specific macro, is defined.  So, when
8488   # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
8489   # The issue was reported to the Python community, but still isn't
8490   # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
8491
8492   case "$gdb_host" in
8493     irix*) if test "${GCC}" = yes; then
8494              CPPFLAGS="$CPPFLAGS -Dsiginfo=__siginfo"
8495            fi
8496            ;;
8497     mingw64)
8498            if test "${GCC}" = yes; then
8499              CPPFLAGS="$CPPFLAGS -DMS_WIN64"
8500            fi
8501            ;;
8502   esac
8503
8504   # Note that "python -m threading" cannot be used to check for
8505   # threading support due to a bug in Python 2.7.3
8506   # (http://bugs.python.org/issue15567).
8507   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether python supports threads" >&5
8508 $as_echo_n "checking whether python supports threads... " >&6; }
8509   saved_CPPFLAGS="${CPPFLAGS}"
8510   CPPFLAGS="${PYTHON_CPPFLAGS}"
8511   # Note that the test is reversed so that python_has_threads=yes on
8512   # unexpected failures.
8513   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8514 /* end confdefs.h.  */
8515
8516 #include <Python.h>
8517 #ifdef WITH_THREAD
8518 # error
8519 #endif
8520
8521 _ACEOF
8522 if ac_fn_c_try_cpp "$LINENO"; then :
8523   python_has_threads=no
8524 else
8525   python_has_threads=yes
8526 fi
8527 rm -f conftest.err conftest.$ac_ext
8528   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_has_threads}" >&5
8529 $as_echo "${python_has_threads}" >&6; }
8530   CPPFLAGS="${saved_CPPFLAGS}"
8531 else
8532   # Even if Python support is not compiled in, we need to have these files
8533   # included.
8534   CONFIG_OBS="$CONFIG_OBS python.o py-value.o py-prettyprint.o py-auto-load.o"
8535   CONFIG_SRCS="$CONFIG_SRCS python/python.c python/py-value.c \
8536         python/py-prettyprint.c python/py-auto-load.c"
8537 fi
8538
8539
8540
8541
8542 # Provide a --enable-libmcheck/--disable-libmcheck set of options
8543 # allowing a user to enable this option even when building releases,
8544 # or to disable it when building a snapshot.
8545 # Check whether --enable-libmcheck was given.
8546 if test "${enable_libmcheck+set}" = set; then :
8547   enableval=$enable_libmcheck; case "${enableval}" in
8548      yes | y) ENABLE_LIBMCHECK="yes" ;;
8549      no | n)  ENABLE_LIBMCHECK="no" ;;
8550      *) as_fn_error "bad value ${enableval} for --enable-libmcheck" "$LINENO" 5 ;;
8551    esac
8552 fi
8553
8554
8555 # Enable -lmcheck by default (it provides cheap-enough memory mangling),
8556 # but turn it off if Python is enabled with threads, since -lmcheck is
8557 # not thread safe (http://sourceware.org/bugzilla/show_bug.cgi?id=9939),
8558 # and for releases.
8559 if test -z "${ENABLE_LIBMCHECK}" \
8560         -a \( "${have_libpython}" = "no" \
8561              -o "${python_has_threads}" = "no" \) \
8562     && $development; then
8563   ENABLE_LIBMCHECK=yes
8564 fi
8565
8566 if test "$ENABLE_LIBMCHECK" = "yes" ; then
8567   if test "${have_libpython}" != "no" -a "${python_has_threads}" = "yes" ; then
8568     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&5
8569 $as_echo "$as_me: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&2;}
8570   fi
8571   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lmcheck" >&5
8572 $as_echo_n "checking for main in -lmcheck... " >&6; }
8573 if test "${ac_cv_lib_mcheck_main+set}" = set; then :
8574   $as_echo_n "(cached) " >&6
8575 else
8576   ac_check_lib_save_LIBS=$LIBS
8577 LIBS="-lmcheck  $LIBS"
8578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8579 /* end confdefs.h.  */
8580
8581
8582 int
8583 main ()
8584 {
8585 return main ();
8586   ;
8587   return 0;
8588 }
8589 _ACEOF
8590 if ac_fn_c_try_link "$LINENO"; then :
8591   ac_cv_lib_mcheck_main=yes
8592 else
8593   ac_cv_lib_mcheck_main=no
8594 fi
8595 rm -f core conftest.err conftest.$ac_objext \
8596     conftest$ac_exeext conftest.$ac_ext
8597 LIBS=$ac_check_lib_save_LIBS
8598 fi
8599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mcheck_main" >&5
8600 $as_echo "$ac_cv_lib_mcheck_main" >&6; }
8601 if test "x$ac_cv_lib_mcheck_main" = x""yes; then :
8602   cat >>confdefs.h <<_ACEOF
8603 #define HAVE_LIBMCHECK 1
8604 _ACEOF
8605
8606   LIBS="-lmcheck $LIBS"
8607
8608 fi
8609
8610 fi
8611
8612 # ------------------------- #
8613 # Checks for header files.  #
8614 # ------------------------- #
8615
8616 ac_header_dirent=no
8617 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
8618   as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
8619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
8620 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
8621 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then :
8622   $as_echo_n "(cached) " >&6
8623 else
8624   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8625 /* end confdefs.h.  */
8626 #include <sys/types.h>
8627 #include <$ac_hdr>
8628
8629 int
8630 main ()
8631 {
8632 if ((DIR *) 0)
8633 return 0;
8634   ;
8635   return 0;
8636 }
8637 _ACEOF
8638 if ac_fn_c_try_compile "$LINENO"; then :
8639   eval "$as_ac_Header=yes"
8640 else
8641   eval "$as_ac_Header=no"
8642 fi
8643 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8644 fi
8645 eval ac_res=\$$as_ac_Header
8646                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8647 $as_echo "$ac_res" >&6; }
8648 eval as_val=\$$as_ac_Header
8649    if test "x$as_val" = x""yes; then :
8650   cat >>confdefs.h <<_ACEOF
8651 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
8652 _ACEOF
8653
8654 ac_header_dirent=$ac_hdr; break
8655 fi
8656
8657 done
8658 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
8659 if test $ac_header_dirent = dirent.h; then
8660   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8661 $as_echo_n "checking for library containing opendir... " >&6; }
8662 if test "${ac_cv_search_opendir+set}" = set; then :
8663   $as_echo_n "(cached) " >&6
8664 else
8665   ac_func_search_save_LIBS=$LIBS
8666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8667 /* end confdefs.h.  */
8668
8669 /* Override any GCC internal prototype to avoid an error.
8670    Use char because int might match the return type of a GCC
8671    builtin and then its argument prototype would still apply.  */
8672 #ifdef __cplusplus
8673 extern "C"
8674 #endif
8675 char opendir ();
8676 int
8677 main ()
8678 {
8679 return opendir ();
8680   ;
8681   return 0;
8682 }
8683 _ACEOF
8684 for ac_lib in '' dir; do
8685   if test -z "$ac_lib"; then
8686     ac_res="none required"
8687   else
8688     ac_res=-l$ac_lib
8689     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8690   fi
8691   if ac_fn_c_try_link "$LINENO"; then :
8692   ac_cv_search_opendir=$ac_res
8693 fi
8694 rm -f core conftest.err conftest.$ac_objext \
8695     conftest$ac_exeext
8696   if test "${ac_cv_search_opendir+set}" = set; then :
8697   break
8698 fi
8699 done
8700 if test "${ac_cv_search_opendir+set}" = set; then :
8701
8702 else
8703   ac_cv_search_opendir=no
8704 fi
8705 rm conftest.$ac_ext
8706 LIBS=$ac_func_search_save_LIBS
8707 fi
8708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8709 $as_echo "$ac_cv_search_opendir" >&6; }
8710 ac_res=$ac_cv_search_opendir
8711 if test "$ac_res" != no; then :
8712   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8713
8714 fi
8715
8716 else
8717   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8718 $as_echo_n "checking for library containing opendir... " >&6; }
8719 if test "${ac_cv_search_opendir+set}" = set; then :
8720   $as_echo_n "(cached) " >&6
8721 else
8722   ac_func_search_save_LIBS=$LIBS
8723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8724 /* end confdefs.h.  */
8725
8726 /* Override any GCC internal prototype to avoid an error.
8727    Use char because int might match the return type of a GCC
8728    builtin and then its argument prototype would still apply.  */
8729 #ifdef __cplusplus
8730 extern "C"
8731 #endif
8732 char opendir ();
8733 int
8734 main ()
8735 {
8736 return opendir ();
8737   ;
8738   return 0;
8739 }
8740 _ACEOF
8741 for ac_lib in '' x; do
8742   if test -z "$ac_lib"; then
8743     ac_res="none required"
8744   else
8745     ac_res=-l$ac_lib
8746     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8747   fi
8748   if ac_fn_c_try_link "$LINENO"; then :
8749   ac_cv_search_opendir=$ac_res
8750 fi
8751 rm -f core conftest.err conftest.$ac_objext \
8752     conftest$ac_exeext
8753   if test "${ac_cv_search_opendir+set}" = set; then :
8754   break
8755 fi
8756 done
8757 if test "${ac_cv_search_opendir+set}" = set; then :
8758
8759 else
8760   ac_cv_search_opendir=no
8761 fi
8762 rm conftest.$ac_ext
8763 LIBS=$ac_func_search_save_LIBS
8764 fi
8765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8766 $as_echo "$ac_cv_search_opendir" >&6; }
8767 ac_res=$ac_cv_search_opendir
8768 if test "$ac_res" != no; then :
8769   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8770
8771 fi
8772
8773 fi
8774
8775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
8776 $as_echo_n "checking for ANSI C header files... " >&6; }
8777 if test "${ac_cv_header_stdc+set}" = set; then :
8778   $as_echo_n "(cached) " >&6
8779 else
8780   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8781 /* end confdefs.h.  */
8782 #include <stdlib.h>
8783 #include <stdarg.h>
8784 #include <string.h>
8785 #include <float.h>
8786
8787 int
8788 main ()
8789 {
8790
8791   ;
8792   return 0;
8793 }
8794 _ACEOF
8795 if ac_fn_c_try_compile "$LINENO"; then :
8796   ac_cv_header_stdc=yes
8797 else
8798   ac_cv_header_stdc=no
8799 fi
8800 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8801
8802 if test $ac_cv_header_stdc = yes; then
8803   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8804   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8805 /* end confdefs.h.  */
8806 #include <string.h>
8807
8808 _ACEOF
8809 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8810   $EGREP "memchr" >/dev/null 2>&1; then :
8811
8812 else
8813   ac_cv_header_stdc=no
8814 fi
8815 rm -f conftest*
8816
8817 fi
8818
8819 if test $ac_cv_header_stdc = yes; then
8820   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8821   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8822 /* end confdefs.h.  */
8823 #include <stdlib.h>
8824
8825 _ACEOF
8826 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8827   $EGREP "free" >/dev/null 2>&1; then :
8828
8829 else
8830   ac_cv_header_stdc=no
8831 fi
8832 rm -f conftest*
8833
8834 fi
8835
8836 if test $ac_cv_header_stdc = yes; then
8837   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8838   if test "$cross_compiling" = yes; then :
8839   :
8840 else
8841   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8842 /* end confdefs.h.  */
8843 #include <ctype.h>
8844 #include <stdlib.h>
8845 #if ((' ' & 0x0FF) == 0x020)
8846 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8847 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8848 #else
8849 # define ISLOWER(c) \
8850                    (('a' <= (c) && (c) <= 'i') \
8851                      || ('j' <= (c) && (c) <= 'r') \
8852                      || ('s' <= (c) && (c) <= 'z'))
8853 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8854 #endif
8855
8856 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8857 int
8858 main ()
8859 {
8860   int i;
8861   for (i = 0; i < 256; i++)
8862     if (XOR (islower (i), ISLOWER (i))
8863         || toupper (i) != TOUPPER (i))
8864       return 2;
8865   return 0;
8866 }
8867 _ACEOF
8868 if ac_fn_c_try_run "$LINENO"; then :
8869
8870 else
8871   ac_cv_header_stdc=no
8872 fi
8873 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8874   conftest.$ac_objext conftest.beam conftest.$ac_ext
8875 fi
8876
8877 fi
8878 fi
8879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8880 $as_echo "$ac_cv_header_stdc" >&6; }
8881 if test $ac_cv_header_stdc = yes; then
8882
8883 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
8884
8885 fi
8886
8887 # elf_hp.h is for HP/UX 64-bit shared library support.
8888 for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
8889                   thread_db.h signal.h stddef.h \
8890                   stdlib.h string.h memory.h strings.h sys/fault.h \
8891                   sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
8892                   sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
8893                   sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
8894                   sys/types.h sys/wait.h wait.h termios.h termio.h \
8895                   sgtty.h unistd.h elf_hp.h locale.h \
8896                   dlfcn.h sys/socket.h sys/un.h linux/perf_event.h
8897 do :
8898   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8899 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8900 eval as_val=\$$as_ac_Header
8901    if test "x$as_val" = x""yes; then :
8902   cat >>confdefs.h <<_ACEOF
8903 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8904 _ACEOF
8905
8906 fi
8907
8908 done
8909
8910 for ac_header in link.h
8911 do :
8912   ac_fn_c_check_header_compile "$LINENO" "link.h" "ac_cv_header_link_h" "#if HAVE_SYS_TYPES_H
8913 # include <sys/types.h>
8914 #endif
8915 #if HAVE_NLIST_H
8916 # include <nlist.h>
8917 #endif
8918
8919 "
8920 if test "x$ac_cv_header_link_h" = x""yes; then :
8921   cat >>confdefs.h <<_ACEOF
8922 #define HAVE_LINK_H 1
8923 _ACEOF
8924
8925 fi
8926
8927 done
8928
8929 for ac_header in sys/proc.h
8930 do :
8931   ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" "#if HAVE_SYS_PARAM_H
8932 # include <sys/param.h>
8933 #endif
8934
8935 "
8936 if test "x$ac_cv_header_sys_proc_h" = x""yes; then :
8937   cat >>confdefs.h <<_ACEOF
8938 #define HAVE_SYS_PROC_H 1
8939 _ACEOF
8940
8941 fi
8942
8943 done
8944
8945 for ac_header in sys/user.h
8946 do :
8947   ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
8948 # include <sys/param.h>
8949 #endif
8950
8951 "
8952 if test "x$ac_cv_header_sys_user_h" = x""yes; then :
8953   cat >>confdefs.h <<_ACEOF
8954 #define HAVE_SYS_USER_H 1
8955 _ACEOF
8956
8957 fi
8958
8959 done
8960
8961
8962 # On Solaris 2.[789], we need to define _MSE_INT_H to avoid a clash
8963 # between <widec.h> and <wchar.h> that would cause AC_CHECK_HEADERS to
8964 # think that we don't have <curses.h> if we're using GCC.
8965 case $host_os in
8966   solaris2.[789])
8967     if test "$GCC" = yes; then
8968
8969 $as_echo "#define _MSE_INT_H 1" >>confdefs.h
8970
8971     fi ;;
8972 esac
8973 for ac_header in curses.h cursesX.h ncurses.h ncurses/ncurses.h ncurses/term.h
8974 do :
8975   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8976 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8977 eval as_val=\$$as_ac_Header
8978    if test "x$as_val" = x""yes; then :
8979   cat >>confdefs.h <<_ACEOF
8980 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8981 _ACEOF
8982
8983 fi
8984
8985 done
8986
8987 for ac_header in term.h
8988 do :
8989   ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
8990 # include <curses.h>
8991 #endif
8992
8993 "
8994 if test "x$ac_cv_header_term_h" = x""yes; then :
8995   cat >>confdefs.h <<_ACEOF
8996 #define HAVE_TERM_H 1
8997 _ACEOF
8998
8999 fi
9000
9001 done
9002
9003
9004 # ------------------------- #
9005 # Checks for declarations.  #
9006 # ------------------------- #
9007
9008 ac_fn_c_check_decl "$LINENO" "free" "ac_cv_have_decl_free" "$ac_includes_default"
9009 if test "x$ac_cv_have_decl_free" = x""yes; then :
9010   ac_have_decl=1
9011 else
9012   ac_have_decl=0
9013 fi
9014
9015 cat >>confdefs.h <<_ACEOF
9016 #define HAVE_DECL_FREE $ac_have_decl
9017 _ACEOF
9018 ac_fn_c_check_decl "$LINENO" "malloc" "ac_cv_have_decl_malloc" "$ac_includes_default"
9019 if test "x$ac_cv_have_decl_malloc" = x""yes; then :
9020   ac_have_decl=1
9021 else
9022   ac_have_decl=0
9023 fi
9024
9025 cat >>confdefs.h <<_ACEOF
9026 #define HAVE_DECL_MALLOC $ac_have_decl
9027 _ACEOF
9028 ac_fn_c_check_decl "$LINENO" "realloc" "ac_cv_have_decl_realloc" "$ac_includes_default"
9029 if test "x$ac_cv_have_decl_realloc" = x""yes; then :
9030   ac_have_decl=1
9031 else
9032   ac_have_decl=0
9033 fi
9034
9035 cat >>confdefs.h <<_ACEOF
9036 #define HAVE_DECL_REALLOC $ac_have_decl
9037 _ACEOF
9038 ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
9039 if test "x$ac_cv_have_decl_strerror" = x""yes; then :
9040   ac_have_decl=1
9041 else
9042   ac_have_decl=0
9043 fi
9044
9045 cat >>confdefs.h <<_ACEOF
9046 #define HAVE_DECL_STRERROR $ac_have_decl
9047 _ACEOF
9048 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
9049 if test "x$ac_cv_have_decl_strstr" = x""yes; then :
9050   ac_have_decl=1
9051 else
9052   ac_have_decl=0
9053 fi
9054
9055 cat >>confdefs.h <<_ACEOF
9056 #define HAVE_DECL_STRSTR $ac_have_decl
9057 _ACEOF
9058 ac_fn_c_check_decl "$LINENO" "getopt" "ac_cv_have_decl_getopt" "$ac_includes_default"
9059 if test "x$ac_cv_have_decl_getopt" = x""yes; then :
9060   ac_have_decl=1
9061 else
9062   ac_have_decl=0
9063 fi
9064
9065 cat >>confdefs.h <<_ACEOF
9066 #define HAVE_DECL_GETOPT $ac_have_decl
9067 _ACEOF
9068 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
9069 if test "x$ac_cv_have_decl_snprintf" = x""yes; then :
9070   ac_have_decl=1
9071 else
9072   ac_have_decl=0
9073 fi
9074
9075 cat >>confdefs.h <<_ACEOF
9076 #define HAVE_DECL_SNPRINTF $ac_have_decl
9077 _ACEOF
9078 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
9079 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then :
9080   ac_have_decl=1
9081 else
9082   ac_have_decl=0
9083 fi
9084
9085 cat >>confdefs.h <<_ACEOF
9086 #define HAVE_DECL_VSNPRINTF $ac_have_decl
9087 _ACEOF
9088
9089
9090   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
9091 $as_echo_n "checking for LC_MESSAGES... " >&6; }
9092 if test "${am_cv_val_LC_MESSAGES+set}" = set; then :
9093   $as_echo_n "(cached) " >&6
9094 else
9095   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9096 /* end confdefs.h.  */
9097 #include <locale.h>
9098 int
9099 main ()
9100 {
9101 return LC_MESSAGES
9102   ;
9103   return 0;
9104 }
9105 _ACEOF
9106 if ac_fn_c_try_link "$LINENO"; then :
9107   am_cv_val_LC_MESSAGES=yes
9108 else
9109   am_cv_val_LC_MESSAGES=no
9110 fi
9111 rm -f core conftest.err conftest.$ac_objext \
9112     conftest$ac_exeext conftest.$ac_ext
9113 fi
9114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
9115 $as_echo "$am_cv_val_LC_MESSAGES" >&6; }
9116   if test $am_cv_val_LC_MESSAGES = yes; then
9117
9118 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
9119
9120   fi
9121
9122
9123 # ----------------------- #
9124 # Checks for structures.  #
9125 # ----------------------- #
9126
9127 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
9128 if test "x$ac_cv_member_struct_stat_st_blocks" = x""yes; then :
9129
9130 cat >>confdefs.h <<_ACEOF
9131 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
9132 _ACEOF
9133
9134
9135 fi
9136 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
9137 if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then :
9138
9139 cat >>confdefs.h <<_ACEOF
9140 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
9141 _ACEOF
9142
9143
9144 fi
9145
9146
9147 # ------------------ #
9148 # Checks for types.  #
9149 # ------------------ #
9150
9151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
9152 $as_echo_n "checking return type of signal handlers... " >&6; }
9153 if test "${ac_cv_type_signal+set}" = set; then :
9154   $as_echo_n "(cached) " >&6
9155 else
9156   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9157 /* end confdefs.h.  */
9158 #include <sys/types.h>
9159 #include <signal.h>
9160
9161 int
9162 main ()
9163 {
9164 return *(signal (0, 0)) (0) == 1;
9165   ;
9166   return 0;
9167 }
9168 _ACEOF
9169 if ac_fn_c_try_compile "$LINENO"; then :
9170   ac_cv_type_signal=int
9171 else
9172   ac_cv_type_signal=void
9173 fi
9174 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9175 fi
9176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
9177 $as_echo "$ac_cv_type_signal" >&6; }
9178
9179 cat >>confdefs.h <<_ACEOF
9180 #define RETSIGTYPE $ac_cv_type_signal
9181 _ACEOF
9182
9183
9184 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
9185 #include <sys/socket.h>
9186
9187 "
9188 if test "x$ac_cv_type_socklen_t" = x""yes; then :
9189
9190 cat >>confdefs.h <<_ACEOF
9191 #define HAVE_SOCKLEN_T 1
9192 _ACEOF
9193
9194
9195 fi
9196
9197
9198 # ------------------------------------- #
9199 # Checks for compiler characteristics.  #
9200 # ------------------------------------- #
9201
9202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
9203 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
9204 if test "${ac_cv_c_const+set}" = set; then :
9205   $as_echo_n "(cached) " >&6
9206 else
9207   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9208 /* end confdefs.h.  */
9209
9210 int
9211 main ()
9212 {
9213 /* FIXME: Include the comments suggested by Paul. */
9214 #ifndef __cplusplus
9215   /* Ultrix mips cc rejects this.  */
9216   typedef int charset[2];
9217   const charset cs;
9218   /* SunOS 4.1.1 cc rejects this.  */
9219   char const *const *pcpcc;
9220   char **ppc;
9221   /* NEC SVR4.0.2 mips cc rejects this.  */
9222   struct point {int x, y;};
9223   static struct point const zero = {0,0};
9224   /* AIX XL C 1.02.0.0 rejects this.
9225      It does not let you subtract one const X* pointer from another in
9226      an arm of an if-expression whose if-part is not a constant
9227      expression */
9228   const char *g = "string";
9229   pcpcc = &g + (g ? g-g : 0);
9230   /* HPUX 7.0 cc rejects these. */
9231   ++pcpcc;
9232   ppc = (char**) pcpcc;
9233   pcpcc = (char const *const *) ppc;
9234   { /* SCO 3.2v4 cc rejects this.  */
9235     char *t;
9236     char const *s = 0 ? (char *) 0 : (char const *) 0;
9237
9238     *t++ = 0;
9239     if (s) return 0;
9240   }
9241   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9242     int x[] = {25, 17};
9243     const int *foo = &x[0];
9244     ++foo;
9245   }
9246   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9247     typedef const int *iptr;
9248     iptr p = 0;
9249     ++p;
9250   }
9251   { /* AIX XL C 1.02.0.0 rejects this saying
9252        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9253     struct s { int j; const int *ap[3]; };
9254     struct s *b; b->j = 5;
9255   }
9256   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9257     const int foo = 10;
9258     if (!foo) return 0;
9259   }
9260   return !cs[0] && !zero.x;
9261 #endif
9262
9263   ;
9264   return 0;
9265 }
9266 _ACEOF
9267 if ac_fn_c_try_compile "$LINENO"; then :
9268   ac_cv_c_const=yes
9269 else
9270   ac_cv_c_const=no
9271 fi
9272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9273 fi
9274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
9275 $as_echo "$ac_cv_c_const" >&6; }
9276 if test $ac_cv_c_const = no; then
9277
9278 $as_echo "#define const /**/" >>confdefs.h
9279
9280 fi
9281
9282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
9283 $as_echo_n "checking for inline... " >&6; }
9284 if test "${ac_cv_c_inline+set}" = set; then :
9285   $as_echo_n "(cached) " >&6
9286 else
9287   ac_cv_c_inline=no
9288 for ac_kw in inline __inline__ __inline; do
9289   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9290 /* end confdefs.h.  */
9291 #ifndef __cplusplus
9292 typedef int foo_t;
9293 static $ac_kw foo_t static_foo () {return 0; }
9294 $ac_kw foo_t foo () {return 0; }
9295 #endif
9296
9297 _ACEOF
9298 if ac_fn_c_try_compile "$LINENO"; then :
9299   ac_cv_c_inline=$ac_kw
9300 fi
9301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9302   test "$ac_cv_c_inline" != no && break
9303 done
9304
9305 fi
9306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
9307 $as_echo "$ac_cv_c_inline" >&6; }
9308
9309 case $ac_cv_c_inline in
9310   inline | yes) ;;
9311   *)
9312     case $ac_cv_c_inline in
9313       no) ac_val=;;
9314       *) ac_val=$ac_cv_c_inline;;
9315     esac
9316     cat >>confdefs.h <<_ACEOF
9317 #ifndef __cplusplus
9318 #define inline $ac_val
9319 #endif
9320 _ACEOF
9321     ;;
9322 esac
9323
9324  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9325 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
9326 if test "${ac_cv_c_bigendian+set}" = set; then :
9327   $as_echo_n "(cached) " >&6
9328 else
9329   ac_cv_c_bigendian=unknown
9330     # See if we're dealing with a universal compiler.
9331     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9332 /* end confdefs.h.  */
9333 #ifndef __APPLE_CC__
9334                not a universal capable compiler
9335              #endif
9336              typedef int dummy;
9337
9338 _ACEOF
9339 if ac_fn_c_try_compile "$LINENO"; then :
9340
9341         # Check for potential -arch flags.  It is not universal unless
9342         # there are at least two -arch flags with different values.
9343         ac_arch=
9344         ac_prev=
9345         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9346          if test -n "$ac_prev"; then
9347            case $ac_word in
9348              i?86 | x86_64 | ppc | ppc64)
9349                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9350                  ac_arch=$ac_word
9351                else
9352                  ac_cv_c_bigendian=universal
9353                  break
9354                fi
9355                ;;
9356            esac
9357            ac_prev=
9358          elif test "x$ac_word" = "x-arch"; then
9359            ac_prev=arch
9360          fi
9361        done
9362 fi
9363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9364     if test $ac_cv_c_bigendian = unknown; then
9365       # See if sys/param.h defines the BYTE_ORDER macro.
9366       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9367 /* end confdefs.h.  */
9368 #include <sys/types.h>
9369              #include <sys/param.h>
9370
9371 int
9372 main ()
9373 {
9374 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9375                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9376                      && LITTLE_ENDIAN)
9377               bogus endian macros
9378              #endif
9379
9380   ;
9381   return 0;
9382 }
9383 _ACEOF
9384 if ac_fn_c_try_compile "$LINENO"; then :
9385   # It does; now see whether it defined to BIG_ENDIAN or not.
9386          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9387 /* end confdefs.h.  */
9388 #include <sys/types.h>
9389                 #include <sys/param.h>
9390
9391 int
9392 main ()
9393 {
9394 #if BYTE_ORDER != BIG_ENDIAN
9395                  not big endian
9396                 #endif
9397
9398   ;
9399   return 0;
9400 }
9401 _ACEOF
9402 if ac_fn_c_try_compile "$LINENO"; then :
9403   ac_cv_c_bigendian=yes
9404 else
9405   ac_cv_c_bigendian=no
9406 fi
9407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9408 fi
9409 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9410     fi
9411     if test $ac_cv_c_bigendian = unknown; then
9412       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9413       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9414 /* end confdefs.h.  */
9415 #include <limits.h>
9416
9417 int
9418 main ()
9419 {
9420 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9421               bogus endian macros
9422              #endif
9423
9424   ;
9425   return 0;
9426 }
9427 _ACEOF
9428 if ac_fn_c_try_compile "$LINENO"; then :
9429   # It does; now see whether it defined to _BIG_ENDIAN or not.
9430          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9431 /* end confdefs.h.  */
9432 #include <limits.h>
9433
9434 int
9435 main ()
9436 {
9437 #ifndef _BIG_ENDIAN
9438                  not big endian
9439                 #endif
9440
9441   ;
9442   return 0;
9443 }
9444 _ACEOF
9445 if ac_fn_c_try_compile "$LINENO"; then :
9446   ac_cv_c_bigendian=yes
9447 else
9448   ac_cv_c_bigendian=no
9449 fi
9450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9451 fi
9452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9453     fi
9454     if test $ac_cv_c_bigendian = unknown; then
9455       # Compile a test program.
9456       if test "$cross_compiling" = yes; then :
9457   # Try to guess by grepping values from an object file.
9458          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9459 /* end confdefs.h.  */
9460 short int ascii_mm[] =
9461                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9462                 short int ascii_ii[] =
9463                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9464                 int use_ascii (int i) {
9465                   return ascii_mm[i] + ascii_ii[i];
9466                 }
9467                 short int ebcdic_ii[] =
9468                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9469                 short int ebcdic_mm[] =
9470                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9471                 int use_ebcdic (int i) {
9472                   return ebcdic_mm[i] + ebcdic_ii[i];
9473                 }
9474                 extern int foo;
9475
9476 int
9477 main ()
9478 {
9479 return use_ascii (foo) == use_ebcdic (foo);
9480   ;
9481   return 0;
9482 }
9483 _ACEOF
9484 if ac_fn_c_try_compile "$LINENO"; then :
9485   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9486               ac_cv_c_bigendian=yes
9487             fi
9488             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9489               if test "$ac_cv_c_bigendian" = unknown; then
9490                 ac_cv_c_bigendian=no
9491               else
9492                 # finding both strings is unlikely to happen, but who knows?
9493                 ac_cv_c_bigendian=unknown
9494               fi
9495             fi
9496 fi
9497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9498 else
9499   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9500 /* end confdefs.h.  */
9501 $ac_includes_default
9502 int
9503 main ()
9504 {
9505
9506              /* Are we little or big endian?  From Harbison&Steele.  */
9507              union
9508              {
9509                long int l;
9510                char c[sizeof (long int)];
9511              } u;
9512              u.l = 1;
9513              return u.c[sizeof (long int) - 1] == 1;
9514
9515   ;
9516   return 0;
9517 }
9518 _ACEOF
9519 if ac_fn_c_try_run "$LINENO"; then :
9520   ac_cv_c_bigendian=no
9521 else
9522   ac_cv_c_bigendian=yes
9523 fi
9524 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9525   conftest.$ac_objext conftest.beam conftest.$ac_ext
9526 fi
9527
9528     fi
9529 fi
9530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9531 $as_echo "$ac_cv_c_bigendian" >&6; }
9532  case $ac_cv_c_bigendian in #(
9533    yes)
9534      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9535 ;; #(
9536    no)
9537       ;; #(
9538    universal)
9539
9540 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9541
9542      ;; #(
9543    *)
9544      as_fn_error "unknown endianness
9545  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9546  esac
9547
9548
9549 # ------------------------------ #
9550 # Checks for library functions.  #
9551 # ------------------------------ #
9552
9553 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
9554 # for constant arguments.  Useless!
9555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
9556 $as_echo_n "checking for working alloca.h... " >&6; }
9557 if test "${ac_cv_working_alloca_h+set}" = set; then :
9558   $as_echo_n "(cached) " >&6
9559 else
9560   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9561 /* end confdefs.h.  */
9562 #include <alloca.h>
9563 int
9564 main ()
9565 {
9566 char *p = (char *) alloca (2 * sizeof (int));
9567                           if (p) return 0;
9568   ;
9569   return 0;
9570 }
9571 _ACEOF
9572 if ac_fn_c_try_link "$LINENO"; then :
9573   ac_cv_working_alloca_h=yes
9574 else
9575   ac_cv_working_alloca_h=no
9576 fi
9577 rm -f core conftest.err conftest.$ac_objext \
9578     conftest$ac_exeext conftest.$ac_ext
9579 fi
9580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
9581 $as_echo "$ac_cv_working_alloca_h" >&6; }
9582 if test $ac_cv_working_alloca_h = yes; then
9583
9584 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
9585
9586 fi
9587
9588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
9589 $as_echo_n "checking for alloca... " >&6; }
9590 if test "${ac_cv_func_alloca_works+set}" = set; then :
9591   $as_echo_n "(cached) " >&6
9592 else
9593   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9594 /* end confdefs.h.  */
9595 #ifdef __GNUC__
9596 # define alloca __builtin_alloca
9597 #else
9598 # ifdef _MSC_VER
9599 #  include <malloc.h>
9600 #  define alloca _alloca
9601 # else
9602 #  ifdef HAVE_ALLOCA_H
9603 #   include <alloca.h>
9604 #  else
9605 #   ifdef _AIX
9606  #pragma alloca
9607 #   else
9608 #    ifndef alloca /* predefined by HP cc +Olibcalls */
9609 char *alloca ();
9610 #    endif
9611 #   endif
9612 #  endif
9613 # endif
9614 #endif
9615
9616 int
9617 main ()
9618 {
9619 char *p = (char *) alloca (1);
9620                                     if (p) return 0;
9621   ;
9622   return 0;
9623 }
9624 _ACEOF
9625 if ac_fn_c_try_link "$LINENO"; then :
9626   ac_cv_func_alloca_works=yes
9627 else
9628   ac_cv_func_alloca_works=no
9629 fi
9630 rm -f core conftest.err conftest.$ac_objext \
9631     conftest$ac_exeext conftest.$ac_ext
9632 fi
9633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
9634 $as_echo "$ac_cv_func_alloca_works" >&6; }
9635
9636 if test $ac_cv_func_alloca_works = yes; then
9637
9638 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
9639
9640 else
9641   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
9642 # that cause trouble.  Some versions do not even contain alloca or
9643 # contain a buggy version.  If you still want to use their alloca,
9644 # use ar to extract alloca.o from them instead of compiling alloca.c.
9645
9646 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
9647
9648 $as_echo "#define C_ALLOCA 1" >>confdefs.h
9649
9650
9651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
9652 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
9653 if test "${ac_cv_os_cray+set}" = set; then :
9654   $as_echo_n "(cached) " >&6
9655 else
9656   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9657 /* end confdefs.h.  */
9658 #if defined CRAY && ! defined CRAY2
9659 webecray
9660 #else
9661 wenotbecray
9662 #endif
9663
9664 _ACEOF
9665 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9666   $EGREP "webecray" >/dev/null 2>&1; then :
9667   ac_cv_os_cray=yes
9668 else
9669   ac_cv_os_cray=no
9670 fi
9671 rm -f conftest*
9672
9673 fi
9674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
9675 $as_echo "$ac_cv_os_cray" >&6; }
9676 if test $ac_cv_os_cray = yes; then
9677   for ac_func in _getb67 GETB67 getb67; do
9678     as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9679 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9680 eval as_val=\$$as_ac_var
9681    if test "x$as_val" = x""yes; then :
9682
9683 cat >>confdefs.h <<_ACEOF
9684 #define CRAY_STACKSEG_END $ac_func
9685 _ACEOF
9686
9687     break
9688 fi
9689
9690   done
9691 fi
9692
9693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
9694 $as_echo_n "checking stack direction for C alloca... " >&6; }
9695 if test "${ac_cv_c_stack_direction+set}" = set; then :
9696   $as_echo_n "(cached) " >&6
9697 else
9698   if test "$cross_compiling" = yes; then :
9699   ac_cv_c_stack_direction=0
9700 else
9701   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9702 /* end confdefs.h.  */
9703 $ac_includes_default
9704 int
9705 find_stack_direction ()
9706 {
9707   static char *addr = 0;
9708   auto char dummy;
9709   if (addr == 0)
9710     {
9711       addr = &dummy;
9712       return find_stack_direction ();
9713     }
9714   else
9715     return (&dummy > addr) ? 1 : -1;
9716 }
9717
9718 int
9719 main ()
9720 {
9721   return find_stack_direction () < 0;
9722 }
9723 _ACEOF
9724 if ac_fn_c_try_run "$LINENO"; then :
9725   ac_cv_c_stack_direction=1
9726 else
9727   ac_cv_c_stack_direction=-1
9728 fi
9729 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9730   conftest.$ac_objext conftest.beam conftest.$ac_ext
9731 fi
9732
9733 fi
9734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
9735 $as_echo "$ac_cv_c_stack_direction" >&6; }
9736 cat >>confdefs.h <<_ACEOF
9737 #define STACK_DIRECTION $ac_cv_c_stack_direction
9738 _ACEOF
9739
9740
9741 fi
9742
9743 for ac_header in stdlib.h unistd.h
9744 do :
9745   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9746 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9747 eval as_val=\$$as_ac_Header
9748    if test "x$as_val" = x""yes; then :
9749   cat >>confdefs.h <<_ACEOF
9750 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9751 _ACEOF
9752
9753 fi
9754
9755 done
9756
9757 for ac_func in getpagesize
9758 do :
9759   ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9760 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9761   cat >>confdefs.h <<_ACEOF
9762 #define HAVE_GETPAGESIZE 1
9763 _ACEOF
9764
9765 fi
9766 done
9767
9768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9769 $as_echo_n "checking for working mmap... " >&6; }
9770 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9771   $as_echo_n "(cached) " >&6
9772 else
9773   if test "$cross_compiling" = yes; then :
9774   ac_cv_func_mmap_fixed_mapped=no
9775 else
9776   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9777 /* end confdefs.h.  */
9778 $ac_includes_default
9779 /* malloc might have been renamed as rpl_malloc. */
9780 #undef malloc
9781
9782 /* Thanks to Mike Haertel and Jim Avera for this test.
9783    Here is a matrix of mmap possibilities:
9784         mmap private not fixed
9785         mmap private fixed at somewhere currently unmapped
9786         mmap private fixed at somewhere already mapped
9787         mmap shared not fixed
9788         mmap shared fixed at somewhere currently unmapped
9789         mmap shared fixed at somewhere already mapped
9790    For private mappings, we should verify that changes cannot be read()
9791    back from the file, nor mmap's back from the file at a different
9792    address.  (There have been systems where private was not correctly
9793    implemented like the infamous i386 svr4.0, and systems where the
9794    VM page cache was not coherent with the file system buffer cache
9795    like early versions of FreeBSD and possibly contemporary NetBSD.)
9796    For shared mappings, we should conversely verify that changes get
9797    propagated back to all the places they're supposed to be.
9798
9799    Grep wants private fixed already mapped.
9800    The main things grep needs to know about mmap are:
9801    * does it exist and is it safe to write into the mmap'd area
9802    * how to use it (BSD variants)  */
9803
9804 #include <fcntl.h>
9805 #include <sys/mman.h>
9806
9807 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9808 char *malloc ();
9809 #endif
9810
9811 /* This mess was copied from the GNU getpagesize.h.  */
9812 #ifndef HAVE_GETPAGESIZE
9813 /* Assume that all systems that can run configure have sys/param.h.  */
9814 # ifndef HAVE_SYS_PARAM_H
9815 #  define HAVE_SYS_PARAM_H 1
9816 # endif
9817
9818 # ifdef _SC_PAGESIZE
9819 #  define getpagesize() sysconf(_SC_PAGESIZE)
9820 # else /* no _SC_PAGESIZE */
9821 #  ifdef HAVE_SYS_PARAM_H
9822 #   include <sys/param.h>
9823 #   ifdef EXEC_PAGESIZE
9824 #    define getpagesize() EXEC_PAGESIZE
9825 #   else /* no EXEC_PAGESIZE */
9826 #    ifdef NBPG
9827 #     define getpagesize() NBPG * CLSIZE
9828 #     ifndef CLSIZE
9829 #      define CLSIZE 1
9830 #     endif /* no CLSIZE */
9831 #    else /* no NBPG */
9832 #     ifdef NBPC
9833 #      define getpagesize() NBPC
9834 #     else /* no NBPC */
9835 #      ifdef PAGESIZE
9836 #       define getpagesize() PAGESIZE
9837 #      endif /* PAGESIZE */
9838 #     endif /* no NBPC */
9839 #    endif /* no NBPG */
9840 #   endif /* no EXEC_PAGESIZE */
9841 #  else /* no HAVE_SYS_PARAM_H */
9842 #   define getpagesize() 8192   /* punt totally */
9843 #  endif /* no HAVE_SYS_PARAM_H */
9844 # endif /* no _SC_PAGESIZE */
9845
9846 #endif /* no HAVE_GETPAGESIZE */
9847
9848 int
9849 main ()
9850 {
9851   char *data, *data2, *data3;
9852   int i, pagesize;
9853   int fd;
9854
9855   pagesize = getpagesize ();
9856
9857   /* First, make a file with some known garbage in it. */
9858   data = (char *) malloc (pagesize);
9859   if (!data)
9860     return 1;
9861   for (i = 0; i < pagesize; ++i)
9862     *(data + i) = rand ();
9863   umask (0);
9864   fd = creat ("conftest.mmap", 0600);
9865   if (fd < 0)
9866     return 1;
9867   if (write (fd, data, pagesize) != pagesize)
9868     return 1;
9869   close (fd);
9870
9871   /* Next, try to mmap the file at a fixed address which already has
9872      something else allocated at it.  If we can, also make sure that
9873      we see the same garbage.  */
9874   fd = open ("conftest.mmap", O_RDWR);
9875   if (fd < 0)
9876     return 1;
9877   data2 = (char *) malloc (2 * pagesize);
9878   if (!data2)
9879     return 1;
9880   data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1);
9881   if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9882                      MAP_PRIVATE | MAP_FIXED, fd, 0L))
9883     return 1;
9884   for (i = 0; i < pagesize; ++i)
9885     if (*(data + i) != *(data2 + i))
9886       return 1;
9887
9888   /* Finally, make sure that changes to the mapped area do not
9889      percolate back to the file as seen by read().  (This is a bug on
9890      some variants of i386 svr4.0.)  */
9891   for (i = 0; i < pagesize; ++i)
9892     *(data2 + i) = *(data2 + i) + 1;
9893   data3 = (char *) malloc (pagesize);
9894   if (!data3)
9895     return 1;
9896   if (read (fd, data3, pagesize) != pagesize)
9897     return 1;
9898   for (i = 0; i < pagesize; ++i)
9899     if (*(data + i) != *(data3 + i))
9900       return 1;
9901   close (fd);
9902   return 0;
9903 }
9904 _ACEOF
9905 if ac_fn_c_try_run "$LINENO"; then :
9906   ac_cv_func_mmap_fixed_mapped=yes
9907 else
9908   ac_cv_func_mmap_fixed_mapped=no
9909 fi
9910 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9911   conftest.$ac_objext conftest.beam conftest.$ac_ext
9912 fi
9913
9914 fi
9915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9916 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9917 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9918
9919 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9920
9921 fi
9922 rm -f conftest.mmap
9923
9924 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
9925 if test "x$ac_cv_type_pid_t" = x""yes; then :
9926
9927 else
9928
9929 cat >>confdefs.h <<_ACEOF
9930 #define pid_t int
9931 _ACEOF
9932
9933 fi
9934
9935 for ac_header in vfork.h
9936 do :
9937   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
9938 if test "x$ac_cv_header_vfork_h" = x""yes; then :
9939   cat >>confdefs.h <<_ACEOF
9940 #define HAVE_VFORK_H 1
9941 _ACEOF
9942
9943 fi
9944
9945 done
9946
9947 for ac_func in fork vfork
9948 do :
9949   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9950 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9951 eval as_val=\$$as_ac_var
9952    if test "x$as_val" = x""yes; then :
9953   cat >>confdefs.h <<_ACEOF
9954 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9955 _ACEOF
9956
9957 fi
9958 done
9959
9960 if test "x$ac_cv_func_fork" = xyes; then
9961   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
9962 $as_echo_n "checking for working fork... " >&6; }
9963 if test "${ac_cv_func_fork_works+set}" = set; then :
9964   $as_echo_n "(cached) " >&6
9965 else
9966   if test "$cross_compiling" = yes; then :
9967   ac_cv_func_fork_works=cross
9968 else
9969   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9970 /* end confdefs.h.  */
9971 $ac_includes_default
9972 int
9973 main ()
9974 {
9975
9976           /* By Ruediger Kuhlmann. */
9977           return fork () < 0;
9978
9979   ;
9980   return 0;
9981 }
9982 _ACEOF
9983 if ac_fn_c_try_run "$LINENO"; then :
9984   ac_cv_func_fork_works=yes
9985 else
9986   ac_cv_func_fork_works=no
9987 fi
9988 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9989   conftest.$ac_objext conftest.beam conftest.$ac_ext
9990 fi
9991
9992 fi
9993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
9994 $as_echo "$ac_cv_func_fork_works" >&6; }
9995
9996 else
9997   ac_cv_func_fork_works=$ac_cv_func_fork
9998 fi
9999 if test "x$ac_cv_func_fork_works" = xcross; then
10000   case $host in
10001     *-*-amigaos* | *-*-msdosdjgpp*)
10002       # Override, as these systems have only a dummy fork() stub
10003       ac_cv_func_fork_works=no
10004       ;;
10005     *)
10006       ac_cv_func_fork_works=yes
10007       ;;
10008   esac
10009   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
10010 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
10011 fi
10012 ac_cv_func_vfork_works=$ac_cv_func_vfork
10013 if test "x$ac_cv_func_vfork" = xyes; then
10014   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
10015 $as_echo_n "checking for working vfork... " >&6; }
10016 if test "${ac_cv_func_vfork_works+set}" = set; then :
10017   $as_echo_n "(cached) " >&6
10018 else
10019   if test "$cross_compiling" = yes; then :
10020   ac_cv_func_vfork_works=cross
10021 else
10022   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10023 /* end confdefs.h.  */
10024 /* Thanks to Paul Eggert for this test.  */
10025 $ac_includes_default
10026 #include <sys/wait.h>
10027 #ifdef HAVE_VFORK_H
10028 # include <vfork.h>
10029 #endif
10030 /* On some sparc systems, changes by the child to local and incoming
10031    argument registers are propagated back to the parent.  The compiler
10032    is told about this with #include <vfork.h>, but some compilers
10033    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
10034    static variable whose address is put into a register that is
10035    clobbered by the vfork.  */
10036 static void
10037 #ifdef __cplusplus
10038 sparc_address_test (int arg)
10039 # else
10040 sparc_address_test (arg) int arg;
10041 #endif
10042 {
10043   static pid_t child;
10044   if (!child) {
10045     child = vfork ();
10046     if (child < 0) {
10047       perror ("vfork");
10048       _exit(2);
10049     }
10050     if (!child) {
10051       arg = getpid();
10052       write(-1, "", 0);
10053       _exit (arg);
10054     }
10055   }
10056 }
10057
10058 int
10059 main ()
10060 {
10061   pid_t parent = getpid ();
10062   pid_t child;
10063
10064   sparc_address_test (0);
10065
10066   child = vfork ();
10067
10068   if (child == 0) {
10069     /* Here is another test for sparc vfork register problems.  This
10070        test uses lots of local variables, at least as many local
10071        variables as main has allocated so far including compiler
10072        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
10073        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
10074        reuse the register of parent for one of the local variables,
10075        since it will think that parent can't possibly be used any more
10076        in this routine.  Assigning to the local variable will thus
10077        munge parent in the parent process.  */
10078     pid_t
10079       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
10080       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
10081     /* Convince the compiler that p..p7 are live; otherwise, it might
10082        use the same hardware register for all 8 local variables.  */
10083     if (p != p1 || p != p2 || p != p3 || p != p4
10084         || p != p5 || p != p6 || p != p7)
10085       _exit(1);
10086
10087     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
10088        from child file descriptors.  If the child closes a descriptor
10089        before it execs or exits, this munges the parent's descriptor
10090        as well.  Test for this by closing stdout in the child.  */
10091     _exit(close(fileno(stdout)) != 0);
10092   } else {
10093     int status;
10094     struct stat st;
10095
10096     while (wait(&status) != child)
10097       ;
10098     return (
10099          /* Was there some problem with vforking?  */
10100          child < 0
10101
10102          /* Did the child fail?  (This shouldn't happen.)  */
10103          || status
10104
10105          /* Did the vfork/compiler bug occur?  */
10106          || parent != getpid()
10107
10108          /* Did the file descriptor bug occur?  */
10109          || fstat(fileno(stdout), &st) != 0
10110          );
10111   }
10112 }
10113 _ACEOF
10114 if ac_fn_c_try_run "$LINENO"; then :
10115   ac_cv_func_vfork_works=yes
10116 else
10117   ac_cv_func_vfork_works=no
10118 fi
10119 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10120   conftest.$ac_objext conftest.beam conftest.$ac_ext
10121 fi
10122
10123 fi
10124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
10125 $as_echo "$ac_cv_func_vfork_works" >&6; }
10126
10127 fi;
10128 if test "x$ac_cv_func_fork_works" = xcross; then
10129   ac_cv_func_vfork_works=$ac_cv_func_vfork
10130   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
10131 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
10132 fi
10133
10134 if test "x$ac_cv_func_vfork_works" = xyes; then
10135
10136 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
10137
10138 else
10139
10140 $as_echo "#define vfork fork" >>confdefs.h
10141
10142 fi
10143 if test "x$ac_cv_func_fork_works" = xyes; then
10144
10145 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
10146
10147 fi
10148
10149 for ac_func in canonicalize_file_name realpath getrusage getuid getgid \
10150                 pipe poll pread pread64 pwrite readlink resize_term \
10151                 sbrk setpgid setpgrp setsid \
10152                 sigaction sigprocmask sigsetmask socketpair syscall \
10153                 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
10154                 setrlimit getrlimit posix_madvise waitpid lstat
10155 do :
10156   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10157 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10158 eval as_val=\$$as_ac_var
10159    if test "x$as_val" = x""yes; then :
10160   cat >>confdefs.h <<_ACEOF
10161 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10162 _ACEOF
10163
10164 fi
10165 done
10166
10167
10168   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
10169 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
10170 if test "${am_cv_langinfo_codeset+set}" = set; then :
10171   $as_echo_n "(cached) " >&6
10172 else
10173   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10174 /* end confdefs.h.  */
10175 #include <langinfo.h>
10176 int
10177 main ()
10178 {
10179 char* cs = nl_langinfo(CODESET);
10180   ;
10181   return 0;
10182 }
10183 _ACEOF
10184 if ac_fn_c_try_link "$LINENO"; then :
10185   am_cv_langinfo_codeset=yes
10186 else
10187   am_cv_langinfo_codeset=no
10188 fi
10189 rm -f core conftest.err conftest.$ac_objext \
10190     conftest$ac_exeext conftest.$ac_ext
10191
10192 fi
10193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
10194 $as_echo "$am_cv_langinfo_codeset" >&6; }
10195   if test $am_cv_langinfo_codeset = yes; then
10196
10197 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
10198
10199   fi
10200
10201
10202 # Check the return and argument types of ptrace.  No canned test for
10203 # this, so roll our own.
10204 gdb_ptrace_headers='
10205 #if HAVE_SYS_TYPES_H
10206 # include <sys/types.h>
10207 #endif
10208 #if HAVE_SYS_PTRACE_H
10209 # include <sys/ptrace.h>
10210 #endif
10211 #if HAVE_UNISTD_H
10212 # include <unistd.h>
10213 #endif
10214 '
10215 # There is no point in checking if we don't have a prototype.
10216 ac_fn_c_check_decl "$LINENO" "ptrace" "ac_cv_have_decl_ptrace" "$gdb_ptrace_headers
10217 "
10218 if test "x$ac_cv_have_decl_ptrace" = x""yes; then :
10219   ac_have_decl=1
10220 else
10221   ac_have_decl=0
10222 fi
10223
10224 cat >>confdefs.h <<_ACEOF
10225 #define HAVE_DECL_PTRACE $ac_have_decl
10226 _ACEOF
10227 if test $ac_have_decl = 1; then :
10228
10229 else
10230
10231   : ${gdb_cv_func_ptrace_ret='int'}
10232   : ${gdb_cv_func_ptrace_args='int,int,long,long'}
10233
10234 fi
10235
10236 # Check return type.  Varargs (used on GNU/Linux) conflict with the
10237 # empty argument list, so check for that explicitly.
10238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
10239 $as_echo_n "checking return type of ptrace... " >&6; }
10240 if test "${gdb_cv_func_ptrace_ret+set}" = set; then :
10241   $as_echo_n "(cached) " >&6
10242 else
10243   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10244 /* end confdefs.h.  */
10245 $gdb_ptrace_headers
10246 int
10247 main ()
10248 {
10249 extern long ptrace (enum __ptrace_request, ...);
10250   ;
10251   return 0;
10252 }
10253 _ACEOF
10254 if ac_fn_c_try_compile "$LINENO"; then :
10255   gdb_cv_func_ptrace_ret='long'
10256 else
10257   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10258 /* end confdefs.h.  */
10259 $gdb_ptrace_headers
10260 int
10261 main ()
10262 {
10263 extern int ptrace ();
10264   ;
10265   return 0;
10266 }
10267 _ACEOF
10268 if ac_fn_c_try_compile "$LINENO"; then :
10269   gdb_cv_func_ptrace_ret='int'
10270 else
10271   gdb_cv_func_ptrace_ret='long'
10272 fi
10273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10274 fi
10275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10276 fi
10277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
10278 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
10279
10280 cat >>confdefs.h <<_ACEOF
10281 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
10282 _ACEOF
10283
10284 # Check argument types.
10285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
10286 $as_echo_n "checking types of arguments for ptrace... " >&6; }
10287 if test "${gdb_cv_func_ptrace_args+set}" = set; then :
10288   $as_echo_n "(cached) " >&6
10289 else
10290
10291   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10292 /* end confdefs.h.  */
10293 $gdb_ptrace_headers
10294 int
10295 main ()
10296 {
10297 extern long ptrace (enum __ptrace_request, ...);
10298   ;
10299   return 0;
10300 }
10301 _ACEOF
10302 if ac_fn_c_try_compile "$LINENO"; then :
10303   gdb_cv_func_ptrace_args='int,int,long,long'
10304 else
10305
10306 for gdb_arg1 in 'int' 'long'; do
10307  for gdb_arg2 in 'pid_t' 'int' 'long'; do
10308   for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
10309    for gdb_arg4 in 'int' 'long'; do
10310      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10311 /* end confdefs.h.  */
10312 $gdb_ptrace_headers
10313 int
10314 main ()
10315 {
10316
10317 extern $gdb_cv_func_ptrace_ret
10318   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
10319
10320   ;
10321   return 0;
10322 }
10323 _ACEOF
10324 if ac_fn_c_try_compile "$LINENO"; then :
10325   gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
10326     break 4;
10327 fi
10328 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10329     for gdb_arg5 in 'int *' 'int' 'long'; do
10330      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10331 /* end confdefs.h.  */
10332 $gdb_ptrace_headers
10333 int
10334 main ()
10335 {
10336
10337 extern $gdb_cv_func_ptrace_ret
10338   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
10339
10340   ;
10341   return 0;
10342 }
10343 _ACEOF
10344 if ac_fn_c_try_compile "$LINENO"; then :
10345
10346 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
10347     break 5;
10348 fi
10349 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10350     done
10351    done
10352   done
10353  done
10354 done
10355 # Provide a safe default value.
10356 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
10357
10358 fi
10359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10360 fi
10361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
10362 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
10363 ac_save_IFS=$IFS; IFS=','
10364 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
10365 IFS=$ac_save_IFS
10366 shift
10367
10368 cat >>confdefs.h <<_ACEOF
10369 #define PTRACE_TYPE_ARG3 $3
10370 _ACEOF
10371
10372 if test -n "$5"; then
10373
10374 cat >>confdefs.h <<_ACEOF
10375 #define PTRACE_TYPE_ARG5 $5
10376 _ACEOF
10377
10378 fi
10379
10380 if test "$cross_compiling" = no; then
10381   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
10382 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
10383 if test "${ac_cv_func_setpgrp_void+set}" = set; then :
10384   $as_echo_n "(cached) " >&6
10385 else
10386   if test "$cross_compiling" = yes; then :
10387   as_fn_error "cannot check setpgrp when cross compiling" "$LINENO" 5
10388 else
10389   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10390 /* end confdefs.h.  */
10391 $ac_includes_default
10392 int
10393 main ()
10394 {
10395 /* If this system has a BSD-style setpgrp which takes arguments,
10396   setpgrp(1, 1) will fail with ESRCH and return -1, in that case
10397   exit successfully. */
10398   return setpgrp (1,1) != -1;
10399   ;
10400   return 0;
10401 }
10402 _ACEOF
10403 if ac_fn_c_try_run "$LINENO"; then :
10404   ac_cv_func_setpgrp_void=no
10405 else
10406   ac_cv_func_setpgrp_void=yes
10407 fi
10408 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10409   conftest.$ac_objext conftest.beam conftest.$ac_ext
10410 fi
10411
10412 fi
10413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
10414 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
10415 if test $ac_cv_func_setpgrp_void = yes; then
10416
10417 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
10418
10419 fi
10420
10421 else
10422   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
10423 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
10424 if test "${ac_cv_func_setpgrp_void+set}" = set; then :
10425   $as_echo_n "(cached) " >&6
10426 else
10427   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10428 /* end confdefs.h.  */
10429
10430 #include <unistd.h>
10431
10432 int
10433 main ()
10434 {
10435
10436   if (setpgrp(1,1) == -1)
10437     exit (0);
10438   else
10439     exit (1);
10440
10441   ;
10442   return 0;
10443 }
10444 _ACEOF
10445 if ac_fn_c_try_compile "$LINENO"; then :
10446   ac_cv_func_setpgrp_void=no
10447 else
10448   ac_cv_func_setpgrp_void=yes
10449 fi
10450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10451 fi
10452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
10453 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
10454 if test $ac_cv_func_setpgrp_void = yes; then
10455   $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
10456
10457 fi
10458 fi
10459
10460 # Check if sigsetjmp is available.  Using AC_CHECK_FUNCS won't do
10461 # since sigsetjmp might only be defined as a macro.
10462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
10463 $as_echo_n "checking for sigsetjmp... " >&6; }
10464 if test "${gdb_cv_func_sigsetjmp+set}" = set; then :
10465   $as_echo_n "(cached) " >&6
10466 else
10467   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10468 /* end confdefs.h.  */
10469
10470 #include <setjmp.h>
10471
10472 int
10473 main ()
10474 {
10475 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
10476   ;
10477   return 0;
10478 }
10479 _ACEOF
10480 if ac_fn_c_try_compile "$LINENO"; then :
10481   gdb_cv_func_sigsetjmp=yes
10482 else
10483   gdb_cv_func_sigsetjmp=no
10484 fi
10485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10486 fi
10487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
10488 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
10489 if test $gdb_cv_func_sigsetjmp = yes; then
10490
10491 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
10492
10493 fi
10494
10495 # Assume we'll default to using the included libiberty regex.
10496 gdb_use_included_regex=yes
10497
10498 # However, if the system regex is GNU regex, then default to *not*
10499 # using the included regex.
10500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
10501 $as_echo_n "checking for GNU regex... " >&6; }
10502 if test "${gdb_cv_have_gnu_regex+set}" = set; then :
10503   $as_echo_n "(cached) " >&6
10504 else
10505   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10506 /* end confdefs.h.  */
10507 #include <gnu-versions.h>
10508 int
10509 main ()
10510 {
10511 #define REGEX_INTERFACE_VERSION 1
10512 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
10513 # error "Version mismatch"
10514 #endif
10515   ;
10516   return 0;
10517 }
10518 _ACEOF
10519 if ac_fn_c_try_compile "$LINENO"; then :
10520   gdb_cv_have_gnu_regex=yes
10521 else
10522   gdb_cv_have_gnu_regex=no
10523 fi
10524 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10525 fi
10526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
10527 $as_echo "$gdb_cv_have_gnu_regex" >&6; }
10528 if test $gdb_cv_have_gnu_regex = yes; then
10529   gdb_use_included_regex=no
10530 fi
10531
10532
10533 # Check whether --with-included-regex was given.
10534 if test "${with_included_regex+set}" = set; then :
10535   withval=$with_included_regex; gdb_with_regex=$withval
10536 else
10537   gdb_with_regex=$gdb_use_included_regex
10538 fi
10539
10540 if test "$gdb_with_regex" = yes; then
10541
10542 $as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
10543
10544 fi
10545
10546 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
10547 ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
10548 #include <sys/proc.h>
10549
10550 "
10551 if test "x$ac_cv_member_struct_thread_td_pcb" = x""yes; then :
10552
10553 cat >>confdefs.h <<_ACEOF
10554 #define HAVE_STRUCT_THREAD_TD_PCB 1
10555 _ACEOF
10556
10557
10558 fi
10559
10560
10561 # See if <sys/lwp.h> defines `struct lwp`.
10562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
10563 $as_echo_n "checking for struct lwp... " >&6; }
10564 if test "${gdb_cv_struct_lwp+set}" = set; then :
10565   $as_echo_n "(cached) " >&6
10566 else
10567   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10568 /* end confdefs.h.  */
10569 #include <sys/param.h>
10570 #include <sys/lwp.h>
10571 int
10572 main ()
10573 {
10574 struct lwp l;
10575   ;
10576   return 0;
10577 }
10578 _ACEOF
10579 if ac_fn_c_try_compile "$LINENO"; then :
10580   gdb_cv_struct_lwp=yes
10581 else
10582   gdb_cv_struct_lwp=no
10583 fi
10584 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10585 fi
10586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
10587 $as_echo "$gdb_cv_struct_lwp" >&6; }
10588 if test $gdb_cv_struct_lwp = yes; then
10589
10590 $as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
10591
10592 fi
10593
10594 # See if <machine/reg.h> degines `struct reg'.
10595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
10596 $as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
10597 if test "${gdb_cv_struct_reg+set}" = set; then :
10598   $as_echo_n "(cached) " >&6
10599 else
10600   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10601 /* end confdefs.h.  */
10602 #include <sys/types.h>
10603 #include <machine/reg.h>
10604 int
10605 main ()
10606 {
10607 struct reg r;
10608   ;
10609   return 0;
10610 }
10611 _ACEOF
10612 if ac_fn_c_try_compile "$LINENO"; then :
10613   gdb_cv_struct_reg=yes
10614 else
10615   gdb_cv_struct_reg=no
10616 fi
10617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10618 fi
10619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
10620 $as_echo "$gdb_cv_struct_reg" >&6; }
10621 if test $gdb_cv_struct_reg = yes; then
10622
10623 $as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
10624
10625 fi
10626
10627 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
10628 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
10629 ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <machine/reg.h>
10630 "
10631 if test "x$ac_cv_member_struct_reg_r_fs" = x""yes; then :
10632
10633 cat >>confdefs.h <<_ACEOF
10634 #define HAVE_STRUCT_REG_R_FS 1
10635 _ACEOF
10636
10637
10638 fi
10639 ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <machine/reg.h>
10640 "
10641 if test "x$ac_cv_member_struct_reg_r_gs" = x""yes; then :
10642
10643 cat >>confdefs.h <<_ACEOF
10644 #define HAVE_STRUCT_REG_R_GS 1
10645 _ACEOF
10646
10647
10648 fi
10649
10650
10651 # See if <sys/user.h> supports the %fs_base and %gs_bas amd64 segment registers.
10652 # Older amd64 Linux's don't have the fs_base and gs_base members of
10653 # `struct user_regs_struct'.
10654 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>
10655 "
10656 if test "x$ac_cv_member_struct_user_regs_struct_fs_base" = x""yes; then :
10657
10658 cat >>confdefs.h <<_ACEOF
10659 #define HAVE_STRUCT_USER_REGS_STRUCT_FS_BASE 1
10660 _ACEOF
10661
10662
10663 fi
10664 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>
10665 "
10666 if test "x$ac_cv_member_struct_user_regs_struct_gs_base" = x""yes; then :
10667
10668 cat >>confdefs.h <<_ACEOF
10669 #define HAVE_STRUCT_USER_REGS_STRUCT_GS_BASE 1
10670 _ACEOF
10671
10672
10673 fi
10674
10675
10676 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
10677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
10678 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
10679 if test "${gdb_cv_have_ptrace_getregs+set}" = set; then :
10680   $as_echo_n "(cached) " >&6
10681 else
10682   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10683 /* end confdefs.h.  */
10684 #include <sys/ptrace.h>
10685 int
10686 main ()
10687 {
10688 PTRACE_GETREGS;
10689   ;
10690   return 0;
10691 }
10692 _ACEOF
10693 if ac_fn_c_try_compile "$LINENO"; then :
10694   gdb_cv_have_ptrace_getregs=yes
10695 else
10696   gdb_cv_have_ptrace_getregs=no
10697 fi
10698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10699 fi
10700
10701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
10702 $as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
10703 if test $gdb_cv_have_ptrace_getregs = yes; then
10704
10705 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
10706
10707 fi
10708
10709 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
10710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
10711 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
10712 if test "${gdb_cv_have_ptrace_getfpxregs+set}" = set; then :
10713   $as_echo_n "(cached) " >&6
10714 else
10715   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10716 /* end confdefs.h.  */
10717 #include <sys/ptrace.h>
10718 int
10719 main ()
10720 {
10721 PTRACE_GETFPXREGS;
10722   ;
10723   return 0;
10724 }
10725 _ACEOF
10726 if ac_fn_c_try_compile "$LINENO"; then :
10727   gdb_cv_have_ptrace_getfpxregs=yes
10728 else
10729   gdb_cv_have_ptrace_getfpxregs=no
10730 fi
10731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10732 fi
10733
10734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
10735 $as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
10736 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
10737
10738 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
10739
10740 fi
10741
10742 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
10743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
10744 $as_echo_n "checking for PT_GETDBREGS... " >&6; }
10745 if test "${gdb_cv_have_pt_getdbregs+set}" = set; then :
10746   $as_echo_n "(cached) " >&6
10747 else
10748   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10749 /* end confdefs.h.  */
10750 #include <sys/types.h>
10751 #include <sys/ptrace.h>
10752 int
10753 main ()
10754 {
10755 PT_GETDBREGS;
10756   ;
10757   return 0;
10758 }
10759 _ACEOF
10760 if ac_fn_c_try_compile "$LINENO"; then :
10761   gdb_cv_have_pt_getdbregs=yes
10762 else
10763   gdb_cv_have_pt_getdbregs=no
10764 fi
10765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10766 fi
10767
10768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
10769 $as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
10770 if test $gdb_cv_have_pt_getdbregs = yes; then
10771
10772 $as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
10773
10774 fi
10775
10776 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
10777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
10778 $as_echo_n "checking for PT_GETXMMREGS... " >&6; }
10779 if test "${gdb_cv_have_pt_getxmmregs+set}" = set; then :
10780   $as_echo_n "(cached) " >&6
10781 else
10782   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10783 /* end confdefs.h.  */
10784 #include <sys/types.h>
10785 #include <sys/ptrace.h>
10786 int
10787 main ()
10788 {
10789 PT_GETXMMREGS;
10790   ;
10791   return 0;
10792 }
10793 _ACEOF
10794 if ac_fn_c_try_compile "$LINENO"; then :
10795   gdb_cv_have_pt_getxmmregs=yes
10796 else
10797   gdb_cv_have_pt_getxmmregs=no
10798 fi
10799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10800 fi
10801
10802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
10803 $as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
10804 if test $gdb_cv_have_pt_getxmmregs = yes; then
10805
10806 $as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
10807
10808 fi
10809
10810 # Detect which type of /proc is in use, such as for Solaris.
10811
10812 if test "${target}" = "${host}"; then
10813   case "${host}" in
10814   *-*-sysv4.2* | *-*-sysv5* | *-*-interix* )
10815
10816 $as_echo "#define NEW_PROC_API 1" >>confdefs.h
10817
10818       ;;
10819   *-*-solaris2.[6789] | *-*-solaris2.1[0-9]*)
10820
10821 $as_echo "#define NEW_PROC_API 1" >>confdefs.h
10822
10823       ;;
10824   mips-sgi-irix5*)
10825       # Work around <sys/proc.h> needing _KMEMUSER problem on IRIX 5.
10826
10827 $as_echo "#define _KMEMUSER 1" >>confdefs.h
10828
10829       ;;
10830   esac
10831 fi
10832
10833 if test "$ac_cv_header_sys_procfs_h" = yes; then
10834   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pstatus_t in sys/procfs.h" >&5
10835 $as_echo_n "checking for pstatus_t in sys/procfs.h... " >&6; }
10836  if test "${bfd_cv_have_sys_procfs_type_pstatus_t+set}" = set; then :
10837   $as_echo_n "(cached) " >&6
10838 else
10839   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10840 /* end confdefs.h.  */
10841
10842 #define _SYSCALL32
10843 /* Needed for new procfs interface on sparc-solaris.  */
10844 #define _STRUCTURED_PROC 1
10845 #include <sys/procfs.h>
10846 int
10847 main ()
10848 {
10849 pstatus_t avar
10850   ;
10851   return 0;
10852 }
10853 _ACEOF
10854 if ac_fn_c_try_compile "$LINENO"; then :
10855   bfd_cv_have_sys_procfs_type_pstatus_t=yes
10856 else
10857   bfd_cv_have_sys_procfs_type_pstatus_t=no
10858
10859 fi
10860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10861 fi
10862
10863  if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
10864
10865 $as_echo "#define HAVE_PSTATUS_T 1" >>confdefs.h
10866
10867  fi
10868  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pstatus_t" >&5
10869 $as_echo "$bfd_cv_have_sys_procfs_type_pstatus_t" >&6; }
10870
10871   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prrun_t in sys/procfs.h" >&5
10872 $as_echo_n "checking for prrun_t in sys/procfs.h... " >&6; }
10873  if test "${bfd_cv_have_sys_procfs_type_prrun_t+set}" = set; then :
10874   $as_echo_n "(cached) " >&6
10875 else
10876   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10877 /* end confdefs.h.  */
10878
10879 #define _SYSCALL32
10880 /* Needed for new procfs interface on sparc-solaris.  */
10881 #define _STRUCTURED_PROC 1
10882 #include <sys/procfs.h>
10883 int
10884 main ()
10885 {
10886 prrun_t avar
10887   ;
10888   return 0;
10889 }
10890 _ACEOF
10891 if ac_fn_c_try_compile "$LINENO"; then :
10892   bfd_cv_have_sys_procfs_type_prrun_t=yes
10893 else
10894   bfd_cv_have_sys_procfs_type_prrun_t=no
10895
10896 fi
10897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10898 fi
10899
10900  if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then
10901
10902 $as_echo "#define HAVE_PRRUN_T 1" >>confdefs.h
10903
10904  fi
10905  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prrun_t" >&5
10906 $as_echo "$bfd_cv_have_sys_procfs_type_prrun_t" >&6; }
10907
10908   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
10909 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
10910  if test "${bfd_cv_have_sys_procfs_type_gregset_t+set}" = set; then :
10911   $as_echo_n "(cached) " >&6
10912 else
10913   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10914 /* end confdefs.h.  */
10915
10916 #define _SYSCALL32
10917 /* Needed for new procfs interface on sparc-solaris.  */
10918 #define _STRUCTURED_PROC 1
10919 #include <sys/procfs.h>
10920 int
10921 main ()
10922 {
10923 gregset_t avar
10924   ;
10925   return 0;
10926 }
10927 _ACEOF
10928 if ac_fn_c_try_compile "$LINENO"; then :
10929   bfd_cv_have_sys_procfs_type_gregset_t=yes
10930 else
10931   bfd_cv_have_sys_procfs_type_gregset_t=no
10932
10933 fi
10934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10935 fi
10936
10937  if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
10938
10939 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
10940
10941  fi
10942  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
10943 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
10944
10945   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
10946 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
10947  if test "${bfd_cv_have_sys_procfs_type_fpregset_t+set}" = set; then :
10948   $as_echo_n "(cached) " >&6
10949 else
10950   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10951 /* end confdefs.h.  */
10952
10953 #define _SYSCALL32
10954 /* Needed for new procfs interface on sparc-solaris.  */
10955 #define _STRUCTURED_PROC 1
10956 #include <sys/procfs.h>
10957 int
10958 main ()
10959 {
10960 fpregset_t avar
10961   ;
10962   return 0;
10963 }
10964 _ACEOF
10965 if ac_fn_c_try_compile "$LINENO"; then :
10966   bfd_cv_have_sys_procfs_type_fpregset_t=yes
10967 else
10968   bfd_cv_have_sys_procfs_type_fpregset_t=no
10969
10970 fi
10971 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10972 fi
10973
10974  if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
10975
10976 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
10977
10978  fi
10979  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
10980 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
10981
10982   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
10983 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
10984  if test "${bfd_cv_have_sys_procfs_type_prgregset_t+set}" = set; then :
10985   $as_echo_n "(cached) " >&6
10986 else
10987   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10988 /* end confdefs.h.  */
10989
10990 #define _SYSCALL32
10991 /* Needed for new procfs interface on sparc-solaris.  */
10992 #define _STRUCTURED_PROC 1
10993 #include <sys/procfs.h>
10994 int
10995 main ()
10996 {
10997 prgregset_t avar
10998   ;
10999   return 0;
11000 }
11001 _ACEOF
11002 if ac_fn_c_try_compile "$LINENO"; then :
11003   bfd_cv_have_sys_procfs_type_prgregset_t=yes
11004 else
11005   bfd_cv_have_sys_procfs_type_prgregset_t=no
11006
11007 fi
11008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11009 fi
11010
11011  if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
11012
11013 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
11014
11015  fi
11016  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
11017 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
11018
11019   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
11020 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
11021  if test "${bfd_cv_have_sys_procfs_type_prfpregset_t+set}" = set; then :
11022   $as_echo_n "(cached) " >&6
11023 else
11024   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11025 /* end confdefs.h.  */
11026
11027 #define _SYSCALL32
11028 /* Needed for new procfs interface on sparc-solaris.  */
11029 #define _STRUCTURED_PROC 1
11030 #include <sys/procfs.h>
11031 int
11032 main ()
11033 {
11034 prfpregset_t avar
11035   ;
11036   return 0;
11037 }
11038 _ACEOF
11039 if ac_fn_c_try_compile "$LINENO"; then :
11040   bfd_cv_have_sys_procfs_type_prfpregset_t=yes
11041 else
11042   bfd_cv_have_sys_procfs_type_prfpregset_t=no
11043
11044 fi
11045 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11046 fi
11047
11048  if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
11049
11050 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
11051
11052  fi
11053  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
11054 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
11055
11056   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
11057 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
11058  if test "${bfd_cv_have_sys_procfs_type_prgregset32_t+set}" = set; then :
11059   $as_echo_n "(cached) " >&6
11060 else
11061   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11062 /* end confdefs.h.  */
11063
11064 #define _SYSCALL32
11065 /* Needed for new procfs interface on sparc-solaris.  */
11066 #define _STRUCTURED_PROC 1
11067 #include <sys/procfs.h>
11068 int
11069 main ()
11070 {
11071 prgregset32_t avar
11072   ;
11073   return 0;
11074 }
11075 _ACEOF
11076 if ac_fn_c_try_compile "$LINENO"; then :
11077   bfd_cv_have_sys_procfs_type_prgregset32_t=yes
11078 else
11079   bfd_cv_have_sys_procfs_type_prgregset32_t=no
11080
11081 fi
11082 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11083 fi
11084
11085  if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
11086
11087 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
11088
11089  fi
11090  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
11091 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
11092
11093   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset32_t in sys/procfs.h" >&5
11094 $as_echo_n "checking for prfpregset32_t in sys/procfs.h... " >&6; }
11095  if test "${bfd_cv_have_sys_procfs_type_prfpregset32_t+set}" = set; then :
11096   $as_echo_n "(cached) " >&6
11097 else
11098   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11099 /* end confdefs.h.  */
11100
11101 #define _SYSCALL32
11102 /* Needed for new procfs interface on sparc-solaris.  */
11103 #define _STRUCTURED_PROC 1
11104 #include <sys/procfs.h>
11105 int
11106 main ()
11107 {
11108 prfpregset32_t avar
11109   ;
11110   return 0;
11111 }
11112 _ACEOF
11113 if ac_fn_c_try_compile "$LINENO"; then :
11114   bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
11115 else
11116   bfd_cv_have_sys_procfs_type_prfpregset32_t=no
11117
11118 fi
11119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11120 fi
11121
11122  if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then
11123
11124 $as_echo "#define HAVE_PRFPREGSET32_T 1" >>confdefs.h
11125
11126  fi
11127  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset32_t" >&5
11128 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset32_t" >&6; }
11129
11130   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
11131 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
11132  if test "${bfd_cv_have_sys_procfs_type_lwpid_t+set}" = set; then :
11133   $as_echo_n "(cached) " >&6
11134 else
11135   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11136 /* end confdefs.h.  */
11137
11138 #define _SYSCALL32
11139 /* Needed for new procfs interface on sparc-solaris.  */
11140 #define _STRUCTURED_PROC 1
11141 #include <sys/procfs.h>
11142 int
11143 main ()
11144 {
11145 lwpid_t avar
11146   ;
11147   return 0;
11148 }
11149 _ACEOF
11150 if ac_fn_c_try_compile "$LINENO"; then :
11151   bfd_cv_have_sys_procfs_type_lwpid_t=yes
11152 else
11153   bfd_cv_have_sys_procfs_type_lwpid_t=no
11154
11155 fi
11156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11157 fi
11158
11159  if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
11160
11161 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
11162
11163  fi
11164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
11165 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
11166
11167   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
11168 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
11169  if test "${bfd_cv_have_sys_procfs_type_psaddr_t+set}" = set; then :
11170   $as_echo_n "(cached) " >&6
11171 else
11172   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11173 /* end confdefs.h.  */
11174
11175 #define _SYSCALL32
11176 /* Needed for new procfs interface on sparc-solaris.  */
11177 #define _STRUCTURED_PROC 1
11178 #include <sys/procfs.h>
11179 int
11180 main ()
11181 {
11182 psaddr_t avar
11183   ;
11184   return 0;
11185 }
11186 _ACEOF
11187 if ac_fn_c_try_compile "$LINENO"; then :
11188   bfd_cv_have_sys_procfs_type_psaddr_t=yes
11189 else
11190   bfd_cv_have_sys_procfs_type_psaddr_t=no
11191
11192 fi
11193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11194 fi
11195
11196  if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
11197
11198 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
11199
11200  fi
11201  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
11202 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
11203
11204   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prsysent_t in sys/procfs.h" >&5
11205 $as_echo_n "checking for prsysent_t in sys/procfs.h... " >&6; }
11206  if test "${bfd_cv_have_sys_procfs_type_prsysent_t+set}" = set; then :
11207   $as_echo_n "(cached) " >&6
11208 else
11209   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11210 /* end confdefs.h.  */
11211
11212 #define _SYSCALL32
11213 /* Needed for new procfs interface on sparc-solaris.  */
11214 #define _STRUCTURED_PROC 1
11215 #include <sys/procfs.h>
11216 int
11217 main ()
11218 {
11219 prsysent_t avar
11220   ;
11221   return 0;
11222 }
11223 _ACEOF
11224 if ac_fn_c_try_compile "$LINENO"; then :
11225   bfd_cv_have_sys_procfs_type_prsysent_t=yes
11226 else
11227   bfd_cv_have_sys_procfs_type_prsysent_t=no
11228
11229 fi
11230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11231 fi
11232
11233  if test $bfd_cv_have_sys_procfs_type_prsysent_t = yes; then
11234
11235 $as_echo "#define HAVE_PRSYSENT_T 1" >>confdefs.h
11236
11237  fi
11238  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prsysent_t" >&5
11239 $as_echo "$bfd_cv_have_sys_procfs_type_prsysent_t" >&6; }
11240
11241   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigset_t in sys/procfs.h" >&5
11242 $as_echo_n "checking for pr_sigset_t in sys/procfs.h... " >&6; }
11243  if test "${bfd_cv_have_sys_procfs_type_pr_sigset_t+set}" = set; then :
11244   $as_echo_n "(cached) " >&6
11245 else
11246   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11247 /* end confdefs.h.  */
11248
11249 #define _SYSCALL32
11250 /* Needed for new procfs interface on sparc-solaris.  */
11251 #define _STRUCTURED_PROC 1
11252 #include <sys/procfs.h>
11253 int
11254 main ()
11255 {
11256 pr_sigset_t avar
11257   ;
11258   return 0;
11259 }
11260 _ACEOF
11261 if ac_fn_c_try_compile "$LINENO"; then :
11262   bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
11263 else
11264   bfd_cv_have_sys_procfs_type_pr_sigset_t=no
11265
11266 fi
11267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11268 fi
11269
11270  if test $bfd_cv_have_sys_procfs_type_pr_sigset_t = yes; then
11271
11272 $as_echo "#define HAVE_PR_SIGSET_T 1" >>confdefs.h
11273
11274  fi
11275  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigset_t" >&5
11276 $as_echo "$bfd_cv_have_sys_procfs_type_pr_sigset_t" >&6; }
11277
11278   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_sigaction64_t in sys/procfs.h" >&5
11279 $as_echo_n "checking for pr_sigaction64_t in sys/procfs.h... " >&6; }
11280  if test "${bfd_cv_have_sys_procfs_type_pr_sigaction64_t+set}" = set; then :
11281   $as_echo_n "(cached) " >&6
11282 else
11283   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11284 /* end confdefs.h.  */
11285
11286 #define _SYSCALL32
11287 /* Needed for new procfs interface on sparc-solaris.  */
11288 #define _STRUCTURED_PROC 1
11289 #include <sys/procfs.h>
11290 int
11291 main ()
11292 {
11293 pr_sigaction64_t avar
11294   ;
11295   return 0;
11296 }
11297 _ACEOF
11298 if ac_fn_c_try_compile "$LINENO"; then :
11299   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
11300 else
11301   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=no
11302
11303 fi
11304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11305 fi
11306
11307  if test $bfd_cv_have_sys_procfs_type_pr_sigaction64_t = yes; then
11308
11309 $as_echo "#define HAVE_PR_SIGACTION64_T 1" >>confdefs.h
11310
11311  fi
11312  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&5
11313 $as_echo "$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&6; }
11314
11315   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pr_siginfo64_t in sys/procfs.h" >&5
11316 $as_echo_n "checking for pr_siginfo64_t in sys/procfs.h... " >&6; }
11317  if test "${bfd_cv_have_sys_procfs_type_pr_siginfo64_t+set}" = set; then :
11318   $as_echo_n "(cached) " >&6
11319 else
11320   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11321 /* end confdefs.h.  */
11322
11323 #define _SYSCALL32
11324 /* Needed for new procfs interface on sparc-solaris.  */
11325 #define _STRUCTURED_PROC 1
11326 #include <sys/procfs.h>
11327 int
11328 main ()
11329 {
11330 pr_siginfo64_t avar
11331   ;
11332   return 0;
11333 }
11334 _ACEOF
11335 if ac_fn_c_try_compile "$LINENO"; then :
11336   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
11337 else
11338   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=no
11339
11340 fi
11341 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11342 fi
11343
11344  if test $bfd_cv_have_sys_procfs_type_pr_siginfo64_t = yes; then
11345
11346 $as_echo "#define HAVE_PR_SIGINFO64_T 1" >>confdefs.h
11347
11348  fi
11349  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&5
11350 $as_echo "$bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&6; }
11351
11352
11353
11354
11355
11356   if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
11357     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether prfpregset_t type is broken" >&5
11358 $as_echo_n "checking whether prfpregset_t type is broken... " >&6; }
11359     if test "${gdb_cv_prfpregset_t_broken+set}" = set; then :
11360   $as_echo_n "(cached) " >&6
11361 else
11362   if test "$cross_compiling" = yes; then :
11363   gdb_cv_prfpregset_t_broken=yes
11364 else
11365   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11366 /* end confdefs.h.  */
11367 #include <sys/procfs.h>
11368        int main ()
11369        {
11370          if (sizeof (prfpregset_t) == sizeof (void *))
11371            return 1;
11372          return 0;
11373        }
11374 _ACEOF
11375 if ac_fn_c_try_run "$LINENO"; then :
11376   gdb_cv_prfpregset_t_broken=no
11377 else
11378   gdb_cv_prfpregset_t_broken=yes
11379 fi
11380 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11381   conftest.$ac_objext conftest.beam conftest.$ac_ext
11382 fi
11383
11384 fi
11385
11386     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_prfpregset_t_broken" >&5
11387 $as_echo "$gdb_cv_prfpregset_t_broken" >&6; }
11388     if test $gdb_cv_prfpregset_t_broken = yes; then
11389
11390 $as_echo "#define PRFPREGSET_T_BROKEN 1" >>confdefs.h
11391
11392     fi
11393   fi
11394
11395
11396   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
11397 $as_echo_n "checking for PIOCSET ioctl entry in sys/procfs.h... " >&6; }
11398   if test "${gdb_cv_have_procfs_piocset+set}" = set; then :
11399   $as_echo_n "(cached) " >&6
11400 else
11401   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11402 /* end confdefs.h.  */
11403 #include <unistd.h>
11404 #include <sys/types.h>
11405 #include <sys/procfs.h>
11406
11407 int
11408 main ()
11409 {
11410
11411     int dummy;;
11412     dummy = ioctl(0, PIOCSET, &dummy);
11413
11414   ;
11415   return 0;
11416 }
11417 _ACEOF
11418 if ac_fn_c_try_compile "$LINENO"; then :
11419   gdb_cv_have_procfs_piocset=yes
11420 else
11421   gdb_cv_have_procfs_piocset=no
11422 fi
11423 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11424 fi
11425
11426   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_procfs_piocset" >&5
11427 $as_echo "$gdb_cv_have_procfs_piocset" >&6; }
11428   if test $gdb_cv_have_procfs_piocset = yes; then
11429
11430 $as_echo "#define HAVE_PROCFS_PIOCSET 1" >>confdefs.h
11431
11432   fi
11433 fi
11434
11435 if test ${host} = ${target} ; then
11436
11437   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member l_addr in struct link_map" >&5
11438 $as_echo_n "checking for member l_addr in struct link_map... " >&6; }
11439   if test "${gdb_cv_have_struct_link_map_with_l_members+set}" = set; then :
11440   $as_echo_n "(cached) " >&6
11441 else
11442   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11443 /* end confdefs.h.  */
11444 #include <link.h>
11445 int
11446 main ()
11447 {
11448 struct link_map lm; (void) lm.l_addr;
11449   ;
11450   return 0;
11451 }
11452 _ACEOF
11453 if ac_fn_c_try_compile "$LINENO"; then :
11454   gdb_cv_have_struct_link_map_with_l_members=yes
11455 else
11456   gdb_cv_have_struct_link_map_with_l_members=no
11457 fi
11458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11459 fi
11460
11461   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_l_members" >&5
11462 $as_echo "$gdb_cv_have_struct_link_map_with_l_members" >&6; }
11463   if test $gdb_cv_have_struct_link_map_with_l_members = yes; then
11464
11465 $as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_L_MEMBERS 1" >>confdefs.h
11466
11467   fi
11468
11469
11470   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member lm_addr in struct link_map" >&5
11471 $as_echo_n "checking for member lm_addr in struct link_map... " >&6; }
11472   if test "${gdb_cv_have_struct_link_map_with_lm_members+set}" = set; then :
11473   $as_echo_n "(cached) " >&6
11474 else
11475   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11476 /* end confdefs.h.  */
11477 #include <sys/types.h>
11478 #include <link.h>
11479 int
11480 main ()
11481 {
11482 struct link_map lm; (void) lm.lm_addr;
11483   ;
11484   return 0;
11485 }
11486 _ACEOF
11487 if ac_fn_c_try_compile "$LINENO"; then :
11488   gdb_cv_have_struct_link_map_with_lm_members=yes
11489 else
11490   gdb_cv_have_struct_link_map_with_lm_members=no
11491 fi
11492 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11493 fi
11494
11495   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map_with_lm_members" >&5
11496 $as_echo "$gdb_cv_have_struct_link_map_with_lm_members" >&6; }
11497   if test $gdb_cv_have_struct_link_map_with_lm_members = yes; then
11498
11499 $as_echo "#define HAVE_STRUCT_LINK_MAP_WITH_LM_MEMBERS 1" >>confdefs.h
11500
11501   fi
11502
11503
11504   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for member som_addr in struct so_map" >&5
11505 $as_echo_n "checking for member som_addr in struct so_map... " >&6; }
11506   if test "${gdb_cv_have_struct_so_map_with_som_members+set}" = set; then :
11507   $as_echo_n "(cached) " >&6
11508 else
11509   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11510 /* end confdefs.h.  */
11511 #include <sys/types.h>
11512 #ifdef HAVE_NLIST_H
11513 #include <nlist.h>
11514 #endif
11515 #include <link.h>
11516 int
11517 main ()
11518 {
11519 struct so_map lm; (void) lm.som_addr;
11520   ;
11521   return 0;
11522 }
11523 _ACEOF
11524 if ac_fn_c_try_compile "$LINENO"; then :
11525   gdb_cv_have_struct_so_map_with_som_members=yes
11526 else
11527   gdb_cv_have_struct_so_map_with_som_members=no
11528 fi
11529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11530 fi
11531
11532   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_so_map_with_som_members" >&5
11533 $as_echo "$gdb_cv_have_struct_so_map_with_som_members" >&6; }
11534   if test $gdb_cv_have_struct_so_map_with_som_members = yes; then
11535
11536 $as_echo "#define HAVE_STRUCT_SO_MAP_WITH_SOM_MEMBERS 1" >>confdefs.h
11537
11538   fi
11539
11540
11541   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct link_map32 in sys/link.h" >&5
11542 $as_echo_n "checking for struct link_map32 in sys/link.h... " >&6; }
11543   if test "${gdb_cv_have_struct_link_map32+set}" = set; then :
11544   $as_echo_n "(cached) " >&6
11545 else
11546   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11547 /* end confdefs.h.  */
11548 #define _SYSCALL32
11549 #include <sys/link.h>
11550 int
11551 main ()
11552 {
11553 struct link_map32 l;
11554   ;
11555   return 0;
11556 }
11557 _ACEOF
11558 if ac_fn_c_try_compile "$LINENO"; then :
11559   gdb_cv_have_struct_link_map32=yes
11560 else
11561   gdb_cv_have_struct_link_map32=no
11562 fi
11563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11564 fi
11565
11566   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_struct_link_map32" >&5
11567 $as_echo "$gdb_cv_have_struct_link_map32" >&6; }
11568   if test $gdb_cv_have_struct_link_map32 = yes; then
11569
11570 $as_echo "#define HAVE_STRUCT_LINK_MAP32 1" >>confdefs.h
11571
11572
11573 $as_echo "#define _SYSCALL32 1" >>confdefs.h
11574
11575   fi
11576 fi
11577
11578 # Check if the compiler supports the `long long' type.
11579
11580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
11581 $as_echo_n "checking for long long support in compiler... " >&6; }
11582 if test "${gdb_cv_c_long_long+set}" = set; then :
11583   $as_echo_n "(cached) " >&6
11584 else
11585   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11586 /* end confdefs.h.  */
11587 extern long long foo;
11588 int
11589 main ()
11590 {
11591 switch (foo & 2) { case 0: return 1; }
11592   ;
11593   return 0;
11594 }
11595 _ACEOF
11596 if ac_fn_c_try_compile "$LINENO"; then :
11597   gdb_cv_c_long_long=yes
11598 else
11599   gdb_cv_c_long_long=no
11600 fi
11601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11602 fi
11603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
11604 $as_echo "$gdb_cv_c_long_long" >&6; }
11605 if test $gdb_cv_c_long_long != yes; then
11606   # libdecnumber requires long long.
11607   as_fn_error "Compiler must support long long for GDB." "$LINENO" 5
11608 fi
11609
11610 # Check if the compiler and runtime support printing long longs.
11611
11612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
11613 $as_echo_n "checking for long long support in printf... " >&6; }
11614 if test "${gdb_cv_printf_has_long_long+set}" = set; then :
11615   $as_echo_n "(cached) " >&6
11616 else
11617   if test "$cross_compiling" = yes; then :
11618   gdb_cv_printf_has_long_long=no
11619 else
11620   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11621 /* end confdefs.h.  */
11622 $ac_includes_default
11623 int
11624 main ()
11625 {
11626 char buf[32];
11627   long long l = 0;
11628   l = (l << 16) + 0x0123;
11629   l = (l << 16) + 0x4567;
11630   l = (l << 16) + 0x89ab;
11631   l = (l << 16) + 0xcdef;
11632   sprintf (buf, "0x%016llx", l);
11633   return (strcmp ("0x0123456789abcdef", buf));
11634   ;
11635   return 0;
11636 }
11637 _ACEOF
11638 if ac_fn_c_try_run "$LINENO"; then :
11639   gdb_cv_printf_has_long_long=yes
11640 else
11641   gdb_cv_printf_has_long_long=no
11642 fi
11643 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11644   conftest.$ac_objext conftest.beam conftest.$ac_ext
11645 fi
11646
11647 fi
11648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
11649 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
11650 if test $gdb_cv_printf_has_long_long = yes; then
11651
11652 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
11653
11654 fi
11655
11656 # Check if the compiler and runtime support printing decfloats.
11657
11658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
11659 $as_echo_n "checking for decfloat support in printf... " >&6; }
11660 if test "${gdb_cv_printf_has_decfloat+set}" = set; then :
11661   $as_echo_n "(cached) " >&6
11662 else
11663   if test "$cross_compiling" = yes; then :
11664   gdb_cv_printf_has_decfloat=no
11665 else
11666   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11667 /* end confdefs.h.  */
11668 $ac_includes_default
11669 int
11670 main ()
11671 {
11672 char buf[64];
11673   _Decimal32 d32 = 1.2345df;
11674   _Decimal64 d64 = 1.2345dd;
11675   _Decimal128 d128 = 1.2345dl;
11676   sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
11677   return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
11678   ;
11679   return 0;
11680 }
11681 _ACEOF
11682 if ac_fn_c_try_run "$LINENO"; then :
11683   gdb_cv_printf_has_decfloat=yes
11684 else
11685   gdb_cv_printf_has_decfloat=no
11686 fi
11687 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11688   conftest.$ac_objext conftest.beam conftest.$ac_ext
11689 fi
11690
11691 fi
11692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
11693 $as_echo "$gdb_cv_printf_has_decfloat" >&6; }
11694 if test $gdb_cv_printf_has_decfloat = yes; then
11695
11696 $as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
11697
11698 fi
11699
11700 # Check if the compiler supports the `long double' type.  We can't use
11701 # AC_C_LONG_DOUBLE because that one does additional checks on the
11702 # constants defined in <float.h> that fail on some systems,
11703 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
11704
11705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
11706 $as_echo_n "checking for long double support in compiler... " >&6; }
11707 if test "${gdb_cv_c_long_double+set}" = set; then :
11708   $as_echo_n "(cached) " >&6
11709 else
11710   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11711 /* end confdefs.h.  */
11712 long double foo;
11713 _ACEOF
11714 if ac_fn_c_try_compile "$LINENO"; then :
11715   gdb_cv_c_long_double=yes
11716 else
11717   gdb_cv_c_long_double=no
11718 fi
11719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11720 fi
11721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
11722 $as_echo "$gdb_cv_c_long_double" >&6; }
11723 if test $gdb_cv_c_long_double = yes; then
11724
11725 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
11726
11727 fi
11728
11729 # Check if the compiler and runtime support printing long doubles.
11730
11731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
11732 $as_echo_n "checking for long double support in printf... " >&6; }
11733 if test "${gdb_cv_printf_has_long_double+set}" = set; then :
11734   $as_echo_n "(cached) " >&6
11735 else
11736   if test "$cross_compiling" = yes; then :
11737   gdb_cv_printf_has_long_double=no
11738 else
11739   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11740 /* end confdefs.h.  */
11741 $ac_includes_default
11742 int
11743 main ()
11744 {
11745 char buf[16];
11746   long double f = 3.141592653;
11747   sprintf (buf, "%Lg", f);
11748   return (strncmp ("3.14159", buf, 7));
11749   ;
11750   return 0;
11751 }
11752 _ACEOF
11753 if ac_fn_c_try_run "$LINENO"; then :
11754   gdb_cv_printf_has_long_double=yes
11755 else
11756   gdb_cv_printf_has_long_double=no
11757 fi
11758 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11759   conftest.$ac_objext conftest.beam conftest.$ac_ext
11760 fi
11761
11762 fi
11763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
11764 $as_echo "$gdb_cv_printf_has_long_double" >&6; }
11765 if test $gdb_cv_printf_has_long_double = yes; then
11766
11767 $as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
11768
11769 fi
11770
11771 # Check if the compiler and runtime support scanning long doubles.
11772
11773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
11774 $as_echo_n "checking for long double support in scanf... " >&6; }
11775 if test "${gdb_cv_scanf_has_long_double+set}" = set; then :
11776   $as_echo_n "(cached) " >&6
11777 else
11778   if test "$cross_compiling" = yes; then :
11779   gdb_cv_scanf_has_long_double=no
11780 else
11781   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11782 /* end confdefs.h.  */
11783 #include <stdio.h>
11784 int
11785 main ()
11786 {
11787 char *buf = "3.141592653";
11788   long double f = 0;
11789   sscanf (buf, "%Lg", &f);
11790   return !(f > 3.14159 && f < 3.14160);
11791   ;
11792   return 0;
11793 }
11794 _ACEOF
11795 if ac_fn_c_try_run "$LINENO"; then :
11796   gdb_cv_scanf_has_long_double=yes
11797 else
11798   gdb_cv_scanf_has_long_double=no
11799 fi
11800 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11801   conftest.$ac_objext conftest.beam conftest.$ac_ext
11802 fi
11803
11804 fi
11805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
11806 $as_echo "$gdb_cv_scanf_has_long_double" >&6; }
11807 if test $gdb_cv_scanf_has_long_double = yes; then
11808
11809 $as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
11810
11811 fi
11812
11813 case ${host_os} in
11814 aix*)
11815   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
11816 $as_echo_n "checking for -bbigtoc option... " >&6; }
11817 if test "${gdb_cv_bigtoc+set}" = set; then :
11818   $as_echo_n "(cached) " >&6
11819 else
11820
11821     SAVE_LDFLAGS=$LDFLAGS
11822
11823     case $GCC in
11824     yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
11825     *) gdb_cv_bigtoc=-bbigtoc ;;
11826     esac
11827
11828     LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
11829     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11830 /* end confdefs.h.  */
11831
11832 int
11833 main ()
11834 {
11835 int i;
11836   ;
11837   return 0;
11838 }
11839 _ACEOF
11840 if ac_fn_c_try_link "$LINENO"; then :
11841
11842 else
11843   gdb_cv_bigtoc=
11844 fi
11845 rm -f core conftest.err conftest.$ac_objext \
11846     conftest$ac_exeext conftest.$ac_ext
11847     LDFLAGS="${SAVE_LDFLAGS}"
11848
11849 fi
11850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
11851 $as_echo "$gdb_cv_bigtoc" >&6; }
11852   CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
11853   ;;
11854 esac
11855
11856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
11857 $as_echo_n "checking for the dynamic export flag... " >&6; }
11858 dynamic_list=false
11859 if test "${gdb_native}" = yes; then
11860    # The dynamically loaded libthread_db needs access to symbols in the gdb
11861    # executable.  Older GNU ld supports --export-dynamic but --dynamic-list
11862    # may not be supported there.
11863    old_LDFLAGS="$LDFLAGS"
11864    # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
11865    RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
11866    LDFLAGS="$LDFLAGS $RDYNAMIC"
11867    if test "${have_libpython}" = no; then
11868      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11869 /* end confdefs.h.  */
11870
11871 int
11872 main ()
11873 {
11874
11875   ;
11876   return 0;
11877 }
11878 _ACEOF
11879 if ac_fn_c_try_link "$LINENO"; then :
11880   dynamic_list=true
11881 fi
11882 rm -f core conftest.err conftest.$ac_objext \
11883     conftest$ac_exeext conftest.$ac_ext
11884    else
11885      # Workaround http://bugs.python.org/issue4434 where static
11886      # libpythonX.Y.a would get its symbols required for
11887      # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
11888      # Problem does not happen for the recommended libpythonX.Y.so linkage.
11889      old_CFLAGS="$CFLAGS"
11890      CFLAGS="$CFLAGS $PYTHON_CFLAGS"
11891      if test "$cross_compiling" = yes; then :
11892   true
11893 else
11894   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11895 /* end confdefs.h.  */
11896 #include "${have_libpython}/Python.h"
11897 int
11898 main ()
11899 {
11900 int err;
11901           Py_Initialize ();
11902           err = PyRun_SimpleString ("import itertools\n");
11903           Py_Finalize ();
11904           return err == 0 ? 0 : 1;
11905   ;
11906   return 0;
11907 }
11908 _ACEOF
11909 if ac_fn_c_try_run "$LINENO"; then :
11910   dynamic_list=true
11911 fi
11912 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11913   conftest.$ac_objext conftest.beam conftest.$ac_ext
11914 fi
11915
11916      CFLAGS="$old_CFLAGS"
11917    fi
11918    LDFLAGS="$old_LDFLAGS"
11919 fi
11920 if $dynamic_list; then
11921   found="-Wl,--dynamic-list"
11922   RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
11923 else
11924   found="-rdynamic"
11925   RDYNAMIC="-rdynamic"
11926 fi
11927
11928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
11929 $as_echo "$found" >&6; }
11930
11931
11932 if test ${build} = ${host} -a ${host} = ${target} ; then
11933    case ${host_os} in
11934    solaris*)
11935       # See if thread_db library is around for Solaris thread debugging.
11936       # Note that we must explicitly test for version 1 of the library
11937       # because version 0 (present on Solaris 2.4 or earlier) doesn't have
11938       # the same API.
11939       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Solaris thread debugging library" >&5
11940 $as_echo_n "checking for Solaris thread debugging library... " >&6; }
11941       if test -f /usr/lib/libthread_db.so.1 ; then
11942          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11943 $as_echo "yes" >&6; }
11944
11945 $as_echo "#define HAVE_THREAD_DB_LIB 1" >>confdefs.h
11946
11947          CONFIG_OBS="${CONFIG_OBS} sol-thread.o"
11948          CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
11949          # On SPARC CPUs, we also need to build sparc-sol-thread.
11950          case ${host_cpu} in
11951            sparc*)
11952              CONFIG_OBS="${CONFIG_OBS} sparc-sol-thread.o"
11953              CONFIG_SRCS="${CONFIG_SRCS} sparc-sol-thread.c"
11954              ;;
11955          esac
11956          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11957 $as_echo_n "checking for dlopen in -ldl... " >&6; }
11958 if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
11959   $as_echo_n "(cached) " >&6
11960 else
11961   ac_check_lib_save_LIBS=$LIBS
11962 LIBS="-ldl  $LIBS"
11963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11964 /* end confdefs.h.  */
11965
11966 /* Override any GCC internal prototype to avoid an error.
11967    Use char because int might match the return type of a GCC
11968    builtin and then its argument prototype would still apply.  */
11969 #ifdef __cplusplus
11970 extern "C"
11971 #endif
11972 char dlopen ();
11973 int
11974 main ()
11975 {
11976 return dlopen ();
11977   ;
11978   return 0;
11979 }
11980 _ACEOF
11981 if ac_fn_c_try_link "$LINENO"; then :
11982   ac_cv_lib_dl_dlopen=yes
11983 else
11984   ac_cv_lib_dl_dlopen=no
11985 fi
11986 rm -f core conftest.err conftest.$ac_objext \
11987     conftest$ac_exeext conftest.$ac_ext
11988 LIBS=$ac_check_lib_save_LIBS
11989 fi
11990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11991 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11992 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
11993   cat >>confdefs.h <<_ACEOF
11994 #define HAVE_LIBDL 1
11995 _ACEOF
11996
11997   LIBS="-ldl $LIBS"
11998
11999 fi
12000
12001          CONFIG_LDFLAGS="${CONFIG_LDFLAGS} $RDYNAMIC"
12002          # Sun randomly tweaked the prototypes in <proc_service.h>
12003          # at one point.
12004          { $as_echo "$as_me:${as_lineno-$LINENO}: checking if <proc_service.h> is old" >&5
12005 $as_echo_n "checking if <proc_service.h> is old... " >&6; }
12006          if test "${gdb_cv_proc_service_is_old+set}" = set; then :
12007   $as_echo_n "(cached) " >&6
12008 else
12009
12010             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12011 /* end confdefs.h.  */
12012
12013                 #include <proc_service.h>
12014                 ps_err_e ps_pdwrite
12015                     (struct ps_prochandle*, psaddr_t, const void*, size_t);
12016
12017 int
12018 main ()
12019 {
12020
12021   ;
12022   return 0;
12023 }
12024 _ACEOF
12025 if ac_fn_c_try_compile "$LINENO"; then :
12026   gdb_cv_proc_service_is_old=no
12027 else
12028   gdb_cv_proc_service_is_old=yes
12029 fi
12030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12031
12032 fi
12033
12034          { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_proc_service_is_old" >&5
12035 $as_echo "$gdb_cv_proc_service_is_old" >&6; }
12036          if test $gdb_cv_proc_service_is_old = yes; then
12037
12038 $as_echo "#define PROC_SERVICE_IS_OLD 1" >>confdefs.h
12039
12040          fi
12041       else
12042          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12043 $as_echo "no" >&6; }
12044       fi
12045       ;;
12046    aix*)
12047       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
12048 $as_echo_n "checking for AiX thread debugging library... " >&6; }
12049       if test "${gdb_cv_have_aix_thread_debug+set}" = set; then :
12050   $as_echo_n "(cached) " >&6
12051 else
12052   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12053 /* end confdefs.h.  */
12054 #include <sys/pthdebug.h>
12055 int
12056 main ()
12057 {
12058 #ifndef PTHDB_VERSION_3
12059                                     #error
12060                                     #endif
12061   ;
12062   return 0;
12063 }
12064 _ACEOF
12065 if ac_fn_c_try_compile "$LINENO"; then :
12066   gdb_cv_have_aix_thread_debug=yes
12067 else
12068   gdb_cv_have_aix_thread_debug=no
12069 fi
12070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12071 fi
12072
12073       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
12074 $as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
12075       if test $gdb_cv_have_aix_thread_debug = yes; then
12076          CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
12077          CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
12078          LIBS="$LIBS -lpthdebug"
12079
12080          # Older versions of AIX do not provide the declaration for
12081          # the getthrds function (it appears that it was introduced
12082          # with AIX 6.x).
12083          ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
12084 "
12085 if test "x$ac_cv_have_decl_getthrds" = x""yes; then :
12086   ac_have_decl=1
12087 else
12088   ac_have_decl=0
12089 fi
12090
12091 cat >>confdefs.h <<_ACEOF
12092 #define HAVE_DECL_GETTHRDS $ac_have_decl
12093 _ACEOF
12094
12095       fi
12096       ;;
12097    esac
12098
12099 fi
12100
12101 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
12102    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
12103 $as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
12104 if test "${gdb_cv_thread_db_h_has_td_notalloc+set}" = set; then :
12105   $as_echo_n "(cached) " >&6
12106 else
12107   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12108 /* end confdefs.h.  */
12109 #include <thread_db.h>
12110 int
12111 main ()
12112 {
12113 int i = TD_NOTALLOC;
12114   ;
12115   return 0;
12116 }
12117 _ACEOF
12118 if ac_fn_c_try_compile "$LINENO"; then :
12119   gdb_cv_thread_db_h_has_td_notalloc=yes
12120 else
12121   gdb_cv_thread_db_h_has_td_notalloc=no
12122
12123 fi
12124 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12125
12126 fi
12127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
12128 $as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
12129    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
12130 $as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
12131 if test "${gdb_cv_thread_db_h_has_td_version+set}" = set; then :
12132   $as_echo_n "(cached) " >&6
12133 else
12134   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12135 /* end confdefs.h.  */
12136 #include <thread_db.h>
12137 int
12138 main ()
12139 {
12140 int i = TD_VERSION;
12141   ;
12142   return 0;
12143 }
12144 _ACEOF
12145 if ac_fn_c_try_compile "$LINENO"; then :
12146   gdb_cv_thread_db_h_has_td_version=yes
12147 else
12148   gdb_cv_thread_db_h_has_td_version=no
12149
12150 fi
12151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12152
12153 fi
12154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
12155 $as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
12156    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
12157 $as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
12158 if test "${gdb_cv_thread_db_h_has_td_notls+set}" = set; then :
12159   $as_echo_n "(cached) " >&6
12160 else
12161   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12162 /* end confdefs.h.  */
12163 #include <thread_db.h>
12164 int
12165 main ()
12166 {
12167 int i = TD_NOTLS;
12168   ;
12169   return 0;
12170 }
12171 _ACEOF
12172 if ac_fn_c_try_compile "$LINENO"; then :
12173   gdb_cv_thread_db_h_has_td_notls=yes
12174 else
12175   gdb_cv_thread_db_h_has_td_notls=no
12176
12177 fi
12178 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12179
12180 fi
12181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
12182 $as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
12183 fi
12184 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
12185
12186 $as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
12187
12188 fi
12189 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
12190
12191 $as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
12192
12193 fi
12194 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
12195
12196 $as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
12197
12198 fi
12199
12200 if test "x$ac_cv_header_sys_syscall_h" = "xyes"; then
12201    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/syscall.h> has __NR_tkill" >&5
12202 $as_echo_n "checking whether <sys/syscall.h> has __NR_tkill... " >&6; }
12203 if test "${gdb_cv_sys_syscall_h_has_tkill+set}" = set; then :
12204   $as_echo_n "(cached) " >&6
12205 else
12206   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12207 /* end confdefs.h.  */
12208 #include <sys/syscall.h>
12209 int
12210 main ()
12211 {
12212 int i = __NR_tkill;
12213   ;
12214   return 0;
12215 }
12216 _ACEOF
12217 if ac_fn_c_try_compile "$LINENO"; then :
12218   gdb_cv_sys_syscall_h_has_tkill=yes
12219 else
12220   gdb_cv_sys_syscall_h_has_tkill=no
12221
12222 fi
12223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12224
12225 fi
12226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_sys_syscall_h_has_tkill" >&5
12227 $as_echo "$gdb_cv_sys_syscall_h_has_tkill" >&6; }
12228 fi
12229 if test "x$gdb_cv_sys_syscall_h_has_tkill" = "xyes" && test "x$ac_cv_func_syscall" = "xyes"; then
12230
12231 $as_echo "#define HAVE_TKILL_SYSCALL 1" >>confdefs.h
12232
12233 fi
12234
12235 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
12236 "
12237 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = x""yes; then :
12238   ac_have_decl=1
12239 else
12240   ac_have_decl=0
12241 fi
12242
12243 cat >>confdefs.h <<_ACEOF
12244 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
12245 _ACEOF
12246
12247
12248 if test "$cross_compiling" = yes; then :
12249   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12250 /* end confdefs.h.  */
12251 #include <sys/personality.h>
12252 int
12253 main ()
12254 {
12255
12256 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
12257 #       define ADDR_NO_RANDOMIZE 0x0040000
12258 #      endif
12259        /* Test the flag could be set and stays set.  */
12260        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
12261        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
12262            return 1
12263   ;
12264   return 0;
12265 }
12266 _ACEOF
12267 if ac_fn_c_try_link "$LINENO"; then :
12268   have_personality=true
12269 else
12270   have_personality=false
12271 fi
12272 rm -f core conftest.err conftest.$ac_objext \
12273     conftest$ac_exeext conftest.$ac_ext
12274 else
12275   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12276 /* end confdefs.h.  */
12277 #include <sys/personality.h>
12278 int
12279 main ()
12280 {
12281
12282 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
12283 #       define ADDR_NO_RANDOMIZE 0x0040000
12284 #      endif
12285        /* Test the flag could be set and stays set.  */
12286        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
12287        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
12288            return 1
12289   ;
12290   return 0;
12291 }
12292 _ACEOF
12293 if ac_fn_c_try_run "$LINENO"; then :
12294   have_personality=true
12295 else
12296   have_personality=false
12297 fi
12298 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12299   conftest.$ac_objext conftest.beam conftest.$ac_ext
12300 fi
12301
12302 if $have_personality
12303 then
12304
12305 $as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
12306
12307 fi
12308
12309
12310 # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
12311 # except that the argument to --with-sysroot is optional.
12312 # --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
12313 if test "x$with_sysroot" = xyes; then
12314   with_sysroot="${exec_prefix}/${target_alias}/sys-root"
12315 fi
12316
12317 # Check whether --with-sysroot was given.
12318 if test "${with_sysroot+set}" = set; then :
12319   withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
12320 else
12321   TARGET_SYSTEM_ROOT=
12322 fi
12323
12324
12325   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
12326   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12327   ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
12328   ac_define_dir=`eval echo $ac_define_dir`
12329
12330 cat >>confdefs.h <<_ACEOF
12331 #define TARGET_SYSTEM_ROOT "$ac_define_dir"
12332 _ACEOF
12333
12334
12335
12336
12337   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
12338      if test "x$prefix" = xNONE; then
12339         test_prefix=/usr/local
12340      else
12341         test_prefix=$prefix
12342      fi
12343   else
12344      test_prefix=$exec_prefix
12345   fi
12346   value=0
12347   case ${ac_define_dir} in
12348      "${test_prefix}"|"${test_prefix}/"*|\
12349         '${exec_prefix}'|'${exec_prefix}/'*)
12350      value=1
12351      ;;
12352   esac
12353
12354 cat >>confdefs.h <<_ACEOF
12355 #define TARGET_SYSTEM_ROOT_RELOCATABLE $value
12356 _ACEOF
12357
12358
12359
12360
12361
12362 # Check whether --with-system-gdbinit was given.
12363 if test "${with_system_gdbinit+set}" = set; then :
12364   withval=$with_system_gdbinit;
12365     SYSTEM_GDBINIT=$withval
12366 else
12367   SYSTEM_GDBINIT=
12368 fi
12369
12370
12371   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
12372   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
12373   ac_define_dir=`eval echo $SYSTEM_GDBINIT`
12374   ac_define_dir=`eval echo $ac_define_dir`
12375
12376 cat >>confdefs.h <<_ACEOF
12377 #define SYSTEM_GDBINIT "$ac_define_dir"
12378 _ACEOF
12379
12380
12381
12382
12383   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
12384      if test "x$prefix" = xNONE; then
12385         test_prefix=/usr/local
12386      else
12387         test_prefix=$prefix
12388      fi
12389   else
12390      test_prefix=$exec_prefix
12391   fi
12392   value=0
12393   case ${ac_define_dir} in
12394      "${test_prefix}"|"${test_prefix}/"*|\
12395         '${exec_prefix}'|'${exec_prefix}/'*)
12396      value=1
12397      ;;
12398   esac
12399
12400 cat >>confdefs.h <<_ACEOF
12401 #define SYSTEM_GDBINIT_RELOCATABLE $value
12402 _ACEOF
12403
12404
12405
12406
12407 # Check whether --enable-werror was given.
12408 if test "${enable_werror+set}" = set; then :
12409   enableval=$enable_werror; case "${enableval}" in
12410      yes | y) ERROR_ON_WARNING="yes" ;;
12411      no | n)  ERROR_ON_WARNING="no" ;;
12412      *) as_fn_error "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
12413    esac
12414 fi
12415
12416
12417 # Enable -Werror by default when using gcc.  Turn it off for releases.
12418 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
12419     ERROR_ON_WARNING=yes
12420 fi
12421
12422 WERROR_CFLAGS=""
12423 if test "${ERROR_ON_WARNING}" = yes ; then
12424     WERROR_CFLAGS="-Werror"
12425 fi
12426
12427 # The entries after -Wno-pointer-sign are disabled warnings which may
12428 # be enabled in the future, which can not currently be used to build
12429 # GDB.
12430 # NOTE: If you change this list, remember to update
12431 # gdb/doc/gdbint.texinfo.
12432 build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
12433 -Wformat-nonliteral -Wno-pointer-sign \
12434 -Wno-unused -Wunused-value -Wunused-function \
12435 -Wno-switch -Wno-char-subscripts -Wmissing-prototypes \
12436 -Wdeclaration-after-statement -Wempty-body"
12437
12438 # Enable -Wno-format by default when using gcc on mingw since many
12439 # GCC versions complain about %I64.
12440 case "${host}" in
12441   *-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
12442 esac
12443
12444 # Check whether --enable-build-warnings was given.
12445 if test "${enable_build_warnings+set}" = set; then :
12446   enableval=$enable_build_warnings; case "${enableval}" in
12447   yes)  ;;
12448   no)   build_warnings="-w";;
12449   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12450         build_warnings="${build_warnings} ${t}";;
12451   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12452         build_warnings="${t} ${build_warnings}";;
12453   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
12454 esac
12455 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
12456   echo "Setting compiler warning flags = $build_warnings" 6>&1
12457 fi
12458 fi
12459 # Check whether --enable-gdb-build-warnings was given.
12460 if test "${enable_gdb_build_warnings+set}" = set; then :
12461   enableval=$enable_gdb_build_warnings; case "${enableval}" in
12462   yes)  ;;
12463   no)   build_warnings="-w";;
12464   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12465         build_warnings="${build_warnings} ${t}";;
12466   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
12467         build_warnings="${t} ${build_warnings}";;
12468   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
12469 esac
12470 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
12471   echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
12472 fi
12473 fi
12474 WARN_CFLAGS=""
12475 if test "x${build_warnings}" != x -a "x$GCC" = xyes
12476 then
12477     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
12478 $as_echo_n "checking compiler warning flags... " >&6; }
12479     # Separate out the -Werror flag as some files just cannot be
12480     # compiled with it enabled.
12481     for w in ${build_warnings}; do
12482         case $w in
12483         -Werr*) WERROR_CFLAGS=-Werror ;;
12484         *) # Check that GCC accepts it
12485             saved_CFLAGS="$CFLAGS"
12486             CFLAGS="$CFLAGS $w"
12487             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12488 /* end confdefs.h.  */
12489
12490 int
12491 main ()
12492 {
12493
12494   ;
12495   return 0;
12496 }
12497 _ACEOF
12498 if ac_fn_c_try_compile "$LINENO"; then :
12499   WARN_CFLAGS="${WARN_CFLAGS} $w"
12500 fi
12501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12502             CFLAGS="$saved_CFLAGS"
12503         esac
12504     done
12505     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
12506 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
12507 fi
12508
12509
12510
12511 # In the Cygwin environment, we need some additional flags.
12512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
12513 $as_echo_n "checking for cygwin... " >&6; }
12514 if test "${gdb_cv_os_cygwin+set}" = set; then :
12515   $as_echo_n "(cached) " >&6
12516 else
12517   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12518 /* end confdefs.h.  */
12519
12520 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
12521 lose
12522 #endif
12523 _ACEOF
12524 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12525   $EGREP "lose" >/dev/null 2>&1; then :
12526   gdb_cv_os_cygwin=yes
12527 else
12528   gdb_cv_os_cygwin=no
12529 fi
12530 rm -f conftest*
12531
12532 fi
12533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
12534 $as_echo "$gdb_cv_os_cygwin" >&6; }
12535
12536
12537 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
12538 case ${host} in
12539   *go32* ) SER_HARDWIRE=ser-go32.o ;;
12540   *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
12541   *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
12542 esac
12543
12544
12545 # libreadline needs libuser32.a in a cygwin environment
12546 WIN32LIBS=
12547 if test x$gdb_cv_os_cygwin = xyes; then
12548     WIN32LIBS="-luser32"
12549     case "${target}" in
12550         *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
12551         ;;
12552     esac
12553 fi
12554
12555 # The ser-tcp.c module requires sockets.
12556 case ${host} in
12557   *mingw32*)
12558
12559 $as_echo "#define USE_WIN32API 1" >>confdefs.h
12560
12561     WIN32LIBS="$WIN32LIBS -lws2_32"
12562     ;;
12563 esac
12564
12565
12566 # Add ELF support to GDB, but only if BFD includes ELF support.
12567
12568   OLD_CFLAGS=$CFLAGS
12569   OLD_LDFLAGS=$LDFLAGS
12570   OLD_LIBS=$LIBS
12571   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
12572   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
12573   # always want our bfd.
12574   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
12575   LDFLAGS="-L../bfd -L../libiberty $LDFLAGS"
12576   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
12577   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12578   if test "$plugins" = "yes"; then
12579     LIBS="-ldl $LIBS"
12580   fi
12581   LIBS="-lbfd -liberty $intl $LIBS"
12582   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
12583 $as_echo_n "checking for ELF support in BFD... " >&6; }
12584 if test "${gdb_cv_var_elf+set}" = set; then :
12585   $as_echo_n "(cached) " >&6
12586 else
12587   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12588 /* end confdefs.h.  */
12589 #include <stdlib.h>
12590   #include "bfd.h"
12591   #include "elf-bfd.h"
12592
12593 int
12594 main ()
12595 {
12596 return bfd_get_elf_phdr_upper_bound (NULL);
12597   ;
12598   return 0;
12599 }
12600 _ACEOF
12601 if ac_fn_c_try_link "$LINENO"; then :
12602   gdb_cv_var_elf=yes
12603 else
12604   gdb_cv_var_elf=no
12605 fi
12606 rm -f core conftest.err conftest.$ac_objext \
12607     conftest$ac_exeext conftest.$ac_ext
12608 fi
12609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
12610 $as_echo "$gdb_cv_var_elf" >&6; }
12611   CFLAGS=$OLD_CFLAGS
12612   LDFLAGS=$OLD_LDFLAGS
12613   LIBS=$OLD_LIBS
12614 if test $gdb_cv_var_elf = yes; then
12615   CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o"
12616
12617 $as_echo "#define HAVE_ELF 1" >>confdefs.h
12618
12619   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
12620   if test "$plugins" = "yes"; then
12621     LIBS="-ldl $LIBS"
12622   fi
12623 fi
12624
12625 # Add any host-specific objects to GDB.
12626 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
12627
12628 # If building on ELF, look for lzma support for embedded compressed debug info.
12629 if test $gdb_cv_var_elf = yes; then
12630
12631 # Check whether --with-lzma was given.
12632 if test "${with_lzma+set}" = set; then :
12633   withval=$with_lzma;
12634 else
12635   with_lzma=auto
12636 fi
12637
12638   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
12639 $as_echo_n "checking whether to use lzma... " >&6; }
12640   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
12641 $as_echo "$with_lzma" >&6; }
12642
12643   if test "${with_lzma}" != no; then
12644
12645
12646
12647
12648
12649
12650
12651
12652     use_additional=yes
12653
12654   acl_save_prefix="$prefix"
12655   prefix="$acl_final_prefix"
12656   acl_save_exec_prefix="$exec_prefix"
12657   exec_prefix="$acl_final_exec_prefix"
12658
12659     eval additional_includedir=\"$includedir\"
12660     eval additional_libdir=\"$libdir\"
12661
12662   exec_prefix="$acl_save_exec_prefix"
12663   prefix="$acl_save_prefix"
12664
12665
12666 # Check whether --with-liblzma-prefix was given.
12667 if test "${with_liblzma_prefix+set}" = set; then :
12668   withval=$with_liblzma_prefix;
12669     if test "X$withval" = "Xno"; then
12670       use_additional=no
12671     else
12672       if test "X$withval" = "X"; then
12673
12674   acl_save_prefix="$prefix"
12675   prefix="$acl_final_prefix"
12676   acl_save_exec_prefix="$exec_prefix"
12677   exec_prefix="$acl_final_exec_prefix"
12678
12679           eval additional_includedir=\"$includedir\"
12680           eval additional_libdir=\"$libdir\"
12681
12682   exec_prefix="$acl_save_exec_prefix"
12683   prefix="$acl_save_prefix"
12684
12685       else
12686         additional_includedir="$withval/include"
12687         additional_libdir="$withval/lib"
12688       fi
12689     fi
12690
12691 fi
12692
12693       LIBLZMA=
12694   LTLIBLZMA=
12695   INCLZMA=
12696   rpathdirs=
12697   ltrpathdirs=
12698   names_already_handled=
12699   names_next_round='lzma '
12700   while test -n "$names_next_round"; do
12701     names_this_round="$names_next_round"
12702     names_next_round=
12703     for name in $names_this_round; do
12704       already_handled=
12705       for n in $names_already_handled; do
12706         if test "$n" = "$name"; then
12707           already_handled=yes
12708           break
12709         fi
12710       done
12711       if test -z "$already_handled"; then
12712         names_already_handled="$names_already_handled $name"
12713                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
12714         eval value=\"\$HAVE_LIB$uppername\"
12715         if test -n "$value"; then
12716           if test "$value" = yes; then
12717             eval value=\"\$LIB$uppername\"
12718             test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
12719             eval value=\"\$LTLIB$uppername\"
12720             test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
12721           else
12722                                     :
12723           fi
12724         else
12725                               found_dir=
12726           found_la=
12727           found_so=
12728           found_a=
12729           if test $use_additional = yes; then
12730             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
12731               found_dir="$additional_libdir"
12732               found_so="$additional_libdir/lib$name.$shlibext"
12733               if test -f "$additional_libdir/lib$name.la"; then
12734                 found_la="$additional_libdir/lib$name.la"
12735               fi
12736             else
12737               if test -f "$additional_libdir/lib$name.$libext"; then
12738                 found_dir="$additional_libdir"
12739                 found_a="$additional_libdir/lib$name.$libext"
12740                 if test -f "$additional_libdir/lib$name.la"; then
12741                   found_la="$additional_libdir/lib$name.la"
12742                 fi
12743               fi
12744             fi
12745           fi
12746           if test "X$found_dir" = "X"; then
12747             for x in $LDFLAGS $LTLIBLZMA; do
12748
12749   acl_save_prefix="$prefix"
12750   prefix="$acl_final_prefix"
12751   acl_save_exec_prefix="$exec_prefix"
12752   exec_prefix="$acl_final_exec_prefix"
12753   eval x=\"$x\"
12754   exec_prefix="$acl_save_exec_prefix"
12755   prefix="$acl_save_prefix"
12756
12757               case "$x" in
12758                 -L*)
12759                   dir=`echo "X$x" | sed -e 's/^X-L//'`
12760                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
12761                     found_dir="$dir"
12762                     found_so="$dir/lib$name.$shlibext"
12763                     if test -f "$dir/lib$name.la"; then
12764                       found_la="$dir/lib$name.la"
12765                     fi
12766                   else
12767                     if test -f "$dir/lib$name.$libext"; then
12768                       found_dir="$dir"
12769                       found_a="$dir/lib$name.$libext"
12770                       if test -f "$dir/lib$name.la"; then
12771                         found_la="$dir/lib$name.la"
12772                       fi
12773                     fi
12774                   fi
12775                   ;;
12776               esac
12777               if test "X$found_dir" != "X"; then
12778                 break
12779               fi
12780             done
12781           fi
12782           if test "X$found_dir" != "X"; then
12783                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
12784             if test "X$found_so" != "X"; then
12785                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
12786                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12787               else
12788                                                                                 haveit=
12789                 for x in $ltrpathdirs; do
12790                   if test "X$x" = "X$found_dir"; then
12791                     haveit=yes
12792                     break
12793                   fi
12794                 done
12795                 if test -z "$haveit"; then
12796                   ltrpathdirs="$ltrpathdirs $found_dir"
12797                 fi
12798                                 if test "$hardcode_direct" = yes; then
12799                                                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12800                 else
12801                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
12802                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12803                                                             haveit=
12804                     for x in $rpathdirs; do
12805                       if test "X$x" = "X$found_dir"; then
12806                         haveit=yes
12807                         break
12808                       fi
12809                     done
12810                     if test -z "$haveit"; then
12811                       rpathdirs="$rpathdirs $found_dir"
12812                     fi
12813                   else
12814                                                                                 haveit=
12815                     for x in $LDFLAGS $LIBLZMA; do
12816
12817   acl_save_prefix="$prefix"
12818   prefix="$acl_final_prefix"
12819   acl_save_exec_prefix="$exec_prefix"
12820   exec_prefix="$acl_final_exec_prefix"
12821   eval x=\"$x\"
12822   exec_prefix="$acl_save_exec_prefix"
12823   prefix="$acl_save_prefix"
12824
12825                       if test "X$x" = "X-L$found_dir"; then
12826                         haveit=yes
12827                         break
12828                       fi
12829                     done
12830                     if test -z "$haveit"; then
12831                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
12832                     fi
12833                     if test "$hardcode_minus_L" != no; then
12834                                                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
12835                     else
12836                                                                                                                                                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
12837                     fi
12838                   fi
12839                 fi
12840               fi
12841             else
12842               if test "X$found_a" != "X"; then
12843                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
12844               else
12845                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
12846               fi
12847             fi
12848                         additional_includedir=
12849             case "$found_dir" in
12850               */lib | */lib/)
12851                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
12852                 additional_includedir="$basedir/include"
12853                 ;;
12854             esac
12855             if test "X$additional_includedir" != "X"; then
12856                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
12857                 haveit=
12858                 if test "X$additional_includedir" = "X/usr/local/include"; then
12859                   if test -n "$GCC"; then
12860                     case $host_os in
12861                       linux*) haveit=yes;;
12862                     esac
12863                   fi
12864                 fi
12865                 if test -z "$haveit"; then
12866                   for x in $CPPFLAGS $INCLZMA; do
12867
12868   acl_save_prefix="$prefix"
12869   prefix="$acl_final_prefix"
12870   acl_save_exec_prefix="$exec_prefix"
12871   exec_prefix="$acl_final_exec_prefix"
12872   eval x=\"$x\"
12873   exec_prefix="$acl_save_exec_prefix"
12874   prefix="$acl_save_prefix"
12875
12876                     if test "X$x" = "X-I$additional_includedir"; then
12877                       haveit=yes
12878                       break
12879                     fi
12880                   done
12881                   if test -z "$haveit"; then
12882                     if test -d "$additional_includedir"; then
12883                                             INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
12884                     fi
12885                   fi
12886                 fi
12887               fi
12888             fi
12889                         if test -n "$found_la"; then
12890                                                         save_libdir="$libdir"
12891               case "$found_la" in
12892                 */* | *\\*) . "$found_la" ;;
12893                 *) . "./$found_la" ;;
12894               esac
12895               libdir="$save_libdir"
12896                             for dep in $dependency_libs; do
12897                 case "$dep" in
12898                   -L*)
12899                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
12900                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
12901                       haveit=
12902                       if test "X$additional_libdir" = "X/usr/local/lib"; then
12903                         if test -n "$GCC"; then
12904                           case $host_os in
12905                             linux*) haveit=yes;;
12906                           esac
12907                         fi
12908                       fi
12909                       if test -z "$haveit"; then
12910                         haveit=
12911                         for x in $LDFLAGS $LIBLZMA; do
12912
12913   acl_save_prefix="$prefix"
12914   prefix="$acl_final_prefix"
12915   acl_save_exec_prefix="$exec_prefix"
12916   exec_prefix="$acl_final_exec_prefix"
12917   eval x=\"$x\"
12918   exec_prefix="$acl_save_exec_prefix"
12919   prefix="$acl_save_prefix"
12920
12921                           if test "X$x" = "X-L$additional_libdir"; then
12922                             haveit=yes
12923                             break
12924                           fi
12925                         done
12926                         if test -z "$haveit"; then
12927                           if test -d "$additional_libdir"; then
12928                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
12929                           fi
12930                         fi
12931                         haveit=
12932                         for x in $LDFLAGS $LTLIBLZMA; do
12933
12934   acl_save_prefix="$prefix"
12935   prefix="$acl_final_prefix"
12936   acl_save_exec_prefix="$exec_prefix"
12937   exec_prefix="$acl_final_exec_prefix"
12938   eval x=\"$x\"
12939   exec_prefix="$acl_save_exec_prefix"
12940   prefix="$acl_save_prefix"
12941
12942                           if test "X$x" = "X-L$additional_libdir"; then
12943                             haveit=yes
12944                             break
12945                           fi
12946                         done
12947                         if test -z "$haveit"; then
12948                           if test -d "$additional_libdir"; then
12949                                                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
12950                           fi
12951                         fi
12952                       fi
12953                     fi
12954                     ;;
12955                   -R*)
12956                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
12957                     if test "$enable_rpath" != no; then
12958                                                                   haveit=
12959                       for x in $rpathdirs; do
12960                         if test "X$x" = "X$dir"; then
12961                           haveit=yes
12962                           break
12963                         fi
12964                       done
12965                       if test -z "$haveit"; then
12966                         rpathdirs="$rpathdirs $dir"
12967                       fi
12968                                                                   haveit=
12969                       for x in $ltrpathdirs; do
12970                         if test "X$x" = "X$dir"; then
12971                           haveit=yes
12972                           break
12973                         fi
12974                       done
12975                       if test -z "$haveit"; then
12976                         ltrpathdirs="$ltrpathdirs $dir"
12977                       fi
12978                     fi
12979                     ;;
12980                   -l*)
12981                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
12982                     ;;
12983                   *.la)
12984                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
12985                     ;;
12986                   *)
12987                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
12988                     LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
12989                     ;;
12990                 esac
12991               done
12992             fi
12993           else
12994                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
12995             LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
12996           fi
12997         fi
12998       fi
12999     done
13000   done
13001   if test "X$rpathdirs" != "X"; then
13002     if test -n "$hardcode_libdir_separator"; then
13003                         alldirs=
13004       for found_dir in $rpathdirs; do
13005         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
13006       done
13007             acl_save_libdir="$libdir"
13008       libdir="$alldirs"
13009       eval flag=\"$hardcode_libdir_flag_spec\"
13010       libdir="$acl_save_libdir"
13011       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
13012     else
13013             for found_dir in $rpathdirs; do
13014         acl_save_libdir="$libdir"
13015         libdir="$found_dir"
13016         eval flag=\"$hardcode_libdir_flag_spec\"
13017         libdir="$acl_save_libdir"
13018         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
13019       done
13020     fi
13021   fi
13022   if test "X$ltrpathdirs" != "X"; then
13023             for found_dir in $ltrpathdirs; do
13024       LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
13025     done
13026   fi
13027
13028
13029         ac_save_CPPFLAGS="$CPPFLAGS"
13030
13031   for element in $INCLZMA; do
13032     haveit=
13033     for x in $CPPFLAGS; do
13034
13035   acl_save_prefix="$prefix"
13036   prefix="$acl_final_prefix"
13037   acl_save_exec_prefix="$exec_prefix"
13038   exec_prefix="$acl_final_exec_prefix"
13039   eval x=\"$x\"
13040   exec_prefix="$acl_save_exec_prefix"
13041   prefix="$acl_save_prefix"
13042
13043       if test "X$x" = "X$element"; then
13044         haveit=yes
13045         break
13046       fi
13047     done
13048     if test -z "$haveit"; then
13049       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
13050     fi
13051   done
13052
13053
13054   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
13055 $as_echo_n "checking for liblzma... " >&6; }
13056 if test "${ac_cv_liblzma+set}" = set; then :
13057   $as_echo_n "(cached) " >&6
13058 else
13059
13060     ac_save_LIBS="$LIBS"
13061     LIBS="$LIBS $LIBLZMA"
13062     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13063 /* end confdefs.h.  */
13064 #include "lzma.h"
13065 int
13066 main ()
13067 {
13068 lzma_index_iter iter;
13069                            lzma_index_iter_init (&iter, 0);
13070                            lzma_mf_is_supported (LZMA_MF_HC3);
13071   ;
13072   return 0;
13073 }
13074 _ACEOF
13075 if ac_fn_c_try_link "$LINENO"; then :
13076   ac_cv_liblzma=yes
13077 else
13078   ac_cv_liblzma=no
13079 fi
13080 rm -f core conftest.err conftest.$ac_objext \
13081     conftest$ac_exeext conftest.$ac_ext
13082     LIBS="$ac_save_LIBS"
13083
13084 fi
13085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
13086 $as_echo "$ac_cv_liblzma" >&6; }
13087   if test "$ac_cv_liblzma" = yes; then
13088     HAVE_LIBLZMA=yes
13089
13090 $as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
13091
13092     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
13093 $as_echo_n "checking how to link with liblzma... " >&6; }
13094     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
13095 $as_echo "$LIBLZMA" >&6; }
13096   else
13097     HAVE_LIBLZMA=no
13098             CPPFLAGS="$ac_save_CPPFLAGS"
13099     LIBLZMA=
13100     LTLIBLZMA=
13101   fi
13102
13103
13104
13105
13106
13107
13108     if test "$HAVE_LIBLZMA" != yes; then
13109       if test "$with_lzma" = yes; then
13110         as_fn_error "missing liblzma for --with-lzma" "$LINENO" 5
13111       fi
13112     fi
13113   fi
13114 fi
13115
13116 LIBGUI="../libgui/src/libgui.a"
13117 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
13118
13119
13120
13121 WIN32LDAPP=
13122
13123
13124
13125 case "${host}" in
13126 *-*-cygwin* | *-*-mingw* )
13127     configdir="win"
13128     ;;
13129 *)
13130     configdir="unix"
13131     ;;
13132 esac
13133
13134 GDBTKLIBS=
13135 if test "${enable_gdbtk}" = "yes"; then
13136
13137     # Gdbtk must have an absolute path to srcdir in order to run
13138     # properly when not installed.
13139     here=`pwd`
13140     cd ${srcdir}
13141     GDBTK_SRC_DIR=`pwd`
13142     cd $here
13143
13144
13145     #
13146     # Ok, lets find the tcl configuration
13147     # First, look for one uninstalled.
13148     # the alternative search directory is invoked by --with-tcl
13149     #
13150
13151     if test x"${no_tcl}" = x ; then
13152         # we reset no_tcl in case something fails here
13153         no_tcl=true
13154
13155 # Check whether --with-tcl was given.
13156 if test "${with_tcl+set}" = set; then :
13157   withval=$with_tcl; with_tclconfig=${withval}
13158 fi
13159
13160         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
13161 $as_echo_n "checking for Tcl configuration... " >&6; }
13162         if test "${ac_cv_c_tclconfig+set}" = set; then :
13163   $as_echo_n "(cached) " >&6
13164 else
13165
13166
13167             # First check to see if --with-tcl was specified.
13168             case "${host}" in
13169                 *-*-cygwin*) platDir="win" ;;
13170                 *) platDir="unix" ;;
13171             esac
13172             if test x"${with_tclconfig}" != x ; then
13173                 if test -f "${with_tclconfig}/tclConfig.sh" ; then
13174                     ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
13175                 else
13176                     as_fn_error "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
13177                 fi
13178             fi
13179
13180             # then check for a private Tcl installation
13181             if test x"${ac_cv_c_tclconfig}" = x ; then
13182                 for i in \
13183                         ../tcl \
13184                         `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13185                         `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
13186                         `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
13187                         ../../tcl \
13188                         `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13189                         `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
13190                         `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
13191                         ../../../tcl \
13192                         `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13193                         `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
13194                         `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
13195                     if test -f "$i/$platDir/tclConfig.sh" ; then
13196                         ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
13197                         break
13198                     fi
13199                 done
13200             fi
13201
13202             # on Darwin, check in Framework installation locations
13203             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
13204                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
13205                         `ls -d /Library/Frameworks 2>/dev/null` \
13206                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
13207                         `ls -d /System/Library/Frameworks 2>/dev/null` \
13208                         ; do
13209                     if test -f "$i/Tcl.framework/tclConfig.sh" ; then
13210                         ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
13211                         break
13212                     fi
13213                 done
13214             fi
13215
13216             # check in a few common install locations
13217             if test x"${ac_cv_c_tclconfig}" = x ; then
13218                 for i in `ls -d ${libdir} 2>/dev/null` \
13219                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
13220                         `ls -d ${prefix}/lib 2>/dev/null` \
13221                         `ls -d /usr/local/lib 2>/dev/null` \
13222                         `ls -d /usr/contrib/lib 2>/dev/null` \
13223                         `ls -d /usr/lib 2>/dev/null` \
13224                         ; do
13225                     if test -f "$i/tclConfig.sh" ; then
13226                         ac_cv_c_tclconfig=`(cd $i; pwd)`
13227                         break
13228                     fi
13229                 done
13230             fi
13231
13232             # check in a few other private locations
13233             if test x"${ac_cv_c_tclconfig}" = x ; then
13234                 for i in \
13235                         ${srcdir}/../tcl \
13236                         `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
13237                         `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
13238                         `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
13239                     if test -f "$i/$platDir/tclConfig.sh" ; then
13240                     ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
13241                     break
13242                 fi
13243                 done
13244             fi
13245
13246 fi
13247
13248
13249         if test x"${ac_cv_c_tclconfig}" = x ; then
13250             TCL_BIN_DIR="# no Tcl configs found"
13251             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
13252 $as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
13253         else
13254             no_tcl=
13255             TCL_BIN_DIR=${ac_cv_c_tclconfig}
13256             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
13257 $as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
13258         fi
13259     fi
13260
13261
13262     # If $no_tk is nonempty, then we can't do Tk, and there is no
13263     # point to doing Tcl.
13264
13265     #
13266     # Ok, lets find the tk configuration
13267     # First, look for one uninstalled.
13268     # the alternative search directory is invoked by --with-tk
13269     #
13270
13271     if test x"${no_tk}" = x ; then
13272         # we reset no_tk in case something fails here
13273         no_tk=true
13274
13275 # Check whether --with-tk was given.
13276 if test "${with_tk+set}" = set; then :
13277   withval=$with_tk; with_tkconfig=${withval}
13278 fi
13279
13280         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
13281 $as_echo_n "checking for Tk configuration... " >&6; }
13282         if test "${ac_cv_c_tkconfig+set}" = set; then :
13283   $as_echo_n "(cached) " >&6
13284 else
13285
13286
13287             # First check to see if --with-tkconfig was specified.
13288             if test x"${with_tkconfig}" != x ; then
13289                 if test -f "${with_tkconfig}/tkConfig.sh" ; then
13290                     ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
13291                 else
13292                     as_fn_error "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
13293                 fi
13294             fi
13295
13296             # then check for a private Tk library
13297             case "${host}" in
13298                 *-*-cygwin*) platDir="win" ;;
13299                 *) platDir="unix" ;;
13300             esac
13301             if test x"${ac_cv_c_tkconfig}" = x ; then
13302                 for i in \
13303                         ../tk \
13304                         `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13305                         `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
13306                         `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
13307                         ../../tk \
13308                         `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13309                         `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
13310                         `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
13311                         ../../../tk \
13312                         `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13313                         `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
13314                         `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
13315                     if test -f "$i/$platDir/tkConfig.sh" ; then
13316                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
13317                         break
13318                     fi
13319                 done
13320             fi
13321
13322             # on Darwin, check in Framework installation locations
13323             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
13324                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
13325                         `ls -d /Library/Frameworks 2>/dev/null` \
13326                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
13327                         `ls -d /System/Library/Frameworks 2>/dev/null` \
13328                         ; do
13329                     if test -f "$i/Tk.framework/tkConfig.sh" ; then
13330                         ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
13331                         break
13332                     fi
13333                 done
13334             fi
13335
13336             # check in a few common install locations
13337             if test x"${ac_cv_c_tkconfig}" = x ; then
13338                 for i in `ls -d ${libdir} 2>/dev/null` \
13339                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
13340                         `ls -d ${prefix}/lib 2>/dev/null` \
13341                         `ls -d /usr/local/lib 2>/dev/null` \
13342                         `ls -d /usr/contrib/lib 2>/dev/null` \
13343                         `ls -d /usr/lib 2>/dev/null` \
13344                         ; do
13345                     if test -f "$i/tkConfig.sh" ; then
13346                         ac_cv_c_tkconfig=`(cd $i; pwd)`
13347                         break
13348                     fi
13349                 done
13350             fi
13351             # check in a few other private locations
13352             if test x"${ac_cv_c_tkconfig}" = x ; then
13353                 for i in \
13354                         ${srcdir}/../tk \
13355                         `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
13356                         `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
13357                         `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
13358                     if test -f "$i/$platDir/tkConfig.sh" ; then
13359                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
13360                         break
13361                     fi
13362                 done
13363             fi
13364
13365 fi
13366
13367
13368         if test x"${ac_cv_c_tkconfig}" = x ; then
13369             TK_BIN_DIR="# no Tk configs found"
13370             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
13371 $as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
13372         else
13373             no_tk=
13374             TK_BIN_DIR=${ac_cv_c_tkconfig}
13375             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
13376 $as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
13377         fi
13378     fi
13379
13380
13381     if test -z "${no_tcl}" -a -z "${no_tk}"; then
13382
13383     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
13384 $as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
13385
13386     if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
13387         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
13388 $as_echo "loading" >&6; }
13389         . ${TCL_BIN_DIR}/tclConfig.sh
13390     else
13391         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
13392 $as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
13393     fi
13394
13395     # eval is required to do the TCL_DBGX substitution
13396     eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
13397     eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
13398
13399     # If the TCL_BIN_DIR is the build directory (not the install directory),
13400     # then set the common variable name to the value of the build variables.
13401     # For example, the variable TCL_LIB_SPEC will be set to the value
13402     # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
13403     # instead of TCL_BUILD_LIB_SPEC since it will work with both an
13404     # installed and uninstalled version of Tcl.
13405     if test -f "${TCL_BIN_DIR}/Makefile" ; then
13406         TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
13407         TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
13408         TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
13409     elif test "`uname -s`" = "Darwin"; then
13410         # If Tcl was built as a framework, attempt to use the libraries
13411         # from the framework at the given location so that linking works
13412         # against Tcl.framework installed in an arbitrary location.
13413         case ${TCL_DEFS} in
13414             *TCL_FRAMEWORK*)
13415                 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
13416                     for i in "`cd ${TCL_BIN_DIR}; pwd`" \
13417                              "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
13418                         if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
13419                             TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
13420                             break
13421                         fi
13422                     done
13423                 fi
13424                 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
13425                     TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
13426                     TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
13427                 fi
13428                 ;;
13429         esac
13430     fi
13431
13432     # eval is required to do the TCL_DBGX substitution
13433     eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
13434     eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
13435     eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
13436     eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446
13447
13448
13449
13450
13451
13452         # Check for in-tree tcl
13453         here=`pwd`
13454         cd ${srcdir}/..
13455         topdir=`pwd`
13456         cd ${here}
13457
13458         intree="no"
13459         if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
13460           intree="yes"
13461         fi
13462
13463         # Find Tcl private headers
13464         if test x"${intree}" = xno; then
13465
13466   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
13467 $as_echo_n "checking for Tcl private headers... " >&6; }
13468   private_dir=""
13469   dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
13470   if test -f ${dir}/tclInt.h ; then
13471     private_dir=${dir}
13472   fi
13473
13474   if test x"${private_dir}" = x; then
13475     as_fn_error "could not find private Tcl headers" "$LINENO" 5
13476   else
13477     TCL_PRIVATE_INCLUDE="-I${private_dir}"
13478     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
13479 $as_echo "${private_dir}" >&6; }
13480   fi
13481
13482           TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
13483           TCL_LIBRARY="${TCL_LIB_SPEC}"
13484           TCL_DEPS=""
13485         else
13486           # If building tcl in the same src tree, private headers
13487           # are not needed, but we need to be sure to use the right
13488           # headers library
13489           TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
13490           TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
13491           TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
13492         fi
13493
13494
13495
13496
13497
13498     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
13499 $as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
13500
13501     if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
13502         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
13503 $as_echo "loading" >&6; }
13504         . ${TK_BIN_DIR}/tkConfig.sh
13505     else
13506         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
13507 $as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
13508     fi
13509
13510     # eval is required to do the TK_DBGX substitution
13511     eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
13512     eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
13513
13514     # If the TK_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 TK_LIB_SPEC will be set to the value
13517     # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
13518     # instead of TK_BUILD_LIB_SPEC since it will work with both an
13519     # installed and uninstalled version of Tcl.
13520     if test -f "${TK_BIN_DIR}/Makefile" ; then
13521         TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
13522         TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
13523         TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
13524     elif test "`uname -s`" = "Darwin"; then
13525         # If Tk was built as a framework, attempt to use the libraries
13526         # from the framework at the given location so that linking works
13527         # against Tk.framework installed in an arbitrary location.
13528         case ${TK_DEFS} in
13529             *TK_FRAMEWORK*)
13530                 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
13531                     for i in "`cd ${TK_BIN_DIR}; pwd`" \
13532                              "`cd ${TK_BIN_DIR}/../..; pwd`"; do
13533                         if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
13534                             TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
13535                             break
13536                         fi
13537                     done
13538                 fi
13539                 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
13540                     TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
13541                     TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
13542                 fi
13543                 ;;
13544         esac
13545     fi
13546
13547     # eval is required to do the TK_DBGX substitution
13548     eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
13549     eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
13550     eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
13551     eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
13552
13553
13554
13555
13556
13557
13558
13559
13560
13561
13562
13563
13564
13565
13566         # Check for in-tree Tk
13567         intree="no"
13568         if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
13569           intree="yes"
13570         fi
13571
13572         # Find Tk private headers
13573         if test x"${intree}" = xno; then
13574
13575   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
13576 $as_echo_n "checking for Tk private headers... " >&6; }
13577   private_dir=""
13578   dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
13579   if test -f ${dir}/tkInt.h; then
13580     private_dir=${dir}
13581   fi
13582
13583   if test x"${private_dir}" = x; then
13584     as_fn_error "could not find Tk private headers" "$LINENO" 5
13585   else
13586     TK_PRIVATE_INCLUDE="-I${private_dir}"
13587     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
13588 $as_echo "${private_dir}" >&6; }
13589   fi
13590
13591           TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
13592           TK_LIBRARY=${TK_LIB_SPEC}
13593           TK_DEPS=""
13594         else
13595           TK_INCLUDE="-I${TK_SRC_DIR}/generic"
13596           TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
13597           TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
13598         fi
13599
13600
13601
13602
13603
13604         ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
13605
13606         # Include some libraries that Tcl and Tk want.
13607         TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
13608         # Yes, the ordering seems wrong here.  But it isn't.
13609         # TK_LIBS is the list of libraries that need to be linked
13610         # after Tcl/Tk.  Note that this isn't put into LIBS.  If it
13611         # were in LIBS then any link tests after this point would
13612         # try to include things like `$(LIBGUI)', which wouldn't work.
13613         GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
13614
13615         CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
13616         CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
13617         CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
13618         CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
13619         CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
13620         CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
13621         CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
13622
13623         if test x$gdb_cv_os_cygwin = xyes; then
13624           WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
13625           WIN32LDAPP="-Wl,--subsystem,console"
13626           CONFIG_OBS="${CONFIG_OBS} gdbres.o"
13627         fi
13628
13629         subdirs="$subdirs gdbtk"
13630
13631     fi
13632 fi
13633
13634
13635
13636
13637
13638
13639
13640
13641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
13642 $as_echo_n "checking for X... " >&6; }
13643
13644
13645 # Check whether --with-x was given.
13646 if test "${with_x+set}" = set; then :
13647   withval=$with_x;
13648 fi
13649
13650 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
13651 if test "x$with_x" = xno; then
13652   # The user explicitly disabled X.
13653   have_x=disabled
13654 else
13655   case $x_includes,$x_libraries in #(
13656     *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
13657     *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
13658   $as_echo_n "(cached) " >&6
13659 else
13660   # One or both of the vars are not set, and there is no cached value.
13661 ac_x_includes=no ac_x_libraries=no
13662 rm -f -r conftest.dir
13663 if mkdir conftest.dir; then
13664   cd conftest.dir
13665   cat >Imakefile <<'_ACEOF'
13666 incroot:
13667         @echo incroot='${INCROOT}'
13668 usrlibdir:
13669         @echo usrlibdir='${USRLIBDIR}'
13670 libdir:
13671         @echo libdir='${LIBDIR}'
13672 _ACEOF
13673   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
13674     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
13675     for ac_var in incroot usrlibdir libdir; do
13676       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
13677     done
13678     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
13679     for ac_extension in a so sl dylib la dll; do
13680       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
13681          test -f "$ac_im_libdir/libX11.$ac_extension"; then
13682         ac_im_usrlibdir=$ac_im_libdir; break
13683       fi
13684     done
13685     # Screen out bogus values from the imake configuration.  They are
13686     # bogus both because they are the default anyway, and because
13687     # using them would break gcc on systems where it needs fixed includes.
13688     case $ac_im_incroot in
13689         /usr/include) ac_x_includes= ;;
13690         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
13691     esac
13692     case $ac_im_usrlibdir in
13693         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
13694         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
13695     esac
13696   fi
13697   cd ..
13698   rm -f -r conftest.dir
13699 fi
13700
13701 # Standard set of common directories for X headers.
13702 # Check X11 before X11Rn because it is often a symlink to the current release.
13703 ac_x_header_dirs='
13704 /usr/X11/include
13705 /usr/X11R7/include
13706 /usr/X11R6/include
13707 /usr/X11R5/include
13708 /usr/X11R4/include
13709
13710 /usr/include/X11
13711 /usr/include/X11R7
13712 /usr/include/X11R6
13713 /usr/include/X11R5
13714 /usr/include/X11R4
13715
13716 /usr/local/X11/include
13717 /usr/local/X11R7/include
13718 /usr/local/X11R6/include
13719 /usr/local/X11R5/include
13720 /usr/local/X11R4/include
13721
13722 /usr/local/include/X11
13723 /usr/local/include/X11R7
13724 /usr/local/include/X11R6
13725 /usr/local/include/X11R5
13726 /usr/local/include/X11R4
13727
13728 /usr/X386/include
13729 /usr/x386/include
13730 /usr/XFree86/include/X11
13731
13732 /usr/include
13733 /usr/local/include
13734 /usr/unsupported/include
13735 /usr/athena/include
13736 /usr/local/x11r5/include
13737 /usr/lpp/Xamples/include
13738
13739 /usr/openwin/include
13740 /usr/openwin/share/include'
13741
13742 if test "$ac_x_includes" = no; then
13743   # Guess where to find include files, by looking for Xlib.h.
13744   # First, try using that file with no special directory specified.
13745   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13746 /* end confdefs.h.  */
13747 #include <X11/Xlib.h>
13748 _ACEOF
13749 if ac_fn_c_try_cpp "$LINENO"; then :
13750   # We can compile using X headers with no special include directory.
13751 ac_x_includes=
13752 else
13753   for ac_dir in $ac_x_header_dirs; do
13754   if test -r "$ac_dir/X11/Xlib.h"; then
13755     ac_x_includes=$ac_dir
13756     break
13757   fi
13758 done
13759 fi
13760 rm -f conftest.err conftest.$ac_ext
13761 fi # $ac_x_includes = no
13762
13763 if test "$ac_x_libraries" = no; then
13764   # Check for the libraries.
13765   # See if we find them without any special options.
13766   # Don't add to $LIBS permanently.
13767   ac_save_LIBS=$LIBS
13768   LIBS="-lX11 $LIBS"
13769   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13770 /* end confdefs.h.  */
13771 #include <X11/Xlib.h>
13772 int
13773 main ()
13774 {
13775 XrmInitialize ()
13776   ;
13777   return 0;
13778 }
13779 _ACEOF
13780 if ac_fn_c_try_link "$LINENO"; then :
13781   LIBS=$ac_save_LIBS
13782 # We can link X programs with no special library path.
13783 ac_x_libraries=
13784 else
13785   LIBS=$ac_save_LIBS
13786 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
13787 do
13788   # Don't even attempt the hair of trying to link an X program!
13789   for ac_extension in a so sl dylib la dll; do
13790     if test -r "$ac_dir/libX11.$ac_extension"; then
13791       ac_x_libraries=$ac_dir
13792       break 2
13793     fi
13794   done
13795 done
13796 fi
13797 rm -f core conftest.err conftest.$ac_objext \
13798     conftest$ac_exeext conftest.$ac_ext
13799 fi # $ac_x_libraries = no
13800
13801 case $ac_x_includes,$ac_x_libraries in #(
13802   no,* | *,no | *\'*)
13803     # Didn't find X, or a directory has "'" in its name.
13804     ac_cv_have_x="have_x=no";; #(
13805   *)
13806     # Record where we found X for the cache.
13807     ac_cv_have_x="have_x=yes\
13808         ac_x_includes='$ac_x_includes'\
13809         ac_x_libraries='$ac_x_libraries'"
13810 esac
13811 fi
13812 ;; #(
13813     *) have_x=yes;;
13814   esac
13815   eval "$ac_cv_have_x"
13816 fi # $with_x != no
13817
13818 if test "$have_x" != yes; then
13819   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
13820 $as_echo "$have_x" >&6; }
13821   no_x=yes
13822 else
13823   # If each of the values was on the command line, it overrides each guess.
13824   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
13825   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
13826   # Update the cache value to reflect the command line values.
13827   ac_cv_have_x="have_x=yes\
13828         ac_x_includes='$x_includes'\
13829         ac_x_libraries='$x_libraries'"
13830   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
13831 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
13832 fi
13833
13834
13835 # Unlike the sim directory, whether a simulator is linked is controlled by
13836 # presence of a gdb_sim definition in the target configure.tgt entry.
13837 # This code just checks for a few cases where we'd like to ignore those
13838 # definitions, even when they're present in the '.mt' file.  These cases
13839 # are when --disable-sim is specified, or if the simulator directory is
13840 # not part of the source tree.
13841 #
13842 # Check whether --enable-sim was given.
13843 if test "${enable_sim+set}" = set; then :
13844   enableval=$enable_sim; echo "enable_sim = $enable_sim";
13845  echo "enableval = ${enableval}";
13846  case "${enableval}" in
13847   yes) ignore_sim=false ;;
13848   no)  ignore_sim=true ;;
13849   *)   ignore_sim=false ;;
13850  esac
13851 else
13852   ignore_sim=false
13853 fi
13854
13855
13856 if test ! -d "${srcdir}/../sim"; then
13857   ignore_sim=true
13858 fi
13859
13860 SIM=
13861 SIM_OBS=
13862 if test "${ignore_sim}" = "false"; then
13863   if test x"${gdb_sim}" != x ; then
13864     SIM="${gdb_sim}"
13865     SIM_OBS="remote-sim.o"
13866
13867 $as_echo "#define WITH_SIM 1" >>confdefs.h
13868
13869   fi
13870 fi
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885 # List of host floatformats.
13886
13887 cat >>confdefs.h <<_ACEOF
13888 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
13889 _ACEOF
13890
13891
13892 cat >>confdefs.h <<_ACEOF
13893 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
13894 _ACEOF
13895
13896
13897 cat >>confdefs.h <<_ACEOF
13898 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
13899 _ACEOF
13900
13901
13902 # target_subdir is used by the testsuite to find the target libraries.
13903 target_subdir=
13904 if test "${host}" != "${target}"; then
13905     target_subdir="${target_alias}/"
13906 fi
13907
13908
13909 frags=
13910 if test "${gdb_native}" = "yes"; then
13911   host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
13912   if test ! -f ${host_makefile_frag}; then
13913     as_fn_error "\"*** Gdb does not support native target ${host}\"" "$LINENO" 5
13914   fi
13915   frags="$frags $host_makefile_frag"
13916 else
13917   host_makefile_frag=/dev/null
13918 fi
13919
13920
13921
13922
13923 if test "${gdb_native}" = "yes"; then
13924 # We pick this up from the host configuration file (.mh) because we
13925 # do not have a native configuration Makefile fragment.
13926 nativefile=`sed -n '
13927 s/NAT_FILE[     ]*=[    ]*\([^  ]*\)/\1/p
13928 ' ${host_makefile_frag}`
13929 fi
13930
13931
13932 if test x"${gdb_osabi}" != x ; then
13933
13934 cat >>confdefs.h <<_ACEOF
13935 #define GDB_OSABI_DEFAULT $gdb_osabi
13936 _ACEOF
13937
13938 fi
13939
13940 # Enable multi-ice-gdb-server.
13941 # Check whether --enable-multi-ice was given.
13942 if test "${enable_multi_ice+set}" = set; then :
13943   enableval=$enable_multi_ice; case $enableval in
13944     yes | no)
13945       ;;
13946     *) as_fn_error "bad value $enableval for --enable-multi-ice" "$LINENO" 5 ;;
13947   esac
13948 fi
13949
13950 if test "x$enable_multi_ice" = xyes; then
13951    subdirs="$subdirs multi-ice"
13952
13953 fi
13954
13955 # Check whether --enable-gdbserver was given.
13956 if test "${enable_gdbserver+set}" = set; then :
13957   enableval=$enable_gdbserver; case "${enableval}" in
13958   yes| no|auto) ;;
13959   *) as_fn_error "bad value ${enableval} for --enable-gdbserver option" "$LINENO" 5 ;;
13960 esac
13961 else
13962   enable_gdbserver=auto
13963 fi
13964
13965
13966 # We only build gdbserver automatically in a native configuration, and
13967 # only if the user did not explicitly disable its build.
13968 if test "$gdb_native" = "yes" -a "$enable_gdbserver" != "no"; then
13969   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gdbserver is supported on this host" >&5
13970 $as_echo_n "checking whether gdbserver is supported on this host... " >&6; }
13971   if test "x$build_gdbserver" = xyes; then
13972     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13973 $as_echo "yes" >&6; }
13974     subdirs="$subdirs gdbserver"
13975
13976     gdbserver_build_enabled=yes
13977   else
13978     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13979 $as_echo "no" >&6; }
13980   fi
13981 fi
13982
13983 # If the user explicitly request the gdbserver to be built, verify that
13984 # we were in fact able to enable it.
13985 if test "$enable_gdbserver" = "yes" -a "$gdbserver_build_enabled" != "yes"; then
13986   as_fn_error "Automatic gdbserver build is not supported for this configuration" "$LINENO" 5
13987 fi
13988
13989 # If nativefile (NAT_FILE) is not set in config/*/*.m[ht] files, we link
13990 # to an empty version.
13991
13992 files=
13993 links=
13994
13995 rm -f nm.h
13996 if test "${nativefile}" != ""; then
13997     case "${nativefile}" in
13998       nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
13999       * ) GDB_NM_FILE="${nativefile}"
14000     esac
14001     files="${files} ${GDB_NM_FILE}"
14002     links="${links} nm.h"
14003
14004 cat >>confdefs.h <<_ACEOF
14005 #define GDB_NM_FILE "${GDB_NM_FILE}"
14006 _ACEOF
14007
14008 fi
14009
14010
14011 ac_sources="$files"
14012 ac_dests="$links"
14013 while test -n "$ac_sources"; do
14014   set $ac_dests; ac_dest=$1; shift; ac_dests=$*
14015   set $ac_sources; ac_source=$1; shift; ac_sources=$*
14016   ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
14017 done
14018 ac_config_links="$ac_config_links $ac_config_links_1"
14019
14020
14021
14022
14023
14024 $as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
14025
14026
14027 ac_config_files="$ac_config_files Makefile gdb-gdb.gdb doc/Makefile data-directory/Makefile"
14028
14029 ac_config_commands="$ac_config_commands default"
14030
14031 cat >confcache <<\_ACEOF
14032 # This file is a shell script that caches the results of configure
14033 # tests run on this system so they can be shared between configure
14034 # scripts and configure runs, see configure's option --config-cache.
14035 # It is not useful on other systems.  If it contains results you don't
14036 # want to keep, you may remove or edit it.
14037 #
14038 # config.status only pays attention to the cache file if you give it
14039 # the --recheck option to rerun configure.
14040 #
14041 # `ac_cv_env_foo' variables (set or unset) will be overridden when
14042 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14043 # following values.
14044
14045 _ACEOF
14046
14047 # The following way of writing the cache mishandles newlines in values,
14048 # but we know of no workaround that is simple, portable, and efficient.
14049 # So, we kill variables containing newlines.
14050 # Ultrix sh set writes to stderr and can't be redirected directly,
14051 # and sets the high bit in the cache file unless we assign to the vars.
14052 (
14053   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
14054     eval ac_val=\$$ac_var
14055     case $ac_val in #(
14056     *${as_nl}*)
14057       case $ac_var in #(
14058       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
14059 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
14060       esac
14061       case $ac_var in #(
14062       _ | IFS | as_nl) ;; #(
14063       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
14064       *) { eval $ac_var=; unset $ac_var;} ;;
14065       esac ;;
14066     esac
14067   done
14068
14069   (set) 2>&1 |
14070     case $as_nl`(ac_space=' '; set) 2>&1` in #(
14071     *${as_nl}ac_space=\ *)
14072       # `set' does not quote correctly, so add quotes: double-quote
14073       # substitution turns \\\\ into \\, and sed turns \\ into \.
14074       sed -n \
14075         "s/'/'\\\\''/g;
14076           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14077       ;; #(
14078     *)
14079       # `set' quotes correctly as required by POSIX, so do not add quotes.
14080       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
14081       ;;
14082     esac |
14083     sort
14084 ) |
14085   sed '
14086      /^ac_cv_env_/b end
14087      t clear
14088      :clear
14089      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14090      t end
14091      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14092      :end' >>confcache
14093 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
14094   if test -w "$cache_file"; then
14095     test "x$cache_file" != "x/dev/null" &&
14096       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
14097 $as_echo "$as_me: updating cache $cache_file" >&6;}
14098     cat confcache >$cache_file
14099   else
14100     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
14101 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
14102   fi
14103 fi
14104 rm -f confcache
14105
14106 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14107 # Let make expand exec_prefix.
14108 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14109
14110 DEFS=-DHAVE_CONFIG_H
14111
14112 ac_libobjs=
14113 ac_ltlibobjs=
14114 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
14115   # 1. Remove the extension, and $U if already installed.
14116   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
14117   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
14118   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
14119   #    will be set to the directory where LIBOBJS objects are built.
14120   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
14121   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
14122 done
14123 LIBOBJS=$ac_libobjs
14124
14125 LTLIBOBJS=$ac_ltlibobjs
14126
14127
14128 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
14129   as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
14130 Usually this means the macro was only invoked conditionally." "$LINENO" 5
14131 fi
14132 if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
14133   as_fn_error "conditional \"GMAKE\" was never defined.
14134 Usually this means the macro was only invoked conditionally." "$LINENO" 5
14135 fi
14136
14137
14138 : ${CONFIG_STATUS=./config.status}
14139 ac_write_fail=0
14140 ac_clean_files_save=$ac_clean_files
14141 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14142 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
14143 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
14144 as_write_fail=0
14145 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
14146 #! $SHELL
14147 # Generated by $as_me.
14148 # Run this file to recreate the current configuration.
14149 # Compiler output produced by configure, useful for debugging
14150 # configure, is in config.log if it exists.
14151
14152 debug=false
14153 ac_cs_recheck=false
14154 ac_cs_silent=false
14155
14156 SHELL=\${CONFIG_SHELL-$SHELL}
14157 export SHELL
14158 _ASEOF
14159 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
14160 ## -------------------- ##
14161 ## M4sh Initialization. ##
14162 ## -------------------- ##
14163
14164 # Be more Bourne compatible
14165 DUALCASE=1; export DUALCASE # for MKS sh
14166 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14167   emulate sh
14168   NULLCMD=:
14169   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14170   # is contrary to our usage.  Disable this feature.
14171   alias -g '${1+"$@"}'='"$@"'
14172   setopt NO_GLOB_SUBST
14173 else
14174   case `(set -o) 2>/dev/null` in #(
14175   *posix*) :
14176     set -o posix ;; #(
14177   *) :
14178      ;;
14179 esac
14180 fi
14181
14182
14183 as_nl='
14184 '
14185 export as_nl
14186 # Printing a long string crashes Solaris 7 /usr/bin/printf.
14187 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14188 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14189 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14190 # Prefer a ksh shell builtin over an external printf program on Solaris,
14191 # but without wasting forks for bash or zsh.
14192 if test -z "$BASH_VERSION$ZSH_VERSION" \
14193     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14194   as_echo='print -r --'
14195   as_echo_n='print -rn --'
14196 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14197   as_echo='printf %s\n'
14198   as_echo_n='printf %s'
14199 else
14200   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14201     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14202     as_echo_n='/usr/ucb/echo -n'
14203   else
14204     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14205     as_echo_n_body='eval
14206       arg=$1;
14207       case $arg in #(
14208       *"$as_nl"*)
14209         expr "X$arg" : "X\\(.*\\)$as_nl";
14210         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14211       esac;
14212       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14213     '
14214     export as_echo_n_body
14215     as_echo_n='sh -c $as_echo_n_body as_echo'
14216   fi
14217   export as_echo_body
14218   as_echo='sh -c $as_echo_body as_echo'
14219 fi
14220
14221 # The user is always right.
14222 if test "${PATH_SEPARATOR+set}" != set; then
14223   PATH_SEPARATOR=:
14224   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14225     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14226       PATH_SEPARATOR=';'
14227   }
14228 fi
14229
14230
14231 # IFS
14232 # We need space, tab and new line, in precisely that order.  Quoting is
14233 # there to prevent editors from complaining about space-tab.
14234 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
14235 # splitting by setting IFS to empty value.)
14236 IFS=" ""        $as_nl"
14237
14238 # Find who we are.  Look in the path if we contain no directory separator.
14239 case $0 in #((
14240   *[\\/]* ) as_myself=$0 ;;
14241   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14242 for as_dir in $PATH
14243 do
14244   IFS=$as_save_IFS
14245   test -z "$as_dir" && as_dir=.
14246     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14247   done
14248 IFS=$as_save_IFS
14249
14250      ;;
14251 esac
14252 # We did not find ourselves, most probably we were run as `sh COMMAND'
14253 # in which case we are not to be found in the path.
14254 if test "x$as_myself" = x; then
14255   as_myself=$0
14256 fi
14257 if test ! -f "$as_myself"; then
14258   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14259   exit 1
14260 fi
14261
14262 # Unset variables that we do not need and which cause bugs (e.g. in
14263 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
14264 # suppresses any "Segmentation fault" message there.  '((' could
14265 # trigger a bug in pdksh 5.2.14.
14266 for as_var in BASH_ENV ENV MAIL MAILPATH
14267 do eval test x\${$as_var+set} = xset \
14268   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14269 done
14270 PS1='$ '
14271 PS2='> '
14272 PS4='+ '
14273
14274 # NLS nuisances.
14275 LC_ALL=C
14276 export LC_ALL
14277 LANGUAGE=C
14278 export LANGUAGE
14279
14280 # CDPATH.
14281 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
14282
14283
14284 # as_fn_error ERROR [LINENO LOG_FD]
14285 # ---------------------------------
14286 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
14287 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
14288 # script with status $?, using 1 if that was 0.
14289 as_fn_error ()
14290 {
14291   as_status=$?; test $as_status -eq 0 && as_status=1
14292   if test "$3"; then
14293     as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
14294     $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
14295   fi
14296   $as_echo "$as_me: error: $1" >&2
14297   as_fn_exit $as_status
14298 } # as_fn_error
14299
14300
14301 # as_fn_set_status STATUS
14302 # -----------------------
14303 # Set $? to STATUS, without forking.
14304 as_fn_set_status ()
14305 {
14306   return $1
14307 } # as_fn_set_status
14308
14309 # as_fn_exit STATUS
14310 # -----------------
14311 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
14312 as_fn_exit ()
14313 {
14314   set +e
14315   as_fn_set_status $1
14316   exit $1
14317 } # as_fn_exit
14318
14319 # as_fn_unset VAR
14320 # ---------------
14321 # Portably unset VAR.
14322 as_fn_unset ()
14323 {
14324   { eval $1=; unset $1;}
14325 }
14326 as_unset=as_fn_unset
14327 # as_fn_append VAR VALUE
14328 # ----------------------
14329 # Append the text in VALUE to the end of the definition contained in VAR. Take
14330 # advantage of any shell optimizations that allow amortized linear growth over
14331 # repeated appends, instead of the typical quadratic growth present in naive
14332 # implementations.
14333 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
14334   eval 'as_fn_append ()
14335   {
14336     eval $1+=\$2
14337   }'
14338 else
14339   as_fn_append ()
14340   {
14341     eval $1=\$$1\$2
14342   }
14343 fi # as_fn_append
14344
14345 # as_fn_arith ARG...
14346 # ------------------
14347 # Perform arithmetic evaluation on the ARGs, and store the result in the
14348 # global $as_val. Take advantage of shells that can avoid forks. The arguments
14349 # must be portable across $(()) and expr.
14350 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
14351   eval 'as_fn_arith ()
14352   {
14353     as_val=$(( $* ))
14354   }'
14355 else
14356   as_fn_arith ()
14357   {
14358     as_val=`expr "$@" || test $? -eq 1`
14359   }
14360 fi # as_fn_arith
14361
14362
14363 if expr a : '\(a\)' >/dev/null 2>&1 &&
14364    test "X`expr 00001 : '.*\(...\)'`" = X001; then
14365   as_expr=expr
14366 else
14367   as_expr=false
14368 fi
14369
14370 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
14371   as_basename=basename
14372 else
14373   as_basename=false
14374 fi
14375
14376 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
14377   as_dirname=dirname
14378 else
14379   as_dirname=false
14380 fi
14381
14382 as_me=`$as_basename -- "$0" ||
14383 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
14384          X"$0" : 'X\(//\)$' \| \
14385          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
14386 $as_echo X/"$0" |
14387     sed '/^.*\/\([^/][^/]*\)\/*$/{
14388             s//\1/
14389             q
14390           }
14391           /^X\/\(\/\/\)$/{
14392             s//\1/
14393             q
14394           }
14395           /^X\/\(\/\).*/{
14396             s//\1/
14397             q
14398           }
14399           s/.*/./; q'`
14400
14401 # Avoid depending upon Character Ranges.
14402 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
14403 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14404 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14405 as_cr_digits='0123456789'
14406 as_cr_alnum=$as_cr_Letters$as_cr_digits
14407
14408 ECHO_C= ECHO_N= ECHO_T=
14409 case `echo -n x` in #(((((
14410 -n*)
14411   case `echo 'xy\c'` in
14412   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
14413   xy)  ECHO_C='\c';;
14414   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
14415        ECHO_T=' ';;
14416   esac;;
14417 *)
14418   ECHO_N='-n';;
14419 esac
14420
14421 rm -f conf$$ conf$$.exe conf$$.file
14422 if test -d conf$$.dir; then
14423   rm -f conf$$.dir/conf$$.file
14424 else
14425   rm -f conf$$.dir
14426   mkdir conf$$.dir 2>/dev/null
14427 fi
14428 if (echo >conf$$.file) 2>/dev/null; then
14429   if ln -s conf$$.file conf$$ 2>/dev/null; then
14430     as_ln_s='ln -s'
14431     # ... but there are two gotchas:
14432     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
14433     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
14434     # In both cases, we have to default to `cp -p'.
14435     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
14436       as_ln_s='cp -p'
14437   elif ln conf$$.file conf$$ 2>/dev/null; then
14438     as_ln_s=ln
14439   else
14440     as_ln_s='cp -p'
14441   fi
14442 else
14443   as_ln_s='cp -p'
14444 fi
14445 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
14446 rmdir conf$$.dir 2>/dev/null
14447
14448
14449 # as_fn_mkdir_p
14450 # -------------
14451 # Create "$as_dir" as a directory, including parents if necessary.
14452 as_fn_mkdir_p ()
14453 {
14454
14455   case $as_dir in #(
14456   -*) as_dir=./$as_dir;;
14457   esac
14458   test -d "$as_dir" || eval $as_mkdir_p || {
14459     as_dirs=
14460     while :; do
14461       case $as_dir in #(
14462       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
14463       *) as_qdir=$as_dir;;
14464       esac
14465       as_dirs="'$as_qdir' $as_dirs"
14466       as_dir=`$as_dirname -- "$as_dir" ||
14467 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
14468          X"$as_dir" : 'X\(//\)[^/]' \| \
14469          X"$as_dir" : 'X\(//\)$' \| \
14470          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
14471 $as_echo X"$as_dir" |
14472     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
14473             s//\1/
14474             q
14475           }
14476           /^X\(\/\/\)[^/].*/{
14477             s//\1/
14478             q
14479           }
14480           /^X\(\/\/\)$/{
14481             s//\1/
14482             q
14483           }
14484           /^X\(\/\).*/{
14485             s//\1/
14486             q
14487           }
14488           s/.*/./; q'`
14489       test -d "$as_dir" && break
14490     done
14491     test -z "$as_dirs" || eval "mkdir $as_dirs"
14492   } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
14493
14494
14495 } # as_fn_mkdir_p
14496 if mkdir -p . 2>/dev/null; then
14497   as_mkdir_p='mkdir -p "$as_dir"'
14498 else
14499   test -d ./-p && rmdir ./-p
14500   as_mkdir_p=false
14501 fi
14502
14503 if test -x / >/dev/null 2>&1; then
14504   as_test_x='test -x'
14505 else
14506   if ls -dL / >/dev/null 2>&1; then
14507     as_ls_L_option=L
14508   else
14509     as_ls_L_option=
14510   fi
14511   as_test_x='
14512     eval sh -c '\''
14513       if test -d "$1"; then
14514         test -d "$1/.";
14515       else
14516         case $1 in #(
14517         -*)set "./$1";;
14518         esac;
14519         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
14520         ???[sx]*):;;*)false;;esac;fi
14521     '\'' sh
14522   '
14523 fi
14524 as_executable_p=$as_test_x
14525
14526 # Sed expression to map a string onto a valid CPP name.
14527 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
14528
14529 # Sed expression to map a string onto a valid variable name.
14530 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
14531
14532
14533 exec 6>&1
14534 ## ----------------------------------- ##
14535 ## Main body of $CONFIG_STATUS script. ##
14536 ## ----------------------------------- ##
14537 _ASEOF
14538 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
14539
14540 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14541 # Save the log message, to keep $0 and so on meaningful, and to
14542 # report actual input values of CONFIG_FILES etc. instead of their
14543 # values after options handling.
14544 ac_log="
14545 This file was extended by $as_me, which was
14546 generated by GNU Autoconf 2.64.  Invocation command line was
14547
14548   CONFIG_FILES    = $CONFIG_FILES
14549   CONFIG_HEADERS  = $CONFIG_HEADERS
14550   CONFIG_LINKS    = $CONFIG_LINKS
14551   CONFIG_COMMANDS = $CONFIG_COMMANDS
14552   $ $0 $@
14553
14554 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14555 "
14556
14557 _ACEOF
14558
14559 case $ac_config_files in *"
14560 "*) set x $ac_config_files; shift; ac_config_files=$*;;
14561 esac
14562
14563 case $ac_config_headers in *"
14564 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
14565 esac
14566
14567
14568 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14569 # Files that config.status was made for.
14570 config_files="$ac_config_files"
14571 config_headers="$ac_config_headers"
14572 config_links="$ac_config_links"
14573 config_commands="$ac_config_commands"
14574
14575 _ACEOF
14576
14577 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14578 ac_cs_usage="\
14579 \`$as_me' instantiates files and other configuration actions
14580 from templates according to the current configuration.  Unless the files
14581 and actions are specified as TAGs, all are instantiated by default.
14582
14583 Usage: $0 [OPTION]... [TAG]...
14584
14585   -h, --help       print this help, then exit
14586   -V, --version    print version number and configuration settings, then exit
14587   -q, --quiet, --silent
14588                    do not print progress messages
14589   -d, --debug      don't remove temporary files
14590       --recheck    update $as_me by reconfiguring in the same conditions
14591       --file=FILE[:TEMPLATE]
14592                    instantiate the configuration file FILE
14593       --header=FILE[:TEMPLATE]
14594                    instantiate the configuration header FILE
14595
14596 Configuration files:
14597 $config_files
14598
14599 Configuration headers:
14600 $config_headers
14601
14602 Configuration links:
14603 $config_links
14604
14605 Configuration commands:
14606 $config_commands
14607
14608 Report bugs to the package provider."
14609
14610 _ACEOF
14611 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14612 ac_cs_version="\\
14613 config.status
14614 configured by $0, generated by GNU Autoconf 2.64,
14615   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
14616
14617 Copyright (C) 2009 Free Software Foundation, Inc.
14618 This config.status script is free software; the Free Software Foundation
14619 gives unlimited permission to copy, distribute and modify it."
14620
14621 ac_pwd='$ac_pwd'
14622 srcdir='$srcdir'
14623 INSTALL='$INSTALL'
14624 AWK='$AWK'
14625 test -n "\$AWK" || AWK=awk
14626 _ACEOF
14627
14628 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14629 # The default lists apply if the user does not specify any file.
14630 ac_need_defaults=:
14631 while test $# != 0
14632 do
14633   case $1 in
14634   --*=*)
14635     ac_option=`expr "X$1" : 'X\([^=]*\)='`
14636     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
14637     ac_shift=:
14638     ;;
14639   *)
14640     ac_option=$1
14641     ac_optarg=$2
14642     ac_shift=shift
14643     ;;
14644   esac
14645
14646   case $ac_option in
14647   # Handling of the options.
14648   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14649     ac_cs_recheck=: ;;
14650   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
14651     $as_echo "$ac_cs_version"; exit ;;
14652   --debug | --debu | --deb | --de | --d | -d )
14653     debug=: ;;
14654   --file | --fil | --fi | --f )
14655     $ac_shift
14656     case $ac_optarg in
14657     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
14658     esac
14659     as_fn_append CONFIG_FILES " '$ac_optarg'"
14660     ac_need_defaults=false;;
14661   --header | --heade | --head | --hea )
14662     $ac_shift
14663     case $ac_optarg in
14664     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
14665     esac
14666     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
14667     ac_need_defaults=false;;
14668   --he | --h)
14669     # Conflict between --help and --header
14670     as_fn_error "ambiguous option: \`$1'
14671 Try \`$0 --help' for more information.";;
14672   --help | --hel | -h )
14673     $as_echo "$ac_cs_usage"; exit ;;
14674   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
14675   | -silent | --silent | --silen | --sile | --sil | --si | --s)
14676     ac_cs_silent=: ;;
14677
14678   # This is an error.
14679   -*) as_fn_error "unrecognized option: \`$1'
14680 Try \`$0 --help' for more information." ;;
14681
14682   *) as_fn_append ac_config_targets " $1"
14683      ac_need_defaults=false ;;
14684
14685   esac
14686   shift
14687 done
14688
14689 ac_configure_extra_args=
14690
14691 if $ac_cs_silent; then
14692   exec 6>/dev/null
14693   ac_configure_extra_args="$ac_configure_extra_args --silent"
14694 fi
14695
14696 _ACEOF
14697 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14698 if \$ac_cs_recheck; then
14699   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
14700   shift
14701   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
14702   CONFIG_SHELL='$SHELL'
14703   export CONFIG_SHELL
14704   exec "\$@"
14705 fi
14706
14707 _ACEOF
14708 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14709 exec 5>>config.log
14710 {
14711   echo
14712   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
14713 ## Running $as_me. ##
14714 _ASBOX
14715   $as_echo "$ac_log"
14716 } >&5
14717
14718 _ACEOF
14719 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14720 #
14721 # INIT-COMMANDS
14722 #
14723 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
14724
14725 _ACEOF
14726
14727 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14728
14729 # Handling of arguments.
14730 for ac_config_target in $ac_config_targets
14731 do
14732   case $ac_config_target in
14733     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
14734     "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
14735     "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
14736     "$ac_config_links_1") CONFIG_LINKS="$CONFIG_LINKS $ac_config_links_1" ;;
14737     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
14738     "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
14739     "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
14740     "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
14741     "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
14742
14743   *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
14744   esac
14745 done
14746
14747
14748 # If the user did not use the arguments to specify the items to instantiate,
14749 # then the envvar interface is used.  Set only those that are not.
14750 # We use the long form for the default assignment because of an extremely
14751 # bizarre bug on SunOS 4.1.3.
14752 if $ac_need_defaults; then
14753   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
14754   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
14755   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
14756   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
14757 fi
14758
14759 # Have a temporary directory for convenience.  Make it in the build tree
14760 # simply because there is no reason against having it here, and in addition,
14761 # creating and moving files from /tmp can sometimes cause problems.
14762 # Hook for its removal unless debugging.
14763 # Note that there is a small window in which the directory will not be cleaned:
14764 # after its creation but before its name has been assigned to `$tmp'.
14765 $debug ||
14766 {
14767   tmp=
14768   trap 'exit_status=$?
14769   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
14770 ' 0
14771   trap 'as_fn_exit 1' 1 2 13 15
14772 }
14773 # Create a (secure) tmp directory for tmp files.
14774
14775 {
14776   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
14777   test -n "$tmp" && test -d "$tmp"
14778 }  ||
14779 {
14780   tmp=./conf$$-$RANDOM
14781   (umask 077 && mkdir "$tmp")
14782 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
14783
14784 # Set up the scripts for CONFIG_FILES section.
14785 # No need to generate them if there are no CONFIG_FILES.
14786 # This happens for instance with `./config.status config.h'.
14787 if test -n "$CONFIG_FILES"; then
14788
14789 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
14790   ac_cs_awk_getline=:
14791   ac_cs_awk_pipe_init=
14792   ac_cs_awk_read_file='
14793       while ((getline aline < (F[key])) > 0)
14794         print(aline)
14795       close(F[key])'
14796   ac_cs_awk_pipe_fini=
14797 else
14798   ac_cs_awk_getline=false
14799   ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
14800   ac_cs_awk_read_file='
14801       print "|#_!!_#|"
14802       print "cat " F[key] " &&"
14803       '$ac_cs_awk_pipe_init
14804   # The final `:' finishes the AND list.
14805   ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
14806 fi
14807 ac_cr=`echo X | tr X '\015'`
14808 # On cygwin, bash can eat \r inside `` if the user requested igncr.
14809 # But we know of no other shell where ac_cr would be empty at this
14810 # point, so we can use a bashism as a fallback.
14811 if test "x$ac_cr" = x; then
14812   eval ac_cr=\$\'\\r\'
14813 fi
14814 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
14815 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
14816   ac_cs_awk_cr='\r'
14817 else
14818   ac_cs_awk_cr=$ac_cr
14819 fi
14820
14821 echo 'BEGIN {' >"$tmp/subs1.awk" &&
14822 _ACEOF
14823
14824 # Create commands to substitute file output variables.
14825 {
14826   echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
14827   echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
14828   echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
14829   echo "_ACAWK" &&
14830   echo "_ACEOF"
14831 } >conf$$files.sh &&
14832 . ./conf$$files.sh ||
14833   as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
14834 rm -f conf$$files.sh
14835
14836 {
14837   echo "cat >conf$$subs.awk <<_ACEOF" &&
14838   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
14839   echo "_ACEOF"
14840 } >conf$$subs.sh ||
14841   as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
14842 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
14843 ac_delim='%!_!# '
14844 for ac_last_try in false false false false false :; do
14845   . ./conf$$subs.sh ||
14846     as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
14847
14848   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
14849   if test $ac_delim_n = $ac_delim_num; then
14850     break
14851   elif $ac_last_try; then
14852     as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
14853   else
14854     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
14855   fi
14856 done
14857 rm -f conf$$subs.sh
14858
14859 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14860 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
14861 _ACEOF
14862 sed -n '
14863 h
14864 s/^/S["/; s/!.*/"]=/
14865 p
14866 g
14867 s/^[^!]*!//
14868 :repl
14869 t repl
14870 s/'"$ac_delim"'$//
14871 t delim
14872 :nl
14873 h
14874 s/\(.\{148\}\).*/\1/
14875 t more1
14876 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
14877 p
14878 n
14879 b repl
14880 :more1
14881 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
14882 p
14883 g
14884 s/.\{148\}//
14885 t nl
14886 :delim
14887 h
14888 s/\(.\{148\}\).*/\1/
14889 t more2
14890 s/["\\]/\\&/g; s/^/"/; s/$/"/
14891 p
14892 b
14893 :more2
14894 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
14895 p
14896 g
14897 s/.\{148\}//
14898 t delim
14899 ' <conf$$subs.awk | sed '
14900 /^[^""]/{
14901   N
14902   s/\n//
14903 }
14904 ' >>$CONFIG_STATUS || ac_write_fail=1
14905 rm -f conf$$subs.awk
14906 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14907 _ACAWK
14908 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
14909   for (key in S) S_is_set[key] = 1
14910   FS = "\a"
14911   \$ac_cs_awk_pipe_init
14912 }
14913 {
14914   line = $ 0
14915   nfields = split(line, field, "@")
14916   substed = 0
14917   len = length(field[1])
14918   for (i = 2; i < nfields; i++) {
14919     key = field[i]
14920     keylen = length(key)
14921     if (S_is_set[key]) {
14922       value = S[key]
14923       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
14924       len += length(value) + length(field[++i])
14925       substed = 1
14926     } else
14927       len += 1 + keylen
14928   }
14929   if (nfields == 3 && !substed) {
14930     key = field[2]
14931     if (F[key] != "" && line ~ /^[       ]*@.*@[         ]*$/) {
14932       \$ac_cs_awk_read_file
14933       next
14934     }
14935   }
14936   print line
14937 }
14938 \$ac_cs_awk_pipe_fini
14939 _ACAWK
14940 _ACEOF
14941 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14942 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
14943   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
14944 else
14945   cat
14946 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
14947   || as_fn_error "could not setup config files machinery" "$LINENO" 5
14948 _ACEOF
14949
14950 # VPATH may cause trouble with some makes, so we remove $(srcdir),
14951 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
14952 # trailing colons and then remove the whole line if VPATH becomes empty
14953 # (actually we leave an empty line to preserve line numbers).
14954 if test "x$srcdir" = x.; then
14955   ac_vpsub='/^[  ]*VPATH[        ]*=/{
14956 s/:*\$(srcdir):*/:/
14957 s/:*\${srcdir}:*/:/
14958 s/:*@srcdir@:*/:/
14959 s/^\([^=]*=[     ]*\):*/\1/
14960 s/:*$//
14961 s/^[^=]*=[       ]*$//
14962 }'
14963 fi
14964
14965 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14966 fi # test -n "$CONFIG_FILES"
14967
14968 # Set up the scripts for CONFIG_HEADERS section.
14969 # No need to generate them if there are no CONFIG_HEADERS.
14970 # This happens for instance with `./config.status Makefile'.
14971 if test -n "$CONFIG_HEADERS"; then
14972 cat >"$tmp/defines.awk" <<\_ACAWK ||
14973 BEGIN {
14974 _ACEOF
14975
14976 # Transform confdefs.h into an awk script `defines.awk', embedded as
14977 # here-document in config.status, that substitutes the proper values into
14978 # config.h.in to produce config.h.
14979
14980 # Create a delimiter string that does not exist in confdefs.h, to ease
14981 # handling of long lines.
14982 ac_delim='%!_!# '
14983 for ac_last_try in false false :; do
14984   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
14985   if test -z "$ac_t"; then
14986     break
14987   elif $ac_last_try; then
14988     as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
14989   else
14990     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
14991   fi
14992 done
14993
14994 # For the awk script, D is an array of macro values keyed by name,
14995 # likewise P contains macro parameters if any.  Preserve backslash
14996 # newline sequences.
14997
14998 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
14999 sed -n '
15000 s/.\{148\}/&'"$ac_delim"'/g
15001 t rset
15002 :rset
15003 s/^[     ]*#[    ]*define[       ][      ]*/ /
15004 t def
15005 d
15006 :def
15007 s/\\$//
15008 t bsnl
15009 s/["\\]/\\&/g
15010 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
15011 D["\1"]=" \3"/p
15012 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
15013 d
15014 :bsnl
15015 s/["\\]/\\&/g
15016 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
15017 D["\1"]=" \3\\\\\\n"\\/p
15018 t cont
15019 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
15020 t cont
15021 d
15022 :cont
15023 n
15024 s/.\{148\}/&'"$ac_delim"'/g
15025 t clear
15026 :clear
15027 s/\\$//
15028 t bsnlc
15029 s/["\\]/\\&/g; s/^/"/; s/$/"/p
15030 d
15031 :bsnlc
15032 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
15033 b cont
15034 ' <confdefs.h | sed '
15035 s/'"$ac_delim"'/"\\\
15036 "/g' >>$CONFIG_STATUS || ac_write_fail=1
15037
15038 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15039   for (key in D) D_is_set[key] = 1
15040   FS = "\a"
15041 }
15042 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
15043   line = \$ 0
15044   split(line, arg, " ")
15045   if (arg[1] == "#") {
15046     defundef = arg[2]
15047     mac1 = arg[3]
15048   } else {
15049     defundef = substr(arg[1], 2)
15050     mac1 = arg[2]
15051   }
15052   split(mac1, mac2, "(") #)
15053   macro = mac2[1]
15054   prefix = substr(line, 1, index(line, defundef) - 1)
15055   if (D_is_set[macro]) {
15056     # Preserve the white space surrounding the "#".
15057     print prefix "define", macro P[macro] D[macro]
15058     next
15059   } else {
15060     # Replace #undef with comments.  This is necessary, for example,
15061     # in the case of _POSIX_SOURCE, which is predefined and required
15062     # on some systems where configure will not decide to define it.
15063     if (defundef == "undef") {
15064       print "/*", prefix defundef, macro, "*/"
15065       next
15066     }
15067   }
15068 }
15069 { print }
15070 _ACAWK
15071 _ACEOF
15072 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15073   as_fn_error "could not setup config headers machinery" "$LINENO" 5
15074 fi # test -n "$CONFIG_HEADERS"
15075
15076
15077 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
15078 shift
15079 for ac_tag
15080 do
15081   case $ac_tag in
15082   :[FHLC]) ac_mode=$ac_tag; continue;;
15083   esac
15084   case $ac_mode$ac_tag in
15085   :[FHL]*:*);;
15086   :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
15087   :[FH]-) ac_tag=-:-;;
15088   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
15089   esac
15090   ac_save_IFS=$IFS
15091   IFS=:
15092   set x $ac_tag
15093   IFS=$ac_save_IFS
15094   shift
15095   ac_file=$1
15096   shift
15097
15098   case $ac_mode in
15099   :L) ac_source=$1;;
15100   :[FH])
15101     ac_file_inputs=
15102     for ac_f
15103     do
15104       case $ac_f in
15105       -) ac_f="$tmp/stdin";;
15106       *) # Look for the file first in the build tree, then in the source tree
15107          # (if the path is not absolute).  The absolute path cannot be DOS-style,
15108          # because $ac_f cannot contain `:'.
15109          test -f "$ac_f" ||
15110            case $ac_f in
15111            [\\/$]*) false;;
15112            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
15113            esac ||
15114            as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
15115       esac
15116       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
15117       as_fn_append ac_file_inputs " '$ac_f'"
15118     done
15119
15120     # Let's still pretend it is `configure' which instantiates (i.e., don't
15121     # use $as_me), people would be surprised to read:
15122     #    /* config.h.  Generated by config.status.  */
15123     configure_input='Generated from '`
15124           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
15125         `' by configure.'
15126     if test x"$ac_file" != x-; then
15127       configure_input="$ac_file.  $configure_input"
15128       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
15129 $as_echo "$as_me: creating $ac_file" >&6;}
15130     fi
15131     # Neutralize special characters interpreted by sed in replacement strings.
15132     case $configure_input in #(
15133     *\&* | *\|* | *\\* )
15134        ac_sed_conf_input=`$as_echo "$configure_input" |
15135        sed 's/[\\\\&|]/\\\\&/g'`;; #(
15136     *) ac_sed_conf_input=$configure_input;;
15137     esac
15138
15139     case $ac_tag in
15140     *:-:* | *:-) cat >"$tmp/stdin" \
15141       || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
15142     esac
15143     ;;
15144   esac
15145
15146   ac_dir=`$as_dirname -- "$ac_file" ||
15147 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15148          X"$ac_file" : 'X\(//\)[^/]' \| \
15149          X"$ac_file" : 'X\(//\)$' \| \
15150          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
15151 $as_echo X"$ac_file" |
15152     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15153             s//\1/
15154             q
15155           }
15156           /^X\(\/\/\)[^/].*/{
15157             s//\1/
15158             q
15159           }
15160           /^X\(\/\/\)$/{
15161             s//\1/
15162             q
15163           }
15164           /^X\(\/\).*/{
15165             s//\1/
15166             q
15167           }
15168           s/.*/./; q'`
15169   as_dir="$ac_dir"; as_fn_mkdir_p
15170   ac_builddir=.
15171
15172 case "$ac_dir" in
15173 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15174 *)
15175   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15176   # A ".." for each directory in $ac_dir_suffix.
15177   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15178   case $ac_top_builddir_sub in
15179   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15180   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15181   esac ;;
15182 esac
15183 ac_abs_top_builddir=$ac_pwd
15184 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15185 # for backward compatibility:
15186 ac_top_builddir=$ac_top_build_prefix
15187
15188 case $srcdir in
15189   .)  # We are building in place.
15190     ac_srcdir=.
15191     ac_top_srcdir=$ac_top_builddir_sub
15192     ac_abs_top_srcdir=$ac_pwd ;;
15193   [\\/]* | ?:[\\/]* )  # Absolute name.
15194     ac_srcdir=$srcdir$ac_dir_suffix;
15195     ac_top_srcdir=$srcdir
15196     ac_abs_top_srcdir=$srcdir ;;
15197   *) # Relative name.
15198     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15199     ac_top_srcdir=$ac_top_build_prefix$srcdir
15200     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15201 esac
15202 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15203
15204
15205   case $ac_mode in
15206   :F)
15207   #
15208   # CONFIG_FILE
15209   #
15210
15211   case $INSTALL in
15212   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15213   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
15214   esac
15215 _ACEOF
15216
15217 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15218 # If the template does not know about datarootdir, expand it.
15219 # FIXME: This hack should be removed a few years after 2.60.
15220 ac_datarootdir_hack=; ac_datarootdir_seen=
15221 ac_sed_dataroot='
15222 /datarootdir/ {
15223   p
15224   q
15225 }
15226 /@datadir@/p
15227 /@docdir@/p
15228 /@infodir@/p
15229 /@localedir@/p
15230 /@mandir@/p'
15231 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
15232 *datarootdir*) ac_datarootdir_seen=yes;;
15233 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
15234   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
15235 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
15236 _ACEOF
15237 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15238   ac_datarootdir_hack='
15239   s&@datadir@&$datadir&g
15240   s&@docdir@&$docdir&g
15241   s&@infodir@&$infodir&g
15242   s&@localedir@&$localedir&g
15243   s&@mandir@&$mandir&g
15244   s&\\\${datarootdir}&$datarootdir&g' ;;
15245 esac
15246 _ACEOF
15247
15248 # Neutralize VPATH when `$srcdir' = `.'.
15249 # Shell code in configure.ac might set extrasub.
15250 # FIXME: do we really want to maintain this feature?
15251 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15252 ac_sed_extra="$ac_vpsub
15253 $extrasub
15254 _ACEOF
15255 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15256 :t
15257 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15258 s|@configure_input@|$ac_sed_conf_input|;t t
15259 s&@top_builddir@&$ac_top_builddir_sub&;t t
15260 s&@top_build_prefix@&$ac_top_build_prefix&;t t
15261 s&@srcdir@&$ac_srcdir&;t t
15262 s&@abs_srcdir@&$ac_abs_srcdir&;t t
15263 s&@top_srcdir@&$ac_top_srcdir&;t t
15264 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
15265 s&@builddir@&$ac_builddir&;t t
15266 s&@abs_builddir@&$ac_abs_builddir&;t t
15267 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
15268 s&@INSTALL@&$ac_INSTALL&;t t
15269 $ac_datarootdir_hack
15270 "
15271 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
15272 if $ac_cs_awk_getline; then
15273   $AWK -f "$tmp/subs.awk"
15274 else
15275   $AWK -f "$tmp/subs.awk" | $SHELL
15276 fi >$tmp/out \
15277   || as_fn_error "could not create $ac_file" "$LINENO" 5
15278
15279 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
15280   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
15281   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
15282   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15283 which seems to be undefined.  Please make sure it is defined." >&5
15284 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15285 which seems to be undefined.  Please make sure it is defined." >&2;}
15286
15287   rm -f "$tmp/stdin"
15288   case $ac_file in
15289   -) cat "$tmp/out" && rm -f "$tmp/out";;
15290   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
15291   esac \
15292   || as_fn_error "could not create $ac_file" "$LINENO" 5
15293  ;;
15294   :H)
15295   #
15296   # CONFIG_HEADER
15297   #
15298   if test x"$ac_file" != x-; then
15299     {
15300       $as_echo "/* $configure_input  */" \
15301       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
15302     } >"$tmp/config.h" \
15303       || as_fn_error "could not create $ac_file" "$LINENO" 5
15304     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
15305       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
15306 $as_echo "$as_me: $ac_file is unchanged" >&6;}
15307     else
15308       rm -f "$ac_file"
15309       mv "$tmp/config.h" "$ac_file" \
15310         || as_fn_error "could not create $ac_file" "$LINENO" 5
15311     fi
15312   else
15313     $as_echo "/* $configure_input  */" \
15314       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
15315       || as_fn_error "could not create -" "$LINENO" 5
15316   fi
15317  ;;
15318   :L)
15319   #
15320   # CONFIG_LINK
15321   #
15322
15323   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
15324     :
15325   else
15326     # Prefer the file from the source tree if names are identical.
15327     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
15328       ac_source=$srcdir/$ac_source
15329     fi
15330
15331     { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
15332 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
15333
15334     if test ! -r "$ac_source"; then
15335       as_fn_error "$ac_source: file not found" "$LINENO" 5
15336     fi
15337     rm -f "$ac_file"
15338
15339     # Try a relative symlink, then a hard link, then a copy.
15340     case $srcdir in
15341     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
15342         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
15343     esac
15344     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
15345       ln "$ac_source" "$ac_file" 2>/dev/null ||
15346       cp -p "$ac_source" "$ac_file" ||
15347       as_fn_error "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
15348   fi
15349  ;;
15350   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
15351 $as_echo "$as_me: executing $ac_file commands" >&6;}
15352  ;;
15353   esac
15354
15355
15356   case $ac_file$ac_mode in
15357     "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
15358     "default":C)
15359 case x$CONFIG_HEADERS in
15360 xconfig.h:config.in)
15361 echo > stamp-h ;;
15362 esac
15363  ;;
15364
15365   esac
15366 done # for ac_tag
15367
15368
15369 as_fn_exit 0
15370 _ACEOF
15371 ac_clean_files=$ac_clean_files_save
15372
15373 test $ac_write_fail = 0 ||
15374   as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
15375
15376
15377 # configure is writing to config.log, and then calls config.status.
15378 # config.status does its own redirection, appending to config.log.
15379 # Unfortunately, on DOS this fails, as config.log is still kept open
15380 # by configure, so config.status won't be able to write to it; its
15381 # output is simply discarded.  So we exec the FD to /dev/null,
15382 # effectively closing config.log, so it can be properly (re)opened and
15383 # appended to by config.status.  When coming back to configure, we
15384 # need to make the FD available again.
15385 if test "$no_create" != yes; then
15386   ac_cs_success=:
15387   ac_config_status_args=
15388   test "$silent" = yes &&
15389     ac_config_status_args="$ac_config_status_args --quiet"
15390   exec 5>/dev/null
15391   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
15392   exec 5>>config.log
15393   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15394   # would make configure fail if this is the last instruction.
15395   $ac_cs_success || as_fn_exit $?
15396 fi
15397
15398 #
15399 # CONFIG_SUBDIRS section.
15400 #
15401 if test "$no_recursion" != yes; then
15402
15403   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
15404   # so they do not pile up.
15405   ac_sub_configure_args=
15406   ac_prev=
15407   eval "set x $ac_configure_args"
15408   shift
15409   for ac_arg
15410   do
15411     if test -n "$ac_prev"; then
15412       ac_prev=
15413       continue
15414     fi
15415     case $ac_arg in
15416     -cache-file | --cache-file | --cache-fil | --cache-fi \
15417     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
15418       ac_prev=cache_file ;;
15419     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
15420     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
15421     | --c=*)
15422       ;;
15423     --config-cache | -C)
15424       ;;
15425     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
15426       ac_prev=srcdir ;;
15427     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
15428       ;;
15429     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
15430       ac_prev=prefix ;;
15431     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
15432       ;;
15433     --disable-option-checking)
15434       ;;
15435     *)
15436       case $ac_arg in
15437       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
15438       esac
15439       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
15440     esac
15441   done
15442
15443   # Always prepend --prefix to ensure using the same prefix
15444   # in subdir configurations.
15445   ac_arg="--prefix=$prefix"
15446   case $ac_arg in
15447   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
15448   esac
15449   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
15450
15451   # Pass --silent
15452   if test "$silent" = yes; then
15453     ac_sub_configure_args="--silent $ac_sub_configure_args"
15454   fi
15455
15456   # Always prepend --disable-option-checking to silence warnings, since
15457   # different subdirs can have different --enable and --with options.
15458   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
15459
15460   ac_popdir=`pwd`
15461   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
15462
15463     # Do not complain, so a configure script can configure whichever
15464     # parts of a large source tree are present.
15465     test -d "$srcdir/$ac_dir" || continue
15466
15467     ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
15468     $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
15469     $as_echo "$ac_msg" >&6
15470     as_dir="$ac_dir"; as_fn_mkdir_p
15471     ac_builddir=.
15472
15473 case "$ac_dir" in
15474 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15475 *)
15476   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15477   # A ".." for each directory in $ac_dir_suffix.
15478   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15479   case $ac_top_builddir_sub in
15480   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15481   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15482   esac ;;
15483 esac
15484 ac_abs_top_builddir=$ac_pwd
15485 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15486 # for backward compatibility:
15487 ac_top_builddir=$ac_top_build_prefix
15488
15489 case $srcdir in
15490   .)  # We are building in place.
15491     ac_srcdir=.
15492     ac_top_srcdir=$ac_top_builddir_sub
15493     ac_abs_top_srcdir=$ac_pwd ;;
15494   [\\/]* | ?:[\\/]* )  # Absolute name.
15495     ac_srcdir=$srcdir$ac_dir_suffix;
15496     ac_top_srcdir=$srcdir
15497     ac_abs_top_srcdir=$srcdir ;;
15498   *) # Relative name.
15499     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15500     ac_top_srcdir=$ac_top_build_prefix$srcdir
15501     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15502 esac
15503 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15504
15505
15506     cd "$ac_dir"
15507
15508     # Check for guested configure; otherwise get Cygnus style configure.
15509     if test -f "$ac_srcdir/configure.gnu"; then
15510       ac_sub_configure=$ac_srcdir/configure.gnu
15511     elif test -f "$ac_srcdir/configure"; then
15512       ac_sub_configure=$ac_srcdir/configure
15513     elif test -f "$ac_srcdir/configure.in"; then
15514       # This should be Cygnus configure.
15515       ac_sub_configure=$ac_aux_dir/configure
15516     else
15517       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
15518 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
15519       ac_sub_configure=
15520     fi
15521
15522     # The recursion is here.
15523     if test -n "$ac_sub_configure"; then
15524       # Make the cache file name correct relative to the subdirectory.
15525       case $cache_file in
15526       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
15527       *) # Relative name.
15528         ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
15529       esac
15530
15531       { $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
15532 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
15533       # The eval makes quoting arguments work.
15534       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
15535            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
15536         as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
15537     fi
15538
15539     cd "$ac_popdir"
15540   done
15541 fi
15542 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
15543   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
15544 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
15545 fi
15546
15547
15548 exit 0