Move gnulib to top level
[external/binutils.git] / gdb / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69.
4 #
5 #
6 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7 #
8 #
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 ## -------------------- ##
12 ## M4sh Initialization. ##
13 ## -------------------- ##
14
15 # Be more Bourne compatible
16 DUALCASE=1; export DUALCASE # for MKS sh
17 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18   emulate sh
19   NULLCMD=:
20   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21   # is contrary to our usage.  Disable this feature.
22   alias -g '${1+"$@"}'='"$@"'
23   setopt NO_GLOB_SUBST
24 else
25   case `(set -o) 2>/dev/null` in #(
26   *posix*) :
27     set -o posix ;; #(
28   *) :
29      ;;
30 esac
31 fi
32
33
34 as_nl='
35 '
36 export as_nl
37 # Printing a long string crashes Solaris 7 /usr/bin/printf.
38 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41 # Prefer a ksh shell builtin over an external printf program on Solaris,
42 # but without wasting forks for bash or zsh.
43 if test -z "$BASH_VERSION$ZSH_VERSION" \
44     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45   as_echo='print -r --'
46   as_echo_n='print -rn --'
47 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48   as_echo='printf %s\n'
49   as_echo_n='printf %s'
50 else
51   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53     as_echo_n='/usr/ucb/echo -n'
54   else
55     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56     as_echo_n_body='eval
57       arg=$1;
58       case $arg in #(
59       *"$as_nl"*)
60         expr "X$arg" : "X\\(.*\\)$as_nl";
61         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62       esac;
63       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64     '
65     export as_echo_n_body
66     as_echo_n='sh -c $as_echo_n_body as_echo'
67   fi
68   export as_echo_body
69   as_echo='sh -c $as_echo_body as_echo'
70 fi
71
72 # The user is always right.
73 if test "${PATH_SEPARATOR+set}" != set; then
74   PATH_SEPARATOR=:
75   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77       PATH_SEPARATOR=';'
78   }
79 fi
80
81
82 # IFS
83 # We need space, tab and new line, in precisely that order.  Quoting is
84 # there to prevent editors from complaining about space-tab.
85 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
86 # splitting by setting IFS to empty value.)
87 IFS=" ""        $as_nl"
88
89 # Find who we are.  Look in the path if we contain no directory separator.
90 as_myself=
91 case $0 in #((
92   *[\\/]* ) as_myself=$0 ;;
93   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94 for as_dir in $PATH
95 do
96   IFS=$as_save_IFS
97   test -z "$as_dir" && as_dir=.
98     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99   done
100 IFS=$as_save_IFS
101
102      ;;
103 esac
104 # We did not find ourselves, most probably we were run as `sh COMMAND'
105 # in which case we are not to be found in the path.
106 if test "x$as_myself" = x; then
107   as_myself=$0
108 fi
109 if test ! -f "$as_myself"; then
110   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111   exit 1
112 fi
113
114 # Unset variables that we do not need and which cause bugs (e.g. in
115 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
116 # suppresses any "Segmentation fault" message there.  '((' could
117 # trigger a bug in pdksh 5.2.14.
118 for as_var in BASH_ENV ENV MAIL MAILPATH
119 do eval test x\${$as_var+set} = xset \
120   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121 done
122 PS1='$ '
123 PS2='> '
124 PS4='+ '
125
126 # NLS nuisances.
127 LC_ALL=C
128 export LC_ALL
129 LANGUAGE=C
130 export LANGUAGE
131
132 # CDPATH.
133 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
135 # Use a proper internal environment variable to ensure we don't fall
136   # into an infinite loop, continuously re-executing ourselves.
137   if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138     _as_can_reexec=no; export _as_can_reexec;
139     # We cannot yet assume a decent shell, so we have to provide a
140 # neutralization value for shells without unset; and this also
141 # works around shells that cannot unset nonexistent variables.
142 # Preserve -v and -x to the replacement shell.
143 BASH_ENV=/dev/null
144 ENV=/dev/null
145 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146 case $- in # ((((
147   *v*x* | *x*v* ) as_opts=-vx ;;
148   *v* ) as_opts=-v ;;
149   *x* ) as_opts=-x ;;
150   * ) as_opts= ;;
151 esac
152 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153 # Admittedly, this is quite paranoid, since all the known shells bail
154 # out after a failed `exec'.
155 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156 as_fn_exit 255
157   fi
158   # We don't want this to propagate to other subprocesses.
159           { _as_can_reexec=; unset _as_can_reexec;}
160 if test "x$CONFIG_SHELL" = x; then
161   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162   emulate sh
163   NULLCMD=:
164   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165   # is contrary to our usage.  Disable this feature.
166   alias -g '\${1+\"\$@\"}'='\"\$@\"'
167   setopt NO_GLOB_SUBST
168 else
169   case \`(set -o) 2>/dev/null\` in #(
170   *posix*) :
171     set -o posix ;; #(
172   *) :
173      ;;
174 esac
175 fi
176 "
177   as_required="as_fn_return () { (exit \$1); }
178 as_fn_success () { as_fn_return 0; }
179 as_fn_failure () { as_fn_return 1; }
180 as_fn_ret_success () { return 0; }
181 as_fn_ret_failure () { return 1; }
182
183 exitcode=0
184 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190 else
191   exitcode=1; echo positional parameters were not saved.
192 fi
193 test x\$exitcode = x0 || exit 1
194 test -x / || exit 1"
195   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199 test \$(( 1 + 1 )) = 2 || exit 1"
200   if (eval "$as_required") 2>/dev/null; then :
201   as_have_required=yes
202 else
203   as_have_required=no
204 fi
205   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
207 else
208   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209 as_found=false
210 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
211 do
212   IFS=$as_save_IFS
213   test -z "$as_dir" && as_dir=.
214   as_found=:
215   case $as_dir in #(
216          /*)
217            for as_base in sh bash ksh sh5; do
218              # Try only shells that exist, to save several forks.
219              as_shell=$as_dir/$as_base
220              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222   CONFIG_SHELL=$as_shell as_have_required=yes
223                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224   break 2
225 fi
226 fi
227            done;;
228        esac
229   as_found=false
230 done
231 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233   CONFIG_SHELL=$SHELL as_have_required=yes
234 fi; }
235 IFS=$as_save_IFS
236
237
238       if test "x$CONFIG_SHELL" != x; then :
239   export CONFIG_SHELL
240              # We cannot yet assume a decent shell, so we have to provide a
241 # neutralization value for shells without unset; and this also
242 # works around shells that cannot unset nonexistent variables.
243 # Preserve -v and -x to the replacement shell.
244 BASH_ENV=/dev/null
245 ENV=/dev/null
246 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247 case $- in # ((((
248   *v*x* | *x*v* ) as_opts=-vx ;;
249   *v* ) as_opts=-v ;;
250   *x* ) as_opts=-x ;;
251   * ) as_opts= ;;
252 esac
253 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254 # Admittedly, this is quite paranoid, since all the known shells bail
255 # out after a failed `exec'.
256 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257 exit 255
258 fi
259
260     if test x$as_have_required = xno; then :
261   $as_echo "$0: This script requires a shell more modern than all"
262   $as_echo "$0: the shells that I found on your system."
263   if test x${ZSH_VERSION+set} = xset ; then
264     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
266   else
267     $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268 $0: including any error possibly output before this
269 $0: message. Then install a modern shell, or manually run
270 $0: the script under such a shell if you do have one."
271   fi
272   exit 1
273 fi
274 fi
275 fi
276 SHELL=${CONFIG_SHELL-/bin/sh}
277 export SHELL
278 # Unset more variables known to interfere with behavior of common tools.
279 CLICOLOR_FORCE= GREP_OPTIONS=
280 unset CLICOLOR_FORCE GREP_OPTIONS
281
282 ## --------------------- ##
283 ## M4sh Shell Functions. ##
284 ## --------------------- ##
285 # as_fn_unset VAR
286 # ---------------
287 # Portably unset VAR.
288 as_fn_unset ()
289 {
290   { eval $1=; unset $1;}
291 }
292 as_unset=as_fn_unset
293
294 # as_fn_set_status STATUS
295 # -----------------------
296 # Set $? to STATUS, without forking.
297 as_fn_set_status ()
298 {
299   return $1
300 } # as_fn_set_status
301
302 # as_fn_exit STATUS
303 # -----------------
304 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305 as_fn_exit ()
306 {
307   set +e
308   as_fn_set_status $1
309   exit $1
310 } # as_fn_exit
311
312 # as_fn_mkdir_p
313 # -------------
314 # Create "$as_dir" as a directory, including parents if necessary.
315 as_fn_mkdir_p ()
316 {
317
318   case $as_dir in #(
319   -*) as_dir=./$as_dir;;
320   esac
321   test -d "$as_dir" || eval $as_mkdir_p || {
322     as_dirs=
323     while :; do
324       case $as_dir in #(
325       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326       *) as_qdir=$as_dir;;
327       esac
328       as_dirs="'$as_qdir' $as_dirs"
329       as_dir=`$as_dirname -- "$as_dir" ||
330 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331          X"$as_dir" : 'X\(//\)[^/]' \| \
332          X"$as_dir" : 'X\(//\)$' \| \
333          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334 $as_echo X"$as_dir" |
335     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336             s//\1/
337             q
338           }
339           /^X\(\/\/\)[^/].*/{
340             s//\1/
341             q
342           }
343           /^X\(\/\/\)$/{
344             s//\1/
345             q
346           }
347           /^X\(\/\).*/{
348             s//\1/
349             q
350           }
351           s/.*/./; q'`
352       test -d "$as_dir" && break
353     done
354     test -z "$as_dirs" || eval "mkdir $as_dirs"
355   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
356
357
358 } # as_fn_mkdir_p
359
360 # as_fn_executable_p FILE
361 # -----------------------
362 # Test if FILE is an executable regular file.
363 as_fn_executable_p ()
364 {
365   test -f "$1" && test -x "$1"
366 } # as_fn_executable_p
367 # as_fn_append VAR VALUE
368 # ----------------------
369 # Append the text in VALUE to the end of the definition contained in VAR. Take
370 # advantage of any shell optimizations that allow amortized linear growth over
371 # repeated appends, instead of the typical quadratic growth present in naive
372 # implementations.
373 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374   eval 'as_fn_append ()
375   {
376     eval $1+=\$2
377   }'
378 else
379   as_fn_append ()
380   {
381     eval $1=\$$1\$2
382   }
383 fi # as_fn_append
384
385 # as_fn_arith ARG...
386 # ------------------
387 # Perform arithmetic evaluation on the ARGs, and store the result in the
388 # global $as_val. Take advantage of shells that can avoid forks. The arguments
389 # must be portable across $(()) and expr.
390 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391   eval 'as_fn_arith ()
392   {
393     as_val=$(( $* ))
394   }'
395 else
396   as_fn_arith ()
397   {
398     as_val=`expr "$@" || test $? -eq 1`
399   }
400 fi # as_fn_arith
401
402
403 # as_fn_error STATUS ERROR [LINENO LOG_FD]
404 # ----------------------------------------
405 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
407 # script with STATUS, using 1 if that was 0.
408 as_fn_error ()
409 {
410   as_status=$1; test $as_status -eq 0 && as_status=1
411   if test "$4"; then
412     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
414   fi
415   $as_echo "$as_me: error: $2" >&2
416   as_fn_exit $as_status
417 } # as_fn_error
418
419 if expr a : '\(a\)' >/dev/null 2>&1 &&
420    test "X`expr 00001 : '.*\(...\)'`" = X001; then
421   as_expr=expr
422 else
423   as_expr=false
424 fi
425
426 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
427   as_basename=basename
428 else
429   as_basename=false
430 fi
431
432 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433   as_dirname=dirname
434 else
435   as_dirname=false
436 fi
437
438 as_me=`$as_basename -- "$0" ||
439 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440          X"$0" : 'X\(//\)$' \| \
441          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442 $as_echo X/"$0" |
443     sed '/^.*\/\([^/][^/]*\)\/*$/{
444             s//\1/
445             q
446           }
447           /^X\/\(\/\/\)$/{
448             s//\1/
449             q
450           }
451           /^X\/\(\/\).*/{
452             s//\1/
453             q
454           }
455           s/.*/./; q'`
456
457 # Avoid depending upon Character Ranges.
458 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461 as_cr_digits='0123456789'
462 as_cr_alnum=$as_cr_Letters$as_cr_digits
463
464
465   as_lineno_1=$LINENO as_lineno_1a=$LINENO
466   as_lineno_2=$LINENO as_lineno_2a=$LINENO
467   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
470   sed -n '
471     p
472     /[$]LINENO/=
473   ' <$as_myself |
474     sed '
475       s/[$]LINENO.*/&-/
476       t lineno
477       b
478       :lineno
479       N
480       :loop
481       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
482       t loop
483       s/-\n.*//
484     ' >$as_me.lineno &&
485   chmod +x "$as_me.lineno" ||
486     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
487
488   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489   # already done that, so ensure we don't try to do so again and fall
490   # in an infinite loop.  This has already happened in practice.
491   _as_can_reexec=no; export _as_can_reexec
492   # Don't try to exec as it changes $[0], causing all sort of problems
493   # (the dirname of $[0] is not the place where we might find the
494   # original and so on.  Autoconf is especially sensitive to this).
495   . "./$as_me.lineno"
496   # Exit status is that of the last command.
497   exit
498 }
499
500 ECHO_C= ECHO_N= ECHO_T=
501 case `echo -n x` in #(((((
502 -n*)
503   case `echo 'xy\c'` in
504   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
505   xy)  ECHO_C='\c';;
506   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
507        ECHO_T=' ';;
508   esac;;
509 *)
510   ECHO_N='-n';;
511 esac
512
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515   rm -f conf$$.dir/conf$$.file
516 else
517   rm -f conf$$.dir
518   mkdir conf$$.dir 2>/dev/null
519 fi
520 if (echo >conf$$.file) 2>/dev/null; then
521   if ln -s conf$$.file conf$$ 2>/dev/null; then
522     as_ln_s='ln -s'
523     # ... but there are two gotchas:
524     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526     # In both cases, we have to default to `cp -pR'.
527     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528       as_ln_s='cp -pR'
529   elif ln conf$$.file conf$$ 2>/dev/null; then
530     as_ln_s=ln
531   else
532     as_ln_s='cp -pR'
533   fi
534 else
535   as_ln_s='cp -pR'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
540 if mkdir -p . 2>/dev/null; then
541   as_mkdir_p='mkdir -p "$as_dir"'
542 else
543   test -d ./-p && rmdir ./-p
544   as_mkdir_p=false
545 fi
546
547 as_test_x='test -x'
548 as_executable_p=as_fn_executable_p
549
550 # Sed expression to map a string onto a valid CPP name.
551 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
552
553 # Sed expression to map a string onto a valid variable name.
554 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
555
556
557 test -n "$DJDIR" || exec 7<&0 </dev/null
558 exec 6>&1
559
560 # Name of the host.
561 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
562 # so uname gets run too.
563 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
564
565 #
566 # Initializations.
567 #
568 ac_default_prefix=/usr/local
569 ac_clean_files=
570 ac_config_libobj_dir=.
571 LIBOBJS=
572 cross_compiling=no
573 subdirs=
574 MFLAGS=
575 MAKEFLAGS=
576
577 # Identity of this package.
578 PACKAGE_NAME=
579 PACKAGE_TARNAME=
580 PACKAGE_VERSION=
581 PACKAGE_STRING=
582 PACKAGE_BUGREPORT=
583 PACKAGE_URL=
584
585 ac_unique_file="main.c"
586 # Factoring default headers for most tests.
587 ac_includes_default="\
588 #include <stdio.h>
589 #ifdef HAVE_SYS_TYPES_H
590 # include <sys/types.h>
591 #endif
592 #ifdef HAVE_SYS_STAT_H
593 # include <sys/stat.h>
594 #endif
595 #ifdef STDC_HEADERS
596 # include <stdlib.h>
597 # include <stddef.h>
598 #else
599 # ifdef HAVE_STDLIB_H
600 #  include <stdlib.h>
601 # endif
602 #endif
603 #ifdef HAVE_STRING_H
604 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
605 #  include <memory.h>
606 # endif
607 # include <string.h>
608 #endif
609 #ifdef HAVE_STRINGS_H
610 # include <strings.h>
611 #endif
612 #ifdef HAVE_INTTYPES_H
613 # include <inttypes.h>
614 #endif
615 #ifdef HAVE_STDINT_H
616 # include <stdint.h>
617 #endif
618 #ifdef HAVE_UNISTD_H
619 # include <unistd.h>
620 #endif"
621
622 enable_option_checking=no
623 ac_header_list=
624 ac_subst_vars='LTLIBOBJS
625 LIBOBJS
626 GCORE_TRANSFORM_NAME
627 GDB_TRANSFORM_NAME
628 XSLTPROC
629 GDB_NM_FILE
630 LTLIBBABELTRACE
631 LIBBABELTRACE
632 HAVE_LIBBABELTRACE
633 HAVE_NATIVE_GCORE_HOST
634 NAT_GENERATED_FILES
635 XM_CLIBS
636 MH_CFLAGS
637 LOADLIBES
638 NAT_CDEPS
639 NATDEPFILES
640 NAT_FILE
641 target_subdir
642 CONFIG_UNINSTALL
643 CONFIG_INSTALL
644 CONFIG_CLEAN
645 CONFIG_ALL
646 CONFIG_SRCS
647 CONFIG_DEPS
648 CONFIG_OBS
649 PROFILE_CFLAGS
650 ENABLE_CFLAGS
651 SIM_OBS
652 SIM
653 XMKMF
654 GDBTK_SRC_DIR
655 GDBTK_CFLAGS
656 GDBTKLIBS
657 X_LIBS
658 X_LDFLAGS
659 X_CFLAGS
660 TK_XINCLUDES
661 TK_DEPS
662 TK_LIBRARY
663 TK_INCLUDE
664 TK_STUB_LIB_SPEC
665 TK_STUB_LIB_FLAG
666 TK_STUB_LIB_FILE
667 TK_LIB_SPEC
668 TK_LIB_FLAG
669 TK_LIB_FILE
670 TK_SRC_DIR
671 TK_BIN_DIR
672 TK_VERSION
673 TCL_DEPS
674 TCL_LIBRARY
675 TCL_INCLUDE
676 TCL_STUB_LIB_SPEC
677 TCL_STUB_LIB_FLAG
678 TCL_STUB_LIB_FILE
679 TCL_LIB_SPEC
680 TCL_LIB_FLAG
681 TCL_LIB_FILE
682 TCL_SRC_DIR
683 TCL_BIN_DIR
684 TCL_PATCH_LEVEL
685 TCL_VERSION
686 WIN32LDAPP
687 GUI_CFLAGS_X
688 LIBGUI
689 LTLIBLZMA
690 LIBLZMA
691 HAVE_LIBLZMA
692 WIN32LIBS
693 SER_HARDWIRE
694 WERROR_CFLAGS
695 WARN_CFLAGS
696 SYSTEM_GDBINIT
697 TARGET_SYSTEM_ROOT
698 CONFIG_LDFLAGS
699 RDYNAMIC
700 ALLOCA
701 LTLIBIPT
702 LIBIPT
703 HAVE_LIBIPT
704 SRCHIGH_CFLAGS
705 SRCHIGH_LIBS
706 HAVE_GUILE_FALSE
707 HAVE_GUILE_TRUE
708 GUILE_LIBS
709 GUILE_CPPFLAGS
710 GUILD_TARGET_FLAG
711 GUILD
712 pkg_config_prog_path
713 HAVE_PYTHON_FALSE
714 HAVE_PYTHON_TRUE
715 PYTHON_LIBS
716 PYTHON_CPPFLAGS
717 PYTHON_CFLAGS
718 python_prog_path
719 LTLIBMPFR
720 LIBMPFR
721 HAVE_LIBMPFR
722 LTLIBEXPAT
723 LIBEXPAT
724 HAVE_LIBEXPAT
725 JIT_READER_DIR
726 TARGET_PTR
727 READLINE_TEXI_INCFLAG
728 READLINE_CFLAGS
729 READLINE_DEPS
730 READLINE
731 LTLIBICONV
732 LIBICONV
733 zlibinc
734 zlibdir
735 MIG
736 WINDRES
737 DLLTOOL
738 AR
739 YFLAGS
740 YACC
741 RANLIB
742 LN_S
743 INSTALL_DATA
744 INSTALL_SCRIPT
745 INSTALL_PROGRAM
746 AWK
747 REPORT_BUGS_TEXI
748 REPORT_BUGS_TO
749 PKGVERSION
750 CODESIGN_CERT
751 HAVE_NATIVE_GCORE_TARGET
752 TARGET_OBS
753 subdirs
754 GDB_DATADIR
755 DEBUGDIR
756 MAKEINFO_EXTRA_FLAGS
757 MAKEINFOFLAGS
758 MAKEINFO
759 PACKAGE
760 CATOBJEXT
761 GENCAT
762 INSTOBJEXT
763 DATADIRNAME
764 CATALOGS
765 POSUB
766 GMSGFMT
767 XGETTEXT
768 INCINTL
769 LIBINTL_DEP
770 LIBINTL
771 USE_NLS
772 CCDEPMODE
773 DEPDIR
774 am__leading_dot
775 CXX_DIALECT
776 HAVE_CXX11
777 INSTALL_STRIP_PROGRAM
778 STRIP
779 install_sh
780 target_os
781 target_vendor
782 target_cpu
783 target
784 host_os
785 host_vendor
786 host_cpu
787 host
788 build_os
789 build_vendor
790 build_cpu
791 build
792 EGREP
793 GREP
794 CPP
795 ac_ct_CXX
796 CXXFLAGS
797 CXX
798 OBJEXT
799 EXEEXT
800 ac_ct_CC
801 CPPFLAGS
802 LDFLAGS
803 CFLAGS
804 CC
805 MAINT
806 MAINTAINER_MODE_FALSE
807 MAINTAINER_MODE_TRUE
808 target_alias
809 host_alias
810 build_alias
811 LIBS
812 ECHO_T
813 ECHO_N
814 ECHO_C
815 DEFS
816 mandir
817 localedir
818 libdir
819 psdir
820 pdfdir
821 dvidir
822 htmldir
823 infodir
824 docdir
825 oldincludedir
826 includedir
827 localstatedir
828 sharedstatedir
829 sysconfdir
830 datadir
831 datarootdir
832 libexecdir
833 sbindir
834 bindir
835 program_transform_name
836 prefix
837 exec_prefix
838 PACKAGE_URL
839 PACKAGE_BUGREPORT
840 PACKAGE_STRING
841 PACKAGE_VERSION
842 PACKAGE_TARNAME
843 PACKAGE_NAME
844 PATH_SEPARATOR
845 SHELL'
846 ac_subst_files='nat_makefile_frag'
847 ac_user_opts='
848 enable_option_checking
849 enable_maintainer_mode
850 enable_plugins
851 enable_largefile
852 with_separate_debug_dir
853 with_gdb_datadir
854 with_relocated_sources
855 with_auto_load_dir
856 with_auto_load_safe_path
857 enable_targets
858 enable_64_bit_bfd
859 enable_gdbmi
860 enable_tui
861 enable_gdbtk
862 with_libunwind_ia64
863 with_curses
864 enable_profiling
865 enable_codesign
866 with_pkgversion
867 with_bugurl
868 with_system_zlib
869 with_gnu_ld
870 enable_rpath
871 with_libiconv_prefix
872 with_iconv_bin
873 with_system_readline
874 with_jit_reader_dir
875 with_expat
876 with_libexpat_prefix
877 with_mpfr
878 with_libmpfr_prefix
879 with_python
880 with_guile
881 enable_source_highlight
882 enable_libmcheck
883 with_intel_pt
884 with_libipt_prefix
885 with_included_regex
886 with_sysroot
887 with_system_gdbinit
888 enable_werror
889 enable_build_warnings
890 enable_gdb_build_warnings
891 enable_ubsan
892 with_lzma
893 with_liblzma_prefix
894 with_tcl
895 with_tk
896 with_x
897 enable_sim
898 enable_gdbserver
899 with_babeltrace
900 with_libbabeltrace_prefix
901 enable_unit_tests
902 '
903       ac_precious_vars='build_alias
904 host_alias
905 target_alias
906 CC
907 CFLAGS
908 LDFLAGS
909 LIBS
910 CPPFLAGS
911 CXX
912 CXXFLAGS
913 CCC
914 CPP
915 MAKEINFO
916 MAKEINFOFLAGS
917 YACC
918 YFLAGS
919 XMKMF'
920 ac_subdirs_all='testsuite
921 gdbtk
922 gdbserver'
923
924 # Initialize some variables set by options.
925 ac_init_help=
926 ac_init_version=false
927 ac_unrecognized_opts=
928 ac_unrecognized_sep=
929 # The variables have the same names as the options, with
930 # dashes changed to underlines.
931 cache_file=/dev/null
932 exec_prefix=NONE
933 no_create=
934 no_recursion=
935 prefix=NONE
936 program_prefix=NONE
937 program_suffix=NONE
938 program_transform_name=s,x,x,
939 silent=
940 site=
941 srcdir=
942 verbose=
943 x_includes=NONE
944 x_libraries=NONE
945
946 # Installation directory options.
947 # These are left unexpanded so users can "make install exec_prefix=/foo"
948 # and all the variables that are supposed to be based on exec_prefix
949 # by default will actually change.
950 # Use braces instead of parens because sh, perl, etc. also accept them.
951 # (The list follows the same order as the GNU Coding Standards.)
952 bindir='${exec_prefix}/bin'
953 sbindir='${exec_prefix}/sbin'
954 libexecdir='${exec_prefix}/libexec'
955 datarootdir='${prefix}/share'
956 datadir='${datarootdir}'
957 sysconfdir='${prefix}/etc'
958 sharedstatedir='${prefix}/com'
959 localstatedir='${prefix}/var'
960 includedir='${prefix}/include'
961 oldincludedir='/usr/include'
962 docdir='${datarootdir}/doc/${PACKAGE}'
963 infodir='${datarootdir}/info'
964 htmldir='${docdir}'
965 dvidir='${docdir}'
966 pdfdir='${docdir}'
967 psdir='${docdir}'
968 libdir='${exec_prefix}/lib'
969 localedir='${datarootdir}/locale'
970 mandir='${datarootdir}/man'
971
972 ac_prev=
973 ac_dashdash=
974 for ac_option
975 do
976   # If the previous option needs an argument, assign it.
977   if test -n "$ac_prev"; then
978     eval $ac_prev=\$ac_option
979     ac_prev=
980     continue
981   fi
982
983   case $ac_option in
984   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
985   *=)   ac_optarg= ;;
986   *)    ac_optarg=yes ;;
987   esac
988
989   # Accept the important Cygnus configure options, so we can diagnose typos.
990
991   case $ac_dashdash$ac_option in
992   --)
993     ac_dashdash=yes ;;
994
995   -bindir | --bindir | --bindi | --bind | --bin | --bi)
996     ac_prev=bindir ;;
997   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
998     bindir=$ac_optarg ;;
999
1000   -build | --build | --buil | --bui | --bu)
1001     ac_prev=build_alias ;;
1002   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1003     build_alias=$ac_optarg ;;
1004
1005   -cache-file | --cache-file | --cache-fil | --cache-fi \
1006   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1007     ac_prev=cache_file ;;
1008   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1009   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1010     cache_file=$ac_optarg ;;
1011
1012   --config-cache | -C)
1013     cache_file=config.cache ;;
1014
1015   -datadir | --datadir | --datadi | --datad)
1016     ac_prev=datadir ;;
1017   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1018     datadir=$ac_optarg ;;
1019
1020   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1021   | --dataroo | --dataro | --datar)
1022     ac_prev=datarootdir ;;
1023   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1024   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1025     datarootdir=$ac_optarg ;;
1026
1027   -disable-* | --disable-*)
1028     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1029     # Reject names that are not valid shell variable names.
1030     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1031       as_fn_error $? "invalid feature name: $ac_useropt"
1032     ac_useropt_orig=$ac_useropt
1033     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1034     case $ac_user_opts in
1035       *"
1036 "enable_$ac_useropt"
1037 "*) ;;
1038       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1039          ac_unrecognized_sep=', ';;
1040     esac
1041     eval enable_$ac_useropt=no ;;
1042
1043   -docdir | --docdir | --docdi | --doc | --do)
1044     ac_prev=docdir ;;
1045   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1046     docdir=$ac_optarg ;;
1047
1048   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1049     ac_prev=dvidir ;;
1050   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1051     dvidir=$ac_optarg ;;
1052
1053   -enable-* | --enable-*)
1054     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1055     # Reject names that are not valid shell variable names.
1056     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1057       as_fn_error $? "invalid feature name: $ac_useropt"
1058     ac_useropt_orig=$ac_useropt
1059     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1060     case $ac_user_opts in
1061       *"
1062 "enable_$ac_useropt"
1063 "*) ;;
1064       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1065          ac_unrecognized_sep=', ';;
1066     esac
1067     eval enable_$ac_useropt=\$ac_optarg ;;
1068
1069   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1070   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1071   | --exec | --exe | --ex)
1072     ac_prev=exec_prefix ;;
1073   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1074   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1075   | --exec=* | --exe=* | --ex=*)
1076     exec_prefix=$ac_optarg ;;
1077
1078   -gas | --gas | --ga | --g)
1079     # Obsolete; use --with-gas.
1080     with_gas=yes ;;
1081
1082   -help | --help | --hel | --he | -h)
1083     ac_init_help=long ;;
1084   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1085     ac_init_help=recursive ;;
1086   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1087     ac_init_help=short ;;
1088
1089   -host | --host | --hos | --ho)
1090     ac_prev=host_alias ;;
1091   -host=* | --host=* | --hos=* | --ho=*)
1092     host_alias=$ac_optarg ;;
1093
1094   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1095     ac_prev=htmldir ;;
1096   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1097   | --ht=*)
1098     htmldir=$ac_optarg ;;
1099
1100   -includedir | --includedir | --includedi | --included | --include \
1101   | --includ | --inclu | --incl | --inc)
1102     ac_prev=includedir ;;
1103   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1104   | --includ=* | --inclu=* | --incl=* | --inc=*)
1105     includedir=$ac_optarg ;;
1106
1107   -infodir | --infodir | --infodi | --infod | --info | --inf)
1108     ac_prev=infodir ;;
1109   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1110     infodir=$ac_optarg ;;
1111
1112   -libdir | --libdir | --libdi | --libd)
1113     ac_prev=libdir ;;
1114   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1115     libdir=$ac_optarg ;;
1116
1117   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1118   | --libexe | --libex | --libe)
1119     ac_prev=libexecdir ;;
1120   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1121   | --libexe=* | --libex=* | --libe=*)
1122     libexecdir=$ac_optarg ;;
1123
1124   -localedir | --localedir | --localedi | --localed | --locale)
1125     ac_prev=localedir ;;
1126   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1127     localedir=$ac_optarg ;;
1128
1129   -localstatedir | --localstatedir | --localstatedi | --localstated \
1130   | --localstate | --localstat | --localsta | --localst | --locals)
1131     ac_prev=localstatedir ;;
1132   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1133   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1134     localstatedir=$ac_optarg ;;
1135
1136   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1137     ac_prev=mandir ;;
1138   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1139     mandir=$ac_optarg ;;
1140
1141   -nfp | --nfp | --nf)
1142     # Obsolete; use --without-fp.
1143     with_fp=no ;;
1144
1145   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1146   | --no-cr | --no-c | -n)
1147     no_create=yes ;;
1148
1149   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1150   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1151     no_recursion=yes ;;
1152
1153   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1154   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1155   | --oldin | --oldi | --old | --ol | --o)
1156     ac_prev=oldincludedir ;;
1157   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1158   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1159   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1160     oldincludedir=$ac_optarg ;;
1161
1162   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1163     ac_prev=prefix ;;
1164   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1165     prefix=$ac_optarg ;;
1166
1167   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1168   | --program-pre | --program-pr | --program-p)
1169     ac_prev=program_prefix ;;
1170   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1171   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1172     program_prefix=$ac_optarg ;;
1173
1174   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1175   | --program-suf | --program-su | --program-s)
1176     ac_prev=program_suffix ;;
1177   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1178   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1179     program_suffix=$ac_optarg ;;
1180
1181   -program-transform-name | --program-transform-name \
1182   | --program-transform-nam | --program-transform-na \
1183   | --program-transform-n | --program-transform- \
1184   | --program-transform | --program-transfor \
1185   | --program-transfo | --program-transf \
1186   | --program-trans | --program-tran \
1187   | --progr-tra | --program-tr | --program-t)
1188     ac_prev=program_transform_name ;;
1189   -program-transform-name=* | --program-transform-name=* \
1190   | --program-transform-nam=* | --program-transform-na=* \
1191   | --program-transform-n=* | --program-transform-=* \
1192   | --program-transform=* | --program-transfor=* \
1193   | --program-transfo=* | --program-transf=* \
1194   | --program-trans=* | --program-tran=* \
1195   | --progr-tra=* | --program-tr=* | --program-t=*)
1196     program_transform_name=$ac_optarg ;;
1197
1198   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1199     ac_prev=pdfdir ;;
1200   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1201     pdfdir=$ac_optarg ;;
1202
1203   -psdir | --psdir | --psdi | --psd | --ps)
1204     ac_prev=psdir ;;
1205   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1206     psdir=$ac_optarg ;;
1207
1208   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1209   | -silent | --silent | --silen | --sile | --sil)
1210     silent=yes ;;
1211
1212   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1213     ac_prev=sbindir ;;
1214   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1215   | --sbi=* | --sb=*)
1216     sbindir=$ac_optarg ;;
1217
1218   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1219   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1220   | --sharedst | --shareds | --shared | --share | --shar \
1221   | --sha | --sh)
1222     ac_prev=sharedstatedir ;;
1223   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1224   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1225   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1226   | --sha=* | --sh=*)
1227     sharedstatedir=$ac_optarg ;;
1228
1229   -site | --site | --sit)
1230     ac_prev=site ;;
1231   -site=* | --site=* | --sit=*)
1232     site=$ac_optarg ;;
1233
1234   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1235     ac_prev=srcdir ;;
1236   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1237     srcdir=$ac_optarg ;;
1238
1239   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1240   | --syscon | --sysco | --sysc | --sys | --sy)
1241     ac_prev=sysconfdir ;;
1242   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1243   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1244     sysconfdir=$ac_optarg ;;
1245
1246   -target | --target | --targe | --targ | --tar | --ta | --t)
1247     ac_prev=target_alias ;;
1248   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1249     target_alias=$ac_optarg ;;
1250
1251   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1252     verbose=yes ;;
1253
1254   -version | --version | --versio | --versi | --vers | -V)
1255     ac_init_version=: ;;
1256
1257   -with-* | --with-*)
1258     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1259     # Reject names that are not valid shell variable names.
1260     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1261       as_fn_error $? "invalid package name: $ac_useropt"
1262     ac_useropt_orig=$ac_useropt
1263     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1264     case $ac_user_opts in
1265       *"
1266 "with_$ac_useropt"
1267 "*) ;;
1268       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1269          ac_unrecognized_sep=', ';;
1270     esac
1271     eval with_$ac_useropt=\$ac_optarg ;;
1272
1273   -without-* | --without-*)
1274     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1275     # Reject names that are not valid shell variable names.
1276     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1277       as_fn_error $? "invalid package name: $ac_useropt"
1278     ac_useropt_orig=$ac_useropt
1279     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1280     case $ac_user_opts in
1281       *"
1282 "with_$ac_useropt"
1283 "*) ;;
1284       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1285          ac_unrecognized_sep=', ';;
1286     esac
1287     eval with_$ac_useropt=no ;;
1288
1289   --x)
1290     # Obsolete; use --with-x.
1291     with_x=yes ;;
1292
1293   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1294   | --x-incl | --x-inc | --x-in | --x-i)
1295     ac_prev=x_includes ;;
1296   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1297   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1298     x_includes=$ac_optarg ;;
1299
1300   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1301   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1302     ac_prev=x_libraries ;;
1303   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1304   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1305     x_libraries=$ac_optarg ;;
1306
1307   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1308 Try \`$0 --help' for more information"
1309     ;;
1310
1311   *=*)
1312     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1313     # Reject names that are not valid shell variable names.
1314     case $ac_envvar in #(
1315       '' | [0-9]* | *[!_$as_cr_alnum]* )
1316       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1317     esac
1318     eval $ac_envvar=\$ac_optarg
1319     export $ac_envvar ;;
1320
1321   *)
1322     # FIXME: should be removed in autoconf 3.0.
1323     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1324     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1325       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1326     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1327     ;;
1328
1329   esac
1330 done
1331
1332 if test -n "$ac_prev"; then
1333   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1334   as_fn_error $? "missing argument to $ac_option"
1335 fi
1336
1337 if test -n "$ac_unrecognized_opts"; then
1338   case $enable_option_checking in
1339     no) ;;
1340     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1341     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1342   esac
1343 fi
1344
1345 # Check all directory arguments for consistency.
1346 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1347                 datadir sysconfdir sharedstatedir localstatedir includedir \
1348                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1349                 libdir localedir mandir
1350 do
1351   eval ac_val=\$$ac_var
1352   # Remove trailing slashes.
1353   case $ac_val in
1354     */ )
1355       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1356       eval $ac_var=\$ac_val;;
1357   esac
1358   # Be sure to have absolute directory names.
1359   case $ac_val in
1360     [\\/$]* | ?:[\\/]* )  continue;;
1361     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1362   esac
1363   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1364 done
1365
1366 # There might be people who depend on the old broken behavior: `$host'
1367 # used to hold the argument of --host etc.
1368 # FIXME: To remove some day.
1369 build=$build_alias
1370 host=$host_alias
1371 target=$target_alias
1372
1373 # FIXME: To remove some day.
1374 if test "x$host_alias" != x; then
1375   if test "x$build_alias" = x; then
1376     cross_compiling=maybe
1377   elif test "x$build_alias" != "x$host_alias"; then
1378     cross_compiling=yes
1379   fi
1380 fi
1381
1382 ac_tool_prefix=
1383 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1384
1385 test "$silent" = yes && exec 6>/dev/null
1386
1387
1388 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1389 ac_ls_di=`ls -di .` &&
1390 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1391   as_fn_error $? "working directory cannot be determined"
1392 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1393   as_fn_error $? "pwd does not report name of working directory"
1394
1395
1396 # Find the source files, if location was not specified.
1397 if test -z "$srcdir"; then
1398   ac_srcdir_defaulted=yes
1399   # Try the directory containing this script, then the parent directory.
1400   ac_confdir=`$as_dirname -- "$as_myself" ||
1401 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1402          X"$as_myself" : 'X\(//\)[^/]' \| \
1403          X"$as_myself" : 'X\(//\)$' \| \
1404          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1405 $as_echo X"$as_myself" |
1406     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1407             s//\1/
1408             q
1409           }
1410           /^X\(\/\/\)[^/].*/{
1411             s//\1/
1412             q
1413           }
1414           /^X\(\/\/\)$/{
1415             s//\1/
1416             q
1417           }
1418           /^X\(\/\).*/{
1419             s//\1/
1420             q
1421           }
1422           s/.*/./; q'`
1423   srcdir=$ac_confdir
1424   if test ! -r "$srcdir/$ac_unique_file"; then
1425     srcdir=..
1426   fi
1427 else
1428   ac_srcdir_defaulted=no
1429 fi
1430 if test ! -r "$srcdir/$ac_unique_file"; then
1431   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1432   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1433 fi
1434 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1435 ac_abs_confdir=`(
1436         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1437         pwd)`
1438 # When building in place, set srcdir=.
1439 if test "$ac_abs_confdir" = "$ac_pwd"; then
1440   srcdir=.
1441 fi
1442 # Remove unnecessary trailing slashes from srcdir.
1443 # Double slashes in file names in object file debugging info
1444 # mess up M-x gdb in Emacs.
1445 case $srcdir in
1446 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1447 esac
1448 for ac_var in $ac_precious_vars; do
1449   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1450   eval ac_env_${ac_var}_value=\$${ac_var}
1451   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1452   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1453 done
1454
1455 #
1456 # Report the --help message.
1457 #
1458 if test "$ac_init_help" = "long"; then
1459   # Omit some internal or obsolete options to make the list less imposing.
1460   # This message is too long to be a string in the A/UX 3.1 sh.
1461   cat <<_ACEOF
1462 \`configure' configures this package to adapt to many kinds of systems.
1463
1464 Usage: $0 [OPTION]... [VAR=VALUE]...
1465
1466 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1467 VAR=VALUE.  See below for descriptions of some of the useful variables.
1468
1469 Defaults for the options are specified in brackets.
1470
1471 Configuration:
1472   -h, --help              display this help and exit
1473       --help=short        display options specific to this package
1474       --help=recursive    display the short help of all the included packages
1475   -V, --version           display version information and exit
1476   -q, --quiet, --silent   do not print \`checking ...' messages
1477       --cache-file=FILE   cache test results in FILE [disabled]
1478   -C, --config-cache      alias for \`--cache-file=config.cache'
1479   -n, --no-create         do not create output files
1480       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1481
1482 Installation directories:
1483   --prefix=PREFIX         install architecture-independent files in PREFIX
1484                           [$ac_default_prefix]
1485   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1486                           [PREFIX]
1487
1488 By default, \`make install' will install all the files in
1489 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1490 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1491 for instance \`--prefix=\$HOME'.
1492
1493 For better control, use the options below.
1494
1495 Fine tuning of the installation directories:
1496   --bindir=DIR            user executables [EPREFIX/bin]
1497   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1498   --libexecdir=DIR        program executables [EPREFIX/libexec]
1499   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1500   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1501   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1502   --libdir=DIR            object code libraries [EPREFIX/lib]
1503   --includedir=DIR        C header files [PREFIX/include]
1504   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1505   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1506   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1507   --infodir=DIR           info documentation [DATAROOTDIR/info]
1508   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1509   --mandir=DIR            man documentation [DATAROOTDIR/man]
1510   --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
1511   --htmldir=DIR           html documentation [DOCDIR]
1512   --dvidir=DIR            dvi documentation [DOCDIR]
1513   --pdfdir=DIR            pdf documentation [DOCDIR]
1514   --psdir=DIR             ps documentation [DOCDIR]
1515 _ACEOF
1516
1517   cat <<\_ACEOF
1518
1519 Program names:
1520   --program-prefix=PREFIX            prepend PREFIX to installed program names
1521   --program-suffix=SUFFIX            append SUFFIX to installed program names
1522   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1523
1524 X features:
1525   --x-includes=DIR    X include files are in DIR
1526   --x-libraries=DIR   X library files are in DIR
1527
1528 System types:
1529   --build=BUILD     configure for building on BUILD [guessed]
1530   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1531   --target=TARGET   configure for building compilers for TARGET [HOST]
1532 _ACEOF
1533 fi
1534
1535 if test -n "$ac_init_help"; then
1536
1537   cat <<\_ACEOF
1538
1539 Optional Features:
1540   --disable-option-checking  ignore unrecognized --enable/--with options
1541   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1542   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1543   --enable-maintainer-mode
1544                           enable make rules and dependencies not useful (and
1545                           sometimes confusing) to the casual installer
1546   --enable-plugins        Enable support for plugins
1547   --disable-largefile     omit support for large files
1548   --enable-targets=TARGETS
1549                           alternative target configurations
1550   --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
1551   --disable-gdbmi         disable machine-interface (MI)
1552   --enable-tui            enable full-screen terminal user interface (TUI)
1553   --enable-gdbtk          enable gdbtk graphical user interface (GUI)
1554   --enable-profiling      enable profiling of GDB
1555   --enable-codesign=CERT  sign gdb with 'codesign -s CERT'
1556   --disable-rpath         do not hardcode runtime library paths
1557   --enable-source-highlight
1558                           enable source-highlight for source listings
1559   --enable-libmcheck      Try linking with -lmcheck if available
1560   --enable-werror         treat compile warnings as errors
1561   --enable-build-warnings enable build-time compiler warnings if gcc is used
1562   --enable-gdb-build-warnings
1563                           enable GDB specific build-time compiler warnings if
1564                           gcc is used
1565   --enable-ubsan          enable undefined behavior sanitizer (auto/yes/no)
1566   --enable-sim            link gdb with simulator
1567   --enable-gdbserver      automatically build gdbserver (yes/no/auto, default
1568                           is auto)
1569   --enable-unit-tests     Enable the inclusion of unit tests when compiling
1570                           GDB
1571
1572 Optional Packages:
1573   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1574   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1575   --with-separate-debug-dir=PATH
1576                           look for global separate debug info in this path
1577                           [LIBDIR/debug]
1578   --with-gdb-datadir=PATH look for global separate data files in this path
1579                           [DATADIR/gdb]
1580   --with-relocated-sources=PATH
1581                           automatically relocate this path for source files
1582   --with-auto-load-dir=PATH
1583                           directories from which to load auto-loaded scripts
1584                           [$debugdir:$datadir/auto-load]
1585   --with-auto-load-safe-path=PATH
1586                           directories safe to hold auto-loaded files
1587                           [--with-auto-load-dir]
1588   --without-auto-load-safe-path
1589                           do not restrict auto-loaded files locations
1590   --with-libunwind-ia64   use libunwind frame unwinding for ia64 targets
1591   --with-curses           use the curses library instead of the termcap
1592                           library
1593   --with-pkgversion=PKG   Use PKG in the version string in place of "GDB"
1594   --with-bugurl=URL       Direct users to URL to report a bug
1595   --with-system-zlib      use installed libz
1596   --with-gnu-ld           assume the C compiler uses GNU ld default=no
1597   --with-libiconv-prefix[=DIR]  search for libiconv in DIR/include and DIR/lib
1598   --without-libiconv-prefix     don't search for libiconv in includedir and libdir
1599   --with-iconv-bin=PATH   specify where to find the iconv program
1600   --with-system-readline  use installed readline library
1601   --with-jit-reader-dir=PATH
1602                           directory to load the JIT readers from
1603   --with-expat            include expat support (auto/yes/no)
1604   --with-libexpat-prefix[=DIR]  search for libexpat in DIR/include and DIR/lib
1605   --without-libexpat-prefix     don't search for libexpat in includedir and libdir
1606   --with-mpfr             include MPFR support (auto/yes/no)
1607   --with-libmpfr-prefix[=DIR]  search for libmpfr in DIR/include and DIR/lib
1608   --without-libmpfr-prefix     don't search for libmpfr in includedir and libdir
1609   --with-python[=PYTHON]  include python support
1610                           (auto/yes/no/<python-program>)
1611   --with-guile[=GUILE]    include guile support
1612                           (auto/yes/no/<guile-version>/<pkg-config-program>)
1613   --with-intel-pt         include Intel Processor Trace support (auto/yes/no)
1614   --with-libipt-prefix[=DIR]  search for libipt in DIR/include and DIR/lib
1615   --without-libipt-prefix     don't search for libipt in includedir and libdir
1616   --without-included-regex
1617                           don't use included regex; this is the default on
1618                           systems with version 2 of the GNU C library (use
1619                           with caution on other system)
1620   --with-sysroot[=DIR]    search for usr/lib et al within DIR
1621   --with-system-gdbinit=PATH
1622                           automatically load a system-wide gdbinit file
1623   --with-lzma             support lzma compression (auto/yes/no)
1624   --with-liblzma-prefix[=DIR]  search for liblzma in DIR/include and DIR/lib
1625   --without-liblzma-prefix     don't search for liblzma in includedir and libdir
1626   --with-tcl              directory containing tcl configuration (tclConfig.sh)
1627   --with-tk               directory containing tk configuration (tkConfig.sh)
1628   --with-x                use the X Window System
1629   --with-babeltrace       include babeltrace support (auto/yes/no)
1630   --with-libbabeltrace-prefix[=DIR]  search for libbabeltrace in DIR/include and DIR/lib
1631   --without-libbabeltrace-prefix     don't search for libbabeltrace in includedir and libdir
1632
1633 Some influential environment variables:
1634   CC          C compiler command
1635   CFLAGS      C compiler flags
1636   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1637               nonstandard directory <lib dir>
1638   LIBS        libraries to pass to the linker, e.g. -l<library>
1639   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1640               you have headers in a nonstandard directory <include dir>
1641   CXX         C++ compiler command
1642   CXXFLAGS    C++ compiler flags
1643   CPP         C preprocessor
1644   MAKEINFO    Parent configure detects if it is of sufficient version.
1645   MAKEINFOFLAGS
1646               Parameters for MAKEINFO.
1647   YACC        The `Yet Another Compiler Compiler' implementation to use.
1648               Defaults to the first program found out of: `bison -y', `byacc',
1649               `yacc'.
1650   YFLAGS      The list of arguments that will be passed by default to $YACC.
1651               This script will default YFLAGS to the empty string to avoid a
1652               default value of `-d' given by some make applications.
1653   XMKMF       Path to xmkmf, Makefile generator for X Window System
1654
1655 Use these variables to override the choices made by `configure' or to help
1656 it to find libraries and programs with nonstandard names/locations.
1657
1658 Report bugs to the package provider.
1659 _ACEOF
1660 ac_status=$?
1661 fi
1662
1663 if test "$ac_init_help" = "recursive"; then
1664   # If there are subdirs, report their specific --help.
1665   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1666     test -d "$ac_dir" ||
1667       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1668       continue
1669     ac_builddir=.
1670
1671 case "$ac_dir" in
1672 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1673 *)
1674   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1675   # A ".." for each directory in $ac_dir_suffix.
1676   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1677   case $ac_top_builddir_sub in
1678   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1679   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1680   esac ;;
1681 esac
1682 ac_abs_top_builddir=$ac_pwd
1683 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1684 # for backward compatibility:
1685 ac_top_builddir=$ac_top_build_prefix
1686
1687 case $srcdir in
1688   .)  # We are building in place.
1689     ac_srcdir=.
1690     ac_top_srcdir=$ac_top_builddir_sub
1691     ac_abs_top_srcdir=$ac_pwd ;;
1692   [\\/]* | ?:[\\/]* )  # Absolute name.
1693     ac_srcdir=$srcdir$ac_dir_suffix;
1694     ac_top_srcdir=$srcdir
1695     ac_abs_top_srcdir=$srcdir ;;
1696   *) # Relative name.
1697     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1698     ac_top_srcdir=$ac_top_build_prefix$srcdir
1699     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1700 esac
1701 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1702
1703     cd "$ac_dir" || { ac_status=$?; continue; }
1704     # Check for guested configure.
1705     if test -f "$ac_srcdir/configure.gnu"; then
1706       echo &&
1707       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1708     elif test -f "$ac_srcdir/configure"; then
1709       echo &&
1710       $SHELL "$ac_srcdir/configure" --help=recursive
1711     else
1712       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1713     fi || ac_status=$?
1714     cd "$ac_pwd" || { ac_status=$?; break; }
1715   done
1716 fi
1717
1718 test -n "$ac_init_help" && exit $ac_status
1719 if $ac_init_version; then
1720   cat <<\_ACEOF
1721 configure
1722 generated by GNU Autoconf 2.69
1723
1724 Copyright (C) 2012 Free Software Foundation, Inc.
1725 This configure script is free software; the Free Software Foundation
1726 gives unlimited permission to copy, distribute and modify it.
1727 _ACEOF
1728   exit
1729 fi
1730
1731 ## ------------------------ ##
1732 ## Autoconf initialization. ##
1733 ## ------------------------ ##
1734
1735 # ac_fn_c_try_compile LINENO
1736 # --------------------------
1737 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1738 ac_fn_c_try_compile ()
1739 {
1740   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1741   rm -f conftest.$ac_objext
1742   if { { ac_try="$ac_compile"
1743 case "(($ac_try" in
1744   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1745   *) ac_try_echo=$ac_try;;
1746 esac
1747 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1748 $as_echo "$ac_try_echo"; } >&5
1749   (eval "$ac_compile") 2>conftest.err
1750   ac_status=$?
1751   if test -s conftest.err; then
1752     grep -v '^ *+' conftest.err >conftest.er1
1753     cat conftest.er1 >&5
1754     mv -f conftest.er1 conftest.err
1755   fi
1756   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1757   test $ac_status = 0; } && {
1758          test -z "$ac_c_werror_flag" ||
1759          test ! -s conftest.err
1760        } && test -s conftest.$ac_objext; then :
1761   ac_retval=0
1762 else
1763   $as_echo "$as_me: failed program was:" >&5
1764 sed 's/^/| /' conftest.$ac_ext >&5
1765
1766         ac_retval=1
1767 fi
1768   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1769   as_fn_set_status $ac_retval
1770
1771 } # ac_fn_c_try_compile
1772
1773 # ac_fn_cxx_try_compile LINENO
1774 # ----------------------------
1775 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1776 ac_fn_cxx_try_compile ()
1777 {
1778   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1779   rm -f conftest.$ac_objext
1780   if { { ac_try="$ac_compile"
1781 case "(($ac_try" in
1782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1783   *) ac_try_echo=$ac_try;;
1784 esac
1785 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1786 $as_echo "$ac_try_echo"; } >&5
1787   (eval "$ac_compile") 2>conftest.err
1788   ac_status=$?
1789   if test -s conftest.err; then
1790     grep -v '^ *+' conftest.err >conftest.er1
1791     cat conftest.er1 >&5
1792     mv -f conftest.er1 conftest.err
1793   fi
1794   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1795   test $ac_status = 0; } && {
1796          test -z "$ac_cxx_werror_flag" ||
1797          test ! -s conftest.err
1798        } && test -s conftest.$ac_objext; then :
1799   ac_retval=0
1800 else
1801   $as_echo "$as_me: failed program was:" >&5
1802 sed 's/^/| /' conftest.$ac_ext >&5
1803
1804         ac_retval=1
1805 fi
1806   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1807   as_fn_set_status $ac_retval
1808
1809 } # ac_fn_cxx_try_compile
1810
1811 # ac_fn_c_try_cpp LINENO
1812 # ----------------------
1813 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1814 ac_fn_c_try_cpp ()
1815 {
1816   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1817   if { { ac_try="$ac_cpp conftest.$ac_ext"
1818 case "(($ac_try" in
1819   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1820   *) ac_try_echo=$ac_try;;
1821 esac
1822 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1823 $as_echo "$ac_try_echo"; } >&5
1824   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1825   ac_status=$?
1826   if test -s conftest.err; then
1827     grep -v '^ *+' conftest.err >conftest.er1
1828     cat conftest.er1 >&5
1829     mv -f conftest.er1 conftest.err
1830   fi
1831   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1832   test $ac_status = 0; } > conftest.i && {
1833          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1834          test ! -s conftest.err
1835        }; then :
1836   ac_retval=0
1837 else
1838   $as_echo "$as_me: failed program was:" >&5
1839 sed 's/^/| /' conftest.$ac_ext >&5
1840
1841     ac_retval=1
1842 fi
1843   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1844   as_fn_set_status $ac_retval
1845
1846 } # ac_fn_c_try_cpp
1847
1848 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1849 # -------------------------------------------------------
1850 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1851 # the include files in INCLUDES and setting the cache variable VAR
1852 # accordingly.
1853 ac_fn_c_check_header_mongrel ()
1854 {
1855   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1856   if eval \${$3+:} false; then :
1857   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1858 $as_echo_n "checking for $2... " >&6; }
1859 if eval \${$3+:} false; then :
1860   $as_echo_n "(cached) " >&6
1861 fi
1862 eval ac_res=\$$3
1863                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1864 $as_echo "$ac_res" >&6; }
1865 else
1866   # Is the header compilable?
1867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1868 $as_echo_n "checking $2 usability... " >&6; }
1869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1870 /* end confdefs.h.  */
1871 $4
1872 #include <$2>
1873 _ACEOF
1874 if ac_fn_c_try_compile "$LINENO"; then :
1875   ac_header_compiler=yes
1876 else
1877   ac_header_compiler=no
1878 fi
1879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1881 $as_echo "$ac_header_compiler" >&6; }
1882
1883 # Is the header present?
1884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1885 $as_echo_n "checking $2 presence... " >&6; }
1886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1887 /* end confdefs.h.  */
1888 #include <$2>
1889 _ACEOF
1890 if ac_fn_c_try_cpp "$LINENO"; then :
1891   ac_header_preproc=yes
1892 else
1893   ac_header_preproc=no
1894 fi
1895 rm -f conftest.err conftest.i conftest.$ac_ext
1896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1897 $as_echo "$ac_header_preproc" >&6; }
1898
1899 # So?  What about this header?
1900 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1901   yes:no: )
1902     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1903 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1904     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1905 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1906     ;;
1907   no:yes:* )
1908     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1909 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1910     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1911 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1912     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1913 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1914     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1915 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1916     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1917 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1918     ;;
1919 esac
1920   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1921 $as_echo_n "checking for $2... " >&6; }
1922 if eval \${$3+:} false; then :
1923   $as_echo_n "(cached) " >&6
1924 else
1925   eval "$3=\$ac_header_compiler"
1926 fi
1927 eval ac_res=\$$3
1928                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1929 $as_echo "$ac_res" >&6; }
1930 fi
1931   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1932
1933 } # ac_fn_c_check_header_mongrel
1934
1935 # ac_fn_c_try_run LINENO
1936 # ----------------------
1937 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1938 # that executables *can* be run.
1939 ac_fn_c_try_run ()
1940 {
1941   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1942   if { { ac_try="$ac_link"
1943 case "(($ac_try" in
1944   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1945   *) ac_try_echo=$ac_try;;
1946 esac
1947 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1948 $as_echo "$ac_try_echo"; } >&5
1949   (eval "$ac_link") 2>&5
1950   ac_status=$?
1951   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1952   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1953   { { case "(($ac_try" in
1954   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1955   *) ac_try_echo=$ac_try;;
1956 esac
1957 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1958 $as_echo "$ac_try_echo"; } >&5
1959   (eval "$ac_try") 2>&5
1960   ac_status=$?
1961   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1962   test $ac_status = 0; }; }; then :
1963   ac_retval=0
1964 else
1965   $as_echo "$as_me: program exited with status $ac_status" >&5
1966        $as_echo "$as_me: failed program was:" >&5
1967 sed 's/^/| /' conftest.$ac_ext >&5
1968
1969        ac_retval=$ac_status
1970 fi
1971   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1972   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1973   as_fn_set_status $ac_retval
1974
1975 } # ac_fn_c_try_run
1976
1977 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1978 # -------------------------------------------------------
1979 # Tests whether HEADER exists and can be compiled using the include files in
1980 # INCLUDES, setting the cache variable VAR accordingly.
1981 ac_fn_c_check_header_compile ()
1982 {
1983   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1984   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1985 $as_echo_n "checking for $2... " >&6; }
1986 if eval \${$3+:} false; then :
1987   $as_echo_n "(cached) " >&6
1988 else
1989   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1990 /* end confdefs.h.  */
1991 $4
1992 #include <$2>
1993 _ACEOF
1994 if ac_fn_c_try_compile "$LINENO"; then :
1995   eval "$3=yes"
1996 else
1997   eval "$3=no"
1998 fi
1999 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2000 fi
2001 eval ac_res=\$$3
2002                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2003 $as_echo "$ac_res" >&6; }
2004   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2005
2006 } # ac_fn_c_check_header_compile
2007
2008 # ac_fn_c_try_link LINENO
2009 # -----------------------
2010 # Try to link conftest.$ac_ext, and return whether this succeeded.
2011 ac_fn_c_try_link ()
2012 {
2013   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2014   rm -f conftest.$ac_objext conftest$ac_exeext
2015   if { { ac_try="$ac_link"
2016 case "(($ac_try" in
2017   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2018   *) ac_try_echo=$ac_try;;
2019 esac
2020 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2021 $as_echo "$ac_try_echo"; } >&5
2022   (eval "$ac_link") 2>conftest.err
2023   ac_status=$?
2024   if test -s conftest.err; then
2025     grep -v '^ *+' conftest.err >conftest.er1
2026     cat conftest.er1 >&5
2027     mv -f conftest.er1 conftest.err
2028   fi
2029   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2030   test $ac_status = 0; } && {
2031          test -z "$ac_c_werror_flag" ||
2032          test ! -s conftest.err
2033        } && test -s conftest$ac_exeext && {
2034          test "$cross_compiling" = yes ||
2035          test -x conftest$ac_exeext
2036        }; then :
2037   ac_retval=0
2038 else
2039   $as_echo "$as_me: failed program was:" >&5
2040 sed 's/^/| /' conftest.$ac_ext >&5
2041
2042         ac_retval=1
2043 fi
2044   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2045   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2046   # interfere with the next link command; also delete a directory that is
2047   # left behind by Apple's compiler.  We do this before executing the actions.
2048   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2049   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2050   as_fn_set_status $ac_retval
2051
2052 } # ac_fn_c_try_link
2053
2054 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2055 # --------------------------------------------
2056 # Tries to find the compile-time value of EXPR in a program that includes
2057 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2058 # computed
2059 ac_fn_c_compute_int ()
2060 {
2061   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2062   if test "$cross_compiling" = yes; then
2063     # Depending upon the size, compute the lo and hi bounds.
2064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2065 /* end confdefs.h.  */
2066 $4
2067 int
2068 main ()
2069 {
2070 static int test_array [1 - 2 * !(($2) >= 0)];
2071 test_array [0] = 0;
2072 return test_array [0];
2073
2074   ;
2075   return 0;
2076 }
2077 _ACEOF
2078 if ac_fn_c_try_compile "$LINENO"; then :
2079   ac_lo=0 ac_mid=0
2080   while :; do
2081     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2082 /* end confdefs.h.  */
2083 $4
2084 int
2085 main ()
2086 {
2087 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2088 test_array [0] = 0;
2089 return test_array [0];
2090
2091   ;
2092   return 0;
2093 }
2094 _ACEOF
2095 if ac_fn_c_try_compile "$LINENO"; then :
2096   ac_hi=$ac_mid; break
2097 else
2098   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2099                         if test $ac_lo -le $ac_mid; then
2100                           ac_lo= ac_hi=
2101                           break
2102                         fi
2103                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2104 fi
2105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2106   done
2107 else
2108   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2109 /* end confdefs.h.  */
2110 $4
2111 int
2112 main ()
2113 {
2114 static int test_array [1 - 2 * !(($2) < 0)];
2115 test_array [0] = 0;
2116 return test_array [0];
2117
2118   ;
2119   return 0;
2120 }
2121 _ACEOF
2122 if ac_fn_c_try_compile "$LINENO"; then :
2123   ac_hi=-1 ac_mid=-1
2124   while :; do
2125     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2126 /* end confdefs.h.  */
2127 $4
2128 int
2129 main ()
2130 {
2131 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2132 test_array [0] = 0;
2133 return test_array [0];
2134
2135   ;
2136   return 0;
2137 }
2138 _ACEOF
2139 if ac_fn_c_try_compile "$LINENO"; then :
2140   ac_lo=$ac_mid; break
2141 else
2142   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2143                         if test $ac_mid -le $ac_hi; then
2144                           ac_lo= ac_hi=
2145                           break
2146                         fi
2147                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2148 fi
2149 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2150   done
2151 else
2152   ac_lo= ac_hi=
2153 fi
2154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2155 fi
2156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2157 # Binary search between lo and hi bounds.
2158 while test "x$ac_lo" != "x$ac_hi"; do
2159   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2160   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2161 /* end confdefs.h.  */
2162 $4
2163 int
2164 main ()
2165 {
2166 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2167 test_array [0] = 0;
2168 return test_array [0];
2169
2170   ;
2171   return 0;
2172 }
2173 _ACEOF
2174 if ac_fn_c_try_compile "$LINENO"; then :
2175   ac_hi=$ac_mid
2176 else
2177   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2178 fi
2179 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2180 done
2181 case $ac_lo in #((
2182 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2183 '') ac_retval=1 ;;
2184 esac
2185   else
2186     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2187 /* end confdefs.h.  */
2188 $4
2189 static long int longval () { return $2; }
2190 static unsigned long int ulongval () { return $2; }
2191 #include <stdio.h>
2192 #include <stdlib.h>
2193 int
2194 main ()
2195 {
2196
2197   FILE *f = fopen ("conftest.val", "w");
2198   if (! f)
2199     return 1;
2200   if (($2) < 0)
2201     {
2202       long int i = longval ();
2203       if (i != ($2))
2204         return 1;
2205       fprintf (f, "%ld", i);
2206     }
2207   else
2208     {
2209       unsigned long int i = ulongval ();
2210       if (i != ($2))
2211         return 1;
2212       fprintf (f, "%lu", i);
2213     }
2214   /* Do not output a trailing newline, as this causes \r\n confusion
2215      on some platforms.  */
2216   return ferror (f) || fclose (f) != 0;
2217
2218   ;
2219   return 0;
2220 }
2221 _ACEOF
2222 if ac_fn_c_try_run "$LINENO"; then :
2223   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2224 else
2225   ac_retval=1
2226 fi
2227 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2228   conftest.$ac_objext conftest.beam conftest.$ac_ext
2229 rm -f conftest.val
2230
2231   fi
2232   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2233   as_fn_set_status $ac_retval
2234
2235 } # ac_fn_c_compute_int
2236
2237 # ac_fn_c_check_func LINENO FUNC VAR
2238 # ----------------------------------
2239 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2240 ac_fn_c_check_func ()
2241 {
2242   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2243   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2244 $as_echo_n "checking for $2... " >&6; }
2245 if eval \${$3+:} false; then :
2246   $as_echo_n "(cached) " >&6
2247 else
2248   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2249 /* end confdefs.h.  */
2250 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2251    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2252 #define $2 innocuous_$2
2253
2254 /* System header to define __stub macros and hopefully few prototypes,
2255     which can conflict with char $2 (); below.
2256     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2257     <limits.h> exists even on freestanding compilers.  */
2258
2259 #ifdef __STDC__
2260 # include <limits.h>
2261 #else
2262 # include <assert.h>
2263 #endif
2264
2265 #undef $2
2266
2267 /* Override any GCC internal prototype to avoid an error.
2268    Use char because int might match the return type of a GCC
2269    builtin and then its argument prototype would still apply.  */
2270 #ifdef __cplusplus
2271 extern "C"
2272 #endif
2273 char $2 ();
2274 /* The GNU C library defines this for functions which it implements
2275     to always fail with ENOSYS.  Some functions are actually named
2276     something starting with __ and the normal name is an alias.  */
2277 #if defined __stub_$2 || defined __stub___$2
2278 choke me
2279 #endif
2280
2281 int
2282 main ()
2283 {
2284 return $2 ();
2285   ;
2286   return 0;
2287 }
2288 _ACEOF
2289 if ac_fn_c_try_link "$LINENO"; then :
2290   eval "$3=yes"
2291 else
2292   eval "$3=no"
2293 fi
2294 rm -f core conftest.err conftest.$ac_objext \
2295     conftest$ac_exeext conftest.$ac_ext
2296 fi
2297 eval ac_res=\$$3
2298                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2299 $as_echo "$ac_res" >&6; }
2300   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2301
2302 } # ac_fn_c_check_func
2303
2304 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2305 # ----------------------------------------------------
2306 # Tries to find if the field MEMBER exists in type AGGR, after including
2307 # INCLUDES, setting cache variable VAR accordingly.
2308 ac_fn_c_check_member ()
2309 {
2310   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2311   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2312 $as_echo_n "checking for $2.$3... " >&6; }
2313 if eval \${$4+:} false; then :
2314   $as_echo_n "(cached) " >&6
2315 else
2316   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2317 /* end confdefs.h.  */
2318 $5
2319 int
2320 main ()
2321 {
2322 static $2 ac_aggr;
2323 if (ac_aggr.$3)
2324 return 0;
2325   ;
2326   return 0;
2327 }
2328 _ACEOF
2329 if ac_fn_c_try_compile "$LINENO"; then :
2330   eval "$4=yes"
2331 else
2332   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2333 /* end confdefs.h.  */
2334 $5
2335 int
2336 main ()
2337 {
2338 static $2 ac_aggr;
2339 if (sizeof ac_aggr.$3)
2340 return 0;
2341   ;
2342   return 0;
2343 }
2344 _ACEOF
2345 if ac_fn_c_try_compile "$LINENO"; then :
2346   eval "$4=yes"
2347 else
2348   eval "$4=no"
2349 fi
2350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2351 fi
2352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2353 fi
2354 eval ac_res=\$$4
2355                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2356 $as_echo "$ac_res" >&6; }
2357   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2358
2359 } # ac_fn_c_check_member
2360
2361 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2362 # -------------------------------------------
2363 # Tests whether TYPE exists after having included INCLUDES, setting cache
2364 # variable VAR accordingly.
2365 ac_fn_c_check_type ()
2366 {
2367   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2368   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2369 $as_echo_n "checking for $2... " >&6; }
2370 if eval \${$3+:} false; then :
2371   $as_echo_n "(cached) " >&6
2372 else
2373   eval "$3=no"
2374   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2375 /* end confdefs.h.  */
2376 $4
2377 int
2378 main ()
2379 {
2380 if (sizeof ($2))
2381          return 0;
2382   ;
2383   return 0;
2384 }
2385 _ACEOF
2386 if ac_fn_c_try_compile "$LINENO"; then :
2387   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2388 /* end confdefs.h.  */
2389 $4
2390 int
2391 main ()
2392 {
2393 if (sizeof (($2)))
2394             return 0;
2395   ;
2396   return 0;
2397 }
2398 _ACEOF
2399 if ac_fn_c_try_compile "$LINENO"; then :
2400
2401 else
2402   eval "$3=yes"
2403 fi
2404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2405 fi
2406 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2407 fi
2408 eval ac_res=\$$3
2409                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2410 $as_echo "$ac_res" >&6; }
2411   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2412
2413 } # ac_fn_c_check_type
2414
2415 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2416 # ---------------------------------------------
2417 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2418 # accordingly.
2419 ac_fn_c_check_decl ()
2420 {
2421   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2422   as_decl_name=`echo $2|sed 's/ *(.*//'`
2423   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2424   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2425 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2426 if eval \${$3+:} false; then :
2427   $as_echo_n "(cached) " >&6
2428 else
2429   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2430 /* end confdefs.h.  */
2431 $4
2432 int
2433 main ()
2434 {
2435 #ifndef $as_decl_name
2436 #ifdef __cplusplus
2437   (void) $as_decl_use;
2438 #else
2439   (void) $as_decl_name;
2440 #endif
2441 #endif
2442
2443   ;
2444   return 0;
2445 }
2446 _ACEOF
2447 if ac_fn_c_try_compile "$LINENO"; then :
2448   eval "$3=yes"
2449 else
2450   eval "$3=no"
2451 fi
2452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2453 fi
2454 eval ac_res=\$$3
2455                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2456 $as_echo "$ac_res" >&6; }
2457   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2458
2459 } # ac_fn_c_check_decl
2460
2461 # ac_fn_cxx_try_link LINENO
2462 # -------------------------
2463 # Try to link conftest.$ac_ext, and return whether this succeeded.
2464 ac_fn_cxx_try_link ()
2465 {
2466   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2467   rm -f conftest.$ac_objext conftest$ac_exeext
2468   if { { ac_try="$ac_link"
2469 case "(($ac_try" in
2470   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2471   *) ac_try_echo=$ac_try;;
2472 esac
2473 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2474 $as_echo "$ac_try_echo"; } >&5
2475   (eval "$ac_link") 2>conftest.err
2476   ac_status=$?
2477   if test -s conftest.err; then
2478     grep -v '^ *+' conftest.err >conftest.er1
2479     cat conftest.er1 >&5
2480     mv -f conftest.er1 conftest.err
2481   fi
2482   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2483   test $ac_status = 0; } && {
2484          test -z "$ac_cxx_werror_flag" ||
2485          test ! -s conftest.err
2486        } && test -s conftest$ac_exeext && {
2487          test "$cross_compiling" = yes ||
2488          test -x conftest$ac_exeext
2489        }; then :
2490   ac_retval=0
2491 else
2492   $as_echo "$as_me: failed program was:" >&5
2493 sed 's/^/| /' conftest.$ac_ext >&5
2494
2495         ac_retval=1
2496 fi
2497   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2498   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2499   # interfere with the next link command; also delete a directory that is
2500   # left behind by Apple's compiler.  We do this before executing the actions.
2501   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2502   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2503   as_fn_set_status $ac_retval
2504
2505 } # ac_fn_cxx_try_link
2506 cat >config.log <<_ACEOF
2507 This file contains any messages produced by compilers while
2508 running configure, to aid debugging if configure makes a mistake.
2509
2510 It was created by $as_me, which was
2511 generated by GNU Autoconf 2.69.  Invocation command line was
2512
2513   $ $0 $@
2514
2515 _ACEOF
2516 exec 5>>config.log
2517 {
2518 cat <<_ASUNAME
2519 ## --------- ##
2520 ## Platform. ##
2521 ## --------- ##
2522
2523 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2524 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2525 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2526 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2527 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2528
2529 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2530 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2531
2532 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2533 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2534 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2535 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2536 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2537 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2538 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2539
2540 _ASUNAME
2541
2542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2543 for as_dir in $PATH
2544 do
2545   IFS=$as_save_IFS
2546   test -z "$as_dir" && as_dir=.
2547     $as_echo "PATH: $as_dir"
2548   done
2549 IFS=$as_save_IFS
2550
2551 } >&5
2552
2553 cat >&5 <<_ACEOF
2554
2555
2556 ## ----------- ##
2557 ## Core tests. ##
2558 ## ----------- ##
2559
2560 _ACEOF
2561
2562
2563 # Keep a trace of the command line.
2564 # Strip out --no-create and --no-recursion so they do not pile up.
2565 # Strip out --silent because we don't want to record it for future runs.
2566 # Also quote any args containing shell meta-characters.
2567 # Make two passes to allow for proper duplicate-argument suppression.
2568 ac_configure_args=
2569 ac_configure_args0=
2570 ac_configure_args1=
2571 ac_must_keep_next=false
2572 for ac_pass in 1 2
2573 do
2574   for ac_arg
2575   do
2576     case $ac_arg in
2577     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2578     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2579     | -silent | --silent | --silen | --sile | --sil)
2580       continue ;;
2581     *\'*)
2582       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2583     esac
2584     case $ac_pass in
2585     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2586     2)
2587       as_fn_append ac_configure_args1 " '$ac_arg'"
2588       if test $ac_must_keep_next = true; then
2589         ac_must_keep_next=false # Got value, back to normal.
2590       else
2591         case $ac_arg in
2592           *=* | --config-cache | -C | -disable-* | --disable-* \
2593           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2594           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2595           | -with-* | --with-* | -without-* | --without-* | --x)
2596             case "$ac_configure_args0 " in
2597               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2598             esac
2599             ;;
2600           -* ) ac_must_keep_next=true ;;
2601         esac
2602       fi
2603       as_fn_append ac_configure_args " '$ac_arg'"
2604       ;;
2605     esac
2606   done
2607 done
2608 { ac_configure_args0=; unset ac_configure_args0;}
2609 { ac_configure_args1=; unset ac_configure_args1;}
2610
2611 # When interrupted or exit'd, cleanup temporary files, and complete
2612 # config.log.  We remove comments because anyway the quotes in there
2613 # would cause problems or look ugly.
2614 # WARNING: Use '\'' to represent an apostrophe within the trap.
2615 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2616 trap 'exit_status=$?
2617   # Save into config.log some information that might help in debugging.
2618   {
2619     echo
2620
2621     $as_echo "## ---------------- ##
2622 ## Cache variables. ##
2623 ## ---------------- ##"
2624     echo
2625     # The following way of writing the cache mishandles newlines in values,
2626 (
2627   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2628     eval ac_val=\$$ac_var
2629     case $ac_val in #(
2630     *${as_nl}*)
2631       case $ac_var in #(
2632       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2633 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2634       esac
2635       case $ac_var in #(
2636       _ | IFS | as_nl) ;; #(
2637       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2638       *) { eval $ac_var=; unset $ac_var;} ;;
2639       esac ;;
2640     esac
2641   done
2642   (set) 2>&1 |
2643     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2644     *${as_nl}ac_space=\ *)
2645       sed -n \
2646         "s/'\''/'\''\\\\'\'''\''/g;
2647           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2648       ;; #(
2649     *)
2650       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2651       ;;
2652     esac |
2653     sort
2654 )
2655     echo
2656
2657     $as_echo "## ----------------- ##
2658 ## Output variables. ##
2659 ## ----------------- ##"
2660     echo
2661     for ac_var in $ac_subst_vars
2662     do
2663       eval ac_val=\$$ac_var
2664       case $ac_val in
2665       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2666       esac
2667       $as_echo "$ac_var='\''$ac_val'\''"
2668     done | sort
2669     echo
2670
2671     if test -n "$ac_subst_files"; then
2672       $as_echo "## ------------------- ##
2673 ## File substitutions. ##
2674 ## ------------------- ##"
2675       echo
2676       for ac_var in $ac_subst_files
2677       do
2678         eval ac_val=\$$ac_var
2679         case $ac_val in
2680         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2681         esac
2682         $as_echo "$ac_var='\''$ac_val'\''"
2683       done | sort
2684       echo
2685     fi
2686
2687     if test -s confdefs.h; then
2688       $as_echo "## ----------- ##
2689 ## confdefs.h. ##
2690 ## ----------- ##"
2691       echo
2692       cat confdefs.h
2693       echo
2694     fi
2695     test "$ac_signal" != 0 &&
2696       $as_echo "$as_me: caught signal $ac_signal"
2697     $as_echo "$as_me: exit $exit_status"
2698   } >&5
2699   rm -f core *.core core.conftest.* &&
2700     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2701     exit $exit_status
2702 ' 0
2703 for ac_signal in 1 2 13 15; do
2704   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2705 done
2706 ac_signal=0
2707
2708 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2709 rm -f -r conftest* confdefs.h
2710
2711 $as_echo "/* confdefs.h */" > confdefs.h
2712
2713 # Predefined preprocessor variables.
2714
2715 cat >>confdefs.h <<_ACEOF
2716 #define PACKAGE_NAME "$PACKAGE_NAME"
2717 _ACEOF
2718
2719 cat >>confdefs.h <<_ACEOF
2720 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2721 _ACEOF
2722
2723 cat >>confdefs.h <<_ACEOF
2724 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2725 _ACEOF
2726
2727 cat >>confdefs.h <<_ACEOF
2728 #define PACKAGE_STRING "$PACKAGE_STRING"
2729 _ACEOF
2730
2731 cat >>confdefs.h <<_ACEOF
2732 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2733 _ACEOF
2734
2735 cat >>confdefs.h <<_ACEOF
2736 #define PACKAGE_URL "$PACKAGE_URL"
2737 _ACEOF
2738
2739
2740 # Let the site file select an alternate cache file if it wants to.
2741 # Prefer an explicitly selected file to automatically selected ones.
2742 ac_site_file1=NONE
2743 ac_site_file2=NONE
2744 if test -n "$CONFIG_SITE"; then
2745   # We do not want a PATH search for config.site.
2746   case $CONFIG_SITE in #((
2747     -*)  ac_site_file1=./$CONFIG_SITE;;
2748     */*) ac_site_file1=$CONFIG_SITE;;
2749     *)   ac_site_file1=./$CONFIG_SITE;;
2750   esac
2751 elif test "x$prefix" != xNONE; then
2752   ac_site_file1=$prefix/share/config.site
2753   ac_site_file2=$prefix/etc/config.site
2754 else
2755   ac_site_file1=$ac_default_prefix/share/config.site
2756   ac_site_file2=$ac_default_prefix/etc/config.site
2757 fi
2758 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2759 do
2760   test "x$ac_site_file" = xNONE && continue
2761   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2762     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2763 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2764     sed 's/^/| /' "$ac_site_file" >&5
2765     . "$ac_site_file" \
2766       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2767 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2768 as_fn_error $? "failed to load site script $ac_site_file
2769 See \`config.log' for more details" "$LINENO" 5; }
2770   fi
2771 done
2772
2773 if test -r "$cache_file"; then
2774   # Some versions of bash will fail to source /dev/null (special files
2775   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2776   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2777     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2778 $as_echo "$as_me: loading cache $cache_file" >&6;}
2779     case $cache_file in
2780       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2781       *)                      . "./$cache_file";;
2782     esac
2783   fi
2784 else
2785   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2786 $as_echo "$as_me: creating cache $cache_file" >&6;}
2787   >$cache_file
2788 fi
2789
2790 as_fn_append ac_header_list " stdlib.h"
2791 as_fn_append ac_header_list " unistd.h"
2792 as_fn_append ac_header_list " sys/param.h"
2793 # Check that the precious variables saved in the cache have kept the same
2794 # value.
2795 ac_cache_corrupted=false
2796 for ac_var in $ac_precious_vars; do
2797   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2798   eval ac_new_set=\$ac_env_${ac_var}_set
2799   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2800   eval ac_new_val=\$ac_env_${ac_var}_value
2801   case $ac_old_set,$ac_new_set in
2802     set,)
2803       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2804 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2805       ac_cache_corrupted=: ;;
2806     ,set)
2807       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2808 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2809       ac_cache_corrupted=: ;;
2810     ,);;
2811     *)
2812       if test "x$ac_old_val" != "x$ac_new_val"; then
2813         # differences in whitespace do not lead to failure.
2814         ac_old_val_w=`echo x $ac_old_val`
2815         ac_new_val_w=`echo x $ac_new_val`
2816         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2817           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2818 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2819           ac_cache_corrupted=:
2820         else
2821           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2822 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2823           eval $ac_var=\$ac_old_val
2824         fi
2825         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2826 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2827         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2828 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2829       fi;;
2830   esac
2831   # Pass precious variables to config.status.
2832   if test "$ac_new_set" = set; then
2833     case $ac_new_val in
2834     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2835     *) ac_arg=$ac_var=$ac_new_val ;;
2836     esac
2837     case " $ac_configure_args " in
2838       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2839       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2840     esac
2841   fi
2842 done
2843 if $ac_cache_corrupted; then
2844   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2845 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2846   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2847 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2848   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2849 fi
2850 ## -------------------- ##
2851 ## Main body of script. ##
2852 ## -------------------- ##
2853
2854 ac_ext=c
2855 ac_cpp='$CPP $CPPFLAGS'
2856 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2857 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2858 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2859
2860
2861
2862
2863
2864 ac_config_headers="$ac_config_headers config.h:config.in"
2865
2866
2867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
2868 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2869     # Check whether --enable-maintainer-mode was given.
2870 if test "${enable_maintainer_mode+set}" = set; then :
2871   enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2872 else
2873   USE_MAINTAINER_MODE=no
2874 fi
2875
2876   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
2877 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2878    if test $USE_MAINTAINER_MODE = yes; then
2879   MAINTAINER_MODE_TRUE=
2880   MAINTAINER_MODE_FALSE='#'
2881 else
2882   MAINTAINER_MODE_TRUE='#'
2883   MAINTAINER_MODE_FALSE=
2884 fi
2885
2886   MAINT=$MAINTAINER_MODE_TRUE
2887
2888
2889
2890 # Set the 'development' global.
2891 . $srcdir/../bfd/development.sh
2892
2893 ac_ext=c
2894 ac_cpp='$CPP $CPPFLAGS'
2895 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2896 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2897 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2898 if test -n "$ac_tool_prefix"; then
2899   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2900 set dummy ${ac_tool_prefix}gcc; 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 ${ac_cv_prog_CC+:} false; 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 as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2916     ac_cv_prog_CC="${ac_tool_prefix}gcc"
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 fi
2937 if test -z "$ac_cv_prog_CC"; then
2938   ac_ct_CC=$CC
2939   # Extract the first word of "gcc", so it can be a program name with args.
2940 set dummy gcc; ac_word=$2
2941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2942 $as_echo_n "checking for $ac_word... " >&6; }
2943 if ${ac_cv_prog_ac_ct_CC+:} false; then :
2944   $as_echo_n "(cached) " >&6
2945 else
2946   if test -n "$ac_ct_CC"; then
2947   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2948 else
2949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2950 for as_dir in $PATH
2951 do
2952   IFS=$as_save_IFS
2953   test -z "$as_dir" && as_dir=.
2954     for ac_exec_ext in '' $ac_executable_extensions; do
2955   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2956     ac_cv_prog_ac_ct_CC="gcc"
2957     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2958     break 2
2959   fi
2960 done
2961   done
2962 IFS=$as_save_IFS
2963
2964 fi
2965 fi
2966 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2967 if test -n "$ac_ct_CC"; then
2968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2969 $as_echo "$ac_ct_CC" >&6; }
2970 else
2971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2972 $as_echo "no" >&6; }
2973 fi
2974
2975   if test "x$ac_ct_CC" = x; then
2976     CC=""
2977   else
2978     case $cross_compiling:$ac_tool_warned in
2979 yes:)
2980 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2981 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2982 ac_tool_warned=yes ;;
2983 esac
2984     CC=$ac_ct_CC
2985   fi
2986 else
2987   CC="$ac_cv_prog_CC"
2988 fi
2989
2990 if test -z "$CC"; then
2991           if test -n "$ac_tool_prefix"; then
2992     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2993 set dummy ${ac_tool_prefix}cc; ac_word=$2
2994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2995 $as_echo_n "checking for $ac_word... " >&6; }
2996 if ${ac_cv_prog_CC+:} false; then :
2997   $as_echo_n "(cached) " >&6
2998 else
2999   if test -n "$CC"; then
3000   ac_cv_prog_CC="$CC" # Let the user override the test.
3001 else
3002 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3003 for as_dir in $PATH
3004 do
3005   IFS=$as_save_IFS
3006   test -z "$as_dir" && as_dir=.
3007     for ac_exec_ext in '' $ac_executable_extensions; do
3008   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3009     ac_cv_prog_CC="${ac_tool_prefix}cc"
3010     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3011     break 2
3012   fi
3013 done
3014   done
3015 IFS=$as_save_IFS
3016
3017 fi
3018 fi
3019 CC=$ac_cv_prog_CC
3020 if test -n "$CC"; then
3021   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3022 $as_echo "$CC" >&6; }
3023 else
3024   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3025 $as_echo "no" >&6; }
3026 fi
3027
3028
3029   fi
3030 fi
3031 if test -z "$CC"; then
3032   # Extract the first word of "cc", so it can be a program name with args.
3033 set dummy cc; ac_word=$2
3034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3035 $as_echo_n "checking for $ac_word... " >&6; }
3036 if ${ac_cv_prog_CC+:} false; then :
3037   $as_echo_n "(cached) " >&6
3038 else
3039   if test -n "$CC"; then
3040   ac_cv_prog_CC="$CC" # Let the user override the test.
3041 else
3042   ac_prog_rejected=no
3043 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3044 for as_dir in $PATH
3045 do
3046   IFS=$as_save_IFS
3047   test -z "$as_dir" && as_dir=.
3048     for ac_exec_ext in '' $ac_executable_extensions; do
3049   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3050     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3051        ac_prog_rejected=yes
3052        continue
3053      fi
3054     ac_cv_prog_CC="cc"
3055     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3056     break 2
3057   fi
3058 done
3059   done
3060 IFS=$as_save_IFS
3061
3062 if test $ac_prog_rejected = yes; then
3063   # We found a bogon in the path, so make sure we never use it.
3064   set dummy $ac_cv_prog_CC
3065   shift
3066   if test $# != 0; then
3067     # We chose a different compiler from the bogus one.
3068     # However, it has the same basename, so the bogon will be chosen
3069     # first if we set CC to just the basename; use the full file name.
3070     shift
3071     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3072   fi
3073 fi
3074 fi
3075 fi
3076 CC=$ac_cv_prog_CC
3077 if test -n "$CC"; then
3078   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3079 $as_echo "$CC" >&6; }
3080 else
3081   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3082 $as_echo "no" >&6; }
3083 fi
3084
3085
3086 fi
3087 if test -z "$CC"; then
3088   if test -n "$ac_tool_prefix"; then
3089   for ac_prog in cl.exe
3090   do
3091     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3092 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3094 $as_echo_n "checking for $ac_word... " >&6; }
3095 if ${ac_cv_prog_CC+:} false; then :
3096   $as_echo_n "(cached) " >&6
3097 else
3098   if test -n "$CC"; then
3099   ac_cv_prog_CC="$CC" # Let the user override the test.
3100 else
3101 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3102 for as_dir in $PATH
3103 do
3104   IFS=$as_save_IFS
3105   test -z "$as_dir" && as_dir=.
3106     for ac_exec_ext in '' $ac_executable_extensions; do
3107   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3108     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3109     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3110     break 2
3111   fi
3112 done
3113   done
3114 IFS=$as_save_IFS
3115
3116 fi
3117 fi
3118 CC=$ac_cv_prog_CC
3119 if test -n "$CC"; then
3120   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3121 $as_echo "$CC" >&6; }
3122 else
3123   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3124 $as_echo "no" >&6; }
3125 fi
3126
3127
3128     test -n "$CC" && break
3129   done
3130 fi
3131 if test -z "$CC"; then
3132   ac_ct_CC=$CC
3133   for ac_prog in cl.exe
3134 do
3135   # Extract the first word of "$ac_prog", so it can be a program name with args.
3136 set dummy $ac_prog; ac_word=$2
3137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3138 $as_echo_n "checking for $ac_word... " >&6; }
3139 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3140   $as_echo_n "(cached) " >&6
3141 else
3142   if test -n "$ac_ct_CC"; then
3143   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3144 else
3145 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3146 for as_dir in $PATH
3147 do
3148   IFS=$as_save_IFS
3149   test -z "$as_dir" && as_dir=.
3150     for ac_exec_ext in '' $ac_executable_extensions; do
3151   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3152     ac_cv_prog_ac_ct_CC="$ac_prog"
3153     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3154     break 2
3155   fi
3156 done
3157   done
3158 IFS=$as_save_IFS
3159
3160 fi
3161 fi
3162 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3163 if test -n "$ac_ct_CC"; then
3164   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3165 $as_echo "$ac_ct_CC" >&6; }
3166 else
3167   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3168 $as_echo "no" >&6; }
3169 fi
3170
3171
3172   test -n "$ac_ct_CC" && break
3173 done
3174
3175   if test "x$ac_ct_CC" = x; then
3176     CC=""
3177   else
3178     case $cross_compiling:$ac_tool_warned in
3179 yes:)
3180 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3181 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3182 ac_tool_warned=yes ;;
3183 esac
3184     CC=$ac_ct_CC
3185   fi
3186 fi
3187
3188 fi
3189
3190
3191 test -z "$CC" && { { $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 $? "no acceptable C compiler found in \$PATH
3194 See \`config.log' for more details" "$LINENO" 5; }
3195
3196 # Provide some information about the compiler.
3197 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3198 set X $ac_compile
3199 ac_compiler=$2
3200 for ac_option in --version -v -V -qversion; do
3201   { { ac_try="$ac_compiler $ac_option >&5"
3202 case "(($ac_try" in
3203   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3204   *) ac_try_echo=$ac_try;;
3205 esac
3206 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3207 $as_echo "$ac_try_echo"; } >&5
3208   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3209   ac_status=$?
3210   if test -s conftest.err; then
3211     sed '10a\
3212 ... rest of stderr output deleted ...
3213          10q' conftest.err >conftest.er1
3214     cat conftest.er1 >&5
3215   fi
3216   rm -f conftest.er1 conftest.err
3217   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3218   test $ac_status = 0; }
3219 done
3220
3221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3222 /* end confdefs.h.  */
3223
3224 int
3225 main ()
3226 {
3227
3228   ;
3229   return 0;
3230 }
3231 _ACEOF
3232 ac_clean_files_save=$ac_clean_files
3233 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3234 # Try to create an executable without -o first, disregard a.out.
3235 # It will help us diagnose broken compilers, and finding out an intuition
3236 # of exeext.
3237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3238 $as_echo_n "checking whether the C compiler works... " >&6; }
3239 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3240
3241 # The possible output files:
3242 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3243
3244 ac_rmfiles=
3245 for ac_file in $ac_files
3246 do
3247   case $ac_file in
3248     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3249     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3250   esac
3251 done
3252 rm -f $ac_rmfiles
3253
3254 if { { ac_try="$ac_link_default"
3255 case "(($ac_try" in
3256   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3257   *) ac_try_echo=$ac_try;;
3258 esac
3259 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3260 $as_echo "$ac_try_echo"; } >&5
3261   (eval "$ac_link_default") 2>&5
3262   ac_status=$?
3263   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3264   test $ac_status = 0; }; then :
3265   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3266 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3267 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3268 # so that the user can short-circuit this test for compilers unknown to
3269 # Autoconf.
3270 for ac_file in $ac_files ''
3271 do
3272   test -f "$ac_file" || continue
3273   case $ac_file in
3274     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3275         ;;
3276     [ab].out )
3277         # We found the default executable, but exeext='' is most
3278         # certainly right.
3279         break;;
3280     *.* )
3281         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3282         then :; else
3283            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3284         fi
3285         # We set ac_cv_exeext here because the later test for it is not
3286         # safe: cross compilers may not add the suffix if given an `-o'
3287         # argument, so we may need to know it at that point already.
3288         # Even if this section looks crufty: it has the advantage of
3289         # actually working.
3290         break;;
3291     * )
3292         break;;
3293   esac
3294 done
3295 test "$ac_cv_exeext" = no && ac_cv_exeext=
3296
3297 else
3298   ac_file=''
3299 fi
3300 if test -z "$ac_file"; then :
3301   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3302 $as_echo "no" >&6; }
3303 $as_echo "$as_me: failed program was:" >&5
3304 sed 's/^/| /' conftest.$ac_ext >&5
3305
3306 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3307 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3308 as_fn_error 77 "C compiler cannot create executables
3309 See \`config.log' for more details" "$LINENO" 5; }
3310 else
3311   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3312 $as_echo "yes" >&6; }
3313 fi
3314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3315 $as_echo_n "checking for C compiler default output file name... " >&6; }
3316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3317 $as_echo "$ac_file" >&6; }
3318 ac_exeext=$ac_cv_exeext
3319
3320 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3321 ac_clean_files=$ac_clean_files_save
3322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3323 $as_echo_n "checking for suffix of executables... " >&6; }
3324 if { { ac_try="$ac_link"
3325 case "(($ac_try" in
3326   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3327   *) ac_try_echo=$ac_try;;
3328 esac
3329 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3330 $as_echo "$ac_try_echo"; } >&5
3331   (eval "$ac_link") 2>&5
3332   ac_status=$?
3333   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3334   test $ac_status = 0; }; then :
3335   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3336 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3337 # work properly (i.e., refer to `conftest.exe'), while it won't with
3338 # `rm'.
3339 for ac_file in conftest.exe conftest conftest.*; do
3340   test -f "$ac_file" || continue
3341   case $ac_file in
3342     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3343     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3344           break;;
3345     * ) break;;
3346   esac
3347 done
3348 else
3349   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3350 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3351 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3352 See \`config.log' for more details" "$LINENO" 5; }
3353 fi
3354 rm -f conftest conftest$ac_cv_exeext
3355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3356 $as_echo "$ac_cv_exeext" >&6; }
3357
3358 rm -f conftest.$ac_ext
3359 EXEEXT=$ac_cv_exeext
3360 ac_exeext=$EXEEXT
3361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3362 /* end confdefs.h.  */
3363 #include <stdio.h>
3364 int
3365 main ()
3366 {
3367 FILE *f = fopen ("conftest.out", "w");
3368  return ferror (f) || fclose (f) != 0;
3369
3370   ;
3371   return 0;
3372 }
3373 _ACEOF
3374 ac_clean_files="$ac_clean_files conftest.out"
3375 # Check that the compiler produces executables we can run.  If not, either
3376 # the compiler is broken, or we cross compile.
3377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3378 $as_echo_n "checking whether we are cross compiling... " >&6; }
3379 if test "$cross_compiling" != yes; then
3380   { { ac_try="$ac_link"
3381 case "(($ac_try" in
3382   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3383   *) ac_try_echo=$ac_try;;
3384 esac
3385 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3386 $as_echo "$ac_try_echo"; } >&5
3387   (eval "$ac_link") 2>&5
3388   ac_status=$?
3389   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3390   test $ac_status = 0; }
3391   if { ac_try='./conftest$ac_cv_exeext'
3392   { { case "(($ac_try" in
3393   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3394   *) ac_try_echo=$ac_try;;
3395 esac
3396 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3397 $as_echo "$ac_try_echo"; } >&5
3398   (eval "$ac_try") 2>&5
3399   ac_status=$?
3400   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3401   test $ac_status = 0; }; }; then
3402     cross_compiling=no
3403   else
3404     if test "$cross_compiling" = maybe; then
3405         cross_compiling=yes
3406     else
3407         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3408 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3409 as_fn_error $? "cannot run C compiled programs.
3410 If you meant to cross compile, use \`--host'.
3411 See \`config.log' for more details" "$LINENO" 5; }
3412     fi
3413   fi
3414 fi
3415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3416 $as_echo "$cross_compiling" >&6; }
3417
3418 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3419 ac_clean_files=$ac_clean_files_save
3420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3421 $as_echo_n "checking for suffix of object files... " >&6; }
3422 if ${ac_cv_objext+:} false; then :
3423   $as_echo_n "(cached) " >&6
3424 else
3425   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3426 /* end confdefs.h.  */
3427
3428 int
3429 main ()
3430 {
3431
3432   ;
3433   return 0;
3434 }
3435 _ACEOF
3436 rm -f conftest.o conftest.obj
3437 if { { ac_try="$ac_compile"
3438 case "(($ac_try" in
3439   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3440   *) ac_try_echo=$ac_try;;
3441 esac
3442 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3443 $as_echo "$ac_try_echo"; } >&5
3444   (eval "$ac_compile") 2>&5
3445   ac_status=$?
3446   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3447   test $ac_status = 0; }; then :
3448   for ac_file in conftest.o conftest.obj conftest.*; do
3449   test -f "$ac_file" || continue;
3450   case $ac_file in
3451     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3452     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3453        break;;
3454   esac
3455 done
3456 else
3457   $as_echo "$as_me: failed program was:" >&5
3458 sed 's/^/| /' conftest.$ac_ext >&5
3459
3460 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3461 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3462 as_fn_error $? "cannot compute suffix of object files: cannot compile
3463 See \`config.log' for more details" "$LINENO" 5; }
3464 fi
3465 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3466 fi
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3468 $as_echo "$ac_cv_objext" >&6; }
3469 OBJEXT=$ac_cv_objext
3470 ac_objext=$OBJEXT
3471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3472 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3473 if ${ac_cv_c_compiler_gnu+:} false; then :
3474   $as_echo_n "(cached) " >&6
3475 else
3476   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3477 /* end confdefs.h.  */
3478
3479 int
3480 main ()
3481 {
3482 #ifndef __GNUC__
3483        choke me
3484 #endif
3485
3486   ;
3487   return 0;
3488 }
3489 _ACEOF
3490 if ac_fn_c_try_compile "$LINENO"; then :
3491   ac_compiler_gnu=yes
3492 else
3493   ac_compiler_gnu=no
3494 fi
3495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3496 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3497
3498 fi
3499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3500 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3501 if test $ac_compiler_gnu = yes; then
3502   GCC=yes
3503 else
3504   GCC=
3505 fi
3506 ac_test_CFLAGS=${CFLAGS+set}
3507 ac_save_CFLAGS=$CFLAGS
3508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3509 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3510 if ${ac_cv_prog_cc_g+:} false; then :
3511   $as_echo_n "(cached) " >&6
3512 else
3513   ac_save_c_werror_flag=$ac_c_werror_flag
3514    ac_c_werror_flag=yes
3515    ac_cv_prog_cc_g=no
3516    CFLAGS="-g"
3517    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3518 /* end confdefs.h.  */
3519
3520 int
3521 main ()
3522 {
3523
3524   ;
3525   return 0;
3526 }
3527 _ACEOF
3528 if ac_fn_c_try_compile "$LINENO"; then :
3529   ac_cv_prog_cc_g=yes
3530 else
3531   CFLAGS=""
3532       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3533 /* end confdefs.h.  */
3534
3535 int
3536 main ()
3537 {
3538
3539   ;
3540   return 0;
3541 }
3542 _ACEOF
3543 if ac_fn_c_try_compile "$LINENO"; then :
3544
3545 else
3546   ac_c_werror_flag=$ac_save_c_werror_flag
3547          CFLAGS="-g"
3548          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3549 /* end confdefs.h.  */
3550
3551 int
3552 main ()
3553 {
3554
3555   ;
3556   return 0;
3557 }
3558 _ACEOF
3559 if ac_fn_c_try_compile "$LINENO"; then :
3560   ac_cv_prog_cc_g=yes
3561 fi
3562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3563 fi
3564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3565 fi
3566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3567    ac_c_werror_flag=$ac_save_c_werror_flag
3568 fi
3569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3570 $as_echo "$ac_cv_prog_cc_g" >&6; }
3571 if test "$ac_test_CFLAGS" = set; then
3572   CFLAGS=$ac_save_CFLAGS
3573 elif test $ac_cv_prog_cc_g = yes; then
3574   if test "$GCC" = yes; then
3575     CFLAGS="-g -O2"
3576   else
3577     CFLAGS="-g"
3578   fi
3579 else
3580   if test "$GCC" = yes; then
3581     CFLAGS="-O2"
3582   else
3583     CFLAGS=
3584   fi
3585 fi
3586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3587 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3588 if ${ac_cv_prog_cc_c89+:} false; then :
3589   $as_echo_n "(cached) " >&6
3590 else
3591   ac_cv_prog_cc_c89=no
3592 ac_save_CC=$CC
3593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3594 /* end confdefs.h.  */
3595 #include <stdarg.h>
3596 #include <stdio.h>
3597 struct stat;
3598 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3599 struct buf { int x; };
3600 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3601 static char *e (p, i)
3602      char **p;
3603      int i;
3604 {
3605   return p[i];
3606 }
3607 static char *f (char * (*g) (char **, int), char **p, ...)
3608 {
3609   char *s;
3610   va_list v;
3611   va_start (v,p);
3612   s = g (p, va_arg (v,int));
3613   va_end (v);
3614   return s;
3615 }
3616
3617 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3618    function prototypes and stuff, but not '\xHH' hex character constants.
3619    These don't provoke an error unfortunately, instead are silently treated
3620    as 'x'.  The following induces an error, until -std is added to get
3621    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3622    array size at least.  It's necessary to write '\x00'==0 to get something
3623    that's true only with -std.  */
3624 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3625
3626 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3627    inside strings and character constants.  */
3628 #define FOO(x) 'x'
3629 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3630
3631 int test (int i, double x);
3632 struct s1 {int (*f) (int a);};
3633 struct s2 {int (*f) (double a);};
3634 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3635 int argc;
3636 char **argv;
3637 int
3638 main ()
3639 {
3640 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3641   ;
3642   return 0;
3643 }
3644 _ACEOF
3645 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3646         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3647 do
3648   CC="$ac_save_CC $ac_arg"
3649   if ac_fn_c_try_compile "$LINENO"; then :
3650   ac_cv_prog_cc_c89=$ac_arg
3651 fi
3652 rm -f core conftest.err conftest.$ac_objext
3653   test "x$ac_cv_prog_cc_c89" != "xno" && break
3654 done
3655 rm -f conftest.$ac_ext
3656 CC=$ac_save_CC
3657
3658 fi
3659 # AC_CACHE_VAL
3660 case "x$ac_cv_prog_cc_c89" in
3661   x)
3662     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3663 $as_echo "none needed" >&6; } ;;
3664   xno)
3665     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3666 $as_echo "unsupported" >&6; } ;;
3667   *)
3668     CC="$CC $ac_cv_prog_cc_c89"
3669     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3670 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3671 esac
3672 if test "x$ac_cv_prog_cc_c89" != xno; then :
3673
3674 fi
3675
3676 ac_ext=c
3677 ac_cpp='$CPP $CPPFLAGS'
3678 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3679 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3680 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3681
3682 ac_ext=cpp
3683 ac_cpp='$CXXCPP $CPPFLAGS'
3684 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3685 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3686 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3687 if test -z "$CXX"; then
3688   if test -n "$CCC"; then
3689     CXX=$CCC
3690   else
3691     if test -n "$ac_tool_prefix"; then
3692   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3693   do
3694     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3695 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3697 $as_echo_n "checking for $ac_word... " >&6; }
3698 if ${ac_cv_prog_CXX+:} false; then :
3699   $as_echo_n "(cached) " >&6
3700 else
3701   if test -n "$CXX"; then
3702   ac_cv_prog_CXX="$CXX" # Let the user override the test.
3703 else
3704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3705 for as_dir in $PATH
3706 do
3707   IFS=$as_save_IFS
3708   test -z "$as_dir" && as_dir=.
3709     for ac_exec_ext in '' $ac_executable_extensions; do
3710   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3711     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3712     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3713     break 2
3714   fi
3715 done
3716   done
3717 IFS=$as_save_IFS
3718
3719 fi
3720 fi
3721 CXX=$ac_cv_prog_CXX
3722 if test -n "$CXX"; then
3723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3724 $as_echo "$CXX" >&6; }
3725 else
3726   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3727 $as_echo "no" >&6; }
3728 fi
3729
3730
3731     test -n "$CXX" && break
3732   done
3733 fi
3734 if test -z "$CXX"; then
3735   ac_ct_CXX=$CXX
3736   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3737 do
3738   # Extract the first word of "$ac_prog", so it can be a program name with args.
3739 set dummy $ac_prog; ac_word=$2
3740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3741 $as_echo_n "checking for $ac_word... " >&6; }
3742 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3743   $as_echo_n "(cached) " >&6
3744 else
3745   if test -n "$ac_ct_CXX"; then
3746   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3747 else
3748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3749 for as_dir in $PATH
3750 do
3751   IFS=$as_save_IFS
3752   test -z "$as_dir" && as_dir=.
3753     for ac_exec_ext in '' $ac_executable_extensions; do
3754   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3755     ac_cv_prog_ac_ct_CXX="$ac_prog"
3756     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3757     break 2
3758   fi
3759 done
3760   done
3761 IFS=$as_save_IFS
3762
3763 fi
3764 fi
3765 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3766 if test -n "$ac_ct_CXX"; then
3767   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3768 $as_echo "$ac_ct_CXX" >&6; }
3769 else
3770   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3771 $as_echo "no" >&6; }
3772 fi
3773
3774
3775   test -n "$ac_ct_CXX" && break
3776 done
3777
3778   if test "x$ac_ct_CXX" = x; then
3779     CXX="g++"
3780   else
3781     case $cross_compiling:$ac_tool_warned in
3782 yes:)
3783 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3784 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3785 ac_tool_warned=yes ;;
3786 esac
3787     CXX=$ac_ct_CXX
3788   fi
3789 fi
3790
3791   fi
3792 fi
3793 # Provide some information about the compiler.
3794 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3795 set X $ac_compile
3796 ac_compiler=$2
3797 for ac_option in --version -v -V -qversion; do
3798   { { ac_try="$ac_compiler $ac_option >&5"
3799 case "(($ac_try" in
3800   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3801   *) ac_try_echo=$ac_try;;
3802 esac
3803 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3804 $as_echo "$ac_try_echo"; } >&5
3805   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3806   ac_status=$?
3807   if test -s conftest.err; then
3808     sed '10a\
3809 ... rest of stderr output deleted ...
3810          10q' conftest.err >conftest.er1
3811     cat conftest.er1 >&5
3812   fi
3813   rm -f conftest.er1 conftest.err
3814   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3815   test $ac_status = 0; }
3816 done
3817
3818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3819 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
3820 if ${ac_cv_cxx_compiler_gnu+:} false; then :
3821   $as_echo_n "(cached) " >&6
3822 else
3823   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3824 /* end confdefs.h.  */
3825
3826 int
3827 main ()
3828 {
3829 #ifndef __GNUC__
3830        choke me
3831 #endif
3832
3833   ;
3834   return 0;
3835 }
3836 _ACEOF
3837 if ac_fn_cxx_try_compile "$LINENO"; then :
3838   ac_compiler_gnu=yes
3839 else
3840   ac_compiler_gnu=no
3841 fi
3842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3843 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
3844
3845 fi
3846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3847 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3848 if test $ac_compiler_gnu = yes; then
3849   GXX=yes
3850 else
3851   GXX=
3852 fi
3853 ac_test_CXXFLAGS=${CXXFLAGS+set}
3854 ac_save_CXXFLAGS=$CXXFLAGS
3855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3856 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
3857 if ${ac_cv_prog_cxx_g+:} false; then :
3858   $as_echo_n "(cached) " >&6
3859 else
3860   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3861    ac_cxx_werror_flag=yes
3862    ac_cv_prog_cxx_g=no
3863    CXXFLAGS="-g"
3864    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3865 /* end confdefs.h.  */
3866
3867 int
3868 main ()
3869 {
3870
3871   ;
3872   return 0;
3873 }
3874 _ACEOF
3875 if ac_fn_cxx_try_compile "$LINENO"; then :
3876   ac_cv_prog_cxx_g=yes
3877 else
3878   CXXFLAGS=""
3879       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3880 /* end confdefs.h.  */
3881
3882 int
3883 main ()
3884 {
3885
3886   ;
3887   return 0;
3888 }
3889 _ACEOF
3890 if ac_fn_cxx_try_compile "$LINENO"; then :
3891
3892 else
3893   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3894          CXXFLAGS="-g"
3895          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3896 /* end confdefs.h.  */
3897
3898 int
3899 main ()
3900 {
3901
3902   ;
3903   return 0;
3904 }
3905 _ACEOF
3906 if ac_fn_cxx_try_compile "$LINENO"; then :
3907   ac_cv_prog_cxx_g=yes
3908 fi
3909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3910 fi
3911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3912 fi
3913 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3914    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3915 fi
3916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3917 $as_echo "$ac_cv_prog_cxx_g" >&6; }
3918 if test "$ac_test_CXXFLAGS" = set; then
3919   CXXFLAGS=$ac_save_CXXFLAGS
3920 elif test $ac_cv_prog_cxx_g = yes; then
3921   if test "$GXX" = yes; then
3922     CXXFLAGS="-g -O2"
3923   else
3924     CXXFLAGS="-g"
3925   fi
3926 else
3927   if test "$GXX" = yes; then
3928     CXXFLAGS="-O2"
3929   else
3930     CXXFLAGS=
3931   fi
3932 fi
3933 ac_ext=c
3934 ac_cpp='$CPP $CPPFLAGS'
3935 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3936 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3937 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3938
3939
3940
3941 ac_ext=c
3942 ac_cpp='$CPP $CPPFLAGS'
3943 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3944 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3945 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3947 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3948 # On Suns, sometimes $CPP names a directory.
3949 if test -n "$CPP" && test -d "$CPP"; then
3950   CPP=
3951 fi
3952 if test -z "$CPP"; then
3953   if ${ac_cv_prog_CPP+:} false; then :
3954   $as_echo_n "(cached) " >&6
3955 else
3956       # Double quotes because CPP needs to be expanded
3957     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3958     do
3959       ac_preproc_ok=false
3960 for ac_c_preproc_warn_flag in '' yes
3961 do
3962   # Use a header file that comes with gcc, so configuring glibc
3963   # with a fresh cross-compiler works.
3964   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3965   # <limits.h> exists even on freestanding compilers.
3966   # On the NeXT, cc -E runs the code through the compiler's parser,
3967   # not just through cpp. "Syntax error" is here to catch this case.
3968   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3969 /* end confdefs.h.  */
3970 #ifdef __STDC__
3971 # include <limits.h>
3972 #else
3973 # include <assert.h>
3974 #endif
3975                      Syntax error
3976 _ACEOF
3977 if ac_fn_c_try_cpp "$LINENO"; then :
3978
3979 else
3980   # Broken: fails on valid input.
3981 continue
3982 fi
3983 rm -f conftest.err conftest.i conftest.$ac_ext
3984
3985   # OK, works on sane cases.  Now check whether nonexistent headers
3986   # can be detected and how.
3987   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3988 /* end confdefs.h.  */
3989 #include <ac_nonexistent.h>
3990 _ACEOF
3991 if ac_fn_c_try_cpp "$LINENO"; then :
3992   # Broken: success on invalid input.
3993 continue
3994 else
3995   # Passes both tests.
3996 ac_preproc_ok=:
3997 break
3998 fi
3999 rm -f conftest.err conftest.i conftest.$ac_ext
4000
4001 done
4002 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4003 rm -f conftest.i conftest.err conftest.$ac_ext
4004 if $ac_preproc_ok; then :
4005   break
4006 fi
4007
4008     done
4009     ac_cv_prog_CPP=$CPP
4010
4011 fi
4012   CPP=$ac_cv_prog_CPP
4013 else
4014   ac_cv_prog_CPP=$CPP
4015 fi
4016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4017 $as_echo "$CPP" >&6; }
4018 ac_preproc_ok=false
4019 for ac_c_preproc_warn_flag in '' yes
4020 do
4021   # Use a header file that comes with gcc, so configuring glibc
4022   # with a fresh cross-compiler works.
4023   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4024   # <limits.h> exists even on freestanding compilers.
4025   # On the NeXT, cc -E runs the code through the compiler's parser,
4026   # not just through cpp. "Syntax error" is here to catch this case.
4027   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4028 /* end confdefs.h.  */
4029 #ifdef __STDC__
4030 # include <limits.h>
4031 #else
4032 # include <assert.h>
4033 #endif
4034                      Syntax error
4035 _ACEOF
4036 if ac_fn_c_try_cpp "$LINENO"; then :
4037
4038 else
4039   # Broken: fails on valid input.
4040 continue
4041 fi
4042 rm -f conftest.err conftest.i conftest.$ac_ext
4043
4044   # OK, works on sane cases.  Now check whether nonexistent headers
4045   # can be detected and how.
4046   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4047 /* end confdefs.h.  */
4048 #include <ac_nonexistent.h>
4049 _ACEOF
4050 if ac_fn_c_try_cpp "$LINENO"; then :
4051   # Broken: success on invalid input.
4052 continue
4053 else
4054   # Passes both tests.
4055 ac_preproc_ok=:
4056 break
4057 fi
4058 rm -f conftest.err conftest.i conftest.$ac_ext
4059
4060 done
4061 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4062 rm -f conftest.i conftest.err conftest.$ac_ext
4063 if $ac_preproc_ok; then :
4064
4065 else
4066   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4067 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4068 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4069 See \`config.log' for more details" "$LINENO" 5; }
4070 fi
4071
4072 ac_ext=c
4073 ac_cpp='$CPP $CPPFLAGS'
4074 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4075 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4076 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4077
4078
4079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4080 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4081 if ${ac_cv_path_GREP+:} false; then :
4082   $as_echo_n "(cached) " >&6
4083 else
4084   if test -z "$GREP"; then
4085   ac_path_GREP_found=false
4086   # Loop through the user's path and test for each of PROGNAME-LIST
4087   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4088 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4089 do
4090   IFS=$as_save_IFS
4091   test -z "$as_dir" && as_dir=.
4092     for ac_prog in grep ggrep; do
4093     for ac_exec_ext in '' $ac_executable_extensions; do
4094       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4095       as_fn_executable_p "$ac_path_GREP" || continue
4096 # Check for GNU ac_path_GREP and select it if it is found.
4097   # Check for GNU $ac_path_GREP
4098 case `"$ac_path_GREP" --version 2>&1` in
4099 *GNU*)
4100   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4101 *)
4102   ac_count=0
4103   $as_echo_n 0123456789 >"conftest.in"
4104   while :
4105   do
4106     cat "conftest.in" "conftest.in" >"conftest.tmp"
4107     mv "conftest.tmp" "conftest.in"
4108     cp "conftest.in" "conftest.nl"
4109     $as_echo 'GREP' >> "conftest.nl"
4110     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4111     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4112     as_fn_arith $ac_count + 1 && ac_count=$as_val
4113     if test $ac_count -gt ${ac_path_GREP_max-0}; then
4114       # Best one so far, save it but keep looking for a better one
4115       ac_cv_path_GREP="$ac_path_GREP"
4116       ac_path_GREP_max=$ac_count
4117     fi
4118     # 10*(2^10) chars as input seems more than enough
4119     test $ac_count -gt 10 && break
4120   done
4121   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4122 esac
4123
4124       $ac_path_GREP_found && break 3
4125     done
4126   done
4127   done
4128 IFS=$as_save_IFS
4129   if test -z "$ac_cv_path_GREP"; then
4130     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4131   fi
4132 else
4133   ac_cv_path_GREP=$GREP
4134 fi
4135
4136 fi
4137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4138 $as_echo "$ac_cv_path_GREP" >&6; }
4139  GREP="$ac_cv_path_GREP"
4140
4141
4142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4143 $as_echo_n "checking for egrep... " >&6; }
4144 if ${ac_cv_path_EGREP+:} false; then :
4145   $as_echo_n "(cached) " >&6
4146 else
4147   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4148    then ac_cv_path_EGREP="$GREP -E"
4149    else
4150      if test -z "$EGREP"; then
4151   ac_path_EGREP_found=false
4152   # Loop through the user's path and test for each of PROGNAME-LIST
4153   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4154 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4155 do
4156   IFS=$as_save_IFS
4157   test -z "$as_dir" && as_dir=.
4158     for ac_prog in egrep; do
4159     for ac_exec_ext in '' $ac_executable_extensions; do
4160       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4161       as_fn_executable_p "$ac_path_EGREP" || continue
4162 # Check for GNU ac_path_EGREP and select it if it is found.
4163   # Check for GNU $ac_path_EGREP
4164 case `"$ac_path_EGREP" --version 2>&1` in
4165 *GNU*)
4166   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4167 *)
4168   ac_count=0
4169   $as_echo_n 0123456789 >"conftest.in"
4170   while :
4171   do
4172     cat "conftest.in" "conftest.in" >"conftest.tmp"
4173     mv "conftest.tmp" "conftest.in"
4174     cp "conftest.in" "conftest.nl"
4175     $as_echo 'EGREP' >> "conftest.nl"
4176     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4177     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4178     as_fn_arith $ac_count + 1 && ac_count=$as_val
4179     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4180       # Best one so far, save it but keep looking for a better one
4181       ac_cv_path_EGREP="$ac_path_EGREP"
4182       ac_path_EGREP_max=$ac_count
4183     fi
4184     # 10*(2^10) chars as input seems more than enough
4185     test $ac_count -gt 10 && break
4186   done
4187   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4188 esac
4189
4190       $ac_path_EGREP_found && break 3
4191     done
4192   done
4193   done
4194 IFS=$as_save_IFS
4195   if test -z "$ac_cv_path_EGREP"; then
4196     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4197   fi
4198 else
4199   ac_cv_path_EGREP=$EGREP
4200 fi
4201
4202    fi
4203 fi
4204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4205 $as_echo "$ac_cv_path_EGREP" >&6; }
4206  EGREP="$ac_cv_path_EGREP"
4207
4208
4209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4210 $as_echo_n "checking for ANSI C header files... " >&6; }
4211 if ${ac_cv_header_stdc+:} false; then :
4212   $as_echo_n "(cached) " >&6
4213 else
4214   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4215 /* end confdefs.h.  */
4216 #include <stdlib.h>
4217 #include <stdarg.h>
4218 #include <string.h>
4219 #include <float.h>
4220
4221 int
4222 main ()
4223 {
4224
4225   ;
4226   return 0;
4227 }
4228 _ACEOF
4229 if ac_fn_c_try_compile "$LINENO"; then :
4230   ac_cv_header_stdc=yes
4231 else
4232   ac_cv_header_stdc=no
4233 fi
4234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4235
4236 if test $ac_cv_header_stdc = yes; then
4237   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4238   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4239 /* end confdefs.h.  */
4240 #include <string.h>
4241
4242 _ACEOF
4243 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4244   $EGREP "memchr" >/dev/null 2>&1; then :
4245
4246 else
4247   ac_cv_header_stdc=no
4248 fi
4249 rm -f conftest*
4250
4251 fi
4252
4253 if test $ac_cv_header_stdc = yes; then
4254   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4255   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4256 /* end confdefs.h.  */
4257 #include <stdlib.h>
4258
4259 _ACEOF
4260 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4261   $EGREP "free" >/dev/null 2>&1; then :
4262
4263 else
4264   ac_cv_header_stdc=no
4265 fi
4266 rm -f conftest*
4267
4268 fi
4269
4270 if test $ac_cv_header_stdc = yes; then
4271   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4272   if test "$cross_compiling" = yes; then :
4273   :
4274 else
4275   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4276 /* end confdefs.h.  */
4277 #include <ctype.h>
4278 #include <stdlib.h>
4279 #if ((' ' & 0x0FF) == 0x020)
4280 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4281 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4282 #else
4283 # define ISLOWER(c) \
4284                    (('a' <= (c) && (c) <= 'i') \
4285                      || ('j' <= (c) && (c) <= 'r') \
4286                      || ('s' <= (c) && (c) <= 'z'))
4287 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4288 #endif
4289
4290 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4291 int
4292 main ()
4293 {
4294   int i;
4295   for (i = 0; i < 256; i++)
4296     if (XOR (islower (i), ISLOWER (i))
4297         || toupper (i) != TOUPPER (i))
4298       return 2;
4299   return 0;
4300 }
4301 _ACEOF
4302 if ac_fn_c_try_run "$LINENO"; then :
4303
4304 else
4305   ac_cv_header_stdc=no
4306 fi
4307 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4308   conftest.$ac_objext conftest.beam conftest.$ac_ext
4309 fi
4310
4311 fi
4312 fi
4313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4314 $as_echo "$ac_cv_header_stdc" >&6; }
4315 if test $ac_cv_header_stdc = yes; then
4316
4317 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4318
4319 fi
4320
4321 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4322 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4323                   inttypes.h stdint.h unistd.h
4324 do :
4325   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4326 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4327 "
4328 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4329   cat >>confdefs.h <<_ACEOF
4330 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4331 _ACEOF
4332
4333 fi
4334
4335 done
4336
4337
4338
4339   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4340 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4341   MINIX=yes
4342 else
4343   MINIX=
4344 fi
4345
4346
4347   if test "$MINIX" = yes; then
4348
4349 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4350
4351
4352 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4353
4354
4355 $as_echo "#define _MINIX 1" >>confdefs.h
4356
4357   fi
4358
4359
4360   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4361 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4362 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4363   $as_echo_n "(cached) " >&6
4364 else
4365   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4366 /* end confdefs.h.  */
4367
4368 #         define __EXTENSIONS__ 1
4369           $ac_includes_default
4370 int
4371 main ()
4372 {
4373
4374   ;
4375   return 0;
4376 }
4377 _ACEOF
4378 if ac_fn_c_try_compile "$LINENO"; then :
4379   ac_cv_safe_to_define___extensions__=yes
4380 else
4381   ac_cv_safe_to_define___extensions__=no
4382 fi
4383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4384 fi
4385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4386 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4387   test $ac_cv_safe_to_define___extensions__ = yes &&
4388     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4389
4390   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4391
4392   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4393
4394   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4395
4396   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4397
4398
4399 ac_aux_dir=
4400 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4401   if test -f "$ac_dir/install-sh"; then
4402     ac_aux_dir=$ac_dir
4403     ac_install_sh="$ac_aux_dir/install-sh -c"
4404     break
4405   elif test -f "$ac_dir/install.sh"; then
4406     ac_aux_dir=$ac_dir
4407     ac_install_sh="$ac_aux_dir/install.sh -c"
4408     break
4409   elif test -f "$ac_dir/shtool"; then
4410     ac_aux_dir=$ac_dir
4411     ac_install_sh="$ac_aux_dir/shtool install -c"
4412     break
4413   fi
4414 done
4415 if test -z "$ac_aux_dir"; then
4416   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
4417 fi
4418
4419 # These three variables are undocumented and unsupported,
4420 # and are intended to be withdrawn in a future Autoconf release.
4421 # They can cause serious problems if a builder's source tree is in a directory
4422 # whose full name contains unusual characters.
4423 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
4424 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
4425 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
4426
4427
4428 # Make sure we can run config.sub.
4429 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4430   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4431
4432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4433 $as_echo_n "checking build system type... " >&6; }
4434 if ${ac_cv_build+:} false; then :
4435   $as_echo_n "(cached) " >&6
4436 else
4437   ac_build_alias=$build_alias
4438 test "x$ac_build_alias" = x &&
4439   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4440 test "x$ac_build_alias" = x &&
4441   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4442 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4443   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4444
4445 fi
4446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4447 $as_echo "$ac_cv_build" >&6; }
4448 case $ac_cv_build in
4449 *-*-*) ;;
4450 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4451 esac
4452 build=$ac_cv_build
4453 ac_save_IFS=$IFS; IFS='-'
4454 set x $ac_cv_build
4455 shift
4456 build_cpu=$1
4457 build_vendor=$2
4458 shift; shift
4459 # Remember, the first character of IFS is used to create $*,
4460 # except with old shells:
4461 build_os=$*
4462 IFS=$ac_save_IFS
4463 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4464
4465
4466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4467 $as_echo_n "checking host system type... " >&6; }
4468 if ${ac_cv_host+:} false; then :
4469   $as_echo_n "(cached) " >&6
4470 else
4471   if test "x$host_alias" = x; then
4472   ac_cv_host=$ac_cv_build
4473 else
4474   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4475     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4476 fi
4477
4478 fi
4479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4480 $as_echo "$ac_cv_host" >&6; }
4481 case $ac_cv_host in
4482 *-*-*) ;;
4483 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4484 esac
4485 host=$ac_cv_host
4486 ac_save_IFS=$IFS; IFS='-'
4487 set x $ac_cv_host
4488 shift
4489 host_cpu=$1
4490 host_vendor=$2
4491 shift; shift
4492 # Remember, the first character of IFS is used to create $*,
4493 # except with old shells:
4494 host_os=$*
4495 IFS=$ac_save_IFS
4496 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4497
4498
4499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4500 $as_echo_n "checking target system type... " >&6; }
4501 if ${ac_cv_target+:} false; then :
4502   $as_echo_n "(cached) " >&6
4503 else
4504   if test "x$target_alias" = x; then
4505   ac_cv_target=$ac_cv_host
4506 else
4507   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
4508     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
4509 fi
4510
4511 fi
4512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4513 $as_echo "$ac_cv_target" >&6; }
4514 case $ac_cv_target in
4515 *-*-*) ;;
4516 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4517 esac
4518 target=$ac_cv_target
4519 ac_save_IFS=$IFS; IFS='-'
4520 set x $ac_cv_target
4521 shift
4522 target_cpu=$1
4523 target_vendor=$2
4524 shift; shift
4525 # Remember, the first character of IFS is used to create $*,
4526 # except with old shells:
4527 target_os=$*
4528 IFS=$ac_save_IFS
4529 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4530
4531
4532 # The aliases save the names the user supplied, while $host etc.
4533 # will get canonicalized.
4534 test -n "$target_alias" &&
4535   test "$program_prefix$program_suffix$program_transform_name" = \
4536     NONENONEs,x,x, &&
4537   program_prefix=${target_alias}-
4538
4539 # The tests for host and target for $enable_largefile require
4540 # canonical names.
4541
4542
4543
4544 # As the $enable_largefile decision depends on --enable-plugins we must set it
4545 # even in directories otherwise not depending on the $plugins option.
4546
4547
4548   maybe_plugins=no
4549   for ac_header in dlfcn.h
4550 do :
4551   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
4552 "
4553 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
4554   cat >>confdefs.h <<_ACEOF
4555 #define HAVE_DLFCN_H 1
4556 _ACEOF
4557  maybe_plugins=yes
4558 fi
4559
4560 done
4561
4562   for ac_header in windows.h
4563 do :
4564   ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
4565 "
4566 if test "x$ac_cv_header_windows_h" = xyes; then :
4567   cat >>confdefs.h <<_ACEOF
4568 #define HAVE_WINDOWS_H 1
4569 _ACEOF
4570  maybe_plugins=yes
4571 fi
4572
4573 done
4574
4575
4576   # Check whether --enable-plugins was given.
4577 if test "${enable_plugins+set}" = set; then :
4578   enableval=$enable_plugins; case "${enableval}" in
4579       no) plugins=no ;;
4580       *) plugins=yes
4581          if test "$maybe_plugins" != "yes" ; then
4582            as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
4583          fi ;;
4584      esac
4585 else
4586   plugins=$maybe_plugins
4587
4588 fi
4589
4590   if test "$plugins" = "yes"; then
4591     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
4592 $as_echo_n "checking for library containing dlsym... " >&6; }
4593 if ${ac_cv_search_dlsym+:} false; then :
4594   $as_echo_n "(cached) " >&6
4595 else
4596   ac_func_search_save_LIBS=$LIBS
4597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4598 /* end confdefs.h.  */
4599
4600 /* Override any GCC internal prototype to avoid an error.
4601    Use char because int might match the return type of a GCC
4602    builtin and then its argument prototype would still apply.  */
4603 #ifdef __cplusplus
4604 extern "C"
4605 #endif
4606 char dlsym ();
4607 int
4608 main ()
4609 {
4610 return dlsym ();
4611   ;
4612   return 0;
4613 }
4614 _ACEOF
4615 for ac_lib in '' dl; do
4616   if test -z "$ac_lib"; then
4617     ac_res="none required"
4618   else
4619     ac_res=-l$ac_lib
4620     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
4621   fi
4622   if ac_fn_c_try_link "$LINENO"; then :
4623   ac_cv_search_dlsym=$ac_res
4624 fi
4625 rm -f core conftest.err conftest.$ac_objext \
4626     conftest$ac_exeext
4627   if ${ac_cv_search_dlsym+:} false; then :
4628   break
4629 fi
4630 done
4631 if ${ac_cv_search_dlsym+:} false; then :
4632
4633 else
4634   ac_cv_search_dlsym=no
4635 fi
4636 rm conftest.$ac_ext
4637 LIBS=$ac_func_search_save_LIBS
4638 fi
4639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
4640 $as_echo "$ac_cv_search_dlsym" >&6; }
4641 ac_res=$ac_cv_search_dlsym
4642 if test "$ac_res" != no; then :
4643   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
4644
4645 fi
4646
4647   fi
4648
4649
4650 case "${host}" in
4651   sparc-*-solaris*|i[3-7]86-*-solaris*)
4652     # On native 32bit sparc and ia32 solaris, large-file and procfs support
4653     # are mutually exclusive; and without procfs support, the bfd/ elf module
4654     # cannot provide certain routines such as elfcore_write_prpsinfo
4655     # or elfcore_write_prstatus.  So unless the user explicitly requested
4656     # large-file support through the --enable-largefile switch, disable
4657     # large-file support in favor of procfs support.
4658     test "${target}" = "${host}" -a "x$plugins" = xno \
4659       && : ${enable_largefile="no"}
4660     ;;
4661 esac
4662
4663 # Check whether --enable-largefile was given.
4664 if test "${enable_largefile+set}" = set; then :
4665   enableval=$enable_largefile;
4666 fi
4667
4668 if test "$enable_largefile" != no; then
4669
4670   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
4671 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
4672 if ${ac_cv_sys_largefile_CC+:} false; then :
4673   $as_echo_n "(cached) " >&6
4674 else
4675   ac_cv_sys_largefile_CC=no
4676      if test "$GCC" != yes; then
4677        ac_save_CC=$CC
4678        while :; do
4679          # IRIX 6.2 and later do not support large files by default,
4680          # so use the C compiler's -n32 option if that helps.
4681          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4682 /* end confdefs.h.  */
4683 #include <sys/types.h>
4684  /* Check that off_t can represent 2**63 - 1 correctly.
4685     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4686     since some C++ compilers masquerading as C compilers
4687     incorrectly reject 9223372036854775807.  */
4688 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4689   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4690                        && LARGE_OFF_T % 2147483647 == 1)
4691                       ? 1 : -1];
4692 int
4693 main ()
4694 {
4695
4696   ;
4697   return 0;
4698 }
4699 _ACEOF
4700          if ac_fn_c_try_compile "$LINENO"; then :
4701   break
4702 fi
4703 rm -f core conftest.err conftest.$ac_objext
4704          CC="$CC -n32"
4705          if ac_fn_c_try_compile "$LINENO"; then :
4706   ac_cv_sys_largefile_CC=' -n32'; break
4707 fi
4708 rm -f core conftest.err conftest.$ac_objext
4709          break
4710        done
4711        CC=$ac_save_CC
4712        rm -f conftest.$ac_ext
4713     fi
4714 fi
4715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
4716 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
4717   if test "$ac_cv_sys_largefile_CC" != no; then
4718     CC=$CC$ac_cv_sys_largefile_CC
4719   fi
4720
4721   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
4722 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
4723 if ${ac_cv_sys_file_offset_bits+:} false; then :
4724   $as_echo_n "(cached) " >&6
4725 else
4726   while :; do
4727   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4728 /* end confdefs.h.  */
4729 #include <sys/types.h>
4730  /* Check that off_t can represent 2**63 - 1 correctly.
4731     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4732     since some C++ compilers masquerading as C compilers
4733     incorrectly reject 9223372036854775807.  */
4734 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4735   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4736                        && LARGE_OFF_T % 2147483647 == 1)
4737                       ? 1 : -1];
4738 int
4739 main ()
4740 {
4741
4742   ;
4743   return 0;
4744 }
4745 _ACEOF
4746 if ac_fn_c_try_compile "$LINENO"; then :
4747   ac_cv_sys_file_offset_bits=no; break
4748 fi
4749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4750   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4751 /* end confdefs.h.  */
4752 #define _FILE_OFFSET_BITS 64
4753 #include <sys/types.h>
4754  /* Check that off_t can represent 2**63 - 1 correctly.
4755     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4756     since some C++ compilers masquerading as C compilers
4757     incorrectly reject 9223372036854775807.  */
4758 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4759   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4760                        && LARGE_OFF_T % 2147483647 == 1)
4761                       ? 1 : -1];
4762 int
4763 main ()
4764 {
4765
4766   ;
4767   return 0;
4768 }
4769 _ACEOF
4770 if ac_fn_c_try_compile "$LINENO"; then :
4771   ac_cv_sys_file_offset_bits=64; break
4772 fi
4773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4774   ac_cv_sys_file_offset_bits=unknown
4775   break
4776 done
4777 fi
4778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
4779 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
4780 case $ac_cv_sys_file_offset_bits in #(
4781   no | unknown) ;;
4782   *)
4783 cat >>confdefs.h <<_ACEOF
4784 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
4785 _ACEOF
4786 ;;
4787 esac
4788 rm -rf conftest*
4789   if test $ac_cv_sys_file_offset_bits = unknown; then
4790     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
4791 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
4792 if ${ac_cv_sys_large_files+:} false; then :
4793   $as_echo_n "(cached) " >&6
4794 else
4795   while :; do
4796   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4797 /* end confdefs.h.  */
4798 #include <sys/types.h>
4799  /* Check that off_t can represent 2**63 - 1 correctly.
4800     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4801     since some C++ compilers masquerading as C compilers
4802     incorrectly reject 9223372036854775807.  */
4803 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4804   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4805                        && LARGE_OFF_T % 2147483647 == 1)
4806                       ? 1 : -1];
4807 int
4808 main ()
4809 {
4810
4811   ;
4812   return 0;
4813 }
4814 _ACEOF
4815 if ac_fn_c_try_compile "$LINENO"; then :
4816   ac_cv_sys_large_files=no; break
4817 fi
4818 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4819   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4820 /* end confdefs.h.  */
4821 #define _LARGE_FILES 1
4822 #include <sys/types.h>
4823  /* Check that off_t can represent 2**63 - 1 correctly.
4824     We can't simply define LARGE_OFF_T to be 9223372036854775807,
4825     since some C++ compilers masquerading as C compilers
4826     incorrectly reject 9223372036854775807.  */
4827 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4828   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4829                        && LARGE_OFF_T % 2147483647 == 1)
4830                       ? 1 : -1];
4831 int
4832 main ()
4833 {
4834
4835   ;
4836   return 0;
4837 }
4838 _ACEOF
4839 if ac_fn_c_try_compile "$LINENO"; then :
4840   ac_cv_sys_large_files=1; break
4841 fi
4842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4843   ac_cv_sys_large_files=unknown
4844   break
4845 done
4846 fi
4847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
4848 $as_echo "$ac_cv_sys_large_files" >&6; }
4849 case $ac_cv_sys_large_files in #(
4850   no | unknown) ;;
4851   *)
4852 cat >>confdefs.h <<_ACEOF
4853 #define _LARGE_FILES $ac_cv_sys_large_files
4854 _ACEOF
4855 ;;
4856 esac
4857 rm -rf conftest*
4858   fi
4859
4860
4861 fi
4862
4863
4864
4865
4866
4867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${CC-cc} option to accept ANSI C" >&5
4868 $as_echo_n "checking for ${CC-cc} option to accept ANSI C... " >&6; }
4869 if ${am_cv_prog_cc_stdc+:} false; then :
4870   $as_echo_n "(cached) " >&6
4871 else
4872   am_cv_prog_cc_stdc=no
4873 ac_save_CC="$CC"
4874 # Don't try gcc -ansi; that turns off useful extensions and
4875 # breaks some systems' header files.
4876 # AIX                   -qlanglvl=ansi
4877 # Ultrix and OSF/1      -std1
4878 # HP-UX 10.20 and later -Ae
4879 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4880 # SVR4                  -Xc -D__EXTENSIONS__
4881 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4882 do
4883   CC="$ac_save_CC $ac_arg"
4884   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4885 /* end confdefs.h.  */
4886 #include <stdarg.h>
4887 #include <stdio.h>
4888 #include <sys/types.h>
4889 #include <sys/stat.h>
4890 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4891 struct buf { int x; };
4892 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4893 static char *e (p, i)
4894      char **p;
4895      int i;
4896 {
4897   return p[i];
4898 }
4899 static char *f (char * (*g) (char **, int), char **p, ...)
4900 {
4901   char *s;
4902   va_list v;
4903   va_start (v,p);
4904   s = g (p, va_arg (v,int));
4905   va_end (v);
4906   return s;
4907 }
4908 int test (int i, double x);
4909 struct s1 {int (*f) (int a);};
4910 struct s2 {int (*f) (double a);};
4911 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4912 int argc;
4913 char **argv;
4914
4915 int
4916 main ()
4917 {
4918
4919 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4920
4921   ;
4922   return 0;
4923 }
4924 _ACEOF
4925 if ac_fn_c_try_compile "$LINENO"; then :
4926   am_cv_prog_cc_stdc="$ac_arg"; break
4927 fi
4928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4929 done
4930 CC="$ac_save_CC"
4931
4932 fi
4933
4934 if test -z "$am_cv_prog_cc_stdc"; then
4935   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4936 $as_echo "none needed" >&6; }
4937 else
4938   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_stdc" >&5
4939 $as_echo "$am_cv_prog_cc_stdc" >&6; }
4940 fi
4941 case "x$am_cv_prog_cc_stdc" in
4942   x|xno) ;;
4943   *) CC="$CC $am_cv_prog_cc_stdc" ;;
4944 esac
4945
4946 # Expand $ac_aux_dir to an absolute path.
4947 am_aux_dir=`cd "$ac_aux_dir" && pwd`
4948
4949 if test x"${install_sh+set}" != xset; then
4950   case $am_aux_dir in
4951   *\ * | *\     *)
4952     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4953   *)
4954     install_sh="\${SHELL} $am_aux_dir/install-sh"
4955   esac
4956 fi
4957
4958 # Installed binaries are usually stripped using 'strip' when the user
4959 # run "make install-strip".  However 'strip' might not be the right
4960 # tool to use in cross-compilation environments, therefore Automake
4961 # will honor the 'STRIP' environment variable to overrule this program.
4962 if test "$cross_compiling" != no; then
4963   if test -n "$ac_tool_prefix"; then
4964   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4965 set dummy ${ac_tool_prefix}strip; ac_word=$2
4966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4967 $as_echo_n "checking for $ac_word... " >&6; }
4968 if ${ac_cv_prog_STRIP+:} false; then :
4969   $as_echo_n "(cached) " >&6
4970 else
4971   if test -n "$STRIP"; then
4972   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4973 else
4974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4975 for as_dir in $PATH
4976 do
4977   IFS=$as_save_IFS
4978   test -z "$as_dir" && as_dir=.
4979     for ac_exec_ext in '' $ac_executable_extensions; do
4980   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4981     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4982     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4983     break 2
4984   fi
4985 done
4986   done
4987 IFS=$as_save_IFS
4988
4989 fi
4990 fi
4991 STRIP=$ac_cv_prog_STRIP
4992 if test -n "$STRIP"; then
4993   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
4994 $as_echo "$STRIP" >&6; }
4995 else
4996   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4997 $as_echo "no" >&6; }
4998 fi
4999
5000
5001 fi
5002 if test -z "$ac_cv_prog_STRIP"; then
5003   ac_ct_STRIP=$STRIP
5004   # Extract the first word of "strip", so it can be a program name with args.
5005 set dummy strip; ac_word=$2
5006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5007 $as_echo_n "checking for $ac_word... " >&6; }
5008 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
5009   $as_echo_n "(cached) " >&6
5010 else
5011   if test -n "$ac_ct_STRIP"; then
5012   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5013 else
5014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5015 for as_dir in $PATH
5016 do
5017   IFS=$as_save_IFS
5018   test -z "$as_dir" && as_dir=.
5019     for ac_exec_ext in '' $ac_executable_extensions; do
5020   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5021     ac_cv_prog_ac_ct_STRIP="strip"
5022     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5023     break 2
5024   fi
5025 done
5026   done
5027 IFS=$as_save_IFS
5028
5029 fi
5030 fi
5031 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5032 if test -n "$ac_ct_STRIP"; then
5033   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5034 $as_echo "$ac_ct_STRIP" >&6; }
5035 else
5036   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5037 $as_echo "no" >&6; }
5038 fi
5039
5040   if test "x$ac_ct_STRIP" = x; then
5041     STRIP=":"
5042   else
5043     case $cross_compiling:$ac_tool_warned in
5044 yes:)
5045 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5046 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5047 ac_tool_warned=yes ;;
5048 esac
5049     STRIP=$ac_ct_STRIP
5050   fi
5051 else
5052   STRIP="$ac_cv_prog_STRIP"
5053 fi
5054
5055 fi
5056 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5057
5058
5059 ac_aux_dir=
5060 for ac_dir in .. "$srcdir"/..; do
5061   if test -f "$ac_dir/install-sh"; then
5062     ac_aux_dir=$ac_dir
5063     ac_install_sh="$ac_aux_dir/install-sh -c"
5064     break
5065   elif test -f "$ac_dir/install.sh"; then
5066     ac_aux_dir=$ac_dir
5067     ac_install_sh="$ac_aux_dir/install.sh -c"
5068     break
5069   elif test -f "$ac_dir/shtool"; then
5070     ac_aux_dir=$ac_dir
5071     ac_install_sh="$ac_aux_dir/shtool install -c"
5072     break
5073   fi
5074 done
5075 if test -z "$ac_aux_dir"; then
5076   as_fn_error $? "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
5077 fi
5078
5079 # These three variables are undocumented and unsupported,
5080 # and are intended to be withdrawn in a future Autoconf release.
5081 # They can cause serious problems if a builder's source tree is in a directory
5082 # whose full name contains unusual characters.
5083 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
5084 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
5085 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
5086
5087
5088
5089 test "$program_prefix" != NONE &&
5090   program_transform_name="s&^&$program_prefix&;$program_transform_name"
5091 # Use a double $ so make ignores it.
5092 test "$program_suffix" != NONE &&
5093   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5094 # Double any \ or $.
5095 # By default was `s,x,x', remove it if useless.
5096 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5097 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5098
5099
5100 # We require a C++11 compiler.  Check if one is available, and if
5101 # necessary, set CXX_DIALECT to some -std=xxx switch.
5102
5103   ax_cxx_compile_alternatives="11 0x"    ax_cxx_compile_cxx11_required=true
5104   ac_ext=cpp
5105 ac_cpp='$CXXCPP $CPPFLAGS'
5106 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5107 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5108 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5109   CXX_DIALECT=""
5110   ac_success=no
5111   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5112 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5113 if ${ax_cv_cxx_compile_cxx11+:} false; then :
5114   $as_echo_n "(cached) " >&6
5115 else
5116   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5117 /* end confdefs.h.  */
5118
5119
5120 // If the compiler admits that it is not ready for C++11, why torture it?
5121 // Hopefully, this will speed up the test.
5122
5123 #ifndef __cplusplus
5124
5125 #error "This is not a C++ compiler"
5126
5127 #elif __cplusplus < 201103L
5128
5129 #error "This is not a C++11 compiler"
5130
5131 #else
5132
5133 namespace cxx11
5134 {
5135
5136   namespace test_static_assert
5137   {
5138
5139     template <typename T>
5140     struct check
5141     {
5142       static_assert(sizeof(int) <= sizeof(T), "not big enough");
5143     };
5144
5145   }
5146
5147   namespace test_final_override
5148   {
5149
5150     struct Base
5151     {
5152       virtual void f() {}
5153     };
5154
5155     struct Derived : public Base
5156     {
5157       virtual void f() override {}
5158     };
5159
5160   }
5161
5162   namespace test_double_right_angle_brackets
5163   {
5164
5165     template < typename T >
5166     struct check {};
5167
5168     typedef check<void> single_type;
5169     typedef check<check<void>> double_type;
5170     typedef check<check<check<void>>> triple_type;
5171     typedef check<check<check<check<void>>>> quadruple_type;
5172
5173   }
5174
5175   namespace test_decltype
5176   {
5177
5178     int
5179     f()
5180     {
5181       int a = 1;
5182       decltype(a) b = 2;
5183       return a + b;
5184     }
5185
5186   }
5187
5188   namespace test_type_deduction
5189   {
5190
5191     template < typename T1, typename T2 >
5192     struct is_same
5193     {
5194       static const bool value = false;
5195     };
5196
5197     template < typename T >
5198     struct is_same<T, T>
5199     {
5200       static const bool value = true;
5201     };
5202
5203     template < typename T1, typename T2 >
5204     auto
5205     add(T1 a1, T2 a2) -> decltype(a1 + a2)
5206     {
5207       return a1 + a2;
5208     }
5209
5210     int
5211     test(const int c, volatile int v)
5212     {
5213       static_assert(is_same<int, decltype(0)>::value == true, "");
5214       static_assert(is_same<int, decltype(c)>::value == false, "");
5215       static_assert(is_same<int, decltype(v)>::value == false, "");
5216       auto ac = c;
5217       auto av = v;
5218       auto sumi = ac + av + 'x';
5219       auto sumf = ac + av + 1.0;
5220       static_assert(is_same<int, decltype(ac)>::value == true, "");
5221       static_assert(is_same<int, decltype(av)>::value == true, "");
5222       static_assert(is_same<int, decltype(sumi)>::value == true, "");
5223       static_assert(is_same<int, decltype(sumf)>::value == false, "");
5224       static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5225       return (sumf > 0.0) ? sumi : add(c, v);
5226     }
5227
5228   }
5229
5230   namespace test_noexcept
5231   {
5232
5233     int f() { return 0; }
5234     int g() noexcept { return 0; }
5235
5236     static_assert(noexcept(f()) == false, "");
5237     static_assert(noexcept(g()) == true, "");
5238
5239   }
5240
5241   namespace test_constexpr
5242   {
5243
5244     template < typename CharT >
5245     unsigned long constexpr
5246     strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5247     {
5248       return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5249     }
5250
5251     template < typename CharT >
5252     unsigned long constexpr
5253     strlen_c(const CharT *const s) noexcept
5254     {
5255       return strlen_c_r(s, 0UL);
5256     }
5257
5258     static_assert(strlen_c("") == 0UL, "");
5259     static_assert(strlen_c("1") == 1UL, "");
5260     static_assert(strlen_c("example") == 7UL, "");
5261     static_assert(strlen_c("another\0example") == 7UL, "");
5262
5263   }
5264
5265   namespace test_rvalue_references
5266   {
5267
5268     template < int N >
5269     struct answer
5270     {
5271       static constexpr int value = N;
5272     };
5273
5274     answer<1> f(int&)       { return answer<1>(); }
5275     answer<2> f(const int&) { return answer<2>(); }
5276     answer<3> f(int&&)      { return answer<3>(); }
5277
5278     void
5279     test()
5280     {
5281       int i = 0;
5282       const int c = 0;
5283       static_assert(decltype(f(i))::value == 1, "");
5284       static_assert(decltype(f(c))::value == 2, "");
5285       static_assert(decltype(f(0))::value == 3, "");
5286     }
5287
5288   }
5289
5290   namespace test_uniform_initialization
5291   {
5292
5293     struct test
5294     {
5295       static const int zero {};
5296       static const int one {1};
5297     };
5298
5299     static_assert(test::zero == 0, "");
5300     static_assert(test::one == 1, "");
5301
5302   }
5303
5304   namespace test_lambdas
5305   {
5306
5307     void
5308     test1()
5309     {
5310       auto lambda1 = [](){};
5311       auto lambda2 = lambda1;
5312       lambda1();
5313       lambda2();
5314     }
5315
5316     int
5317     test2()
5318     {
5319       auto a = [](int i, int j){ return i + j; }(1, 2);
5320       auto b = []() -> int { return '0'; }();
5321       auto c = [=](){ return a + b; }();
5322       auto d = [&](){ return c; }();
5323       auto e = [a, &b](int x) mutable {
5324         const auto identity = [](int y){ return y; };
5325         for (auto i = 0; i < a; ++i)
5326           a += b--;
5327         return x + identity(a + b);
5328       }(0);
5329       return a + b + c + d + e;
5330     }
5331
5332     int
5333     test3()
5334     {
5335       const auto nullary = [](){ return 0; };
5336       const auto unary = [](int x){ return x; };
5337       using nullary_t = decltype(nullary);
5338       using unary_t = decltype(unary);
5339       const auto higher1st = [](nullary_t f){ return f(); };
5340       const auto higher2nd = [unary](nullary_t f1){
5341         return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5342       };
5343       return higher1st(nullary) + higher2nd(nullary)(unary);
5344     }
5345
5346   }
5347
5348   namespace test_variadic_templates
5349   {
5350
5351     template <int...>
5352     struct sum;
5353
5354     template <int N0, int... N1toN>
5355     struct sum<N0, N1toN...>
5356     {
5357       static constexpr auto value = N0 + sum<N1toN...>::value;
5358     };
5359
5360     template <>
5361     struct sum<>
5362     {
5363       static constexpr auto value = 0;
5364     };
5365
5366     static_assert(sum<>::value == 0, "");
5367     static_assert(sum<1>::value == 1, "");
5368     static_assert(sum<23>::value == 23, "");
5369     static_assert(sum<1, 2>::value == 3, "");
5370     static_assert(sum<5, 5, 11>::value == 21, "");
5371     static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5372
5373   }
5374
5375   // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5376   // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5377   // because of this.
5378   namespace test_template_alias_sfinae
5379   {
5380
5381     struct foo {};
5382
5383     template<typename T>
5384     using member = typename T::member_type;
5385
5386     template<typename T>
5387     void func(...) {}
5388
5389     template<typename T>
5390     void func(member<T>*) {}
5391
5392     void test();
5393
5394     void test() { func<foo>(0); }
5395
5396   }
5397
5398 }  // namespace cxx11
5399
5400 #endif  // __cplusplus >= 201103L
5401
5402
5403
5404 _ACEOF
5405 if ac_fn_cxx_try_compile "$LINENO"; then :
5406   ax_cv_cxx_compile_cxx11=yes
5407 else
5408   ax_cv_cxx_compile_cxx11=no
5409 fi
5410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5411 fi
5412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
5413 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
5414   if test x$ax_cv_cxx_compile_cxx11 = xyes; then
5415     ac_success=yes
5416   fi
5417
5418     if test x$ac_success = xno; then
5419     for alternative in ${ax_cxx_compile_alternatives}; do
5420       switch="-std=gnu++${alternative}"
5421       cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5422       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5423 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5424 if eval \${$cachevar+:} false; then :
5425   $as_echo_n "(cached) " >&6
5426 else
5427   ac_save_CXX="$CXX"
5428          CXX="$CXX $switch"
5429          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5430 /* end confdefs.h.  */
5431
5432
5433 // If the compiler admits that it is not ready for C++11, why torture it?
5434 // Hopefully, this will speed up the test.
5435
5436 #ifndef __cplusplus
5437
5438 #error "This is not a C++ compiler"
5439
5440 #elif __cplusplus < 201103L
5441
5442 #error "This is not a C++11 compiler"
5443
5444 #else
5445
5446 namespace cxx11
5447 {
5448
5449   namespace test_static_assert
5450   {
5451
5452     template <typename T>
5453     struct check
5454     {
5455       static_assert(sizeof(int) <= sizeof(T), "not big enough");
5456     };
5457
5458   }
5459
5460   namespace test_final_override
5461   {
5462
5463     struct Base
5464     {
5465       virtual void f() {}
5466     };
5467
5468     struct Derived : public Base
5469     {
5470       virtual void f() override {}
5471     };
5472
5473   }
5474
5475   namespace test_double_right_angle_brackets
5476   {
5477
5478     template < typename T >
5479     struct check {};
5480
5481     typedef check<void> single_type;
5482     typedef check<check<void>> double_type;
5483     typedef check<check<check<void>>> triple_type;
5484     typedef check<check<check<check<void>>>> quadruple_type;
5485
5486   }
5487
5488   namespace test_decltype
5489   {
5490
5491     int
5492     f()
5493     {
5494       int a = 1;
5495       decltype(a) b = 2;
5496       return a + b;
5497     }
5498
5499   }
5500
5501   namespace test_type_deduction
5502   {
5503
5504     template < typename T1, typename T2 >
5505     struct is_same
5506     {
5507       static const bool value = false;
5508     };
5509
5510     template < typename T >
5511     struct is_same<T, T>
5512     {
5513       static const bool value = true;
5514     };
5515
5516     template < typename T1, typename T2 >
5517     auto
5518     add(T1 a1, T2 a2) -> decltype(a1 + a2)
5519     {
5520       return a1 + a2;
5521     }
5522
5523     int
5524     test(const int c, volatile int v)
5525     {
5526       static_assert(is_same<int, decltype(0)>::value == true, "");
5527       static_assert(is_same<int, decltype(c)>::value == false, "");
5528       static_assert(is_same<int, decltype(v)>::value == false, "");
5529       auto ac = c;
5530       auto av = v;
5531       auto sumi = ac + av + 'x';
5532       auto sumf = ac + av + 1.0;
5533       static_assert(is_same<int, decltype(ac)>::value == true, "");
5534       static_assert(is_same<int, decltype(av)>::value == true, "");
5535       static_assert(is_same<int, decltype(sumi)>::value == true, "");
5536       static_assert(is_same<int, decltype(sumf)>::value == false, "");
5537       static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5538       return (sumf > 0.0) ? sumi : add(c, v);
5539     }
5540
5541   }
5542
5543   namespace test_noexcept
5544   {
5545
5546     int f() { return 0; }
5547     int g() noexcept { return 0; }
5548
5549     static_assert(noexcept(f()) == false, "");
5550     static_assert(noexcept(g()) == true, "");
5551
5552   }
5553
5554   namespace test_constexpr
5555   {
5556
5557     template < typename CharT >
5558     unsigned long constexpr
5559     strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5560     {
5561       return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5562     }
5563
5564     template < typename CharT >
5565     unsigned long constexpr
5566     strlen_c(const CharT *const s) noexcept
5567     {
5568       return strlen_c_r(s, 0UL);
5569     }
5570
5571     static_assert(strlen_c("") == 0UL, "");
5572     static_assert(strlen_c("1") == 1UL, "");
5573     static_assert(strlen_c("example") == 7UL, "");
5574     static_assert(strlen_c("another\0example") == 7UL, "");
5575
5576   }
5577
5578   namespace test_rvalue_references
5579   {
5580
5581     template < int N >
5582     struct answer
5583     {
5584       static constexpr int value = N;
5585     };
5586
5587     answer<1> f(int&)       { return answer<1>(); }
5588     answer<2> f(const int&) { return answer<2>(); }
5589     answer<3> f(int&&)      { return answer<3>(); }
5590
5591     void
5592     test()
5593     {
5594       int i = 0;
5595       const int c = 0;
5596       static_assert(decltype(f(i))::value == 1, "");
5597       static_assert(decltype(f(c))::value == 2, "");
5598       static_assert(decltype(f(0))::value == 3, "");
5599     }
5600
5601   }
5602
5603   namespace test_uniform_initialization
5604   {
5605
5606     struct test
5607     {
5608       static const int zero {};
5609       static const int one {1};
5610     };
5611
5612     static_assert(test::zero == 0, "");
5613     static_assert(test::one == 1, "");
5614
5615   }
5616
5617   namespace test_lambdas
5618   {
5619
5620     void
5621     test1()
5622     {
5623       auto lambda1 = [](){};
5624       auto lambda2 = lambda1;
5625       lambda1();
5626       lambda2();
5627     }
5628
5629     int
5630     test2()
5631     {
5632       auto a = [](int i, int j){ return i + j; }(1, 2);
5633       auto b = []() -> int { return '0'; }();
5634       auto c = [=](){ return a + b; }();
5635       auto d = [&](){ return c; }();
5636       auto e = [a, &b](int x) mutable {
5637         const auto identity = [](int y){ return y; };
5638         for (auto i = 0; i < a; ++i)
5639           a += b--;
5640         return x + identity(a + b);
5641       }(0);
5642       return a + b + c + d + e;
5643     }
5644
5645     int
5646     test3()
5647     {
5648       const auto nullary = [](){ return 0; };
5649       const auto unary = [](int x){ return x; };
5650       using nullary_t = decltype(nullary);
5651       using unary_t = decltype(unary);
5652       const auto higher1st = [](nullary_t f){ return f(); };
5653       const auto higher2nd = [unary](nullary_t f1){
5654         return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5655       };
5656       return higher1st(nullary) + higher2nd(nullary)(unary);
5657     }
5658
5659   }
5660
5661   namespace test_variadic_templates
5662   {
5663
5664     template <int...>
5665     struct sum;
5666
5667     template <int N0, int... N1toN>
5668     struct sum<N0, N1toN...>
5669     {
5670       static constexpr auto value = N0 + sum<N1toN...>::value;
5671     };
5672
5673     template <>
5674     struct sum<>
5675     {
5676       static constexpr auto value = 0;
5677     };
5678
5679     static_assert(sum<>::value == 0, "");
5680     static_assert(sum<1>::value == 1, "");
5681     static_assert(sum<23>::value == 23, "");
5682     static_assert(sum<1, 2>::value == 3, "");
5683     static_assert(sum<5, 5, 11>::value == 21, "");
5684     static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
5685
5686   }
5687
5688   // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
5689   // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
5690   // because of this.
5691   namespace test_template_alias_sfinae
5692   {
5693
5694     struct foo {};
5695
5696     template<typename T>
5697     using member = typename T::member_type;
5698
5699     template<typename T>
5700     void func(...) {}
5701
5702     template<typename T>
5703     void func(member<T>*) {}
5704
5705     void test();
5706
5707     void test() { func<foo>(0); }
5708
5709   }
5710
5711 }  // namespace cxx11
5712
5713 #endif  // __cplusplus >= 201103L
5714
5715
5716
5717 _ACEOF
5718 if ac_fn_cxx_try_compile "$LINENO"; then :
5719   eval $cachevar=yes
5720 else
5721   eval $cachevar=no
5722 fi
5723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5724          CXX="$ac_save_CXX"
5725 fi
5726 eval ac_res=\$$cachevar
5727                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
5728 $as_echo "$ac_res" >&6; }
5729       if eval test x\$$cachevar = xyes; then
5730         CXX_DIALECT="$switch"
5731         ac_success=yes
5732         break
5733       fi
5734     done
5735   fi
5736
5737     if test x$ac_success = xno; then
5738                 for alternative in ${ax_cxx_compile_alternatives}; do
5739       for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
5740         cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
5741         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
5742 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
5743 if eval \${$cachevar+:} false; then :
5744   $as_echo_n "(cached) " >&6
5745 else
5746   ac_save_CXX="$CXX"
5747            CXX="$CXX $switch"
5748            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5749 /* end confdefs.h.  */
5750
5751
5752 // If the compiler admits that it is not ready for C++11, why torture it?
5753 // Hopefully, this will speed up the test.
5754
5755 #ifndef __cplusplus
5756
5757 #error "This is not a C++ compiler"
5758
5759 #elif __cplusplus < 201103L
5760
5761 #error "This is not a C++11 compiler"
5762
5763 #else
5764
5765 namespace cxx11
5766 {
5767
5768   namespace test_static_assert
5769   {
5770
5771     template <typename T>
5772     struct check
5773     {
5774       static_assert(sizeof(int) <= sizeof(T), "not big enough");
5775     };
5776
5777   }
5778
5779   namespace test_final_override
5780   {
5781
5782     struct Base
5783     {
5784       virtual void f() {}
5785     };
5786
5787     struct Derived : public Base
5788     {
5789       virtual void f() override {}
5790     };
5791
5792   }
5793
5794   namespace test_double_right_angle_brackets
5795   {
5796
5797     template < typename T >
5798     struct check {};
5799
5800     typedef check<void> single_type;
5801     typedef check<check<void>> double_type;
5802     typedef check<check<check<void>>> triple_type;
5803     typedef check<check<check<check<void>>>> quadruple_type;
5804
5805   }
5806
5807   namespace test_decltype
5808   {
5809
5810     int
5811     f()
5812     {
5813       int a = 1;
5814       decltype(a) b = 2;
5815       return a + b;
5816     }
5817
5818   }
5819
5820   namespace test_type_deduction
5821   {
5822
5823     template < typename T1, typename T2 >
5824     struct is_same
5825     {
5826       static const bool value = false;
5827     };
5828
5829     template < typename T >
5830     struct is_same<T, T>
5831     {
5832       static const bool value = true;
5833     };
5834
5835     template < typename T1, typename T2 >
5836     auto
5837     add(T1 a1, T2 a2) -> decltype(a1 + a2)
5838     {
5839       return a1 + a2;
5840     }
5841
5842     int
5843     test(const int c, volatile int v)
5844     {
5845       static_assert(is_same<int, decltype(0)>::value == true, "");
5846       static_assert(is_same<int, decltype(c)>::value == false, "");
5847       static_assert(is_same<int, decltype(v)>::value == false, "");
5848       auto ac = c;
5849       auto av = v;
5850       auto sumi = ac + av + 'x';
5851       auto sumf = ac + av + 1.0;
5852       static_assert(is_same<int, decltype(ac)>::value == true, "");
5853       static_assert(is_same<int, decltype(av)>::value == true, "");
5854       static_assert(is_same<int, decltype(sumi)>::value == true, "");
5855       static_assert(is_same<int, decltype(sumf)>::value == false, "");
5856       static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5857       return (sumf > 0.0) ? sumi : add(c, v);
5858     }
5859
5860   }
5861
5862   namespace test_noexcept
5863   {
5864
5865     int f() { return 0; }
5866     int g() noexcept { return 0; }
5867
5868     static_assert(noexcept(f()) == false, "");
5869     static_assert(noexcept(g()) == true, "");
5870
5871   }
5872
5873   namespace test_constexpr
5874   {
5875
5876     template < typename CharT >
5877     unsigned long constexpr
5878     strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5879     {
5880       return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5881     }
5882
5883     template < typename CharT >
5884     unsigned long constexpr
5885     strlen_c(const CharT *const s) noexcept
5886     {
5887       return strlen_c_r(s, 0UL);
5888     }
5889
5890     static_assert(strlen_c("") == 0UL, "");
5891     static_assert(strlen_c("1") == 1UL, "");
5892     static_assert(strlen_c("example") == 7UL, "");
5893     static_assert(strlen_c("another\0example") == 7UL, "");
5894
5895   }
5896
5897   namespace test_rvalue_references
5898   {
5899
5900     template < int N >
5901     struct answer
5902     {
5903       static constexpr int value = N;
5904     };
5905
5906     answer<1> f(int&)       { return answer<1>(); }
5907     answer<2> f(const int&) { return answer<2>(); }
5908     answer<3> f(int&&)      { return answer<3>(); }
5909
5910     void
5911     test()
5912     {
5913       int i = 0;
5914       const int c = 0;
5915       static_assert(decltype(f(i))::value == 1, "");
5916       static_assert(decltype(f(c))::value == 2, "");
5917       static_assert(decltype(f(0))::value == 3, "");
5918     }
5919
5920   }
5921
5922   namespace test_uniform_initialization
5923   {
5924
5925     struct test
5926     {
5927       static const int zero {};
5928       static const int one {1};
5929     };
5930
5931     static_assert(test::zero == 0, "");
5932     static_assert(test::one == 1, "");
5933
5934   }
5935
5936   namespace test_lambdas
5937   {
5938
5939     void
5940     test1()
5941     {
5942       auto lambda1 = [](){};
5943       auto lambda2 = lambda1;
5944       lambda1();
5945       lambda2();
5946     }
5947
5948     int
5949     test2()
5950     {
5951       auto a = [](int i, int j){ return i + j; }(1, 2);
5952       auto b = []() -> int { return '0'; }();
5953       auto c = [=](){ return a + b; }();
5954       auto d = [&](){ return c; }();
5955       auto e = [a, &b](int x) mutable {
5956         const auto identity = [](int y){ return y; };
5957         for (auto i = 0; i < a; ++i)
5958           a += b--;
5959         return x + identity(a + b);
5960       }(0);
5961       return a + b + c + d + e;
5962     }
5963
5964     int
5965     test3()
5966     {
5967       const auto nullary = [](){ return 0; };
5968       const auto unary = [](int x){ return x; };
5969       using nullary_t = decltype(nullary);
5970       using unary_t = decltype(unary);
5971       const auto higher1st = [](nullary_t f){ return f(); };
5972       const auto higher2nd = [unary](nullary_t f1){
5973         return [unary, f1](unary_t f2){ return f2(unary(f1())); };
5974       };
5975       return higher1st(nullary) + higher2nd(nullary)(unary);
5976     }
5977
5978   }
5979
5980   namespace test_variadic_templates
5981   {
5982
5983     template <int...>
5984     struct sum;
5985
5986     template <int N0, int... N1toN>
5987     struct sum<N0, N1toN...>
5988     {
5989       static constexpr auto value = N0 + sum<N1toN...>::value;
5990     };
5991
5992     template <>
5993     struct sum<>
5994     {
5995       static constexpr auto value = 0;
5996     };
5997
5998     static_assert(sum<>::value == 0, "");
5999     static_assert(sum<1>::value == 1, "");
6000     static_assert(sum<23>::value == 23, "");
6001     static_assert(sum<1, 2>::value == 3, "");
6002     static_assert(sum<5, 5, 11>::value == 21, "");
6003     static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6004
6005   }
6006
6007   // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6008   // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6009   // because of this.
6010   namespace test_template_alias_sfinae
6011   {
6012
6013     struct foo {};
6014
6015     template<typename T>
6016     using member = typename T::member_type;
6017
6018     template<typename T>
6019     void func(...) {}
6020
6021     template<typename T>
6022     void func(member<T>*) {}
6023
6024     void test();
6025
6026     void test() { func<foo>(0); }
6027
6028   }
6029
6030 }  // namespace cxx11
6031
6032 #endif  // __cplusplus >= 201103L
6033
6034
6035
6036 _ACEOF
6037 if ac_fn_cxx_try_compile "$LINENO"; then :
6038   eval $cachevar=yes
6039 else
6040   eval $cachevar=no
6041 fi
6042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6043            CXX="$ac_save_CXX"
6044 fi
6045 eval ac_res=\$$cachevar
6046                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6047 $as_echo "$ac_res" >&6; }
6048         if eval test x\$$cachevar = xyes; then
6049           CXX_DIALECT="$switch"
6050           ac_success=yes
6051           break
6052         fi
6053       done
6054       if test x$ac_success = xyes; then
6055         break
6056       fi
6057     done
6058   fi
6059   ac_ext=c
6060 ac_cpp='$CPP $CPPFLAGS'
6061 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6062 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6063 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6064
6065   if test x$ax_cxx_compile_cxx11_required = xtrue; then
6066     if test x$ac_success = xno; then
6067       as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
6068     fi
6069   fi
6070   if test x$ac_success = xno; then
6071     HAVE_CXX11=0
6072     { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
6073 $as_echo "$as_me: No compiler with C++11 support was found" >&6;}
6074   else
6075     HAVE_CXX11=1
6076
6077 $as_echo "#define HAVE_CXX11 1" >>confdefs.h
6078
6079   fi
6080
6081
6082
6083
6084 # Dependency checking.
6085 rm -rf .tst 2>/dev/null
6086 mkdir .tst 2>/dev/null
6087 if test -d .tst; then
6088   am__leading_dot=.
6089 else
6090   am__leading_dot=_
6091 fi
6092 rmdir .tst 2>/dev/null
6093
6094 DEPDIR="${am__leading_dot}deps"
6095
6096 ac_config_commands="$ac_config_commands depdir"
6097
6098
6099 depcc="$CC"   am_compiler_list=
6100
6101 am_depcomp=$ac_aux_dir/depcomp
6102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6103 $as_echo_n "checking dependency style of $depcc... " >&6; }
6104 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
6105   $as_echo_n "(cached) " >&6
6106 else
6107   if test -f "$am_depcomp"; then
6108   # We make a subdir and do the tests there.  Otherwise we can end up
6109   # making bogus files that we don't know about and never remove.  For
6110   # instance it was reported that on HP-UX the gcc test will end up
6111   # making a dummy file named `D' -- because `-MD' means `put the output
6112   # in D'.
6113   mkdir conftest.dir
6114   # Copy depcomp to subdir because otherwise we won't find it if we're
6115   # using a relative directory.
6116   cp "$am_depcomp" conftest.dir
6117   cd conftest.dir
6118   # We will build objects and dependencies in a subdirectory because
6119   # it helps to detect inapplicable dependency modes.  For instance
6120   # both Tru64's cc and ICC support -MD to output dependencies as a
6121   # side effect of compilation, but ICC will put the dependencies in
6122   # the current directory while Tru64 will put them in the object
6123   # directory.
6124   mkdir sub
6125
6126   am_cv_CC_dependencies_compiler_type=none
6127   if test "$am_compiler_list" = ""; then
6128      am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6129   fi
6130   for depmode in $am_compiler_list; do
6131     if test $depmode = none; then break; fi
6132
6133     $as_echo "$as_me:$LINENO: trying $depmode" >&5
6134     # Setup a source with many dependencies, because some compilers
6135     # like to wrap large dependency lists on column 80 (with \), and
6136     # we should not choose a depcomp mode which is confused by this.
6137     #
6138     # We need to recreate these files for each test, as the compiler may
6139     # overwrite some of them when testing with obscure command lines.
6140     # This happens at least with the AIX C compiler.
6141     : > sub/conftest.c
6142     for i in 1 2 3 4 5 6; do
6143       echo '#include "conftst'$i'.h"' >> sub/conftest.c
6144       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
6145       # Solaris 8's {/usr,}/bin/sh.
6146       touch sub/conftst$i.h
6147     done
6148     echo "include sub/conftest.Po" > confmf
6149
6150     # We check with `-c' and `-o' for the sake of the "dashmstdout"
6151     # mode.  It turns out that the SunPro C++ compiler does not properly
6152     # handle `-M -o', and we need to detect this.
6153     depcmd="depmode=$depmode \
6154        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
6155        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6156        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
6157     echo "| $depcmd" | sed -e 's/  */ /g' >&5
6158     if env $depcmd > conftest.err 2>&1 &&
6159        grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
6160        grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
6161        ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
6162       # icc doesn't choke on unknown options, it will just issue warnings
6163       # or remarks (even with -Werror).  So we grep stderr for any message
6164       # that says an option was ignored or not supported.
6165       # When given -MP, icc 7.0 and 7.1 complain thusly:
6166       #   icc: Command line warning: ignoring option '-M'; no argument required
6167       # The diagnosis changed in icc 8.0:
6168       #   icc: Command line remark: option '-MP' not supported
6169       if (grep 'ignoring option' conftest.err ||
6170           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6171         am_cv_CC_dependencies_compiler_type=$depmode
6172         $as_echo "$as_me:$LINENO: success" >&5
6173         break
6174       fi
6175     fi
6176     $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5
6177     sed -e 's/^/| /' < conftest.err >&5
6178   done
6179
6180   cd ..
6181   rm -rf conftest.dir
6182 else
6183   am_cv_CC_dependencies_compiler_type=none
6184 fi
6185
6186 fi
6187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6188 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6189 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
6190 then as_fn_error $? "no usable dependency style found" "$LINENO" 5
6191 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6192
6193 fi
6194
6195
6196
6197 CONFIG_OBS=
6198 CONFIG_DEPS=
6199 CONFIG_SRCS=
6200 ENABLE_CFLAGS=
6201
6202 CONFIG_ALL=
6203 CONFIG_CLEAN=
6204 CONFIG_INSTALL=
6205 CONFIG_UNINSTALL=
6206
6207 # If we haven't got the data from the intl directory,
6208 # assume NLS is disabled.
6209 USE_NLS=no
6210 LIBINTL=
6211 LIBINTL_DEP=
6212 INCINTL=
6213 XGETTEXT=
6214 GMSGFMT=
6215 POSUB=
6216
6217 if test -f  ../intl/config.intl; then
6218   .  ../intl/config.intl
6219 fi
6220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
6221 $as_echo_n "checking whether NLS is requested... " >&6; }
6222 if test x"$USE_NLS" != xyes; then
6223   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6224 $as_echo "no" >&6; }
6225 else
6226   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6227 $as_echo "yes" >&6; }
6228
6229 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
6230
6231
6232   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
6233 $as_echo_n "checking for catalogs to be installed... " >&6; }
6234   # Look for .po and .gmo files in the source directory.
6235   CATALOGS=
6236   XLINGUAS=
6237   for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
6238     # If there aren't any .gmo files the shell will give us the
6239     # literal string "../path/to/srcdir/po/*.gmo" which has to be
6240     # weeded out.
6241     case "$cat" in *\**)
6242       continue;;
6243     esac
6244     # The quadruple backslash is collapsed to a double backslash
6245     # by the backticks, then collapsed again by the double quotes,
6246     # leaving us with one backslash in the sed expression (right
6247     # before the dot that mustn't act as a wildcard).
6248     cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
6249     lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
6250     # The user is allowed to set LINGUAS to a list of languages to
6251     # install catalogs for.  If it's empty that means "all of them."
6252     if test "x$LINGUAS" = x; then
6253       CATALOGS="$CATALOGS $cat"
6254       XLINGUAS="$XLINGUAS $lang"
6255     else
6256       case "$LINGUAS" in *$lang*)
6257         CATALOGS="$CATALOGS $cat"
6258         XLINGUAS="$XLINGUAS $lang"
6259         ;;
6260       esac
6261     fi
6262   done
6263   LINGUAS="$XLINGUAS"
6264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
6265 $as_echo "$LINGUAS" >&6; }
6266
6267
6268     DATADIRNAME=share
6269
6270   INSTOBJEXT=.mo
6271
6272   GENCAT=gencat
6273
6274   CATOBJEXT=.gmo
6275
6276 fi
6277
6278 localedir='${datadir}/locale'
6279
6280
6281 if test x"$USE_NLS" = xyes; then
6282    CONFIG_ALL="$CONFIG_ALL all-po"
6283    CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
6284    CONFIG_INSTALL="$CONFIG_INSTALL install-po"
6285    CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
6286 fi
6287
6288 PACKAGE=gdb
6289
6290 cat >>confdefs.h <<_ACEOF
6291 #define PACKAGE "$PACKAGE"
6292 _ACEOF
6293
6294
6295
6296 # We never need to detect it in this sub-configure.
6297 # But preserve it for config.status --recheck.
6298
6299
6300
6301 MAKEINFO_EXTRA_FLAGS=""
6302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $MAKEINFO supports @click" >&5
6303 $as_echo_n "checking whether $MAKEINFO supports @click... " >&6; }
6304 if ${gdb_cv_have_makeinfo_click+:} false; then :
6305   $as_echo_n "(cached) " >&6
6306 else
6307   echo '@clicksequence{a @click{} b}' >conftest.texinfo
6308   if eval "$MAKEINFO conftest.texinfo >&5 2>&5"; then
6309     gdb_cv_have_makeinfo_click=yes
6310   else
6311     gdb_cv_have_makeinfo_click=no
6312   fi
6313 fi
6314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_makeinfo_click" >&5
6315 $as_echo "$gdb_cv_have_makeinfo_click" >&6; }
6316 if test x"$gdb_cv_have_makeinfo_click" = xyes; then
6317   MAKEINFO_EXTRA_FLAGS="$MAKEINFO_EXTRA_FLAGS -DHAVE_MAKEINFO_CLICK"
6318 fi
6319
6320
6321
6322
6323 # Check whether --with-separate-debug-dir was given.
6324 if test "${with_separate_debug_dir+set}" = set; then :
6325   withval=$with_separate_debug_dir;
6326     DEBUGDIR=$withval
6327 else
6328   DEBUGDIR=${libdir}/debug
6329 fi
6330
6331
6332   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6333   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6334   ac_define_dir=`eval echo $DEBUGDIR`
6335   ac_define_dir=`eval echo $ac_define_dir`
6336
6337 cat >>confdefs.h <<_ACEOF
6338 #define DEBUGDIR "$ac_define_dir"
6339 _ACEOF
6340
6341
6342
6343
6344   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6345      if test "x$prefix" = xNONE; then
6346         test_prefix=/usr/local
6347      else
6348         test_prefix=$prefix
6349      fi
6350   else
6351      test_prefix=$exec_prefix
6352   fi
6353   value=0
6354   case ${ac_define_dir} in
6355      "${test_prefix}"|"${test_prefix}/"*|\
6356         '${exec_prefix}'|'${exec_prefix}/'*)
6357      value=1
6358      ;;
6359   esac
6360
6361 cat >>confdefs.h <<_ACEOF
6362 #define DEBUGDIR_RELOCATABLE $value
6363 _ACEOF
6364
6365
6366
6367
6368 # We can't pass paths as command line arguments.
6369 # Mingw32 tries to be clever and will convert the paths for us.
6370 # For example -DBINDIR="/usr/local/bin" passed on the command line may get
6371 # converted to -DBINDIR="E:/msys/mingw32/msys/1.0/local/bin".
6372 # This breaks GDB's relocatable path conversions since paths passed in
6373 # config.h would not get so translated, the path prefixes no longer match.
6374
6375   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6376   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6377   ac_define_dir=`eval echo $bindir`
6378   ac_define_dir=`eval echo $ac_define_dir`
6379
6380 cat >>confdefs.h <<_ACEOF
6381 #define BINDIR "$ac_define_dir"
6382 _ACEOF
6383
6384
6385
6386 # GDB's datadir relocation
6387
6388
6389
6390 # Check whether --with-gdb-datadir was given.
6391 if test "${with_gdb_datadir+set}" = set; then :
6392   withval=$with_gdb_datadir;
6393     GDB_DATADIR=$withval
6394 else
6395   GDB_DATADIR=${datadir}/gdb
6396 fi
6397
6398
6399   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6400   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6401   ac_define_dir=`eval echo $GDB_DATADIR`
6402   ac_define_dir=`eval echo $ac_define_dir`
6403
6404 cat >>confdefs.h <<_ACEOF
6405 #define GDB_DATADIR "$ac_define_dir"
6406 _ACEOF
6407
6408
6409
6410
6411   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
6412      if test "x$prefix" = xNONE; then
6413         test_prefix=/usr/local
6414      else
6415         test_prefix=$prefix
6416      fi
6417   else
6418      test_prefix=$exec_prefix
6419   fi
6420   value=0
6421   case ${ac_define_dir} in
6422      "${test_prefix}"|"${test_prefix}/"*|\
6423         '${exec_prefix}'|'${exec_prefix}/'*)
6424      value=1
6425      ;;
6426   esac
6427
6428 cat >>confdefs.h <<_ACEOF
6429 #define GDB_DATADIR_RELOCATABLE $value
6430 _ACEOF
6431
6432
6433
6434
6435
6436 # Check whether --with-relocated-sources was given.
6437 if test "${with_relocated_sources+set}" = set; then :
6438   withval=$with_relocated_sources; reloc_srcdir="${withval}"
6439
6440   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6441   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6442   ac_define_dir=`eval echo $reloc_srcdir`
6443   ac_define_dir=`eval echo $ac_define_dir`
6444
6445 cat >>confdefs.h <<_ACEOF
6446 #define RELOC_SRCDIR "$ac_define_dir"
6447 _ACEOF
6448
6449
6450
6451 fi
6452
6453
6454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load directory" >&5
6455 $as_echo_n "checking for default auto-load directory... " >&6; }
6456
6457 # Check whether --with-auto-load-dir was given.
6458 if test "${with_auto_load_dir+set}" = set; then :
6459   withval=$with_auto_load_dir;
6460 else
6461   with_auto_load_dir='$debugdir:$datadir/auto-load'
6462 fi
6463
6464 escape_dir=`echo $with_auto_load_dir | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6465
6466   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6467   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6468   ac_define_dir=`eval echo $escape_dir`
6469   ac_define_dir=`eval echo $ac_define_dir`
6470
6471 cat >>confdefs.h <<_ACEOF
6472 #define AUTO_LOAD_DIR "$ac_define_dir"
6473 _ACEOF
6474
6475
6476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_dir" >&5
6477 $as_echo "$with_auto_load_dir" >&6; }
6478
6479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default auto-load safe-path" >&5
6480 $as_echo_n "checking for default auto-load safe-path... " >&6; }
6481
6482 # Check whether --with-auto-load-safe-path was given.
6483 if test "${with_auto_load_safe_path+set}" = set; then :
6484   withval=$with_auto_load_safe_path; if test "$with_auto_load_safe_path" = "no"; then
6485      with_auto_load_safe_path="/"
6486      fi
6487 else
6488   with_auto_load_safe_path="$with_auto_load_dir"
6489 fi
6490
6491 escape_dir=`echo $with_auto_load_safe_path | sed -e 's/[$]datadir\>/\\\\\\\\\\\\&/g' -e 's/[$]debugdir\>/\\\\\\\\\\\\&/g'`
6492
6493   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
6494   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6495   ac_define_dir=`eval echo $escape_dir`
6496   ac_define_dir=`eval echo $ac_define_dir`
6497
6498 cat >>confdefs.h <<_ACEOF
6499 #define AUTO_LOAD_SAFE_PATH "$ac_define_dir"
6500 _ACEOF
6501
6502
6503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
6504 $as_echo "$with_auto_load_safe_path" >&6; }
6505
6506
6507
6508 subdirs="$subdirs testsuite"
6509
6510
6511 # Check whether to support alternative target configurations
6512 # Check whether --enable-targets was given.
6513 if test "${enable_targets+set}" = set; then :
6514   enableval=$enable_targets; case "${enableval}" in
6515   yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
6516             ;;
6517   no)       enable_targets= ;;
6518   *)        enable_targets=$enableval ;;
6519 esac
6520 fi
6521
6522
6523 # Check whether to enable 64-bit support on 32-bit hosts
6524 # Check whether --enable-64-bit-bfd was given.
6525 if test "${enable_64_bit_bfd+set}" = set; then :
6526   enableval=$enable_64_bit_bfd; case "${enableval}" in
6527   yes)  want64=true  ;;
6528   no)   want64=false ;;
6529   *)    as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;;
6530 esac
6531 else
6532   want64=false
6533 fi
6534
6535 # Provide defaults for some variables set by the per-host and per-target
6536 # configuration.
6537 gdb_host_obs=posix-hdep.o
6538
6539 if test "${target}" = "${host}"; then
6540   gdb_native=yes
6541 else
6542   gdb_native=no
6543 fi
6544
6545 . $srcdir/configure.host
6546
6547 # Add in the common host objects.
6548 . $srcdir/common/common.host
6549 gdb_host_obs="$gdb_host_obs $common_host_obs"
6550
6551 # Accumulate some settings from configure.tgt over all enabled targets
6552
6553 TARGET_OBS=
6554 all_targets=
6555 HAVE_NATIVE_GCORE_TARGET=
6556
6557 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
6558 do
6559   if test "$targ_alias" = "all"; then
6560     all_targets=true
6561   else
6562     # Canonicalize the secondary target names.
6563     result=`$ac_config_sub $targ_alias 2>/dev/null`
6564     if test -n "$result"; then
6565         targ=$result
6566     else
6567         targ=$targ_alias
6568     fi
6569
6570     . ${srcdir}/configure.tgt
6571
6572     if test -z "${gdb_target_obs}"; then :
6573   as_fn_error $? "configuration ${targ} is unsupported." "$LINENO" 5
6574 fi
6575
6576     # Target-specific object files
6577     for i in ${gdb_target_obs}; do
6578         case " $TARGET_OBS " in
6579         *" ${i} "*) ;;
6580         *)
6581           TARGET_OBS="$TARGET_OBS ${i}"
6582           ;;
6583         esac
6584     done
6585
6586     # Check whether this target needs 64-bit CORE_ADDR
6587     if test x${want64} = xfalse; then
6588       . ${srcdir}/../bfd/config.bfd
6589     fi
6590
6591     # Check whether this target is native and supports gcore.
6592     if test $gdb_native = yes -a "$targ_alias" = "$target_alias" \
6593        && $gdb_have_gcore; then
6594       HAVE_NATIVE_GCORE_TARGET=1
6595     fi
6596   fi
6597 done
6598
6599 if test x${all_targets} = xtrue; then
6600
6601   # We want all 64-bit targets if we either:
6602   #  - run on a 64-bit host  or
6603   #  - already require 64-bit support for some other target  or
6604   #  - the --enable-64-bit-bfd option was supplied
6605   # Otherwise we only support all 32-bit targets.
6606   #
6607   # NOTE: This test must be in sync with the corresponding
6608   #       tests in BFD!
6609
6610   if test x${want64} = xfalse; then
6611     # The cast to long int works around a bug in the HP C Compiler
6612 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6613 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6614 # This bug is HP SR number 8606223364.
6615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
6616 $as_echo_n "checking size of long... " >&6; }
6617 if ${ac_cv_sizeof_long+:} false; then :
6618   $as_echo_n "(cached) " >&6
6619 else
6620   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
6621
6622 else
6623   if test "$ac_cv_type_long" = yes; then
6624      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6625 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6626 as_fn_error 77 "cannot compute sizeof (long)
6627 See \`config.log' for more details" "$LINENO" 5; }
6628    else
6629      ac_cv_sizeof_long=0
6630    fi
6631 fi
6632
6633 fi
6634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
6635 $as_echo "$ac_cv_sizeof_long" >&6; }
6636
6637
6638
6639 cat >>confdefs.h <<_ACEOF
6640 #define SIZEOF_LONG $ac_cv_sizeof_long
6641 _ACEOF
6642
6643
6644     if test "x${ac_cv_sizeof_long}" = "x8"; then
6645       want64=true
6646     fi
6647   fi
6648   if test x${want64} = xtrue; then
6649     TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
6650   else
6651     TARGET_OBS='$(ALL_TARGET_OBS)'
6652   fi
6653 fi
6654
6655
6656
6657
6658 # For other settings, only the main target counts.
6659 gdb_sim=
6660 gdb_osabi=
6661 build_gdbserver=
6662 targ=$target; . ${srcdir}/configure.tgt
6663
6664 # Fetch the default architecture and default target vector from BFD.
6665 targ=$target; . $srcdir/../bfd/config.bfd
6666
6667 # We only want the first architecture, so strip off the others if
6668 # there is more than one.
6669 targ_archs=`echo $targ_archs | sed 's/ .*//'`
6670
6671 if test "x$targ_archs" != x; then
6672
6673 cat >>confdefs.h <<_ACEOF
6674 #define DEFAULT_BFD_ARCH $targ_archs
6675 _ACEOF
6676
6677 fi
6678 if test "x$targ_defvec" != x; then
6679
6680 cat >>confdefs.h <<_ACEOF
6681 #define DEFAULT_BFD_VEC $targ_defvec
6682 _ACEOF
6683
6684 fi
6685
6686 # Enable MI.
6687 # Check whether --enable-gdbmi was given.
6688 if test "${enable_gdbmi+set}" = set; then :
6689   enableval=$enable_gdbmi; case $enableval in
6690     yes | no)
6691       ;;
6692     *)
6693       as_fn_error $? "bad value $enableval for --enable-gdbmi" "$LINENO" 5 ;;
6694   esac
6695 else
6696   enable_gdbmi=yes
6697 fi
6698
6699 if test x"$enable_gdbmi" = xyes; then
6700   if test -d $srcdir/mi; then
6701     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
6702     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
6703     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
6704     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
6705   fi
6706 fi
6707
6708 # Enable TUI.
6709 # Check whether --enable-tui was given.
6710 if test "${enable_tui+set}" = set; then :
6711   enableval=$enable_tui; case $enableval in
6712     yes | no | auto)
6713       ;;
6714     *)
6715       as_fn_error $? "bad value $enableval for --enable-tui" "$LINENO" 5 ;;
6716   esac
6717 else
6718   enable_tui=auto
6719 fi
6720
6721
6722 # Enable gdbtk.
6723 # Check whether --enable-gdbtk was given.
6724 if test "${enable_gdbtk+set}" = set; then :
6725   enableval=$enable_gdbtk; case $enableval in
6726     yes | no)
6727       ;;
6728     *)
6729       as_fn_error $? "bad value $enableval for --enable-gdbtk" "$LINENO" 5 ;;
6730   esac
6731 else
6732   if test -d $srcdir/gdbtk; then
6733     enable_gdbtk=yes
6734   else
6735     enable_gdbtk=no
6736   fi
6737 fi
6738
6739 # We unconditionally disable gdbtk tests on selected platforms.
6740 case $host_os in
6741   go32* | windows*)
6742     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: gdbtk isn't supported on $host; disabling" >&5
6743 $as_echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
6744     enable_gdbtk=no ;;
6745 esac
6746
6747 # Libunwind support for ia64.
6748
6749
6750 # Check whether --with-libunwind-ia64 was given.
6751 if test "${with_libunwind_ia64+set}" = set; then :
6752   withval=$with_libunwind_ia64;
6753 else
6754   with_libunwind_ia64=auto
6755 fi
6756
6757
6758 # Backward compatibility option.
6759 if test "${with_libunwind+set}" = set; then
6760   if test x"$with_libunwind_ia64" != xauto; then
6761     as_fn_error $? "option --with-libunwind is deprecated, use --with-libunwind-ia64" "$LINENO" 5
6762   fi
6763   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&5
6764 $as_echo "$as_me: WARNING: option --with-libunwind is deprecated, use --with-libunwind-ia64" >&2;}
6765   with_libunwind_ia64="$with_libunwind"
6766 fi
6767
6768 case "$with_libunwind_ia64" in
6769   yes | no)
6770     ;;
6771   auto)
6772     for ac_header in libunwind-ia64.h
6773 do :
6774   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
6775 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
6776   cat >>confdefs.h <<_ACEOF
6777 #define HAVE_LIBUNWIND_IA64_H 1
6778 _ACEOF
6779
6780 fi
6781
6782 done
6783
6784     with_libunwind_ia64=$ac_cv_header_libunwind_ia64_h
6785     ;;
6786   *)
6787     as_fn_error $? "bad value $with_libunwind_ia64 for GDB --with-libunwind-ia64 option" "$LINENO" 5
6788     ;;
6789 esac
6790
6791 if test x"$with_libunwind_ia64" = xyes; then
6792   for ac_header in libunwind-ia64.h
6793 do :
6794   ac_fn_c_check_header_mongrel "$LINENO" "libunwind-ia64.h" "ac_cv_header_libunwind_ia64_h" "$ac_includes_default"
6795 if test "x$ac_cv_header_libunwind_ia64_h" = xyes; then :
6796   cat >>confdefs.h <<_ACEOF
6797 #define HAVE_LIBUNWIND_IA64_H 1
6798 _ACEOF
6799
6800 fi
6801
6802 done
6803
6804   if test x"$ac_cv_header_libunwind_ia64_h" != xyes; then
6805     as_fn_error $? "GDB option --with-libunwind-ia64 requires libunwind-ia64.h" "$LINENO" 5
6806   fi
6807   CONFIG_OBS="$CONFIG_OBS ia64-libunwind-tdep.o"
6808   CONFIG_DEPS="$CONFIG_DEPS ia64-libunwind-tdep.o"
6809   CONFIG_SRCS="$CONFIG_SRCS ia64-libunwind-tdep.c"
6810 fi
6811
6812 opt_curses=no
6813
6814 # Check whether --with-curses was given.
6815 if test "${with_curses+set}" = set; then :
6816   withval=$with_curses; opt_curses=$withval
6817 fi
6818
6819
6820 prefer_curses=no
6821 if test "$opt_curses" = "yes"; then
6822   prefer_curses=yes
6823 fi
6824
6825 # Profiling support.
6826 # Check whether --enable-profiling was given.
6827 if test "${enable_profiling+set}" = set; then :
6828   enableval=$enable_profiling; case $enableval in
6829     yes | no)
6830       ;;
6831     *)
6832       as_fn_error $? "bad value $enableval for --enable-profile" "$LINENO" 5 ;;
6833   esac
6834 else
6835   enable_profiling=no
6836 fi
6837
6838
6839 for ac_func in monstartup _mcleanup
6840 do :
6841   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6842 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6843 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6844   cat >>confdefs.h <<_ACEOF
6845 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6846 _ACEOF
6847
6848 fi
6849 done
6850
6851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _etext" >&5
6852 $as_echo_n "checking for _etext... " >&6; }
6853 if ${ac_cv_var__etext+:} false; then :
6854   $as_echo_n "(cached) " >&6
6855 else
6856   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6857 /* end confdefs.h.  */
6858 #include <stdlib.h>
6859 extern char _etext;
6860
6861 int
6862 main ()
6863 {
6864 free (&_etext);
6865   ;
6866   return 0;
6867 }
6868 _ACEOF
6869 if ac_fn_c_try_link "$LINENO"; then :
6870   ac_cv_var__etext=yes
6871 else
6872   ac_cv_var__etext=no
6873 fi
6874 rm -f core conftest.err conftest.$ac_objext \
6875     conftest$ac_exeext conftest.$ac_ext
6876 fi
6877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__etext" >&5
6878 $as_echo "$ac_cv_var__etext" >&6; }
6879 if test $ac_cv_var__etext = yes; then
6880
6881 $as_echo "#define HAVE__ETEXT 1" >>confdefs.h
6882
6883 fi
6884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for etext" >&5
6885 $as_echo_n "checking for etext... " >&6; }
6886 if ${ac_cv_var_etext+:} false; then :
6887   $as_echo_n "(cached) " >&6
6888 else
6889   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6890 /* end confdefs.h.  */
6891 #include <stdlib.h>
6892 extern char etext;
6893
6894 int
6895 main ()
6896 {
6897 free (&etext);
6898   ;
6899   return 0;
6900 }
6901 _ACEOF
6902 if ac_fn_c_try_link "$LINENO"; then :
6903   ac_cv_var_etext=yes
6904 else
6905   ac_cv_var_etext=no
6906 fi
6907 rm -f core conftest.err conftest.$ac_objext \
6908     conftest$ac_exeext conftest.$ac_ext
6909 fi
6910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_etext" >&5
6911 $as_echo "$ac_cv_var_etext" >&6; }
6912 if test $ac_cv_var_etext = yes; then
6913
6914 $as_echo "#define HAVE_ETEXT 1" >>confdefs.h
6915
6916 fi
6917 if test "$enable_profiling" = yes ; then
6918   if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
6919     as_fn_error $? "--enable-profiling requires monstartup and _mcleanup" "$LINENO" 5
6920   fi
6921   PROFILE_CFLAGS=-pg
6922   OLD_CFLAGS="$CFLAGS"
6923   CFLAGS="$CFLAGS $PROFILE_CFLAGS"
6924
6925   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pg" >&5
6926 $as_echo_n "checking whether $CC supports -pg... " >&6; }
6927 if ${ac_cv_cc_supports_pg+:} false; then :
6928   $as_echo_n "(cached) " >&6
6929 else
6930   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6931 /* end confdefs.h.  */
6932
6933 int
6934 main ()
6935 {
6936 int x;
6937   ;
6938   return 0;
6939 }
6940 _ACEOF
6941 if ac_fn_c_try_compile "$LINENO"; then :
6942   ac_cv_cc_supports_pg=yes
6943 else
6944   ac_cv_cc_supports_pg=no
6945 fi
6946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6947 fi
6948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_supports_pg" >&5
6949 $as_echo "$ac_cv_cc_supports_pg" >&6; }
6950
6951   if test $ac_cv_cc_supports_pg = no; then
6952     as_fn_error $? "--enable-profiling requires a compiler which supports -pg" "$LINENO" 5
6953   fi
6954
6955   CFLAGS="$OLD_CFLAGS"
6956 fi
6957
6958 CODESIGN_CERT=
6959 # Check whether --enable-codesign was given.
6960 if test "${enable_codesign+set}" = set; then :
6961   enableval=$enable_codesign; CODESIGN_CERT=$enableval
6962 fi
6963
6964
6965
6966
6967
6968 # Check whether --with-pkgversion was given.
6969 if test "${with_pkgversion+set}" = set; then :
6970   withval=$with_pkgversion; case "$withval" in
6971       yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
6972       no)  PKGVERSION= ;;
6973       *)   PKGVERSION="($withval) " ;;
6974      esac
6975 else
6976   PKGVERSION="(GDB) "
6977
6978 fi
6979
6980
6981
6982
6983
6984 # Check whether --with-bugurl was given.
6985 if test "${with_bugurl+set}" = set; then :
6986   withval=$with_bugurl; case "$withval" in
6987       yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
6988       no)  BUGURL=
6989            ;;
6990       *)   BUGURL="$withval"
6991            ;;
6992      esac
6993 else
6994   BUGURL="http://www.gnu.org/software/gdb/bugs/"
6995
6996 fi
6997
6998   case ${BUGURL} in
6999   "")
7000     REPORT_BUGS_TO=
7001     REPORT_BUGS_TEXI=
7002     ;;
7003   *)
7004     REPORT_BUGS_TO="<$BUGURL>"
7005     REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
7006     ;;
7007   esac;
7008
7009
7010
7011
7012 cat >>confdefs.h <<_ACEOF
7013 #define PKGVERSION "$PKGVERSION"
7014 _ACEOF
7015
7016
7017 cat >>confdefs.h <<_ACEOF
7018 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
7019 _ACEOF
7020
7021
7022 # --------------------- #
7023 # Checks for programs.  #
7024 # --------------------- #
7025
7026 for ac_prog in gawk mawk nawk awk
7027 do
7028   # Extract the first word of "$ac_prog", so it can be a program name with args.
7029 set dummy $ac_prog; ac_word=$2
7030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7031 $as_echo_n "checking for $ac_word... " >&6; }
7032 if ${ac_cv_prog_AWK+:} false; then :
7033   $as_echo_n "(cached) " >&6
7034 else
7035   if test -n "$AWK"; then
7036   ac_cv_prog_AWK="$AWK" # Let the user override the test.
7037 else
7038 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7039 for as_dir in $PATH
7040 do
7041   IFS=$as_save_IFS
7042   test -z "$as_dir" && as_dir=.
7043     for ac_exec_ext in '' $ac_executable_extensions; do
7044   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7045     ac_cv_prog_AWK="$ac_prog"
7046     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7047     break 2
7048   fi
7049 done
7050   done
7051 IFS=$as_save_IFS
7052
7053 fi
7054 fi
7055 AWK=$ac_cv_prog_AWK
7056 if test -n "$AWK"; then
7057   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
7058 $as_echo "$AWK" >&6; }
7059 else
7060   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7061 $as_echo "no" >&6; }
7062 fi
7063
7064
7065   test -n "$AWK" && break
7066 done
7067
7068 # Find a good install program.  We prefer a C program (faster),
7069 # so one script is as good as another.  But avoid the broken or
7070 # incompatible versions:
7071 # SysV /etc/install, /usr/sbin/install
7072 # SunOS /usr/etc/install
7073 # IRIX /sbin/install
7074 # AIX /bin/install
7075 # AmigaOS /C/install, which installs bootblocks on floppy discs
7076 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
7077 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
7078 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
7079 # OS/2's system install, which has a completely different semantic
7080 # ./install, which can be erroneously created by make from ./install.sh.
7081 # Reject install programs that cannot install multiple files.
7082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
7083 $as_echo_n "checking for a BSD-compatible install... " >&6; }
7084 if test -z "$INSTALL"; then
7085 if ${ac_cv_path_install+:} false; then :
7086   $as_echo_n "(cached) " >&6
7087 else
7088   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7089 for as_dir in $PATH
7090 do
7091   IFS=$as_save_IFS
7092   test -z "$as_dir" && as_dir=.
7093     # Account for people who put trailing slashes in PATH elements.
7094 case $as_dir/ in #((
7095   ./ | .// | /[cC]/* | \
7096   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
7097   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
7098   /usr/ucb/* ) ;;
7099   *)
7100     # OSF1 and SCO ODT 3.0 have their own names for install.
7101     # Don't use installbsd from OSF since it installs stuff as root
7102     # by default.
7103     for ac_prog in ginstall scoinst install; do
7104       for ac_exec_ext in '' $ac_executable_extensions; do
7105         if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
7106           if test $ac_prog = install &&
7107             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7108             # AIX install.  It has an incompatible calling convention.
7109             :
7110           elif test $ac_prog = install &&
7111             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7112             # program-specific install script used by HP pwplus--don't use.
7113             :
7114           else
7115             rm -rf conftest.one conftest.two conftest.dir
7116             echo one > conftest.one
7117             echo two > conftest.two
7118             mkdir conftest.dir
7119             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
7120               test -s conftest.one && test -s conftest.two &&
7121               test -s conftest.dir/conftest.one &&
7122               test -s conftest.dir/conftest.two
7123             then
7124               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
7125               break 3
7126             fi
7127           fi
7128         fi
7129       done
7130     done
7131     ;;
7132 esac
7133
7134   done
7135 IFS=$as_save_IFS
7136
7137 rm -rf conftest.one conftest.two conftest.dir
7138
7139 fi
7140   if test "${ac_cv_path_install+set}" = set; then
7141     INSTALL=$ac_cv_path_install
7142   else
7143     # As a last resort, use the slow shell script.  Don't cache a
7144     # value for INSTALL within a source directory, because that will
7145     # break other packages using the cache if that directory is
7146     # removed, or if the value is a relative name.
7147     INSTALL=$ac_install_sh
7148   fi
7149 fi
7150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
7151 $as_echo "$INSTALL" >&6; }
7152
7153 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
7154 # It thinks the first close brace ends the variable substitution.
7155 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
7156
7157 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
7158
7159 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
7160
7161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7162 $as_echo_n "checking whether ln -s works... " >&6; }
7163 LN_S=$as_ln_s
7164 if test "$LN_S" = "ln -s"; then
7165   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7166 $as_echo "yes" >&6; }
7167 else
7168   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7169 $as_echo "no, using $LN_S" >&6; }
7170 fi
7171
7172 if test -n "$ac_tool_prefix"; then
7173   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7174 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7176 $as_echo_n "checking for $ac_word... " >&6; }
7177 if ${ac_cv_prog_RANLIB+:} false; then :
7178   $as_echo_n "(cached) " >&6
7179 else
7180   if test -n "$RANLIB"; then
7181   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7182 else
7183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7184 for as_dir in $PATH
7185 do
7186   IFS=$as_save_IFS
7187   test -z "$as_dir" && as_dir=.
7188     for ac_exec_ext in '' $ac_executable_extensions; do
7189   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7190     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7191     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7192     break 2
7193   fi
7194 done
7195   done
7196 IFS=$as_save_IFS
7197
7198 fi
7199 fi
7200 RANLIB=$ac_cv_prog_RANLIB
7201 if test -n "$RANLIB"; then
7202   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7203 $as_echo "$RANLIB" >&6; }
7204 else
7205   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7206 $as_echo "no" >&6; }
7207 fi
7208
7209
7210 fi
7211 if test -z "$ac_cv_prog_RANLIB"; then
7212   ac_ct_RANLIB=$RANLIB
7213   # Extract the first word of "ranlib", so it can be a program name with args.
7214 set dummy ranlib; ac_word=$2
7215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7216 $as_echo_n "checking for $ac_word... " >&6; }
7217 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
7218   $as_echo_n "(cached) " >&6
7219 else
7220   if test -n "$ac_ct_RANLIB"; then
7221   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7222 else
7223 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7224 for as_dir in $PATH
7225 do
7226   IFS=$as_save_IFS
7227   test -z "$as_dir" && as_dir=.
7228     for ac_exec_ext in '' $ac_executable_extensions; do
7229   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7230     ac_cv_prog_ac_ct_RANLIB="ranlib"
7231     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7232     break 2
7233   fi
7234 done
7235   done
7236 IFS=$as_save_IFS
7237
7238 fi
7239 fi
7240 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7241 if test -n "$ac_ct_RANLIB"; then
7242   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7243 $as_echo "$ac_ct_RANLIB" >&6; }
7244 else
7245   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7246 $as_echo "no" >&6; }
7247 fi
7248
7249   if test "x$ac_ct_RANLIB" = x; then
7250     RANLIB=":"
7251   else
7252     case $cross_compiling:$ac_tool_warned in
7253 yes:)
7254 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7255 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7256 ac_tool_warned=yes ;;
7257 esac
7258     RANLIB=$ac_ct_RANLIB
7259   fi
7260 else
7261   RANLIB="$ac_cv_prog_RANLIB"
7262 fi
7263
7264 for ac_prog in 'bison -y' byacc
7265 do
7266   # Extract the first word of "$ac_prog", so it can be a program name with args.
7267 set dummy $ac_prog; ac_word=$2
7268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7269 $as_echo_n "checking for $ac_word... " >&6; }
7270 if ${ac_cv_prog_YACC+:} false; then :
7271   $as_echo_n "(cached) " >&6
7272 else
7273   if test -n "$YACC"; then
7274   ac_cv_prog_YACC="$YACC" # Let the user override the test.
7275 else
7276 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7277 for as_dir in $PATH
7278 do
7279   IFS=$as_save_IFS
7280   test -z "$as_dir" && as_dir=.
7281     for ac_exec_ext in '' $ac_executable_extensions; do
7282   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7283     ac_cv_prog_YACC="$ac_prog"
7284     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7285     break 2
7286   fi
7287 done
7288   done
7289 IFS=$as_save_IFS
7290
7291 fi
7292 fi
7293 YACC=$ac_cv_prog_YACC
7294 if test -n "$YACC"; then
7295   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
7296 $as_echo "$YACC" >&6; }
7297 else
7298   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7299 $as_echo "no" >&6; }
7300 fi
7301
7302
7303   test -n "$YACC" && break
7304 done
7305 test -n "$YACC" || YACC="yacc"
7306
7307
7308 if test -n "$ac_tool_prefix"; then
7309   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7310 set dummy ${ac_tool_prefix}ar; ac_word=$2
7311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7312 $as_echo_n "checking for $ac_word... " >&6; }
7313 if ${ac_cv_prog_AR+:} false; then :
7314   $as_echo_n "(cached) " >&6
7315 else
7316   if test -n "$AR"; then
7317   ac_cv_prog_AR="$AR" # Let the user override the test.
7318 else
7319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7320 for as_dir in $PATH
7321 do
7322   IFS=$as_save_IFS
7323   test -z "$as_dir" && as_dir=.
7324     for ac_exec_ext in '' $ac_executable_extensions; do
7325   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7326     ac_cv_prog_AR="${ac_tool_prefix}ar"
7327     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7328     break 2
7329   fi
7330 done
7331   done
7332 IFS=$as_save_IFS
7333
7334 fi
7335 fi
7336 AR=$ac_cv_prog_AR
7337 if test -n "$AR"; then
7338   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
7339 $as_echo "$AR" >&6; }
7340 else
7341   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7342 $as_echo "no" >&6; }
7343 fi
7344
7345
7346 fi
7347 if test -z "$ac_cv_prog_AR"; then
7348   ac_ct_AR=$AR
7349   # Extract the first word of "ar", so it can be a program name with args.
7350 set dummy ar; ac_word=$2
7351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7352 $as_echo_n "checking for $ac_word... " >&6; }
7353 if ${ac_cv_prog_ac_ct_AR+:} false; then :
7354   $as_echo_n "(cached) " >&6
7355 else
7356   if test -n "$ac_ct_AR"; then
7357   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7358 else
7359 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7360 for as_dir in $PATH
7361 do
7362   IFS=$as_save_IFS
7363   test -z "$as_dir" && as_dir=.
7364     for ac_exec_ext in '' $ac_executable_extensions; do
7365   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7366     ac_cv_prog_ac_ct_AR="ar"
7367     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7368     break 2
7369   fi
7370 done
7371   done
7372 IFS=$as_save_IFS
7373
7374 fi
7375 fi
7376 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7377 if test -n "$ac_ct_AR"; then
7378   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
7379 $as_echo "$ac_ct_AR" >&6; }
7380 else
7381   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7382 $as_echo "no" >&6; }
7383 fi
7384
7385   if test "x$ac_ct_AR" = x; then
7386     AR=""
7387   else
7388     case $cross_compiling:$ac_tool_warned in
7389 yes:)
7390 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7391 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7392 ac_tool_warned=yes ;;
7393 esac
7394     AR=$ac_ct_AR
7395   fi
7396 else
7397   AR="$ac_cv_prog_AR"
7398 fi
7399
7400 if test -n "$ac_tool_prefix"; then
7401   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
7402 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
7403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7404 $as_echo_n "checking for $ac_word... " >&6; }
7405 if ${ac_cv_prog_DLLTOOL+:} false; then :
7406   $as_echo_n "(cached) " >&6
7407 else
7408   if test -n "$DLLTOOL"; then
7409   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
7410 else
7411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7412 for as_dir in $PATH
7413 do
7414   IFS=$as_save_IFS
7415   test -z "$as_dir" && as_dir=.
7416     for ac_exec_ext in '' $ac_executable_extensions; do
7417   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7418     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
7419     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7420     break 2
7421   fi
7422 done
7423   done
7424 IFS=$as_save_IFS
7425
7426 fi
7427 fi
7428 DLLTOOL=$ac_cv_prog_DLLTOOL
7429 if test -n "$DLLTOOL"; then
7430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
7431 $as_echo "$DLLTOOL" >&6; }
7432 else
7433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7434 $as_echo "no" >&6; }
7435 fi
7436
7437
7438 fi
7439 if test -z "$ac_cv_prog_DLLTOOL"; then
7440   ac_ct_DLLTOOL=$DLLTOOL
7441   # Extract the first word of "dlltool", so it can be a program name with args.
7442 set dummy dlltool; ac_word=$2
7443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7444 $as_echo_n "checking for $ac_word... " >&6; }
7445 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
7446   $as_echo_n "(cached) " >&6
7447 else
7448   if test -n "$ac_ct_DLLTOOL"; then
7449   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
7450 else
7451 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7452 for as_dir in $PATH
7453 do
7454   IFS=$as_save_IFS
7455   test -z "$as_dir" && as_dir=.
7456     for ac_exec_ext in '' $ac_executable_extensions; do
7457   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7458     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
7459     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7460     break 2
7461   fi
7462 done
7463   done
7464 IFS=$as_save_IFS
7465
7466 fi
7467 fi
7468 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
7469 if test -n "$ac_ct_DLLTOOL"; then
7470   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
7471 $as_echo "$ac_ct_DLLTOOL" >&6; }
7472 else
7473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7474 $as_echo "no" >&6; }
7475 fi
7476
7477   if test "x$ac_ct_DLLTOOL" = x; then
7478     DLLTOOL=""
7479   else
7480     case $cross_compiling:$ac_tool_warned in
7481 yes:)
7482 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7483 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7484 ac_tool_warned=yes ;;
7485 esac
7486     DLLTOOL=$ac_ct_DLLTOOL
7487   fi
7488 else
7489   DLLTOOL="$ac_cv_prog_DLLTOOL"
7490 fi
7491
7492 if test -n "$ac_tool_prefix"; then
7493   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
7494 set dummy ${ac_tool_prefix}windres; ac_word=$2
7495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7496 $as_echo_n "checking for $ac_word... " >&6; }
7497 if ${ac_cv_prog_WINDRES+:} false; then :
7498   $as_echo_n "(cached) " >&6
7499 else
7500   if test -n "$WINDRES"; then
7501   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
7502 else
7503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7504 for as_dir in $PATH
7505 do
7506   IFS=$as_save_IFS
7507   test -z "$as_dir" && as_dir=.
7508     for ac_exec_ext in '' $ac_executable_extensions; do
7509   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7510     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
7511     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7512     break 2
7513   fi
7514 done
7515   done
7516 IFS=$as_save_IFS
7517
7518 fi
7519 fi
7520 WINDRES=$ac_cv_prog_WINDRES
7521 if test -n "$WINDRES"; then
7522   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
7523 $as_echo "$WINDRES" >&6; }
7524 else
7525   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7526 $as_echo "no" >&6; }
7527 fi
7528
7529
7530 fi
7531 if test -z "$ac_cv_prog_WINDRES"; then
7532   ac_ct_WINDRES=$WINDRES
7533   # Extract the first word of "windres", so it can be a program name with args.
7534 set dummy windres; ac_word=$2
7535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7536 $as_echo_n "checking for $ac_word... " >&6; }
7537 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
7538   $as_echo_n "(cached) " >&6
7539 else
7540   if test -n "$ac_ct_WINDRES"; then
7541   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
7542 else
7543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7544 for as_dir in $PATH
7545 do
7546   IFS=$as_save_IFS
7547   test -z "$as_dir" && as_dir=.
7548     for ac_exec_ext in '' $ac_executable_extensions; do
7549   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7550     ac_cv_prog_ac_ct_WINDRES="windres"
7551     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7552     break 2
7553   fi
7554 done
7555   done
7556 IFS=$as_save_IFS
7557
7558 fi
7559 fi
7560 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
7561 if test -n "$ac_ct_WINDRES"; then
7562   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
7563 $as_echo "$ac_ct_WINDRES" >&6; }
7564 else
7565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7566 $as_echo "no" >&6; }
7567 fi
7568
7569   if test "x$ac_ct_WINDRES" = x; then
7570     WINDRES=""
7571   else
7572     case $cross_compiling:$ac_tool_warned in
7573 yes:)
7574 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7575 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7576 ac_tool_warned=yes ;;
7577 esac
7578     WINDRES=$ac_ct_WINDRES
7579   fi
7580 else
7581   WINDRES="$ac_cv_prog_WINDRES"
7582 fi
7583
7584
7585 case $host_os in
7586   gnu*)
7587     # Needed for GNU Hurd hosts.
7588     if test -n "$ac_tool_prefix"; then
7589   # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
7590 set dummy ${ac_tool_prefix}mig; ac_word=$2
7591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7592 $as_echo_n "checking for $ac_word... " >&6; }
7593 if ${ac_cv_prog_MIG+:} false; then :
7594   $as_echo_n "(cached) " >&6
7595 else
7596   if test -n "$MIG"; then
7597   ac_cv_prog_MIG="$MIG" # Let the user override the test.
7598 else
7599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7600 for as_dir in $PATH
7601 do
7602   IFS=$as_save_IFS
7603   test -z "$as_dir" && as_dir=.
7604     for ac_exec_ext in '' $ac_executable_extensions; do
7605   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7606     ac_cv_prog_MIG="${ac_tool_prefix}mig"
7607     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7608     break 2
7609   fi
7610 done
7611   done
7612 IFS=$as_save_IFS
7613
7614 fi
7615 fi
7616 MIG=$ac_cv_prog_MIG
7617 if test -n "$MIG"; then
7618   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MIG" >&5
7619 $as_echo "$MIG" >&6; }
7620 else
7621   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7622 $as_echo "no" >&6; }
7623 fi
7624
7625
7626 fi
7627 if test -z "$ac_cv_prog_MIG"; then
7628   ac_ct_MIG=$MIG
7629   # Extract the first word of "mig", so it can be a program name with args.
7630 set dummy mig; ac_word=$2
7631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7632 $as_echo_n "checking for $ac_word... " >&6; }
7633 if ${ac_cv_prog_ac_ct_MIG+:} false; then :
7634   $as_echo_n "(cached) " >&6
7635 else
7636   if test -n "$ac_ct_MIG"; then
7637   ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
7638 else
7639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7640 for as_dir in $PATH
7641 do
7642   IFS=$as_save_IFS
7643   test -z "$as_dir" && as_dir=.
7644     for ac_exec_ext in '' $ac_executable_extensions; do
7645   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7646     ac_cv_prog_ac_ct_MIG="mig"
7647     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7648     break 2
7649   fi
7650 done
7651   done
7652 IFS=$as_save_IFS
7653
7654 fi
7655 fi
7656 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
7657 if test -n "$ac_ct_MIG"; then
7658   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MIG" >&5
7659 $as_echo "$ac_ct_MIG" >&6; }
7660 else
7661   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7662 $as_echo "no" >&6; }
7663 fi
7664
7665   if test "x$ac_ct_MIG" = x; then
7666     MIG=""
7667   else
7668     case $cross_compiling:$ac_tool_warned in
7669 yes:)
7670 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7671 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7672 ac_tool_warned=yes ;;
7673 esac
7674     MIG=$ac_ct_MIG
7675   fi
7676 else
7677   MIG="$ac_cv_prog_MIG"
7678 fi
7679
7680     if test x"$MIG" = x; then
7681       as_fn_error $? "MIG not found but required for $host hosts" "$LINENO" 5
7682     fi
7683     ;;
7684 esac
7685
7686 # ---------------------- #
7687 # Checks for libraries.  #
7688 # ---------------------- #
7689
7690 # We might need to link with -lm; most simulators need it.
7691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
7692 $as_echo_n "checking for main in -lm... " >&6; }
7693 if ${ac_cv_lib_m_main+:} false; then :
7694   $as_echo_n "(cached) " >&6
7695 else
7696   ac_check_lib_save_LIBS=$LIBS
7697 LIBS="-lm  $LIBS"
7698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7699 /* end confdefs.h.  */
7700
7701
7702 int
7703 main ()
7704 {
7705 return main ();
7706   ;
7707   return 0;
7708 }
7709 _ACEOF
7710 if ac_fn_c_try_link "$LINENO"; then :
7711   ac_cv_lib_m_main=yes
7712 else
7713   ac_cv_lib_m_main=no
7714 fi
7715 rm -f core conftest.err conftest.$ac_objext \
7716     conftest$ac_exeext conftest.$ac_ext
7717 LIBS=$ac_check_lib_save_LIBS
7718 fi
7719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
7720 $as_echo "$ac_cv_lib_m_main" >&6; }
7721 if test "x$ac_cv_lib_m_main" = xyes; then :
7722   cat >>confdefs.h <<_ACEOF
7723 #define HAVE_LIBM 1
7724 _ACEOF
7725
7726   LIBS="-lm $LIBS"
7727
7728 fi
7729
7730
7731 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
7732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
7733 $as_echo_n "checking for library containing gethostbyname... " >&6; }
7734 if ${ac_cv_search_gethostbyname+:} false; then :
7735   $as_echo_n "(cached) " >&6
7736 else
7737   ac_func_search_save_LIBS=$LIBS
7738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7739 /* end confdefs.h.  */
7740
7741 /* Override any GCC internal prototype to avoid an error.
7742    Use char because int might match the return type of a GCC
7743    builtin and then its argument prototype would still apply.  */
7744 #ifdef __cplusplus
7745 extern "C"
7746 #endif
7747 char gethostbyname ();
7748 int
7749 main ()
7750 {
7751 return gethostbyname ();
7752   ;
7753   return 0;
7754 }
7755 _ACEOF
7756 for ac_lib in '' nsl; do
7757   if test -z "$ac_lib"; then
7758     ac_res="none required"
7759   else
7760     ac_res=-l$ac_lib
7761     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7762   fi
7763   if ac_fn_c_try_link "$LINENO"; then :
7764   ac_cv_search_gethostbyname=$ac_res
7765 fi
7766 rm -f core conftest.err conftest.$ac_objext \
7767     conftest$ac_exeext
7768   if ${ac_cv_search_gethostbyname+:} false; then :
7769   break
7770 fi
7771 done
7772 if ${ac_cv_search_gethostbyname+:} false; then :
7773
7774 else
7775   ac_cv_search_gethostbyname=no
7776 fi
7777 rm conftest.$ac_ext
7778 LIBS=$ac_func_search_save_LIBS
7779 fi
7780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
7781 $as_echo "$ac_cv_search_gethostbyname" >&6; }
7782 ac_res=$ac_cv_search_gethostbyname
7783 if test "$ac_res" != no; then :
7784   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7785
7786 fi
7787
7788
7789 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
7790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socketpair" >&5
7791 $as_echo_n "checking for library containing socketpair... " >&6; }
7792 if ${ac_cv_search_socketpair+:} false; then :
7793   $as_echo_n "(cached) " >&6
7794 else
7795   ac_func_search_save_LIBS=$LIBS
7796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7797 /* end confdefs.h.  */
7798
7799 /* Override any GCC internal prototype to avoid an error.
7800    Use char because int might match the return type of a GCC
7801    builtin and then its argument prototype would still apply.  */
7802 #ifdef __cplusplus
7803 extern "C"
7804 #endif
7805 char socketpair ();
7806 int
7807 main ()
7808 {
7809 return socketpair ();
7810   ;
7811   return 0;
7812 }
7813 _ACEOF
7814 for ac_lib in '' socket; do
7815   if test -z "$ac_lib"; then
7816     ac_res="none required"
7817   else
7818     ac_res=-l$ac_lib
7819     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7820   fi
7821   if ac_fn_c_try_link "$LINENO"; then :
7822   ac_cv_search_socketpair=$ac_res
7823 fi
7824 rm -f core conftest.err conftest.$ac_objext \
7825     conftest$ac_exeext
7826   if ${ac_cv_search_socketpair+:} false; then :
7827   break
7828 fi
7829 done
7830 if ${ac_cv_search_socketpair+:} false; then :
7831
7832 else
7833   ac_cv_search_socketpair=no
7834 fi
7835 rm conftest.$ac_ext
7836 LIBS=$ac_func_search_save_LIBS
7837 fi
7838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socketpair" >&5
7839 $as_echo "$ac_cv_search_socketpair" >&6; }
7840 ac_res=$ac_cv_search_socketpair
7841 if test "$ac_res" != no; then :
7842   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7843
7844 fi
7845
7846
7847 # Link in zlib if we can.  This allows us to read compressed debug sections.
7848
7849   # Use the system's zlib library.
7850   zlibdir="-L\$(top_builddir)/../zlib"
7851   zlibinc="-I\$(top_srcdir)/../zlib"
7852
7853 # Check whether --with-system-zlib was given.
7854 if test "${with_system_zlib+set}" = set; then :
7855   withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
7856     zlibdir=
7857     zlibinc=
7858   fi
7859
7860 fi
7861
7862
7863
7864
7865
7866 # On FreeBSD we may need libutil for kinfo_getvmmap (used by fbsd-nat.c).
7867 # On GNU/kFreeBSD systems, FreeBSD libutil is renamed to libutil-freebsd.
7868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getvmmap" >&5
7869 $as_echo_n "checking for library containing kinfo_getvmmap... " >&6; }
7870 if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7871   $as_echo_n "(cached) " >&6
7872 else
7873   ac_func_search_save_LIBS=$LIBS
7874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7875 /* end confdefs.h.  */
7876
7877 /* Override any GCC internal prototype to avoid an error.
7878    Use char because int might match the return type of a GCC
7879    builtin and then its argument prototype would still apply.  */
7880 #ifdef __cplusplus
7881 extern "C"
7882 #endif
7883 char kinfo_getvmmap ();
7884 int
7885 main ()
7886 {
7887 return kinfo_getvmmap ();
7888   ;
7889   return 0;
7890 }
7891 _ACEOF
7892 for ac_lib in '' util util-freebsd; do
7893   if test -z "$ac_lib"; then
7894     ac_res="none required"
7895   else
7896     ac_res=-l$ac_lib
7897     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7898   fi
7899   if ac_fn_c_try_link "$LINENO"; then :
7900   ac_cv_search_kinfo_getvmmap=$ac_res
7901 fi
7902 rm -f core conftest.err conftest.$ac_objext \
7903     conftest$ac_exeext
7904   if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7905   break
7906 fi
7907 done
7908 if ${ac_cv_search_kinfo_getvmmap+:} false; then :
7909
7910 else
7911   ac_cv_search_kinfo_getvmmap=no
7912 fi
7913 rm conftest.$ac_ext
7914 LIBS=$ac_func_search_save_LIBS
7915 fi
7916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getvmmap" >&5
7917 $as_echo "$ac_cv_search_kinfo_getvmmap" >&6; }
7918 ac_res=$ac_cv_search_kinfo_getvmmap
7919 if test "$ac_res" != no; then :
7920   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7921
7922 $as_echo "#define HAVE_KINFO_GETVMMAP 1" >>confdefs.h
7923
7924 fi
7925
7926
7927 # fbsd-nat.c can also use kinfo_getfile.
7928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kinfo_getfile" >&5
7929 $as_echo_n "checking for library containing kinfo_getfile... " >&6; }
7930 if ${ac_cv_search_kinfo_getfile+:} false; then :
7931   $as_echo_n "(cached) " >&6
7932 else
7933   ac_func_search_save_LIBS=$LIBS
7934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7935 /* end confdefs.h.  */
7936
7937 /* Override any GCC internal prototype to avoid an error.
7938    Use char because int might match the return type of a GCC
7939    builtin and then its argument prototype would still apply.  */
7940 #ifdef __cplusplus
7941 extern "C"
7942 #endif
7943 char kinfo_getfile ();
7944 int
7945 main ()
7946 {
7947 return kinfo_getfile ();
7948   ;
7949   return 0;
7950 }
7951 _ACEOF
7952 for ac_lib in '' util util-freebsd; do
7953   if test -z "$ac_lib"; then
7954     ac_res="none required"
7955   else
7956     ac_res=-l$ac_lib
7957     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7958   fi
7959   if ac_fn_c_try_link "$LINENO"; then :
7960   ac_cv_search_kinfo_getfile=$ac_res
7961 fi
7962 rm -f core conftest.err conftest.$ac_objext \
7963     conftest$ac_exeext
7964   if ${ac_cv_search_kinfo_getfile+:} false; then :
7965   break
7966 fi
7967 done
7968 if ${ac_cv_search_kinfo_getfile+:} false; then :
7969
7970 else
7971   ac_cv_search_kinfo_getfile=no
7972 fi
7973 rm conftest.$ac_ext
7974 LIBS=$ac_func_search_save_LIBS
7975 fi
7976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kinfo_getfile" >&5
7977 $as_echo "$ac_cv_search_kinfo_getfile" >&6; }
7978 ac_res=$ac_cv_search_kinfo_getfile
7979 if test "$ac_res" != no; then :
7980   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7981
7982 $as_echo "#define HAVE_KINFO_GETFILE 1" >>confdefs.h
7983
7984 fi
7985
7986
7987
7988       if test "X$prefix" = "XNONE"; then
7989     acl_final_prefix="$ac_default_prefix"
7990   else
7991     acl_final_prefix="$prefix"
7992   fi
7993   if test "X$exec_prefix" = "XNONE"; then
7994     acl_final_exec_prefix='${prefix}'
7995   else
7996     acl_final_exec_prefix="$exec_prefix"
7997   fi
7998   acl_save_prefix="$prefix"
7999   prefix="$acl_final_prefix"
8000   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8001   prefix="$acl_save_prefix"
8002
8003
8004 # Check whether --with-gnu-ld was given.
8005 if test "${with_gnu_ld+set}" = set; then :
8006   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8007 else
8008   with_gnu_ld=no
8009 fi
8010
8011 # Prepare PATH_SEPARATOR.
8012 # The user is always right.
8013 if test "${PATH_SEPARATOR+set}" != set; then
8014   echo "#! /bin/sh" >conf$$.sh
8015   echo  "exit 0"   >>conf$$.sh
8016   chmod +x conf$$.sh
8017   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
8018     PATH_SEPARATOR=';'
8019   else
8020     PATH_SEPARATOR=:
8021   fi
8022   rm -f conf$$.sh
8023 fi
8024 ac_prog=ld
8025 if test "$GCC" = yes; then
8026   # Check if gcc -print-prog-name=ld gives a path.
8027   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8028 $as_echo_n "checking for ld used by GCC... " >&6; }
8029   case $host in
8030   *-*-mingw*)
8031     # gcc leaves a trailing carriage return which upsets mingw
8032     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8033   *)
8034     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8035   esac
8036   case $ac_prog in
8037     # Accept absolute paths.
8038     [\\/]* | [A-Za-z]:[\\/]*)
8039       re_direlt='/[^/][^/]*/\.\./'
8040       # Canonicalize the path of ld
8041       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8042       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8043         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8044       done
8045       test -z "$LD" && LD="$ac_prog"
8046       ;;
8047   "")
8048     # If it fails, then pretend we aren't using GCC.
8049     ac_prog=ld
8050     ;;
8051   *)
8052     # If it is relative, then search for the first ld in PATH.
8053     with_gnu_ld=unknown
8054     ;;
8055   esac
8056 elif test "$with_gnu_ld" = yes; then
8057   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8058 $as_echo_n "checking for GNU ld... " >&6; }
8059 else
8060   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8061 $as_echo_n "checking for non-GNU ld... " >&6; }
8062 fi
8063 if ${acl_cv_path_LD+:} false; then :
8064   $as_echo_n "(cached) " >&6
8065 else
8066   if test -z "$LD"; then
8067   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8068   for ac_dir in $PATH; do
8069     test -z "$ac_dir" && ac_dir=.
8070     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8071       acl_cv_path_LD="$ac_dir/$ac_prog"
8072       # Check to see if the program is GNU ld.  I'd rather use --version,
8073       # but apparently some GNU ld's only accept -v.
8074       # Break only if it was the GNU/non-GNU ld that we prefer.
8075       if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8076         test "$with_gnu_ld" != no && break
8077       else
8078         test "$with_gnu_ld" != yes && break
8079       fi
8080     fi
8081   done
8082   IFS="$ac_save_ifs"
8083 else
8084   acl_cv_path_LD="$LD" # Let the user override the test with a path.
8085 fi
8086 fi
8087
8088 LD="$acl_cv_path_LD"
8089 if test -n "$LD"; then
8090   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8091 $as_echo "$LD" >&6; }
8092 else
8093   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8094 $as_echo "no" >&6; }
8095 fi
8096 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8098 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8099 if ${acl_cv_prog_gnu_ld+:} false; then :
8100   $as_echo_n "(cached) " >&6
8101 else
8102   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8103 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8104   acl_cv_prog_gnu_ld=yes
8105 else
8106   acl_cv_prog_gnu_ld=no
8107 fi
8108 fi
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8110 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
8111 with_gnu_ld=$acl_cv_prog_gnu_ld
8112
8113
8114
8115                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8116 $as_echo_n "checking for shared library run path origin... " >&6; }
8117 if ${acl_cv_rpath+:} false; then :
8118   $as_echo_n "(cached) " >&6
8119 else
8120
8121     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8122     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8123     . ./conftest.sh
8124     rm -f ./conftest.sh
8125     acl_cv_rpath=done
8126
8127 fi
8128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8129 $as_echo "$acl_cv_rpath" >&6; }
8130   wl="$acl_cv_wl"
8131   libext="$acl_cv_libext"
8132   shlibext="$acl_cv_shlibext"
8133   hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8134   hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8135   hardcode_direct="$acl_cv_hardcode_direct"
8136   hardcode_minus_L="$acl_cv_hardcode_minus_L"
8137     # Check whether --enable-rpath was given.
8138 if test "${enable_rpath+set}" = set; then :
8139   enableval=$enable_rpath; :
8140 else
8141   enable_rpath=yes
8142 fi
8143
8144
8145
8146
8147
8148
8149
8150
8151     use_additional=yes
8152
8153   acl_save_prefix="$prefix"
8154   prefix="$acl_final_prefix"
8155   acl_save_exec_prefix="$exec_prefix"
8156   exec_prefix="$acl_final_exec_prefix"
8157
8158     eval additional_includedir=\"$includedir\"
8159     eval additional_libdir=\"$libdir\"
8160
8161   exec_prefix="$acl_save_exec_prefix"
8162   prefix="$acl_save_prefix"
8163
8164
8165 # Check whether --with-libiconv-prefix was given.
8166 if test "${with_libiconv_prefix+set}" = set; then :
8167   withval=$with_libiconv_prefix;
8168     if test "X$withval" = "Xno"; then
8169       use_additional=no
8170     else
8171       if test "X$withval" = "X"; then
8172
8173   acl_save_prefix="$prefix"
8174   prefix="$acl_final_prefix"
8175   acl_save_exec_prefix="$exec_prefix"
8176   exec_prefix="$acl_final_exec_prefix"
8177
8178           eval additional_includedir=\"$includedir\"
8179           eval additional_libdir=\"$libdir\"
8180
8181   exec_prefix="$acl_save_exec_prefix"
8182   prefix="$acl_save_prefix"
8183
8184       else
8185         additional_includedir="$withval/include"
8186         additional_libdir="$withval/lib"
8187       fi
8188     fi
8189
8190 fi
8191
8192       LIBICONV=
8193   LTLIBICONV=
8194   INCICONV=
8195   rpathdirs=
8196   ltrpathdirs=
8197   names_already_handled=
8198   names_next_round='iconv '
8199   while test -n "$names_next_round"; do
8200     names_this_round="$names_next_round"
8201     names_next_round=
8202     for name in $names_this_round; do
8203       already_handled=
8204       for n in $names_already_handled; do
8205         if test "$n" = "$name"; then
8206           already_handled=yes
8207           break
8208         fi
8209       done
8210       if test -z "$already_handled"; then
8211         names_already_handled="$names_already_handled $name"
8212                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
8213         eval value=\"\$HAVE_LIB$uppername\"
8214         if test -n "$value"; then
8215           if test "$value" = yes; then
8216             eval value=\"\$LIB$uppername\"
8217             test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
8218             eval value=\"\$LTLIB$uppername\"
8219             test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
8220           else
8221                                     :
8222           fi
8223         else
8224                               found_dir=
8225           found_la=
8226           found_so=
8227           found_a=
8228           if test $use_additional = yes; then
8229             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
8230               found_dir="$additional_libdir"
8231               found_so="$additional_libdir/lib$name.$shlibext"
8232               if test -f "$additional_libdir/lib$name.la"; then
8233                 found_la="$additional_libdir/lib$name.la"
8234               fi
8235             else
8236               if test -f "$additional_libdir/lib$name.$libext"; then
8237                 found_dir="$additional_libdir"
8238                 found_a="$additional_libdir/lib$name.$libext"
8239                 if test -f "$additional_libdir/lib$name.la"; then
8240                   found_la="$additional_libdir/lib$name.la"
8241                 fi
8242               fi
8243             fi
8244           fi
8245           if test "X$found_dir" = "X"; then
8246             for x in $LDFLAGS $LTLIBICONV; do
8247
8248   acl_save_prefix="$prefix"
8249   prefix="$acl_final_prefix"
8250   acl_save_exec_prefix="$exec_prefix"
8251   exec_prefix="$acl_final_exec_prefix"
8252   eval x=\"$x\"
8253   exec_prefix="$acl_save_exec_prefix"
8254   prefix="$acl_save_prefix"
8255
8256               case "$x" in
8257                 -L*)
8258                   dir=`echo "X$x" | sed -e 's/^X-L//'`
8259                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
8260                     found_dir="$dir"
8261                     found_so="$dir/lib$name.$shlibext"
8262                     if test -f "$dir/lib$name.la"; then
8263                       found_la="$dir/lib$name.la"
8264                     fi
8265                   else
8266                     if test -f "$dir/lib$name.$libext"; then
8267                       found_dir="$dir"
8268                       found_a="$dir/lib$name.$libext"
8269                       if test -f "$dir/lib$name.la"; then
8270                         found_la="$dir/lib$name.la"
8271                       fi
8272                     fi
8273                   fi
8274                   ;;
8275               esac
8276               if test "X$found_dir" != "X"; then
8277                 break
8278               fi
8279             done
8280           fi
8281           if test "X$found_dir" != "X"; then
8282                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
8283             if test "X$found_so" != "X"; then
8284                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
8285                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8286               else
8287                                                                                 haveit=
8288                 for x in $ltrpathdirs; do
8289                   if test "X$x" = "X$found_dir"; then
8290                     haveit=yes
8291                     break
8292                   fi
8293                 done
8294                 if test -z "$haveit"; then
8295                   ltrpathdirs="$ltrpathdirs $found_dir"
8296                 fi
8297                                 if test "$hardcode_direct" = yes; then
8298                                                       LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8299                 else
8300                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
8301                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8302                                                             haveit=
8303                     for x in $rpathdirs; do
8304                       if test "X$x" = "X$found_dir"; then
8305                         haveit=yes
8306                         break
8307                       fi
8308                     done
8309                     if test -z "$haveit"; then
8310                       rpathdirs="$rpathdirs $found_dir"
8311                     fi
8312                   else
8313                                                                                 haveit=
8314                     for x in $LDFLAGS $LIBICONV; do
8315
8316   acl_save_prefix="$prefix"
8317   prefix="$acl_final_prefix"
8318   acl_save_exec_prefix="$exec_prefix"
8319   exec_prefix="$acl_final_exec_prefix"
8320   eval x=\"$x\"
8321   exec_prefix="$acl_save_exec_prefix"
8322   prefix="$acl_save_prefix"
8323
8324                       if test "X$x" = "X-L$found_dir"; then
8325                         haveit=yes
8326                         break
8327                       fi
8328                     done
8329                     if test -z "$haveit"; then
8330                       LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
8331                     fi
8332                     if test "$hardcode_minus_L" != no; then
8333                                                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
8334                     else
8335                                                                                                                                                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8336                     fi
8337                   fi
8338                 fi
8339               fi
8340             else
8341               if test "X$found_a" != "X"; then
8342                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
8343               else
8344                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
8345               fi
8346             fi
8347                         additional_includedir=
8348             case "$found_dir" in
8349               */lib | */lib/)
8350                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
8351                 additional_includedir="$basedir/include"
8352                 ;;
8353             esac
8354             if test "X$additional_includedir" != "X"; then
8355                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
8356                 haveit=
8357                 if test "X$additional_includedir" = "X/usr/local/include"; then
8358                   if test -n "$GCC"; then
8359                     case $host_os in
8360                       linux*) haveit=yes;;
8361                     esac
8362                   fi
8363                 fi
8364                 if test -z "$haveit"; then
8365                   for x in $CPPFLAGS $INCICONV; do
8366
8367   acl_save_prefix="$prefix"
8368   prefix="$acl_final_prefix"
8369   acl_save_exec_prefix="$exec_prefix"
8370   exec_prefix="$acl_final_exec_prefix"
8371   eval x=\"$x\"
8372   exec_prefix="$acl_save_exec_prefix"
8373   prefix="$acl_save_prefix"
8374
8375                     if test "X$x" = "X-I$additional_includedir"; then
8376                       haveit=yes
8377                       break
8378                     fi
8379                   done
8380                   if test -z "$haveit"; then
8381                     if test -d "$additional_includedir"; then
8382                                             INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
8383                     fi
8384                   fi
8385                 fi
8386               fi
8387             fi
8388                         if test -n "$found_la"; then
8389                                                         save_libdir="$libdir"
8390               case "$found_la" in
8391                 */* | *\\*) . "$found_la" ;;
8392                 *) . "./$found_la" ;;
8393               esac
8394               libdir="$save_libdir"
8395                             for dep in $dependency_libs; do
8396                 case "$dep" in
8397                   -L*)
8398                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
8399                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
8400                       haveit=
8401                       if test "X$additional_libdir" = "X/usr/local/lib"; then
8402                         if test -n "$GCC"; then
8403                           case $host_os in
8404                             linux*) haveit=yes;;
8405                           esac
8406                         fi
8407                       fi
8408                       if test -z "$haveit"; then
8409                         haveit=
8410                         for x in $LDFLAGS $LIBICONV; do
8411
8412   acl_save_prefix="$prefix"
8413   prefix="$acl_final_prefix"
8414   acl_save_exec_prefix="$exec_prefix"
8415   exec_prefix="$acl_final_exec_prefix"
8416   eval x=\"$x\"
8417   exec_prefix="$acl_save_exec_prefix"
8418   prefix="$acl_save_prefix"
8419
8420                           if test "X$x" = "X-L$additional_libdir"; then
8421                             haveit=yes
8422                             break
8423                           fi
8424                         done
8425                         if test -z "$haveit"; then
8426                           if test -d "$additional_libdir"; then
8427                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
8428                           fi
8429                         fi
8430                         haveit=
8431                         for x in $LDFLAGS $LTLIBICONV; do
8432
8433   acl_save_prefix="$prefix"
8434   prefix="$acl_final_prefix"
8435   acl_save_exec_prefix="$exec_prefix"
8436   exec_prefix="$acl_final_exec_prefix"
8437   eval x=\"$x\"
8438   exec_prefix="$acl_save_exec_prefix"
8439   prefix="$acl_save_prefix"
8440
8441                           if test "X$x" = "X-L$additional_libdir"; then
8442                             haveit=yes
8443                             break
8444                           fi
8445                         done
8446                         if test -z "$haveit"; then
8447                           if test -d "$additional_libdir"; then
8448                                                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
8449                           fi
8450                         fi
8451                       fi
8452                     fi
8453                     ;;
8454                   -R*)
8455                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
8456                     if test "$enable_rpath" != no; then
8457                                                                   haveit=
8458                       for x in $rpathdirs; do
8459                         if test "X$x" = "X$dir"; then
8460                           haveit=yes
8461                           break
8462                         fi
8463                       done
8464                       if test -z "$haveit"; then
8465                         rpathdirs="$rpathdirs $dir"
8466                       fi
8467                                                                   haveit=
8468                       for x in $ltrpathdirs; do
8469                         if test "X$x" = "X$dir"; then
8470                           haveit=yes
8471                           break
8472                         fi
8473                       done
8474                       if test -z "$haveit"; then
8475                         ltrpathdirs="$ltrpathdirs $dir"
8476                       fi
8477                     fi
8478                     ;;
8479                   -l*)
8480                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
8481                     ;;
8482                   *.la)
8483                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
8484                     ;;
8485                   *)
8486                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
8487                     LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
8488                     ;;
8489                 esac
8490               done
8491             fi
8492           else
8493                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
8494             LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
8495           fi
8496         fi
8497       fi
8498     done
8499   done
8500   if test "X$rpathdirs" != "X"; then
8501     if test -n "$hardcode_libdir_separator"; then
8502                         alldirs=
8503       for found_dir in $rpathdirs; do
8504         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
8505       done
8506             acl_save_libdir="$libdir"
8507       libdir="$alldirs"
8508       eval flag=\"$hardcode_libdir_flag_spec\"
8509       libdir="$acl_save_libdir"
8510       LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8511     else
8512             for found_dir in $rpathdirs; do
8513         acl_save_libdir="$libdir"
8514         libdir="$found_dir"
8515         eval flag=\"$hardcode_libdir_flag_spec\"
8516         libdir="$acl_save_libdir"
8517         LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
8518       done
8519     fi
8520   fi
8521   if test "X$ltrpathdirs" != "X"; then
8522             for found_dir in $ltrpathdirs; do
8523       LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
8524     done
8525   fi
8526
8527
8528
8529
8530
8531
8532
8533   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
8534 $as_echo_n "checking for iconv... " >&6; }
8535 if ${am_cv_func_iconv+:} false; then :
8536   $as_echo_n "(cached) " >&6
8537 else
8538
8539     am_cv_func_iconv="no, consider installing GNU libiconv"
8540     am_cv_lib_iconv=no
8541                     am_save_CPPFLAGS="$CPPFLAGS"
8542     CPPFLAGS="$CPPFLAGS $INCICONV"
8543     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8544 /* end confdefs.h.  */
8545 #include <stdlib.h>
8546 #include <iconv.h>
8547 int
8548 main ()
8549 {
8550 iconv_t cd = iconv_open("","");
8551        iconv(cd,NULL,NULL,NULL,NULL);
8552        iconv_close(cd);
8553   ;
8554   return 0;
8555 }
8556 _ACEOF
8557 if ac_fn_c_try_link "$LINENO"; then :
8558   am_cv_func_iconv=yes
8559 fi
8560 rm -f core conftest.err conftest.$ac_objext \
8561     conftest$ac_exeext conftest.$ac_ext
8562     CPPFLAGS="$am_save_CPPFLAGS"
8563
8564     if test "$am_cv_func_iconv" != yes && test -d ../libiconv; then
8565       for _libs in .libs _libs; do
8566         am_save_CPPFLAGS="$CPPFLAGS"
8567         am_save_LIBS="$LIBS"
8568         CPPFLAGS="$CPPFLAGS -I../libiconv/include"
8569         LIBS="$LIBS ../libiconv/lib/$_libs/libiconv.a"
8570         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8571 /* end confdefs.h.  */
8572 #include <stdlib.h>
8573 #include <iconv.h>
8574 int
8575 main ()
8576 {
8577 iconv_t cd = iconv_open("","");
8578            iconv(cd,NULL,NULL,NULL,NULL);
8579            iconv_close(cd);
8580   ;
8581   return 0;
8582 }
8583 _ACEOF
8584 if ac_fn_c_try_link "$LINENO"; then :
8585   INCICONV="-I../libiconv/include"
8586           LIBICONV='${top_builddir}'/../libiconv/lib/$_libs/libiconv.a
8587           LTLIBICONV='${top_builddir}'/../libiconv/lib/libiconv.la
8588           am_cv_lib_iconv=yes
8589           am_cv_func_iconv=yes
8590 fi
8591 rm -f core conftest.err conftest.$ac_objext \
8592     conftest$ac_exeext conftest.$ac_ext
8593         CPPFLAGS="$am_save_CPPFLAGS"
8594         LIBS="$am_save_LIBS"
8595         if test "$am_cv_func_iconv" = "yes"; then
8596           break
8597         fi
8598       done
8599     fi
8600
8601     if test "$am_cv_func_iconv" != yes; then
8602       am_save_CPPFLAGS="$CPPFLAGS"
8603       am_save_LIBS="$LIBS"
8604       CPPFLAGS="$CPPFLAGS $INCICONV"
8605       LIBS="$LIBS $LIBICONV"
8606       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8607 /* end confdefs.h.  */
8608 #include <stdlib.h>
8609 #include <iconv.h>
8610 int
8611 main ()
8612 {
8613 iconv_t cd = iconv_open("","");
8614          iconv(cd,NULL,NULL,NULL,NULL);
8615          iconv_close(cd);
8616   ;
8617   return 0;
8618 }
8619 _ACEOF
8620 if ac_fn_c_try_link "$LINENO"; then :
8621   am_cv_lib_iconv=yes
8622         am_cv_func_iconv=yes
8623 fi
8624 rm -f core conftest.err conftest.$ac_objext \
8625     conftest$ac_exeext conftest.$ac_ext
8626       CPPFLAGS="$am_save_CPPFLAGS"
8627       LIBS="$am_save_LIBS"
8628     fi
8629
8630 fi
8631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
8632 $as_echo "$am_cv_func_iconv" >&6; }
8633   if test "$am_cv_func_iconv" = yes; then
8634
8635 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
8636
8637   fi
8638   if test "$am_cv_lib_iconv" = yes; then
8639
8640   for element in $INCICONV; do
8641     haveit=
8642     for x in $CPPFLAGS; do
8643
8644   acl_save_prefix="$prefix"
8645   prefix="$acl_final_prefix"
8646   acl_save_exec_prefix="$exec_prefix"
8647   exec_prefix="$acl_final_exec_prefix"
8648   eval x=\"$x\"
8649   exec_prefix="$acl_save_exec_prefix"
8650   prefix="$acl_save_prefix"
8651
8652       if test "X$x" = "X$element"; then
8653         haveit=yes
8654         break
8655       fi
8656     done
8657     if test -z "$haveit"; then
8658       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
8659     fi
8660   done
8661
8662     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
8663 $as_echo_n "checking how to link with libiconv... " >&6; }
8664     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
8665 $as_echo "$LIBICONV" >&6; }
8666   else
8667     LIBICONV=
8668     LTLIBICONV=
8669   fi
8670
8671
8672
8673   if test "$am_cv_func_iconv" = yes; then
8674     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5
8675 $as_echo_n "checking for iconv declaration... " >&6; }
8676     if ${am_cv_proto_iconv+:} false; then :
8677   $as_echo_n "(cached) " >&6
8678 else
8679
8680       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8681 /* end confdefs.h.  */
8682
8683 #include <stdlib.h>
8684 #include <iconv.h>
8685 extern
8686 #ifdef __cplusplus
8687 "C"
8688 #endif
8689 #if defined(__STDC__) || defined(__cplusplus)
8690 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
8691 #else
8692 size_t iconv();
8693 #endif
8694
8695 int
8696 main ()
8697 {
8698
8699   ;
8700   return 0;
8701 }
8702 _ACEOF
8703 if ac_fn_c_try_compile "$LINENO"; then :
8704   am_cv_proto_iconv_arg1=""
8705 else
8706   am_cv_proto_iconv_arg1="const"
8707 fi
8708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8709       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);"
8710 fi
8711
8712     am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
8713     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:-
8714          }$am_cv_proto_iconv" >&5
8715 $as_echo "${ac_t:-
8716          }$am_cv_proto_iconv" >&6; }
8717
8718 cat >>confdefs.h <<_ACEOF
8719 #define ICONV_CONST $am_cv_proto_iconv_arg1
8720 _ACEOF
8721
8722   fi
8723
8724
8725 # GDB may fork/exec the iconv program to get the list of supported character
8726 # sets.  Allow the user to specify where to find it.
8727 # There are several factors affecting the choice of option name:
8728 # - There is already --with-libiconv-prefix but we can't use it, it specifies
8729 #   the build-time location of libiconv files.
8730 # - The program we need to find is iconv, which comes with glibc.  The user
8731 #   doesn't necessarily have libiconv installed.  Therefore naming this
8732 #   --with-libiconv-foo feels wrong.
8733 # - We want the path to be relocatable, but GDB_AC_DEFINE_RELOCATABLE is
8734 #   defined to work on directories not files (though it really doesn't know
8735 #   the difference).
8736 # - Calling this --with-iconv-prefix is perceived to cause too much confusion
8737 #   with --with-libiconv-prefix.
8738 # Putting these together is why the option name is --with-iconv-bin.
8739
8740
8741 # Check whether --with-iconv-bin was given.
8742 if test "${with_iconv_bin+set}" = set; then :
8743   withval=$with_iconv_bin; iconv_bin="${withval}"
8744
8745 cat >>confdefs.h <<_ACEOF
8746 #define ICONV_BIN "${iconv_bin}"
8747 _ACEOF
8748
8749
8750   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
8751      if test "x$prefix" = xNONE; then
8752         test_prefix=/usr/local
8753      else
8754         test_prefix=$prefix
8755      fi
8756   else
8757      test_prefix=$exec_prefix
8758   fi
8759   value=0
8760   case ${iconv_bin} in
8761      "${test_prefix}"|"${test_prefix}/"*|\
8762         '${exec_prefix}'|'${exec_prefix}/'*)
8763      value=1
8764      ;;
8765   esac
8766
8767 cat >>confdefs.h <<_ACEOF
8768 #define ICONV_BIN_RELOCATABLE $value
8769 _ACEOF
8770
8771
8772
8773 fi
8774
8775
8776 # For the TUI, we need enhanced curses functionality.
8777 if test x"$enable_tui" != xno; then
8778   prefer_curses=yes
8779 fi
8780
8781 curses_found=no
8782 if test x"$prefer_curses" = xyes; then
8783   # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
8784   # curses library because the latter might not provide all the
8785   # functionality we need.  However, this leads to problems on systems
8786   # where the linker searches /usr/local/lib, but the compiler doesn't
8787   # search /usr/local/include, if ncurses is installed in /usr/local.  A
8788   # default installation of ncurses on alpha*-dec-osf* will lead to such
8789   # a situation.
8790   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
8791 $as_echo_n "checking for library containing waddstr... " >&6; }
8792 if ${ac_cv_search_waddstr+:} false; then :
8793   $as_echo_n "(cached) " >&6
8794 else
8795   ac_func_search_save_LIBS=$LIBS
8796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8797 /* end confdefs.h.  */
8798
8799 /* Override any GCC internal prototype to avoid an error.
8800    Use char because int might match the return type of a GCC
8801    builtin and then its argument prototype would still apply.  */
8802 #ifdef __cplusplus
8803 extern "C"
8804 #endif
8805 char waddstr ();
8806 int
8807 main ()
8808 {
8809 return waddstr ();
8810   ;
8811   return 0;
8812 }
8813 _ACEOF
8814 for ac_lib in '' ncursesw ncurses cursesX curses; do
8815   if test -z "$ac_lib"; then
8816     ac_res="none required"
8817   else
8818     ac_res=-l$ac_lib
8819     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8820   fi
8821   if ac_fn_c_try_link "$LINENO"; then :
8822   ac_cv_search_waddstr=$ac_res
8823 fi
8824 rm -f core conftest.err conftest.$ac_objext \
8825     conftest$ac_exeext
8826   if ${ac_cv_search_waddstr+:} false; then :
8827   break
8828 fi
8829 done
8830 if ${ac_cv_search_waddstr+:} false; then :
8831
8832 else
8833   ac_cv_search_waddstr=no
8834 fi
8835 rm conftest.$ac_ext
8836 LIBS=$ac_func_search_save_LIBS
8837 fi
8838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_waddstr" >&5
8839 $as_echo "$ac_cv_search_waddstr" >&6; }
8840 ac_res=$ac_cv_search_waddstr
8841 if test "$ac_res" != no; then :
8842   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8843
8844 fi
8845
8846
8847   if test "$ac_cv_search_waddstr" != no; then
8848     curses_found=yes
8849   fi
8850 fi
8851
8852 # Check whether we should enable the TUI, but only do so if we really
8853 # can.
8854 if test x"$enable_tui" != xno; then
8855   if test -d $srcdir/tui; then
8856     if test "$curses_found" != no; then
8857       CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
8858       CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
8859       CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
8860       ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
8861     else
8862       if test x"$enable_tui" = xyes; then
8863         as_fn_error $? "no enhanced curses library found; disable TUI" "$LINENO" 5
8864       else
8865         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no enhanced curses library found; disabling TUI" >&5
8866 $as_echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
8867       fi
8868     fi
8869   fi
8870 fi
8871
8872 # Since GDB uses Readline, we need termcap functionality.  In many
8873 # cases this will be provided by the curses library, but some systems
8874 # have a separate termcap library, or no curses library at all.
8875
8876 case $host_os in
8877   cygwin*)
8878     if test -d $srcdir/libtermcap; then
8879       LIBS="../libtermcap/libtermcap.a $LIBS"
8880       ac_cv_search_tgetent="../libtermcap/libtermcap.a"
8881     fi ;;
8882   go32* | *djgpp*)
8883     ac_cv_search_tgetent="none required"
8884     ;;
8885 esac
8886
8887 # These are the libraries checked by Readline.
8888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
8889 $as_echo_n "checking for library containing tgetent... " >&6; }
8890 if ${ac_cv_search_tgetent+:} false; then :
8891   $as_echo_n "(cached) " >&6
8892 else
8893   ac_func_search_save_LIBS=$LIBS
8894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8895 /* end confdefs.h.  */
8896
8897 /* Override any GCC internal prototype to avoid an error.
8898    Use char because int might match the return type of a GCC
8899    builtin and then its argument prototype would still apply.  */
8900 #ifdef __cplusplus
8901 extern "C"
8902 #endif
8903 char tgetent ();
8904 int
8905 main ()
8906 {
8907 return tgetent ();
8908   ;
8909   return 0;
8910 }
8911 _ACEOF
8912 for ac_lib in '' termcap tinfow tinfo curses ncursesw ncurses; do
8913   if test -z "$ac_lib"; then
8914     ac_res="none required"
8915   else
8916     ac_res=-l$ac_lib
8917     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8918   fi
8919   if ac_fn_c_try_link "$LINENO"; then :
8920   ac_cv_search_tgetent=$ac_res
8921 fi
8922 rm -f core conftest.err conftest.$ac_objext \
8923     conftest$ac_exeext
8924   if ${ac_cv_search_tgetent+:} false; then :
8925   break
8926 fi
8927 done
8928 if ${ac_cv_search_tgetent+:} false; then :
8929
8930 else
8931   ac_cv_search_tgetent=no
8932 fi
8933 rm conftest.$ac_ext
8934 LIBS=$ac_func_search_save_LIBS
8935 fi
8936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
8937 $as_echo "$ac_cv_search_tgetent" >&6; }
8938 ac_res=$ac_cv_search_tgetent
8939 if test "$ac_res" != no; then :
8940   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8941
8942 fi
8943
8944
8945 if test "$ac_cv_search_tgetent" = no; then
8946   CONFIG_OBS="$CONFIG_OBS stub-termcap.o"
8947 fi
8948
8949
8950 # Check whether --with-system-readline was given.
8951 if test "${with_system_readline+set}" = set; then :
8952   withval=$with_system_readline;
8953 fi
8954
8955
8956 if test "$with_system_readline" = yes; then
8957   READLINE=-lreadline
8958   READLINE_DEPS=
8959   READLINE_CFLAGS=
8960   READLINE_TEXI_INCFLAG=
8961 else
8962   READLINE='$(READLINE_DIR)/libreadline.a'
8963   READLINE_DEPS='$(READLINE)'
8964   READLINE_CFLAGS='-I$(READLINE_SRC)/..'
8965   READLINE_TEXI_INCFLAG='-I $(READLINE_DIR)'
8966 fi
8967
8968
8969
8970
8971
8972 # Generate jit-reader.h
8973
8974 # This is typedeffed to GDB_CORE_ADDR in jit-reader.h
8975 TARGET_PTR=
8976
8977 # The cast to long int works around a bug in the HP C Compiler
8978 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8979 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8980 # This bug is HP SR number 8606223364.
8981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long long" >&5
8982 $as_echo_n "checking size of unsigned long long... " >&6; }
8983 if ${ac_cv_sizeof_unsigned_long_long+:} false; then :
8984   $as_echo_n "(cached) " >&6
8985 else
8986   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long long))" "ac_cv_sizeof_unsigned_long_long"        "$ac_includes_default"; then :
8987
8988 else
8989   if test "$ac_cv_type_unsigned_long_long" = yes; then
8990      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8991 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8992 as_fn_error 77 "cannot compute sizeof (unsigned long long)
8993 See \`config.log' for more details" "$LINENO" 5; }
8994    else
8995      ac_cv_sizeof_unsigned_long_long=0
8996    fi
8997 fi
8998
8999 fi
9000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long_long" >&5
9001 $as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }
9002
9003
9004
9005 cat >>confdefs.h <<_ACEOF
9006 #define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
9007 _ACEOF
9008
9009
9010 # The cast to long int works around a bug in the HP C Compiler
9011 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9012 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9013 # This bug is HP SR number 8606223364.
9014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned long" >&5
9015 $as_echo_n "checking size of unsigned long... " >&6; }
9016 if ${ac_cv_sizeof_unsigned_long+:} false; then :
9017   $as_echo_n "(cached) " >&6
9018 else
9019   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned long))" "ac_cv_sizeof_unsigned_long"        "$ac_includes_default"; then :
9020
9021 else
9022   if test "$ac_cv_type_unsigned_long" = yes; then
9023      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9024 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9025 as_fn_error 77 "cannot compute sizeof (unsigned long)
9026 See \`config.log' for more details" "$LINENO" 5; }
9027    else
9028      ac_cv_sizeof_unsigned_long=0
9029    fi
9030 fi
9031
9032 fi
9033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned_long" >&5
9034 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
9035
9036
9037
9038 cat >>confdefs.h <<_ACEOF
9039 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
9040 _ACEOF
9041
9042
9043 # The cast to long int works around a bug in the HP C Compiler
9044 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9045 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9046 # This bug is HP SR number 8606223364.
9047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of unsigned __int128" >&5
9048 $as_echo_n "checking size of unsigned __int128... " >&6; }
9049 if ${ac_cv_sizeof_unsigned___int128+:} false; then :
9050   $as_echo_n "(cached) " >&6
9051 else
9052   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (unsigned __int128))" "ac_cv_sizeof_unsigned___int128"        "$ac_includes_default"; then :
9053
9054 else
9055   if test "$ac_cv_type_unsigned___int128" = yes; then
9056      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9057 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9058 as_fn_error 77 "cannot compute sizeof (unsigned __int128)
9059 See \`config.log' for more details" "$LINENO" 5; }
9060    else
9061      ac_cv_sizeof_unsigned___int128=0
9062    fi
9063 fi
9064
9065 fi
9066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_unsigned___int128" >&5
9067 $as_echo "$ac_cv_sizeof_unsigned___int128" >&6; }
9068
9069
9070
9071 cat >>confdefs.h <<_ACEOF
9072 #define SIZEOF_UNSIGNED___INT128 $ac_cv_sizeof_unsigned___int128
9073 _ACEOF
9074
9075
9076
9077 if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then
9078   TARGET_PTR="unsigned long"
9079 elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then
9080   TARGET_PTR="unsigned long long"
9081 elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then
9082   TARGET_PTR="unsigned __int128"
9083 else
9084   TARGET_PTR="unsigned long"
9085 fi
9086
9087
9088 ac_config_files="$ac_config_files jit-reader.h:jit-reader.in"
9089
9090
9091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
9092 $as_echo_n "checking for library containing dlopen... " >&6; }
9093 if ${ac_cv_search_dlopen+:} false; then :
9094   $as_echo_n "(cached) " >&6
9095 else
9096   ac_func_search_save_LIBS=$LIBS
9097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9098 /* end confdefs.h.  */
9099
9100 /* Override any GCC internal prototype to avoid an error.
9101    Use char because int might match the return type of a GCC
9102    builtin and then its argument prototype would still apply.  */
9103 #ifdef __cplusplus
9104 extern "C"
9105 #endif
9106 char dlopen ();
9107 int
9108 main ()
9109 {
9110 return dlopen ();
9111   ;
9112   return 0;
9113 }
9114 _ACEOF
9115 for ac_lib in '' dl; do
9116   if test -z "$ac_lib"; then
9117     ac_res="none required"
9118   else
9119     ac_res=-l$ac_lib
9120     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9121   fi
9122   if ac_fn_c_try_link "$LINENO"; then :
9123   ac_cv_search_dlopen=$ac_res
9124 fi
9125 rm -f core conftest.err conftest.$ac_objext \
9126     conftest$ac_exeext
9127   if ${ac_cv_search_dlopen+:} false; then :
9128   break
9129 fi
9130 done
9131 if ${ac_cv_search_dlopen+:} false; then :
9132
9133 else
9134   ac_cv_search_dlopen=no
9135 fi
9136 rm conftest.$ac_ext
9137 LIBS=$ac_func_search_save_LIBS
9138 fi
9139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
9140 $as_echo "$ac_cv_search_dlopen" >&6; }
9141 ac_res=$ac_cv_search_dlopen
9142 if test "$ac_res" != no; then :
9143   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9144
9145 fi
9146
9147
9148
9149
9150 # Check whether --with-jit-reader-dir was given.
9151 if test "${with_jit_reader_dir+set}" = set; then :
9152   withval=$with_jit_reader_dir;
9153     JIT_READER_DIR=$withval
9154 else
9155   JIT_READER_DIR=${libdir}/gdb
9156 fi
9157
9158
9159   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
9160   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9161   ac_define_dir=`eval echo $JIT_READER_DIR`
9162   ac_define_dir=`eval echo $ac_define_dir`
9163
9164 cat >>confdefs.h <<_ACEOF
9165 #define JIT_READER_DIR "$ac_define_dir"
9166 _ACEOF
9167
9168
9169
9170
9171   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
9172      if test "x$prefix" = xNONE; then
9173         test_prefix=/usr/local
9174      else
9175         test_prefix=$prefix
9176      fi
9177   else
9178      test_prefix=$exec_prefix
9179   fi
9180   value=0
9181   case ${ac_define_dir} in
9182      "${test_prefix}"|"${test_prefix}/"*|\
9183         '${exec_prefix}'|'${exec_prefix}/'*)
9184      value=1
9185      ;;
9186   esac
9187
9188 cat >>confdefs.h <<_ACEOF
9189 #define JIT_READER_DIR_RELOCATABLE $value
9190 _ACEOF
9191
9192
9193
9194
9195
9196 # Check whether --with-expat was given.
9197 if test "${with_expat+set}" = set; then :
9198   withval=$with_expat;
9199 else
9200   with_expat=auto
9201 fi
9202
9203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use expat" >&5
9204 $as_echo_n "checking whether to use expat... " >&6; }
9205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_expat" >&5
9206 $as_echo "$with_expat" >&6; }
9207
9208 if test "${with_expat}" = no; then
9209   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat support disabled; some features may be unavailable." >&5
9210 $as_echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
9211   HAVE_LIBEXPAT=no
9212 else
9213
9214
9215
9216
9217
9218
9219
9220
9221     use_additional=yes
9222
9223   acl_save_prefix="$prefix"
9224   prefix="$acl_final_prefix"
9225   acl_save_exec_prefix="$exec_prefix"
9226   exec_prefix="$acl_final_exec_prefix"
9227
9228     eval additional_includedir=\"$includedir\"
9229     eval additional_libdir=\"$libdir\"
9230
9231   exec_prefix="$acl_save_exec_prefix"
9232   prefix="$acl_save_prefix"
9233
9234
9235 # Check whether --with-libexpat-prefix was given.
9236 if test "${with_libexpat_prefix+set}" = set; then :
9237   withval=$with_libexpat_prefix;
9238     if test "X$withval" = "Xno"; then
9239       use_additional=no
9240     else
9241       if test "X$withval" = "X"; then
9242
9243   acl_save_prefix="$prefix"
9244   prefix="$acl_final_prefix"
9245   acl_save_exec_prefix="$exec_prefix"
9246   exec_prefix="$acl_final_exec_prefix"
9247
9248           eval additional_includedir=\"$includedir\"
9249           eval additional_libdir=\"$libdir\"
9250
9251   exec_prefix="$acl_save_exec_prefix"
9252   prefix="$acl_save_prefix"
9253
9254       else
9255         additional_includedir="$withval/include"
9256         additional_libdir="$withval/lib"
9257       fi
9258     fi
9259
9260 fi
9261
9262       LIBEXPAT=
9263   LTLIBEXPAT=
9264   INCEXPAT=
9265   rpathdirs=
9266   ltrpathdirs=
9267   names_already_handled=
9268   names_next_round='expat '
9269   while test -n "$names_next_round"; do
9270     names_this_round="$names_next_round"
9271     names_next_round=
9272     for name in $names_this_round; do
9273       already_handled=
9274       for n in $names_already_handled; do
9275         if test "$n" = "$name"; then
9276           already_handled=yes
9277           break
9278         fi
9279       done
9280       if test -z "$already_handled"; then
9281         names_already_handled="$names_already_handled $name"
9282                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9283         eval value=\"\$HAVE_LIB$uppername\"
9284         if test -n "$value"; then
9285           if test "$value" = yes; then
9286             eval value=\"\$LIB$uppername\"
9287             test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
9288             eval value=\"\$LTLIB$uppername\"
9289             test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
9290           else
9291                                     :
9292           fi
9293         else
9294                               found_dir=
9295           found_la=
9296           found_so=
9297           found_a=
9298           if test $use_additional = yes; then
9299             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
9300               found_dir="$additional_libdir"
9301               found_so="$additional_libdir/lib$name.$shlibext"
9302               if test -f "$additional_libdir/lib$name.la"; then
9303                 found_la="$additional_libdir/lib$name.la"
9304               fi
9305             else
9306               if test -f "$additional_libdir/lib$name.$libext"; then
9307                 found_dir="$additional_libdir"
9308                 found_a="$additional_libdir/lib$name.$libext"
9309                 if test -f "$additional_libdir/lib$name.la"; then
9310                   found_la="$additional_libdir/lib$name.la"
9311                 fi
9312               fi
9313             fi
9314           fi
9315           if test "X$found_dir" = "X"; then
9316             for x in $LDFLAGS $LTLIBEXPAT; do
9317
9318   acl_save_prefix="$prefix"
9319   prefix="$acl_final_prefix"
9320   acl_save_exec_prefix="$exec_prefix"
9321   exec_prefix="$acl_final_exec_prefix"
9322   eval x=\"$x\"
9323   exec_prefix="$acl_save_exec_prefix"
9324   prefix="$acl_save_prefix"
9325
9326               case "$x" in
9327                 -L*)
9328                   dir=`echo "X$x" | sed -e 's/^X-L//'`
9329                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
9330                     found_dir="$dir"
9331                     found_so="$dir/lib$name.$shlibext"
9332                     if test -f "$dir/lib$name.la"; then
9333                       found_la="$dir/lib$name.la"
9334                     fi
9335                   else
9336                     if test -f "$dir/lib$name.$libext"; then
9337                       found_dir="$dir"
9338                       found_a="$dir/lib$name.$libext"
9339                       if test -f "$dir/lib$name.la"; then
9340                         found_la="$dir/lib$name.la"
9341                       fi
9342                     fi
9343                   fi
9344                   ;;
9345               esac
9346               if test "X$found_dir" != "X"; then
9347                 break
9348               fi
9349             done
9350           fi
9351           if test "X$found_dir" != "X"; then
9352                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
9353             if test "X$found_so" != "X"; then
9354                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9355                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9356               else
9357                                                                                 haveit=
9358                 for x in $ltrpathdirs; do
9359                   if test "X$x" = "X$found_dir"; then
9360                     haveit=yes
9361                     break
9362                   fi
9363                 done
9364                 if test -z "$haveit"; then
9365                   ltrpathdirs="$ltrpathdirs $found_dir"
9366                 fi
9367                                 if test "$hardcode_direct" = yes; then
9368                                                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9369                 else
9370                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9371                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9372                                                             haveit=
9373                     for x in $rpathdirs; do
9374                       if test "X$x" = "X$found_dir"; then
9375                         haveit=yes
9376                         break
9377                       fi
9378                     done
9379                     if test -z "$haveit"; then
9380                       rpathdirs="$rpathdirs $found_dir"
9381                     fi
9382                   else
9383                                                                                 haveit=
9384                     for x in $LDFLAGS $LIBEXPAT; do
9385
9386   acl_save_prefix="$prefix"
9387   prefix="$acl_final_prefix"
9388   acl_save_exec_prefix="$exec_prefix"
9389   exec_prefix="$acl_final_exec_prefix"
9390   eval x=\"$x\"
9391   exec_prefix="$acl_save_exec_prefix"
9392   prefix="$acl_save_prefix"
9393
9394                       if test "X$x" = "X-L$found_dir"; then
9395                         haveit=yes
9396                         break
9397                       fi
9398                     done
9399                     if test -z "$haveit"; then
9400                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
9401                     fi
9402                     if test "$hardcode_minus_L" != no; then
9403                                                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
9404                     else
9405                                                                                                                                                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9406                     fi
9407                   fi
9408                 fi
9409               fi
9410             else
9411               if test "X$found_a" != "X"; then
9412                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
9413               else
9414                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
9415               fi
9416             fi
9417                         additional_includedir=
9418             case "$found_dir" in
9419               */lib | */lib/)
9420                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9421                 additional_includedir="$basedir/include"
9422                 ;;
9423             esac
9424             if test "X$additional_includedir" != "X"; then
9425                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
9426                 haveit=
9427                 if test "X$additional_includedir" = "X/usr/local/include"; then
9428                   if test -n "$GCC"; then
9429                     case $host_os in
9430                       linux*) haveit=yes;;
9431                     esac
9432                   fi
9433                 fi
9434                 if test -z "$haveit"; then
9435                   for x in $CPPFLAGS $INCEXPAT; do
9436
9437   acl_save_prefix="$prefix"
9438   prefix="$acl_final_prefix"
9439   acl_save_exec_prefix="$exec_prefix"
9440   exec_prefix="$acl_final_exec_prefix"
9441   eval x=\"$x\"
9442   exec_prefix="$acl_save_exec_prefix"
9443   prefix="$acl_save_prefix"
9444
9445                     if test "X$x" = "X-I$additional_includedir"; then
9446                       haveit=yes
9447                       break
9448                     fi
9449                   done
9450                   if test -z "$haveit"; then
9451                     if test -d "$additional_includedir"; then
9452                                             INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
9453                     fi
9454                   fi
9455                 fi
9456               fi
9457             fi
9458                         if test -n "$found_la"; then
9459                                                         save_libdir="$libdir"
9460               case "$found_la" in
9461                 */* | *\\*) . "$found_la" ;;
9462                 *) . "./$found_la" ;;
9463               esac
9464               libdir="$save_libdir"
9465                             for dep in $dependency_libs; do
9466                 case "$dep" in
9467                   -L*)
9468                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9469                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
9470                       haveit=
9471                       if test "X$additional_libdir" = "X/usr/local/lib"; then
9472                         if test -n "$GCC"; then
9473                           case $host_os in
9474                             linux*) haveit=yes;;
9475                           esac
9476                         fi
9477                       fi
9478                       if test -z "$haveit"; then
9479                         haveit=
9480                         for x in $LDFLAGS $LIBEXPAT; do
9481
9482   acl_save_prefix="$prefix"
9483   prefix="$acl_final_prefix"
9484   acl_save_exec_prefix="$exec_prefix"
9485   exec_prefix="$acl_final_exec_prefix"
9486   eval x=\"$x\"
9487   exec_prefix="$acl_save_exec_prefix"
9488   prefix="$acl_save_prefix"
9489
9490                           if test "X$x" = "X-L$additional_libdir"; then
9491                             haveit=yes
9492                             break
9493                           fi
9494                         done
9495                         if test -z "$haveit"; then
9496                           if test -d "$additional_libdir"; then
9497                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
9498                           fi
9499                         fi
9500                         haveit=
9501                         for x in $LDFLAGS $LTLIBEXPAT; do
9502
9503   acl_save_prefix="$prefix"
9504   prefix="$acl_final_prefix"
9505   acl_save_exec_prefix="$exec_prefix"
9506   exec_prefix="$acl_final_exec_prefix"
9507   eval x=\"$x\"
9508   exec_prefix="$acl_save_exec_prefix"
9509   prefix="$acl_save_prefix"
9510
9511                           if test "X$x" = "X-L$additional_libdir"; then
9512                             haveit=yes
9513                             break
9514                           fi
9515                         done
9516                         if test -z "$haveit"; then
9517                           if test -d "$additional_libdir"; then
9518                                                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
9519                           fi
9520                         fi
9521                       fi
9522                     fi
9523                     ;;
9524                   -R*)
9525                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
9526                     if test "$enable_rpath" != no; then
9527                                                                   haveit=
9528                       for x in $rpathdirs; do
9529                         if test "X$x" = "X$dir"; then
9530                           haveit=yes
9531                           break
9532                         fi
9533                       done
9534                       if test -z "$haveit"; then
9535                         rpathdirs="$rpathdirs $dir"
9536                       fi
9537                                                                   haveit=
9538                       for x in $ltrpathdirs; do
9539                         if test "X$x" = "X$dir"; then
9540                           haveit=yes
9541                           break
9542                         fi
9543                       done
9544                       if test -z "$haveit"; then
9545                         ltrpathdirs="$ltrpathdirs $dir"
9546                       fi
9547                     fi
9548                     ;;
9549                   -l*)
9550                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
9551                     ;;
9552                   *.la)
9553                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
9554                     ;;
9555                   *)
9556                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
9557                     LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
9558                     ;;
9559                 esac
9560               done
9561             fi
9562           else
9563                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
9564             LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
9565           fi
9566         fi
9567       fi
9568     done
9569   done
9570   if test "X$rpathdirs" != "X"; then
9571     if test -n "$hardcode_libdir_separator"; then
9572                         alldirs=
9573       for found_dir in $rpathdirs; do
9574         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
9575       done
9576             acl_save_libdir="$libdir"
9577       libdir="$alldirs"
9578       eval flag=\"$hardcode_libdir_flag_spec\"
9579       libdir="$acl_save_libdir"
9580       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9581     else
9582             for found_dir in $rpathdirs; do
9583         acl_save_libdir="$libdir"
9584         libdir="$found_dir"
9585         eval flag=\"$hardcode_libdir_flag_spec\"
9586         libdir="$acl_save_libdir"
9587         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
9588       done
9589     fi
9590   fi
9591   if test "X$ltrpathdirs" != "X"; then
9592             for found_dir in $ltrpathdirs; do
9593       LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
9594     done
9595   fi
9596
9597
9598         ac_save_CPPFLAGS="$CPPFLAGS"
9599
9600   for element in $INCEXPAT; do
9601     haveit=
9602     for x in $CPPFLAGS; do
9603
9604   acl_save_prefix="$prefix"
9605   prefix="$acl_final_prefix"
9606   acl_save_exec_prefix="$exec_prefix"
9607   exec_prefix="$acl_final_exec_prefix"
9608   eval x=\"$x\"
9609   exec_prefix="$acl_save_exec_prefix"
9610   prefix="$acl_save_prefix"
9611
9612       if test "X$x" = "X$element"; then
9613         haveit=yes
9614         break
9615       fi
9616     done
9617     if test -z "$haveit"; then
9618       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
9619     fi
9620   done
9621
9622
9623   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libexpat" >&5
9624 $as_echo_n "checking for libexpat... " >&6; }
9625 if ${ac_cv_libexpat+:} false; then :
9626   $as_echo_n "(cached) " >&6
9627 else
9628
9629     ac_save_LIBS="$LIBS"
9630     LIBS="$LIBS $LIBEXPAT"
9631     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9632 /* end confdefs.h.  */
9633 #include "expat.h"
9634 int
9635 main ()
9636 {
9637 XML_Parser p = XML_ParserCreate (0);
9638   ;
9639   return 0;
9640 }
9641 _ACEOF
9642 if ac_fn_c_try_link "$LINENO"; then :
9643   ac_cv_libexpat=yes
9644 else
9645   ac_cv_libexpat=no
9646 fi
9647 rm -f core conftest.err conftest.$ac_objext \
9648     conftest$ac_exeext conftest.$ac_ext
9649     LIBS="$ac_save_LIBS"
9650
9651 fi
9652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libexpat" >&5
9653 $as_echo "$ac_cv_libexpat" >&6; }
9654   if test "$ac_cv_libexpat" = yes; then
9655     HAVE_LIBEXPAT=yes
9656
9657 $as_echo "#define HAVE_LIBEXPAT 1" >>confdefs.h
9658
9659     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libexpat" >&5
9660 $as_echo_n "checking how to link with libexpat... " >&6; }
9661     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBEXPAT" >&5
9662 $as_echo "$LIBEXPAT" >&6; }
9663   else
9664     HAVE_LIBEXPAT=no
9665             CPPFLAGS="$ac_save_CPPFLAGS"
9666     LIBEXPAT=
9667     LTLIBEXPAT=
9668   fi
9669
9670
9671
9672
9673
9674
9675   if test "$HAVE_LIBEXPAT" != yes; then
9676     if test "$with_expat" = yes; then
9677       as_fn_error $? "expat is missing or unusable" "$LINENO" 5
9678     else
9679       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: expat is missing or unusable; some features may be unavailable." >&5
9680 $as_echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
9681     fi
9682   else
9683     save_LIBS=$LIBS
9684     LIBS="$LIBS $LIBEXPAT"
9685     for ac_func in XML_StopParser
9686 do :
9687   ac_fn_c_check_func "$LINENO" "XML_StopParser" "ac_cv_func_XML_StopParser"
9688 if test "x$ac_cv_func_XML_StopParser" = xyes; then :
9689   cat >>confdefs.h <<_ACEOF
9690 #define HAVE_XML_STOPPARSER 1
9691 _ACEOF
9692
9693 fi
9694 done
9695
9696     LIBS=$save_LIBS
9697   fi
9698 fi
9699
9700
9701 # Check whether --with-mpfr was given.
9702 if test "${with_mpfr+set}" = set; then :
9703   withval=$with_mpfr;
9704 else
9705   with_mpfr=auto
9706 fi
9707
9708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use MPFR" >&5
9709 $as_echo_n "checking whether to use MPFR... " >&6; }
9710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_mpfr" >&5
9711 $as_echo "$with_mpfr" >&6; }
9712
9713 if test "${with_mpfr}" = no; then
9714   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR support disabled; some features may be unavailable." >&5
9715 $as_echo "$as_me: WARNING: MPFR support disabled; some features may be unavailable." >&2;}
9716   HAVE_LIBMPFR=no
9717 else
9718
9719
9720
9721
9722
9723
9724
9725
9726     use_additional=yes
9727
9728   acl_save_prefix="$prefix"
9729   prefix="$acl_final_prefix"
9730   acl_save_exec_prefix="$exec_prefix"
9731   exec_prefix="$acl_final_exec_prefix"
9732
9733     eval additional_includedir=\"$includedir\"
9734     eval additional_libdir=\"$libdir\"
9735
9736   exec_prefix="$acl_save_exec_prefix"
9737   prefix="$acl_save_prefix"
9738
9739
9740 # Check whether --with-libmpfr-prefix was given.
9741 if test "${with_libmpfr_prefix+set}" = set; then :
9742   withval=$with_libmpfr_prefix;
9743     if test "X$withval" = "Xno"; then
9744       use_additional=no
9745     else
9746       if test "X$withval" = "X"; then
9747
9748   acl_save_prefix="$prefix"
9749   prefix="$acl_final_prefix"
9750   acl_save_exec_prefix="$exec_prefix"
9751   exec_prefix="$acl_final_exec_prefix"
9752
9753           eval additional_includedir=\"$includedir\"
9754           eval additional_libdir=\"$libdir\"
9755
9756   exec_prefix="$acl_save_exec_prefix"
9757   prefix="$acl_save_prefix"
9758
9759       else
9760         additional_includedir="$withval/include"
9761         additional_libdir="$withval/lib"
9762       fi
9763     fi
9764
9765 fi
9766
9767       LIBMPFR=
9768   LTLIBMPFR=
9769   INCMPFR=
9770   rpathdirs=
9771   ltrpathdirs=
9772   names_already_handled=
9773   names_next_round='mpfr gmp'
9774   while test -n "$names_next_round"; do
9775     names_this_round="$names_next_round"
9776     names_next_round=
9777     for name in $names_this_round; do
9778       already_handled=
9779       for n in $names_already_handled; do
9780         if test "$n" = "$name"; then
9781           already_handled=yes
9782           break
9783         fi
9784       done
9785       if test -z "$already_handled"; then
9786         names_already_handled="$names_already_handled $name"
9787                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
9788         eval value=\"\$HAVE_LIB$uppername\"
9789         if test -n "$value"; then
9790           if test "$value" = yes; then
9791             eval value=\"\$LIB$uppername\"
9792             test -z "$value" || LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$value"
9793             eval value=\"\$LTLIB$uppername\"
9794             test -z "$value" || LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$value"
9795           else
9796                                     :
9797           fi
9798         else
9799                               found_dir=
9800           found_la=
9801           found_so=
9802           found_a=
9803           if test $use_additional = yes; then
9804             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
9805               found_dir="$additional_libdir"
9806               found_so="$additional_libdir/lib$name.$shlibext"
9807               if test -f "$additional_libdir/lib$name.la"; then
9808                 found_la="$additional_libdir/lib$name.la"
9809               fi
9810             else
9811               if test -f "$additional_libdir/lib$name.$libext"; then
9812                 found_dir="$additional_libdir"
9813                 found_a="$additional_libdir/lib$name.$libext"
9814                 if test -f "$additional_libdir/lib$name.la"; then
9815                   found_la="$additional_libdir/lib$name.la"
9816                 fi
9817               fi
9818             fi
9819           fi
9820           if test "X$found_dir" = "X"; then
9821             for x in $LDFLAGS $LTLIBMPFR; do
9822
9823   acl_save_prefix="$prefix"
9824   prefix="$acl_final_prefix"
9825   acl_save_exec_prefix="$exec_prefix"
9826   exec_prefix="$acl_final_exec_prefix"
9827   eval x=\"$x\"
9828   exec_prefix="$acl_save_exec_prefix"
9829   prefix="$acl_save_prefix"
9830
9831               case "$x" in
9832                 -L*)
9833                   dir=`echo "X$x" | sed -e 's/^X-L//'`
9834                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
9835                     found_dir="$dir"
9836                     found_so="$dir/lib$name.$shlibext"
9837                     if test -f "$dir/lib$name.la"; then
9838                       found_la="$dir/lib$name.la"
9839                     fi
9840                   else
9841                     if test -f "$dir/lib$name.$libext"; then
9842                       found_dir="$dir"
9843                       found_a="$dir/lib$name.$libext"
9844                       if test -f "$dir/lib$name.la"; then
9845                         found_la="$dir/lib$name.la"
9846                       fi
9847                     fi
9848                   fi
9849                   ;;
9850               esac
9851               if test "X$found_dir" != "X"; then
9852                 break
9853               fi
9854             done
9855           fi
9856           if test "X$found_dir" != "X"; then
9857                         LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$found_dir -l$name"
9858             if test "X$found_so" != "X"; then
9859                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
9860                                 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9861               else
9862                                                                                 haveit=
9863                 for x in $ltrpathdirs; do
9864                   if test "X$x" = "X$found_dir"; then
9865                     haveit=yes
9866                     break
9867                   fi
9868                 done
9869                 if test -z "$haveit"; then
9870                   ltrpathdirs="$ltrpathdirs $found_dir"
9871                 fi
9872                                 if test "$hardcode_direct" = yes; then
9873                                                       LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9874                 else
9875                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
9876                                                             LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9877                                                             haveit=
9878                     for x in $rpathdirs; do
9879                       if test "X$x" = "X$found_dir"; then
9880                         haveit=yes
9881                         break
9882                       fi
9883                     done
9884                     if test -z "$haveit"; then
9885                       rpathdirs="$rpathdirs $found_dir"
9886                     fi
9887                   else
9888                                                                                 haveit=
9889                     for x in $LDFLAGS $LIBMPFR; do
9890
9891   acl_save_prefix="$prefix"
9892   prefix="$acl_final_prefix"
9893   acl_save_exec_prefix="$exec_prefix"
9894   exec_prefix="$acl_final_exec_prefix"
9895   eval x=\"$x\"
9896   exec_prefix="$acl_save_exec_prefix"
9897   prefix="$acl_save_prefix"
9898
9899                       if test "X$x" = "X-L$found_dir"; then
9900                         haveit=yes
9901                         break
9902                       fi
9903                     done
9904                     if test -z "$haveit"; then
9905                       LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir"
9906                     fi
9907                     if test "$hardcode_minus_L" != no; then
9908                                                                                         LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_so"
9909                     else
9910                                                                                                                                                                                 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
9911                     fi
9912                   fi
9913                 fi
9914               fi
9915             else
9916               if test "X$found_a" != "X"; then
9917                                 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$found_a"
9918               else
9919                                                 LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$found_dir -l$name"
9920               fi
9921             fi
9922                         additional_includedir=
9923             case "$found_dir" in
9924               */lib | */lib/)
9925                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
9926                 additional_includedir="$basedir/include"
9927                 ;;
9928             esac
9929             if test "X$additional_includedir" != "X"; then
9930                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
9931                 haveit=
9932                 if test "X$additional_includedir" = "X/usr/local/include"; then
9933                   if test -n "$GCC"; then
9934                     case $host_os in
9935                       linux*) haveit=yes;;
9936                     esac
9937                   fi
9938                 fi
9939                 if test -z "$haveit"; then
9940                   for x in $CPPFLAGS $INCMPFR; do
9941
9942   acl_save_prefix="$prefix"
9943   prefix="$acl_final_prefix"
9944   acl_save_exec_prefix="$exec_prefix"
9945   exec_prefix="$acl_final_exec_prefix"
9946   eval x=\"$x\"
9947   exec_prefix="$acl_save_exec_prefix"
9948   prefix="$acl_save_prefix"
9949
9950                     if test "X$x" = "X-I$additional_includedir"; then
9951                       haveit=yes
9952                       break
9953                     fi
9954                   done
9955                   if test -z "$haveit"; then
9956                     if test -d "$additional_includedir"; then
9957                                             INCMPFR="${INCMPFR}${INCMPFR:+ }-I$additional_includedir"
9958                     fi
9959                   fi
9960                 fi
9961               fi
9962             fi
9963                         if test -n "$found_la"; then
9964                                                         save_libdir="$libdir"
9965               case "$found_la" in
9966                 */* | *\\*) . "$found_la" ;;
9967                 *) . "./$found_la" ;;
9968               esac
9969               libdir="$save_libdir"
9970                             for dep in $dependency_libs; do
9971                 case "$dep" in
9972                   -L*)
9973                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9974                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
9975                       haveit=
9976                       if test "X$additional_libdir" = "X/usr/local/lib"; then
9977                         if test -n "$GCC"; then
9978                           case $host_os in
9979                             linux*) haveit=yes;;
9980                           esac
9981                         fi
9982                       fi
9983                       if test -z "$haveit"; then
9984                         haveit=
9985                         for x in $LDFLAGS $LIBMPFR; do
9986
9987   acl_save_prefix="$prefix"
9988   prefix="$acl_final_prefix"
9989   acl_save_exec_prefix="$exec_prefix"
9990   exec_prefix="$acl_final_exec_prefix"
9991   eval x=\"$x\"
9992   exec_prefix="$acl_save_exec_prefix"
9993   prefix="$acl_save_prefix"
9994
9995                           if test "X$x" = "X-L$additional_libdir"; then
9996                             haveit=yes
9997                             break
9998                           fi
9999                         done
10000                         if test -z "$haveit"; then
10001                           if test -d "$additional_libdir"; then
10002                                                         LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-L$additional_libdir"
10003                           fi
10004                         fi
10005                         haveit=
10006                         for x in $LDFLAGS $LTLIBMPFR; do
10007
10008   acl_save_prefix="$prefix"
10009   prefix="$acl_final_prefix"
10010   acl_save_exec_prefix="$exec_prefix"
10011   exec_prefix="$acl_final_exec_prefix"
10012   eval x=\"$x\"
10013   exec_prefix="$acl_save_exec_prefix"
10014   prefix="$acl_save_prefix"
10015
10016                           if test "X$x" = "X-L$additional_libdir"; then
10017                             haveit=yes
10018                             break
10019                           fi
10020                         done
10021                         if test -z "$haveit"; then
10022                           if test -d "$additional_libdir"; then
10023                                                         LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-L$additional_libdir"
10024                           fi
10025                         fi
10026                       fi
10027                     fi
10028                     ;;
10029                   -R*)
10030                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
10031                     if test "$enable_rpath" != no; then
10032                                                                   haveit=
10033                       for x in $rpathdirs; do
10034                         if test "X$x" = "X$dir"; then
10035                           haveit=yes
10036                           break
10037                         fi
10038                       done
10039                       if test -z "$haveit"; then
10040                         rpathdirs="$rpathdirs $dir"
10041                       fi
10042                                                                   haveit=
10043                       for x in $ltrpathdirs; do
10044                         if test "X$x" = "X$dir"; then
10045                           haveit=yes
10046                           break
10047                         fi
10048                       done
10049                       if test -z "$haveit"; then
10050                         ltrpathdirs="$ltrpathdirs $dir"
10051                       fi
10052                     fi
10053                     ;;
10054                   -l*)
10055                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
10056                     ;;
10057                   *.la)
10058                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10059                     ;;
10060                   *)
10061                                         LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$dep"
10062                     LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }$dep"
10063                     ;;
10064                 esac
10065               done
10066             fi
10067           else
10068                                                             LIBMPFR="${LIBMPFR}${LIBMPFR:+ }-l$name"
10069             LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-l$name"
10070           fi
10071         fi
10072       fi
10073     done
10074   done
10075   if test "X$rpathdirs" != "X"; then
10076     if test -n "$hardcode_libdir_separator"; then
10077                         alldirs=
10078       for found_dir in $rpathdirs; do
10079         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
10080       done
10081             acl_save_libdir="$libdir"
10082       libdir="$alldirs"
10083       eval flag=\"$hardcode_libdir_flag_spec\"
10084       libdir="$acl_save_libdir"
10085       LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10086     else
10087             for found_dir in $rpathdirs; do
10088         acl_save_libdir="$libdir"
10089         libdir="$found_dir"
10090         eval flag=\"$hardcode_libdir_flag_spec\"
10091         libdir="$acl_save_libdir"
10092         LIBMPFR="${LIBMPFR}${LIBMPFR:+ }$flag"
10093       done
10094     fi
10095   fi
10096   if test "X$ltrpathdirs" != "X"; then
10097             for found_dir in $ltrpathdirs; do
10098       LTLIBMPFR="${LTLIBMPFR}${LTLIBMPFR:+ }-R$found_dir"
10099     done
10100   fi
10101
10102
10103         ac_save_CPPFLAGS="$CPPFLAGS"
10104
10105   for element in $INCMPFR; do
10106     haveit=
10107     for x in $CPPFLAGS; do
10108
10109   acl_save_prefix="$prefix"
10110   prefix="$acl_final_prefix"
10111   acl_save_exec_prefix="$exec_prefix"
10112   exec_prefix="$acl_final_exec_prefix"
10113   eval x=\"$x\"
10114   exec_prefix="$acl_save_exec_prefix"
10115   prefix="$acl_save_prefix"
10116
10117       if test "X$x" = "X$element"; then
10118         haveit=yes
10119         break
10120       fi
10121     done
10122     if test -z "$haveit"; then
10123       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10124     fi
10125   done
10126
10127
10128   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmpfr" >&5
10129 $as_echo_n "checking for libmpfr... " >&6; }
10130 if ${ac_cv_libmpfr+:} false; then :
10131   $as_echo_n "(cached) " >&6
10132 else
10133
10134     ac_save_LIBS="$LIBS"
10135     LIBS="$LIBS $LIBMPFR"
10136     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10137 /* end confdefs.h.  */
10138 #include <mpfr.h>
10139 int
10140 main ()
10141 {
10142 mpfr_exp_t exp; mpfr_t x;
10143                          mpfr_frexp (&exp, x, x, MPFR_RNDN);
10144   ;
10145   return 0;
10146 }
10147 _ACEOF
10148 if ac_fn_c_try_link "$LINENO"; then :
10149   ac_cv_libmpfr=yes
10150 else
10151   ac_cv_libmpfr=no
10152 fi
10153 rm -f core conftest.err conftest.$ac_objext \
10154     conftest$ac_exeext conftest.$ac_ext
10155     LIBS="$ac_save_LIBS"
10156
10157 fi
10158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libmpfr" >&5
10159 $as_echo "$ac_cv_libmpfr" >&6; }
10160   if test "$ac_cv_libmpfr" = yes; then
10161     HAVE_LIBMPFR=yes
10162
10163 $as_echo "#define HAVE_LIBMPFR 1" >>confdefs.h
10164
10165     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libmpfr" >&5
10166 $as_echo_n "checking how to link with libmpfr... " >&6; }
10167     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBMPFR" >&5
10168 $as_echo "$LIBMPFR" >&6; }
10169   else
10170     HAVE_LIBMPFR=no
10171             CPPFLAGS="$ac_save_CPPFLAGS"
10172     LIBMPFR=
10173     LTLIBMPFR=
10174   fi
10175
10176
10177
10178
10179
10180
10181   if test "$HAVE_LIBMPFR" != yes; then
10182     if test "$with_mpfr" = yes; then
10183       as_fn_error $? "MPFR is missing or unusable" "$LINENO" 5
10184     else
10185       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR is missing or unusable; some features may be unavailable." >&5
10186 $as_echo "$as_me: WARNING: MPFR is missing or unusable; some features may be unavailable." >&2;}
10187     fi
10188   fi
10189 fi
10190
10191 # --------------------- #
10192 # Check for libpython.  #
10193 # --------------------- #
10194
10195
10196
10197
10198
10199
10200 # Check whether --with-python was given.
10201 if test "${with_python+set}" = set; then :
10202   withval=$with_python;
10203 else
10204   with_python=auto
10205 fi
10206
10207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use python" >&5
10208 $as_echo_n "checking whether to use python... " >&6; }
10209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
10210 $as_echo "$with_python" >&6; }
10211
10212 if test "${with_python}" = no; then
10213   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python support disabled; some features may be unavailable." >&5
10214 $as_echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
10215   have_libpython=no
10216 else
10217   case "${with_python}" in
10218   [\\/]* | ?:[\\/]*)
10219     if test -d ${with_python}; then
10220       # Assume the python binary is ${with_python}/bin/python.
10221       python_prog="${with_python}/bin/python"
10222       python_prefix=
10223       # If python does not exit ${with_python}/bin, then try in
10224       # ${with_python}.  On Windows/MinGW, this is where the Python
10225       # executable is.
10226       if test ! -x "${python_prog}"; then
10227         python_prog="${with_python}/python"
10228         python_prefix=
10229       fi
10230       if test ! -x "${python_prog}"; then
10231         # Fall back to gdb 7.0/7.1 behaviour.
10232         python_prog=missing
10233         python_prefix=${with_python}
10234       fi
10235     elif test -x "${with_python}"; then
10236       # While we can't run python compiled for $host (unless host == build),
10237       # the user could write a script that provides the needed information,
10238       # so we support that.
10239       python_prog=${with_python}
10240       python_prefix=
10241     else
10242       as_fn_error $? "invalid value for --with-python" "$LINENO" 5
10243     fi
10244     ;;
10245   */*)
10246     # Disallow --with-python=foo/bar.
10247     as_fn_error $? "invalid value for --with-python" "$LINENO" 5
10248     ;;
10249   *)
10250     # The user has either specified auto, yes, or the name of the python
10251     # program assumed to be in $PATH.
10252     python_prefix=
10253     case "${with_python}" in
10254     yes | auto)
10255       if test ${build} = ${host}; then
10256         # Extract the first word of "python", so it can be a program name with args.
10257 set dummy python; ac_word=$2
10258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10259 $as_echo_n "checking for $ac_word... " >&6; }
10260 if ${ac_cv_path_python_prog_path+:} false; then :
10261   $as_echo_n "(cached) " >&6
10262 else
10263   case $python_prog_path in
10264   [\\/]* | ?:[\\/]*)
10265   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10266   ;;
10267   *)
10268   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10269 for as_dir in $PATH
10270 do
10271   IFS=$as_save_IFS
10272   test -z "$as_dir" && as_dir=.
10273     for ac_exec_ext in '' $ac_executable_extensions; do
10274   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10275     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10276     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10277     break 2
10278   fi
10279 done
10280   done
10281 IFS=$as_save_IFS
10282
10283   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10284   ;;
10285 esac
10286 fi
10287 python_prog_path=$ac_cv_path_python_prog_path
10288 if test -n "$python_prog_path"; then
10289   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10290 $as_echo "$python_prog_path" >&6; }
10291 else
10292   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10293 $as_echo "no" >&6; }
10294 fi
10295
10296
10297         if test "${python_prog_path}" = missing; then
10298           python_prog=missing
10299         else
10300           python_prog=${python_prog_path}
10301         fi
10302       else
10303         # Not much we can do except assume the cross-compiler will find the
10304         # right files.
10305         python_prog=missing
10306       fi
10307       ;;
10308     *)
10309       # While we can't run python compiled for $host (unless host == build),
10310       # the user could write a script that provides the needed information,
10311       # so we support that.
10312       python_prog="${with_python}"
10313       # Extract the first word of "${python_prog}", so it can be a program name with args.
10314 set dummy ${python_prog}; ac_word=$2
10315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10316 $as_echo_n "checking for $ac_word... " >&6; }
10317 if ${ac_cv_path_python_prog_path+:} false; then :
10318   $as_echo_n "(cached) " >&6
10319 else
10320   case $python_prog_path in
10321   [\\/]* | ?:[\\/]*)
10322   ac_cv_path_python_prog_path="$python_prog_path" # Let the user override the test with a path.
10323   ;;
10324   *)
10325   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10326 for as_dir in $PATH
10327 do
10328   IFS=$as_save_IFS
10329   test -z "$as_dir" && as_dir=.
10330     for ac_exec_ext in '' $ac_executable_extensions; do
10331   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10332     ac_cv_path_python_prog_path="$as_dir/$ac_word$ac_exec_ext"
10333     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10334     break 2
10335   fi
10336 done
10337   done
10338 IFS=$as_save_IFS
10339
10340   test -z "$ac_cv_path_python_prog_path" && ac_cv_path_python_prog_path="missing"
10341   ;;
10342 esac
10343 fi
10344 python_prog_path=$ac_cv_path_python_prog_path
10345 if test -n "$python_prog_path"; then
10346   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_prog_path" >&5
10347 $as_echo "$python_prog_path" >&6; }
10348 else
10349   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10350 $as_echo "no" >&6; }
10351 fi
10352
10353
10354       if test "${python_prog_path}" = missing; then
10355         as_fn_error $? "unable to find python program ${python_prog}" "$LINENO" 5
10356       fi
10357       ;;
10358     esac
10359   esac
10360
10361   if test "${python_prog}" != missing; then
10362     # We have a python program to use, but it may be too old.
10363     # Don't flag an error for --with-python=auto (the default).
10364     have_python_config=yes
10365     python_includes=`${python_prog} ${srcdir}/python/python-config.py --includes`
10366     if test $? != 0; then
10367       have_python_config=failed
10368       if test "${with_python}" != auto; then
10369         as_fn_error $? "failure running python-config --includes" "$LINENO" 5
10370       fi
10371     fi
10372     python_libs=`${python_prog} ${srcdir}/python/python-config.py --ldflags`
10373     if test $? != 0; then
10374       have_python_config=failed
10375       if test "${with_python}" != auto; then
10376         as_fn_error $? "failure running python-config --ldflags" "$LINENO" 5
10377       fi
10378     fi
10379     python_prefix=`${python_prog} ${srcdir}/python/python-config.py --exec-prefix`
10380     if test $? != 0; then
10381       have_python_config=failed
10382       if test "${with_python}" != auto; then
10383         as_fn_error $? "failure running python-config --exec-prefix" "$LINENO" 5
10384       fi
10385     fi
10386   else
10387     # We do not have a python executable we can use to determine where
10388     # to find the Python headers and libs.  We cannot guess the include
10389     # path from the python_prefix either, because that include path
10390     # depends on the Python version.  So, there is nothing much we can
10391     # do except assume that the compiler will be able to find those files.
10392     python_includes=
10393     python_libs=
10394     have_python_config=no
10395   fi
10396
10397   # If we have python-config, only try the configuration it provides.
10398   # Otherwise fallback on the old way of trying different versions of
10399   # python in turn.
10400
10401   have_libpython=no
10402   if test "${have_python_config}" = yes; then
10403     # Determine the Python version by extracting "-lpython<version>"
10404     # part of the python_libs. <version> is usually X.Y with X and Y
10405     # being decimal numbers, but can also be XY (seen on Windows).
10406     #
10407     # The extraction is performed using sed with a regular expression.
10408     # Initially, the regexp used was using the '?' quantifier to make
10409     # the dot in the version number optional.  Unfortunately, this
10410     # does not work with non-GNU versions of sed because, because of
10411     # what looks like a limitation (the '?' quantifier does not work
10412     # with back-references).  We work around this limitation by using
10413     # the '*' quantifier instead.  It means that, in theory, we might
10414     # match unexpected version strings such as "-lpython2..7", but
10415     # this seems unlikely in practice.  And even if that happens,
10416     # an error will be triggered later on, when checking that version
10417     # number.
10418     python_version=`echo " ${python_libs} " \
10419                          | sed -e 's,^.* -l\(python[0-9]*[.]*[0-9]*\).*$,\1,'`
10420     case "${python_version}" in
10421     python*)
10422
10423   version=${python_version}
10424
10425   new_CPPFLAGS=${python_includes}
10426   new_LIBS=${python_libs}
10427   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10428 $as_echo_n "checking for ${version}... " >&6; }
10429   save_CPPFLAGS=$CPPFLAGS
10430   save_LIBS=$LIBS
10431   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10432   LIBS="$new_LIBS $LIBS"
10433   found_usable_python=no
10434   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10435 /* end confdefs.h.  */
10436 #include "Python.h"
10437 int
10438 main ()
10439 {
10440 Py_Initialize ();
10441   ;
10442   return 0;
10443 }
10444 _ACEOF
10445 if ac_fn_c_try_link "$LINENO"; then :
10446   have_libpython=${version}
10447                   found_usable_python=yes
10448                   PYTHON_CPPFLAGS=$new_CPPFLAGS
10449                   PYTHON_LIBS=$new_LIBS
10450 fi
10451 rm -f core conftest.err conftest.$ac_objext \
10452     conftest$ac_exeext conftest.$ac_ext
10453   CPPFLAGS=$save_CPPFLAGS
10454   LIBS=$save_LIBS
10455   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10456 $as_echo "${found_usable_python}" >&6; }
10457
10458       ;;
10459     *)
10460       as_fn_error $? "unable to determine python version from ${python_libs}" "$LINENO" 5
10461       ;;
10462     esac
10463   elif test "${have_python_config}" != failed; then
10464     if test "${have_libpython}" = no; then
10465
10466   version=python2.7
10467
10468   new_CPPFLAGS=${python_includes}
10469   new_LIBS="-lpython2.7 ${python_libs}"
10470   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10471 $as_echo_n "checking for ${version}... " >&6; }
10472   save_CPPFLAGS=$CPPFLAGS
10473   save_LIBS=$LIBS
10474   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10475   LIBS="$new_LIBS $LIBS"
10476   found_usable_python=no
10477   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10478 /* end confdefs.h.  */
10479 #include "Python.h"
10480 int
10481 main ()
10482 {
10483 Py_Initialize ();
10484   ;
10485   return 0;
10486 }
10487 _ACEOF
10488 if ac_fn_c_try_link "$LINENO"; then :
10489   have_libpython=${version}
10490                   found_usable_python=yes
10491                   PYTHON_CPPFLAGS=$new_CPPFLAGS
10492                   PYTHON_LIBS=$new_LIBS
10493 fi
10494 rm -f core conftest.err conftest.$ac_objext \
10495     conftest$ac_exeext conftest.$ac_ext
10496   CPPFLAGS=$save_CPPFLAGS
10497   LIBS=$save_LIBS
10498   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10499 $as_echo "${found_usable_python}" >&6; }
10500
10501     fi
10502     if test "${have_libpython}" = no; then
10503
10504   version=python2.6
10505
10506   new_CPPFLAGS=${python_includes}
10507   new_LIBS="-lpython2.6 ${python_libs}"
10508   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
10509 $as_echo_n "checking for ${version}... " >&6; }
10510   save_CPPFLAGS=$CPPFLAGS
10511   save_LIBS=$LIBS
10512   CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10513   LIBS="$new_LIBS $LIBS"
10514   found_usable_python=no
10515   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10516 /* end confdefs.h.  */
10517 #include "Python.h"
10518 int
10519 main ()
10520 {
10521 Py_Initialize ();
10522   ;
10523   return 0;
10524 }
10525 _ACEOF
10526 if ac_fn_c_try_link "$LINENO"; then :
10527   have_libpython=${version}
10528                   found_usable_python=yes
10529                   PYTHON_CPPFLAGS=$new_CPPFLAGS
10530                   PYTHON_LIBS=$new_LIBS
10531 fi
10532 rm -f core conftest.err conftest.$ac_objext \
10533     conftest$ac_exeext conftest.$ac_ext
10534   CPPFLAGS=$save_CPPFLAGS
10535   LIBS=$save_LIBS
10536   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_python}" >&5
10537 $as_echo "${found_usable_python}" >&6; }
10538
10539     fi
10540   fi
10541   if test "${have_libpython}" = python2.7 -o "${have_libpython}" = python27; then
10542
10543 $as_echo "#define HAVE_LIBPYTHON2_7 1" >>confdefs.h
10544
10545   elif test "${have_libpython}" = python2.6 -o "${have_libpython}" = python26; then
10546
10547 $as_echo "#define HAVE_LIBPYTHON2_6 1" >>confdefs.h
10548
10549   fi
10550
10551   if test "${have_libpython}" = no; then
10552     case "${with_python}" in
10553     yes)
10554       as_fn_error $? "python is missing or unusable" "$LINENO" 5
10555       ;;
10556     auto)
10557       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: python is missing or unusable; some features may be unavailable." >&5
10558 $as_echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
10559       ;;
10560     *)
10561       as_fn_error $? "no usable python found at ${with_python}" "$LINENO" 5
10562       ;;
10563     esac
10564   else
10565     if test -n "${python_prefix}"; then
10566
10567 cat >>confdefs.h <<_ACEOF
10568 #define WITH_PYTHON_PATH "${python_prefix}"
10569 _ACEOF
10570
10571
10572   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
10573      if test "x$prefix" = xNONE; then
10574         test_prefix=/usr/local
10575      else
10576         test_prefix=$prefix
10577      fi
10578   else
10579      test_prefix=$exec_prefix
10580   fi
10581   value=0
10582   case ${python_prefix} in
10583      "${test_prefix}"|"${test_prefix}/"*|\
10584         '${exec_prefix}'|'${exec_prefix}/'*)
10585      value=1
10586      ;;
10587   esac
10588
10589 cat >>confdefs.h <<_ACEOF
10590 #define PYTHON_PATH_RELOCATABLE $value
10591 _ACEOF
10592
10593
10594     fi
10595   fi
10596 fi
10597
10598 if test "${have_libpython}" != no; then
10599
10600 $as_echo "#define HAVE_PYTHON 1" >>confdefs.h
10601
10602   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
10603   CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
10604   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
10605   CONFIG_INSTALL="$CONFIG_INSTALL install-python"
10606   ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
10607
10608   # Flags needed to compile Python code (taken from python-config --cflags).
10609   # We cannot call python-config directly because it will output whatever was
10610   # used when compiling the Python interpreter itself, including flags which
10611   # would make the python-related objects be compiled differently from the
10612   # rest of GDB (e.g., -O2 and -fPIC).
10613   if test "${GCC}" = yes; then
10614     tentative_python_cflags="-fno-strict-aliasing -fwrapv"
10615     # Python headers recommend -DNDEBUG, but it's unclear if that just
10616     # refers to building Python itself.  In release mode, though, it
10617     # doesn't hurt for the Python code in gdb to follow.
10618     $development || tentative_python_cflags="$tentative_python_cflags -DNDEBUG"
10619   fi
10620
10621   if test "x${tentative_python_cflags}" != x; then
10622     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler flags for python code" >&5
10623 $as_echo_n "checking compiler flags for python code... " >&6; }
10624     for flag in ${tentative_python_cflags}; do
10625       # Check that the compiler accepts it
10626       saved_CFLAGS="$CFLAGS"
10627       CFLAGS="$CFLAGS $flag"
10628       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10629 /* end confdefs.h.  */
10630
10631 int
10632 main ()
10633 {
10634
10635   ;
10636   return 0;
10637 }
10638 _ACEOF
10639 if ac_fn_c_try_compile "$LINENO"; then :
10640   PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
10641 fi
10642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10643       CFLAGS="$saved_CFLAGS"
10644     done
10645     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${PYTHON_CFLAGS}" >&5
10646 $as_echo "${PYTHON_CFLAGS}" >&6; }
10647   fi
10648
10649   # On x64 Windows, Python's include headers, and pyconfig.h in
10650   # particular, rely on MS_WIN64 macro to detect that it's a 64bit
10651   # version of Windows.  Unfortunately, MS_WIN64 is only defined if
10652   # _MSC_VER, a Microsoft-specific macro, is defined.  So, when
10653   # building on x64 Windows with GCC, we define MS_WIN64 ourselves.
10654   # The issue was reported to the Python community, but still isn't
10655   # solved as of 2012-10-02 (http://bugs.python.org/issue4709).
10656
10657   case "$gdb_host" in
10658     mingw64)
10659            if test "${GCC}" = yes; then
10660              CPPFLAGS="$CPPFLAGS -DMS_WIN64"
10661            fi
10662            ;;
10663   esac
10664
10665   # Note that "python -m threading" cannot be used to check for
10666   # threading support due to a bug in Python 2.7.3
10667   # (http://bugs.python.org/issue15567).
10668   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether python supports threads" >&5
10669 $as_echo_n "checking whether python supports threads... " >&6; }
10670   saved_CPPFLAGS="${CPPFLAGS}"
10671   CPPFLAGS="${PYTHON_CPPFLAGS}"
10672   # Note that the test is reversed so that python_has_threads=yes on
10673   # unexpected failures.
10674   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10675 /* end confdefs.h.  */
10676
10677 #include <Python.h>
10678 #ifdef WITH_THREAD
10679 # error
10680 #endif
10681
10682 _ACEOF
10683 if ac_fn_c_try_cpp "$LINENO"; then :
10684   python_has_threads=no
10685 else
10686   python_has_threads=yes
10687 fi
10688 rm -f conftest.err conftest.i conftest.$ac_ext
10689   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_has_threads}" >&5
10690 $as_echo "${python_has_threads}" >&6; }
10691   CPPFLAGS="${saved_CPPFLAGS}"
10692 else
10693   # Even if Python support is not compiled in, we need to have this file
10694   # included so that the "python" command, et.al., still exists.
10695   CONFIG_OBS="$CONFIG_OBS python/python.o"
10696   CONFIG_SRCS="$CONFIG_SRCS python/python.c"
10697 fi
10698
10699 # Work around Python http://bugs.python.org/issue10112.  See also
10700 # http://bugs.python.org/issue11410, otherwise -Wl,--dynamic-list has
10701 # no effect.  Note that the only test after this that uses Python is
10702 # the -rdynamic/-Wl,--dynamic-list test, and we do want that one to be
10703 # run without -export-dynamic too.
10704 PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/-Xlinker -export-dynamic//'`
10705
10706
10707
10708
10709  if test "${have_libpython}" != no; then
10710   HAVE_PYTHON_TRUE=
10711   HAVE_PYTHON_FALSE='#'
10712 else
10713   HAVE_PYTHON_TRUE='#'
10714   HAVE_PYTHON_FALSE=
10715 fi
10716
10717
10718 # -------------------- #
10719 # Check for libguile.  #
10720 # -------------------- #
10721
10722
10723
10724
10725
10726
10727 # Check whether --with-guile was given.
10728 if test "${with_guile+set}" = set; then :
10729   withval=$with_guile;
10730 else
10731   with_guile=auto
10732 fi
10733
10734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use guile" >&5
10735 $as_echo_n "checking whether to use guile... " >&6; }
10736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_guile" >&5
10737 $as_echo "$with_guile" >&6; }
10738
10739 # Extract the first word of "pkg-config", so it can be a program name with args.
10740 set dummy pkg-config; ac_word=$2
10741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10742 $as_echo_n "checking for $ac_word... " >&6; }
10743 if ${ac_cv_path_pkg_config_prog_path+:} false; then :
10744   $as_echo_n "(cached) " >&6
10745 else
10746   case $pkg_config_prog_path in
10747   [\\/]* | ?:[\\/]*)
10748   ac_cv_path_pkg_config_prog_path="$pkg_config_prog_path" # Let the user override the test with a path.
10749   ;;
10750   *)
10751   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10752 for as_dir in $PATH
10753 do
10754   IFS=$as_save_IFS
10755   test -z "$as_dir" && as_dir=.
10756     for ac_exec_ext in '' $ac_executable_extensions; do
10757   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10758     ac_cv_path_pkg_config_prog_path="$as_dir/$ac_word$ac_exec_ext"
10759     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10760     break 2
10761   fi
10762 done
10763   done
10764 IFS=$as_save_IFS
10765
10766   test -z "$ac_cv_path_pkg_config_prog_path" && ac_cv_path_pkg_config_prog_path="missing"
10767   ;;
10768 esac
10769 fi
10770 pkg_config_prog_path=$ac_cv_path_pkg_config_prog_path
10771 if test -n "$pkg_config_prog_path"; then
10772   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pkg_config_prog_path" >&5
10773 $as_echo "$pkg_config_prog_path" >&6; }
10774 else
10775   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10776 $as_echo "no" >&6; }
10777 fi
10778
10779
10780
10781 try_guile_versions="guile-2.0"
10782 have_libguile=no
10783 case "${with_guile}" in
10784 no)
10785   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: guile support disabled; some features will be unavailable." >&5
10786 $as_echo "$as_me: WARNING: guile support disabled; some features will be unavailable." >&2;}
10787   ;;
10788 auto)
10789   if test "${pkg_config_prog_path}" = "missing"; then
10790     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config not found, guile support disabled" >&5
10791 $as_echo "$as_me: WARNING: pkg-config not found, guile support disabled" >&2;}
10792   else
10793
10794   pkg_config=${pkg_config_prog_path}
10795   guile_version_list=${try_guile_versions}
10796   flag_errors=no
10797
10798   found_usable_guile=checking
10799   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10800 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10801   for guile_version in ${guile_version_list}; do
10802     ${pkg_config} --exists ${guile_version} 2>/dev/null
10803     if test $? != 0; then
10804       continue
10805     fi
10806             new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10807     if test $? != 0; then
10808       as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10809     fi
10810     new_LIBS=`${pkg_config} --libs ${guile_version}`
10811     if test $? != 0; then
10812       as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10813     fi
10814         found_usable_guile=${guile_version}
10815     break
10816   done
10817   if test "${found_usable_guile}" = "checking"; then
10818     if test "${flag_errors}" = "yes"; then
10819       as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10820     else
10821       found_usable_guile=no
10822     fi
10823   fi
10824       if test "${found_usable_guile}" != no; then
10825     save_CPPFLAGS=$CPPFLAGS
10826     save_LIBS=$LIBS
10827     CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10828     LIBS="$LIBS $new_LIBS"
10829     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10830 /* end confdefs.h.  */
10831 #include "libguile.h"
10832 int
10833 main ()
10834 {
10835 scm_init_guile ();
10836   ;
10837   return 0;
10838 }
10839 _ACEOF
10840 if ac_fn_c_try_link "$LINENO"; then :
10841   have_libguile=yes
10842                     GUILE_CPPFLAGS=$new_CPPFLAGS
10843                     GUILE_LIBS=$new_LIBS
10844 else
10845   found_usable_guile=no
10846 fi
10847 rm -f core conftest.err conftest.$ac_objext \
10848     conftest$ac_exeext conftest.$ac_ext
10849         ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
10850 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
10851
10852 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
10853
10854
10855 fi
10856
10857     CPPFLAGS=$save_CPPFLAGS
10858     LIBS=$save_LIBS
10859     if test "${found_usable_guile}" = no; then
10860       if test "${flag_errors}" = yes; then
10861         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10862 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10863 as_fn_error $? "linking guile version ${guile_version} test program failed
10864 See \`config.log' for more details" "$LINENO" 5; }
10865       fi
10866     fi
10867   fi
10868   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
10869 $as_echo "${found_usable_guile}" >&6; }
10870
10871   fi
10872   ;;
10873 yes)
10874   if test "${pkg_config_prog_path}" = "missing"; then
10875     as_fn_error $? "pkg-config not found" "$LINENO" 5
10876   fi
10877
10878   pkg_config=${pkg_config_prog_path}
10879   guile_version_list=${try_guile_versions}
10880   flag_errors=yes
10881
10882   found_usable_guile=checking
10883   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10884 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10885   for guile_version in ${guile_version_list}; do
10886     ${pkg_config} --exists ${guile_version} 2>/dev/null
10887     if test $? != 0; then
10888       continue
10889     fi
10890             new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10891     if test $? != 0; then
10892       as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10893     fi
10894     new_LIBS=`${pkg_config} --libs ${guile_version}`
10895     if test $? != 0; then
10896       as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10897     fi
10898         found_usable_guile=${guile_version}
10899     break
10900   done
10901   if test "${found_usable_guile}" = "checking"; then
10902     if test "${flag_errors}" = "yes"; then
10903       as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10904     else
10905       found_usable_guile=no
10906     fi
10907   fi
10908       if test "${found_usable_guile}" != no; then
10909     save_CPPFLAGS=$CPPFLAGS
10910     save_LIBS=$LIBS
10911     CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10912     LIBS="$LIBS $new_LIBS"
10913     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10914 /* end confdefs.h.  */
10915 #include "libguile.h"
10916 int
10917 main ()
10918 {
10919 scm_init_guile ();
10920   ;
10921   return 0;
10922 }
10923 _ACEOF
10924 if ac_fn_c_try_link "$LINENO"; then :
10925   have_libguile=yes
10926                     GUILE_CPPFLAGS=$new_CPPFLAGS
10927                     GUILE_LIBS=$new_LIBS
10928 else
10929   found_usable_guile=no
10930 fi
10931 rm -f core conftest.err conftest.$ac_objext \
10932     conftest$ac_exeext conftest.$ac_ext
10933         ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
10934 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
10935
10936 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
10937
10938
10939 fi
10940
10941     CPPFLAGS=$save_CPPFLAGS
10942     LIBS=$save_LIBS
10943     if test "${found_usable_guile}" = no; then
10944       if test "${flag_errors}" = yes; then
10945         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10946 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10947 as_fn_error $? "linking guile version ${guile_version} test program failed
10948 See \`config.log' for more details" "$LINENO" 5; }
10949       fi
10950     fi
10951   fi
10952   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
10953 $as_echo "${found_usable_guile}" >&6; }
10954
10955   ;;
10956 [\\/]* | ?:[\\/]*)
10957   if test -x "${with_guile}"; then
10958
10959   pkg_config=${with_guile}
10960   guile_version_list=${try_guile_versions}
10961   flag_errors=yes
10962
10963   found_usable_guile=checking
10964   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
10965 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
10966   for guile_version in ${guile_version_list}; do
10967     ${pkg_config} --exists ${guile_version} 2>/dev/null
10968     if test $? != 0; then
10969       continue
10970     fi
10971             new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
10972     if test $? != 0; then
10973       as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
10974     fi
10975     new_LIBS=`${pkg_config} --libs ${guile_version}`
10976     if test $? != 0; then
10977       as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
10978     fi
10979         found_usable_guile=${guile_version}
10980     break
10981   done
10982   if test "${found_usable_guile}" = "checking"; then
10983     if test "${flag_errors}" = "yes"; then
10984       as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
10985     else
10986       found_usable_guile=no
10987     fi
10988   fi
10989       if test "${found_usable_guile}" != no; then
10990     save_CPPFLAGS=$CPPFLAGS
10991     save_LIBS=$LIBS
10992     CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
10993     LIBS="$LIBS $new_LIBS"
10994     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10995 /* end confdefs.h.  */
10996 #include "libguile.h"
10997 int
10998 main ()
10999 {
11000 scm_init_guile ();
11001   ;
11002   return 0;
11003 }
11004 _ACEOF
11005 if ac_fn_c_try_link "$LINENO"; then :
11006   have_libguile=yes
11007                     GUILE_CPPFLAGS=$new_CPPFLAGS
11008                     GUILE_LIBS=$new_LIBS
11009 else
11010   found_usable_guile=no
11011 fi
11012 rm -f core conftest.err conftest.$ac_objext \
11013     conftest$ac_exeext conftest.$ac_ext
11014         ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11015 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11016
11017 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11018
11019
11020 fi
11021
11022     CPPFLAGS=$save_CPPFLAGS
11023     LIBS=$save_LIBS
11024     if test "${found_usable_guile}" = no; then
11025       if test "${flag_errors}" = yes; then
11026         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11027 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11028 as_fn_error $? "linking guile version ${guile_version} test program failed
11029 See \`config.log' for more details" "$LINENO" 5; }
11030       fi
11031     fi
11032   fi
11033   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11034 $as_echo "${found_usable_guile}" >&6; }
11035
11036   else
11037     as_fn_error $? "Guile config program not executable: ${with_guile}" "$LINENO" 5
11038   fi
11039   ;;
11040 "" | */*)
11041   # Disallow --with=guile="" and --with-guile=foo/bar.
11042   as_fn_error $? "invalid value for --with-guile" "$LINENO" 5
11043   ;;
11044 *)
11045   # A space separate list of guile versions to try, in order.
11046   if test "${pkg_config_prog_path}" = "missing"; then
11047     as_fn_error $? "pkg-config not found" "$LINENO" 5
11048   fi
11049
11050   pkg_config=${pkg_config_prog_path}
11051   guile_version_list=${with_guile}
11052   flag_errors=yes
11053
11054   found_usable_guile=checking
11055   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable guile from ${pkg_config}" >&5
11056 $as_echo_n "checking for usable guile from ${pkg_config}... " >&6; }
11057   for guile_version in ${guile_version_list}; do
11058     ${pkg_config} --exists ${guile_version} 2>/dev/null
11059     if test $? != 0; then
11060       continue
11061     fi
11062             new_CPPFLAGS=`${pkg_config} --cflags ${guile_version}`
11063     if test $? != 0; then
11064       as_fn_error $? "failure running pkg-config --cflags ${guile_version}" "$LINENO" 5
11065     fi
11066     new_LIBS=`${pkg_config} --libs ${guile_version}`
11067     if test $? != 0; then
11068       as_fn_error $? "failure running pkg-config --libs ${guile_version}" "$LINENO" 5
11069     fi
11070         found_usable_guile=${guile_version}
11071     break
11072   done
11073   if test "${found_usable_guile}" = "checking"; then
11074     if test "${flag_errors}" = "yes"; then
11075       as_fn_error $? "unable to find usable guile version from \"${guile_version_list}\"" "$LINENO" 5
11076     else
11077       found_usable_guile=no
11078     fi
11079   fi
11080       if test "${found_usable_guile}" != no; then
11081     save_CPPFLAGS=$CPPFLAGS
11082     save_LIBS=$LIBS
11083     CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
11084     LIBS="$LIBS $new_LIBS"
11085     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11086 /* end confdefs.h.  */
11087 #include "libguile.h"
11088 int
11089 main ()
11090 {
11091 scm_init_guile ();
11092   ;
11093   return 0;
11094 }
11095 _ACEOF
11096 if ac_fn_c_try_link "$LINENO"; then :
11097   have_libguile=yes
11098                     GUILE_CPPFLAGS=$new_CPPFLAGS
11099                     GUILE_LIBS=$new_LIBS
11100 else
11101   found_usable_guile=no
11102 fi
11103 rm -f core conftest.err conftest.$ac_objext \
11104     conftest$ac_exeext conftest.$ac_ext
11105         ac_fn_c_check_func "$LINENO" "scm_set_automatic_finalization_enabled" "ac_cv_func_scm_set_automatic_finalization_enabled"
11106 if test "x$ac_cv_func_scm_set_automatic_finalization_enabled" = xyes; then :
11107
11108 $as_echo "#define HAVE_GUILE_MANUAL_FINALIZATION 1" >>confdefs.h
11109
11110
11111 fi
11112
11113     CPPFLAGS=$save_CPPFLAGS
11114     LIBS=$save_LIBS
11115     if test "${found_usable_guile}" = no; then
11116       if test "${flag_errors}" = yes; then
11117         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11118 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11119 as_fn_error $? "linking guile version ${guile_version} test program failed
11120 See \`config.log' for more details" "$LINENO" 5; }
11121       fi
11122     fi
11123   fi
11124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${found_usable_guile}" >&5
11125 $as_echo "${found_usable_guile}" >&6; }
11126
11127   ;;
11128 esac
11129
11130 if test "${have_libguile}" != no; then
11131     case "${with_guile}" in
11132   [\\/]* | ?:[\\/]*)
11133
11134   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11135 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11136 if ${ac_cv_guild_program_name+:} false; then :
11137   $as_echo_n "(cached) " >&6
11138 else
11139   ac_cv_guild_program_name="`"${with_guile}" --variable guild "${guile_version}"`"
11140
11141      # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11142      # the 'guild' and 'bindir' variables.  In that case, try to guess
11143      # what the program name is, at the risk of getting it wrong if
11144      # Guile was configured with '--program-suffix' or similar.
11145      if test "x$ac_cv_guild_program_name" = "x"; then
11146        guile_exec_prefix="`"${with_guile}" --variable exec_prefix "${guile_version}"`"
11147        ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11148      fi
11149
11150 fi
11151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11152 $as_echo "$ac_cv_guild_program_name" >&6; }
11153
11154   if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11155     as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11156   fi
11157
11158   GUILD="$ac_cv_guild_program_name"
11159
11160
11161     ;;
11162   *)
11163
11164   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the absolute file name of the 'guild' command" >&5
11165 $as_echo_n "checking for the absolute file name of the 'guild' command... " >&6; }
11166 if ${ac_cv_guild_program_name+:} false; then :
11167   $as_echo_n "(cached) " >&6
11168 else
11169   ac_cv_guild_program_name="`"${pkg_config_prog_path}" --variable guild "${guile_version}"`"
11170
11171      # In Guile up to 2.0.11 included, guile-2.0.pc would not define
11172      # the 'guild' and 'bindir' variables.  In that case, try to guess
11173      # what the program name is, at the risk of getting it wrong if
11174      # Guile was configured with '--program-suffix' or similar.
11175      if test "x$ac_cv_guild_program_name" = "x"; then
11176        guile_exec_prefix="`"${pkg_config_prog_path}" --variable exec_prefix "${guile_version}"`"
11177        ac_cv_guild_program_name="$guile_exec_prefix/bin/guild"
11178      fi
11179
11180 fi
11181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_program_name" >&5
11182 $as_echo "$ac_cv_guild_program_name" >&6; }
11183
11184   if ! "$ac_cv_guild_program_name" --version >&5 2>&5; then
11185     as_fn_error $? "'$ac_cv_guild_program_name' appears to be unusable" "$LINENO" 5
11186   fi
11187
11188   GUILD="$ac_cv_guild_program_name"
11189
11190
11191     ;;
11192   esac
11193
11194
11195   if test "$cross_compiling" = no; then
11196     GUILD_TARGET_FLAG=
11197   else
11198     GUILD_TARGET_FLAG="--target=$host"
11199   fi
11200
11201
11202
11203
11204   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether guild supports this host" >&5
11205 $as_echo_n "checking whether guild supports this host... " >&6; }
11206 if ${ac_cv_guild_ok+:} false; then :
11207   $as_echo_n "(cached) " >&6
11208 else
11209   echo "$ac_cv_guild_program_name compile $GUILD_TARGET_FLAG -o conftest.go $srcdir/guile/lib/gdb/support.scm" >&5
11210      if "$ac_cv_guild_program_name" compile $GUILD_TARGET_FLAG -o conftest.go "$srcdir/guile/lib/gdb/support.scm" >&5 2>&5; then
11211        ac_cv_guild_ok=yes
11212      else
11213        ac_cv_guild_ok=no
11214      fi
11215 fi
11216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_guild_ok" >&5
11217 $as_echo "$ac_cv_guild_ok" >&6; }
11218
11219     if test "$ac_cv_guild_ok" = no; then
11220     have_libguile=no
11221     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling guile support" >&5
11222 $as_echo "$as_me: WARNING: disabling guile support" >&2;}
11223   fi
11224 fi
11225
11226 if test "${have_libguile}" != no; then
11227
11228 $as_echo "#define HAVE_GUILE 1" >>confdefs.h
11229
11230   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_GUILE_OBS)"
11231   CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_GUILE_DEPS)"
11232   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_GUILE_SRCS)"
11233   CONFIG_INSTALL="$CONFIG_INSTALL install-guile"
11234   ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_GUILE_CFLAGS)"
11235
11236     save_LIBS="$LIBS"
11237   save_CPPFLAGS="$CPPFLAGS"
11238   LIBS="$GUILE_LIBS"
11239   CPPFLAGS="$GUILE_CPPFLAGS"
11240   for ac_func in scm_new_smob
11241 do :
11242   ac_fn_c_check_func "$LINENO" "scm_new_smob" "ac_cv_func_scm_new_smob"
11243 if test "x$ac_cv_func_scm_new_smob" = xyes; then :
11244   cat >>confdefs.h <<_ACEOF
11245 #define HAVE_SCM_NEW_SMOB 1
11246 _ACEOF
11247
11248 fi
11249 done
11250
11251   LIBS="$save_LIBS"
11252   CPPFLAGS="$save_CPPFLAGS"
11253 else
11254   # Even if Guile support is not compiled in, we need to have these files
11255   # included.
11256   CONFIG_OBS="$CONFIG_OBS guile/guile.o"
11257   CONFIG_SRCS="$CONFIG_SRCS guile/guile.c"
11258 fi
11259
11260
11261  if test "${have_libguile}" != no; then
11262   HAVE_GUILE_TRUE=
11263   HAVE_GUILE_FALSE='#'
11264 else
11265   HAVE_GUILE_TRUE='#'
11266   HAVE_GUILE_FALSE=
11267 fi
11268
11269
11270 # ---------------------------- #
11271 # Check for source highlight.  #
11272 # ---------------------------- #
11273
11274 SRCHIGH_LIBS=
11275 SRCHIGH_CFLAGS=
11276
11277 # Check whether --enable-source-highlight was given.
11278 if test "${enable_source_highlight+set}" = set; then :
11279   enableval=$enable_source_highlight; case "${enableval}" in
11280   yes)  enable_source_highlight=yes ;;
11281   no)   enable_source_highlight=no  ;;
11282   *)    as_fn_error $? "bad value ${enableval} for source-highlight option" "$LINENO" 5 ;;
11283 esac
11284 else
11285   enable_source_highlight=auto
11286 fi
11287
11288
11289 if test "${enable_source_highlight}" != "no"; then
11290   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the source-highlight library" >&5
11291 $as_echo_n "checking for the source-highlight library... " >&6; }
11292   if test "${pkg_config_prog_path}" = "missing"; then
11293     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no - pkg-config not found" >&5
11294 $as_echo "no - pkg-config not found" >&6; }
11295     if test "${enable_source_highlight}" = "yes"; then
11296       as_fn_error $? "pkg-config was not found in your system" "$LINENO" 5
11297     fi
11298   else
11299     if ${pkg_config_prog_path} --exists source-highlight; then
11300       SRCHIGH_CFLAGS=`${pkg_config_prog_path} --cflags source-highlight`
11301       SRCHIGH_LIBS=`${pkg_config_prog_path} --libs source-highlight`
11302
11303 $as_echo "#define HAVE_SOURCE_HIGHLIGHT 1" >>confdefs.h
11304
11305       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11306 $as_echo "yes" >&6; }
11307     else
11308       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11309 $as_echo "no" >&6; }
11310       if test "${enable_source_highlight}" = "yes"; then
11311         as_fn_error $? "source-highlight was not found in your system" "$LINENO" 5
11312       fi
11313     fi
11314   fi
11315 fi
11316
11317
11318
11319 # --------------------- #
11320 # Check for libmcheck.  #
11321 # --------------------- #
11322
11323 # Enable -lmcheck by default (it provides cheap-enough memory mangling),
11324 # but turn it off if Python is enabled with threads, since -lmcheck is
11325 # not thread safe (http://sourceware.org/bugzilla/show_bug.cgi?id=9939),
11326 # and for releases.
11327 if test \( "${have_libpython}" = "no" -o "${python_has_threads}" = "no" \) \
11328    && $development; then
11329   libmcheck_default=yes
11330 else
11331   libmcheck_default=no
11332 fi
11333
11334   # Check whether --enable-libmcheck was given.
11335 if test "${enable_libmcheck+set}" = set; then :
11336   enableval=$enable_libmcheck; case "${enableval}" in
11337       yes | y) ENABLE_LIBMCHECK="yes" ;;
11338       no | n)  ENABLE_LIBMCHECK="no" ;;
11339       *) as_fn_error $? "bad value ${enableval} for --enable-libmcheck" "$LINENO" 5 ;;
11340     esac
11341 fi
11342
11343
11344   if test -z "${ENABLE_LIBMCHECK}"; then
11345     ENABLE_LIBMCHECK=${libmcheck_default}
11346   fi
11347
11348   if test "$ENABLE_LIBMCHECK" = "yes" ; then
11349     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lmcheck" >&5
11350 $as_echo_n "checking for main in -lmcheck... " >&6; }
11351 if ${ac_cv_lib_mcheck_main+:} false; then :
11352   $as_echo_n "(cached) " >&6
11353 else
11354   ac_check_lib_save_LIBS=$LIBS
11355 LIBS="-lmcheck  $LIBS"
11356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11357 /* end confdefs.h.  */
11358
11359
11360 int
11361 main ()
11362 {
11363 return main ();
11364   ;
11365   return 0;
11366 }
11367 _ACEOF
11368 if ac_fn_c_try_link "$LINENO"; then :
11369   ac_cv_lib_mcheck_main=yes
11370 else
11371   ac_cv_lib_mcheck_main=no
11372 fi
11373 rm -f core conftest.err conftest.$ac_objext \
11374     conftest$ac_exeext conftest.$ac_ext
11375 LIBS=$ac_check_lib_save_LIBS
11376 fi
11377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mcheck_main" >&5
11378 $as_echo "$ac_cv_lib_mcheck_main" >&6; }
11379 if test "x$ac_cv_lib_mcheck_main" = xyes; then :
11380   cat >>confdefs.h <<_ACEOF
11381 #define HAVE_LIBMCHECK 1
11382 _ACEOF
11383
11384   LIBS="-lmcheck $LIBS"
11385
11386 fi
11387
11388   fi
11389
11390
11391 if test "$ENABLE_LIBMCHECK" = "yes" \
11392         -a "${have_libpython}" != "no" \
11393         -a "${python_has_threads}" = "yes" ; then
11394   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&5
11395 $as_echo "$as_me: WARNING: --enable-libmcheck may lead to spurious crashes if threads are used in python" >&2;}
11396 fi
11397
11398
11399 # Check whether --with-intel_pt was given.
11400 if test "${with_intel_pt+set}" = set; then :
11401   withval=$with_intel_pt;
11402 else
11403   with_intel_pt=auto
11404 fi
11405
11406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use intel pt" >&5
11407 $as_echo_n "checking whether to use intel pt... " >&6; }
11408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_intel_pt" >&5
11409 $as_echo "$with_intel_pt" >&6; }
11410
11411 if test "${with_intel_pt}" = no; then
11412   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&5
11413 $as_echo "$as_me: WARNING: Intel Processor Trace support disabled; some features may be unavailable." >&2;}
11414   HAVE_LIBIPT=no
11415 else
11416   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11417 /* end confdefs.h.  */
11418
11419 #include <linux/perf_event.h>
11420 #ifndef PERF_ATTR_SIZE_VER5
11421 # error
11422 #endif
11423
11424 _ACEOF
11425 if ac_fn_c_try_cpp "$LINENO"; then :
11426   perf_event=yes
11427 else
11428   perf_event=no
11429 fi
11430 rm -f conftest.err conftest.i conftest.$ac_ext
11431   if test "$perf_event" != yes; then
11432     if test "$with_intel_pt" = yes; then
11433       as_fn_error $? "linux/perf_event.h missing or too old" "$LINENO" 5
11434     else
11435       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&5
11436 $as_echo "$as_me: WARNING: linux/perf_event.h missing or too old; some features may be unavailable." >&2;}
11437     fi
11438   fi
11439
11440
11441
11442
11443
11444
11445
11446
11447
11448     use_additional=yes
11449
11450   acl_save_prefix="$prefix"
11451   prefix="$acl_final_prefix"
11452   acl_save_exec_prefix="$exec_prefix"
11453   exec_prefix="$acl_final_exec_prefix"
11454
11455     eval additional_includedir=\"$includedir\"
11456     eval additional_libdir=\"$libdir\"
11457
11458   exec_prefix="$acl_save_exec_prefix"
11459   prefix="$acl_save_prefix"
11460
11461
11462 # Check whether --with-libipt-prefix was given.
11463 if test "${with_libipt_prefix+set}" = set; then :
11464   withval=$with_libipt_prefix;
11465     if test "X$withval" = "Xno"; then
11466       use_additional=no
11467     else
11468       if test "X$withval" = "X"; then
11469
11470   acl_save_prefix="$prefix"
11471   prefix="$acl_final_prefix"
11472   acl_save_exec_prefix="$exec_prefix"
11473   exec_prefix="$acl_final_exec_prefix"
11474
11475           eval additional_includedir=\"$includedir\"
11476           eval additional_libdir=\"$libdir\"
11477
11478   exec_prefix="$acl_save_exec_prefix"
11479   prefix="$acl_save_prefix"
11480
11481       else
11482         additional_includedir="$withval/include"
11483         additional_libdir="$withval/lib"
11484       fi
11485     fi
11486
11487 fi
11488
11489       LIBIPT=
11490   LTLIBIPT=
11491   INCIPT=
11492   rpathdirs=
11493   ltrpathdirs=
11494   names_already_handled=
11495   names_next_round='ipt '
11496   while test -n "$names_next_round"; do
11497     names_this_round="$names_next_round"
11498     names_next_round=
11499     for name in $names_this_round; do
11500       already_handled=
11501       for n in $names_already_handled; do
11502         if test "$n" = "$name"; then
11503           already_handled=yes
11504           break
11505         fi
11506       done
11507       if test -z "$already_handled"; then
11508         names_already_handled="$names_already_handled $name"
11509                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
11510         eval value=\"\$HAVE_LIB$uppername\"
11511         if test -n "$value"; then
11512           if test "$value" = yes; then
11513             eval value=\"\$LIB$uppername\"
11514             test -z "$value" || LIBIPT="${LIBIPT}${LIBIPT:+ }$value"
11515             eval value=\"\$LTLIB$uppername\"
11516             test -z "$value" || LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$value"
11517           else
11518                                     :
11519           fi
11520         else
11521                               found_dir=
11522           found_la=
11523           found_so=
11524           found_a=
11525           if test $use_additional = yes; then
11526             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
11527               found_dir="$additional_libdir"
11528               found_so="$additional_libdir/lib$name.$shlibext"
11529               if test -f "$additional_libdir/lib$name.la"; then
11530                 found_la="$additional_libdir/lib$name.la"
11531               fi
11532             else
11533               if test -f "$additional_libdir/lib$name.$libext"; then
11534                 found_dir="$additional_libdir"
11535                 found_a="$additional_libdir/lib$name.$libext"
11536                 if test -f "$additional_libdir/lib$name.la"; then
11537                   found_la="$additional_libdir/lib$name.la"
11538                 fi
11539               fi
11540             fi
11541           fi
11542           if test "X$found_dir" = "X"; then
11543             for x in $LDFLAGS $LTLIBIPT; do
11544
11545   acl_save_prefix="$prefix"
11546   prefix="$acl_final_prefix"
11547   acl_save_exec_prefix="$exec_prefix"
11548   exec_prefix="$acl_final_exec_prefix"
11549   eval x=\"$x\"
11550   exec_prefix="$acl_save_exec_prefix"
11551   prefix="$acl_save_prefix"
11552
11553               case "$x" in
11554                 -L*)
11555                   dir=`echo "X$x" | sed -e 's/^X-L//'`
11556                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
11557                     found_dir="$dir"
11558                     found_so="$dir/lib$name.$shlibext"
11559                     if test -f "$dir/lib$name.la"; then
11560                       found_la="$dir/lib$name.la"
11561                     fi
11562                   else
11563                     if test -f "$dir/lib$name.$libext"; then
11564                       found_dir="$dir"
11565                       found_a="$dir/lib$name.$libext"
11566                       if test -f "$dir/lib$name.la"; then
11567                         found_la="$dir/lib$name.la"
11568                       fi
11569                     fi
11570                   fi
11571                   ;;
11572               esac
11573               if test "X$found_dir" != "X"; then
11574                 break
11575               fi
11576             done
11577           fi
11578           if test "X$found_dir" != "X"; then
11579                         LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$found_dir -l$name"
11580             if test "X$found_so" != "X"; then
11581                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11582                                 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11583               else
11584                                                                                 haveit=
11585                 for x in $ltrpathdirs; do
11586                   if test "X$x" = "X$found_dir"; then
11587                     haveit=yes
11588                     break
11589                   fi
11590                 done
11591                 if test -z "$haveit"; then
11592                   ltrpathdirs="$ltrpathdirs $found_dir"
11593                 fi
11594                                 if test "$hardcode_direct" = yes; then
11595                                                       LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11596                 else
11597                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11598                                                             LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11599                                                             haveit=
11600                     for x in $rpathdirs; do
11601                       if test "X$x" = "X$found_dir"; then
11602                         haveit=yes
11603                         break
11604                       fi
11605                     done
11606                     if test -z "$haveit"; then
11607                       rpathdirs="$rpathdirs $found_dir"
11608                     fi
11609                   else
11610                                                                                 haveit=
11611                     for x in $LDFLAGS $LIBIPT; do
11612
11613   acl_save_prefix="$prefix"
11614   prefix="$acl_final_prefix"
11615   acl_save_exec_prefix="$exec_prefix"
11616   exec_prefix="$acl_final_exec_prefix"
11617   eval x=\"$x\"
11618   exec_prefix="$acl_save_exec_prefix"
11619   prefix="$acl_save_prefix"
11620
11621                       if test "X$x" = "X-L$found_dir"; then
11622                         haveit=yes
11623                         break
11624                       fi
11625                     done
11626                     if test -z "$haveit"; then
11627                       LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir"
11628                     fi
11629                     if test "$hardcode_minus_L" != no; then
11630                                                                                         LIBIPT="${LIBIPT}${LIBIPT:+ }$found_so"
11631                     else
11632                                                                                                                                                                                 LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
11633                     fi
11634                   fi
11635                 fi
11636               fi
11637             else
11638               if test "X$found_a" != "X"; then
11639                                 LIBIPT="${LIBIPT}${LIBIPT:+ }$found_a"
11640               else
11641                                                 LIBIPT="${LIBIPT}${LIBIPT:+ }-L$found_dir -l$name"
11642               fi
11643             fi
11644                         additional_includedir=
11645             case "$found_dir" in
11646               */lib | */lib/)
11647                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11648                 additional_includedir="$basedir/include"
11649                 ;;
11650             esac
11651             if test "X$additional_includedir" != "X"; then
11652                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
11653                 haveit=
11654                 if test "X$additional_includedir" = "X/usr/local/include"; then
11655                   if test -n "$GCC"; then
11656                     case $host_os in
11657                       linux*) haveit=yes;;
11658                     esac
11659                   fi
11660                 fi
11661                 if test -z "$haveit"; then
11662                   for x in $CPPFLAGS $INCIPT; do
11663
11664   acl_save_prefix="$prefix"
11665   prefix="$acl_final_prefix"
11666   acl_save_exec_prefix="$exec_prefix"
11667   exec_prefix="$acl_final_exec_prefix"
11668   eval x=\"$x\"
11669   exec_prefix="$acl_save_exec_prefix"
11670   prefix="$acl_save_prefix"
11671
11672                     if test "X$x" = "X-I$additional_includedir"; then
11673                       haveit=yes
11674                       break
11675                     fi
11676                   done
11677                   if test -z "$haveit"; then
11678                     if test -d "$additional_includedir"; then
11679                                             INCIPT="${INCIPT}${INCIPT:+ }-I$additional_includedir"
11680                     fi
11681                   fi
11682                 fi
11683               fi
11684             fi
11685                         if test -n "$found_la"; then
11686                                                         save_libdir="$libdir"
11687               case "$found_la" in
11688                 */* | *\\*) . "$found_la" ;;
11689                 *) . "./$found_la" ;;
11690               esac
11691               libdir="$save_libdir"
11692                             for dep in $dependency_libs; do
11693                 case "$dep" in
11694                   -L*)
11695                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11696                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
11697                       haveit=
11698                       if test "X$additional_libdir" = "X/usr/local/lib"; then
11699                         if test -n "$GCC"; then
11700                           case $host_os in
11701                             linux*) haveit=yes;;
11702                           esac
11703                         fi
11704                       fi
11705                       if test -z "$haveit"; then
11706                         haveit=
11707                         for x in $LDFLAGS $LIBIPT; do
11708
11709   acl_save_prefix="$prefix"
11710   prefix="$acl_final_prefix"
11711   acl_save_exec_prefix="$exec_prefix"
11712   exec_prefix="$acl_final_exec_prefix"
11713   eval x=\"$x\"
11714   exec_prefix="$acl_save_exec_prefix"
11715   prefix="$acl_save_prefix"
11716
11717                           if test "X$x" = "X-L$additional_libdir"; then
11718                             haveit=yes
11719                             break
11720                           fi
11721                         done
11722                         if test -z "$haveit"; then
11723                           if test -d "$additional_libdir"; then
11724                                                         LIBIPT="${LIBIPT}${LIBIPT:+ }-L$additional_libdir"
11725                           fi
11726                         fi
11727                         haveit=
11728                         for x in $LDFLAGS $LTLIBIPT; do
11729
11730   acl_save_prefix="$prefix"
11731   prefix="$acl_final_prefix"
11732   acl_save_exec_prefix="$exec_prefix"
11733   exec_prefix="$acl_final_exec_prefix"
11734   eval x=\"$x\"
11735   exec_prefix="$acl_save_exec_prefix"
11736   prefix="$acl_save_prefix"
11737
11738                           if test "X$x" = "X-L$additional_libdir"; then
11739                             haveit=yes
11740                             break
11741                           fi
11742                         done
11743                         if test -z "$haveit"; then
11744                           if test -d "$additional_libdir"; then
11745                                                         LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-L$additional_libdir"
11746                           fi
11747                         fi
11748                       fi
11749                     fi
11750                     ;;
11751                   -R*)
11752                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
11753                     if test "$enable_rpath" != no; then
11754                                                                   haveit=
11755                       for x in $rpathdirs; do
11756                         if test "X$x" = "X$dir"; then
11757                           haveit=yes
11758                           break
11759                         fi
11760                       done
11761                       if test -z "$haveit"; then
11762                         rpathdirs="$rpathdirs $dir"
11763                       fi
11764                                                                   haveit=
11765                       for x in $ltrpathdirs; do
11766                         if test "X$x" = "X$dir"; then
11767                           haveit=yes
11768                           break
11769                         fi
11770                       done
11771                       if test -z "$haveit"; then
11772                         ltrpathdirs="$ltrpathdirs $dir"
11773                       fi
11774                     fi
11775                     ;;
11776                   -l*)
11777                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11778                     ;;
11779                   *.la)
11780                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11781                     ;;
11782                   *)
11783                                         LIBIPT="${LIBIPT}${LIBIPT:+ }$dep"
11784                     LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }$dep"
11785                     ;;
11786                 esac
11787               done
11788             fi
11789           else
11790                                                             LIBIPT="${LIBIPT}${LIBIPT:+ }-l$name"
11791             LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-l$name"
11792           fi
11793         fi
11794       fi
11795     done
11796   done
11797   if test "X$rpathdirs" != "X"; then
11798     if test -n "$hardcode_libdir_separator"; then
11799                         alldirs=
11800       for found_dir in $rpathdirs; do
11801         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11802       done
11803             acl_save_libdir="$libdir"
11804       libdir="$alldirs"
11805       eval flag=\"$hardcode_libdir_flag_spec\"
11806       libdir="$acl_save_libdir"
11807       LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
11808     else
11809             for found_dir in $rpathdirs; do
11810         acl_save_libdir="$libdir"
11811         libdir="$found_dir"
11812         eval flag=\"$hardcode_libdir_flag_spec\"
11813         libdir="$acl_save_libdir"
11814         LIBIPT="${LIBIPT}${LIBIPT:+ }$flag"
11815       done
11816     fi
11817   fi
11818   if test "X$ltrpathdirs" != "X"; then
11819             for found_dir in $ltrpathdirs; do
11820       LTLIBIPT="${LTLIBIPT}${LTLIBIPT:+ }-R$found_dir"
11821     done
11822   fi
11823
11824
11825         ac_save_CPPFLAGS="$CPPFLAGS"
11826
11827   for element in $INCIPT; do
11828     haveit=
11829     for x in $CPPFLAGS; do
11830
11831   acl_save_prefix="$prefix"
11832   prefix="$acl_final_prefix"
11833   acl_save_exec_prefix="$exec_prefix"
11834   exec_prefix="$acl_final_exec_prefix"
11835   eval x=\"$x\"
11836   exec_prefix="$acl_save_exec_prefix"
11837   prefix="$acl_save_prefix"
11838
11839       if test "X$x" = "X$element"; then
11840         haveit=yes
11841         break
11842       fi
11843     done
11844     if test -z "$haveit"; then
11845       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11846     fi
11847   done
11848
11849
11850   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libipt" >&5
11851 $as_echo_n "checking for libipt... " >&6; }
11852 if ${ac_cv_libipt+:} false; then :
11853   $as_echo_n "(cached) " >&6
11854 else
11855
11856     ac_save_LIBS="$LIBS"
11857     LIBS="$LIBS $LIBIPT"
11858     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11859 /* end confdefs.h.  */
11860 #include "intel-pt.h"
11861 int
11862 main ()
11863 {
11864 pt_insn_alloc_decoder (0);
11865   ;
11866   return 0;
11867 }
11868 _ACEOF
11869 if ac_fn_c_try_link "$LINENO"; then :
11870   ac_cv_libipt=yes
11871 else
11872   ac_cv_libipt=no
11873 fi
11874 rm -f core conftest.err conftest.$ac_objext \
11875     conftest$ac_exeext conftest.$ac_ext
11876     LIBS="$ac_save_LIBS"
11877
11878 fi
11879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libipt" >&5
11880 $as_echo "$ac_cv_libipt" >&6; }
11881   if test "$ac_cv_libipt" = yes; then
11882     HAVE_LIBIPT=yes
11883
11884 $as_echo "#define HAVE_LIBIPT 1" >>confdefs.h
11885
11886     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libipt" >&5
11887 $as_echo_n "checking how to link with libipt... " >&6; }
11888     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBIPT" >&5
11889 $as_echo "$LIBIPT" >&6; }
11890   else
11891     HAVE_LIBIPT=no
11892             CPPFLAGS="$ac_save_CPPFLAGS"
11893     LIBIPT=
11894     LTLIBIPT=
11895   fi
11896
11897
11898
11899
11900
11901
11902   if test "$HAVE_LIBIPT" != yes; then
11903     if test "$with_intel_pt" = yes; then
11904       as_fn_error $? "libipt is missing or unusable" "$LINENO" 5
11905     else
11906       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libipt is missing or unusable; some features may be unavailable." >&5
11907 $as_echo "$as_me: WARNING: libipt is missing or unusable; some features may be unavailable." >&2;}
11908     fi
11909   else
11910     save_LIBS=$LIBS
11911     LIBS="$LIBS $LIBIPT"
11912     for ac_func in pt_insn_event
11913 do :
11914   ac_fn_c_check_func "$LINENO" "pt_insn_event" "ac_cv_func_pt_insn_event"
11915 if test "x$ac_cv_func_pt_insn_event" = xyes; then :
11916   cat >>confdefs.h <<_ACEOF
11917 #define HAVE_PT_INSN_EVENT 1
11918 _ACEOF
11919
11920 fi
11921 done
11922
11923     ac_fn_c_check_member "$LINENO" "struct pt_insn" "enabled" "ac_cv_member_struct_pt_insn_enabled" "#include <intel-pt.h>
11924 "
11925 if test "x$ac_cv_member_struct_pt_insn_enabled" = xyes; then :
11926
11927 cat >>confdefs.h <<_ACEOF
11928 #define HAVE_STRUCT_PT_INSN_ENABLED 1
11929 _ACEOF
11930
11931
11932 fi
11933 ac_fn_c_check_member "$LINENO" "struct pt_insn" "resynced" "ac_cv_member_struct_pt_insn_resynced" "#include <intel-pt.h>
11934 "
11935 if test "x$ac_cv_member_struct_pt_insn_resynced" = xyes; then :
11936
11937 cat >>confdefs.h <<_ACEOF
11938 #define HAVE_STRUCT_PT_INSN_RESYNCED 1
11939 _ACEOF
11940
11941
11942 fi
11943
11944     LIBS=$save_LIBS
11945   fi
11946 fi
11947
11948 # ------------------------- #
11949 # Checks for header files.  #
11950 # ------------------------- #
11951
11952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
11953 $as_echo_n "checking for ANSI C header files... " >&6; }
11954 if ${ac_cv_header_stdc+:} false; then :
11955   $as_echo_n "(cached) " >&6
11956 else
11957   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11958 /* end confdefs.h.  */
11959 #include <stdlib.h>
11960 #include <stdarg.h>
11961 #include <string.h>
11962 #include <float.h>
11963
11964 int
11965 main ()
11966 {
11967
11968   ;
11969   return 0;
11970 }
11971 _ACEOF
11972 if ac_fn_c_try_compile "$LINENO"; then :
11973   ac_cv_header_stdc=yes
11974 else
11975   ac_cv_header_stdc=no
11976 fi
11977 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11978
11979 if test $ac_cv_header_stdc = yes; then
11980   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
11981   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11982 /* end confdefs.h.  */
11983 #include <string.h>
11984
11985 _ACEOF
11986 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11987   $EGREP "memchr" >/dev/null 2>&1; then :
11988
11989 else
11990   ac_cv_header_stdc=no
11991 fi
11992 rm -f conftest*
11993
11994 fi
11995
11996 if test $ac_cv_header_stdc = yes; then
11997   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
11998   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11999 /* end confdefs.h.  */
12000 #include <stdlib.h>
12001
12002 _ACEOF
12003 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12004   $EGREP "free" >/dev/null 2>&1; then :
12005
12006 else
12007   ac_cv_header_stdc=no
12008 fi
12009 rm -f conftest*
12010
12011 fi
12012
12013 if test $ac_cv_header_stdc = yes; then
12014   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12015   if test "$cross_compiling" = yes; then :
12016   :
12017 else
12018   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12019 /* end confdefs.h.  */
12020 #include <ctype.h>
12021 #include <stdlib.h>
12022 #if ((' ' & 0x0FF) == 0x020)
12023 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12024 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12025 #else
12026 # define ISLOWER(c) \
12027                    (('a' <= (c) && (c) <= 'i') \
12028                      || ('j' <= (c) && (c) <= 'r') \
12029                      || ('s' <= (c) && (c) <= 'z'))
12030 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12031 #endif
12032
12033 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12034 int
12035 main ()
12036 {
12037   int i;
12038   for (i = 0; i < 256; i++)
12039     if (XOR (islower (i), ISLOWER (i))
12040         || toupper (i) != TOUPPER (i))
12041       return 2;
12042   return 0;
12043 }
12044 _ACEOF
12045 if ac_fn_c_try_run "$LINENO"; then :
12046
12047 else
12048   ac_cv_header_stdc=no
12049 fi
12050 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12051   conftest.$ac_objext conftest.beam conftest.$ac_ext
12052 fi
12053
12054 fi
12055 fi
12056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
12057 $as_echo "$ac_cv_header_stdc" >&6; }
12058 if test $ac_cv_header_stdc = yes; then
12059
12060 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
12061
12062 fi
12063
12064 # elf_hp.h is for HP/UX 64-bit shared library support.
12065 for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
12066                   thread_db.h linux/elf.h \
12067                   sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
12068                   sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
12069                   sys/reg.h sys/debugreg.h sys/select.h \
12070                   termios.h elf_hp.h \
12071                   dlfcn.h
12072 do :
12073   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12074 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12075 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12076   cat >>confdefs.h <<_ACEOF
12077 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12078 _ACEOF
12079
12080 fi
12081
12082 done
12083
12084 for ac_header in sys/user.h
12085 do :
12086   ac_fn_c_check_header_compile "$LINENO" "sys/user.h" "ac_cv_header_sys_user_h" "#if HAVE_SYS_PARAM_H
12087 # include <sys/param.h>
12088 #endif
12089
12090 "
12091 if test "x$ac_cv_header_sys_user_h" = xyes; then :
12092   cat >>confdefs.h <<_ACEOF
12093 #define HAVE_SYS_USER_H 1
12094 _ACEOF
12095
12096 fi
12097
12098 done
12099
12100
12101 for ac_header in curses.h cursesX.h ncurses.h ncursesw/ncurses.h ncurses/ncurses.h ncurses/term.h
12102 do :
12103   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12104 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12105 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12106   cat >>confdefs.h <<_ACEOF
12107 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12108 _ACEOF
12109
12110 fi
12111
12112 done
12113
12114 for ac_header in term.h
12115 do :
12116   ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "#if HAVE_CURSES_H
12117 # include <curses.h>
12118 #endif
12119
12120 "
12121 if test "x$ac_cv_header_term_h" = xyes; then :
12122   cat >>confdefs.h <<_ACEOF
12123 #define HAVE_TERM_H 1
12124 _ACEOF
12125
12126 fi
12127
12128 done
12129
12130
12131 # ------------------------- #
12132 # Checks for declarations.  #
12133 # ------------------------- #
12134
12135
12136   # Check for presence and size of long long.
12137   ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
12138 if test "x$ac_cv_type_long_long" = xyes; then :
12139
12140 cat >>confdefs.h <<_ACEOF
12141 #define HAVE_LONG_LONG 1
12142 _ACEOF
12143
12144 # The cast to long int works around a bug in the HP C Compiler
12145 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12146 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12147 # This bug is HP SR number 8606223364.
12148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
12149 $as_echo_n "checking size of long long... " >&6; }
12150 if ${ac_cv_sizeof_long_long+:} false; then :
12151   $as_echo_n "(cached) " >&6
12152 else
12153   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"; then :
12154
12155 else
12156   if test "$ac_cv_type_long_long" = yes; then
12157      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12158 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12159 as_fn_error 77 "cannot compute sizeof (long long)
12160 See \`config.log' for more details" "$LINENO" 5; }
12161    else
12162      ac_cv_sizeof_long_long=0
12163    fi
12164 fi
12165
12166 fi
12167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
12168 $as_echo "$ac_cv_sizeof_long_long" >&6; }
12169
12170
12171
12172 cat >>confdefs.h <<_ACEOF
12173 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
12174 _ACEOF
12175
12176
12177 fi
12178
12179
12180   as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh`
12181 ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default"
12182 if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then :
12183   ac_have_decl=1
12184 else
12185   ac_have_decl=0
12186 fi
12187
12188 cat >>confdefs.h <<_ACEOF
12189 #define HAVE_DECL_BASENAME $ac_have_decl
12190 _ACEOF
12191 ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
12192 if test "x$ac_cv_have_decl_ffs" = xyes; then :
12193   ac_have_decl=1
12194 else
12195   ac_have_decl=0
12196 fi
12197
12198 cat >>confdefs.h <<_ACEOF
12199 #define HAVE_DECL_FFS $ac_have_decl
12200 _ACEOF
12201 ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
12202 if test "x$ac_cv_have_decl_asprintf" = xyes; then :
12203   ac_have_decl=1
12204 else
12205   ac_have_decl=0
12206 fi
12207
12208 cat >>confdefs.h <<_ACEOF
12209 #define HAVE_DECL_ASPRINTF $ac_have_decl
12210 _ACEOF
12211 ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
12212 if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
12213   ac_have_decl=1
12214 else
12215   ac_have_decl=0
12216 fi
12217
12218 cat >>confdefs.h <<_ACEOF
12219 #define HAVE_DECL_VASPRINTF $ac_have_decl
12220 _ACEOF
12221 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12222 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12223   ac_have_decl=1
12224 else
12225   ac_have_decl=0
12226 fi
12227
12228 cat >>confdefs.h <<_ACEOF
12229 #define HAVE_DECL_SNPRINTF $ac_have_decl
12230 _ACEOF
12231 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
12232 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
12233   ac_have_decl=1
12234 else
12235   ac_have_decl=0
12236 fi
12237
12238 cat >>confdefs.h <<_ACEOF
12239 #define HAVE_DECL_VSNPRINTF $ac_have_decl
12240 _ACEOF
12241
12242   ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default"
12243 if test "x$ac_cv_have_decl_strtol" = xyes; then :
12244   ac_have_decl=1
12245 else
12246   ac_have_decl=0
12247 fi
12248
12249 cat >>confdefs.h <<_ACEOF
12250 #define HAVE_DECL_STRTOL $ac_have_decl
12251 _ACEOF
12252 ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default"
12253 if test "x$ac_cv_have_decl_strtoul" = xyes; then :
12254   ac_have_decl=1
12255 else
12256   ac_have_decl=0
12257 fi
12258
12259 cat >>confdefs.h <<_ACEOF
12260 #define HAVE_DECL_STRTOUL $ac_have_decl
12261 _ACEOF
12262 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
12263 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
12264   ac_have_decl=1
12265 else
12266   ac_have_decl=0
12267 fi
12268
12269 cat >>confdefs.h <<_ACEOF
12270 #define HAVE_DECL_STRTOLL $ac_have_decl
12271 _ACEOF
12272 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
12273 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
12274   ac_have_decl=1
12275 else
12276   ac_have_decl=0
12277 fi
12278
12279 cat >>confdefs.h <<_ACEOF
12280 #define HAVE_DECL_STRTOULL $ac_have_decl
12281 _ACEOF
12282
12283   ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
12284 if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
12285   ac_have_decl=1
12286 else
12287   ac_have_decl=0
12288 fi
12289
12290 cat >>confdefs.h <<_ACEOF
12291 #define HAVE_DECL_STRVERSCMP $ac_have_decl
12292 _ACEOF
12293
12294
12295
12296 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
12297 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
12298   ac_have_decl=1
12299 else
12300   ac_have_decl=0
12301 fi
12302
12303 cat >>confdefs.h <<_ACEOF
12304 #define HAVE_DECL_SNPRINTF $ac_have_decl
12305 _ACEOF
12306
12307
12308   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
12309 $as_echo_n "checking for LC_MESSAGES... " >&6; }
12310 if ${am_cv_val_LC_MESSAGES+:} false; then :
12311   $as_echo_n "(cached) " >&6
12312 else
12313   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12314 /* end confdefs.h.  */
12315 #include <locale.h>
12316 int
12317 main ()
12318 {
12319 return LC_MESSAGES
12320   ;
12321   return 0;
12322 }
12323 _ACEOF
12324 if ac_fn_c_try_link "$LINENO"; then :
12325   am_cv_val_LC_MESSAGES=yes
12326 else
12327   am_cv_val_LC_MESSAGES=no
12328 fi
12329 rm -f core conftest.err conftest.$ac_objext \
12330     conftest$ac_exeext conftest.$ac_ext
12331 fi
12332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
12333 $as_echo "$am_cv_val_LC_MESSAGES" >&6; }
12334   if test $am_cv_val_LC_MESSAGES = yes; then
12335
12336 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
12337
12338   fi
12339
12340
12341 # ----------------------- #
12342 # Checks for structures.  #
12343 # ----------------------- #
12344
12345 ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
12346 if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
12347
12348 cat >>confdefs.h <<_ACEOF
12349 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
12350 _ACEOF
12351
12352
12353 fi
12354 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
12355 if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
12356
12357 cat >>confdefs.h <<_ACEOF
12358 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
12359 _ACEOF
12360
12361
12362 fi
12363
12364
12365 # ------------------ #
12366 # Checks for types.  #
12367 # ------------------ #
12368
12369 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
12370 #include <sys/socket.h>
12371
12372 "
12373 if test "x$ac_cv_type_socklen_t" = xyes; then :
12374
12375 cat >>confdefs.h <<_ACEOF
12376 #define HAVE_SOCKLEN_T 1
12377 _ACEOF
12378
12379
12380 fi
12381
12382
12383 # ------------------------------------- #
12384 # Checks for compiler characteristics.  #
12385 # ------------------------------------- #
12386
12387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
12388 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
12389 if ${ac_cv_c_const+:} false; then :
12390   $as_echo_n "(cached) " >&6
12391 else
12392   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12393 /* end confdefs.h.  */
12394
12395 int
12396 main ()
12397 {
12398
12399 #ifndef __cplusplus
12400   /* Ultrix mips cc rejects this sort of thing.  */
12401   typedef int charset[2];
12402   const charset cs = { 0, 0 };
12403   /* SunOS 4.1.1 cc rejects this.  */
12404   char const *const *pcpcc;
12405   char **ppc;
12406   /* NEC SVR4.0.2 mips cc rejects this.  */
12407   struct point {int x, y;};
12408   static struct point const zero = {0,0};
12409   /* AIX XL C 1.02.0.0 rejects this.
12410      It does not let you subtract one const X* pointer from another in
12411      an arm of an if-expression whose if-part is not a constant
12412      expression */
12413   const char *g = "string";
12414   pcpcc = &g + (g ? g-g : 0);
12415   /* HPUX 7.0 cc rejects these. */
12416   ++pcpcc;
12417   ppc = (char**) pcpcc;
12418   pcpcc = (char const *const *) ppc;
12419   { /* SCO 3.2v4 cc rejects this sort of thing.  */
12420     char tx;
12421     char *t = &tx;
12422     char const *s = 0 ? (char *) 0 : (char const *) 0;
12423
12424     *t++ = 0;
12425     if (s) return 0;
12426   }
12427   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
12428     int x[] = {25, 17};
12429     const int *foo = &x[0];
12430     ++foo;
12431   }
12432   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
12433     typedef const int *iptr;
12434     iptr p = 0;
12435     ++p;
12436   }
12437   { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
12438        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
12439     struct s { int j; const int *ap[3]; } bx;
12440     struct s *b = &bx; b->j = 5;
12441   }
12442   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
12443     const int foo = 10;
12444     if (!foo) return 0;
12445   }
12446   return !cs[0] && !zero.x;
12447 #endif
12448
12449   ;
12450   return 0;
12451 }
12452 _ACEOF
12453 if ac_fn_c_try_compile "$LINENO"; then :
12454   ac_cv_c_const=yes
12455 else
12456   ac_cv_c_const=no
12457 fi
12458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12459 fi
12460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
12461 $as_echo "$ac_cv_c_const" >&6; }
12462 if test $ac_cv_c_const = no; then
12463
12464 $as_echo "#define const /**/" >>confdefs.h
12465
12466 fi
12467
12468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
12469 $as_echo_n "checking for inline... " >&6; }
12470 if ${ac_cv_c_inline+:} false; then :
12471   $as_echo_n "(cached) " >&6
12472 else
12473   ac_cv_c_inline=no
12474 for ac_kw in inline __inline__ __inline; do
12475   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12476 /* end confdefs.h.  */
12477 #ifndef __cplusplus
12478 typedef int foo_t;
12479 static $ac_kw foo_t static_foo () {return 0; }
12480 $ac_kw foo_t foo () {return 0; }
12481 #endif
12482
12483 _ACEOF
12484 if ac_fn_c_try_compile "$LINENO"; then :
12485   ac_cv_c_inline=$ac_kw
12486 fi
12487 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12488   test "$ac_cv_c_inline" != no && break
12489 done
12490
12491 fi
12492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
12493 $as_echo "$ac_cv_c_inline" >&6; }
12494
12495 case $ac_cv_c_inline in
12496   inline | yes) ;;
12497   *)
12498     case $ac_cv_c_inline in
12499       no) ac_val=;;
12500       *) ac_val=$ac_cv_c_inline;;
12501     esac
12502     cat >>confdefs.h <<_ACEOF
12503 #ifndef __cplusplus
12504 #define inline $ac_val
12505 #endif
12506 _ACEOF
12507     ;;
12508 esac
12509
12510  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
12511 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
12512 if ${ac_cv_c_bigendian+:} false; then :
12513   $as_echo_n "(cached) " >&6
12514 else
12515   ac_cv_c_bigendian=unknown
12516     # See if we're dealing with a universal compiler.
12517     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12518 /* end confdefs.h.  */
12519 #ifndef __APPLE_CC__
12520                not a universal capable compiler
12521              #endif
12522              typedef int dummy;
12523
12524 _ACEOF
12525 if ac_fn_c_try_compile "$LINENO"; then :
12526
12527         # Check for potential -arch flags.  It is not universal unless
12528         # there are at least two -arch flags with different values.
12529         ac_arch=
12530         ac_prev=
12531         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
12532          if test -n "$ac_prev"; then
12533            case $ac_word in
12534              i?86 | x86_64 | ppc | ppc64)
12535                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
12536                  ac_arch=$ac_word
12537                else
12538                  ac_cv_c_bigendian=universal
12539                  break
12540                fi
12541                ;;
12542            esac
12543            ac_prev=
12544          elif test "x$ac_word" = "x-arch"; then
12545            ac_prev=arch
12546          fi
12547        done
12548 fi
12549 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12550     if test $ac_cv_c_bigendian = unknown; then
12551       # See if sys/param.h defines the BYTE_ORDER macro.
12552       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12553 /* end confdefs.h.  */
12554 #include <sys/types.h>
12555              #include <sys/param.h>
12556
12557 int
12558 main ()
12559 {
12560 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
12561                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
12562                      && LITTLE_ENDIAN)
12563               bogus endian macros
12564              #endif
12565
12566   ;
12567   return 0;
12568 }
12569 _ACEOF
12570 if ac_fn_c_try_compile "$LINENO"; then :
12571   # It does; now see whether it defined to BIG_ENDIAN or not.
12572          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12573 /* end confdefs.h.  */
12574 #include <sys/types.h>
12575                 #include <sys/param.h>
12576
12577 int
12578 main ()
12579 {
12580 #if BYTE_ORDER != BIG_ENDIAN
12581                  not big endian
12582                 #endif
12583
12584   ;
12585   return 0;
12586 }
12587 _ACEOF
12588 if ac_fn_c_try_compile "$LINENO"; then :
12589   ac_cv_c_bigendian=yes
12590 else
12591   ac_cv_c_bigendian=no
12592 fi
12593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12594 fi
12595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12596     fi
12597     if test $ac_cv_c_bigendian = unknown; then
12598       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
12599       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12600 /* end confdefs.h.  */
12601 #include <limits.h>
12602
12603 int
12604 main ()
12605 {
12606 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
12607               bogus endian macros
12608              #endif
12609
12610   ;
12611   return 0;
12612 }
12613 _ACEOF
12614 if ac_fn_c_try_compile "$LINENO"; then :
12615   # It does; now see whether it defined to _BIG_ENDIAN or not.
12616          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12617 /* end confdefs.h.  */
12618 #include <limits.h>
12619
12620 int
12621 main ()
12622 {
12623 #ifndef _BIG_ENDIAN
12624                  not big endian
12625                 #endif
12626
12627   ;
12628   return 0;
12629 }
12630 _ACEOF
12631 if ac_fn_c_try_compile "$LINENO"; then :
12632   ac_cv_c_bigendian=yes
12633 else
12634   ac_cv_c_bigendian=no
12635 fi
12636 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12637 fi
12638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12639     fi
12640     if test $ac_cv_c_bigendian = unknown; then
12641       # Compile a test program.
12642       if test "$cross_compiling" = yes; then :
12643   # Try to guess by grepping values from an object file.
12644          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12645 /* end confdefs.h.  */
12646 short int ascii_mm[] =
12647                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
12648                 short int ascii_ii[] =
12649                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12650                 int use_ascii (int i) {
12651                   return ascii_mm[i] + ascii_ii[i];
12652                 }
12653                 short int ebcdic_ii[] =
12654                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
12655                 short int ebcdic_mm[] =
12656                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12657                 int use_ebcdic (int i) {
12658                   return ebcdic_mm[i] + ebcdic_ii[i];
12659                 }
12660                 extern int foo;
12661
12662 int
12663 main ()
12664 {
12665 return use_ascii (foo) == use_ebcdic (foo);
12666   ;
12667   return 0;
12668 }
12669 _ACEOF
12670 if ac_fn_c_try_compile "$LINENO"; then :
12671   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
12672               ac_cv_c_bigendian=yes
12673             fi
12674             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12675               if test "$ac_cv_c_bigendian" = unknown; then
12676                 ac_cv_c_bigendian=no
12677               else
12678                 # finding both strings is unlikely to happen, but who knows?
12679                 ac_cv_c_bigendian=unknown
12680               fi
12681             fi
12682 fi
12683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12684 else
12685   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12686 /* end confdefs.h.  */
12687 $ac_includes_default
12688 int
12689 main ()
12690 {
12691
12692              /* Are we little or big endian?  From Harbison&Steele.  */
12693              union
12694              {
12695                long int l;
12696                char c[sizeof (long int)];
12697              } u;
12698              u.l = 1;
12699              return u.c[sizeof (long int) - 1] == 1;
12700
12701   ;
12702   return 0;
12703 }
12704 _ACEOF
12705 if ac_fn_c_try_run "$LINENO"; then :
12706   ac_cv_c_bigendian=no
12707 else
12708   ac_cv_c_bigendian=yes
12709 fi
12710 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12711   conftest.$ac_objext conftest.beam conftest.$ac_ext
12712 fi
12713
12714     fi
12715 fi
12716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
12717 $as_echo "$ac_cv_c_bigendian" >&6; }
12718  case $ac_cv_c_bigendian in #(
12719    yes)
12720      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
12721 ;; #(
12722    no)
12723       ;; #(
12724    universal)
12725
12726 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
12727
12728      ;; #(
12729    *)
12730      as_fn_error $? "unknown endianness
12731  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
12732  esac
12733
12734
12735 # ------------------------------ #
12736 # Checks for library functions.  #
12737 # ------------------------------ #
12738
12739
12740
12741
12742   for ac_header in $ac_header_list
12743 do :
12744   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12745 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
12746 "
12747 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12748   cat >>confdefs.h <<_ACEOF
12749 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12750 _ACEOF
12751
12752 fi
12753
12754 done
12755
12756
12757
12758
12759
12760
12761
12762
12763 for ac_func in getpagesize
12764 do :
12765   ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
12766 if test "x$ac_cv_func_getpagesize" = xyes; then :
12767   cat >>confdefs.h <<_ACEOF
12768 #define HAVE_GETPAGESIZE 1
12769 _ACEOF
12770
12771 fi
12772 done
12773
12774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
12775 $as_echo_n "checking for working mmap... " >&6; }
12776 if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
12777   $as_echo_n "(cached) " >&6
12778 else
12779   if test "$cross_compiling" = yes; then :
12780   ac_cv_func_mmap_fixed_mapped=no
12781 else
12782   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12783 /* end confdefs.h.  */
12784 $ac_includes_default
12785 /* malloc might have been renamed as rpl_malloc. */
12786 #undef malloc
12787
12788 /* Thanks to Mike Haertel and Jim Avera for this test.
12789    Here is a matrix of mmap possibilities:
12790         mmap private not fixed
12791         mmap private fixed at somewhere currently unmapped
12792         mmap private fixed at somewhere already mapped
12793         mmap shared not fixed
12794         mmap shared fixed at somewhere currently unmapped
12795         mmap shared fixed at somewhere already mapped
12796    For private mappings, we should verify that changes cannot be read()
12797    back from the file, nor mmap's back from the file at a different
12798    address.  (There have been systems where private was not correctly
12799    implemented like the infamous i386 svr4.0, and systems where the
12800    VM page cache was not coherent with the file system buffer cache
12801    like early versions of FreeBSD and possibly contemporary NetBSD.)
12802    For shared mappings, we should conversely verify that changes get
12803    propagated back to all the places they're supposed to be.
12804
12805    Grep wants private fixed already mapped.
12806    The main things grep needs to know about mmap are:
12807    * does it exist and is it safe to write into the mmap'd area
12808    * how to use it (BSD variants)  */
12809
12810 #include <fcntl.h>
12811 #include <sys/mman.h>
12812
12813 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
12814 char *malloc ();
12815 #endif
12816
12817 /* This mess was copied from the GNU getpagesize.h.  */
12818 #ifndef HAVE_GETPAGESIZE
12819 # ifdef _SC_PAGESIZE
12820 #  define getpagesize() sysconf(_SC_PAGESIZE)
12821 # else /* no _SC_PAGESIZE */
12822 #  ifdef HAVE_SYS_PARAM_H
12823 #   include <sys/param.h>
12824 #   ifdef EXEC_PAGESIZE
12825 #    define getpagesize() EXEC_PAGESIZE
12826 #   else /* no EXEC_PAGESIZE */
12827 #    ifdef NBPG
12828 #     define getpagesize() NBPG * CLSIZE
12829 #     ifndef CLSIZE
12830 #      define CLSIZE 1
12831 #     endif /* no CLSIZE */
12832 #    else /* no NBPG */
12833 #     ifdef NBPC
12834 #      define getpagesize() NBPC
12835 #     else /* no NBPC */
12836 #      ifdef PAGESIZE
12837 #       define getpagesize() PAGESIZE
12838 #      endif /* PAGESIZE */
12839 #     endif /* no NBPC */
12840 #    endif /* no NBPG */
12841 #   endif /* no EXEC_PAGESIZE */
12842 #  else /* no HAVE_SYS_PARAM_H */
12843 #   define getpagesize() 8192   /* punt totally */
12844 #  endif /* no HAVE_SYS_PARAM_H */
12845 # endif /* no _SC_PAGESIZE */
12846
12847 #endif /* no HAVE_GETPAGESIZE */
12848
12849 int
12850 main ()
12851 {
12852   char *data, *data2, *data3;
12853   const char *cdata2;
12854   int i, pagesize;
12855   int fd, fd2;
12856
12857   pagesize = getpagesize ();
12858
12859   /* First, make a file with some known garbage in it. */
12860   data = (char *) malloc (pagesize);
12861   if (!data)
12862     return 1;
12863   for (i = 0; i < pagesize; ++i)
12864     *(data + i) = rand ();
12865   umask (0);
12866   fd = creat ("conftest.mmap", 0600);
12867   if (fd < 0)
12868     return 2;
12869   if (write (fd, data, pagesize) != pagesize)
12870     return 3;
12871   close (fd);
12872
12873   /* Next, check that the tail of a page is zero-filled.  File must have
12874      non-zero length, otherwise we risk SIGBUS for entire page.  */
12875   fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
12876   if (fd2 < 0)
12877     return 4;
12878   cdata2 = "";
12879   if (write (fd2, cdata2, 1) != 1)
12880     return 5;
12881   data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
12882   if (data2 == MAP_FAILED)
12883     return 6;
12884   for (i = 0; i < pagesize; ++i)
12885     if (*(data2 + i))
12886       return 7;
12887   close (fd2);
12888   if (munmap (data2, pagesize))
12889     return 8;
12890
12891   /* Next, try to mmap the file at a fixed address which already has
12892      something else allocated at it.  If we can, also make sure that
12893      we see the same garbage.  */
12894   fd = open ("conftest.mmap", O_RDWR);
12895   if (fd < 0)
12896     return 9;
12897   if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
12898                      MAP_PRIVATE | MAP_FIXED, fd, 0L))
12899     return 10;
12900   for (i = 0; i < pagesize; ++i)
12901     if (*(data + i) != *(data2 + i))
12902       return 11;
12903
12904   /* Finally, make sure that changes to the mapped area do not
12905      percolate back to the file as seen by read().  (This is a bug on
12906      some variants of i386 svr4.0.)  */
12907   for (i = 0; i < pagesize; ++i)
12908     *(data2 + i) = *(data2 + i) + 1;
12909   data3 = (char *) malloc (pagesize);
12910   if (!data3)
12911     return 12;
12912   if (read (fd, data3, pagesize) != pagesize)
12913     return 13;
12914   for (i = 0; i < pagesize; ++i)
12915     if (*(data + i) != *(data3 + i))
12916       return 14;
12917   close (fd);
12918   return 0;
12919 }
12920 _ACEOF
12921 if ac_fn_c_try_run "$LINENO"; then :
12922   ac_cv_func_mmap_fixed_mapped=yes
12923 else
12924   ac_cv_func_mmap_fixed_mapped=no
12925 fi
12926 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12927   conftest.$ac_objext conftest.beam conftest.$ac_ext
12928 fi
12929
12930 fi
12931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
12932 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
12933 if test $ac_cv_func_mmap_fixed_mapped = yes; then
12934
12935 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
12936
12937 fi
12938 rm -f conftest.mmap conftest.txt
12939
12940 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
12941 if test "x$ac_cv_type_pid_t" = xyes; then :
12942
12943 else
12944
12945 cat >>confdefs.h <<_ACEOF
12946 #define pid_t int
12947 _ACEOF
12948
12949 fi
12950
12951 for ac_header in vfork.h
12952 do :
12953   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
12954 if test "x$ac_cv_header_vfork_h" = xyes; then :
12955   cat >>confdefs.h <<_ACEOF
12956 #define HAVE_VFORK_H 1
12957 _ACEOF
12958
12959 fi
12960
12961 done
12962
12963 for ac_func in fork vfork
12964 do :
12965   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12966 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12967 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12968   cat >>confdefs.h <<_ACEOF
12969 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12970 _ACEOF
12971
12972 fi
12973 done
12974
12975 if test "x$ac_cv_func_fork" = xyes; then
12976   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
12977 $as_echo_n "checking for working fork... " >&6; }
12978 if ${ac_cv_func_fork_works+:} false; then :
12979   $as_echo_n "(cached) " >&6
12980 else
12981   if test "$cross_compiling" = yes; then :
12982   ac_cv_func_fork_works=cross
12983 else
12984   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12985 /* end confdefs.h.  */
12986 $ac_includes_default
12987 int
12988 main ()
12989 {
12990
12991           /* By Ruediger Kuhlmann. */
12992           return fork () < 0;
12993
12994   ;
12995   return 0;
12996 }
12997 _ACEOF
12998 if ac_fn_c_try_run "$LINENO"; then :
12999   ac_cv_func_fork_works=yes
13000 else
13001   ac_cv_func_fork_works=no
13002 fi
13003 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13004   conftest.$ac_objext conftest.beam conftest.$ac_ext
13005 fi
13006
13007 fi
13008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13009 $as_echo "$ac_cv_func_fork_works" >&6; }
13010
13011 else
13012   ac_cv_func_fork_works=$ac_cv_func_fork
13013 fi
13014 if test "x$ac_cv_func_fork_works" = xcross; then
13015   case $host in
13016     *-*-amigaos* | *-*-msdosdjgpp*)
13017       # Override, as these systems have only a dummy fork() stub
13018       ac_cv_func_fork_works=no
13019       ;;
13020     *)
13021       ac_cv_func_fork_works=yes
13022       ;;
13023   esac
13024   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13025 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13026 fi
13027 ac_cv_func_vfork_works=$ac_cv_func_vfork
13028 if test "x$ac_cv_func_vfork" = xyes; then
13029   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13030 $as_echo_n "checking for working vfork... " >&6; }
13031 if ${ac_cv_func_vfork_works+:} false; then :
13032   $as_echo_n "(cached) " >&6
13033 else
13034   if test "$cross_compiling" = yes; then :
13035   ac_cv_func_vfork_works=cross
13036 else
13037   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13038 /* end confdefs.h.  */
13039 /* Thanks to Paul Eggert for this test.  */
13040 $ac_includes_default
13041 #include <sys/wait.h>
13042 #ifdef HAVE_VFORK_H
13043 # include <vfork.h>
13044 #endif
13045 /* On some sparc systems, changes by the child to local and incoming
13046    argument registers are propagated back to the parent.  The compiler
13047    is told about this with #include <vfork.h>, but some compilers
13048    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
13049    static variable whose address is put into a register that is
13050    clobbered by the vfork.  */
13051 static void
13052 #ifdef __cplusplus
13053 sparc_address_test (int arg)
13054 # else
13055 sparc_address_test (arg) int arg;
13056 #endif
13057 {
13058   static pid_t child;
13059   if (!child) {
13060     child = vfork ();
13061     if (child < 0) {
13062       perror ("vfork");
13063       _exit(2);
13064     }
13065     if (!child) {
13066       arg = getpid();
13067       write(-1, "", 0);
13068       _exit (arg);
13069     }
13070   }
13071 }
13072
13073 int
13074 main ()
13075 {
13076   pid_t parent = getpid ();
13077   pid_t child;
13078
13079   sparc_address_test (0);
13080
13081   child = vfork ();
13082
13083   if (child == 0) {
13084     /* Here is another test for sparc vfork register problems.  This
13085        test uses lots of local variables, at least as many local
13086        variables as main has allocated so far including compiler
13087        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
13088        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
13089        reuse the register of parent for one of the local variables,
13090        since it will think that parent can't possibly be used any more
13091        in this routine.  Assigning to the local variable will thus
13092        munge parent in the parent process.  */
13093     pid_t
13094       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13095       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13096     /* Convince the compiler that p..p7 are live; otherwise, it might
13097        use the same hardware register for all 8 local variables.  */
13098     if (p != p1 || p != p2 || p != p3 || p != p4
13099         || p != p5 || p != p6 || p != p7)
13100       _exit(1);
13101
13102     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13103        from child file descriptors.  If the child closes a descriptor
13104        before it execs or exits, this munges the parent's descriptor
13105        as well.  Test for this by closing stdout in the child.  */
13106     _exit(close(fileno(stdout)) != 0);
13107   } else {
13108     int status;
13109     struct stat st;
13110
13111     while (wait(&status) != child)
13112       ;
13113     return (
13114          /* Was there some problem with vforking?  */
13115          child < 0
13116
13117          /* Did the child fail?  (This shouldn't happen.)  */
13118          || status
13119
13120          /* Did the vfork/compiler bug occur?  */
13121          || parent != getpid()
13122
13123          /* Did the file descriptor bug occur?  */
13124          || fstat(fileno(stdout), &st) != 0
13125          );
13126   }
13127 }
13128 _ACEOF
13129 if ac_fn_c_try_run "$LINENO"; then :
13130   ac_cv_func_vfork_works=yes
13131 else
13132   ac_cv_func_vfork_works=no
13133 fi
13134 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13135   conftest.$ac_objext conftest.beam conftest.$ac_ext
13136 fi
13137
13138 fi
13139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13140 $as_echo "$ac_cv_func_vfork_works" >&6; }
13141
13142 fi;
13143 if test "x$ac_cv_func_fork_works" = xcross; then
13144   ac_cv_func_vfork_works=$ac_cv_func_vfork
13145   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13146 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13147 fi
13148
13149 if test "x$ac_cv_func_vfork_works" = xyes; then
13150
13151 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13152
13153 else
13154
13155 $as_echo "#define vfork fork" >>confdefs.h
13156
13157 fi
13158 if test "x$ac_cv_func_fork_works" = xyes; then
13159
13160 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13161
13162 fi
13163
13164 for ac_func in getauxval getrusage getuid getgid \
13165                 pipe poll pread pread64 pwrite resize_term \
13166                 sbrk getpgid setpgid setpgrp setsid \
13167                 sigaction sigprocmask sigsetmask socketpair \
13168                 ttrace wborder wresize setlocale iconvlist libiconvlist btowc \
13169                 setrlimit getrlimit posix_madvise waitpid \
13170                 ptrace64 sigaltstack setns use_default_colors
13171 do :
13172   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13173 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13174 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13175   cat >>confdefs.h <<_ACEOF
13176 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13177 _ACEOF
13178
13179 fi
13180 done
13181
13182
13183   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13184 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13185 if ${am_cv_langinfo_codeset+:} false; then :
13186   $as_echo_n "(cached) " >&6
13187 else
13188   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13189 /* end confdefs.h.  */
13190 #include <langinfo.h>
13191 int
13192 main ()
13193 {
13194 char* cs = nl_langinfo(CODESET);
13195   ;
13196   return 0;
13197 }
13198 _ACEOF
13199 if ac_fn_c_try_link "$LINENO"; then :
13200   am_cv_langinfo_codeset=yes
13201 else
13202   am_cv_langinfo_codeset=no
13203 fi
13204 rm -f core conftest.err conftest.$ac_objext \
13205     conftest$ac_exeext conftest.$ac_ext
13206
13207 fi
13208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13209 $as_echo "$am_cv_langinfo_codeset" >&6; }
13210   if test $am_cv_langinfo_codeset = yes; then
13211
13212 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13213
13214   fi
13215
13216 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
13217 if test "x$ac_cv_type_size_t" = xyes; then :
13218
13219 else
13220
13221 cat >>confdefs.h <<_ACEOF
13222 #define size_t unsigned int
13223 _ACEOF
13224
13225 fi
13226
13227
13228   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
13229 $as_echo_n "checking for ANSI C header files... " >&6; }
13230 if ${ac_cv_header_stdc+:} false; then :
13231   $as_echo_n "(cached) " >&6
13232 else
13233   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13234 /* end confdefs.h.  */
13235 #include <stdlib.h>
13236 #include <stdarg.h>
13237 #include <string.h>
13238 #include <float.h>
13239
13240 int
13241 main ()
13242 {
13243
13244   ;
13245   return 0;
13246 }
13247 _ACEOF
13248 if ac_fn_c_try_compile "$LINENO"; then :
13249   ac_cv_header_stdc=yes
13250 else
13251   ac_cv_header_stdc=no
13252 fi
13253 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13254
13255 if test $ac_cv_header_stdc = yes; then
13256   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13257   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13258 /* end confdefs.h.  */
13259 #include <string.h>
13260
13261 _ACEOF
13262 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13263   $EGREP "memchr" >/dev/null 2>&1; then :
13264
13265 else
13266   ac_cv_header_stdc=no
13267 fi
13268 rm -f conftest*
13269
13270 fi
13271
13272 if test $ac_cv_header_stdc = yes; then
13273   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13274   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13275 /* end confdefs.h.  */
13276 #include <stdlib.h>
13277
13278 _ACEOF
13279 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13280   $EGREP "free" >/dev/null 2>&1; then :
13281
13282 else
13283   ac_cv_header_stdc=no
13284 fi
13285 rm -f conftest*
13286
13287 fi
13288
13289 if test $ac_cv_header_stdc = yes; then
13290   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13291   if test "$cross_compiling" = yes; then :
13292   :
13293 else
13294   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13295 /* end confdefs.h.  */
13296 #include <ctype.h>
13297 #include <stdlib.h>
13298 #if ((' ' & 0x0FF) == 0x020)
13299 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13300 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13301 #else
13302 # define ISLOWER(c) \
13303                    (('a' <= (c) && (c) <= 'i') \
13304                      || ('j' <= (c) && (c) <= 'r') \
13305                      || ('s' <= (c) && (c) <= 'z'))
13306 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
13307 #endif
13308
13309 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13310 int
13311 main ()
13312 {
13313   int i;
13314   for (i = 0; i < 256; i++)
13315     if (XOR (islower (i), ISLOWER (i))
13316         || toupper (i) != TOUPPER (i))
13317       return 2;
13318   return 0;
13319 }
13320 _ACEOF
13321 if ac_fn_c_try_run "$LINENO"; then :
13322
13323 else
13324   ac_cv_header_stdc=no
13325 fi
13326 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13327   conftest.$ac_objext conftest.beam conftest.$ac_ext
13328 fi
13329
13330 fi
13331 fi
13332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
13333 $as_echo "$ac_cv_header_stdc" >&6; }
13334 if test $ac_cv_header_stdc = yes; then
13335
13336 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
13337
13338 fi
13339
13340   # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
13341 # for constant arguments.  Useless!
13342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
13343 $as_echo_n "checking for working alloca.h... " >&6; }
13344 if ${ac_cv_working_alloca_h+:} false; then :
13345   $as_echo_n "(cached) " >&6
13346 else
13347   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13348 /* end confdefs.h.  */
13349 #include <alloca.h>
13350 int
13351 main ()
13352 {
13353 char *p = (char *) alloca (2 * sizeof (int));
13354                           if (p) return 0;
13355   ;
13356   return 0;
13357 }
13358 _ACEOF
13359 if ac_fn_c_try_link "$LINENO"; then :
13360   ac_cv_working_alloca_h=yes
13361 else
13362   ac_cv_working_alloca_h=no
13363 fi
13364 rm -f core conftest.err conftest.$ac_objext \
13365     conftest$ac_exeext conftest.$ac_ext
13366 fi
13367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
13368 $as_echo "$ac_cv_working_alloca_h" >&6; }
13369 if test $ac_cv_working_alloca_h = yes; then
13370
13371 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
13372
13373 fi
13374
13375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
13376 $as_echo_n "checking for alloca... " >&6; }
13377 if ${ac_cv_func_alloca_works+:} false; then :
13378   $as_echo_n "(cached) " >&6
13379 else
13380   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13381 /* end confdefs.h.  */
13382 #ifdef __GNUC__
13383 # define alloca __builtin_alloca
13384 #else
13385 # ifdef _MSC_VER
13386 #  include <malloc.h>
13387 #  define alloca _alloca
13388 # else
13389 #  ifdef HAVE_ALLOCA_H
13390 #   include <alloca.h>
13391 #  else
13392 #   ifdef _AIX
13393  #pragma alloca
13394 #   else
13395 #    ifndef alloca /* predefined by HP cc +Olibcalls */
13396 void *alloca (size_t);
13397 #    endif
13398 #   endif
13399 #  endif
13400 # endif
13401 #endif
13402
13403 int
13404 main ()
13405 {
13406 char *p = (char *) alloca (1);
13407                                     if (p) return 0;
13408   ;
13409   return 0;
13410 }
13411 _ACEOF
13412 if ac_fn_c_try_link "$LINENO"; then :
13413   ac_cv_func_alloca_works=yes
13414 else
13415   ac_cv_func_alloca_works=no
13416 fi
13417 rm -f core conftest.err conftest.$ac_objext \
13418     conftest$ac_exeext conftest.$ac_ext
13419 fi
13420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
13421 $as_echo "$ac_cv_func_alloca_works" >&6; }
13422
13423 if test $ac_cv_func_alloca_works = yes; then
13424
13425 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
13426
13427 else
13428   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
13429 # that cause trouble.  Some versions do not even contain alloca or
13430 # contain a buggy version.  If you still want to use their alloca,
13431 # use ar to extract alloca.o from them instead of compiling alloca.c.
13432
13433 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
13434
13435 $as_echo "#define C_ALLOCA 1" >>confdefs.h
13436
13437
13438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
13439 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
13440 if ${ac_cv_os_cray+:} false; then :
13441   $as_echo_n "(cached) " >&6
13442 else
13443   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13444 /* end confdefs.h.  */
13445 #if defined CRAY && ! defined CRAY2
13446 webecray
13447 #else
13448 wenotbecray
13449 #endif
13450
13451 _ACEOF
13452 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13453   $EGREP "webecray" >/dev/null 2>&1; then :
13454   ac_cv_os_cray=yes
13455 else
13456   ac_cv_os_cray=no
13457 fi
13458 rm -f conftest*
13459
13460 fi
13461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
13462 $as_echo "$ac_cv_os_cray" >&6; }
13463 if test $ac_cv_os_cray = yes; then
13464   for ac_func in _getb67 GETB67 getb67; do
13465     as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13466 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13467 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13468
13469 cat >>confdefs.h <<_ACEOF
13470 #define CRAY_STACKSEG_END $ac_func
13471 _ACEOF
13472
13473     break
13474 fi
13475
13476   done
13477 fi
13478
13479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
13480 $as_echo_n "checking stack direction for C alloca... " >&6; }
13481 if ${ac_cv_c_stack_direction+:} false; then :
13482   $as_echo_n "(cached) " >&6
13483 else
13484   if test "$cross_compiling" = yes; then :
13485   ac_cv_c_stack_direction=0
13486 else
13487   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13488 /* end confdefs.h.  */
13489 $ac_includes_default
13490 int
13491 find_stack_direction (int *addr, int depth)
13492 {
13493   int dir, dummy = 0;
13494   if (! addr)
13495     addr = &dummy;
13496   *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
13497   dir = depth ? find_stack_direction (addr, depth - 1) : 0;
13498   return dir + dummy;
13499 }
13500
13501 int
13502 main (int argc, char **argv)
13503 {
13504   return find_stack_direction (0, argc + !argv + 20) < 0;
13505 }
13506 _ACEOF
13507 if ac_fn_c_try_run "$LINENO"; then :
13508   ac_cv_c_stack_direction=1
13509 else
13510   ac_cv_c_stack_direction=-1
13511 fi
13512 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13513   conftest.$ac_objext conftest.beam conftest.$ac_ext
13514 fi
13515
13516 fi
13517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
13518 $as_echo "$ac_cv_c_stack_direction" >&6; }
13519 cat >>confdefs.h <<_ACEOF
13520 #define STACK_DIRECTION $ac_cv_c_stack_direction
13521 _ACEOF
13522
13523
13524 fi
13525
13526
13527
13528   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13529 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13530 if ${am_cv_langinfo_codeset+:} false; then :
13531   $as_echo_n "(cached) " >&6
13532 else
13533   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13534 /* end confdefs.h.  */
13535 #include <langinfo.h>
13536 int
13537 main ()
13538 {
13539 char* cs = nl_langinfo(CODESET);
13540   ;
13541   return 0;
13542 }
13543 _ACEOF
13544 if ac_fn_c_try_link "$LINENO"; then :
13545   am_cv_langinfo_codeset=yes
13546 else
13547   am_cv_langinfo_codeset=no
13548 fi
13549 rm -f core conftest.err conftest.$ac_objext \
13550     conftest$ac_exeext conftest.$ac_ext
13551
13552 fi
13553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13554 $as_echo "$am_cv_langinfo_codeset" >&6; }
13555   if test $am_cv_langinfo_codeset = yes; then
13556
13557 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13558
13559   fi
13560
13561
13562   for ac_header in linux/perf_event.h locale.h memory.h signal.h                   sys/resource.h sys/socket.h             sys/un.h sys/wait.h             thread_db.h wait.h              termios.h
13563 do :
13564   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13565 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13566 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13567   cat >>confdefs.h <<_ACEOF
13568 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13569 _ACEOF
13570
13571 fi
13572
13573 done
13574
13575
13576   for ac_func in fdwalk getrlimit pipe pipe2 socketpair sigaction
13577 do :
13578   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13579 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13580 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13581   cat >>confdefs.h <<_ACEOF
13582 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13583 _ACEOF
13584
13585 fi
13586 done
13587
13588
13589   ac_fn_c_check_decl "$LINENO" "strerror" "ac_cv_have_decl_strerror" "$ac_includes_default"
13590 if test "x$ac_cv_have_decl_strerror" = xyes; then :
13591   ac_have_decl=1
13592 else
13593   ac_have_decl=0
13594 fi
13595
13596 cat >>confdefs.h <<_ACEOF
13597 #define HAVE_DECL_STRERROR $ac_have_decl
13598 _ACEOF
13599 ac_fn_c_check_decl "$LINENO" "strstr" "ac_cv_have_decl_strstr" "$ac_includes_default"
13600 if test "x$ac_cv_have_decl_strstr" = xyes; then :
13601   ac_have_decl=1
13602 else
13603   ac_have_decl=0
13604 fi
13605
13606 cat >>confdefs.h <<_ACEOF
13607 #define HAVE_DECL_STRSTR $ac_have_decl
13608 _ACEOF
13609
13610
13611     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
13612 $as_echo_n "checking for sigsetjmp... " >&6; }
13613 if ${gdb_cv_func_sigsetjmp+:} false; then :
13614   $as_echo_n "(cached) " >&6
13615 else
13616   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13617 /* end confdefs.h.  */
13618
13619 #include <setjmp.h>
13620
13621 int
13622 main ()
13623 {
13624 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
13625   ;
13626   return 0;
13627 }
13628 _ACEOF
13629 if ac_fn_c_try_compile "$LINENO"; then :
13630   gdb_cv_func_sigsetjmp=yes
13631 else
13632   gdb_cv_func_sigsetjmp=no
13633 fi
13634 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13635 fi
13636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
13637 $as_echo "$gdb_cv_func_sigsetjmp" >&6; }
13638 if test $gdb_cv_func_sigsetjmp = yes; then
13639
13640 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
13641
13642 fi
13643
13644
13645 # Check the return and argument types of ptrace.
13646
13647
13648 for ac_header in sys/ptrace.h ptrace.h
13649 do :
13650   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13651 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13652 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
13653   cat >>confdefs.h <<_ACEOF
13654 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13655 _ACEOF
13656
13657 fi
13658
13659 done
13660
13661
13662 gdb_ptrace_headers='
13663 #include <sys/types.h>
13664 #if HAVE_SYS_PTRACE_H
13665 # include <sys/ptrace.h>
13666 #endif
13667 #if HAVE_UNISTD_H
13668 # include <unistd.h>
13669 #endif
13670 '
13671 # There is no point in checking if we don't have a prototype.
13672 ac_fn_c_check_decl "$LINENO" "ptrace" "ac_cv_have_decl_ptrace" "$gdb_ptrace_headers
13673 "
13674 if test "x$ac_cv_have_decl_ptrace" = xyes; then :
13675   ac_have_decl=1
13676 else
13677   ac_have_decl=0
13678 fi
13679
13680 cat >>confdefs.h <<_ACEOF
13681 #define HAVE_DECL_PTRACE $ac_have_decl
13682 _ACEOF
13683 if test $ac_have_decl = 1; then :
13684
13685 else
13686
13687   : ${gdb_cv_func_ptrace_ret='int'}
13688   : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13689
13690 fi
13691
13692 # Check return type.  Varargs (used on GNU/Linux) conflict with the
13693 # empty argument list, so check for that explicitly.
13694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of ptrace" >&5
13695 $as_echo_n "checking return type of ptrace... " >&6; }
13696 if ${gdb_cv_func_ptrace_ret+:} false; then :
13697   $as_echo_n "(cached) " >&6
13698 else
13699   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13700 /* end confdefs.h.  */
13701 $gdb_ptrace_headers
13702 int
13703 main ()
13704 {
13705 extern long ptrace (enum __ptrace_request, ...);
13706   ;
13707   return 0;
13708 }
13709 _ACEOF
13710 if ac_fn_c_try_compile "$LINENO"; then :
13711   gdb_cv_func_ptrace_ret='long'
13712 else
13713   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13714 /* end confdefs.h.  */
13715 $gdb_ptrace_headers
13716 int
13717 main ()
13718 {
13719 extern int ptrace ();
13720   ;
13721   return 0;
13722 }
13723 _ACEOF
13724 if ac_fn_c_try_compile "$LINENO"; then :
13725   gdb_cv_func_ptrace_ret='int'
13726 else
13727   gdb_cv_func_ptrace_ret='long'
13728 fi
13729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13730 fi
13731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13732 fi
13733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_ret" >&5
13734 $as_echo "$gdb_cv_func_ptrace_ret" >&6; }
13735
13736 cat >>confdefs.h <<_ACEOF
13737 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
13738 _ACEOF
13739
13740 # Check argument types.
13741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for ptrace" >&5
13742 $as_echo_n "checking types of arguments for ptrace... " >&6; }
13743 if ${gdb_cv_func_ptrace_args+:} false; then :
13744   $as_echo_n "(cached) " >&6
13745 else
13746
13747   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13748 /* end confdefs.h.  */
13749 $gdb_ptrace_headers
13750 int
13751 main ()
13752 {
13753 extern long ptrace (enum __ptrace_request, ...);
13754   ;
13755   return 0;
13756 }
13757 _ACEOF
13758 if ac_fn_c_try_compile "$LINENO"; then :
13759   gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'
13760 else
13761
13762 for gdb_arg1 in 'int' 'long'; do
13763  for gdb_arg2 in 'pid_t' 'int' 'long'; do
13764   for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
13765    for gdb_arg4 in 'int' 'long' 'void *'; do
13766      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13767 /* end confdefs.h.  */
13768 $gdb_ptrace_headers
13769 int
13770 main ()
13771 {
13772
13773 extern $gdb_cv_func_ptrace_ret
13774   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
13775
13776   ;
13777   return 0;
13778 }
13779 _ACEOF
13780 if ac_fn_c_try_compile "$LINENO"; then :
13781   gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
13782     break 4;
13783 fi
13784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13785     for gdb_arg5 in 'int *' 'int' 'long'; do
13786      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13787 /* end confdefs.h.  */
13788 $gdb_ptrace_headers
13789 int
13790 main ()
13791 {
13792
13793 extern $gdb_cv_func_ptrace_ret
13794   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
13795
13796   ;
13797   return 0;
13798 }
13799 _ACEOF
13800 if ac_fn_c_try_compile "$LINENO"; then :
13801
13802 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
13803     break 5;
13804 fi
13805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13806     done
13807    done
13808   done
13809  done
13810 done
13811 # Provide a safe default value.
13812 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
13813
13814 fi
13815 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13816 fi
13817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_ptrace_args" >&5
13818 $as_echo "$gdb_cv_func_ptrace_args" >&6; }
13819 ac_save_IFS=$IFS; IFS=','
13820 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
13821 IFS=$ac_save_IFS
13822 shift
13823
13824 cat >>confdefs.h <<_ACEOF
13825 #define PTRACE_TYPE_ARG1 $1
13826 _ACEOF
13827
13828
13829 cat >>confdefs.h <<_ACEOF
13830 #define PTRACE_TYPE_ARG3 $3
13831 _ACEOF
13832
13833
13834 cat >>confdefs.h <<_ACEOF
13835 #define PTRACE_TYPE_ARG4 $4
13836 _ACEOF
13837
13838 if test -n "$5"; then
13839
13840 cat >>confdefs.h <<_ACEOF
13841 #define PTRACE_TYPE_ARG5 $5
13842 _ACEOF
13843
13844 fi
13845
13846
13847 if test "$cross_compiling" = no; then
13848   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
13849 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
13850 if ${ac_cv_func_setpgrp_void+:} false; then :
13851   $as_echo_n "(cached) " >&6
13852 else
13853   if test "$cross_compiling" = yes; then :
13854   as_fn_error $? "cannot check setpgrp when cross compiling" "$LINENO" 5
13855 else
13856   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13857 /* end confdefs.h.  */
13858 $ac_includes_default
13859 int
13860 main ()
13861 {
13862 /* If this system has a BSD-style setpgrp which takes arguments,
13863   setpgrp(1, 1) will fail with ESRCH and return -1, in that case
13864   exit successfully. */
13865   return setpgrp (1,1) != -1;
13866   ;
13867   return 0;
13868 }
13869 _ACEOF
13870 if ac_fn_c_try_run "$LINENO"; then :
13871   ac_cv_func_setpgrp_void=no
13872 else
13873   ac_cv_func_setpgrp_void=yes
13874 fi
13875 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13876   conftest.$ac_objext conftest.beam conftest.$ac_ext
13877 fi
13878
13879 fi
13880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
13881 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
13882 if test $ac_cv_func_setpgrp_void = yes; then
13883
13884 $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
13885
13886 fi
13887
13888 else
13889   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5
13890 $as_echo_n "checking whether setpgrp takes no argument... " >&6; }
13891 if ${ac_cv_func_setpgrp_void+:} false; then :
13892   $as_echo_n "(cached) " >&6
13893 else
13894   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13895 /* end confdefs.h.  */
13896
13897 #include <unistd.h>
13898
13899 int
13900 main ()
13901 {
13902
13903   if (setpgrp(1,1) == -1)
13904     exit (0);
13905   else
13906     exit (1);
13907
13908   ;
13909   return 0;
13910 }
13911 _ACEOF
13912 if ac_fn_c_try_compile "$LINENO"; then :
13913   ac_cv_func_setpgrp_void=no
13914 else
13915   ac_cv_func_setpgrp_void=yes
13916 fi
13917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13918 fi
13919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5
13920 $as_echo "$ac_cv_func_setpgrp_void" >&6; }
13921 if test $ac_cv_func_setpgrp_void = yes; then
13922   $as_echo "#define SETPGRP_VOID 1" >>confdefs.h
13923
13924 fi
13925 fi
13926
13927 # Assume we'll default to using the included libiberty regex.
13928 gdb_use_included_regex=yes
13929
13930 # However, if the system regex is GNU regex, then default to *not*
13931 # using the included regex.
13932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU regex" >&5
13933 $as_echo_n "checking for GNU regex... " >&6; }
13934 if ${gdb_cv_have_gnu_regex+:} false; then :
13935   $as_echo_n "(cached) " >&6
13936 else
13937   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13938 /* end confdefs.h.  */
13939 #include <gnu-versions.h>
13940 int
13941 main ()
13942 {
13943 #define REGEX_INTERFACE_VERSION 1
13944 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
13945 # error "Version mismatch"
13946 #endif
13947   ;
13948   return 0;
13949 }
13950 _ACEOF
13951 if ac_fn_c_try_compile "$LINENO"; then :
13952   gdb_cv_have_gnu_regex=yes
13953 else
13954   gdb_cv_have_gnu_regex=no
13955 fi
13956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13957 fi
13958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_gnu_regex" >&5
13959 $as_echo "$gdb_cv_have_gnu_regex" >&6; }
13960 if test $gdb_cv_have_gnu_regex = yes; then
13961   gdb_use_included_regex=no
13962 fi
13963
13964
13965 # Check whether --with-included-regex was given.
13966 if test "${with_included_regex+set}" = set; then :
13967   withval=$with_included_regex; gdb_with_regex=$withval
13968 else
13969   gdb_with_regex=$gdb_use_included_regex
13970 fi
13971
13972 if test "$gdb_with_regex" = yes; then
13973
13974 $as_echo "#define USE_INCLUDED_REGEX 1" >>confdefs.h
13975
13976 fi
13977
13978 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
13979 ac_fn_c_check_member "$LINENO" "struct thread" "td_pcb" "ac_cv_member_struct_thread_td_pcb" "#include <sys/param.h>
13980 #include <sys/proc.h>
13981
13982 "
13983 if test "x$ac_cv_member_struct_thread_td_pcb" = xyes; then :
13984
13985 cat >>confdefs.h <<_ACEOF
13986 #define HAVE_STRUCT_THREAD_TD_PCB 1
13987 _ACEOF
13988
13989
13990 fi
13991
13992
13993 # See if <sys/lwp.h> defines `struct lwp`.
13994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct lwp" >&5
13995 $as_echo_n "checking for struct lwp... " >&6; }
13996 if ${gdb_cv_struct_lwp+:} false; then :
13997   $as_echo_n "(cached) " >&6
13998 else
13999   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14000 /* end confdefs.h.  */
14001 #include <sys/param.h>
14002 #define _KMEMUSER
14003 #include <sys/lwp.h>
14004 int
14005 main ()
14006 {
14007 struct lwp l;
14008   ;
14009   return 0;
14010 }
14011 _ACEOF
14012 if ac_fn_c_try_compile "$LINENO"; then :
14013   gdb_cv_struct_lwp=yes
14014 else
14015   gdb_cv_struct_lwp=no
14016 fi
14017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14018 fi
14019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_lwp" >&5
14020 $as_echo "$gdb_cv_struct_lwp" >&6; }
14021 if test $gdb_cv_struct_lwp = yes; then
14022
14023 $as_echo "#define HAVE_STRUCT_LWP 1" >>confdefs.h
14024
14025 fi
14026
14027 # See if <machine/reg.h> degines `struct reg'.
14028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct reg in machine/reg.h" >&5
14029 $as_echo_n "checking for struct reg in machine/reg.h... " >&6; }
14030 if ${gdb_cv_struct_reg+:} false; then :
14031   $as_echo_n "(cached) " >&6
14032 else
14033   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14034 /* end confdefs.h.  */
14035 #include <sys/types.h>
14036 #include <machine/reg.h>
14037 int
14038 main ()
14039 {
14040 struct reg r;
14041   ;
14042   return 0;
14043 }
14044 _ACEOF
14045 if ac_fn_c_try_compile "$LINENO"; then :
14046   gdb_cv_struct_reg=yes
14047 else
14048   gdb_cv_struct_reg=no
14049 fi
14050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14051 fi
14052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_struct_reg" >&5
14053 $as_echo "$gdb_cv_struct_reg" >&6; }
14054 if test $gdb_cv_struct_reg = yes; then
14055
14056 $as_echo "#define HAVE_STRUCT_REG 1" >>confdefs.h
14057
14058 fi
14059
14060 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
14061 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
14062 ac_fn_c_check_member "$LINENO" "struct reg" "r_fs" "ac_cv_member_struct_reg_r_fs" "#include <sys/types.h>
14063 #include <machine/reg.h>
14064 "
14065 if test "x$ac_cv_member_struct_reg_r_fs" = xyes; then :
14066
14067 cat >>confdefs.h <<_ACEOF
14068 #define HAVE_STRUCT_REG_R_FS 1
14069 _ACEOF
14070
14071
14072 fi
14073 ac_fn_c_check_member "$LINENO" "struct reg" "r_gs" "ac_cv_member_struct_reg_r_gs" "#include <sys/types.h>
14074 #include <machine/reg.h>
14075 "
14076 if test "x$ac_cv_member_struct_reg_r_gs" = xyes; then :
14077
14078 cat >>confdefs.h <<_ACEOF
14079 #define HAVE_STRUCT_REG_R_GS 1
14080 _ACEOF
14081
14082
14083 fi
14084
14085
14086 # See if <sys/user.h> supports the %fs_base and %gs_bas amd64 segment registers.
14087 # Older amd64 Linux's don't have the fs_base and gs_base members of
14088 # `struct user_regs_struct'.
14089 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "fs_base" "ac_cv_member_struct_user_regs_struct_fs_base" "#include <sys/types.h>
14090 #include <sys/user.h>
14091 "
14092 if test "x$ac_cv_member_struct_user_regs_struct_fs_base" = xyes; then :
14093
14094 cat >>confdefs.h <<_ACEOF
14095 #define HAVE_STRUCT_USER_REGS_STRUCT_FS_BASE 1
14096 _ACEOF
14097
14098
14099 fi
14100 ac_fn_c_check_member "$LINENO" "struct user_regs_struct" "gs_base" "ac_cv_member_struct_user_regs_struct_gs_base" "#include <sys/types.h>
14101 #include <sys/user.h>
14102 "
14103 if test "x$ac_cv_member_struct_user_regs_struct_gs_base" = xyes; then :
14104
14105 cat >>confdefs.h <<_ACEOF
14106 #define HAVE_STRUCT_USER_REGS_STRUCT_GS_BASE 1
14107 _ACEOF
14108
14109
14110 fi
14111
14112
14113 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
14114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETREGS" >&5
14115 $as_echo_n "checking for PTRACE_GETREGS... " >&6; }
14116 if ${gdb_cv_have_ptrace_getregs+:} false; then :
14117   $as_echo_n "(cached) " >&6
14118 else
14119   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14120 /* end confdefs.h.  */
14121 #include <sys/ptrace.h>
14122 int
14123 main ()
14124 {
14125 PTRACE_GETREGS;
14126   ;
14127   return 0;
14128 }
14129 _ACEOF
14130 if ac_fn_c_try_compile "$LINENO"; then :
14131   gdb_cv_have_ptrace_getregs=yes
14132 else
14133   gdb_cv_have_ptrace_getregs=no
14134 fi
14135 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14136 fi
14137
14138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getregs" >&5
14139 $as_echo "$gdb_cv_have_ptrace_getregs" >&6; }
14140 if test $gdb_cv_have_ptrace_getregs = yes; then
14141
14142 $as_echo "#define HAVE_PTRACE_GETREGS 1" >>confdefs.h
14143
14144 fi
14145
14146 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
14147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTRACE_GETFPXREGS" >&5
14148 $as_echo_n "checking for PTRACE_GETFPXREGS... " >&6; }
14149 if ${gdb_cv_have_ptrace_getfpxregs+:} false; then :
14150   $as_echo_n "(cached) " >&6
14151 else
14152   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14153 /* end confdefs.h.  */
14154 #include <sys/ptrace.h>
14155 int
14156 main ()
14157 {
14158 PTRACE_GETFPXREGS;
14159   ;
14160   return 0;
14161 }
14162 _ACEOF
14163 if ac_fn_c_try_compile "$LINENO"; then :
14164   gdb_cv_have_ptrace_getfpxregs=yes
14165 else
14166   gdb_cv_have_ptrace_getfpxregs=no
14167 fi
14168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14169 fi
14170
14171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_ptrace_getfpxregs" >&5
14172 $as_echo "$gdb_cv_have_ptrace_getfpxregs" >&6; }
14173 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
14174
14175 $as_echo "#define HAVE_PTRACE_GETFPXREGS 1" >>confdefs.h
14176
14177 fi
14178
14179 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
14180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETDBREGS" >&5
14181 $as_echo_n "checking for PT_GETDBREGS... " >&6; }
14182 if ${gdb_cv_have_pt_getdbregs+:} false; then :
14183   $as_echo_n "(cached) " >&6
14184 else
14185   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14186 /* end confdefs.h.  */
14187 #include <sys/types.h>
14188 #include <sys/ptrace.h>
14189 int
14190 main ()
14191 {
14192 PT_GETDBREGS;
14193   ;
14194   return 0;
14195 }
14196 _ACEOF
14197 if ac_fn_c_try_compile "$LINENO"; then :
14198   gdb_cv_have_pt_getdbregs=yes
14199 else
14200   gdb_cv_have_pt_getdbregs=no
14201 fi
14202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14203 fi
14204
14205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getdbregs" >&5
14206 $as_echo "$gdb_cv_have_pt_getdbregs" >&6; }
14207 if test $gdb_cv_have_pt_getdbregs = yes; then
14208
14209 $as_echo "#define HAVE_PT_GETDBREGS 1" >>confdefs.h
14210
14211 fi
14212
14213 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
14214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PT_GETXMMREGS" >&5
14215 $as_echo_n "checking for PT_GETXMMREGS... " >&6; }
14216 if ${gdb_cv_have_pt_getxmmregs+:} false; then :
14217   $as_echo_n "(cached) " >&6
14218 else
14219   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14220 /* end confdefs.h.  */
14221 #include <sys/types.h>
14222 #include <sys/ptrace.h>
14223 int
14224 main ()
14225 {
14226 PT_GETXMMREGS;
14227   ;
14228   return 0;
14229 }
14230 _ACEOF
14231 if ac_fn_c_try_compile "$LINENO"; then :
14232   gdb_cv_have_pt_getxmmregs=yes
14233 else
14234   gdb_cv_have_pt_getxmmregs=no
14235 fi
14236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14237 fi
14238
14239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_pt_getxmmregs" >&5
14240 $as_echo "$gdb_cv_have_pt_getxmmregs" >&6; }
14241 if test $gdb_cv_have_pt_getxmmregs = yes; then
14242
14243 $as_echo "#define HAVE_PT_GETXMMREGS 1" >>confdefs.h
14244
14245 fi
14246
14247 # See if <sys/ptrace.h> supports LWP names on FreeBSD
14248 # Older FreeBSD versions don't have the pl_tdname member of
14249 # `struct ptrace_lwpinfo'.
14250 ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_tdname" "ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" "#include <sys/ptrace.h>
14251 "
14252 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_tdname" = xyes; then :
14253
14254 cat >>confdefs.h <<_ACEOF
14255 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_TDNAME 1
14256 _ACEOF
14257
14258
14259 fi
14260
14261
14262 # See if <sys/ptrace.h> supports syscall fields on FreeBSD.  The
14263 # pl_syscall_code member of `struct ptrace_lwpinfo' was added in
14264 # FreeBSD 10.3.
14265 ac_fn_c_check_member "$LINENO" "struct ptrace_lwpinfo" "pl_syscall_code" "ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" "#include <sys/ptrace.h>
14266 "
14267 if test "x$ac_cv_member_struct_ptrace_lwpinfo_pl_syscall_code" = xyes; then :
14268
14269 cat >>confdefs.h <<_ACEOF
14270 #define HAVE_STRUCT_PTRACE_LWPINFO_PL_SYSCALL_CODE 1
14271 _ACEOF
14272
14273
14274 fi
14275
14276
14277 if test "$ac_cv_header_sys_procfs_h" = yes; then
14278   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gregset_t in sys/procfs.h" >&5
14279 $as_echo_n "checking for gregset_t in sys/procfs.h... " >&6; }
14280  if ${bfd_cv_have_sys_procfs_type_gregset_t+:} false; then :
14281   $as_echo_n "(cached) " >&6
14282 else
14283   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14284 /* end confdefs.h.  */
14285
14286 #define _SYSCALL32
14287 /* Needed for new procfs interface on sparc-solaris.  */
14288 #define _STRUCTURED_PROC 1
14289 #include <sys/procfs.h>
14290 int
14291 main ()
14292 {
14293 gregset_t avar
14294   ;
14295   return 0;
14296 }
14297 _ACEOF
14298 if ac_fn_c_try_compile "$LINENO"; then :
14299   bfd_cv_have_sys_procfs_type_gregset_t=yes
14300 else
14301   bfd_cv_have_sys_procfs_type_gregset_t=no
14302
14303 fi
14304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14305 fi
14306
14307  if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
14308
14309 $as_echo "#define HAVE_GREGSET_T 1" >>confdefs.h
14310
14311  fi
14312  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
14313 $as_echo "$bfd_cv_have_sys_procfs_type_gregset_t" >&6; }
14314
14315   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fpregset_t in sys/procfs.h" >&5
14316 $as_echo_n "checking for fpregset_t in sys/procfs.h... " >&6; }
14317  if ${bfd_cv_have_sys_procfs_type_fpregset_t+:} false; then :
14318   $as_echo_n "(cached) " >&6
14319 else
14320   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14321 /* end confdefs.h.  */
14322
14323 #define _SYSCALL32
14324 /* Needed for new procfs interface on sparc-solaris.  */
14325 #define _STRUCTURED_PROC 1
14326 #include <sys/procfs.h>
14327 int
14328 main ()
14329 {
14330 fpregset_t avar
14331   ;
14332   return 0;
14333 }
14334 _ACEOF
14335 if ac_fn_c_try_compile "$LINENO"; then :
14336   bfd_cv_have_sys_procfs_type_fpregset_t=yes
14337 else
14338   bfd_cv_have_sys_procfs_type_fpregset_t=no
14339
14340 fi
14341 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14342 fi
14343
14344  if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
14345
14346 $as_echo "#define HAVE_FPREGSET_T 1" >>confdefs.h
14347
14348  fi
14349  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
14350 $as_echo "$bfd_cv_have_sys_procfs_type_fpregset_t" >&6; }
14351
14352   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset_t in sys/procfs.h" >&5
14353 $as_echo_n "checking for prgregset_t in sys/procfs.h... " >&6; }
14354  if ${bfd_cv_have_sys_procfs_type_prgregset_t+:} false; then :
14355   $as_echo_n "(cached) " >&6
14356 else
14357   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14358 /* end confdefs.h.  */
14359
14360 #define _SYSCALL32
14361 /* Needed for new procfs interface on sparc-solaris.  */
14362 #define _STRUCTURED_PROC 1
14363 #include <sys/procfs.h>
14364 int
14365 main ()
14366 {
14367 prgregset_t avar
14368   ;
14369   return 0;
14370 }
14371 _ACEOF
14372 if ac_fn_c_try_compile "$LINENO"; then :
14373   bfd_cv_have_sys_procfs_type_prgregset_t=yes
14374 else
14375   bfd_cv_have_sys_procfs_type_prgregset_t=no
14376
14377 fi
14378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14379 fi
14380
14381  if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
14382
14383 $as_echo "#define HAVE_PRGREGSET_T 1" >>confdefs.h
14384
14385  fi
14386  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
14387 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset_t" >&6; }
14388
14389   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prfpregset_t in sys/procfs.h" >&5
14390 $as_echo_n "checking for prfpregset_t in sys/procfs.h... " >&6; }
14391  if ${bfd_cv_have_sys_procfs_type_prfpregset_t+:} false; then :
14392   $as_echo_n "(cached) " >&6
14393 else
14394   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14395 /* end confdefs.h.  */
14396
14397 #define _SYSCALL32
14398 /* Needed for new procfs interface on sparc-solaris.  */
14399 #define _STRUCTURED_PROC 1
14400 #include <sys/procfs.h>
14401 int
14402 main ()
14403 {
14404 prfpregset_t avar
14405   ;
14406   return 0;
14407 }
14408 _ACEOF
14409 if ac_fn_c_try_compile "$LINENO"; then :
14410   bfd_cv_have_sys_procfs_type_prfpregset_t=yes
14411 else
14412   bfd_cv_have_sys_procfs_type_prfpregset_t=no
14413
14414 fi
14415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14416 fi
14417
14418  if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
14419
14420 $as_echo "#define HAVE_PRFPREGSET_T 1" >>confdefs.h
14421
14422  fi
14423  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
14424 $as_echo "$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6; }
14425
14426   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prgregset32_t in sys/procfs.h" >&5
14427 $as_echo_n "checking for prgregset32_t in sys/procfs.h... " >&6; }
14428  if ${bfd_cv_have_sys_procfs_type_prgregset32_t+:} false; then :
14429   $as_echo_n "(cached) " >&6
14430 else
14431   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14432 /* end confdefs.h.  */
14433
14434 #define _SYSCALL32
14435 /* Needed for new procfs interface on sparc-solaris.  */
14436 #define _STRUCTURED_PROC 1
14437 #include <sys/procfs.h>
14438 int
14439 main ()
14440 {
14441 prgregset32_t avar
14442   ;
14443   return 0;
14444 }
14445 _ACEOF
14446 if ac_fn_c_try_compile "$LINENO"; then :
14447   bfd_cv_have_sys_procfs_type_prgregset32_t=yes
14448 else
14449   bfd_cv_have_sys_procfs_type_prgregset32_t=no
14450
14451 fi
14452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14453 fi
14454
14455  if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
14456
14457 $as_echo "#define HAVE_PRGREGSET32_T 1" >>confdefs.h
14458
14459  fi
14460  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
14461 $as_echo "$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6; }
14462
14463   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpid_t in sys/procfs.h" >&5
14464 $as_echo_n "checking for lwpid_t in sys/procfs.h... " >&6; }
14465  if ${bfd_cv_have_sys_procfs_type_lwpid_t+:} false; then :
14466   $as_echo_n "(cached) " >&6
14467 else
14468   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14469 /* end confdefs.h.  */
14470
14471 #define _SYSCALL32
14472 /* Needed for new procfs interface on sparc-solaris.  */
14473 #define _STRUCTURED_PROC 1
14474 #include <sys/procfs.h>
14475 int
14476 main ()
14477 {
14478 lwpid_t avar
14479   ;
14480   return 0;
14481 }
14482 _ACEOF
14483 if ac_fn_c_try_compile "$LINENO"; then :
14484   bfd_cv_have_sys_procfs_type_lwpid_t=yes
14485 else
14486   bfd_cv_have_sys_procfs_type_lwpid_t=no
14487
14488 fi
14489 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14490 fi
14491
14492  if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
14493
14494 $as_echo "#define HAVE_LWPID_T 1" >>confdefs.h
14495
14496  fi
14497  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
14498 $as_echo "$bfd_cv_have_sys_procfs_type_lwpid_t" >&6; }
14499
14500   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psaddr_t in sys/procfs.h" >&5
14501 $as_echo_n "checking for psaddr_t in sys/procfs.h... " >&6; }
14502  if ${bfd_cv_have_sys_procfs_type_psaddr_t+:} false; then :
14503   $as_echo_n "(cached) " >&6
14504 else
14505   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14506 /* end confdefs.h.  */
14507
14508 #define _SYSCALL32
14509 /* Needed for new procfs interface on sparc-solaris.  */
14510 #define _STRUCTURED_PROC 1
14511 #include <sys/procfs.h>
14512 int
14513 main ()
14514 {
14515 psaddr_t avar
14516   ;
14517   return 0;
14518 }
14519 _ACEOF
14520 if ac_fn_c_try_compile "$LINENO"; then :
14521   bfd_cv_have_sys_procfs_type_psaddr_t=yes
14522 else
14523   bfd_cv_have_sys_procfs_type_psaddr_t=no
14524
14525 fi
14526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14527 fi
14528
14529  if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
14530
14531 $as_echo "#define HAVE_PSADDR_T 1" >>confdefs.h
14532
14533  fi
14534  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
14535 $as_echo "$bfd_cv_have_sys_procfs_type_psaddr_t" >&6; }
14536
14537   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_fpregset_t in sys/procfs.h" >&5
14538 $as_echo_n "checking for elf_fpregset_t in sys/procfs.h... " >&6; }
14539  if ${bfd_cv_have_sys_procfs_type_elf_fpregset_t+:} false; then :
14540   $as_echo_n "(cached) " >&6
14541 else
14542   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14543 /* end confdefs.h.  */
14544
14545 #define _SYSCALL32
14546 /* Needed for new procfs interface on sparc-solaris.  */
14547 #define _STRUCTURED_PROC 1
14548 #include <sys/procfs.h>
14549 int
14550 main ()
14551 {
14552 elf_fpregset_t avar
14553   ;
14554   return 0;
14555 }
14556 _ACEOF
14557 if ac_fn_c_try_compile "$LINENO"; then :
14558   bfd_cv_have_sys_procfs_type_elf_fpregset_t=yes
14559 else
14560   bfd_cv_have_sys_procfs_type_elf_fpregset_t=no
14561
14562 fi
14563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14564 fi
14565
14566  if test $bfd_cv_have_sys_procfs_type_elf_fpregset_t = yes; then
14567
14568 $as_echo "#define HAVE_ELF_FPREGSET_T 1" >>confdefs.h
14569
14570  fi
14571  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&5
14572 $as_echo "$bfd_cv_have_sys_procfs_type_elf_fpregset_t" >&6; }
14573
14574 fi
14575
14576 # Check if the compiler supports the `long long' type.
14577
14578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in compiler" >&5
14579 $as_echo_n "checking for long long support in compiler... " >&6; }
14580 if ${gdb_cv_c_long_long+:} false; then :
14581   $as_echo_n "(cached) " >&6
14582 else
14583   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14584 /* end confdefs.h.  */
14585 extern long long foo;
14586 int
14587 main ()
14588 {
14589 switch (foo & 2) { case 0: return 1; }
14590   ;
14591   return 0;
14592 }
14593 _ACEOF
14594 if ac_fn_c_try_compile "$LINENO"; then :
14595   gdb_cv_c_long_long=yes
14596 else
14597   gdb_cv_c_long_long=no
14598 fi
14599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14600 fi
14601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_long" >&5
14602 $as_echo "$gdb_cv_c_long_long" >&6; }
14603 if test $gdb_cv_c_long_long != yes; then
14604   # libdecnumber requires long long.
14605   as_fn_error $? "Compiler must support long long for GDB." "$LINENO" 5
14606 fi
14607
14608 # Check if the compiler and runtime support printing long longs.
14609
14610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support in printf" >&5
14611 $as_echo_n "checking for long long support in printf... " >&6; }
14612 if ${gdb_cv_printf_has_long_long+:} false; then :
14613   $as_echo_n "(cached) " >&6
14614 else
14615   if test "$cross_compiling" = yes; then :
14616   gdb_cv_printf_has_long_long=no
14617 else
14618   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14619 /* end confdefs.h.  */
14620 $ac_includes_default
14621 int
14622 main ()
14623 {
14624 char buf[32];
14625   long long l = 0;
14626   l = (l << 16) + 0x0123;
14627   l = (l << 16) + 0x4567;
14628   l = (l << 16) + 0x89ab;
14629   l = (l << 16) + 0xcdef;
14630   sprintf (buf, "0x%016llx", l);
14631   return (strcmp ("0x0123456789abcdef", buf));
14632   ;
14633   return 0;
14634 }
14635 _ACEOF
14636 if ac_fn_c_try_run "$LINENO"; then :
14637   gdb_cv_printf_has_long_long=yes
14638 else
14639   gdb_cv_printf_has_long_long=no
14640 fi
14641 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14642   conftest.$ac_objext conftest.beam conftest.$ac_ext
14643 fi
14644
14645 fi
14646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_long" >&5
14647 $as_echo "$gdb_cv_printf_has_long_long" >&6; }
14648 if test $gdb_cv_printf_has_long_long = yes; then
14649
14650 $as_echo "#define PRINTF_HAS_LONG_LONG 1" >>confdefs.h
14651
14652 fi
14653
14654 # Check if the compiler and runtime support printing decfloats.
14655
14656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for decfloat support in printf" >&5
14657 $as_echo_n "checking for decfloat support in printf... " >&6; }
14658 if ${gdb_cv_printf_has_decfloat+:} false; then :
14659   $as_echo_n "(cached) " >&6
14660 else
14661   if test "$cross_compiling" = yes; then :
14662   gdb_cv_printf_has_decfloat=no
14663 else
14664   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14665 /* end confdefs.h.  */
14666 $ac_includes_default
14667 int
14668 main ()
14669 {
14670 char buf[64];
14671   _Decimal32 d32 = 1.2345df;
14672   _Decimal64 d64 = 1.2345dd;
14673   _Decimal128 d128 = 1.2345dl;
14674   sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
14675   return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
14676   ;
14677   return 0;
14678 }
14679 _ACEOF
14680 if ac_fn_c_try_run "$LINENO"; then :
14681   gdb_cv_printf_has_decfloat=yes
14682 else
14683   gdb_cv_printf_has_decfloat=no
14684 fi
14685 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14686   conftest.$ac_objext conftest.beam conftest.$ac_ext
14687 fi
14688
14689 fi
14690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_decfloat" >&5
14691 $as_echo "$gdb_cv_printf_has_decfloat" >&6; }
14692 if test $gdb_cv_printf_has_decfloat = yes; then
14693
14694 $as_echo "#define PRINTF_HAS_DECFLOAT 1" >>confdefs.h
14695
14696 fi
14697
14698 # Check if the compiler supports the `long double' type.  We can't use
14699 # AC_C_LONG_DOUBLE because that one does additional checks on the
14700 # constants defined in <float.h> that fail on some systems,
14701 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
14702
14703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in compiler" >&5
14704 $as_echo_n "checking for long double support in compiler... " >&6; }
14705 if ${gdb_cv_c_long_double+:} false; then :
14706   $as_echo_n "(cached) " >&6
14707 else
14708   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14709 /* end confdefs.h.  */
14710 long double foo;
14711 _ACEOF
14712 if ac_fn_c_try_compile "$LINENO"; then :
14713   gdb_cv_c_long_double=yes
14714 else
14715   gdb_cv_c_long_double=no
14716 fi
14717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14718 fi
14719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_c_long_double" >&5
14720 $as_echo "$gdb_cv_c_long_double" >&6; }
14721 if test $gdb_cv_c_long_double = yes; then
14722
14723 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
14724
14725 fi
14726
14727 # Check if the compiler and runtime support printing long doubles.
14728
14729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in printf" >&5
14730 $as_echo_n "checking for long double support in printf... " >&6; }
14731 if ${gdb_cv_printf_has_long_double+:} false; then :
14732   $as_echo_n "(cached) " >&6
14733 else
14734   if test "$cross_compiling" = yes; then :
14735   gdb_cv_printf_has_long_double=no
14736 else
14737   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14738 /* end confdefs.h.  */
14739 $ac_includes_default
14740 int
14741 main ()
14742 {
14743 char buf[16];
14744   long double f = 3.141592653;
14745   sprintf (buf, "%Lg", f);
14746   return (strncmp ("3.14159", buf, 7));
14747   ;
14748   return 0;
14749 }
14750 _ACEOF
14751 if ac_fn_c_try_run "$LINENO"; then :
14752   gdb_cv_printf_has_long_double=yes
14753 else
14754   gdb_cv_printf_has_long_double=no
14755 fi
14756 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14757   conftest.$ac_objext conftest.beam conftest.$ac_ext
14758 fi
14759
14760 fi
14761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_printf_has_long_double" >&5
14762 $as_echo "$gdb_cv_printf_has_long_double" >&6; }
14763 if test $gdb_cv_printf_has_long_double = yes; then
14764
14765 $as_echo "#define PRINTF_HAS_LONG_DOUBLE 1" >>confdefs.h
14766
14767 fi
14768
14769 # Check if the compiler and runtime support scanning long doubles.
14770
14771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support in scanf" >&5
14772 $as_echo_n "checking for long double support in scanf... " >&6; }
14773 if ${gdb_cv_scanf_has_long_double+:} false; then :
14774   $as_echo_n "(cached) " >&6
14775 else
14776   if test "$cross_compiling" = yes; then :
14777   gdb_cv_scanf_has_long_double=no
14778 else
14779   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14780 /* end confdefs.h.  */
14781 #include <stdio.h>
14782 int
14783 main ()
14784 {
14785 char *buf = "3.141592653";
14786   long double f = 0;
14787   sscanf (buf, "%Lg", &f);
14788   return !(f > 3.14159 && f < 3.14160);
14789   ;
14790   return 0;
14791 }
14792 _ACEOF
14793 if ac_fn_c_try_run "$LINENO"; then :
14794   gdb_cv_scanf_has_long_double=yes
14795 else
14796   gdb_cv_scanf_has_long_double=no
14797 fi
14798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14799   conftest.$ac_objext conftest.beam conftest.$ac_ext
14800 fi
14801
14802 fi
14803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_scanf_has_long_double" >&5
14804 $as_echo "$gdb_cv_scanf_has_long_double" >&6; }
14805 if test $gdb_cv_scanf_has_long_double = yes; then
14806
14807 $as_echo "#define SCANF_HAS_LONG_DOUBLE 1" >>confdefs.h
14808
14809 fi
14810
14811 case ${host_os} in
14812 aix*)
14813   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
14814 $as_echo_n "checking for -bbigtoc option... " >&6; }
14815 if ${gdb_cv_bigtoc+:} false; then :
14816   $as_echo_n "(cached) " >&6
14817 else
14818
14819     SAVE_LDFLAGS=$LDFLAGS
14820
14821     case $GCC in
14822     yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
14823     *) gdb_cv_bigtoc=-bbigtoc ;;
14824     esac
14825
14826     LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
14827     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14828 /* end confdefs.h.  */
14829
14830 int
14831 main ()
14832 {
14833 int i;
14834   ;
14835   return 0;
14836 }
14837 _ACEOF
14838 if ac_fn_c_try_link "$LINENO"; then :
14839
14840 else
14841   gdb_cv_bigtoc=
14842 fi
14843 rm -f core conftest.err conftest.$ac_objext \
14844     conftest$ac_exeext conftest.$ac_ext
14845     LDFLAGS="${SAVE_LDFLAGS}"
14846
14847 fi
14848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
14849 $as_echo "$gdb_cv_bigtoc" >&6; }
14850   CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
14851   ;;
14852 esac
14853
14854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the dynamic export flag" >&5
14855 $as_echo_n "checking for the dynamic export flag... " >&6; }
14856 dynamic_list=false
14857 if test "${gdb_native}" = yes; then
14858    # The dynamically loaded libthread_db needs access to symbols in the gdb
14859    # executable.  Older GNU ld supports --export-dynamic but --dynamic-list
14860    # may not be supported there.
14861    old_LDFLAGS="$LDFLAGS"
14862    # Older GNU ld supports --export-dynamic but --dynamic-list it does not.
14863    RDYNAMIC="-Wl,--dynamic-list=${srcdir}/proc-service.list"
14864    LDFLAGS="$LDFLAGS $RDYNAMIC"
14865    if test "${have_libpython}" = no; then
14866      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14867 /* end confdefs.h.  */
14868
14869 int
14870 main ()
14871 {
14872
14873   ;
14874   return 0;
14875 }
14876 _ACEOF
14877 if ac_fn_c_try_link "$LINENO"; then :
14878   dynamic_list=true
14879 fi
14880 rm -f core conftest.err conftest.$ac_objext \
14881     conftest$ac_exeext conftest.$ac_ext
14882    else
14883      # Workaround http://bugs.python.org/issue4434 where static
14884      # libpythonX.Y.a would get its symbols required for
14885      # pythonX.Y/lib-dynload/*.so modules hidden by -Wl,--dynamic-list.
14886      # Problem does not happen for the recommended libpythonX.Y.so linkage.
14887
14888      # Note the workaround for Python
14889      # http://bugs.python.org/issue10112 earlier has removed
14890      # -export-dynamic from PYTHON_LIBS.  That's exactly what we want
14891      # here too, as otherwise it'd make this -Wl,--dynamic-list test
14892      # always pass.
14893      old_CFLAGS="$CFLAGS"
14894      CFLAGS="$CFLAGS $PYTHON_CFLAGS"
14895      old_LIBS="$LIBS"
14896      LIBS="$LIBS $PYTHON_LIBS"
14897      old_CPPFLAGS="$CPPFLAGS"
14898      CPPFLAGS="$CPPFLAGS $PYTHON_CPPFLAGS"
14899      if test "$cross_compiling" = yes; then :
14900   true
14901 else
14902   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14903 /* end confdefs.h.  */
14904 #include "Python.h"
14905 int
14906 main ()
14907 {
14908 int err;
14909           Py_Initialize ();
14910           err = PyRun_SimpleString ("import itertools\n");
14911           Py_Finalize ();
14912           return err == 0 ? 0 : 1;
14913   ;
14914   return 0;
14915 }
14916 _ACEOF
14917 if ac_fn_c_try_run "$LINENO"; then :
14918   dynamic_list=true
14919 fi
14920 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14921   conftest.$ac_objext conftest.beam conftest.$ac_ext
14922 fi
14923
14924      LIBS="$old_LIBS"
14925      CFLAGS="$old_CFLAGS"
14926      CPPFLAGS="$old_CPPFLAGS"
14927    fi
14928    LDFLAGS="$old_LDFLAGS"
14929 fi
14930 if $dynamic_list; then
14931   found="-Wl,--dynamic-list"
14932   RDYNAMIC='-Wl,--dynamic-list=$(srcdir)/proc-service.list'
14933 else
14934   found="-rdynamic"
14935   RDYNAMIC="-rdynamic"
14936 fi
14937
14938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $found" >&5
14939 $as_echo "$found" >&6; }
14940
14941
14942 if test ${build} = ${host} -a ${host} = ${target} ; then
14943    case ${host_os} in
14944    aix*)
14945       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AiX thread debugging library" >&5
14946 $as_echo_n "checking for AiX thread debugging library... " >&6; }
14947       if ${gdb_cv_have_aix_thread_debug+:} false; then :
14948   $as_echo_n "(cached) " >&6
14949 else
14950   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14951 /* end confdefs.h.  */
14952 #include <sys/pthdebug.h>
14953 int
14954 main ()
14955 {
14956 #ifndef PTHDB_VERSION_3
14957                                     #error
14958                                     #endif
14959   ;
14960   return 0;
14961 }
14962 _ACEOF
14963 if ac_fn_c_try_compile "$LINENO"; then :
14964   gdb_cv_have_aix_thread_debug=yes
14965 else
14966   gdb_cv_have_aix_thread_debug=no
14967 fi
14968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14969 fi
14970
14971       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_have_aix_thread_debug" >&5
14972 $as_echo "$gdb_cv_have_aix_thread_debug" >&6; }
14973       if test $gdb_cv_have_aix_thread_debug = yes; then
14974          CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
14975          CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
14976          LIBS="$LIBS -lpthdebug"
14977
14978          # Older versions of AIX do not provide the declaration for
14979          # the getthrds function (it appears that it was introduced
14980          # with AIX 6.x).
14981          ac_fn_c_check_decl "$LINENO" "getthrds" "ac_cv_have_decl_getthrds" "#include <procinfo.h>
14982 "
14983 if test "x$ac_cv_have_decl_getthrds" = xyes; then :
14984   ac_have_decl=1
14985 else
14986   ac_have_decl=0
14987 fi
14988
14989 cat >>confdefs.h <<_ACEOF
14990 #define HAVE_DECL_GETTHRDS $ac_have_decl
14991 _ACEOF
14992
14993       fi
14994       ;;
14995    esac
14996
14997 fi
14998
14999 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
15000    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTALLOC" >&5
15001 $as_echo_n "checking whether <thread_db.h> has TD_NOTALLOC... " >&6; }
15002 if ${gdb_cv_thread_db_h_has_td_notalloc+:} false; then :
15003   $as_echo_n "(cached) " >&6
15004 else
15005   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15006 /* end confdefs.h.  */
15007 #include <thread_db.h>
15008 int
15009 main ()
15010 {
15011 int i = TD_NOTALLOC;
15012   ;
15013   return 0;
15014 }
15015 _ACEOF
15016 if ac_fn_c_try_compile "$LINENO"; then :
15017   gdb_cv_thread_db_h_has_td_notalloc=yes
15018 else
15019   gdb_cv_thread_db_h_has_td_notalloc=no
15020
15021 fi
15022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15023
15024 fi
15025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
15026 $as_echo "$gdb_cv_thread_db_h_has_td_notalloc" >&6; }
15027    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_VERSION" >&5
15028 $as_echo_n "checking whether <thread_db.h> has TD_VERSION... " >&6; }
15029 if ${gdb_cv_thread_db_h_has_td_version+:} false; then :
15030   $as_echo_n "(cached) " >&6
15031 else
15032   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15033 /* end confdefs.h.  */
15034 #include <thread_db.h>
15035 int
15036 main ()
15037 {
15038 int i = TD_VERSION;
15039   ;
15040   return 0;
15041 }
15042 _ACEOF
15043 if ac_fn_c_try_compile "$LINENO"; then :
15044   gdb_cv_thread_db_h_has_td_version=yes
15045 else
15046   gdb_cv_thread_db_h_has_td_version=no
15047
15048 fi
15049 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15050
15051 fi
15052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_version" >&5
15053 $as_echo "$gdb_cv_thread_db_h_has_td_version" >&6; }
15054    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <thread_db.h> has TD_NOTLS" >&5
15055 $as_echo_n "checking whether <thread_db.h> has TD_NOTLS... " >&6; }
15056 if ${gdb_cv_thread_db_h_has_td_notls+:} false; then :
15057   $as_echo_n "(cached) " >&6
15058 else
15059   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15060 /* end confdefs.h.  */
15061 #include <thread_db.h>
15062 int
15063 main ()
15064 {
15065 int i = TD_NOTLS;
15066   ;
15067   return 0;
15068 }
15069 _ACEOF
15070 if ac_fn_c_try_compile "$LINENO"; then :
15071   gdb_cv_thread_db_h_has_td_notls=yes
15072 else
15073   gdb_cv_thread_db_h_has_td_notls=no
15074
15075 fi
15076 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15077
15078 fi
15079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_thread_db_h_has_td_notls" >&5
15080 $as_echo "$gdb_cv_thread_db_h_has_td_notls" >&6; }
15081 fi
15082 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
15083
15084 $as_echo "#define THREAD_DB_HAS_TD_NOTALLOC 1" >>confdefs.h
15085
15086 fi
15087 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
15088
15089 $as_echo "#define THREAD_DB_HAS_TD_VERSION 1" >>confdefs.h
15090
15091 fi
15092 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
15093
15094 $as_echo "#define THREAD_DB_HAS_TD_NOTLS 1" >>confdefs.h
15095
15096 fi
15097
15098 ac_fn_c_check_decl "$LINENO" "ADDR_NO_RANDOMIZE" "ac_cv_have_decl_ADDR_NO_RANDOMIZE" "#include <sys/personality.h>
15099 "
15100 if test "x$ac_cv_have_decl_ADDR_NO_RANDOMIZE" = xyes; then :
15101   ac_have_decl=1
15102 else
15103   ac_have_decl=0
15104 fi
15105
15106 cat >>confdefs.h <<_ACEOF
15107 #define HAVE_DECL_ADDR_NO_RANDOMIZE $ac_have_decl
15108 _ACEOF
15109
15110
15111 if test "$cross_compiling" = yes; then :
15112   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15113 /* end confdefs.h.  */
15114 #include <sys/personality.h>
15115 int
15116 main ()
15117 {
15118
15119 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
15120 #       define ADDR_NO_RANDOMIZE 0x0040000
15121 #      endif
15122        /* Test the flag could be set and stays set.  */
15123        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
15124        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
15125            return 1
15126   ;
15127   return 0;
15128 }
15129 _ACEOF
15130 if ac_fn_c_try_link "$LINENO"; then :
15131   have_personality=true
15132 else
15133   have_personality=false
15134 fi
15135 rm -f core conftest.err conftest.$ac_objext \
15136     conftest$ac_exeext conftest.$ac_ext
15137 else
15138   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15139 /* end confdefs.h.  */
15140 #include <sys/personality.h>
15141 int
15142 main ()
15143 {
15144
15145 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
15146 #       define ADDR_NO_RANDOMIZE 0x0040000
15147 #      endif
15148        /* Test the flag could be set and stays set.  */
15149        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
15150        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
15151            return 1
15152   ;
15153   return 0;
15154 }
15155 _ACEOF
15156 if ac_fn_c_try_run "$LINENO"; then :
15157   have_personality=true
15158 else
15159   have_personality=false
15160 fi
15161 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15162   conftest.$ac_objext conftest.beam conftest.$ac_ext
15163 fi
15164
15165 if $have_personality
15166 then
15167
15168 $as_echo "#define HAVE_PERSONALITY 1" >>confdefs.h
15169
15170 fi
15171
15172 case $host_os in
15173   go32* | *djgpp*)
15174     gdbinit=gdb.ini
15175     ;;
15176   *)
15177     gdbinit=.gdbinit
15178     ;;
15179 esac
15180
15181 cat >>confdefs.h <<_ACEOF
15182 #define GDBINIT "$gdbinit"
15183 _ACEOF
15184
15185
15186
15187 # Support for --with-sysroot is a copy of GDB_AC_WITH_DIR,
15188 # except that the argument to --with-sysroot is optional.
15189 # --with-sysroot (or --with-sysroot=yes) sets the default sysroot path.
15190 if test "x$with_sysroot" = xyes; then
15191   with_sysroot="${exec_prefix}/${target_alias}/sys-root"
15192 fi
15193
15194 # Check whether --with-sysroot was given.
15195 if test "${with_sysroot+set}" = set; then :
15196   withval=$with_sysroot; TARGET_SYSTEM_ROOT=$withval
15197 else
15198   TARGET_SYSTEM_ROOT=
15199 fi
15200
15201
15202   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
15203   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15204   ac_define_dir=`eval echo $TARGET_SYSTEM_ROOT`
15205   ac_define_dir=`eval echo $ac_define_dir`
15206
15207 cat >>confdefs.h <<_ACEOF
15208 #define TARGET_SYSTEM_ROOT "$ac_define_dir"
15209 _ACEOF
15210
15211
15212
15213
15214   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
15215      if test "x$prefix" = xNONE; then
15216         test_prefix=/usr/local
15217      else
15218         test_prefix=$prefix
15219      fi
15220   else
15221      test_prefix=$exec_prefix
15222   fi
15223   value=0
15224   case ${ac_define_dir} in
15225      "${test_prefix}"|"${test_prefix}/"*|\
15226         '${exec_prefix}'|'${exec_prefix}/'*)
15227      value=1
15228      ;;
15229   esac
15230
15231 cat >>confdefs.h <<_ACEOF
15232 #define TARGET_SYSTEM_ROOT_RELOCATABLE $value
15233 _ACEOF
15234
15235
15236
15237
15238
15239 # Check whether --with-system-gdbinit was given.
15240 if test "${with_system_gdbinit+set}" = set; then :
15241   withval=$with_system_gdbinit;
15242     SYSTEM_GDBINIT=$withval
15243 else
15244   SYSTEM_GDBINIT=
15245 fi
15246
15247
15248   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
15249   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15250   ac_define_dir=`eval echo $SYSTEM_GDBINIT`
15251   ac_define_dir=`eval echo $ac_define_dir`
15252
15253 cat >>confdefs.h <<_ACEOF
15254 #define SYSTEM_GDBINIT "$ac_define_dir"
15255 _ACEOF
15256
15257
15258
15259
15260   if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
15261      if test "x$prefix" = xNONE; then
15262         test_prefix=/usr/local
15263      else
15264         test_prefix=$prefix
15265      fi
15266   else
15267      test_prefix=$exec_prefix
15268   fi
15269   value=0
15270   case ${ac_define_dir} in
15271      "${test_prefix}"|"${test_prefix}/"*|\
15272         '${exec_prefix}'|'${exec_prefix}/'*)
15273      value=1
15274      ;;
15275   esac
15276
15277 cat >>confdefs.h <<_ACEOF
15278 #define SYSTEM_GDBINIT_RELOCATABLE $value
15279 _ACEOF
15280
15281
15282
15283
15284
15285 # Check whether --enable-werror was given.
15286 if test "${enable_werror+set}" = set; then :
15287   enableval=$enable_werror; case "${enableval}" in
15288      yes | y) ERROR_ON_WARNING="yes" ;;
15289      no | n)  ERROR_ON_WARNING="no" ;;
15290      *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
15291    esac
15292 fi
15293
15294
15295 # Enable -Werror by default when using gcc.  Turn it off for releases.
15296 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" && $development; then
15297     ERROR_ON_WARNING=yes
15298 fi
15299
15300 WERROR_CFLAGS=""
15301 if test "${ERROR_ON_WARNING}" = yes ; then
15302     WERROR_CFLAGS="-Werror"
15303 fi
15304
15305 # The options we'll try to enable.
15306 build_warnings="-Wall -Wpointer-arith \
15307 -Wno-unused -Wunused-value -Wunused-variable -Wunused-function \
15308 -Wno-switch -Wno-char-subscripts \
15309 -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable \
15310 -Wno-sign-compare -Wno-error=maybe-uninitialized \
15311 -Wno-mismatched-tags \
15312 -Wno-error=deprecated-register \
15313 -Wsuggest-override \
15314 -Wimplicit-fallthrough=3 \
15315 -Wduplicated-cond \
15316 -Wshadow=local \
15317 -Wdeprecated-copy \
15318 -Wdeprecated-copy-dtor \
15319 -Wredundant-move"
15320
15321 case "${host}" in
15322   *-*-mingw32*)
15323     # Enable -Wno-format by default when using gcc on mingw since many
15324     # GCC versions complain about %I64.
15325     build_warnings="$build_warnings -Wno-format" ;;
15326   *-*-solaris*)
15327     # Solaris 11.4 <python2.7/ceval.h> uses #pragma no_inline that GCC
15328     # doesn't understand.
15329     build_warnings="$build_warnings -Wno-unknown-pragmas"
15330     # Solaris 11 <unistd.h> marks vfork deprecated.
15331     build_warnings="$build_warnings -Wno-deprecated-declarations" ;;
15332   *)
15333     # Note that gcc requires -Wformat for -Wformat-nonliteral to work,
15334     # but there's a special case for this below.
15335     build_warnings="$build_warnings -Wformat-nonliteral" ;;
15336 esac
15337
15338 # Check whether --enable-build-warnings was given.
15339 if test "${enable_build_warnings+set}" = set; then :
15340   enableval=$enable_build_warnings; case "${enableval}" in
15341   yes)  ;;
15342   no)   build_warnings="-w";;
15343   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
15344         build_warnings="${build_warnings} ${t}";;
15345   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
15346         build_warnings="${t} ${build_warnings}";;
15347   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
15348 esac
15349 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
15350   echo "Setting compiler warning flags = $build_warnings" 6>&1
15351 fi
15352 fi
15353 # Check whether --enable-gdb-build-warnings was given.
15354 if test "${enable_gdb_build_warnings+set}" = set; then :
15355   enableval=$enable_gdb_build_warnings; case "${enableval}" in
15356   yes)  ;;
15357   no)   build_warnings="-w";;
15358   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
15359         build_warnings="${build_warnings} ${t}";;
15360   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
15361         build_warnings="${t} ${build_warnings}";;
15362   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
15363 esac
15364 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
15365   echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
15366 fi
15367 fi
15368
15369 # The set of warnings supported by a C++ compiler is not the same as
15370 # of the C compiler.
15371 ac_ext=cpp
15372 ac_cpp='$CXXCPP $CPPFLAGS'
15373 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15374 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15375 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
15376
15377
15378 WARN_CFLAGS=""
15379 if test "x${build_warnings}" != x -a "x$GCC" = xyes
15380 then
15381     { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
15382 $as_echo_n "checking compiler warning flags... " >&6; }
15383     # Separate out the -Werror flag as some files just cannot be
15384     # compiled with it enabled.
15385     for w in ${build_warnings}; do
15386         # GCC does not complain about -Wno-unknown-warning.  Invert
15387         # and test -Wunknown-warning instead.
15388         case $w in
15389         -Wno-*)
15390                 wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
15391         -Wformat-nonliteral)
15392                 # gcc requires -Wformat before -Wformat-nonliteral
15393                 # will work, so stick them together.
15394                 w="-Wformat $w"
15395                 wtest="$w"
15396                 ;;
15397         *)
15398                 wtest=$w ;;
15399         esac
15400
15401         case $w in
15402         -Werr*) WERROR_CFLAGS=-Werror ;;
15403         *)
15404             # Check whether GCC accepts it.
15405             saved_CFLAGS="$CFLAGS"
15406             CFLAGS="$CFLAGS -Werror $wtest"
15407             saved_CXXFLAGS="$CXXFLAGS"
15408             CXXFLAGS="$CXXFLAGS -Werror $wtest"
15409             if test "x$w" = "x-Wunused-variable"; then
15410               # Check for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=38958,
15411               # fixed in GCC 4.9.  This test is derived from the gdb
15412               # source code that triggered this bug in GCC.
15413               cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15414 /* end confdefs.h.  */
15415 struct scoped_restore_base {};
15416                  struct scoped_restore_tmpl : public scoped_restore_base {
15417                    ~scoped_restore_tmpl() {}
15418                  };
15419 int
15420 main ()
15421 {
15422 const scoped_restore_base &b = scoped_restore_tmpl();
15423   ;
15424   return 0;
15425 }
15426 _ACEOF
15427 if ac_fn_cxx_try_compile "$LINENO"; then :
15428   WARN_CFLAGS="${WARN_CFLAGS} $w"
15429 fi
15430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15431             else
15432               cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15433 /* end confdefs.h.  */
15434
15435 int
15436 main ()
15437 {
15438
15439   ;
15440   return 0;
15441 }
15442 _ACEOF
15443 if ac_fn_cxx_try_compile "$LINENO"; then :
15444   WARN_CFLAGS="${WARN_CFLAGS} $w"
15445 fi
15446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15447             fi
15448             CFLAGS="$saved_CFLAGS"
15449             CXXFLAGS="$saved_CXXFLAGS"
15450         esac
15451     done
15452     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
15453 $as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
15454 fi
15455
15456
15457
15458 ac_ext=c
15459 ac_cpp='$CPP $CPPFLAGS'
15460 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15461 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15462 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15463
15464
15465
15466 # Check whether --enable-ubsan was given.
15467 if test "${enable_ubsan+set}" = set; then :
15468   enableval=$enable_ubsan;
15469 else
15470   enable_ubsan=no
15471 fi
15472
15473 if test "x$enable_ubsan" = xauto; then
15474   if $development; then
15475     enable_ubsan=yes
15476   fi
15477 fi
15478 ac_ext=cpp
15479 ac_cpp='$CXXCPP $CPPFLAGS'
15480 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15481 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15482 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
15483
15484 if test "x$enable_ubsan" = xyes; then
15485   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -fsanitize=undefined is accepted" >&5
15486 $as_echo_n "checking whether -fsanitize=undefined is accepted... " >&6; }
15487   saved_CXXFLAGS="$CXXFLAGS"
15488   CXXFLAGS="$CXXFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
15489         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15490 /* end confdefs.h.  */
15491
15492 int
15493 main ()
15494 {
15495
15496   ;
15497   return 0;
15498 }
15499 _ACEOF
15500 if ac_fn_cxx_try_link "$LINENO"; then :
15501   enable_ubsan=yes
15502 else
15503   enable_ubsan=no
15504 fi
15505 rm -f core conftest.err conftest.$ac_objext \
15506     conftest$ac_exeext conftest.$ac_ext
15507   CXXFLAGS="$saved_CXXFLAGS"
15508   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_ubsan" >&5
15509 $as_echo "$enable_ubsan" >&6; }
15510   if test "x$enable_ubsan" = xyes; then
15511     WARN_CFLAGS="$WARN_CFLAGS -fsanitize=undefined -fno-sanitize-recover=undefined"
15512     CONFIG_LDFLAGS="$CONFIG_LDFLAGS -fsanitize=undefined"
15513   fi
15514 fi
15515 ac_ext=c
15516 ac_cpp='$CPP $CPPFLAGS'
15517 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15518 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15519 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15520
15521
15522
15523 # In the Cygwin environment, we need some additional flags.
15524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
15525 $as_echo_n "checking for cygwin... " >&6; }
15526 if ${gdb_cv_os_cygwin+:} false; then :
15527   $as_echo_n "(cached) " >&6
15528 else
15529   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15530 /* end confdefs.h.  */
15531
15532 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
15533 lose
15534 #endif
15535 _ACEOF
15536 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15537   $EGREP "^lose$" >/dev/null 2>&1; then :
15538   gdb_cv_os_cygwin=yes
15539 else
15540   gdb_cv_os_cygwin=no
15541 fi
15542 rm -f conftest*
15543
15544 fi
15545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_os_cygwin" >&5
15546 $as_echo "$gdb_cv_os_cygwin" >&6; }
15547
15548
15549 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
15550 case ${host} in
15551   *go32* ) SER_HARDWIRE=ser-go32.o ;;
15552   *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
15553   *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
15554   *) SER_HARDWIRE="$SER_HARDWIRE ser-uds.o" ;;
15555 esac
15556
15557
15558 # libreadline needs libuser32.a in a cygwin environment
15559 WIN32LIBS=
15560 if test x$gdb_cv_os_cygwin = xyes; then
15561     WIN32LIBS="-luser32"
15562     case "${target}" in
15563         *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
15564         ;;
15565     esac
15566 fi
15567
15568 # The ser-tcp.c module requires sockets.
15569 case ${host} in
15570   *mingw32*)
15571
15572 $as_echo "#define USE_WIN32API 1" >>confdefs.h
15573
15574     WIN32LIBS="$WIN32LIBS -lws2_32"
15575     ;;
15576 esac
15577
15578
15579 # Add ELF support to GDB, but only if BFD includes ELF support.
15580
15581   OLD_CFLAGS=$CFLAGS
15582   OLD_LDFLAGS=$LDFLAGS
15583   OLD_LIBS=$LIBS
15584   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
15585   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
15586   # always want our bfd.
15587   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
15588   ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
15589   LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
15590   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
15591   LIBS="-lbfd -liberty -lz $intl $LIBS"
15592   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF support in BFD" >&5
15593 $as_echo_n "checking for ELF support in BFD... " >&6; }
15594 if ${gdb_cv_var_elf+:} false; then :
15595   $as_echo_n "(cached) " >&6
15596 else
15597   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15598 /* end confdefs.h.  */
15599 #include <stdlib.h>
15600   #include "bfd.h"
15601   #include "elf-bfd.h"
15602
15603 int
15604 main ()
15605 {
15606 return bfd_get_elf_phdr_upper_bound (NULL);
15607   ;
15608   return 0;
15609 }
15610 _ACEOF
15611 if ac_fn_c_try_link "$LINENO"; then :
15612   gdb_cv_var_elf=yes
15613 else
15614   gdb_cv_var_elf=no
15615 fi
15616 rm -f core conftest.err conftest.$ac_objext \
15617     conftest$ac_exeext conftest.$ac_ext
15618 fi
15619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_elf" >&5
15620 $as_echo "$gdb_cv_var_elf" >&6; }
15621   CFLAGS=$OLD_CFLAGS
15622   LDFLAGS=$OLD_LDFLAGS
15623   LIBS=$OLD_LIBS
15624 if test $gdb_cv_var_elf = yes; then
15625   CONFIG_OBS="$CONFIG_OBS elfread.o stap-probe.o dtrace-probe.o"
15626
15627 $as_echo "#define HAVE_ELF 1" >>confdefs.h
15628
15629   # -ldl is provided by bfd/Makfile.am (LIBDL) <PLUGINS>.
15630   if test "$plugins" = "yes"; then
15631     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
15632 $as_echo_n "checking for library containing dlopen... " >&6; }
15633 if ${ac_cv_search_dlopen+:} false; then :
15634   $as_echo_n "(cached) " >&6
15635 else
15636   ac_func_search_save_LIBS=$LIBS
15637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15638 /* end confdefs.h.  */
15639
15640 /* Override any GCC internal prototype to avoid an error.
15641    Use char because int might match the return type of a GCC
15642    builtin and then its argument prototype would still apply.  */
15643 #ifdef __cplusplus
15644 extern "C"
15645 #endif
15646 char dlopen ();
15647 int
15648 main ()
15649 {
15650 return dlopen ();
15651   ;
15652   return 0;
15653 }
15654 _ACEOF
15655 for ac_lib in '' dl; do
15656   if test -z "$ac_lib"; then
15657     ac_res="none required"
15658   else
15659     ac_res=-l$ac_lib
15660     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15661   fi
15662   if ac_fn_c_try_link "$LINENO"; then :
15663   ac_cv_search_dlopen=$ac_res
15664 fi
15665 rm -f core conftest.err conftest.$ac_objext \
15666     conftest$ac_exeext
15667   if ${ac_cv_search_dlopen+:} false; then :
15668   break
15669 fi
15670 done
15671 if ${ac_cv_search_dlopen+:} false; then :
15672
15673 else
15674   ac_cv_search_dlopen=no
15675 fi
15676 rm conftest.$ac_ext
15677 LIBS=$ac_func_search_save_LIBS
15678 fi
15679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
15680 $as_echo "$ac_cv_search_dlopen" >&6; }
15681 ac_res=$ac_cv_search_dlopen
15682 if test "$ac_res" != no; then :
15683   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15684
15685 fi
15686
15687   fi
15688 fi
15689
15690 # Add macho support to GDB, but only if BFD includes it.
15691
15692   OLD_CFLAGS=$CFLAGS
15693   OLD_LDFLAGS=$LDFLAGS
15694   OLD_LIBS=$LIBS
15695   # Put the old CFLAGS/LDFLAGS last, in case the user's (C|LD)FLAGS
15696   # points somewhere with bfd, with -I/foo/lib and -L/foo/lib.  We
15697   # always want our bfd.
15698   CFLAGS="-I${srcdir}/../include -I../bfd -I${srcdir}/../bfd $CFLAGS"
15699   ZLIBDIR=`echo $zlibdir | sed 's,\$(top_builddir)/,,g'`
15700   LDFLAGS="-L../bfd -L../libiberty $ZLIBDIR $LDFLAGS"
15701   intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
15702   LIBS="-lbfd -liberty -lz $intl $LIBS"
15703   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mach-O support in BFD" >&5
15704 $as_echo_n "checking for Mach-O support in BFD... " >&6; }
15705 if ${gdb_cv_var_macho+:} false; then :
15706   $as_echo_n "(cached) " >&6
15707 else
15708   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15709 /* end confdefs.h.  */
15710 #include <stdlib.h>
15711   #include "bfd.h"
15712   #include "mach-o.h"
15713
15714 int
15715 main ()
15716 {
15717 return bfd_mach_o_lookup_command (NULL, 0, NULL);
15718   ;
15719   return 0;
15720 }
15721 _ACEOF
15722 if ac_fn_c_try_link "$LINENO"; then :
15723   gdb_cv_var_macho=yes
15724 else
15725   gdb_cv_var_macho=no
15726 fi
15727 rm -f core conftest.err conftest.$ac_objext \
15728     conftest$ac_exeext conftest.$ac_ext
15729 fi
15730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_var_macho" >&5
15731 $as_echo "$gdb_cv_var_macho" >&6; }
15732   CFLAGS=$OLD_CFLAGS
15733   LDFLAGS=$OLD_LDFLAGS
15734   LIBS=$OLD_LIBS
15735 if test $gdb_cv_var_macho = yes; then
15736   CONFIG_OBS="$CONFIG_OBS machoread.o"
15737 fi
15738
15739 # Add any host-specific objects to GDB.
15740 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
15741
15742 # If building on ELF, look for lzma support for embedded compressed debug info.
15743 if test $gdb_cv_var_elf = yes; then
15744
15745 # Check whether --with-lzma was given.
15746 if test "${with_lzma+set}" = set; then :
15747   withval=$with_lzma;
15748 else
15749   with_lzma=auto
15750 fi
15751
15752   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use lzma" >&5
15753 $as_echo_n "checking whether to use lzma... " >&6; }
15754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lzma" >&5
15755 $as_echo "$with_lzma" >&6; }
15756
15757   if test "${with_lzma}" != no; then
15758
15759
15760
15761
15762
15763
15764
15765
15766     use_additional=yes
15767
15768   acl_save_prefix="$prefix"
15769   prefix="$acl_final_prefix"
15770   acl_save_exec_prefix="$exec_prefix"
15771   exec_prefix="$acl_final_exec_prefix"
15772
15773     eval additional_includedir=\"$includedir\"
15774     eval additional_libdir=\"$libdir\"
15775
15776   exec_prefix="$acl_save_exec_prefix"
15777   prefix="$acl_save_prefix"
15778
15779
15780 # Check whether --with-liblzma-prefix was given.
15781 if test "${with_liblzma_prefix+set}" = set; then :
15782   withval=$with_liblzma_prefix;
15783     if test "X$withval" = "Xno"; then
15784       use_additional=no
15785     else
15786       if test "X$withval" = "X"; then
15787
15788   acl_save_prefix="$prefix"
15789   prefix="$acl_final_prefix"
15790   acl_save_exec_prefix="$exec_prefix"
15791   exec_prefix="$acl_final_exec_prefix"
15792
15793           eval additional_includedir=\"$includedir\"
15794           eval additional_libdir=\"$libdir\"
15795
15796   exec_prefix="$acl_save_exec_prefix"
15797   prefix="$acl_save_prefix"
15798
15799       else
15800         additional_includedir="$withval/include"
15801         additional_libdir="$withval/lib"
15802       fi
15803     fi
15804
15805 fi
15806
15807       LIBLZMA=
15808   LTLIBLZMA=
15809   INCLZMA=
15810   rpathdirs=
15811   ltrpathdirs=
15812   names_already_handled=
15813   names_next_round='lzma '
15814   while test -n "$names_next_round"; do
15815     names_this_round="$names_next_round"
15816     names_next_round=
15817     for name in $names_this_round; do
15818       already_handled=
15819       for n in $names_already_handled; do
15820         if test "$n" = "$name"; then
15821           already_handled=yes
15822           break
15823         fi
15824       done
15825       if test -z "$already_handled"; then
15826         names_already_handled="$names_already_handled $name"
15827                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
15828         eval value=\"\$HAVE_LIB$uppername\"
15829         if test -n "$value"; then
15830           if test "$value" = yes; then
15831             eval value=\"\$LIB$uppername\"
15832             test -z "$value" || LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$value"
15833             eval value=\"\$LTLIB$uppername\"
15834             test -z "$value" || LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$value"
15835           else
15836                                     :
15837           fi
15838         else
15839                               found_dir=
15840           found_la=
15841           found_so=
15842           found_a=
15843           if test $use_additional = yes; then
15844             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
15845               found_dir="$additional_libdir"
15846               found_so="$additional_libdir/lib$name.$shlibext"
15847               if test -f "$additional_libdir/lib$name.la"; then
15848                 found_la="$additional_libdir/lib$name.la"
15849               fi
15850             else
15851               if test -f "$additional_libdir/lib$name.$libext"; then
15852                 found_dir="$additional_libdir"
15853                 found_a="$additional_libdir/lib$name.$libext"
15854                 if test -f "$additional_libdir/lib$name.la"; then
15855                   found_la="$additional_libdir/lib$name.la"
15856                 fi
15857               fi
15858             fi
15859           fi
15860           if test "X$found_dir" = "X"; then
15861             for x in $LDFLAGS $LTLIBLZMA; do
15862
15863   acl_save_prefix="$prefix"
15864   prefix="$acl_final_prefix"
15865   acl_save_exec_prefix="$exec_prefix"
15866   exec_prefix="$acl_final_exec_prefix"
15867   eval x=\"$x\"
15868   exec_prefix="$acl_save_exec_prefix"
15869   prefix="$acl_save_prefix"
15870
15871               case "$x" in
15872                 -L*)
15873                   dir=`echo "X$x" | sed -e 's/^X-L//'`
15874                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
15875                     found_dir="$dir"
15876                     found_so="$dir/lib$name.$shlibext"
15877                     if test -f "$dir/lib$name.la"; then
15878                       found_la="$dir/lib$name.la"
15879                     fi
15880                   else
15881                     if test -f "$dir/lib$name.$libext"; then
15882                       found_dir="$dir"
15883                       found_a="$dir/lib$name.$libext"
15884                       if test -f "$dir/lib$name.la"; then
15885                         found_la="$dir/lib$name.la"
15886                       fi
15887                     fi
15888                   fi
15889                   ;;
15890               esac
15891               if test "X$found_dir" != "X"; then
15892                 break
15893               fi
15894             done
15895           fi
15896           if test "X$found_dir" != "X"; then
15897                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$found_dir -l$name"
15898             if test "X$found_so" != "X"; then
15899                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
15900                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15901               else
15902                                                                                 haveit=
15903                 for x in $ltrpathdirs; do
15904                   if test "X$x" = "X$found_dir"; then
15905                     haveit=yes
15906                     break
15907                   fi
15908                 done
15909                 if test -z "$haveit"; then
15910                   ltrpathdirs="$ltrpathdirs $found_dir"
15911                 fi
15912                                 if test "$hardcode_direct" = yes; then
15913                                                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15914                 else
15915                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
15916                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15917                                                             haveit=
15918                     for x in $rpathdirs; do
15919                       if test "X$x" = "X$found_dir"; then
15920                         haveit=yes
15921                         break
15922                       fi
15923                     done
15924                     if test -z "$haveit"; then
15925                       rpathdirs="$rpathdirs $found_dir"
15926                     fi
15927                   else
15928                                                                                 haveit=
15929                     for x in $LDFLAGS $LIBLZMA; do
15930
15931   acl_save_prefix="$prefix"
15932   prefix="$acl_final_prefix"
15933   acl_save_exec_prefix="$exec_prefix"
15934   exec_prefix="$acl_final_exec_prefix"
15935   eval x=\"$x\"
15936   exec_prefix="$acl_save_exec_prefix"
15937   prefix="$acl_save_prefix"
15938
15939                       if test "X$x" = "X-L$found_dir"; then
15940                         haveit=yes
15941                         break
15942                       fi
15943                     done
15944                     if test -z "$haveit"; then
15945                       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir"
15946                     fi
15947                     if test "$hardcode_minus_L" != no; then
15948                                                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_so"
15949                     else
15950                                                                                                                                                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
15951                     fi
15952                   fi
15953                 fi
15954               fi
15955             else
15956               if test "X$found_a" != "X"; then
15957                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$found_a"
15958               else
15959                                                 LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$found_dir -l$name"
15960               fi
15961             fi
15962                         additional_includedir=
15963             case "$found_dir" in
15964               */lib | */lib/)
15965                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
15966                 additional_includedir="$basedir/include"
15967                 ;;
15968             esac
15969             if test "X$additional_includedir" != "X"; then
15970                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
15971                 haveit=
15972                 if test "X$additional_includedir" = "X/usr/local/include"; then
15973                   if test -n "$GCC"; then
15974                     case $host_os in
15975                       linux*) haveit=yes;;
15976                     esac
15977                   fi
15978                 fi
15979                 if test -z "$haveit"; then
15980                   for x in $CPPFLAGS $INCLZMA; do
15981
15982   acl_save_prefix="$prefix"
15983   prefix="$acl_final_prefix"
15984   acl_save_exec_prefix="$exec_prefix"
15985   exec_prefix="$acl_final_exec_prefix"
15986   eval x=\"$x\"
15987   exec_prefix="$acl_save_exec_prefix"
15988   prefix="$acl_save_prefix"
15989
15990                     if test "X$x" = "X-I$additional_includedir"; then
15991                       haveit=yes
15992                       break
15993                     fi
15994                   done
15995                   if test -z "$haveit"; then
15996                     if test -d "$additional_includedir"; then
15997                                             INCLZMA="${INCLZMA}${INCLZMA:+ }-I$additional_includedir"
15998                     fi
15999                   fi
16000                 fi
16001               fi
16002             fi
16003                         if test -n "$found_la"; then
16004                                                         save_libdir="$libdir"
16005               case "$found_la" in
16006                 */* | *\\*) . "$found_la" ;;
16007                 *) . "./$found_la" ;;
16008               esac
16009               libdir="$save_libdir"
16010                             for dep in $dependency_libs; do
16011                 case "$dep" in
16012                   -L*)
16013                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
16014                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
16015                       haveit=
16016                       if test "X$additional_libdir" = "X/usr/local/lib"; then
16017                         if test -n "$GCC"; then
16018                           case $host_os in
16019                             linux*) haveit=yes;;
16020                           esac
16021                         fi
16022                       fi
16023                       if test -z "$haveit"; then
16024                         haveit=
16025                         for x in $LDFLAGS $LIBLZMA; do
16026
16027   acl_save_prefix="$prefix"
16028   prefix="$acl_final_prefix"
16029   acl_save_exec_prefix="$exec_prefix"
16030   exec_prefix="$acl_final_exec_prefix"
16031   eval x=\"$x\"
16032   exec_prefix="$acl_save_exec_prefix"
16033   prefix="$acl_save_prefix"
16034
16035                           if test "X$x" = "X-L$additional_libdir"; then
16036                             haveit=yes
16037                             break
16038                           fi
16039                         done
16040                         if test -z "$haveit"; then
16041                           if test -d "$additional_libdir"; then
16042                                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-L$additional_libdir"
16043                           fi
16044                         fi
16045                         haveit=
16046                         for x in $LDFLAGS $LTLIBLZMA; do
16047
16048   acl_save_prefix="$prefix"
16049   prefix="$acl_final_prefix"
16050   acl_save_exec_prefix="$exec_prefix"
16051   exec_prefix="$acl_final_exec_prefix"
16052   eval x=\"$x\"
16053   exec_prefix="$acl_save_exec_prefix"
16054   prefix="$acl_save_prefix"
16055
16056                           if test "X$x" = "X-L$additional_libdir"; then
16057                             haveit=yes
16058                             break
16059                           fi
16060                         done
16061                         if test -z "$haveit"; then
16062                           if test -d "$additional_libdir"; then
16063                                                         LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-L$additional_libdir"
16064                           fi
16065                         fi
16066                       fi
16067                     fi
16068                     ;;
16069                   -R*)
16070                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
16071                     if test "$enable_rpath" != no; then
16072                                                                   haveit=
16073                       for x in $rpathdirs; do
16074                         if test "X$x" = "X$dir"; then
16075                           haveit=yes
16076                           break
16077                         fi
16078                       done
16079                       if test -z "$haveit"; then
16080                         rpathdirs="$rpathdirs $dir"
16081                       fi
16082                                                                   haveit=
16083                       for x in $ltrpathdirs; do
16084                         if test "X$x" = "X$dir"; then
16085                           haveit=yes
16086                           break
16087                         fi
16088                       done
16089                       if test -z "$haveit"; then
16090                         ltrpathdirs="$ltrpathdirs $dir"
16091                       fi
16092                     fi
16093                     ;;
16094                   -l*)
16095                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
16096                     ;;
16097                   *.la)
16098                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
16099                     ;;
16100                   *)
16101                                         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$dep"
16102                     LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }$dep"
16103                     ;;
16104                 esac
16105               done
16106             fi
16107           else
16108                                                             LIBLZMA="${LIBLZMA}${LIBLZMA:+ }-l$name"
16109             LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-l$name"
16110           fi
16111         fi
16112       fi
16113     done
16114   done
16115   if test "X$rpathdirs" != "X"; then
16116     if test -n "$hardcode_libdir_separator"; then
16117                         alldirs=
16118       for found_dir in $rpathdirs; do
16119         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
16120       done
16121             acl_save_libdir="$libdir"
16122       libdir="$alldirs"
16123       eval flag=\"$hardcode_libdir_flag_spec\"
16124       libdir="$acl_save_libdir"
16125       LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
16126     else
16127             for found_dir in $rpathdirs; do
16128         acl_save_libdir="$libdir"
16129         libdir="$found_dir"
16130         eval flag=\"$hardcode_libdir_flag_spec\"
16131         libdir="$acl_save_libdir"
16132         LIBLZMA="${LIBLZMA}${LIBLZMA:+ }$flag"
16133       done
16134     fi
16135   fi
16136   if test "X$ltrpathdirs" != "X"; then
16137             for found_dir in $ltrpathdirs; do
16138       LTLIBLZMA="${LTLIBLZMA}${LTLIBLZMA:+ }-R$found_dir"
16139     done
16140   fi
16141
16142
16143         ac_save_CPPFLAGS="$CPPFLAGS"
16144
16145   for element in $INCLZMA; do
16146     haveit=
16147     for x in $CPPFLAGS; do
16148
16149   acl_save_prefix="$prefix"
16150   prefix="$acl_final_prefix"
16151   acl_save_exec_prefix="$exec_prefix"
16152   exec_prefix="$acl_final_exec_prefix"
16153   eval x=\"$x\"
16154   exec_prefix="$acl_save_exec_prefix"
16155   prefix="$acl_save_prefix"
16156
16157       if test "X$x" = "X$element"; then
16158         haveit=yes
16159         break
16160       fi
16161     done
16162     if test -z "$haveit"; then
16163       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
16164     fi
16165   done
16166
16167
16168   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liblzma" >&5
16169 $as_echo_n "checking for liblzma... " >&6; }
16170 if ${ac_cv_liblzma+:} false; then :
16171   $as_echo_n "(cached) " >&6
16172 else
16173
16174     ac_save_LIBS="$LIBS"
16175     LIBS="$LIBS $LIBLZMA"
16176     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16177 /* end confdefs.h.  */
16178 #include "lzma.h"
16179 int
16180 main ()
16181 {
16182 lzma_index_iter iter;
16183                            lzma_index_iter_init (&iter, 0);
16184                            lzma_mf_is_supported (LZMA_MF_HC3);
16185   ;
16186   return 0;
16187 }
16188 _ACEOF
16189 if ac_fn_c_try_link "$LINENO"; then :
16190   ac_cv_liblzma=yes
16191 else
16192   ac_cv_liblzma=no
16193 fi
16194 rm -f core conftest.err conftest.$ac_objext \
16195     conftest$ac_exeext conftest.$ac_ext
16196     LIBS="$ac_save_LIBS"
16197
16198 fi
16199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_liblzma" >&5
16200 $as_echo "$ac_cv_liblzma" >&6; }
16201   if test "$ac_cv_liblzma" = yes; then
16202     HAVE_LIBLZMA=yes
16203
16204 $as_echo "#define HAVE_LIBLZMA 1" >>confdefs.h
16205
16206     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with liblzma" >&5
16207 $as_echo_n "checking how to link with liblzma... " >&6; }
16208     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBLZMA" >&5
16209 $as_echo "$LIBLZMA" >&6; }
16210   else
16211     HAVE_LIBLZMA=no
16212             CPPFLAGS="$ac_save_CPPFLAGS"
16213     LIBLZMA=
16214     LTLIBLZMA=
16215   fi
16216
16217
16218
16219
16220
16221
16222     if test "$HAVE_LIBLZMA" != yes; then
16223       if test "$with_lzma" = yes; then
16224         as_fn_error $? "missing liblzma for --with-lzma" "$LINENO" 5
16225       fi
16226     fi
16227   fi
16228 fi
16229
16230 LIBGUI="../libgui/src/libgui.a"
16231 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
16232
16233
16234
16235 WIN32LDAPP=
16236
16237
16238
16239 case "${host}" in
16240 *-*-cygwin* | *-*-mingw* )
16241     configdir="win"
16242     ;;
16243 *)
16244     configdir="unix"
16245     ;;
16246 esac
16247
16248 GDBTKLIBS=
16249 if test "${enable_gdbtk}" = "yes"; then
16250
16251     # Gdbtk must have an absolute path to srcdir in order to run
16252     # properly when not installed.
16253     here=`pwd`
16254     cd ${srcdir}
16255     GDBTK_SRC_DIR=`pwd`
16256     cd $here
16257
16258
16259     #
16260     # Ok, lets find the tcl configuration
16261     # First, look for one uninstalled.
16262     # the alternative search directory is invoked by --with-tcl
16263     #
16264
16265     if test x"${no_tcl}" = x ; then
16266         # we reset no_tcl in case something fails here
16267         no_tcl=true
16268
16269 # Check whether --with-tcl was given.
16270 if test "${with_tcl+set}" = set; then :
16271   withval=$with_tcl; with_tclconfig=${withval}
16272 fi
16273
16274         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5
16275 $as_echo_n "checking for Tcl configuration... " >&6; }
16276         if ${ac_cv_c_tclconfig+:} false; then :
16277   $as_echo_n "(cached) " >&6
16278 else
16279
16280
16281             # First check to see if --with-tcl was specified.
16282             case "${host}" in
16283                 *-*-cygwin*) platDir="win" ;;
16284                 *) platDir="unix" ;;
16285             esac
16286             if test x"${with_tclconfig}" != x ; then
16287                 if test -f "${with_tclconfig}/tclConfig.sh" ; then
16288                     ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
16289                 else
16290                     as_fn_error $? "${with_tclconfig} directory doesn't contain tclConfig.sh" "$LINENO" 5
16291                 fi
16292             fi
16293
16294             # then check for a private Tcl installation
16295             if test x"${ac_cv_c_tclconfig}" = x ; then
16296                 for i in \
16297                         ../tcl \
16298                         `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16299                         `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
16300                         `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
16301                         ../../tcl \
16302                         `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16303                         `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
16304                         `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
16305                         ../../../tcl \
16306                         `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16307                         `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
16308                         `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
16309                     if test -f "$i/$platDir/tclConfig.sh" ; then
16310                         ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
16311                         break
16312                     fi
16313                 done
16314             fi
16315
16316             # on Darwin, check in Framework installation locations
16317             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
16318                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
16319                         `ls -d /Library/Frameworks 2>/dev/null` \
16320                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
16321                         `ls -d /System/Library/Frameworks 2>/dev/null` \
16322                         ; do
16323                     if test -f "$i/Tcl.framework/tclConfig.sh" ; then
16324                         ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
16325                         break
16326                     fi
16327                 done
16328             fi
16329
16330             # check in a few common install locations
16331             if test x"${ac_cv_c_tclconfig}" = x ; then
16332                 for i in `ls -d ${libdir} 2>/dev/null` \
16333                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
16334                         `ls -d ${prefix}/lib 2>/dev/null` \
16335                         `ls -d /usr/local/lib 2>/dev/null` \
16336                         `ls -d /usr/contrib/lib 2>/dev/null` \
16337                         `ls -d /usr/lib 2>/dev/null` \
16338                         ; do
16339                     if test -f "$i/tclConfig.sh" ; then
16340                         ac_cv_c_tclconfig=`(cd $i; pwd)`
16341                         break
16342                     fi
16343                 done
16344             fi
16345
16346             # check in a few other private locations
16347             if test x"${ac_cv_c_tclconfig}" = x ; then
16348                 for i in \
16349                         ${srcdir}/../tcl \
16350                         `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
16351                         `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
16352                         `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
16353                     if test -f "$i/$platDir/tclConfig.sh" ; then
16354                     ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
16355                     break
16356                 fi
16357                 done
16358             fi
16359
16360 fi
16361
16362
16363         if test x"${ac_cv_c_tclconfig}" = x ; then
16364             TCL_BIN_DIR="# no Tcl configs found"
16365             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tcl configuration definitions" >&5
16366 $as_echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
16367         else
16368             no_tcl=
16369             TCL_BIN_DIR=${ac_cv_c_tclconfig}
16370             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
16371 $as_echo "found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
16372         fi
16373     fi
16374
16375
16376     # If $no_tk is nonempty, then we can't do Tk, and there is no
16377     # point to doing Tcl.
16378
16379     #
16380     # Ok, lets find the tk configuration
16381     # First, look for one uninstalled.
16382     # the alternative search directory is invoked by --with-tk
16383     #
16384
16385     if test x"${no_tk}" = x ; then
16386         # we reset no_tk in case something fails here
16387         no_tk=true
16388
16389 # Check whether --with-tk was given.
16390 if test "${with_tk+set}" = set; then :
16391   withval=$with_tk; with_tkconfig=${withval}
16392 fi
16393
16394         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk configuration" >&5
16395 $as_echo_n "checking for Tk configuration... " >&6; }
16396         if ${ac_cv_c_tkconfig+:} false; then :
16397   $as_echo_n "(cached) " >&6
16398 else
16399
16400
16401             # First check to see if --with-tkconfig was specified.
16402             if test x"${with_tkconfig}" != x ; then
16403                 if test -f "${with_tkconfig}/tkConfig.sh" ; then
16404                     ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
16405                 else
16406                     as_fn_error $? "${with_tkconfig} directory doesn't contain tkConfig.sh" "$LINENO" 5
16407                 fi
16408             fi
16409
16410             # then check for a private Tk library
16411             case "${host}" in
16412                 *-*-cygwin*) platDir="win" ;;
16413                 *) platDir="unix" ;;
16414             esac
16415             if test x"${ac_cv_c_tkconfig}" = x ; then
16416                 for i in \
16417                         ../tk \
16418                         `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16419                         `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
16420                         `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
16421                         ../../tk \
16422                         `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16423                         `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
16424                         `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
16425                         ../../../tk \
16426                         `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16427                         `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
16428                         `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
16429                     if test -f "$i/$platDir/tkConfig.sh" ; then
16430                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
16431                         break
16432                     fi
16433                 done
16434             fi
16435
16436             # on Darwin, check in Framework installation locations
16437             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
16438                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
16439                         `ls -d /Library/Frameworks 2>/dev/null` \
16440                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
16441                         `ls -d /System/Library/Frameworks 2>/dev/null` \
16442                         ; do
16443                     if test -f "$i/Tk.framework/tkConfig.sh" ; then
16444                         ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
16445                         break
16446                     fi
16447                 done
16448             fi
16449
16450             # check in a few common install locations
16451             if test x"${ac_cv_c_tkconfig}" = x ; then
16452                 for i in `ls -d ${libdir} 2>/dev/null` \
16453                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
16454                         `ls -d ${prefix}/lib 2>/dev/null` \
16455                         `ls -d /usr/local/lib 2>/dev/null` \
16456                         `ls -d /usr/contrib/lib 2>/dev/null` \
16457                         `ls -d /usr/lib 2>/dev/null` \
16458                         ; do
16459                     if test -f "$i/tkConfig.sh" ; then
16460                         ac_cv_c_tkconfig=`(cd $i; pwd)`
16461                         break
16462                     fi
16463                 done
16464             fi
16465             # check in a few other private locations
16466             if test x"${ac_cv_c_tkconfig}" = x ; then
16467                 for i in \
16468                         ${srcdir}/../tk \
16469                         `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
16470                         `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
16471                         `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
16472                     if test -f "$i/$platDir/tkConfig.sh" ; then
16473                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
16474                         break
16475                     fi
16476                 done
16477             fi
16478
16479 fi
16480
16481
16482         if test x"${ac_cv_c_tkconfig}" = x ; then
16483             TK_BIN_DIR="# no Tk configs found"
16484             { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find Tk configuration definitions" >&5
16485 $as_echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
16486         else
16487             no_tk=
16488             TK_BIN_DIR=${ac_cv_c_tkconfig}
16489             { $as_echo "$as_me:${as_lineno-$LINENO}: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
16490 $as_echo "found ${TK_BIN_DIR}/tkConfig.sh" >&6; }
16491         fi
16492     fi
16493
16494
16495     if test -z "${no_tcl}" -a -z "${no_tk}"; then
16496
16497     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
16498 $as_echo_n "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... " >&6; }
16499
16500     if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
16501         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
16502 $as_echo "loading" >&6; }
16503         . ${TCL_BIN_DIR}/tclConfig.sh
16504     else
16505         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
16506 $as_echo "could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
16507     fi
16508
16509     # eval is required to do the TCL_DBGX substitution
16510     eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
16511     eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
16512
16513     # If the TCL_BIN_DIR is the build directory (not the install directory),
16514     # then set the common variable name to the value of the build variables.
16515     # For example, the variable TCL_LIB_SPEC will be set to the value
16516     # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
16517     # instead of TCL_BUILD_LIB_SPEC since it will work with both an
16518     # installed and uninstalled version of Tcl.
16519     if test -f "${TCL_BIN_DIR}/Makefile" ; then
16520         TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
16521         TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
16522         TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
16523     elif test "`uname -s`" = "Darwin"; then
16524         # If Tcl was built as a framework, attempt to use the libraries
16525         # from the framework at the given location so that linking works
16526         # against Tcl.framework installed in an arbitrary location.
16527         case ${TCL_DEFS} in
16528             *TCL_FRAMEWORK*)
16529                 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
16530                     for i in "`cd ${TCL_BIN_DIR}; pwd`" \
16531                              "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
16532                         if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
16533                             TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
16534                             break
16535                         fi
16536                     done
16537                 fi
16538                 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
16539                     TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
16540                     TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
16541                 fi
16542                 ;;
16543         esac
16544     fi
16545
16546     # eval is required to do the TCL_DBGX substitution
16547     eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
16548     eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
16549     eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
16550     eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
16551
16552
16553
16554
16555
16556
16557
16558
16559
16560
16561
16562
16563
16564
16565
16566         # Check for in-tree tcl
16567         here=`pwd`
16568         cd ${srcdir}/..
16569         topdir=`pwd`
16570         cd ${here}
16571
16572         intree="no"
16573         if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
16574           intree="yes"
16575         fi
16576
16577         # Find Tcl private headers
16578         if test x"${intree}" = xno; then
16579
16580   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tcl private headers" >&5
16581 $as_echo_n "checking for Tcl private headers... " >&6; }
16582   private_dir=""
16583   dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
16584   if test -f ${dir}/tclInt.h ; then
16585     private_dir=${dir}
16586   fi
16587
16588   if test x"${private_dir}" = x; then
16589     as_fn_error $? "could not find private Tcl headers" "$LINENO" 5
16590   else
16591     TCL_PRIVATE_INCLUDE="-I${private_dir}"
16592     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
16593 $as_echo "${private_dir}" >&6; }
16594   fi
16595
16596           TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
16597           TCL_LIBRARY="${TCL_LIB_SPEC}"
16598           TCL_DEPS=""
16599         else
16600           # If building tcl in the same src tree, private headers
16601           # are not needed, but we need to be sure to use the right
16602           # headers library
16603           TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
16604           TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
16605           TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
16606         fi
16607
16608
16609
16610
16611
16612     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
16613 $as_echo_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... " >&6; }
16614
16615     if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
16616         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loading" >&5
16617 $as_echo "loading" >&6; }
16618         . ${TK_BIN_DIR}/tkConfig.sh
16619     else
16620         { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
16621 $as_echo "could not find ${TK_BIN_DIR}/tkConfig.sh" >&6; }
16622     fi
16623
16624     # eval is required to do the TK_DBGX substitution
16625     eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
16626     eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
16627
16628     # If the TK_BIN_DIR is the build directory (not the install directory),
16629     # then set the common variable name to the value of the build variables.
16630     # For example, the variable TK_LIB_SPEC will be set to the value
16631     # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
16632     # instead of TK_BUILD_LIB_SPEC since it will work with both an
16633     # installed and uninstalled version of Tcl.
16634     if test -f "${TK_BIN_DIR}/Makefile" ; then
16635         TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
16636         TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
16637         TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
16638     elif test "`uname -s`" = "Darwin"; then
16639         # If Tk was built as a framework, attempt to use the libraries
16640         # from the framework at the given location so that linking works
16641         # against Tk.framework installed in an arbitrary location.
16642         case ${TK_DEFS} in
16643             *TK_FRAMEWORK*)
16644                 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
16645                     for i in "`cd ${TK_BIN_DIR}; pwd`" \
16646                              "`cd ${TK_BIN_DIR}/../..; pwd`"; do
16647                         if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
16648                             TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
16649                             break
16650                         fi
16651                     done
16652                 fi
16653                 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
16654                     TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
16655                     TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
16656                 fi
16657                 ;;
16658         esac
16659     fi
16660
16661     # eval is required to do the TK_DBGX substitution
16662     eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
16663     eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
16664     eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
16665     eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
16666
16667
16668
16669
16670
16671
16672
16673
16674
16675
16676
16677
16678
16679
16680         # Check for in-tree Tk
16681         intree="no"
16682         if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
16683           intree="yes"
16684         fi
16685
16686         # Find Tk private headers
16687         if test x"${intree}" = xno; then
16688
16689   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Tk private headers" >&5
16690 $as_echo_n "checking for Tk private headers... " >&6; }
16691   private_dir=""
16692   dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
16693   if test -f ${dir}/tkInt.h; then
16694     private_dir=${dir}
16695   fi
16696
16697   if test x"${private_dir}" = x; then
16698     as_fn_error $? "could not find Tk private headers" "$LINENO" 5
16699   else
16700     TK_PRIVATE_INCLUDE="-I${private_dir}"
16701     { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${private_dir}" >&5
16702 $as_echo "${private_dir}" >&6; }
16703   fi
16704
16705           TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
16706           TK_LIBRARY=${TK_LIB_SPEC}
16707           TK_DEPS=""
16708         else
16709           TK_INCLUDE="-I${TK_SRC_DIR}/generic"
16710           TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
16711           TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
16712         fi
16713
16714
16715
16716
16717
16718         ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
16719
16720         # Include some libraries that Tcl and Tk want.
16721         TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
16722         # Yes, the ordering seems wrong here.  But it isn't.
16723         # TK_LIBS is the list of libraries that need to be linked
16724         # after Tcl/Tk.  Note that this isn't put into LIBS.  If it
16725         # were in LIBS then any link tests after this point would
16726         # try to include things like `$(LIBGUI)', which wouldn't work.
16727         GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
16728
16729         CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
16730         CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
16731         CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
16732         CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
16733         CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
16734         CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
16735         CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
16736
16737         if test x$gdb_cv_os_cygwin = xyes; then
16738           WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
16739           WIN32LDAPP="-Wl,--subsystem,console"
16740           CONFIG_OBS="${CONFIG_OBS} gdbres.o"
16741         fi
16742
16743         subdirs="$subdirs gdbtk"
16744
16745     fi
16746 fi
16747
16748
16749
16750
16751
16752
16753
16754
16755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
16756 $as_echo_n "checking for X... " >&6; }
16757
16758
16759 # Check whether --with-x was given.
16760 if test "${with_x+set}" = set; then :
16761   withval=$with_x;
16762 fi
16763
16764 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
16765 if test "x$with_x" = xno; then
16766   # The user explicitly disabled X.
16767   have_x=disabled
16768 else
16769   case $x_includes,$x_libraries in #(
16770     *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
16771     *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
16772   $as_echo_n "(cached) " >&6
16773 else
16774   # One or both of the vars are not set, and there is no cached value.
16775 ac_x_includes=no ac_x_libraries=no
16776 rm -f -r conftest.dir
16777 if mkdir conftest.dir; then
16778   cd conftest.dir
16779   cat >Imakefile <<'_ACEOF'
16780 incroot:
16781         @echo incroot='${INCROOT}'
16782 usrlibdir:
16783         @echo usrlibdir='${USRLIBDIR}'
16784 libdir:
16785         @echo libdir='${LIBDIR}'
16786 _ACEOF
16787   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
16788     # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
16789     for ac_var in incroot usrlibdir libdir; do
16790       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
16791     done
16792     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
16793     for ac_extension in a so sl dylib la dll; do
16794       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
16795          test -f "$ac_im_libdir/libX11.$ac_extension"; then
16796         ac_im_usrlibdir=$ac_im_libdir; break
16797       fi
16798     done
16799     # Screen out bogus values from the imake configuration.  They are
16800     # bogus both because they are the default anyway, and because
16801     # using them would break gcc on systems where it needs fixed includes.
16802     case $ac_im_incroot in
16803         /usr/include) ac_x_includes= ;;
16804         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
16805     esac
16806     case $ac_im_usrlibdir in
16807         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
16808         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
16809     esac
16810   fi
16811   cd ..
16812   rm -f -r conftest.dir
16813 fi
16814
16815 # Standard set of common directories for X headers.
16816 # Check X11 before X11Rn because it is often a symlink to the current release.
16817 ac_x_header_dirs='
16818 /usr/X11/include
16819 /usr/X11R7/include
16820 /usr/X11R6/include
16821 /usr/X11R5/include
16822 /usr/X11R4/include
16823
16824 /usr/include/X11
16825 /usr/include/X11R7
16826 /usr/include/X11R6
16827 /usr/include/X11R5
16828 /usr/include/X11R4
16829
16830 /usr/local/X11/include
16831 /usr/local/X11R7/include
16832 /usr/local/X11R6/include
16833 /usr/local/X11R5/include
16834 /usr/local/X11R4/include
16835
16836 /usr/local/include/X11
16837 /usr/local/include/X11R7
16838 /usr/local/include/X11R6
16839 /usr/local/include/X11R5
16840 /usr/local/include/X11R4
16841
16842 /usr/X386/include
16843 /usr/x386/include
16844 /usr/XFree86/include/X11
16845
16846 /usr/include
16847 /usr/local/include
16848 /usr/unsupported/include
16849 /usr/athena/include
16850 /usr/local/x11r5/include
16851 /usr/lpp/Xamples/include
16852
16853 /usr/openwin/include
16854 /usr/openwin/share/include'
16855
16856 if test "$ac_x_includes" = no; then
16857   # Guess where to find include files, by looking for Xlib.h.
16858   # First, try using that file with no special directory specified.
16859   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16860 /* end confdefs.h.  */
16861 #include <X11/Xlib.h>
16862 _ACEOF
16863 if ac_fn_c_try_cpp "$LINENO"; then :
16864   # We can compile using X headers with no special include directory.
16865 ac_x_includes=
16866 else
16867   for ac_dir in $ac_x_header_dirs; do
16868   if test -r "$ac_dir/X11/Xlib.h"; then
16869     ac_x_includes=$ac_dir
16870     break
16871   fi
16872 done
16873 fi
16874 rm -f conftest.err conftest.i conftest.$ac_ext
16875 fi # $ac_x_includes = no
16876
16877 if test "$ac_x_libraries" = no; then
16878   # Check for the libraries.
16879   # See if we find them without any special options.
16880   # Don't add to $LIBS permanently.
16881   ac_save_LIBS=$LIBS
16882   LIBS="-lX11 $LIBS"
16883   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16884 /* end confdefs.h.  */
16885 #include <X11/Xlib.h>
16886 int
16887 main ()
16888 {
16889 XrmInitialize ()
16890   ;
16891   return 0;
16892 }
16893 _ACEOF
16894 if ac_fn_c_try_link "$LINENO"; then :
16895   LIBS=$ac_save_LIBS
16896 # We can link X programs with no special library path.
16897 ac_x_libraries=
16898 else
16899   LIBS=$ac_save_LIBS
16900 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
16901 do
16902   # Don't even attempt the hair of trying to link an X program!
16903   for ac_extension in a so sl dylib la dll; do
16904     if test -r "$ac_dir/libX11.$ac_extension"; then
16905       ac_x_libraries=$ac_dir
16906       break 2
16907     fi
16908   done
16909 done
16910 fi
16911 rm -f core conftest.err conftest.$ac_objext \
16912     conftest$ac_exeext conftest.$ac_ext
16913 fi # $ac_x_libraries = no
16914
16915 case $ac_x_includes,$ac_x_libraries in #(
16916   no,* | *,no | *\'*)
16917     # Didn't find X, or a directory has "'" in its name.
16918     ac_cv_have_x="have_x=no";; #(
16919   *)
16920     # Record where we found X for the cache.
16921     ac_cv_have_x="have_x=yes\
16922         ac_x_includes='$ac_x_includes'\
16923         ac_x_libraries='$ac_x_libraries'"
16924 esac
16925 fi
16926 ;; #(
16927     *) have_x=yes;;
16928   esac
16929   eval "$ac_cv_have_x"
16930 fi # $with_x != no
16931
16932 if test "$have_x" != yes; then
16933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
16934 $as_echo "$have_x" >&6; }
16935   no_x=yes
16936 else
16937   # If each of the values was on the command line, it overrides each guess.
16938   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
16939   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
16940   # Update the cache value to reflect the command line values.
16941   ac_cv_have_x="have_x=yes\
16942         ac_x_includes='$x_includes'\
16943         ac_x_libraries='$x_libraries'"
16944   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
16945 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
16946 fi
16947
16948
16949 # Unlike the sim directory, whether a simulator is linked is controlled by
16950 # presence of a gdb_sim definition in the target configure.tgt entry.
16951 # This code just checks for a few cases where we'd like to ignore those
16952 # definitions, even when they're present in the '.mt' file.  These cases
16953 # are when --disable-sim is specified, or if the simulator directory is
16954 # not part of the source tree.
16955 #
16956 # Check whether --enable-sim was given.
16957 if test "${enable_sim+set}" = set; then :
16958   enableval=$enable_sim; echo "enable_sim = $enable_sim";
16959  echo "enableval = ${enableval}";
16960  case "${enableval}" in
16961   yes) ignore_sim=false ;;
16962   no)  ignore_sim=true ;;
16963   *)   ignore_sim=false ;;
16964  esac
16965 else
16966   ignore_sim=false
16967 fi
16968
16969
16970 if test ! -d "${srcdir}/../sim"; then
16971   ignore_sim=true
16972 fi
16973
16974 SIM=
16975 SIM_OBS=
16976 if test "${ignore_sim}" = "false"; then
16977   if test x"${gdb_sim}" != x ; then
16978     SIM="${gdb_sim}"
16979     SIM_OBS="remote-sim.o"
16980
16981 $as_echo "#define WITH_SIM 1" >>confdefs.h
16982
16983
16984     # Some tdep code should only be compiled in when the ppc sim is
16985     # built.  PR sim/13418.
16986     case $target in
16987       powerpc*-*-*)
16988
16989 $as_echo "#define WITH_PPC_SIM 1" >>confdefs.h
16990
16991         ;;
16992     esac
16993   fi
16994 fi
16995
16996
16997
16998
16999
17000
17001
17002
17003
17004
17005
17006
17007
17008
17009 # List of host floatformats.
17010
17011 cat >>confdefs.h <<_ACEOF
17012 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
17013 _ACEOF
17014
17015
17016 cat >>confdefs.h <<_ACEOF
17017 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
17018 _ACEOF
17019
17020
17021 cat >>confdefs.h <<_ACEOF
17022 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
17023 _ACEOF
17024
17025
17026 # target_subdir is used by the testsuite to find the target libraries.
17027 target_subdir=
17028 if test "${host}" != "${target}"; then
17029     target_subdir="${target_alias}/"
17030 fi
17031
17032
17033 # Import nat definitions.
17034 nat_makefile_frag=/dev/null
17035 if test "${gdb_native}" = "yes"; then
17036   . ${srcdir}/configure.nat
17037   nativefile=$NAT_FILE
17038 fi
17039
17040
17041
17042
17043
17044
17045
17046
17047
17048
17049
17050 if test x"${gdb_osabi}" != x ; then
17051
17052 cat >>confdefs.h <<_ACEOF
17053 #define GDB_OSABI_DEFAULT $gdb_osabi
17054 _ACEOF
17055
17056 fi
17057
17058 # Check whether --enable-gdbserver was given.
17059 if test "${enable_gdbserver+set}" = set; then :
17060   enableval=$enable_gdbserver; case "${enableval}" in
17061   yes| no|auto) ;;
17062   *) as_fn_error $? "bad value ${enableval} for --enable-gdbserver option" "$LINENO" 5 ;;
17063 esac
17064 else
17065   enable_gdbserver=auto
17066 fi
17067
17068
17069 # We only build gdbserver automatically in a native configuration, and
17070 # only if the user did not explicitly disable its build.
17071 if test "$gdb_native" = "yes" -a "$enable_gdbserver" != "no"; then
17072   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gdbserver is supported on this host" >&5
17073 $as_echo_n "checking whether gdbserver is supported on this host... " >&6; }
17074   if test "x$build_gdbserver" = xyes; then
17075     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17076 $as_echo "yes" >&6; }
17077     subdirs="$subdirs gdbserver"
17078
17079     gdbserver_build_enabled=yes
17080   else
17081     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17082 $as_echo "no" >&6; }
17083   fi
17084 fi
17085
17086 # If the user explicitly request the gdbserver to be built, verify that
17087 # we were in fact able to enable it.
17088 if test "$enable_gdbserver" = "yes" -a "$gdbserver_build_enabled" != "yes"; then
17089   as_fn_error $? "Automatic gdbserver build is not supported for this configuration" "$LINENO" 5
17090 fi
17091
17092 # Check for babeltrace and babeltrace-ctf
17093
17094 # Check whether --with-babeltrace was given.
17095 if test "${with_babeltrace+set}" = set; then :
17096   withval=$with_babeltrace;
17097 else
17098   with_babeltrace=auto
17099 fi
17100
17101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use babeltrace" >&5
17102 $as_echo_n "checking whether to use babeltrace... " >&6; }
17103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_babeltrace" >&5
17104 $as_echo "$with_babeltrace" >&6; }
17105
17106 if test "x$with_babeltrace" = "xno"; then
17107   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&5
17108 $as_echo "$as_me: WARNING: babletrace support disabled; GDB is unable to read CTF data." >&2;}
17109 else
17110   # Append -Werror to CFLAGS so that configure can catch the warning
17111   # "assignment from incompatible pointer type", which is related to
17112   # the babeltrace change from 1.0.3 to 1.1.0.  Babeltrace 1.1.0 works
17113   # in GDB, while babeltrace 1.0.3 is broken.
17114   # AC_LIB_HAVE_LINKFLAGS may modify CPPFLAGS in it, so it should be
17115   # safe to save and restore CFLAGS here.
17116   saved_CFLAGS=$CFLAGS
17117   CFLAGS="$CFLAGS -Werror"
17118
17119
17120
17121
17122
17123
17124
17125
17126     use_additional=yes
17127
17128   acl_save_prefix="$prefix"
17129   prefix="$acl_final_prefix"
17130   acl_save_exec_prefix="$exec_prefix"
17131   exec_prefix="$acl_final_exec_prefix"
17132
17133     eval additional_includedir=\"$includedir\"
17134     eval additional_libdir=\"$libdir\"
17135
17136   exec_prefix="$acl_save_exec_prefix"
17137   prefix="$acl_save_prefix"
17138
17139
17140 # Check whether --with-libbabeltrace-prefix was given.
17141 if test "${with_libbabeltrace_prefix+set}" = set; then :
17142   withval=$with_libbabeltrace_prefix;
17143     if test "X$withval" = "Xno"; then
17144       use_additional=no
17145     else
17146       if test "X$withval" = "X"; then
17147
17148   acl_save_prefix="$prefix"
17149   prefix="$acl_final_prefix"
17150   acl_save_exec_prefix="$exec_prefix"
17151   exec_prefix="$acl_final_exec_prefix"
17152
17153           eval additional_includedir=\"$includedir\"
17154           eval additional_libdir=\"$libdir\"
17155
17156   exec_prefix="$acl_save_exec_prefix"
17157   prefix="$acl_save_prefix"
17158
17159       else
17160         additional_includedir="$withval/include"
17161         additional_libdir="$withval/lib"
17162       fi
17163     fi
17164
17165 fi
17166
17167       LIBBABELTRACE=
17168   LTLIBBABELTRACE=
17169   INCBABELTRACE=
17170   rpathdirs=
17171   ltrpathdirs=
17172   names_already_handled=
17173   names_next_round='babeltrace babeltrace-ctf'
17174   while test -n "$names_next_round"; do
17175     names_this_round="$names_next_round"
17176     names_next_round=
17177     for name in $names_this_round; do
17178       already_handled=
17179       for n in $names_already_handled; do
17180         if test "$n" = "$name"; then
17181           already_handled=yes
17182           break
17183         fi
17184       done
17185       if test -z "$already_handled"; then
17186         names_already_handled="$names_already_handled $name"
17187                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
17188         eval value=\"\$HAVE_LIB$uppername\"
17189         if test -n "$value"; then
17190           if test "$value" = yes; then
17191             eval value=\"\$LIB$uppername\"
17192             test -z "$value" || LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$value"
17193             eval value=\"\$LTLIB$uppername\"
17194             test -z "$value" || LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$value"
17195           else
17196                                     :
17197           fi
17198         else
17199                               found_dir=
17200           found_la=
17201           found_so=
17202           found_a=
17203           if test $use_additional = yes; then
17204             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
17205               found_dir="$additional_libdir"
17206               found_so="$additional_libdir/lib$name.$shlibext"
17207               if test -f "$additional_libdir/lib$name.la"; then
17208                 found_la="$additional_libdir/lib$name.la"
17209               fi
17210             else
17211               if test -f "$additional_libdir/lib$name.$libext"; then
17212                 found_dir="$additional_libdir"
17213                 found_a="$additional_libdir/lib$name.$libext"
17214                 if test -f "$additional_libdir/lib$name.la"; then
17215                   found_la="$additional_libdir/lib$name.la"
17216                 fi
17217               fi
17218             fi
17219           fi
17220           if test "X$found_dir" = "X"; then
17221             for x in $LDFLAGS $LTLIBBABELTRACE; do
17222
17223   acl_save_prefix="$prefix"
17224   prefix="$acl_final_prefix"
17225   acl_save_exec_prefix="$exec_prefix"
17226   exec_prefix="$acl_final_exec_prefix"
17227   eval x=\"$x\"
17228   exec_prefix="$acl_save_exec_prefix"
17229   prefix="$acl_save_prefix"
17230
17231               case "$x" in
17232                 -L*)
17233                   dir=`echo "X$x" | sed -e 's/^X-L//'`
17234                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
17235                     found_dir="$dir"
17236                     found_so="$dir/lib$name.$shlibext"
17237                     if test -f "$dir/lib$name.la"; then
17238                       found_la="$dir/lib$name.la"
17239                     fi
17240                   else
17241                     if test -f "$dir/lib$name.$libext"; then
17242                       found_dir="$dir"
17243                       found_a="$dir/lib$name.$libext"
17244                       if test -f "$dir/lib$name.la"; then
17245                         found_la="$dir/lib$name.la"
17246                       fi
17247                     fi
17248                   fi
17249                   ;;
17250               esac
17251               if test "X$found_dir" != "X"; then
17252                 break
17253               fi
17254             done
17255           fi
17256           if test "X$found_dir" != "X"; then
17257                         LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$found_dir -l$name"
17258             if test "X$found_so" != "X"; then
17259                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
17260                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17261               else
17262                                                                                 haveit=
17263                 for x in $ltrpathdirs; do
17264                   if test "X$x" = "X$found_dir"; then
17265                     haveit=yes
17266                     break
17267                   fi
17268                 done
17269                 if test -z "$haveit"; then
17270                   ltrpathdirs="$ltrpathdirs $found_dir"
17271                 fi
17272                                 if test "$hardcode_direct" = yes; then
17273                                                       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17274                 else
17275                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
17276                                                             LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17277                                                             haveit=
17278                     for x in $rpathdirs; do
17279                       if test "X$x" = "X$found_dir"; then
17280                         haveit=yes
17281                         break
17282                       fi
17283                     done
17284                     if test -z "$haveit"; then
17285                       rpathdirs="$rpathdirs $found_dir"
17286                     fi
17287                   else
17288                                                                                 haveit=
17289                     for x in $LDFLAGS $LIBBABELTRACE; do
17290
17291   acl_save_prefix="$prefix"
17292   prefix="$acl_final_prefix"
17293   acl_save_exec_prefix="$exec_prefix"
17294   exec_prefix="$acl_final_exec_prefix"
17295   eval x=\"$x\"
17296   exec_prefix="$acl_save_exec_prefix"
17297   prefix="$acl_save_prefix"
17298
17299                       if test "X$x" = "X-L$found_dir"; then
17300                         haveit=yes
17301                         break
17302                       fi
17303                     done
17304                     if test -z "$haveit"; then
17305                       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir"
17306                     fi
17307                     if test "$hardcode_minus_L" != no; then
17308                                                                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_so"
17309                     else
17310                                                                                                                                                                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
17311                     fi
17312                   fi
17313                 fi
17314               fi
17315             else
17316               if test "X$found_a" != "X"; then
17317                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$found_a"
17318               else
17319                                                 LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$found_dir -l$name"
17320               fi
17321             fi
17322                         additional_includedir=
17323             case "$found_dir" in
17324               */lib | */lib/)
17325                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
17326                 additional_includedir="$basedir/include"
17327                 ;;
17328             esac
17329             if test "X$additional_includedir" != "X"; then
17330                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
17331                 haveit=
17332                 if test "X$additional_includedir" = "X/usr/local/include"; then
17333                   if test -n "$GCC"; then
17334                     case $host_os in
17335                       linux*) haveit=yes;;
17336                     esac
17337                   fi
17338                 fi
17339                 if test -z "$haveit"; then
17340                   for x in $CPPFLAGS $INCBABELTRACE; do
17341
17342   acl_save_prefix="$prefix"
17343   prefix="$acl_final_prefix"
17344   acl_save_exec_prefix="$exec_prefix"
17345   exec_prefix="$acl_final_exec_prefix"
17346   eval x=\"$x\"
17347   exec_prefix="$acl_save_exec_prefix"
17348   prefix="$acl_save_prefix"
17349
17350                     if test "X$x" = "X-I$additional_includedir"; then
17351                       haveit=yes
17352                       break
17353                     fi
17354                   done
17355                   if test -z "$haveit"; then
17356                     if test -d "$additional_includedir"; then
17357                                             INCBABELTRACE="${INCBABELTRACE}${INCBABELTRACE:+ }-I$additional_includedir"
17358                     fi
17359                   fi
17360                 fi
17361               fi
17362             fi
17363                         if test -n "$found_la"; then
17364                                                         save_libdir="$libdir"
17365               case "$found_la" in
17366                 */* | *\\*) . "$found_la" ;;
17367                 *) . "./$found_la" ;;
17368               esac
17369               libdir="$save_libdir"
17370                             for dep in $dependency_libs; do
17371                 case "$dep" in
17372                   -L*)
17373                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
17374                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
17375                       haveit=
17376                       if test "X$additional_libdir" = "X/usr/local/lib"; then
17377                         if test -n "$GCC"; then
17378                           case $host_os in
17379                             linux*) haveit=yes;;
17380                           esac
17381                         fi
17382                       fi
17383                       if test -z "$haveit"; then
17384                         haveit=
17385                         for x in $LDFLAGS $LIBBABELTRACE; do
17386
17387   acl_save_prefix="$prefix"
17388   prefix="$acl_final_prefix"
17389   acl_save_exec_prefix="$exec_prefix"
17390   exec_prefix="$acl_final_exec_prefix"
17391   eval x=\"$x\"
17392   exec_prefix="$acl_save_exec_prefix"
17393   prefix="$acl_save_prefix"
17394
17395                           if test "X$x" = "X-L$additional_libdir"; then
17396                             haveit=yes
17397                             break
17398                           fi
17399                         done
17400                         if test -z "$haveit"; then
17401                           if test -d "$additional_libdir"; then
17402                                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-L$additional_libdir"
17403                           fi
17404                         fi
17405                         haveit=
17406                         for x in $LDFLAGS $LTLIBBABELTRACE; do
17407
17408   acl_save_prefix="$prefix"
17409   prefix="$acl_final_prefix"
17410   acl_save_exec_prefix="$exec_prefix"
17411   exec_prefix="$acl_final_exec_prefix"
17412   eval x=\"$x\"
17413   exec_prefix="$acl_save_exec_prefix"
17414   prefix="$acl_save_prefix"
17415
17416                           if test "X$x" = "X-L$additional_libdir"; then
17417                             haveit=yes
17418                             break
17419                           fi
17420                         done
17421                         if test -z "$haveit"; then
17422                           if test -d "$additional_libdir"; then
17423                                                         LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-L$additional_libdir"
17424                           fi
17425                         fi
17426                       fi
17427                     fi
17428                     ;;
17429                   -R*)
17430                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
17431                     if test "$enable_rpath" != no; then
17432                                                                   haveit=
17433                       for x in $rpathdirs; do
17434                         if test "X$x" = "X$dir"; then
17435                           haveit=yes
17436                           break
17437                         fi
17438                       done
17439                       if test -z "$haveit"; then
17440                         rpathdirs="$rpathdirs $dir"
17441                       fi
17442                                                                   haveit=
17443                       for x in $ltrpathdirs; do
17444                         if test "X$x" = "X$dir"; then
17445                           haveit=yes
17446                           break
17447                         fi
17448                       done
17449                       if test -z "$haveit"; then
17450                         ltrpathdirs="$ltrpathdirs $dir"
17451                       fi
17452                     fi
17453                     ;;
17454                   -l*)
17455                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
17456                     ;;
17457                   *.la)
17458                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
17459                     ;;
17460                   *)
17461                                         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$dep"
17462                     LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }$dep"
17463                     ;;
17464                 esac
17465               done
17466             fi
17467           else
17468                                                             LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }-l$name"
17469             LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-l$name"
17470           fi
17471         fi
17472       fi
17473     done
17474   done
17475   if test "X$rpathdirs" != "X"; then
17476     if test -n "$hardcode_libdir_separator"; then
17477                         alldirs=
17478       for found_dir in $rpathdirs; do
17479         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
17480       done
17481             acl_save_libdir="$libdir"
17482       libdir="$alldirs"
17483       eval flag=\"$hardcode_libdir_flag_spec\"
17484       libdir="$acl_save_libdir"
17485       LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
17486     else
17487             for found_dir in $rpathdirs; do
17488         acl_save_libdir="$libdir"
17489         libdir="$found_dir"
17490         eval flag=\"$hardcode_libdir_flag_spec\"
17491         libdir="$acl_save_libdir"
17492         LIBBABELTRACE="${LIBBABELTRACE}${LIBBABELTRACE:+ }$flag"
17493       done
17494     fi
17495   fi
17496   if test "X$ltrpathdirs" != "X"; then
17497             for found_dir in $ltrpathdirs; do
17498       LTLIBBABELTRACE="${LTLIBBABELTRACE}${LTLIBBABELTRACE:+ }-R$found_dir"
17499     done
17500   fi
17501
17502
17503         ac_save_CPPFLAGS="$CPPFLAGS"
17504
17505   for element in $INCBABELTRACE; do
17506     haveit=
17507     for x in $CPPFLAGS; do
17508
17509   acl_save_prefix="$prefix"
17510   prefix="$acl_final_prefix"
17511   acl_save_exec_prefix="$exec_prefix"
17512   exec_prefix="$acl_final_exec_prefix"
17513   eval x=\"$x\"
17514   exec_prefix="$acl_save_exec_prefix"
17515   prefix="$acl_save_prefix"
17516
17517       if test "X$x" = "X$element"; then
17518         haveit=yes
17519         break
17520       fi
17521     done
17522     if test -z "$haveit"; then
17523       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
17524     fi
17525   done
17526
17527
17528   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbabeltrace" >&5
17529 $as_echo_n "checking for libbabeltrace... " >&6; }
17530 if ${ac_cv_libbabeltrace+:} false; then :
17531   $as_echo_n "(cached) " >&6
17532 else
17533
17534     ac_save_LIBS="$LIBS"
17535     LIBS="$LIBS $LIBBABELTRACE"
17536     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17537 /* end confdefs.h.  */
17538 #include <babeltrace/babeltrace.h>
17539                          #include <babeltrace/ctf/events.h>
17540                          #include <babeltrace/ctf/iterator.h>
17541 int
17542 main ()
17543 {
17544 struct bt_iter_pos *pos = bt_iter_get_pos (bt_ctf_get_iter (NULL));
17545                         struct bt_ctf_event *event = NULL;
17546                         const struct bt_definition *scope;
17547
17548                         pos->type = BT_SEEK_BEGIN;
17549                         bt_iter_set_pos (bt_ctf_get_iter (NULL), pos);
17550                         scope = bt_ctf_get_top_level_scope (event,
17551                                                            BT_STREAM_EVENT_HEADER);
17552                         bt_ctf_get_uint64 (bt_ctf_get_field (event, scope, "id"));
17553
17554   ;
17555   return 0;
17556 }
17557 _ACEOF
17558 if ac_fn_c_try_link "$LINENO"; then :
17559   ac_cv_libbabeltrace=yes
17560 else
17561   ac_cv_libbabeltrace=no
17562 fi
17563 rm -f core conftest.err conftest.$ac_objext \
17564     conftest$ac_exeext conftest.$ac_ext
17565     LIBS="$ac_save_LIBS"
17566
17567 fi
17568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libbabeltrace" >&5
17569 $as_echo "$ac_cv_libbabeltrace" >&6; }
17570   if test "$ac_cv_libbabeltrace" = yes; then
17571     HAVE_LIBBABELTRACE=yes
17572
17573 $as_echo "#define HAVE_LIBBABELTRACE 1" >>confdefs.h
17574
17575     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libbabeltrace" >&5
17576 $as_echo_n "checking how to link with libbabeltrace... " >&6; }
17577     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBBABELTRACE" >&5
17578 $as_echo "$LIBBABELTRACE" >&6; }
17579   else
17580     HAVE_LIBBABELTRACE=no
17581             CPPFLAGS="$ac_save_CPPFLAGS"
17582     LIBBABELTRACE=
17583     LTLIBBABELTRACE=
17584   fi
17585
17586
17587
17588
17589
17590
17591   CFLAGS=$saved_CFLAGS
17592
17593   if test "$HAVE_LIBBABELTRACE" != yes; then
17594      if test "$with_babeltrace" = yes; then
17595        as_fn_error $? "babeltrace is missing or unusable" "$LINENO" 5
17596      else
17597        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&5
17598 $as_echo "$as_me: WARNING: babeltrace is missing or unusable; GDB is unable to read CTF data." >&2;}
17599      fi
17600   fi
17601 fi
17602
17603 # If nativefile (NAT_FILE) is not set in configure.nat, we link to an
17604 # empty version.
17605
17606 files=
17607 links=
17608
17609 rm -f nm.h
17610 if test "${nativefile}" != ""; then
17611     case "${nativefile}" in
17612       nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
17613       * ) GDB_NM_FILE="${nativefile}"
17614     esac
17615     files="${files} ${GDB_NM_FILE}"
17616     links="${links} nm.h"
17617
17618 cat >>confdefs.h <<_ACEOF
17619 #define GDB_NM_FILE "${GDB_NM_FILE}"
17620 _ACEOF
17621
17622 fi
17623
17624
17625 for ac_prog in xsltproc
17626 do
17627   # Extract the first word of "$ac_prog", so it can be a program name with args.
17628 set dummy $ac_prog; ac_word=$2
17629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17630 $as_echo_n "checking for $ac_word... " >&6; }
17631 if ${ac_cv_path_XSLTPROC+:} false; then :
17632   $as_echo_n "(cached) " >&6
17633 else
17634   case $XSLTPROC in
17635   [\\/]* | ?:[\\/]*)
17636   ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
17637   ;;
17638   *)
17639   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17640 for as_dir in $PATH
17641 do
17642   IFS=$as_save_IFS
17643   test -z "$as_dir" && as_dir=.
17644     for ac_exec_ext in '' $ac_executable_extensions; do
17645   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17646     ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
17647     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17648     break 2
17649   fi
17650 done
17651   done
17652 IFS=$as_save_IFS
17653
17654   ;;
17655 esac
17656 fi
17657 XSLTPROC=$ac_cv_path_XSLTPROC
17658 if test -n "$XSLTPROC"; then
17659   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
17660 $as_echo "$XSLTPROC" >&6; }
17661 else
17662   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17663 $as_echo "no" >&6; }
17664 fi
17665
17666
17667   test -n "$XSLTPROC" && break
17668 done
17669 test -n "$XSLTPROC" || XSLTPROC="missing"
17670
17671 if test "x$USE_MAINTAINER_MODE" = xyes; then
17672   if test "${XSLTPROC}" = missing; then
17673     as_fn_error $? "unable to find xsltproc.  maintainer-mode requires xsltproc." "$LINENO" 5
17674   fi
17675 fi
17676
17677
17678 ac_sources="$files"
17679 ac_dests="$links"
17680 while test -n "$ac_sources"; do
17681   set $ac_dests; ac_dest=$1; shift; ac_dests=$*
17682   set $ac_sources; ac_source=$1; shift; ac_sources=$*
17683   ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
17684 done
17685 ac_config_links="$ac_config_links $ac_config_links_1"
17686
17687
17688
17689
17690
17691 $as_echo "#define GDB_DEFAULT_HOST_CHARSET \"UTF-8\"" >>confdefs.h
17692
17693
17694
17695 # Check whether we will enable the inclusion of unit tests when
17696 # compiling GDB.
17697 #
17698 # The default value of this option changes depending whether we're on
17699 # development mode (in which case it's "true") or not (in which case
17700 # it's "false").
17701 # Check whether --enable-unit-tests was given.
17702 if test "${enable_unit_tests+set}" = set; then :
17703   enableval=$enable_unit_tests; case "${enableval}" in
17704   yes)  enable_unittests=true  ;;
17705   no)   enable_unittests=false ;;
17706   *)    as_fn_error $? "bad value ${enableval} for --{enable,disable}-unit-tests option" "$LINENO" 5 ;;
17707 esac
17708 else
17709   enable_unittests=$development
17710 fi
17711
17712
17713 if $enable_unittests; then
17714
17715 $as_echo "#define GDB_SELF_TEST 1" >>confdefs.h
17716
17717
17718   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_UNITTESTS_OBS) common/selftest.o selftest-arch.o"
17719   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_UNITTESTS_SRCS) common/selftest.c selftest-arch.c"
17720
17721 fi
17722
17723
17724
17725   gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
17726   GDB_TRANSFORM_NAME=`echo gdb | sed -e "$gdb_ac_transform"`
17727   if test "x$GDB_TRANSFORM_NAME" = x; then
17728      GDB_TRANSFORM_NAME=gdb
17729   fi
17730
17731
17732
17733   gdb_ac_transform=`echo "$program_transform_name" | sed -e 's/\\$\\$/\\$/g'`
17734   GCORE_TRANSFORM_NAME=`echo gcore | sed -e "$gdb_ac_transform"`
17735   if test "x$GCORE_TRANSFORM_NAME" = x; then
17736      GCORE_TRANSFORM_NAME=gcore
17737   fi
17738
17739
17740 ac_config_files="$ac_config_files gcore"
17741
17742 ac_config_files="$ac_config_files Makefile gdb-gdb.gdb gdb-gdb.py doc/Makefile data-directory/Makefile"
17743
17744
17745 cat >confcache <<\_ACEOF
17746 # This file is a shell script that caches the results of configure
17747 # tests run on this system so they can be shared between configure
17748 # scripts and configure runs, see configure's option --config-cache.
17749 # It is not useful on other systems.  If it contains results you don't
17750 # want to keep, you may remove or edit it.
17751 #
17752 # config.status only pays attention to the cache file if you give it
17753 # the --recheck option to rerun configure.
17754 #
17755 # `ac_cv_env_foo' variables (set or unset) will be overridden when
17756 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17757 # following values.
17758
17759 _ACEOF
17760
17761 # The following way of writing the cache mishandles newlines in values,
17762 # but we know of no workaround that is simple, portable, and efficient.
17763 # So, we kill variables containing newlines.
17764 # Ultrix sh set writes to stderr and can't be redirected directly,
17765 # and sets the high bit in the cache file unless we assign to the vars.
17766 (
17767   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
17768     eval ac_val=\$$ac_var
17769     case $ac_val in #(
17770     *${as_nl}*)
17771       case $ac_var in #(
17772       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
17773 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
17774       esac
17775       case $ac_var in #(
17776       _ | IFS | as_nl) ;; #(
17777       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
17778       *) { eval $ac_var=; unset $ac_var;} ;;
17779       esac ;;
17780     esac
17781   done
17782
17783   (set) 2>&1 |
17784     case $as_nl`(ac_space=' '; set) 2>&1` in #(
17785     *${as_nl}ac_space=\ *)
17786       # `set' does not quote correctly, so add quotes: double-quote
17787       # substitution turns \\\\ into \\, and sed turns \\ into \.
17788       sed -n \
17789         "s/'/'\\\\''/g;
17790           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
17791       ;; #(
17792     *)
17793       # `set' quotes correctly as required by POSIX, so do not add quotes.
17794       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
17795       ;;
17796     esac |
17797     sort
17798 ) |
17799   sed '
17800      /^ac_cv_env_/b end
17801      t clear
17802      :clear
17803      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
17804      t end
17805      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
17806      :end' >>confcache
17807 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
17808   if test -w "$cache_file"; then
17809     if test "x$cache_file" != "x/dev/null"; then
17810       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
17811 $as_echo "$as_me: updating cache $cache_file" >&6;}
17812       if test ! -f "$cache_file" || test -h "$cache_file"; then
17813         cat confcache >"$cache_file"
17814       else
17815         case $cache_file in #(
17816         */* | ?:*)
17817           mv -f confcache "$cache_file"$$ &&
17818           mv -f "$cache_file"$$ "$cache_file" ;; #(
17819         *)
17820           mv -f confcache "$cache_file" ;;
17821         esac
17822       fi
17823     fi
17824   else
17825     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
17826 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
17827   fi
17828 fi
17829 rm -f confcache
17830
17831 test "x$prefix" = xNONE && prefix=$ac_default_prefix
17832 # Let make expand exec_prefix.
17833 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
17834
17835 DEFS=-DHAVE_CONFIG_H
17836
17837 ac_libobjs=
17838 ac_ltlibobjs=
17839 U=
17840 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
17841   # 1. Remove the extension, and $U if already installed.
17842   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
17843   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
17844   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
17845   #    will be set to the directory where LIBOBJS objects are built.
17846   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
17847   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
17848 done
17849 LIBOBJS=$ac_libobjs
17850
17851 LTLIBOBJS=$ac_ltlibobjs
17852
17853
17854 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
17855   as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
17856 Usually this means the macro was only invoked conditionally." "$LINENO" 5
17857 fi
17858 if test -z "${HAVE_PYTHON_TRUE}" && test -z "${HAVE_PYTHON_FALSE}"; then
17859   as_fn_error $? "conditional \"HAVE_PYTHON\" was never defined.
17860 Usually this means the macro was only invoked conditionally." "$LINENO" 5
17861 fi
17862 if test -z "${HAVE_GUILE_TRUE}" && test -z "${HAVE_GUILE_FALSE}"; then
17863   as_fn_error $? "conditional \"HAVE_GUILE\" was never defined.
17864 Usually this means the macro was only invoked conditionally." "$LINENO" 5
17865 fi
17866
17867
17868 : "${CONFIG_STATUS=./config.status}"
17869 ac_write_fail=0
17870 ac_clean_files_save=$ac_clean_files
17871 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
17872 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
17873 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
17874 as_write_fail=0
17875 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
17876 #! $SHELL
17877 # Generated by $as_me.
17878 # Run this file to recreate the current configuration.
17879 # Compiler output produced by configure, useful for debugging
17880 # configure, is in config.log if it exists.
17881
17882 debug=false
17883 ac_cs_recheck=false
17884 ac_cs_silent=false
17885
17886 SHELL=\${CONFIG_SHELL-$SHELL}
17887 export SHELL
17888 _ASEOF
17889 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
17890 ## -------------------- ##
17891 ## M4sh Initialization. ##
17892 ## -------------------- ##
17893
17894 # Be more Bourne compatible
17895 DUALCASE=1; export DUALCASE # for MKS sh
17896 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
17897   emulate sh
17898   NULLCMD=:
17899   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
17900   # is contrary to our usage.  Disable this feature.
17901   alias -g '${1+"$@"}'='"$@"'
17902   setopt NO_GLOB_SUBST
17903 else
17904   case `(set -o) 2>/dev/null` in #(
17905   *posix*) :
17906     set -o posix ;; #(
17907   *) :
17908      ;;
17909 esac
17910 fi
17911
17912
17913 as_nl='
17914 '
17915 export as_nl
17916 # Printing a long string crashes Solaris 7 /usr/bin/printf.
17917 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
17918 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
17919 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
17920 # Prefer a ksh shell builtin over an external printf program on Solaris,
17921 # but without wasting forks for bash or zsh.
17922 if test -z "$BASH_VERSION$ZSH_VERSION" \
17923     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
17924   as_echo='print -r --'
17925   as_echo_n='print -rn --'
17926 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
17927   as_echo='printf %s\n'
17928   as_echo_n='printf %s'
17929 else
17930   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
17931     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
17932     as_echo_n='/usr/ucb/echo -n'
17933   else
17934     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
17935     as_echo_n_body='eval
17936       arg=$1;
17937       case $arg in #(
17938       *"$as_nl"*)
17939         expr "X$arg" : "X\\(.*\\)$as_nl";
17940         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
17941       esac;
17942       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
17943     '
17944     export as_echo_n_body
17945     as_echo_n='sh -c $as_echo_n_body as_echo'
17946   fi
17947   export as_echo_body
17948   as_echo='sh -c $as_echo_body as_echo'
17949 fi
17950
17951 # The user is always right.
17952 if test "${PATH_SEPARATOR+set}" != set; then
17953   PATH_SEPARATOR=:
17954   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
17955     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
17956       PATH_SEPARATOR=';'
17957   }
17958 fi
17959
17960
17961 # IFS
17962 # We need space, tab and new line, in precisely that order.  Quoting is
17963 # there to prevent editors from complaining about space-tab.
17964 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
17965 # splitting by setting IFS to empty value.)
17966 IFS=" ""        $as_nl"
17967
17968 # Find who we are.  Look in the path if we contain no directory separator.
17969 as_myself=
17970 case $0 in #((
17971   *[\\/]* ) as_myself=$0 ;;
17972   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17973 for as_dir in $PATH
17974 do
17975   IFS=$as_save_IFS
17976   test -z "$as_dir" && as_dir=.
17977     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
17978   done
17979 IFS=$as_save_IFS
17980
17981      ;;
17982 esac
17983 # We did not find ourselves, most probably we were run as `sh COMMAND'
17984 # in which case we are not to be found in the path.
17985 if test "x$as_myself" = x; then
17986   as_myself=$0
17987 fi
17988 if test ! -f "$as_myself"; then
17989   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
17990   exit 1
17991 fi
17992
17993 # Unset variables that we do not need and which cause bugs (e.g. in
17994 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
17995 # suppresses any "Segmentation fault" message there.  '((' could
17996 # trigger a bug in pdksh 5.2.14.
17997 for as_var in BASH_ENV ENV MAIL MAILPATH
17998 do eval test x\${$as_var+set} = xset \
17999   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
18000 done
18001 PS1='$ '
18002 PS2='> '
18003 PS4='+ '
18004
18005 # NLS nuisances.
18006 LC_ALL=C
18007 export LC_ALL
18008 LANGUAGE=C
18009 export LANGUAGE
18010
18011 # CDPATH.
18012 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
18013
18014
18015 # as_fn_error STATUS ERROR [LINENO LOG_FD]
18016 # ----------------------------------------
18017 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
18018 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
18019 # script with STATUS, using 1 if that was 0.
18020 as_fn_error ()
18021 {
18022   as_status=$1; test $as_status -eq 0 && as_status=1
18023   if test "$4"; then
18024     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
18025     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
18026   fi
18027   $as_echo "$as_me: error: $2" >&2
18028   as_fn_exit $as_status
18029 } # as_fn_error
18030
18031
18032 # as_fn_set_status STATUS
18033 # -----------------------
18034 # Set $? to STATUS, without forking.
18035 as_fn_set_status ()
18036 {
18037   return $1
18038 } # as_fn_set_status
18039
18040 # as_fn_exit STATUS
18041 # -----------------
18042 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
18043 as_fn_exit ()
18044 {
18045   set +e
18046   as_fn_set_status $1
18047   exit $1
18048 } # as_fn_exit
18049
18050 # as_fn_unset VAR
18051 # ---------------
18052 # Portably unset VAR.
18053 as_fn_unset ()
18054 {
18055   { eval $1=; unset $1;}
18056 }
18057 as_unset=as_fn_unset
18058 # as_fn_append VAR VALUE
18059 # ----------------------
18060 # Append the text in VALUE to the end of the definition contained in VAR. Take
18061 # advantage of any shell optimizations that allow amortized linear growth over
18062 # repeated appends, instead of the typical quadratic growth present in naive
18063 # implementations.
18064 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
18065   eval 'as_fn_append ()
18066   {
18067     eval $1+=\$2
18068   }'
18069 else
18070   as_fn_append ()
18071   {
18072     eval $1=\$$1\$2
18073   }
18074 fi # as_fn_append
18075
18076 # as_fn_arith ARG...
18077 # ------------------
18078 # Perform arithmetic evaluation on the ARGs, and store the result in the
18079 # global $as_val. Take advantage of shells that can avoid forks. The arguments
18080 # must be portable across $(()) and expr.
18081 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
18082   eval 'as_fn_arith ()
18083   {
18084     as_val=$(( $* ))
18085   }'
18086 else
18087   as_fn_arith ()
18088   {
18089     as_val=`expr "$@" || test $? -eq 1`
18090   }
18091 fi # as_fn_arith
18092
18093
18094 if expr a : '\(a\)' >/dev/null 2>&1 &&
18095    test "X`expr 00001 : '.*\(...\)'`" = X001; then
18096   as_expr=expr
18097 else
18098   as_expr=false
18099 fi
18100
18101 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
18102   as_basename=basename
18103 else
18104   as_basename=false
18105 fi
18106
18107 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
18108   as_dirname=dirname
18109 else
18110   as_dirname=false
18111 fi
18112
18113 as_me=`$as_basename -- "$0" ||
18114 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18115          X"$0" : 'X\(//\)$' \| \
18116          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
18117 $as_echo X/"$0" |
18118     sed '/^.*\/\([^/][^/]*\)\/*$/{
18119             s//\1/
18120             q
18121           }
18122           /^X\/\(\/\/\)$/{
18123             s//\1/
18124             q
18125           }
18126           /^X\/\(\/\).*/{
18127             s//\1/
18128             q
18129           }
18130           s/.*/./; q'`
18131
18132 # Avoid depending upon Character Ranges.
18133 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18134 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18135 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18136 as_cr_digits='0123456789'
18137 as_cr_alnum=$as_cr_Letters$as_cr_digits
18138
18139 ECHO_C= ECHO_N= ECHO_T=
18140 case `echo -n x` in #(((((
18141 -n*)
18142   case `echo 'xy\c'` in
18143   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
18144   xy)  ECHO_C='\c';;
18145   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
18146        ECHO_T=' ';;
18147   esac;;
18148 *)
18149   ECHO_N='-n';;
18150 esac
18151
18152 rm -f conf$$ conf$$.exe conf$$.file
18153 if test -d conf$$.dir; then
18154   rm -f conf$$.dir/conf$$.file
18155 else
18156   rm -f conf$$.dir
18157   mkdir conf$$.dir 2>/dev/null
18158 fi
18159 if (echo >conf$$.file) 2>/dev/null; then
18160   if ln -s conf$$.file conf$$ 2>/dev/null; then
18161     as_ln_s='ln -s'
18162     # ... but there are two gotchas:
18163     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
18164     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
18165     # In both cases, we have to default to `cp -pR'.
18166     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
18167       as_ln_s='cp -pR'
18168   elif ln conf$$.file conf$$ 2>/dev/null; then
18169     as_ln_s=ln
18170   else
18171     as_ln_s='cp -pR'
18172   fi
18173 else
18174   as_ln_s='cp -pR'
18175 fi
18176 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
18177 rmdir conf$$.dir 2>/dev/null
18178
18179
18180 # as_fn_mkdir_p
18181 # -------------
18182 # Create "$as_dir" as a directory, including parents if necessary.
18183 as_fn_mkdir_p ()
18184 {
18185
18186   case $as_dir in #(
18187   -*) as_dir=./$as_dir;;
18188   esac
18189   test -d "$as_dir" || eval $as_mkdir_p || {
18190     as_dirs=
18191     while :; do
18192       case $as_dir in #(
18193       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
18194       *) as_qdir=$as_dir;;
18195       esac
18196       as_dirs="'$as_qdir' $as_dirs"
18197       as_dir=`$as_dirname -- "$as_dir" ||
18198 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18199          X"$as_dir" : 'X\(//\)[^/]' \| \
18200          X"$as_dir" : 'X\(//\)$' \| \
18201          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
18202 $as_echo X"$as_dir" |
18203     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18204             s//\1/
18205             q
18206           }
18207           /^X\(\/\/\)[^/].*/{
18208             s//\1/
18209             q
18210           }
18211           /^X\(\/\/\)$/{
18212             s//\1/
18213             q
18214           }
18215           /^X\(\/\).*/{
18216             s//\1/
18217             q
18218           }
18219           s/.*/./; q'`
18220       test -d "$as_dir" && break
18221     done
18222     test -z "$as_dirs" || eval "mkdir $as_dirs"
18223   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
18224
18225
18226 } # as_fn_mkdir_p
18227 if mkdir -p . 2>/dev/null; then
18228   as_mkdir_p='mkdir -p "$as_dir"'
18229 else
18230   test -d ./-p && rmdir ./-p
18231   as_mkdir_p=false
18232 fi
18233
18234
18235 # as_fn_executable_p FILE
18236 # -----------------------
18237 # Test if FILE is an executable regular file.
18238 as_fn_executable_p ()
18239 {
18240   test -f "$1" && test -x "$1"
18241 } # as_fn_executable_p
18242 as_test_x='test -x'
18243 as_executable_p=as_fn_executable_p
18244
18245 # Sed expression to map a string onto a valid CPP name.
18246 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
18247
18248 # Sed expression to map a string onto a valid variable name.
18249 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
18250
18251
18252 exec 6>&1
18253 ## ----------------------------------- ##
18254 ## Main body of $CONFIG_STATUS script. ##
18255 ## ----------------------------------- ##
18256 _ASEOF
18257 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
18258
18259 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18260 # Save the log message, to keep $0 and so on meaningful, and to
18261 # report actual input values of CONFIG_FILES etc. instead of their
18262 # values after options handling.
18263 ac_log="
18264 This file was extended by $as_me, which was
18265 generated by GNU Autoconf 2.69.  Invocation command line was
18266
18267   CONFIG_FILES    = $CONFIG_FILES
18268   CONFIG_HEADERS  = $CONFIG_HEADERS
18269   CONFIG_LINKS    = $CONFIG_LINKS
18270   CONFIG_COMMANDS = $CONFIG_COMMANDS
18271   $ $0 $@
18272
18273 on `(hostname || uname -n) 2>/dev/null | sed 1q`
18274 "
18275
18276 _ACEOF
18277
18278 case $ac_config_files in *"
18279 "*) set x $ac_config_files; shift; ac_config_files=$*;;
18280 esac
18281
18282 case $ac_config_headers in *"
18283 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
18284 esac
18285
18286
18287 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18288 # Files that config.status was made for.
18289 config_files="$ac_config_files"
18290 config_headers="$ac_config_headers"
18291 config_links="$ac_config_links"
18292 config_commands="$ac_config_commands"
18293
18294 _ACEOF
18295
18296 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18297 ac_cs_usage="\
18298 \`$as_me' instantiates files and other configuration actions
18299 from templates according to the current configuration.  Unless the files
18300 and actions are specified as TAGs, all are instantiated by default.
18301
18302 Usage: $0 [OPTION]... [TAG]...
18303
18304   -h, --help       print this help, then exit
18305   -V, --version    print version number and configuration settings, then exit
18306       --config     print configuration, then exit
18307   -q, --quiet, --silent
18308                    do not print progress messages
18309   -d, --debug      don't remove temporary files
18310       --recheck    update $as_me by reconfiguring in the same conditions
18311       --file=FILE[:TEMPLATE]
18312                    instantiate the configuration file FILE
18313       --header=FILE[:TEMPLATE]
18314                    instantiate the configuration header FILE
18315
18316 Configuration files:
18317 $config_files
18318
18319 Configuration headers:
18320 $config_headers
18321
18322 Configuration links:
18323 $config_links
18324
18325 Configuration commands:
18326 $config_commands
18327
18328 Report bugs to the package provider."
18329
18330 _ACEOF
18331 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18332 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
18333 ac_cs_version="\\
18334 config.status
18335 configured by $0, generated by GNU Autoconf 2.69,
18336   with options \\"\$ac_cs_config\\"
18337
18338 Copyright (C) 2012 Free Software Foundation, Inc.
18339 This config.status script is free software; the Free Software Foundation
18340 gives unlimited permission to copy, distribute and modify it."
18341
18342 ac_pwd='$ac_pwd'
18343 srcdir='$srcdir'
18344 INSTALL='$INSTALL'
18345 AWK='$AWK'
18346 test -n "\$AWK" || AWK=awk
18347 _ACEOF
18348
18349 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18350 # The default lists apply if the user does not specify any file.
18351 ac_need_defaults=:
18352 while test $# != 0
18353 do
18354   case $1 in
18355   --*=?*)
18356     ac_option=`expr "X$1" : 'X\([^=]*\)='`
18357     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
18358     ac_shift=:
18359     ;;
18360   --*=)
18361     ac_option=`expr "X$1" : 'X\([^=]*\)='`
18362     ac_optarg=
18363     ac_shift=:
18364     ;;
18365   *)
18366     ac_option=$1
18367     ac_optarg=$2
18368     ac_shift=shift
18369     ;;
18370   esac
18371
18372   case $ac_option in
18373   # Handling of the options.
18374   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18375     ac_cs_recheck=: ;;
18376   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
18377     $as_echo "$ac_cs_version"; exit ;;
18378   --config | --confi | --conf | --con | --co | --c )
18379     $as_echo "$ac_cs_config"; exit ;;
18380   --debug | --debu | --deb | --de | --d | -d )
18381     debug=: ;;
18382   --file | --fil | --fi | --f )
18383     $ac_shift
18384     case $ac_optarg in
18385     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18386     '') as_fn_error $? "missing file argument" ;;
18387     esac
18388     as_fn_append CONFIG_FILES " '$ac_optarg'"
18389     ac_need_defaults=false;;
18390   --header | --heade | --head | --hea )
18391     $ac_shift
18392     case $ac_optarg in
18393     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18394     esac
18395     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
18396     ac_need_defaults=false;;
18397   --he | --h)
18398     # Conflict between --help and --header
18399     as_fn_error $? "ambiguous option: \`$1'
18400 Try \`$0 --help' for more information.";;
18401   --help | --hel | -h )
18402     $as_echo "$ac_cs_usage"; exit ;;
18403   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18404   | -silent | --silent | --silen | --sile | --sil | --si | --s)
18405     ac_cs_silent=: ;;
18406
18407   # This is an error.
18408   -*) as_fn_error $? "unrecognized option: \`$1'
18409 Try \`$0 --help' for more information." ;;
18410
18411   *) as_fn_append ac_config_targets " $1"
18412      ac_need_defaults=false ;;
18413
18414   esac
18415   shift
18416 done
18417
18418 ac_configure_extra_args=
18419
18420 if $ac_cs_silent; then
18421   exec 6>/dev/null
18422   ac_configure_extra_args="$ac_configure_extra_args --silent"
18423 fi
18424
18425 _ACEOF
18426 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18427 if \$ac_cs_recheck; then
18428   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18429   shift
18430   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
18431   CONFIG_SHELL='$SHELL'
18432   export CONFIG_SHELL
18433   exec "\$@"
18434 fi
18435
18436 _ACEOF
18437 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18438 exec 5>>config.log
18439 {
18440   echo
18441   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18442 ## Running $as_me. ##
18443 _ASBOX
18444   $as_echo "$ac_log"
18445 } >&5
18446
18447 _ACEOF
18448 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18449 #
18450 # INIT-COMMANDS
18451 #
18452 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
18453
18454 _ACEOF
18455
18456 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18457
18458 # Handling of arguments.
18459 for ac_config_target in $ac_config_targets
18460 do
18461   case $ac_config_target in
18462     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
18463     "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
18464     "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;;
18465     "$ac_config_links_1") CONFIG_LINKS="$CONFIG_LINKS $ac_config_links_1" ;;
18466     "gcore") CONFIG_FILES="$CONFIG_FILES gcore" ;;
18467     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18468     "gdb-gdb.gdb") CONFIG_FILES="$CONFIG_FILES gdb-gdb.gdb" ;;
18469     "gdb-gdb.py") CONFIG_FILES="$CONFIG_FILES gdb-gdb.py" ;;
18470     "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
18471     "data-directory/Makefile") CONFIG_FILES="$CONFIG_FILES data-directory/Makefile" ;;
18472
18473   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
18474   esac
18475 done
18476
18477
18478 # If the user did not use the arguments to specify the items to instantiate,
18479 # then the envvar interface is used.  Set only those that are not.
18480 # We use the long form for the default assignment because of an extremely
18481 # bizarre bug on SunOS 4.1.3.
18482 if $ac_need_defaults; then
18483   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18484   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18485   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
18486   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
18487 fi
18488
18489 # Have a temporary directory for convenience.  Make it in the build tree
18490 # simply because there is no reason against having it here, and in addition,
18491 # creating and moving files from /tmp can sometimes cause problems.
18492 # Hook for its removal unless debugging.
18493 # Note that there is a small window in which the directory will not be cleaned:
18494 # after its creation but before its name has been assigned to `$tmp'.
18495 $debug ||
18496 {
18497   tmp= ac_tmp=
18498   trap 'exit_status=$?
18499   : "${ac_tmp:=$tmp}"
18500   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
18501 ' 0
18502   trap 'as_fn_exit 1' 1 2 13 15
18503 }
18504 # Create a (secure) tmp directory for tmp files.
18505
18506 {
18507   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
18508   test -d "$tmp"
18509 }  ||
18510 {
18511   tmp=./conf$$-$RANDOM
18512   (umask 077 && mkdir "$tmp")
18513 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
18514 ac_tmp=$tmp
18515
18516 # Set up the scripts for CONFIG_FILES section.
18517 # No need to generate them if there are no CONFIG_FILES.
18518 # This happens for instance with `./config.status config.h'.
18519 if test -n "$CONFIG_FILES"; then
18520
18521 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
18522   ac_cs_awk_getline=:
18523   ac_cs_awk_pipe_init=
18524   ac_cs_awk_read_file='
18525       while ((getline aline < (F[key])) > 0)
18526         print(aline)
18527       close(F[key])'
18528   ac_cs_awk_pipe_fini=
18529 else
18530   ac_cs_awk_getline=false
18531   ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
18532   ac_cs_awk_read_file='
18533       print "|#_!!_#|"
18534       print "cat " F[key] " &&"
18535       '$ac_cs_awk_pipe_init
18536   # The final `:' finishes the AND list.
18537   ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
18538 fi
18539 ac_cr=`echo X | tr X '\015'`
18540 # On cygwin, bash can eat \r inside `` if the user requested igncr.
18541 # But we know of no other shell where ac_cr would be empty at this
18542 # point, so we can use a bashism as a fallback.
18543 if test "x$ac_cr" = x; then
18544   eval ac_cr=\$\'\\r\'
18545 fi
18546 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
18547 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
18548   ac_cs_awk_cr='\\r'
18549 else
18550   ac_cs_awk_cr=$ac_cr
18551 fi
18552
18553 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
18554 _ACEOF
18555
18556 # Create commands to substitute file output variables.
18557 {
18558   echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
18559   echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
18560   echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
18561   echo "_ACAWK" &&
18562   echo "_ACEOF"
18563 } >conf$$files.sh &&
18564 . ./conf$$files.sh ||
18565   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18566 rm -f conf$$files.sh
18567
18568 {
18569   echo "cat >conf$$subs.awk <<_ACEOF" &&
18570   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
18571   echo "_ACEOF"
18572 } >conf$$subs.sh ||
18573   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18574 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
18575 ac_delim='%!_!# '
18576 for ac_last_try in false false false false false :; do
18577   . ./conf$$subs.sh ||
18578     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18579
18580   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
18581   if test $ac_delim_n = $ac_delim_num; then
18582     break
18583   elif $ac_last_try; then
18584     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18585   else
18586     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
18587   fi
18588 done
18589 rm -f conf$$subs.sh
18590
18591 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18592 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
18593 _ACEOF
18594 sed -n '
18595 h
18596 s/^/S["/; s/!.*/"]=/
18597 p
18598 g
18599 s/^[^!]*!//
18600 :repl
18601 t repl
18602 s/'"$ac_delim"'$//
18603 t delim
18604 :nl
18605 h
18606 s/\(.\{148\}\)..*/\1/
18607 t more1
18608 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
18609 p
18610 n
18611 b repl
18612 :more1
18613 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18614 p
18615 g
18616 s/.\{148\}//
18617 t nl
18618 :delim
18619 h
18620 s/\(.\{148\}\)..*/\1/
18621 t more2
18622 s/["\\]/\\&/g; s/^/"/; s/$/"/
18623 p
18624 b
18625 :more2
18626 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18627 p
18628 g
18629 s/.\{148\}//
18630 t delim
18631 ' <conf$$subs.awk | sed '
18632 /^[^""]/{
18633   N
18634   s/\n//
18635 }
18636 ' >>$CONFIG_STATUS || ac_write_fail=1
18637 rm -f conf$$subs.awk
18638 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18639 _ACAWK
18640 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
18641   for (key in S) S_is_set[key] = 1
18642   FS = "\a"
18643   \$ac_cs_awk_pipe_init
18644 }
18645 {
18646   line = $ 0
18647   nfields = split(line, field, "@")
18648   substed = 0
18649   len = length(field[1])
18650   for (i = 2; i < nfields; i++) {
18651     key = field[i]
18652     keylen = length(key)
18653     if (S_is_set[key]) {
18654       value = S[key]
18655       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
18656       len += length(value) + length(field[++i])
18657       substed = 1
18658     } else
18659       len += 1 + keylen
18660   }
18661   if (nfields == 3 && !substed) {
18662     key = field[2]
18663     if (F[key] != "" && line ~ /^[       ]*@.*@[         ]*$/) {
18664       \$ac_cs_awk_read_file
18665       next
18666     }
18667   }
18668   print line
18669 }
18670 \$ac_cs_awk_pipe_fini
18671 _ACAWK
18672 _ACEOF
18673 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18674 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
18675   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
18676 else
18677   cat
18678 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
18679   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
18680 _ACEOF
18681
18682 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
18683 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
18684 # trailing colons and then remove the whole line if VPATH becomes empty
18685 # (actually we leave an empty line to preserve line numbers).
18686 if test "x$srcdir" = x.; then
18687   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
18688 h
18689 s///
18690 s/^/:/
18691 s/[      ]*$/:/
18692 s/:\$(srcdir):/:/g
18693 s/:\${srcdir}:/:/g
18694 s/:@srcdir@:/:/g
18695 s/^:*//
18696 s/:*$//
18697 x
18698 s/\(=[   ]*\).*/\1/
18699 G
18700 s/\n//
18701 s/^[^=]*=[       ]*$//
18702 }'
18703 fi
18704
18705 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18706 fi # test -n "$CONFIG_FILES"
18707
18708 # Set up the scripts for CONFIG_HEADERS section.
18709 # No need to generate them if there are no CONFIG_HEADERS.
18710 # This happens for instance with `./config.status Makefile'.
18711 if test -n "$CONFIG_HEADERS"; then
18712 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
18713 BEGIN {
18714 _ACEOF
18715
18716 # Transform confdefs.h into an awk script `defines.awk', embedded as
18717 # here-document in config.status, that substitutes the proper values into
18718 # config.h.in to produce config.h.
18719
18720 # Create a delimiter string that does not exist in confdefs.h, to ease
18721 # handling of long lines.
18722 ac_delim='%!_!# '
18723 for ac_last_try in false false :; do
18724   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
18725   if test -z "$ac_tt"; then
18726     break
18727   elif $ac_last_try; then
18728     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
18729   else
18730     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
18731   fi
18732 done
18733
18734 # For the awk script, D is an array of macro values keyed by name,
18735 # likewise P contains macro parameters if any.  Preserve backslash
18736 # newline sequences.
18737
18738 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
18739 sed -n '
18740 s/.\{148\}/&'"$ac_delim"'/g
18741 t rset
18742 :rset
18743 s/^[     ]*#[    ]*define[       ][      ]*/ /
18744 t def
18745 d
18746 :def
18747 s/\\$//
18748 t bsnl
18749 s/["\\]/\\&/g
18750 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
18751 D["\1"]=" \3"/p
18752 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
18753 d
18754 :bsnl
18755 s/["\\]/\\&/g
18756 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
18757 D["\1"]=" \3\\\\\\n"\\/p
18758 t cont
18759 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
18760 t cont
18761 d
18762 :cont
18763 n
18764 s/.\{148\}/&'"$ac_delim"'/g
18765 t clear
18766 :clear
18767 s/\\$//
18768 t bsnlc
18769 s/["\\]/\\&/g; s/^/"/; s/$/"/p
18770 d
18771 :bsnlc
18772 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
18773 b cont
18774 ' <confdefs.h | sed '
18775 s/'"$ac_delim"'/"\\\
18776 "/g' >>$CONFIG_STATUS || ac_write_fail=1
18777
18778 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18779   for (key in D) D_is_set[key] = 1
18780   FS = "\a"
18781 }
18782 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
18783   line = \$ 0
18784   split(line, arg, " ")
18785   if (arg[1] == "#") {
18786     defundef = arg[2]
18787     mac1 = arg[3]
18788   } else {
18789     defundef = substr(arg[1], 2)
18790     mac1 = arg[2]
18791   }
18792   split(mac1, mac2, "(") #)
18793   macro = mac2[1]
18794   prefix = substr(line, 1, index(line, defundef) - 1)
18795   if (D_is_set[macro]) {
18796     # Preserve the white space surrounding the "#".
18797     print prefix "define", macro P[macro] D[macro]
18798     next
18799   } else {
18800     # Replace #undef with comments.  This is necessary, for example,
18801     # in the case of _POSIX_SOURCE, which is predefined and required
18802     # on some systems where configure will not decide to define it.
18803     if (defundef == "undef") {
18804       print "/*", prefix defundef, macro, "*/"
18805       next
18806     }
18807   }
18808 }
18809 { print }
18810 _ACAWK
18811 _ACEOF
18812 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18813   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
18814 fi # test -n "$CONFIG_HEADERS"
18815
18816
18817 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
18818 shift
18819 for ac_tag
18820 do
18821   case $ac_tag in
18822   :[FHLC]) ac_mode=$ac_tag; continue;;
18823   esac
18824   case $ac_mode$ac_tag in
18825   :[FHL]*:*);;
18826   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
18827   :[FH]-) ac_tag=-:-;;
18828   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
18829   esac
18830   ac_save_IFS=$IFS
18831   IFS=:
18832   set x $ac_tag
18833   IFS=$ac_save_IFS
18834   shift
18835   ac_file=$1
18836   shift
18837
18838   case $ac_mode in
18839   :L) ac_source=$1;;
18840   :[FH])
18841     ac_file_inputs=
18842     for ac_f
18843     do
18844       case $ac_f in
18845       -) ac_f="$ac_tmp/stdin";;
18846       *) # Look for the file first in the build tree, then in the source tree
18847          # (if the path is not absolute).  The absolute path cannot be DOS-style,
18848          # because $ac_f cannot contain `:'.
18849          test -f "$ac_f" ||
18850            case $ac_f in
18851            [\\/$]*) false;;
18852            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
18853            esac ||
18854            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
18855       esac
18856       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
18857       as_fn_append ac_file_inputs " '$ac_f'"
18858     done
18859
18860     # Let's still pretend it is `configure' which instantiates (i.e., don't
18861     # use $as_me), people would be surprised to read:
18862     #    /* config.h.  Generated by config.status.  */
18863     configure_input='Generated from '`
18864           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
18865         `' by configure.'
18866     if test x"$ac_file" != x-; then
18867       configure_input="$ac_file.  $configure_input"
18868       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
18869 $as_echo "$as_me: creating $ac_file" >&6;}
18870     fi
18871     # Neutralize special characters interpreted by sed in replacement strings.
18872     case $configure_input in #(
18873     *\&* | *\|* | *\\* )
18874        ac_sed_conf_input=`$as_echo "$configure_input" |
18875        sed 's/[\\\\&|]/\\\\&/g'`;; #(
18876     *) ac_sed_conf_input=$configure_input;;
18877     esac
18878
18879     case $ac_tag in
18880     *:-:* | *:-) cat >"$ac_tmp/stdin" \
18881       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
18882     esac
18883     ;;
18884   esac
18885
18886   ac_dir=`$as_dirname -- "$ac_file" ||
18887 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18888          X"$ac_file" : 'X\(//\)[^/]' \| \
18889          X"$ac_file" : 'X\(//\)$' \| \
18890          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
18891 $as_echo X"$ac_file" |
18892     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18893             s//\1/
18894             q
18895           }
18896           /^X\(\/\/\)[^/].*/{
18897             s//\1/
18898             q
18899           }
18900           /^X\(\/\/\)$/{
18901             s//\1/
18902             q
18903           }
18904           /^X\(\/\).*/{
18905             s//\1/
18906             q
18907           }
18908           s/.*/./; q'`
18909   as_dir="$ac_dir"; as_fn_mkdir_p
18910   ac_builddir=.
18911
18912 case "$ac_dir" in
18913 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
18914 *)
18915   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
18916   # A ".." for each directory in $ac_dir_suffix.
18917   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
18918   case $ac_top_builddir_sub in
18919   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
18920   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
18921   esac ;;
18922 esac
18923 ac_abs_top_builddir=$ac_pwd
18924 ac_abs_builddir=$ac_pwd$ac_dir_suffix
18925 # for backward compatibility:
18926 ac_top_builddir=$ac_top_build_prefix
18927
18928 case $srcdir in
18929   .)  # We are building in place.
18930     ac_srcdir=.
18931     ac_top_srcdir=$ac_top_builddir_sub
18932     ac_abs_top_srcdir=$ac_pwd ;;
18933   [\\/]* | ?:[\\/]* )  # Absolute name.
18934     ac_srcdir=$srcdir$ac_dir_suffix;
18935     ac_top_srcdir=$srcdir
18936     ac_abs_top_srcdir=$srcdir ;;
18937   *) # Relative name.
18938     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
18939     ac_top_srcdir=$ac_top_build_prefix$srcdir
18940     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
18941 esac
18942 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
18943
18944
18945   case $ac_mode in
18946   :F)
18947   #
18948   # CONFIG_FILE
18949   #
18950
18951   case $INSTALL in
18952   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
18953   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
18954   esac
18955 _ACEOF
18956
18957 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18958 # If the template does not know about datarootdir, expand it.
18959 # FIXME: This hack should be removed a few years after 2.60.
18960 ac_datarootdir_hack=; ac_datarootdir_seen=
18961 ac_sed_dataroot='
18962 /datarootdir/ {
18963   p
18964   q
18965 }
18966 /@datadir@/p
18967 /@docdir@/p
18968 /@infodir@/p
18969 /@localedir@/p
18970 /@mandir@/p'
18971 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
18972 *datarootdir*) ac_datarootdir_seen=yes;;
18973 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
18974   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
18975 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
18976 _ACEOF
18977 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18978   ac_datarootdir_hack='
18979   s&@datadir@&$datadir&g
18980   s&@docdir@&$docdir&g
18981   s&@infodir@&$infodir&g
18982   s&@localedir@&$localedir&g
18983   s&@mandir@&$mandir&g
18984   s&\\\${datarootdir}&$datarootdir&g' ;;
18985 esac
18986 _ACEOF
18987
18988 # Neutralize VPATH when `$srcdir' = `.'.
18989 # Shell code in configure.ac might set extrasub.
18990 # FIXME: do we really want to maintain this feature?
18991 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18992 ac_sed_extra="$ac_vpsub
18993 $extrasub
18994 _ACEOF
18995 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18996 :t
18997 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18998 s|@configure_input@|$ac_sed_conf_input|;t t
18999 s&@top_builddir@&$ac_top_builddir_sub&;t t
19000 s&@top_build_prefix@&$ac_top_build_prefix&;t t
19001 s&@srcdir@&$ac_srcdir&;t t
19002 s&@abs_srcdir@&$ac_abs_srcdir&;t t
19003 s&@top_srcdir@&$ac_top_srcdir&;t t
19004 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
19005 s&@builddir@&$ac_builddir&;t t
19006 s&@abs_builddir@&$ac_abs_builddir&;t t
19007 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
19008 s&@INSTALL@&$ac_INSTALL&;t t
19009 $ac_datarootdir_hack
19010 "
19011 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
19012 if $ac_cs_awk_getline; then
19013   $AWK -f "$ac_tmp/subs.awk"
19014 else
19015   $AWK -f "$ac_tmp/subs.awk" | $SHELL
19016 fi \
19017   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19018
19019 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
19020   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
19021   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
19022       "$ac_tmp/out"`; test -z "$ac_out"; } &&
19023   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19024 which seems to be undefined.  Please make sure it is defined" >&5
19025 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19026 which seems to be undefined.  Please make sure it is defined" >&2;}
19027
19028   rm -f "$ac_tmp/stdin"
19029   case $ac_file in
19030   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
19031   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
19032   esac \
19033   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19034  ;;
19035   :H)
19036   #
19037   # CONFIG_HEADER
19038   #
19039   if test x"$ac_file" != x-; then
19040     {
19041       $as_echo "/* $configure_input  */" \
19042       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
19043     } >"$ac_tmp/config.h" \
19044       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19045     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
19046       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
19047 $as_echo "$as_me: $ac_file is unchanged" >&6;}
19048     else
19049       rm -f "$ac_file"
19050       mv "$ac_tmp/config.h" "$ac_file" \
19051         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19052     fi
19053   else
19054     $as_echo "/* $configure_input  */" \
19055       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
19056       || as_fn_error $? "could not create -" "$LINENO" 5
19057   fi
19058  ;;
19059   :L)
19060   #
19061   # CONFIG_LINK
19062   #
19063
19064   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
19065     :
19066   else
19067     # Prefer the file from the source tree if names are identical.
19068     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
19069       ac_source=$srcdir/$ac_source
19070     fi
19071
19072     { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
19073 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
19074
19075     if test ! -r "$ac_source"; then
19076       as_fn_error $? "$ac_source: file not found" "$LINENO" 5
19077     fi
19078     rm -f "$ac_file"
19079
19080     # Try a relative symlink, then a hard link, then a copy.
19081     case $ac_source in
19082     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
19083         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
19084     esac
19085     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
19086       ln "$ac_source" "$ac_file" 2>/dev/null ||
19087       cp -p "$ac_source" "$ac_file" ||
19088       as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
19089   fi
19090  ;;
19091   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
19092 $as_echo "$as_me: executing $ac_file commands" >&6;}
19093  ;;
19094   esac
19095
19096
19097   case $ac_file$ac_mode in
19098     "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
19099     "gcore":F) chmod +x gcore ;;
19100     "Makefile":F)
19101 case x$CONFIG_HEADERS in
19102 xconfig.h:config.in)
19103 echo > stamp-h ;;
19104 esac
19105  ;;
19106     "gdb-gdb.gdb":F)
19107 case x$CONFIG_HEADERS in
19108 xconfig.h:config.in)
19109 echo > stamp-h ;;
19110 esac
19111  ;;
19112     "gdb-gdb.py":F)
19113 case x$CONFIG_HEADERS in
19114 xconfig.h:config.in)
19115 echo > stamp-h ;;
19116 esac
19117  ;;
19118     "doc/Makefile":F)
19119 case x$CONFIG_HEADERS in
19120 xconfig.h:config.in)
19121 echo > stamp-h ;;
19122 esac
19123  ;;
19124     "data-directory/Makefile":F)
19125 case x$CONFIG_HEADERS in
19126 xconfig.h:config.in)
19127 echo > stamp-h ;;
19128 esac
19129  ;;
19130
19131   esac
19132 done # for ac_tag
19133
19134
19135 as_fn_exit 0
19136 _ACEOF
19137 ac_clean_files=$ac_clean_files_save
19138
19139 test $ac_write_fail = 0 ||
19140   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
19141
19142
19143 # configure is writing to config.log, and then calls config.status.
19144 # config.status does its own redirection, appending to config.log.
19145 # Unfortunately, on DOS this fails, as config.log is still kept open
19146 # by configure, so config.status won't be able to write to it; its
19147 # output is simply discarded.  So we exec the FD to /dev/null,
19148 # effectively closing config.log, so it can be properly (re)opened and
19149 # appended to by config.status.  When coming back to configure, we
19150 # need to make the FD available again.
19151 if test "$no_create" != yes; then
19152   ac_cs_success=:
19153   ac_config_status_args=
19154   test "$silent" = yes &&
19155     ac_config_status_args="$ac_config_status_args --quiet"
19156   exec 5>/dev/null
19157   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
19158   exec 5>>config.log
19159   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19160   # would make configure fail if this is the last instruction.
19161   $ac_cs_success || as_fn_exit 1
19162 fi
19163
19164 #
19165 # CONFIG_SUBDIRS section.
19166 #
19167 if test "$no_recursion" != yes; then
19168
19169   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
19170   # so they do not pile up.
19171   ac_sub_configure_args=
19172   ac_prev=
19173   eval "set x $ac_configure_args"
19174   shift
19175   for ac_arg
19176   do
19177     if test -n "$ac_prev"; then
19178       ac_prev=
19179       continue
19180     fi
19181     case $ac_arg in
19182     -cache-file | --cache-file | --cache-fil | --cache-fi \
19183     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
19184       ac_prev=cache_file ;;
19185     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
19186     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
19187     | --c=*)
19188       ;;
19189     --config-cache | -C)
19190       ;;
19191     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
19192       ac_prev=srcdir ;;
19193     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
19194       ;;
19195     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
19196       ac_prev=prefix ;;
19197     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
19198       ;;
19199     --disable-option-checking)
19200       ;;
19201     *)
19202       case $ac_arg in
19203       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
19204       esac
19205       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
19206     esac
19207   done
19208
19209   # Always prepend --prefix to ensure using the same prefix
19210   # in subdir configurations.
19211   ac_arg="--prefix=$prefix"
19212   case $ac_arg in
19213   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
19214   esac
19215   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
19216
19217   # Pass --silent
19218   if test "$silent" = yes; then
19219     ac_sub_configure_args="--silent $ac_sub_configure_args"
19220   fi
19221
19222   # Always prepend --disable-option-checking to silence warnings, since
19223   # different subdirs can have different --enable and --with options.
19224   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
19225
19226   ac_popdir=`pwd`
19227   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
19228
19229     # Do not complain, so a configure script can configure whichever
19230     # parts of a large source tree are present.
19231     test -d "$srcdir/$ac_dir" || continue
19232
19233     ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
19234     $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
19235     $as_echo "$ac_msg" >&6
19236     as_dir="$ac_dir"; as_fn_mkdir_p
19237     ac_builddir=.
19238
19239 case "$ac_dir" in
19240 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
19241 *)
19242   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
19243   # A ".." for each directory in $ac_dir_suffix.
19244   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
19245   case $ac_top_builddir_sub in
19246   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
19247   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
19248   esac ;;
19249 esac
19250 ac_abs_top_builddir=$ac_pwd
19251 ac_abs_builddir=$ac_pwd$ac_dir_suffix
19252 # for backward compatibility:
19253 ac_top_builddir=$ac_top_build_prefix
19254
19255 case $srcdir in
19256   .)  # We are building in place.
19257     ac_srcdir=.
19258     ac_top_srcdir=$ac_top_builddir_sub
19259     ac_abs_top_srcdir=$ac_pwd ;;
19260   [\\/]* | ?:[\\/]* )  # Absolute name.
19261     ac_srcdir=$srcdir$ac_dir_suffix;
19262     ac_top_srcdir=$srcdir
19263     ac_abs_top_srcdir=$srcdir ;;
19264   *) # Relative name.
19265     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
19266     ac_top_srcdir=$ac_top_build_prefix$srcdir
19267     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
19268 esac
19269 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
19270
19271
19272     cd "$ac_dir"
19273
19274     # Check for guested configure; otherwise get Cygnus style configure.
19275     if test -f "$ac_srcdir/configure.gnu"; then
19276       ac_sub_configure=$ac_srcdir/configure.gnu
19277     elif test -f "$ac_srcdir/configure"; then
19278       ac_sub_configure=$ac_srcdir/configure
19279     elif test -f "$ac_srcdir/configure.in"; then
19280       # This should be Cygnus configure.
19281       ac_sub_configure=$ac_aux_dir/configure
19282     else
19283       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
19284 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
19285       ac_sub_configure=
19286     fi
19287
19288     # The recursion is here.
19289     if test -n "$ac_sub_configure"; then
19290       # Make the cache file name correct relative to the subdirectory.
19291       case $cache_file in
19292       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
19293       *) # Relative name.
19294         ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
19295       esac
19296
19297       { $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
19298 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
19299       # The eval makes quoting arguments work.
19300       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
19301            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
19302         as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
19303     fi
19304
19305     cd "$ac_popdir"
19306   done
19307 fi
19308 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
19309   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
19310 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
19311 fi
19312