gdb:
[platform/upstream/binutils.git] / gdb / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.59.
4 #
5 # Copyright (C) 2003 Free Software Foundation, Inc.
6 # This configure script is free software; the Free Software Foundation
7 # gives unlimited permission to copy, distribute and modify it.
8 ## --------------------- ##
9 ## M4sh Initialization.  ##
10 ## --------------------- ##
11
12 # Be Bourne compatible
13 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14   emulate sh
15   NULLCMD=:
16   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17   # is contrary to our usage.  Disable this feature.
18   alias -g '${1+"$@"}'='"$@"'
19 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20   set -o posix
21 fi
22 DUALCASE=1; export DUALCASE # for MKS sh
23
24 # Support unset when possible.
25 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
26   as_unset=unset
27 else
28   as_unset=false
29 fi
30
31
32 # Work around bugs in pre-3.0 UWIN ksh.
33 $as_unset ENV MAIL MAILPATH
34 PS1='$ '
35 PS2='> '
36 PS4='+ '
37
38 # NLS nuisances.
39 for as_var in \
40   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42   LC_TELEPHONE LC_TIME
43 do
44   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
45     eval $as_var=C; export $as_var
46   else
47     $as_unset $as_var
48   fi
49 done
50
51 # Required to use basename.
52 if expr a : '\(a\)' >/dev/null 2>&1; then
53   as_expr=expr
54 else
55   as_expr=false
56 fi
57
58 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
59   as_basename=basename
60 else
61   as_basename=false
62 fi
63
64
65 # Name of the executable.
66 as_me=`$as_basename "$0" ||
67 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68          X"$0" : 'X\(//\)$' \| \
69          X"$0" : 'X\(/\)$' \| \
70          .     : '\(.\)' 2>/dev/null ||
71 echo X/"$0" |
72     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73           /^X\/\(\/\/\)$/{ s//\1/; q; }
74           /^X\/\(\/\).*/{ s//\1/; q; }
75           s/.*/./; q'`
76
77
78 # PATH needs CR, and LINENO needs CR and PATH.
79 # Avoid depending upon Character Ranges.
80 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83 as_cr_digits='0123456789'
84 as_cr_alnum=$as_cr_Letters$as_cr_digits
85
86 # The user is always right.
87 if test "${PATH_SEPARATOR+set}" != set; then
88   echo "#! /bin/sh" >conf$$.sh
89   echo  "exit 0"   >>conf$$.sh
90   chmod +x conf$$.sh
91   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
92     PATH_SEPARATOR=';'
93   else
94     PATH_SEPARATOR=:
95   fi
96   rm -f conf$$.sh
97 fi
98
99
100   as_lineno_1=$LINENO
101   as_lineno_2=$LINENO
102   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103   test "x$as_lineno_1" != "x$as_lineno_2" &&
104   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
105   # Find who we are.  Look in the path if we contain no path at all
106   # relative or not.
107   case $0 in
108     *[\\/]* ) as_myself=$0 ;;
109     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110 for as_dir in $PATH
111 do
112   IFS=$as_save_IFS
113   test -z "$as_dir" && as_dir=.
114   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115 done
116
117        ;;
118   esac
119   # We did not find ourselves, most probably we were run as `sh COMMAND'
120   # in which case we are not to be found in the path.
121   if test "x$as_myself" = x; then
122     as_myself=$0
123   fi
124   if test ! -f "$as_myself"; then
125     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126    { (exit 1); exit 1; }; }
127   fi
128   case $CONFIG_SHELL in
129   '')
130     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
131 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
132 do
133   IFS=$as_save_IFS
134   test -z "$as_dir" && as_dir=.
135   for as_base in sh bash ksh sh5; do
136          case $as_dir in
137          /*)
138            if ("$as_dir/$as_base" -c '
139   as_lineno_1=$LINENO
140   as_lineno_2=$LINENO
141   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
142   test "x$as_lineno_1" != "x$as_lineno_2" &&
143   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
144              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
146              CONFIG_SHELL=$as_dir/$as_base
147              export CONFIG_SHELL
148              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149            fi;;
150          esac
151        done
152 done
153 ;;
154   esac
155
156   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157   # uniformly replaced by the line number.  The first 'sed' inserts a
158   # line-number line before each line; the second 'sed' does the real
159   # work.  The second script uses 'N' to pair each line-number line
160   # with the numbered line, and appends trailing '-' during
161   # substitution so that $LINENO is not a special case at line end.
162   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
163   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
164   sed '=' <$as_myself |
165     sed '
166       N
167       s,$,-,
168       : loop
169       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
170       t loop
171       s,-$,,
172       s,^['$as_cr_digits']*\n,,
173     ' >$as_me.lineno &&
174   chmod +x $as_me.lineno ||
175     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176    { (exit 1); exit 1; }; }
177
178   # Don't try to exec as it changes $[0], causing all sort of problems
179   # (the dirname of $[0] is not the place where we might find the
180   # original and so on.  Autoconf is especially sensible to this).
181   . ./$as_me.lineno
182   # Exit status is that of the last command.
183   exit
184 }
185
186
187 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188   *c*,-n*) ECHO_N= ECHO_C='
189 ' ECHO_T='      ' ;;
190   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
192 esac
193
194 if expr a : '\(a\)' >/dev/null 2>&1; then
195   as_expr=expr
196 else
197   as_expr=false
198 fi
199
200 rm -f conf$$ conf$$.exe conf$$.file
201 echo >conf$$.file
202 if ln -s conf$$.file conf$$ 2>/dev/null; then
203   # We could just check for DJGPP; but this test a) works b) is more generic
204   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205   if test -f conf$$.exe; then
206     # Don't use ln at all; we don't have any links
207     as_ln_s='cp -p'
208   else
209     as_ln_s='ln -s'
210   fi
211 elif ln conf$$.file conf$$ 2>/dev/null; then
212   as_ln_s=ln
213 else
214   as_ln_s='cp -p'
215 fi
216 rm -f conf$$ conf$$.exe conf$$.file
217
218 if mkdir -p . 2>/dev/null; then
219   as_mkdir_p=:
220 else
221   test -d ./-p && rmdir ./-p
222   as_mkdir_p=false
223 fi
224
225 as_executable_p="test -f"
226
227 # Sed expression to map a string onto a valid CPP name.
228 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
229
230 # Sed expression to map a string onto a valid variable name.
231 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
232
233
234 # IFS
235 # We need space, tab and new line, in precisely that order.
236 as_nl='
237 '
238 IFS="   $as_nl"
239
240 # CDPATH.
241 $as_unset CDPATH
242
243
244 # Name of the host.
245 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246 # so uname gets run too.
247 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249 exec 6>&1
250
251 #
252 # Initializations.
253 #
254 ac_default_prefix=/usr/local
255 ac_config_libobj_dir=.
256 cross_compiling=no
257 subdirs=
258 MFLAGS=
259 MAKEFLAGS=
260 SHELL=${CONFIG_SHELL-/bin/sh}
261
262 # Maximum number of lines to put in a shell here document.
263 # This variable seems obsolete.  It should probably be removed, and
264 # only ac_max_sed_lines should be used.
265 : ${ac_max_here_lines=38}
266
267 # Identity of this package.
268 PACKAGE_NAME=
269 PACKAGE_TARNAME=
270 PACKAGE_VERSION=
271 PACKAGE_STRING=
272 PACKAGE_BUGREPORT=
273
274 ac_unique_file="main.c"
275 # Factoring default headers for most tests.
276 ac_includes_default="\
277 #include <stdio.h>
278 #if HAVE_SYS_TYPES_H
279 # include <sys/types.h>
280 #endif
281 #if HAVE_SYS_STAT_H
282 # include <sys/stat.h>
283 #endif
284 #if STDC_HEADERS
285 # include <stdlib.h>
286 # include <stddef.h>
287 #else
288 # if HAVE_STDLIB_H
289 #  include <stdlib.h>
290 # endif
291 #endif
292 #if HAVE_STRING_H
293 # if !STDC_HEADERS && HAVE_MEMORY_H
294 #  include <memory.h>
295 # endif
296 # include <string.h>
297 #endif
298 #if HAVE_STRINGS_H
299 # include <strings.h>
300 #endif
301 #if HAVE_INTTYPES_H
302 # include <inttypes.h>
303 #else
304 # if HAVE_STDINT_H
305 #  include <stdint.h>
306 # endif
307 #endif
308 #if HAVE_UNISTD_H
309 # include <unistd.h>
310 #endif"
311
312 gl_header_list=
313 ac_subdirs_all="$ac_subdirs_all doc testsuite"
314 ac_subdirs_all="$ac_subdirs_all gdbtk"
315 ac_subdirs_all="$ac_subdirs_all multi-ice"
316 ac_subdirs_all="$ac_subdirs_all gdbserver"
317 ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP RANLIB ac_ct_RANLIB build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os am__leading_dot DEPDIR CCDEPMODE MAKE GMAKE_TRUE GMAKE_FALSE SET_MAKE USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT localedir GL_COND_LIBTOOL_TRUE GL_COND_LIBTOOL_FALSE GNULIB_MEMMEM GNULIB_MEMPCPY GNULIB_MEMRCHR GNULIB_STPCPY GNULIB_STPNCPY GNULIB_STRCHRNUL GNULIB_STRDUP GNULIB_STRNDUP GNULIB_STRNLEN GNULIB_STRPBRK GNULIB_STRSEP GNULIB_STRSTR GNULIB_STRCASESTR GNULIB_STRTOK_R GNULIB_MBSLEN GNULIB_MBSNLEN GNULIB_MBSCHR GNULIB_MBSRCHR GNULIB_MBSSTR GNULIB_MBSCASECMP GNULIB_MBSNCASECMP GNULIB_MBSPCASECMP GNULIB_MBSCASESTR GNULIB_MBSCSPN GNULIB_MBSPBRK GNULIB_MBSSPN GNULIB_MBSSEP GNULIB_MBSTOK_R GNULIB_STRERROR GNULIB_STRSIGNAL HAVE_DECL_MEMMEM HAVE_MEMPCPY HAVE_DECL_MEMRCHR HAVE_STPCPY HAVE_STPNCPY HAVE_STRCHRNUL HAVE_DECL_STRDUP HAVE_STRNDUP HAVE_DECL_STRNDUP HAVE_DECL_STRNLEN HAVE_STRPBRK HAVE_STRSEP HAVE_STRCASESTR HAVE_DECL_STRTOK_R HAVE_DECL_STRERROR HAVE_DECL_STRSIGNAL REPLACE_STRERROR REPLACE_STRSIGNAL REPLACE_MEMMEM REPLACE_STRCASESTR REPLACE_STRSTR HAVE_LONG_LONG_INT HAVE_UNSIGNED_LONG_LONG_INT HAVE_INTTYPES_H HAVE_SYS_TYPES_H INCLUDE_NEXT NEXT_STDINT_H HAVE_STDINT_H HAVE_SYS_INTTYPES_H HAVE_SYS_BITYPES_H BITSIZEOF_PTRDIFF_T BITSIZEOF_SIG_ATOMIC_T BITSIZEOF_SIZE_T BITSIZEOF_WCHAR_T BITSIZEOF_WINT_T HAVE_SIGNED_SIG_ATOMIC_T HAVE_SIGNED_WCHAR_T HAVE_SIGNED_WINT_T PTRDIFF_T_SUFFIX SIG_ATOMIC_T_SUFFIX SIZE_T_SUFFIX WCHAR_T_SUFFIX WINT_T_SUFFIX STDINT_H NEXT_STRING_H GNULIB_WCWIDTH HAVE_DECL_WCWIDTH REPLACE_WCWIDTH WCHAR_H HAVE_WCHAR_H NEXT_WCHAR_H LIBGNU_LIBDEPS LIBGNU_LTLIBDEPS GNULIB_STDINT_H PACKAGE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK AMTAR am__tar am__untar am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH am__fastdepCC_TRUE am__fastdepCC_FALSE subdirs TARGET_OBS PKGVERSION REPORT_BUGS_TO REPORT_BUGS_TEXI LN_S YACC AR ac_ct_AR DLLTOOL ac_ct_DLLTOOL WINDRES ac_ct_WINDRES MIG ac_ct_MIG READLINE READLINE_DEPS READLINE_CFLAGS HAVE_LIBEXPAT LIBEXPAT LTLIBEXPAT PYTHON_CFLAGS ALLOCA CONFIG_LDFLAGS TARGET_SYSTEM_ROOT TARGET_SYSTEM_ROOT_DEFINE WARN_CFLAGS WERROR_CFLAGS SER_HARDWIRE WIN32LIBS LIBGUI GUI_CFLAGS_X WIN32LDAPP TCL_VERSION TCL_PATCH_LEVEL TCL_BIN_DIR TCL_SRC_DIR TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC TCL_INCLUDE TCL_LIBRARY TCL_DEPS TK_VERSION TK_BIN_DIR TK_SRC_DIR TK_LIB_FILE TK_LIB_FLAG TK_LIB_SPEC TK_STUB_LIB_FILE TK_STUB_LIB_FLAG TK_STUB_LIB_SPEC TK_INCLUDE TK_LIBRARY TK_DEPS TK_XINCLUDES X_CFLAGS X_LDFLAGS X_LIBS GDBTKLIBS GDBTK_CFLAGS GDBTK_SRC_DIR SIM SIM_OBS ENABLE_CFLAGS PROFILE_CFLAGS CONFIG_OBS CONFIG_DEPS CONFIG_SRCS CONFIG_ALL CONFIG_CLEAN CONFIG_INSTALL CONFIG_UNINSTALL target_subdir frags nm_h datarootdir docdir htmldir pdfdir LIBOBJS LTLIBOBJS gl_LIBOBJS gl_LTLIBOBJS gltests_LIBOBJS gltests_LTLIBOBJS'
318 ac_subst_files='host_makefile_frag'
319 ac_pwd=`pwd`
320
321 # Initialize some variables set by options.
322 ac_init_help=
323 ac_init_version=false
324 # The variables have the same names as the options, with
325 # dashes changed to underlines.
326 cache_file=/dev/null
327 exec_prefix=NONE
328 no_create=
329 no_recursion=
330 prefix=NONE
331 program_prefix=NONE
332 program_suffix=NONE
333 program_transform_name=s,x,x,
334 silent=
335 site=
336 srcdir=
337 verbose=
338 x_includes=NONE
339 x_libraries=NONE
340
341 # Installation directory options.
342 # These are left unexpanded so users can "make install exec_prefix=/foo"
343 # and all the variables that are supposed to be based on exec_prefix
344 # by default will actually change.
345 # Use braces instead of parens because sh, perl, etc. also accept them.
346 bindir='${exec_prefix}/bin'
347 sbindir='${exec_prefix}/sbin'
348 libexecdir='${exec_prefix}/libexec'
349 datadir='${prefix}/share'
350 sysconfdir='${prefix}/etc'
351 sharedstatedir='${prefix}/com'
352 localstatedir='${prefix}/var'
353 libdir='${exec_prefix}/lib'
354 includedir='${prefix}/include'
355 oldincludedir='/usr/include'
356 infodir='${prefix}/info'
357 mandir='${prefix}/man'
358
359 ac_prev=
360 for ac_option
361 do
362   # If the previous option needs an argument, assign it.
363   if test -n "$ac_prev"; then
364     eval "$ac_prev=\$ac_option"
365     ac_prev=
366     continue
367   fi
368
369   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
370
371   # Accept the important Cygnus configure options, so we can diagnose typos.
372
373   case $ac_option in
374
375   -bindir | --bindir | --bindi | --bind | --bin | --bi)
376     ac_prev=bindir ;;
377   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
378     bindir=$ac_optarg ;;
379
380   -build | --build | --buil | --bui | --bu)
381     ac_prev=build_alias ;;
382   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
383     build_alias=$ac_optarg ;;
384
385   -cache-file | --cache-file | --cache-fil | --cache-fi \
386   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
387     ac_prev=cache_file ;;
388   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
389   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
390     cache_file=$ac_optarg ;;
391
392   --config-cache | -C)
393     cache_file=config.cache ;;
394
395   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
396     ac_prev=datadir ;;
397   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
398   | --da=*)
399     datadir=$ac_optarg ;;
400
401   -disable-* | --disable-*)
402     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
403     # Reject names that are not valid shell variable names.
404     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
405       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
406    { (exit 1); exit 1; }; }
407     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
408     eval "enable_$ac_feature=no" ;;
409
410   -enable-* | --enable-*)
411     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
412     # Reject names that are not valid shell variable names.
413     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
414       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
415    { (exit 1); exit 1; }; }
416     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
417     case $ac_option in
418       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
419       *) ac_optarg=yes ;;
420     esac
421     eval "enable_$ac_feature='$ac_optarg'" ;;
422
423   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
424   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
425   | --exec | --exe | --ex)
426     ac_prev=exec_prefix ;;
427   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
428   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
429   | --exec=* | --exe=* | --ex=*)
430     exec_prefix=$ac_optarg ;;
431
432   -gas | --gas | --ga | --g)
433     # Obsolete; use --with-gas.
434     with_gas=yes ;;
435
436   -help | --help | --hel | --he | -h)
437     ac_init_help=long ;;
438   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
439     ac_init_help=recursive ;;
440   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
441     ac_init_help=short ;;
442
443   -host | --host | --hos | --ho)
444     ac_prev=host_alias ;;
445   -host=* | --host=* | --hos=* | --ho=*)
446     host_alias=$ac_optarg ;;
447
448   -includedir | --includedir | --includedi | --included | --include \
449   | --includ | --inclu | --incl | --inc)
450     ac_prev=includedir ;;
451   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
452   | --includ=* | --inclu=* | --incl=* | --inc=*)
453     includedir=$ac_optarg ;;
454
455   -infodir | --infodir | --infodi | --infod | --info | --inf)
456     ac_prev=infodir ;;
457   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
458     infodir=$ac_optarg ;;
459
460   -libdir | --libdir | --libdi | --libd)
461     ac_prev=libdir ;;
462   -libdir=* | --libdir=* | --libdi=* | --libd=*)
463     libdir=$ac_optarg ;;
464
465   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
466   | --libexe | --libex | --libe)
467     ac_prev=libexecdir ;;
468   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
469   | --libexe=* | --libex=* | --libe=*)
470     libexecdir=$ac_optarg ;;
471
472   -localstatedir | --localstatedir | --localstatedi | --localstated \
473   | --localstate | --localstat | --localsta | --localst \
474   | --locals | --local | --loca | --loc | --lo)
475     ac_prev=localstatedir ;;
476   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
477   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
478   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
479     localstatedir=$ac_optarg ;;
480
481   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
482     ac_prev=mandir ;;
483   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
484     mandir=$ac_optarg ;;
485
486   -nfp | --nfp | --nf)
487     # Obsolete; use --without-fp.
488     with_fp=no ;;
489
490   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
491   | --no-cr | --no-c | -n)
492     no_create=yes ;;
493
494   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
495   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
496     no_recursion=yes ;;
497
498   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
499   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
500   | --oldin | --oldi | --old | --ol | --o)
501     ac_prev=oldincludedir ;;
502   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
503   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
504   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
505     oldincludedir=$ac_optarg ;;
506
507   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
508     ac_prev=prefix ;;
509   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
510     prefix=$ac_optarg ;;
511
512   -program-prefix | --program-prefix | --program-prefi | --program-pref \
513   | --program-pre | --program-pr | --program-p)
514     ac_prev=program_prefix ;;
515   -program-prefix=* | --program-prefix=* | --program-prefi=* \
516   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
517     program_prefix=$ac_optarg ;;
518
519   -program-suffix | --program-suffix | --program-suffi | --program-suff \
520   | --program-suf | --program-su | --program-s)
521     ac_prev=program_suffix ;;
522   -program-suffix=* | --program-suffix=* | --program-suffi=* \
523   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
524     program_suffix=$ac_optarg ;;
525
526   -program-transform-name | --program-transform-name \
527   | --program-transform-nam | --program-transform-na \
528   | --program-transform-n | --program-transform- \
529   | --program-transform | --program-transfor \
530   | --program-transfo | --program-transf \
531   | --program-trans | --program-tran \
532   | --progr-tra | --program-tr | --program-t)
533     ac_prev=program_transform_name ;;
534   -program-transform-name=* | --program-transform-name=* \
535   | --program-transform-nam=* | --program-transform-na=* \
536   | --program-transform-n=* | --program-transform-=* \
537   | --program-transform=* | --program-transfor=* \
538   | --program-transfo=* | --program-transf=* \
539   | --program-trans=* | --program-tran=* \
540   | --progr-tra=* | --program-tr=* | --program-t=*)
541     program_transform_name=$ac_optarg ;;
542
543   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
544   | -silent | --silent | --silen | --sile | --sil)
545     silent=yes ;;
546
547   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
548     ac_prev=sbindir ;;
549   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
550   | --sbi=* | --sb=*)
551     sbindir=$ac_optarg ;;
552
553   -sharedstatedir | --sharedstatedir | --sharedstatedi \
554   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
555   | --sharedst | --shareds | --shared | --share | --shar \
556   | --sha | --sh)
557     ac_prev=sharedstatedir ;;
558   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
559   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
560   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
561   | --sha=* | --sh=*)
562     sharedstatedir=$ac_optarg ;;
563
564   -site | --site | --sit)
565     ac_prev=site ;;
566   -site=* | --site=* | --sit=*)
567     site=$ac_optarg ;;
568
569   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
570     ac_prev=srcdir ;;
571   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
572     srcdir=$ac_optarg ;;
573
574   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
575   | --syscon | --sysco | --sysc | --sys | --sy)
576     ac_prev=sysconfdir ;;
577   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
578   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
579     sysconfdir=$ac_optarg ;;
580
581   -target | --target | --targe | --targ | --tar | --ta | --t)
582     ac_prev=target_alias ;;
583   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
584     target_alias=$ac_optarg ;;
585
586   -v | -verbose | --verbose | --verbos | --verbo | --verb)
587     verbose=yes ;;
588
589   -version | --version | --versio | --versi | --vers | -V)
590     ac_init_version=: ;;
591
592   -with-* | --with-*)
593     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
594     # Reject names that are not valid shell variable names.
595     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
596       { echo "$as_me: error: invalid package name: $ac_package" >&2
597    { (exit 1); exit 1; }; }
598     ac_package=`echo $ac_package| sed 's/-/_/g'`
599     case $ac_option in
600       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
601       *) ac_optarg=yes ;;
602     esac
603     eval "with_$ac_package='$ac_optarg'" ;;
604
605   -without-* | --without-*)
606     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
607     # Reject names that are not valid shell variable names.
608     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
609       { echo "$as_me: error: invalid package name: $ac_package" >&2
610    { (exit 1); exit 1; }; }
611     ac_package=`echo $ac_package | sed 's/-/_/g'`
612     eval "with_$ac_package=no" ;;
613
614   --x)
615     # Obsolete; use --with-x.
616     with_x=yes ;;
617
618   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
619   | --x-incl | --x-inc | --x-in | --x-i)
620     ac_prev=x_includes ;;
621   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
622   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
623     x_includes=$ac_optarg ;;
624
625   -x-libraries | --x-libraries | --x-librarie | --x-librari \
626   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
627     ac_prev=x_libraries ;;
628   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
629   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
630     x_libraries=$ac_optarg ;;
631
632   -*) { echo "$as_me: error: unrecognized option: $ac_option
633 Try \`$0 --help' for more information." >&2
634    { (exit 1); exit 1; }; }
635     ;;
636
637   *=*)
638     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
639     # Reject names that are not valid shell variable names.
640     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
641       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
642    { (exit 1); exit 1; }; }
643     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
644     eval "$ac_envvar='$ac_optarg'"
645     export $ac_envvar ;;
646
647   *)
648     # FIXME: should be removed in autoconf 3.0.
649     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
650     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
651       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
652     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
653     ;;
654
655   esac
656 done
657
658 if test -n "$ac_prev"; then
659   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
660   { echo "$as_me: error: missing argument to $ac_option" >&2
661    { (exit 1); exit 1; }; }
662 fi
663
664 # Be sure to have absolute paths.
665 for ac_var in exec_prefix prefix
666 do
667   eval ac_val=$`echo $ac_var`
668   case $ac_val in
669     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
670     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
671    { (exit 1); exit 1; }; };;
672   esac
673 done
674
675 # Be sure to have absolute paths.
676 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
677               localstatedir libdir includedir oldincludedir infodir mandir
678 do
679   eval ac_val=$`echo $ac_var`
680   case $ac_val in
681     [\\/$]* | ?:[\\/]* ) ;;
682     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
683    { (exit 1); exit 1; }; };;
684   esac
685 done
686
687 # There might be people who depend on the old broken behavior: `$host'
688 # used to hold the argument of --host etc.
689 # FIXME: To remove some day.
690 build=$build_alias
691 host=$host_alias
692 target=$target_alias
693
694 # FIXME: To remove some day.
695 if test "x$host_alias" != x; then
696   if test "x$build_alias" = x; then
697     cross_compiling=maybe
698     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
699     If a cross compiler is detected then cross compile mode will be used." >&2
700   elif test "x$build_alias" != "x$host_alias"; then
701     cross_compiling=yes
702   fi
703 fi
704
705 ac_tool_prefix=
706 test -n "$host_alias" && ac_tool_prefix=$host_alias-
707
708 test "$silent" = yes && exec 6>/dev/null
709
710
711 # Find the source files, if location was not specified.
712 if test -z "$srcdir"; then
713   ac_srcdir_defaulted=yes
714   # Try the directory containing this script, then its parent.
715   ac_confdir=`(dirname "$0") 2>/dev/null ||
716 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
717          X"$0" : 'X\(//\)[^/]' \| \
718          X"$0" : 'X\(//\)$' \| \
719          X"$0" : 'X\(/\)' \| \
720          .     : '\(.\)' 2>/dev/null ||
721 echo X"$0" |
722     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
723           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
724           /^X\(\/\/\)$/{ s//\1/; q; }
725           /^X\(\/\).*/{ s//\1/; q; }
726           s/.*/./; q'`
727   srcdir=$ac_confdir
728   if test ! -r $srcdir/$ac_unique_file; then
729     srcdir=..
730   fi
731 else
732   ac_srcdir_defaulted=no
733 fi
734 if test ! -r $srcdir/$ac_unique_file; then
735   if test "$ac_srcdir_defaulted" = yes; then
736     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
737    { (exit 1); exit 1; }; }
738   else
739     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
740    { (exit 1); exit 1; }; }
741   fi
742 fi
743 (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
744   { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
745    { (exit 1); exit 1; }; }
746 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
747 ac_env_build_alias_set=${build_alias+set}
748 ac_env_build_alias_value=$build_alias
749 ac_cv_env_build_alias_set=${build_alias+set}
750 ac_cv_env_build_alias_value=$build_alias
751 ac_env_host_alias_set=${host_alias+set}
752 ac_env_host_alias_value=$host_alias
753 ac_cv_env_host_alias_set=${host_alias+set}
754 ac_cv_env_host_alias_value=$host_alias
755 ac_env_target_alias_set=${target_alias+set}
756 ac_env_target_alias_value=$target_alias
757 ac_cv_env_target_alias_set=${target_alias+set}
758 ac_cv_env_target_alias_value=$target_alias
759 ac_env_CC_set=${CC+set}
760 ac_env_CC_value=$CC
761 ac_cv_env_CC_set=${CC+set}
762 ac_cv_env_CC_value=$CC
763 ac_env_CFLAGS_set=${CFLAGS+set}
764 ac_env_CFLAGS_value=$CFLAGS
765 ac_cv_env_CFLAGS_set=${CFLAGS+set}
766 ac_cv_env_CFLAGS_value=$CFLAGS
767 ac_env_LDFLAGS_set=${LDFLAGS+set}
768 ac_env_LDFLAGS_value=$LDFLAGS
769 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
770 ac_cv_env_LDFLAGS_value=$LDFLAGS
771 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
772 ac_env_CPPFLAGS_value=$CPPFLAGS
773 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
774 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
775 ac_env_CPP_set=${CPP+set}
776 ac_env_CPP_value=$CPP
777 ac_cv_env_CPP_set=${CPP+set}
778 ac_cv_env_CPP_value=$CPP
779
780 #
781 # Report the --help message.
782 #
783 if test "$ac_init_help" = "long"; then
784   # Omit some internal or obsolete options to make the list less imposing.
785   # This message is too long to be a string in the A/UX 3.1 sh.
786   cat <<_ACEOF
787 \`configure' configures this package to adapt to many kinds of systems.
788
789 Usage: $0 [OPTION]... [VAR=VALUE]...
790
791 To assign environment variables (e.g., CC, CFLAGS...), specify them as
792 VAR=VALUE.  See below for descriptions of some of the useful variables.
793
794 Defaults for the options are specified in brackets.
795
796 Configuration:
797   -h, --help              display this help and exit
798       --help=short        display options specific to this package
799       --help=recursive    display the short help of all the included packages
800   -V, --version           display version information and exit
801   -q, --quiet, --silent   do not print \`checking...' messages
802       --cache-file=FILE   cache test results in FILE [disabled]
803   -C, --config-cache      alias for \`--cache-file=config.cache'
804   -n, --no-create         do not create output files
805       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
806
807 _ACEOF
808
809   cat <<_ACEOF
810 Installation directories:
811   --prefix=PREFIX         install architecture-independent files in PREFIX
812                           [$ac_default_prefix]
813   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
814                           [PREFIX]
815
816 By default, \`make install' will install all the files in
817 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
818 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
819 for instance \`--prefix=\$HOME'.
820
821 For better control, use the options below.
822
823 Fine tuning of the installation directories:
824   --bindir=DIR           user executables [EPREFIX/bin]
825   --sbindir=DIR          system admin executables [EPREFIX/sbin]
826   --libexecdir=DIR       program executables [EPREFIX/libexec]
827   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
828   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
829   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
830   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
831   --libdir=DIR           object code libraries [EPREFIX/lib]
832   --includedir=DIR       C header files [PREFIX/include]
833   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
834   --infodir=DIR          info documentation [PREFIX/info]
835   --mandir=DIR           man documentation [PREFIX/man]
836 _ACEOF
837
838   cat <<\_ACEOF
839
840 Program names:
841   --program-prefix=PREFIX            prepend PREFIX to installed program names
842   --program-suffix=SUFFIX            append SUFFIX to installed program names
843   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
844
845 X features:
846   --x-includes=DIR    X include files are in DIR
847   --x-libraries=DIR   X library files are in DIR
848
849 System types:
850   --build=BUILD     configure for building on BUILD [guessed]
851   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
852   --target=TARGET   configure for building compilers for TARGET [HOST]
853 _ACEOF
854 fi
855
856 if test -n "$ac_init_help"; then
857
858   cat <<\_ACEOF
859
860 Optional Features:
861   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
862   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
863   --enable-maintainer-mode  enable make rules and dependencies not useful
864                           (and sometimes confusing) to the casual installer
865   --disable-dependency-tracking  speeds up one-time build
866   --enable-dependency-tracking   do not reject slow dependency extractors
867   --enable-targets        alternative target configurations
868   --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
869   --disable-gdbcli        disable command-line interface (CLI)
870   --disable-gdbmi         disable machine-interface (MI)
871   --enable-tui            enable full-screen terminal user interface (TUI)
872   --enable-gdbtk          enable gdbtk graphical user interface (GUI)
873   --enable-profiling      enable profiling of GDB
874   --disable-rpath         do not hardcode runtime library paths
875   --enable-werror    treat compile warnings as errors
876   --enable-build-warnings Enable build-time compiler warnings if gcc is used
877   --enable-gdb-build-warnings Enable GDB specific build-time compiler warnings if gcc is used
878   --enable-sim            Link gdb with simulator
879   --enable-multi-ice      build the multi-ice-gdb-server
880
881 Optional Packages:
882   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
883   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
884   --with-separate-debug-dir=path   Look for global separate debug info in this path LIBDIR/debug
885   --with-relocated-sources=PATH
886                           Automatically relocate this path for source files
887   --with-libunwind            Use libunwind frame unwinding support
888   --with-curses           use the curses library instead of the termcap
889                           library
890   --with-pkgversion=PKG   Use PKG in the version string in place of "GDB"
891   --with-bugurl=URL       Direct users to URL to report a bug
892   --with-libiconv-prefix=DIR  search for libiconv in DIR/include and DIR/lib
893   --with-system-readline  use installed readline library
894   --with-expat            include expat support (auto/yes/no)
895   --with-gnu-ld           assume the C compiler uses GNU ld default=no
896   --with-libexpat-prefix[=DIR]  search for libexpat in DIR/include and DIR/lib
897   --without-libexpat-prefix     don't search for libexpat in includedir and libdir
898   --with-python           include python support (auto/yes/no/<path>)
899   --without-included-regex don't use included regex; this is the default
900                           on systems with version 2 of the GNU C library
901                           (use with caution on other system)
902   --with-sysroot=DIR Search for usr/lib et al within DIR.
903   --with-system-gdbinit=file       Automatically load a system-wide gdbinit file
904   --with-tcl              directory containing tcl configuration (tclConfig.sh)
905   --with-tk               directory containing tk configuration (tkConfig.sh)
906   --with-x                use the X Window System
907
908 Some influential environment variables:
909   CC          C compiler command
910   CFLAGS      C compiler flags
911   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
912               nonstandard directory <lib dir>
913   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
914               headers in a nonstandard directory <include dir>
915   CPP         C preprocessor
916
917 Use these variables to override the choices made by `configure' or to help
918 it to find libraries and programs with nonstandard names/locations.
919
920 _ACEOF
921 fi
922
923 if test "$ac_init_help" = "recursive"; then
924   # If there are subdirs, report their specific --help.
925   ac_popdir=`pwd`
926   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
927     test -d $ac_dir || continue
928     ac_builddir=.
929
930 if test "$ac_dir" != .; then
931   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
932   # A "../" for each directory in $ac_dir_suffix.
933   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
934 else
935   ac_dir_suffix= ac_top_builddir=
936 fi
937
938 case $srcdir in
939   .)  # No --srcdir option.  We are building in place.
940     ac_srcdir=.
941     if test -z "$ac_top_builddir"; then
942        ac_top_srcdir=.
943     else
944        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
945     fi ;;
946   [\\/]* | ?:[\\/]* )  # Absolute path.
947     ac_srcdir=$srcdir$ac_dir_suffix;
948     ac_top_srcdir=$srcdir ;;
949   *) # Relative path.
950     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
951     ac_top_srcdir=$ac_top_builddir$srcdir ;;
952 esac
953
954 # Do not use `cd foo && pwd` to compute absolute paths, because
955 # the directories may not exist.
956 case `pwd` in
957 .) ac_abs_builddir="$ac_dir";;
958 *)
959   case "$ac_dir" in
960   .) ac_abs_builddir=`pwd`;;
961   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
962   *) ac_abs_builddir=`pwd`/"$ac_dir";;
963   esac;;
964 esac
965 case $ac_abs_builddir in
966 .) ac_abs_top_builddir=${ac_top_builddir}.;;
967 *)
968   case ${ac_top_builddir}. in
969   .) ac_abs_top_builddir=$ac_abs_builddir;;
970   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
971   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
972   esac;;
973 esac
974 case $ac_abs_builddir in
975 .) ac_abs_srcdir=$ac_srcdir;;
976 *)
977   case $ac_srcdir in
978   .) ac_abs_srcdir=$ac_abs_builddir;;
979   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
980   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
981   esac;;
982 esac
983 case $ac_abs_builddir in
984 .) ac_abs_top_srcdir=$ac_top_srcdir;;
985 *)
986   case $ac_top_srcdir in
987   .) ac_abs_top_srcdir=$ac_abs_builddir;;
988   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
989   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
990   esac;;
991 esac
992
993     cd $ac_dir
994     # Check for guested configure; otherwise get Cygnus style configure.
995     if test -f $ac_srcdir/configure.gnu; then
996       echo
997       $SHELL $ac_srcdir/configure.gnu  --help=recursive
998     elif test -f $ac_srcdir/configure; then
999       echo
1000       $SHELL $ac_srcdir/configure  --help=recursive
1001     elif test -f $ac_srcdir/configure.ac ||
1002            test -f $ac_srcdir/configure.in; then
1003       echo
1004       $ac_configure --help
1005     else
1006       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1007     fi
1008     cd $ac_popdir
1009   done
1010 fi
1011
1012 test -n "$ac_init_help" && exit 0
1013 if $ac_init_version; then
1014   cat <<\_ACEOF
1015
1016 Copyright (C) 2003 Free Software Foundation, Inc.
1017 This configure script is free software; the Free Software Foundation
1018 gives unlimited permission to copy, distribute and modify it.
1019 _ACEOF
1020   exit 0
1021 fi
1022 exec 5>config.log
1023 cat >&5 <<_ACEOF
1024 This file contains any messages produced by compilers while
1025 running configure, to aid debugging if configure makes a mistake.
1026
1027 It was created by $as_me, which was
1028 generated by GNU Autoconf 2.59.  Invocation command line was
1029
1030   $ $0 $@
1031
1032 _ACEOF
1033 {
1034 cat <<_ASUNAME
1035 ## --------- ##
1036 ## Platform. ##
1037 ## --------- ##
1038
1039 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1040 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1041 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1042 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1043 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1044
1045 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1046 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1047
1048 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1049 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1050 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1051 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1052 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1053 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1054 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1055
1056 _ASUNAME
1057
1058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1059 for as_dir in $PATH
1060 do
1061   IFS=$as_save_IFS
1062   test -z "$as_dir" && as_dir=.
1063   echo "PATH: $as_dir"
1064 done
1065
1066 } >&5
1067
1068 cat >&5 <<_ACEOF
1069
1070
1071 ## ----------- ##
1072 ## Core tests. ##
1073 ## ----------- ##
1074
1075 _ACEOF
1076
1077
1078 # Keep a trace of the command line.
1079 # Strip out --no-create and --no-recursion so they do not pile up.
1080 # Strip out --silent because we don't want to record it for future runs.
1081 # Also quote any args containing shell meta-characters.
1082 # Make two passes to allow for proper duplicate-argument suppression.
1083 ac_configure_args=
1084 ac_configure_args0=
1085 ac_configure_args1=
1086 ac_sep=
1087 ac_must_keep_next=false
1088 for ac_pass in 1 2
1089 do
1090   for ac_arg
1091   do
1092     case $ac_arg in
1093     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1094     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1095     | -silent | --silent | --silen | --sile | --sil)
1096       continue ;;
1097     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1098       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1099     esac
1100     case $ac_pass in
1101     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1102     2)
1103       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1104       if test $ac_must_keep_next = true; then
1105         ac_must_keep_next=false # Got value, back to normal.
1106       else
1107         case $ac_arg in
1108           *=* | --config-cache | -C | -disable-* | --disable-* \
1109           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1110           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1111           | -with-* | --with-* | -without-* | --without-* | --x)
1112             case "$ac_configure_args0 " in
1113               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1114             esac
1115             ;;
1116           -* ) ac_must_keep_next=true ;;
1117         esac
1118       fi
1119       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1120       # Get rid of the leading space.
1121       ac_sep=" "
1122       ;;
1123     esac
1124   done
1125 done
1126 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1127 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1128
1129 # When interrupted or exit'd, cleanup temporary files, and complete
1130 # config.log.  We remove comments because anyway the quotes in there
1131 # would cause problems or look ugly.
1132 # WARNING: Be sure not to use single quotes in there, as some shells,
1133 # such as our DU 5.0 friend, will then `close' the trap.
1134 trap 'exit_status=$?
1135   # Save into config.log some information that might help in debugging.
1136   {
1137     echo
1138
1139     cat <<\_ASBOX
1140 ## ---------------- ##
1141 ## Cache variables. ##
1142 ## ---------------- ##
1143 _ASBOX
1144     echo
1145     # The following way of writing the cache mishandles newlines in values,
1146 {
1147   (set) 2>&1 |
1148     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1149     *ac_space=\ *)
1150       sed -n \
1151         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1152           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1153       ;;
1154     *)
1155       sed -n \
1156         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1157       ;;
1158     esac;
1159 }
1160     echo
1161
1162     cat <<\_ASBOX
1163 ## ----------------- ##
1164 ## Output variables. ##
1165 ## ----------------- ##
1166 _ASBOX
1167     echo
1168     for ac_var in $ac_subst_vars
1169     do
1170       eval ac_val=$`echo $ac_var`
1171       echo "$ac_var='"'"'$ac_val'"'"'"
1172     done | sort
1173     echo
1174
1175     if test -n "$ac_subst_files"; then
1176       cat <<\_ASBOX
1177 ## ------------- ##
1178 ## Output files. ##
1179 ## ------------- ##
1180 _ASBOX
1181       echo
1182       for ac_var in $ac_subst_files
1183       do
1184         eval ac_val=$`echo $ac_var`
1185         echo "$ac_var='"'"'$ac_val'"'"'"
1186       done | sort
1187       echo
1188     fi
1189
1190     if test -s confdefs.h; then
1191       cat <<\_ASBOX
1192 ## ----------- ##
1193 ## confdefs.h. ##
1194 ## ----------- ##
1195 _ASBOX
1196       echo
1197       sed "/^$/d" confdefs.h | sort
1198       echo
1199     fi
1200     test "$ac_signal" != 0 &&
1201       echo "$as_me: caught signal $ac_signal"
1202     echo "$as_me: exit $exit_status"
1203   } >&5
1204   rm -f core *.core &&
1205   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1206     exit $exit_status
1207      ' 0
1208 for ac_signal in 1 2 13 15; do
1209   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1210 done
1211 ac_signal=0
1212
1213 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1214 rm -rf conftest* confdefs.h
1215 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1216 echo >confdefs.h
1217
1218 # Predefined preprocessor variables.
1219
1220 cat >>confdefs.h <<_ACEOF
1221 #define PACKAGE_NAME "$PACKAGE_NAME"
1222 _ACEOF
1223
1224
1225 cat >>confdefs.h <<_ACEOF
1226 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1227 _ACEOF
1228
1229
1230 cat >>confdefs.h <<_ACEOF
1231 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1232 _ACEOF
1233
1234
1235 cat >>confdefs.h <<_ACEOF
1236 #define PACKAGE_STRING "$PACKAGE_STRING"
1237 _ACEOF
1238
1239
1240 cat >>confdefs.h <<_ACEOF
1241 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1242 _ACEOF
1243
1244
1245 # Let the site file select an alternate cache file if it wants to.
1246 # Prefer explicitly selected file to automatically selected ones.
1247 if test -z "$CONFIG_SITE"; then
1248   if test "x$prefix" != xNONE; then
1249     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1250   else
1251     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1252   fi
1253 fi
1254 for ac_site_file in $CONFIG_SITE; do
1255   if test -r "$ac_site_file"; then
1256     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1257 echo "$as_me: loading site script $ac_site_file" >&6;}
1258     sed 's/^/| /' "$ac_site_file" >&5
1259     . "$ac_site_file"
1260   fi
1261 done
1262
1263 if test -r "$cache_file"; then
1264   # Some versions of bash will fail to source /dev/null (special
1265   # files actually), so we avoid doing that.
1266   if test -f "$cache_file"; then
1267     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1268 echo "$as_me: loading cache $cache_file" >&6;}
1269     case $cache_file in
1270       [\\/]* | ?:[\\/]* ) . $cache_file;;
1271       *)                      . ./$cache_file;;
1272     esac
1273   fi
1274 else
1275   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1276 echo "$as_me: creating cache $cache_file" >&6;}
1277   >$cache_file
1278 fi
1279
1280 # Check that the precious variables saved in the cache have kept the same
1281 # value.
1282 ac_cache_corrupted=false
1283 for ac_var in `(set) 2>&1 |
1284                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1285   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1286   eval ac_new_set=\$ac_env_${ac_var}_set
1287   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1288   eval ac_new_val="\$ac_env_${ac_var}_value"
1289   case $ac_old_set,$ac_new_set in
1290     set,)
1291       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1292 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1293       ac_cache_corrupted=: ;;
1294     ,set)
1295       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1296 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1297       ac_cache_corrupted=: ;;
1298     ,);;
1299     *)
1300       if test "x$ac_old_val" != "x$ac_new_val"; then
1301         # differences in whitespace do not lead to failure.
1302         ac_old_val_w=`echo x $ac_old_val`
1303         ac_new_val_w=`echo x $ac_new_val`
1304         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1305           { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1306 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1307           ac_cache_corrupted=:
1308         else
1309           { echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1310 echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1311           eval $ac_var=\$ac_old_val
1312         fi
1313         { echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1314 echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1315         { echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1316 echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1317       fi;;
1318   esac
1319   # Pass precious variables to config.status.
1320   if test "$ac_new_set" = set; then
1321     case $ac_new_val in
1322     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1323       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1324     *) ac_arg=$ac_var=$ac_new_val ;;
1325     esac
1326     case " $ac_configure_args " in
1327       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1328       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1329     esac
1330   fi
1331 done
1332 if $ac_cache_corrupted; then
1333   { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1334 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1335   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1336 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1337   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1338 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1339    { (exit 1); exit 1; }; }
1340 fi
1341
1342 ac_ext=c
1343 ac_cpp='$CPP $CPPFLAGS'
1344 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1345 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1346 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1347
1348
1349 gl_header_list="$gl_header_list stdint.h"
1350 gl_header_list="$gl_header_list wchar.h"
1351 gl_header_list="$gl_header_list string.h"
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372           ac_config_headers="$ac_config_headers config.h:config.in"
1373
1374 echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
1375 echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6
1376     # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1377 if test "${enable_maintainer_mode+set}" = set; then
1378   enableval="$enable_maintainer_mode"
1379   USE_MAINTAINER_MODE=$enableval
1380 else
1381   USE_MAINTAINER_MODE=no
1382 fi;
1383   echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
1384 echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6
1385
1386
1387 if test $USE_MAINTAINER_MODE = yes; then
1388   MAINTAINER_MODE_TRUE=
1389   MAINTAINER_MODE_FALSE='#'
1390 else
1391   MAINTAINER_MODE_TRUE='#'
1392   MAINTAINER_MODE_FALSE=
1393 fi
1394
1395   MAINT=$MAINTAINER_MODE_TRUE
1396
1397
1398
1399 ac_ext=c
1400 ac_cpp='$CPP $CPPFLAGS'
1401 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1402 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1403 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1404 if test -n "$ac_tool_prefix"; then
1405   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1406 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1407 echo "$as_me:$LINENO: checking for $ac_word" >&5
1408 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1409 if test "${ac_cv_prog_CC+set}" = set; then
1410   echo $ECHO_N "(cached) $ECHO_C" >&6
1411 else
1412   if test -n "$CC"; then
1413   ac_cv_prog_CC="$CC" # Let the user override the test.
1414 else
1415 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1416 for as_dir in $PATH
1417 do
1418   IFS=$as_save_IFS
1419   test -z "$as_dir" && as_dir=.
1420   for ac_exec_ext in '' $ac_executable_extensions; do
1421   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1422     ac_cv_prog_CC="${ac_tool_prefix}gcc"
1423     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1424     break 2
1425   fi
1426 done
1427 done
1428
1429 fi
1430 fi
1431 CC=$ac_cv_prog_CC
1432 if test -n "$CC"; then
1433   echo "$as_me:$LINENO: result: $CC" >&5
1434 echo "${ECHO_T}$CC" >&6
1435 else
1436   echo "$as_me:$LINENO: result: no" >&5
1437 echo "${ECHO_T}no" >&6
1438 fi
1439
1440 fi
1441 if test -z "$ac_cv_prog_CC"; then
1442   ac_ct_CC=$CC
1443   # Extract the first word of "gcc", so it can be a program name with args.
1444 set dummy gcc; ac_word=$2
1445 echo "$as_me:$LINENO: checking for $ac_word" >&5
1446 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1447 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1448   echo $ECHO_N "(cached) $ECHO_C" >&6
1449 else
1450   if test -n "$ac_ct_CC"; then
1451   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1452 else
1453 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1454 for as_dir in $PATH
1455 do
1456   IFS=$as_save_IFS
1457   test -z "$as_dir" && as_dir=.
1458   for ac_exec_ext in '' $ac_executable_extensions; do
1459   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1460     ac_cv_prog_ac_ct_CC="gcc"
1461     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1462     break 2
1463   fi
1464 done
1465 done
1466
1467 fi
1468 fi
1469 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1470 if test -n "$ac_ct_CC"; then
1471   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1472 echo "${ECHO_T}$ac_ct_CC" >&6
1473 else
1474   echo "$as_me:$LINENO: result: no" >&5
1475 echo "${ECHO_T}no" >&6
1476 fi
1477
1478   CC=$ac_ct_CC
1479 else
1480   CC="$ac_cv_prog_CC"
1481 fi
1482
1483 if test -z "$CC"; then
1484   if test -n "$ac_tool_prefix"; then
1485   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1486 set dummy ${ac_tool_prefix}cc; ac_word=$2
1487 echo "$as_me:$LINENO: checking for $ac_word" >&5
1488 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1489 if test "${ac_cv_prog_CC+set}" = set; then
1490   echo $ECHO_N "(cached) $ECHO_C" >&6
1491 else
1492   if test -n "$CC"; then
1493   ac_cv_prog_CC="$CC" # Let the user override the test.
1494 else
1495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1496 for as_dir in $PATH
1497 do
1498   IFS=$as_save_IFS
1499   test -z "$as_dir" && as_dir=.
1500   for ac_exec_ext in '' $ac_executable_extensions; do
1501   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1502     ac_cv_prog_CC="${ac_tool_prefix}cc"
1503     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1504     break 2
1505   fi
1506 done
1507 done
1508
1509 fi
1510 fi
1511 CC=$ac_cv_prog_CC
1512 if test -n "$CC"; then
1513   echo "$as_me:$LINENO: result: $CC" >&5
1514 echo "${ECHO_T}$CC" >&6
1515 else
1516   echo "$as_me:$LINENO: result: no" >&5
1517 echo "${ECHO_T}no" >&6
1518 fi
1519
1520 fi
1521 if test -z "$ac_cv_prog_CC"; then
1522   ac_ct_CC=$CC
1523   # Extract the first word of "cc", so it can be a program name with args.
1524 set dummy cc; ac_word=$2
1525 echo "$as_me:$LINENO: checking for $ac_word" >&5
1526 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1527 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1528   echo $ECHO_N "(cached) $ECHO_C" >&6
1529 else
1530   if test -n "$ac_ct_CC"; then
1531   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1532 else
1533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1534 for as_dir in $PATH
1535 do
1536   IFS=$as_save_IFS
1537   test -z "$as_dir" && as_dir=.
1538   for ac_exec_ext in '' $ac_executable_extensions; do
1539   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1540     ac_cv_prog_ac_ct_CC="cc"
1541     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1542     break 2
1543   fi
1544 done
1545 done
1546
1547 fi
1548 fi
1549 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1550 if test -n "$ac_ct_CC"; then
1551   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1552 echo "${ECHO_T}$ac_ct_CC" >&6
1553 else
1554   echo "$as_me:$LINENO: result: no" >&5
1555 echo "${ECHO_T}no" >&6
1556 fi
1557
1558   CC=$ac_ct_CC
1559 else
1560   CC="$ac_cv_prog_CC"
1561 fi
1562
1563 fi
1564 if test -z "$CC"; then
1565   # Extract the first word of "cc", so it can be a program name with args.
1566 set dummy cc; ac_word=$2
1567 echo "$as_me:$LINENO: checking for $ac_word" >&5
1568 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1569 if test "${ac_cv_prog_CC+set}" = set; then
1570   echo $ECHO_N "(cached) $ECHO_C" >&6
1571 else
1572   if test -n "$CC"; then
1573   ac_cv_prog_CC="$CC" # Let the user override the test.
1574 else
1575   ac_prog_rejected=no
1576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1577 for as_dir in $PATH
1578 do
1579   IFS=$as_save_IFS
1580   test -z "$as_dir" && as_dir=.
1581   for ac_exec_ext in '' $ac_executable_extensions; do
1582   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1583     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1584        ac_prog_rejected=yes
1585        continue
1586      fi
1587     ac_cv_prog_CC="cc"
1588     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1589     break 2
1590   fi
1591 done
1592 done
1593
1594 if test $ac_prog_rejected = yes; then
1595   # We found a bogon in the path, so make sure we never use it.
1596   set dummy $ac_cv_prog_CC
1597   shift
1598   if test $# != 0; then
1599     # We chose a different compiler from the bogus one.
1600     # However, it has the same basename, so the bogon will be chosen
1601     # first if we set CC to just the basename; use the full file name.
1602     shift
1603     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
1604   fi
1605 fi
1606 fi
1607 fi
1608 CC=$ac_cv_prog_CC
1609 if test -n "$CC"; then
1610   echo "$as_me:$LINENO: result: $CC" >&5
1611 echo "${ECHO_T}$CC" >&6
1612 else
1613   echo "$as_me:$LINENO: result: no" >&5
1614 echo "${ECHO_T}no" >&6
1615 fi
1616
1617 fi
1618 if test -z "$CC"; then
1619   if test -n "$ac_tool_prefix"; then
1620   for ac_prog in cl
1621   do
1622     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1623 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1624 echo "$as_me:$LINENO: checking for $ac_word" >&5
1625 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1626 if test "${ac_cv_prog_CC+set}" = set; then
1627   echo $ECHO_N "(cached) $ECHO_C" >&6
1628 else
1629   if test -n "$CC"; then
1630   ac_cv_prog_CC="$CC" # Let the user override the test.
1631 else
1632 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1633 for as_dir in $PATH
1634 do
1635   IFS=$as_save_IFS
1636   test -z "$as_dir" && as_dir=.
1637   for ac_exec_ext in '' $ac_executable_extensions; do
1638   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1639     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1640     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1641     break 2
1642   fi
1643 done
1644 done
1645
1646 fi
1647 fi
1648 CC=$ac_cv_prog_CC
1649 if test -n "$CC"; then
1650   echo "$as_me:$LINENO: result: $CC" >&5
1651 echo "${ECHO_T}$CC" >&6
1652 else
1653   echo "$as_me:$LINENO: result: no" >&5
1654 echo "${ECHO_T}no" >&6
1655 fi
1656
1657     test -n "$CC" && break
1658   done
1659 fi
1660 if test -z "$CC"; then
1661   ac_ct_CC=$CC
1662   for ac_prog in cl
1663 do
1664   # Extract the first word of "$ac_prog", so it can be a program name with args.
1665 set dummy $ac_prog; ac_word=$2
1666 echo "$as_me:$LINENO: checking for $ac_word" >&5
1667 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1668 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1669   echo $ECHO_N "(cached) $ECHO_C" >&6
1670 else
1671   if test -n "$ac_ct_CC"; then
1672   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1673 else
1674 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1675 for as_dir in $PATH
1676 do
1677   IFS=$as_save_IFS
1678   test -z "$as_dir" && as_dir=.
1679   for ac_exec_ext in '' $ac_executable_extensions; do
1680   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1681     ac_cv_prog_ac_ct_CC="$ac_prog"
1682     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1683     break 2
1684   fi
1685 done
1686 done
1687
1688 fi
1689 fi
1690 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1691 if test -n "$ac_ct_CC"; then
1692   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1693 echo "${ECHO_T}$ac_ct_CC" >&6
1694 else
1695   echo "$as_me:$LINENO: result: no" >&5
1696 echo "${ECHO_T}no" >&6
1697 fi
1698
1699   test -n "$ac_ct_CC" && break
1700 done
1701
1702   CC=$ac_ct_CC
1703 fi
1704
1705 fi
1706
1707
1708 test -z "$CC" && { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1709 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1710 { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
1711 See \`config.log' for more details." >&5
1712 echo "$as_me: error: no acceptable C compiler found in \$PATH
1713 See \`config.log' for more details." >&2;}
1714    { (exit 1); exit 1; }; }; }
1715
1716 # Provide some information about the compiler.
1717 echo "$as_me:$LINENO:" \
1718      "checking for C compiler version" >&5
1719 ac_compiler=`set X $ac_compile; echo $2`
1720 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1721   (eval $ac_compiler --version </dev/null >&5) 2>&5
1722   ac_status=$?
1723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1724   (exit $ac_status); }
1725 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1726   (eval $ac_compiler -v </dev/null >&5) 2>&5
1727   ac_status=$?
1728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1729   (exit $ac_status); }
1730 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1731   (eval $ac_compiler -V </dev/null >&5) 2>&5
1732   ac_status=$?
1733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1734   (exit $ac_status); }
1735
1736 cat >conftest.$ac_ext <<_ACEOF
1737 /* confdefs.h.  */
1738 _ACEOF
1739 cat confdefs.h >>conftest.$ac_ext
1740 cat >>conftest.$ac_ext <<_ACEOF
1741 /* end confdefs.h.  */
1742
1743 int
1744 main ()
1745 {
1746
1747   ;
1748   return 0;
1749 }
1750 _ACEOF
1751 ac_clean_files_save=$ac_clean_files
1752 ac_clean_files="$ac_clean_files a.out a.exe b.out"
1753 # Try to create an executable without -o first, disregard a.out.
1754 # It will help us diagnose broken compilers, and finding out an intuition
1755 # of exeext.
1756 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
1757 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
1758 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1759 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1760   (eval $ac_link_default) 2>&5
1761   ac_status=$?
1762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1763   (exit $ac_status); }; then
1764   # Find the output, starting from the most likely.  This scheme is
1765 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1766 # resort.
1767
1768 # Be careful to initialize this variable, since it used to be cached.
1769 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1770 ac_cv_exeext=
1771 # b.out is created by i960 compilers.
1772 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1773 do
1774   test -f "$ac_file" || continue
1775   case $ac_file in
1776     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
1777         ;;
1778     conftest.$ac_ext )
1779         # This is the source file.
1780         ;;
1781     [ab].out )
1782         # We found the default executable, but exeext='' is most
1783         # certainly right.
1784         break;;
1785     *.* )
1786         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1787         # FIXME: I believe we export ac_cv_exeext for Libtool,
1788         # but it would be cool to find out if it's true.  Does anybody
1789         # maintain Libtool? --akim.
1790         export ac_cv_exeext
1791         break;;
1792     * )
1793         break;;
1794   esac
1795 done
1796 else
1797   echo "$as_me: failed program was:" >&5
1798 sed 's/^/| /' conftest.$ac_ext >&5
1799
1800 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1801 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1802 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
1803 See \`config.log' for more details." >&5
1804 echo "$as_me: error: C compiler cannot create executables
1805 See \`config.log' for more details." >&2;}
1806    { (exit 77); exit 77; }; }; }
1807 fi
1808
1809 ac_exeext=$ac_cv_exeext
1810 echo "$as_me:$LINENO: result: $ac_file" >&5
1811 echo "${ECHO_T}$ac_file" >&6
1812
1813 # Check the compiler produces executables we can run.  If not, either
1814 # the compiler is broken, or we cross compile.
1815 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
1816 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1817 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1818 # If not cross compiling, check that we can run a simple program.
1819 if test "$cross_compiling" != yes; then
1820   if { ac_try='./$ac_file'
1821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1822   (eval $ac_try) 2>&5
1823   ac_status=$?
1824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1825   (exit $ac_status); }; }; then
1826     cross_compiling=no
1827   else
1828     if test "$cross_compiling" = maybe; then
1829         cross_compiling=yes
1830     else
1831         { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1832 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1833 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
1834 If you meant to cross compile, use \`--host'.
1835 See \`config.log' for more details." >&5
1836 echo "$as_me: error: cannot run C compiled programs.
1837 If you meant to cross compile, use \`--host'.
1838 See \`config.log' for more details." >&2;}
1839    { (exit 1); exit 1; }; }; }
1840     fi
1841   fi
1842 fi
1843 echo "$as_me:$LINENO: result: yes" >&5
1844 echo "${ECHO_T}yes" >&6
1845
1846 rm -f a.out a.exe conftest$ac_cv_exeext b.out
1847 ac_clean_files=$ac_clean_files_save
1848 # Check the compiler produces executables we can run.  If not, either
1849 # the compiler is broken, or we cross compile.
1850 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1851 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1852 echo "$as_me:$LINENO: result: $cross_compiling" >&5
1853 echo "${ECHO_T}$cross_compiling" >&6
1854
1855 echo "$as_me:$LINENO: checking for suffix of executables" >&5
1856 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1857 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1858   (eval $ac_link) 2>&5
1859   ac_status=$?
1860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1861   (exit $ac_status); }; then
1862   # If both `conftest.exe' and `conftest' are `present' (well, observable)
1863 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1864 # work properly (i.e., refer to `conftest.exe'), while it won't with
1865 # `rm'.
1866 for ac_file in conftest.exe conftest conftest.*; do
1867   test -f "$ac_file" || continue
1868   case $ac_file in
1869     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
1870     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1871           export ac_cv_exeext
1872           break;;
1873     * ) break;;
1874   esac
1875 done
1876 else
1877   { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1878 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1879 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
1880 See \`config.log' for more details." >&5
1881 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
1882 See \`config.log' for more details." >&2;}
1883    { (exit 1); exit 1; }; }; }
1884 fi
1885
1886 rm -f conftest$ac_cv_exeext
1887 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1888 echo "${ECHO_T}$ac_cv_exeext" >&6
1889
1890 rm -f conftest.$ac_ext
1891 EXEEXT=$ac_cv_exeext
1892 ac_exeext=$EXEEXT
1893 echo "$as_me:$LINENO: checking for suffix of object files" >&5
1894 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
1895 if test "${ac_cv_objext+set}" = set; then
1896   echo $ECHO_N "(cached) $ECHO_C" >&6
1897 else
1898   cat >conftest.$ac_ext <<_ACEOF
1899 /* confdefs.h.  */
1900 _ACEOF
1901 cat confdefs.h >>conftest.$ac_ext
1902 cat >>conftest.$ac_ext <<_ACEOF
1903 /* end confdefs.h.  */
1904
1905 int
1906 main ()
1907 {
1908
1909   ;
1910   return 0;
1911 }
1912 _ACEOF
1913 rm -f conftest.o conftest.obj
1914 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1915   (eval $ac_compile) 2>&5
1916   ac_status=$?
1917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1918   (exit $ac_status); }; then
1919   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1920   case $ac_file in
1921     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
1922     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1923        break;;
1924   esac
1925 done
1926 else
1927   echo "$as_me: failed program was:" >&5
1928 sed 's/^/| /' conftest.$ac_ext >&5
1929
1930 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1931 echo "$as_me: error: in \`$ac_pwd':" >&2;}
1932 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
1933 See \`config.log' for more details." >&5
1934 echo "$as_me: error: cannot compute suffix of object files: cannot compile
1935 See \`config.log' for more details." >&2;}
1936    { (exit 1); exit 1; }; }; }
1937 fi
1938
1939 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1940 fi
1941 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
1942 echo "${ECHO_T}$ac_cv_objext" >&6
1943 OBJEXT=$ac_cv_objext
1944 ac_objext=$OBJEXT
1945 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
1946 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1947 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1948   echo $ECHO_N "(cached) $ECHO_C" >&6
1949 else
1950   cat >conftest.$ac_ext <<_ACEOF
1951 /* confdefs.h.  */
1952 _ACEOF
1953 cat confdefs.h >>conftest.$ac_ext
1954 cat >>conftest.$ac_ext <<_ACEOF
1955 /* end confdefs.h.  */
1956
1957 int
1958 main ()
1959 {
1960 #ifndef __GNUC__
1961        choke me
1962 #endif
1963
1964   ;
1965   return 0;
1966 }
1967 _ACEOF
1968 rm -f conftest.$ac_objext
1969 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
1970   (eval $ac_compile) 2>conftest.er1
1971   ac_status=$?
1972   grep -v '^ *+' conftest.er1 >conftest.err
1973   rm -f conftest.er1
1974   cat conftest.err >&5
1975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1976   (exit $ac_status); } &&
1977          { ac_try='test -z "$ac_c_werror_flag"
1978                          || test ! -s conftest.err'
1979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1980   (eval $ac_try) 2>&5
1981   ac_status=$?
1982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1983   (exit $ac_status); }; } &&
1984          { ac_try='test -s conftest.$ac_objext'
1985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1986   (eval $ac_try) 2>&5
1987   ac_status=$?
1988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1989   (exit $ac_status); }; }; then
1990   ac_compiler_gnu=yes
1991 else
1992   echo "$as_me: failed program was:" >&5
1993 sed 's/^/| /' conftest.$ac_ext >&5
1994
1995 ac_compiler_gnu=no
1996 fi
1997 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1998 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1999
2000 fi
2001 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2002 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2003 GCC=`test $ac_compiler_gnu = yes && echo yes`
2004 ac_test_CFLAGS=${CFLAGS+set}
2005 ac_save_CFLAGS=$CFLAGS
2006 CFLAGS="-g"
2007 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2008 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2009 if test "${ac_cv_prog_cc_g+set}" = set; then
2010   echo $ECHO_N "(cached) $ECHO_C" >&6
2011 else
2012   cat >conftest.$ac_ext <<_ACEOF
2013 /* confdefs.h.  */
2014 _ACEOF
2015 cat confdefs.h >>conftest.$ac_ext
2016 cat >>conftest.$ac_ext <<_ACEOF
2017 /* end confdefs.h.  */
2018
2019 int
2020 main ()
2021 {
2022
2023   ;
2024   return 0;
2025 }
2026 _ACEOF
2027 rm -f conftest.$ac_objext
2028 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2029   (eval $ac_compile) 2>conftest.er1
2030   ac_status=$?
2031   grep -v '^ *+' conftest.er1 >conftest.err
2032   rm -f conftest.er1
2033   cat conftest.err >&5
2034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2035   (exit $ac_status); } &&
2036          { ac_try='test -z "$ac_c_werror_flag"
2037                          || test ! -s conftest.err'
2038   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2039   (eval $ac_try) 2>&5
2040   ac_status=$?
2041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2042   (exit $ac_status); }; } &&
2043          { ac_try='test -s conftest.$ac_objext'
2044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2045   (eval $ac_try) 2>&5
2046   ac_status=$?
2047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2048   (exit $ac_status); }; }; then
2049   ac_cv_prog_cc_g=yes
2050 else
2051   echo "$as_me: failed program was:" >&5
2052 sed 's/^/| /' conftest.$ac_ext >&5
2053
2054 ac_cv_prog_cc_g=no
2055 fi
2056 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2057 fi
2058 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2059 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2060 if test "$ac_test_CFLAGS" = set; then
2061   CFLAGS=$ac_save_CFLAGS
2062 elif test $ac_cv_prog_cc_g = yes; then
2063   if test "$GCC" = yes; then
2064     CFLAGS="-g -O2"
2065   else
2066     CFLAGS="-g"
2067   fi
2068 else
2069   if test "$GCC" = yes; then
2070     CFLAGS="-O2"
2071   else
2072     CFLAGS=
2073   fi
2074 fi
2075 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2076 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2077 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2078   echo $ECHO_N "(cached) $ECHO_C" >&6
2079 else
2080   ac_cv_prog_cc_stdc=no
2081 ac_save_CC=$CC
2082 cat >conftest.$ac_ext <<_ACEOF
2083 /* confdefs.h.  */
2084 _ACEOF
2085 cat confdefs.h >>conftest.$ac_ext
2086 cat >>conftest.$ac_ext <<_ACEOF
2087 /* end confdefs.h.  */
2088 #include <stdarg.h>
2089 #include <stdio.h>
2090 #include <sys/types.h>
2091 #include <sys/stat.h>
2092 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2093 struct buf { int x; };
2094 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2095 static char *e (p, i)
2096      char **p;
2097      int i;
2098 {
2099   return p[i];
2100 }
2101 static char *f (char * (*g) (char **, int), char **p, ...)
2102 {
2103   char *s;
2104   va_list v;
2105   va_start (v,p);
2106   s = g (p, va_arg (v,int));
2107   va_end (v);
2108   return s;
2109 }
2110
2111 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2112    function prototypes and stuff, but not '\xHH' hex character constants.
2113    These don't provoke an error unfortunately, instead are silently treated
2114    as 'x'.  The following induces an error, until -std1 is added to get
2115    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2116    array size at least.  It's necessary to write '\x00'==0 to get something
2117    that's true only with -std1.  */
2118 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2119
2120 int test (int i, double x);
2121 struct s1 {int (*f) (int a);};
2122 struct s2 {int (*f) (double a);};
2123 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2124 int argc;
2125 char **argv;
2126 int
2127 main ()
2128 {
2129 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2130   ;
2131   return 0;
2132 }
2133 _ACEOF
2134 # Don't try gcc -ansi; that turns off useful extensions and
2135 # breaks some systems' header files.
2136 # AIX                   -qlanglvl=ansi
2137 # Ultrix and OSF/1      -std1
2138 # HP-UX 10.20 and later -Ae
2139 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2140 # SVR4                  -Xc -D__EXTENSIONS__
2141 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2142 do
2143   CC="$ac_save_CC $ac_arg"
2144   rm -f conftest.$ac_objext
2145 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2146   (eval $ac_compile) 2>conftest.er1
2147   ac_status=$?
2148   grep -v '^ *+' conftest.er1 >conftest.err
2149   rm -f conftest.er1
2150   cat conftest.err >&5
2151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2152   (exit $ac_status); } &&
2153          { ac_try='test -z "$ac_c_werror_flag"
2154                          || test ! -s conftest.err'
2155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2156   (eval $ac_try) 2>&5
2157   ac_status=$?
2158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2159   (exit $ac_status); }; } &&
2160          { ac_try='test -s conftest.$ac_objext'
2161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2162   (eval $ac_try) 2>&5
2163   ac_status=$?
2164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2165   (exit $ac_status); }; }; then
2166   ac_cv_prog_cc_stdc=$ac_arg
2167 break
2168 else
2169   echo "$as_me: failed program was:" >&5
2170 sed 's/^/| /' conftest.$ac_ext >&5
2171
2172 fi
2173 rm -f conftest.err conftest.$ac_objext
2174 done
2175 rm -f conftest.$ac_ext conftest.$ac_objext
2176 CC=$ac_save_CC
2177
2178 fi
2179
2180 case "x$ac_cv_prog_cc_stdc" in
2181   x|xno)
2182     echo "$as_me:$LINENO: result: none needed" >&5
2183 echo "${ECHO_T}none needed" >&6 ;;
2184   *)
2185     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2186 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2187     CC="$CC $ac_cv_prog_cc_stdc" ;;
2188 esac
2189
2190 # Some people use a C++ compiler to compile C.  Since we use `exit',
2191 # in C++ we need to declare it.  In case someone uses the same compiler
2192 # for both compiling C and C++ we need to have the C++ compiler decide
2193 # the declaration of exit, since it's the most demanding environment.
2194 cat >conftest.$ac_ext <<_ACEOF
2195 #ifndef __cplusplus
2196   choke me
2197 #endif
2198 _ACEOF
2199 rm -f conftest.$ac_objext
2200 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2201   (eval $ac_compile) 2>conftest.er1
2202   ac_status=$?
2203   grep -v '^ *+' conftest.er1 >conftest.err
2204   rm -f conftest.er1
2205   cat conftest.err >&5
2206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2207   (exit $ac_status); } &&
2208          { ac_try='test -z "$ac_c_werror_flag"
2209                          || test ! -s conftest.err'
2210   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2211   (eval $ac_try) 2>&5
2212   ac_status=$?
2213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2214   (exit $ac_status); }; } &&
2215          { ac_try='test -s conftest.$ac_objext'
2216   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2217   (eval $ac_try) 2>&5
2218   ac_status=$?
2219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2220   (exit $ac_status); }; }; then
2221   for ac_declaration in \
2222    '' \
2223    'extern "C" void std::exit (int) throw (); using std::exit;' \
2224    'extern "C" void std::exit (int); using std::exit;' \
2225    'extern "C" void exit (int) throw ();' \
2226    'extern "C" void exit (int);' \
2227    'void exit (int);'
2228 do
2229   cat >conftest.$ac_ext <<_ACEOF
2230 /* confdefs.h.  */
2231 _ACEOF
2232 cat confdefs.h >>conftest.$ac_ext
2233 cat >>conftest.$ac_ext <<_ACEOF
2234 /* end confdefs.h.  */
2235 $ac_declaration
2236 #include <stdlib.h>
2237 int
2238 main ()
2239 {
2240 exit (42);
2241   ;
2242   return 0;
2243 }
2244 _ACEOF
2245 rm -f conftest.$ac_objext
2246 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2247   (eval $ac_compile) 2>conftest.er1
2248   ac_status=$?
2249   grep -v '^ *+' conftest.er1 >conftest.err
2250   rm -f conftest.er1
2251   cat conftest.err >&5
2252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2253   (exit $ac_status); } &&
2254          { ac_try='test -z "$ac_c_werror_flag"
2255                          || test ! -s conftest.err'
2256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2257   (eval $ac_try) 2>&5
2258   ac_status=$?
2259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2260   (exit $ac_status); }; } &&
2261          { ac_try='test -s conftest.$ac_objext'
2262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2263   (eval $ac_try) 2>&5
2264   ac_status=$?
2265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2266   (exit $ac_status); }; }; then
2267   :
2268 else
2269   echo "$as_me: failed program was:" >&5
2270 sed 's/^/| /' conftest.$ac_ext >&5
2271
2272 continue
2273 fi
2274 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2275   cat >conftest.$ac_ext <<_ACEOF
2276 /* confdefs.h.  */
2277 _ACEOF
2278 cat confdefs.h >>conftest.$ac_ext
2279 cat >>conftest.$ac_ext <<_ACEOF
2280 /* end confdefs.h.  */
2281 $ac_declaration
2282 int
2283 main ()
2284 {
2285 exit (42);
2286   ;
2287   return 0;
2288 }
2289 _ACEOF
2290 rm -f conftest.$ac_objext
2291 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2292   (eval $ac_compile) 2>conftest.er1
2293   ac_status=$?
2294   grep -v '^ *+' conftest.er1 >conftest.err
2295   rm -f conftest.er1
2296   cat conftest.err >&5
2297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2298   (exit $ac_status); } &&
2299          { ac_try='test -z "$ac_c_werror_flag"
2300                          || test ! -s conftest.err'
2301   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2302   (eval $ac_try) 2>&5
2303   ac_status=$?
2304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2305   (exit $ac_status); }; } &&
2306          { ac_try='test -s conftest.$ac_objext'
2307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2308   (eval $ac_try) 2>&5
2309   ac_status=$?
2310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2311   (exit $ac_status); }; }; then
2312   break
2313 else
2314   echo "$as_me: failed program was:" >&5
2315 sed 's/^/| /' conftest.$ac_ext >&5
2316
2317 fi
2318 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2319 done
2320 rm -f conftest*
2321 if test -n "$ac_declaration"; then
2322   echo '#ifdef __cplusplus' >>confdefs.h
2323   echo $ac_declaration      >>confdefs.h
2324   echo '#endif'             >>confdefs.h
2325 fi
2326
2327 else
2328   echo "$as_me: failed program was:" >&5
2329 sed 's/^/| /' conftest.$ac_ext >&5
2330
2331 fi
2332 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2333 ac_ext=c
2334 ac_cpp='$CPP $CPPFLAGS'
2335 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2336 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2337 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2338
2339
2340 cat >>confdefs.h <<\_ACEOF
2341 #define _GNU_SOURCE 1
2342 _ACEOF
2343
2344
2345
2346 ac_ext=c
2347 ac_cpp='$CPP $CPPFLAGS'
2348 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2349 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2350 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2351 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2352 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2353 # On Suns, sometimes $CPP names a directory.
2354 if test -n "$CPP" && test -d "$CPP"; then
2355   CPP=
2356 fi
2357 if test -z "$CPP"; then
2358   if test "${ac_cv_prog_CPP+set}" = set; then
2359   echo $ECHO_N "(cached) $ECHO_C" >&6
2360 else
2361       # Double quotes because CPP needs to be expanded
2362     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2363     do
2364       ac_preproc_ok=false
2365 for ac_c_preproc_warn_flag in '' yes
2366 do
2367   # Use a header file that comes with gcc, so configuring glibc
2368   # with a fresh cross-compiler works.
2369   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2370   # <limits.h> exists even on freestanding compilers.
2371   # On the NeXT, cc -E runs the code through the compiler's parser,
2372   # not just through cpp. "Syntax error" is here to catch this case.
2373   cat >conftest.$ac_ext <<_ACEOF
2374 /* confdefs.h.  */
2375 _ACEOF
2376 cat confdefs.h >>conftest.$ac_ext
2377 cat >>conftest.$ac_ext <<_ACEOF
2378 /* end confdefs.h.  */
2379 #ifdef __STDC__
2380 # include <limits.h>
2381 #else
2382 # include <assert.h>
2383 #endif
2384                      Syntax error
2385 _ACEOF
2386 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2387   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2388   ac_status=$?
2389   grep -v '^ *+' conftest.er1 >conftest.err
2390   rm -f conftest.er1
2391   cat conftest.err >&5
2392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2393   (exit $ac_status); } >/dev/null; then
2394   if test -s conftest.err; then
2395     ac_cpp_err=$ac_c_preproc_warn_flag
2396     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2397   else
2398     ac_cpp_err=
2399   fi
2400 else
2401   ac_cpp_err=yes
2402 fi
2403 if test -z "$ac_cpp_err"; then
2404   :
2405 else
2406   echo "$as_me: failed program was:" >&5
2407 sed 's/^/| /' conftest.$ac_ext >&5
2408
2409   # Broken: fails on valid input.
2410 continue
2411 fi
2412 rm -f conftest.err conftest.$ac_ext
2413
2414   # OK, works on sane cases.  Now check whether non-existent headers
2415   # can be detected and how.
2416   cat >conftest.$ac_ext <<_ACEOF
2417 /* confdefs.h.  */
2418 _ACEOF
2419 cat confdefs.h >>conftest.$ac_ext
2420 cat >>conftest.$ac_ext <<_ACEOF
2421 /* end confdefs.h.  */
2422 #include <ac_nonexistent.h>
2423 _ACEOF
2424 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2425   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2426   ac_status=$?
2427   grep -v '^ *+' conftest.er1 >conftest.err
2428   rm -f conftest.er1
2429   cat conftest.err >&5
2430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2431   (exit $ac_status); } >/dev/null; then
2432   if test -s conftest.err; then
2433     ac_cpp_err=$ac_c_preproc_warn_flag
2434     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2435   else
2436     ac_cpp_err=
2437   fi
2438 else
2439   ac_cpp_err=yes
2440 fi
2441 if test -z "$ac_cpp_err"; then
2442   # Broken: success on invalid input.
2443 continue
2444 else
2445   echo "$as_me: failed program was:" >&5
2446 sed 's/^/| /' conftest.$ac_ext >&5
2447
2448   # Passes both tests.
2449 ac_preproc_ok=:
2450 break
2451 fi
2452 rm -f conftest.err conftest.$ac_ext
2453
2454 done
2455 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2456 rm -f conftest.err conftest.$ac_ext
2457 if $ac_preproc_ok; then
2458   break
2459 fi
2460
2461     done
2462     ac_cv_prog_CPP=$CPP
2463
2464 fi
2465   CPP=$ac_cv_prog_CPP
2466 else
2467   ac_cv_prog_CPP=$CPP
2468 fi
2469 echo "$as_me:$LINENO: result: $CPP" >&5
2470 echo "${ECHO_T}$CPP" >&6
2471 ac_preproc_ok=false
2472 for ac_c_preproc_warn_flag in '' yes
2473 do
2474   # Use a header file that comes with gcc, so configuring glibc
2475   # with a fresh cross-compiler works.
2476   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2477   # <limits.h> exists even on freestanding compilers.
2478   # On the NeXT, cc -E runs the code through the compiler's parser,
2479   # not just through cpp. "Syntax error" is here to catch this case.
2480   cat >conftest.$ac_ext <<_ACEOF
2481 /* confdefs.h.  */
2482 _ACEOF
2483 cat confdefs.h >>conftest.$ac_ext
2484 cat >>conftest.$ac_ext <<_ACEOF
2485 /* end confdefs.h.  */
2486 #ifdef __STDC__
2487 # include <limits.h>
2488 #else
2489 # include <assert.h>
2490 #endif
2491                      Syntax error
2492 _ACEOF
2493 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2494   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2495   ac_status=$?
2496   grep -v '^ *+' conftest.er1 >conftest.err
2497   rm -f conftest.er1
2498   cat conftest.err >&5
2499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2500   (exit $ac_status); } >/dev/null; then
2501   if test -s conftest.err; then
2502     ac_cpp_err=$ac_c_preproc_warn_flag
2503     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2504   else
2505     ac_cpp_err=
2506   fi
2507 else
2508   ac_cpp_err=yes
2509 fi
2510 if test -z "$ac_cpp_err"; then
2511   :
2512 else
2513   echo "$as_me: failed program was:" >&5
2514 sed 's/^/| /' conftest.$ac_ext >&5
2515
2516   # Broken: fails on valid input.
2517 continue
2518 fi
2519 rm -f conftest.err conftest.$ac_ext
2520
2521   # OK, works on sane cases.  Now check whether non-existent headers
2522   # can be detected and how.
2523   cat >conftest.$ac_ext <<_ACEOF
2524 /* confdefs.h.  */
2525 _ACEOF
2526 cat confdefs.h >>conftest.$ac_ext
2527 cat >>conftest.$ac_ext <<_ACEOF
2528 /* end confdefs.h.  */
2529 #include <ac_nonexistent.h>
2530 _ACEOF
2531 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2532   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2533   ac_status=$?
2534   grep -v '^ *+' conftest.er1 >conftest.err
2535   rm -f conftest.er1
2536   cat conftest.err >&5
2537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2538   (exit $ac_status); } >/dev/null; then
2539   if test -s conftest.err; then
2540     ac_cpp_err=$ac_c_preproc_warn_flag
2541     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2542   else
2543     ac_cpp_err=
2544   fi
2545 else
2546   ac_cpp_err=yes
2547 fi
2548 if test -z "$ac_cpp_err"; then
2549   # Broken: success on invalid input.
2550 continue
2551 else
2552   echo "$as_me: failed program was:" >&5
2553 sed 's/^/| /' conftest.$ac_ext >&5
2554
2555   # Passes both tests.
2556 ac_preproc_ok=:
2557 break
2558 fi
2559 rm -f conftest.err conftest.$ac_ext
2560
2561 done
2562 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2563 rm -f conftest.err conftest.$ac_ext
2564 if $ac_preproc_ok; then
2565   :
2566 else
2567   { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2568 echo "$as_me: error: in \`$ac_pwd':" >&2;}
2569 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
2570 See \`config.log' for more details." >&5
2571 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
2572 See \`config.log' for more details." >&2;}
2573    { (exit 1); exit 1; }; }; }
2574 fi
2575
2576 ac_ext=c
2577 ac_cpp='$CPP $CPPFLAGS'
2578 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2579 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2580 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2581
2582
2583 echo "$as_me:$LINENO: checking for egrep" >&5
2584 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2585 if test "${ac_cv_prog_egrep+set}" = set; then
2586   echo $ECHO_N "(cached) $ECHO_C" >&6
2587 else
2588   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2589     then ac_cv_prog_egrep='grep -E'
2590     else ac_cv_prog_egrep='egrep'
2591     fi
2592 fi
2593 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
2594 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2595  EGREP=$ac_cv_prog_egrep
2596
2597
2598
2599 echo "$as_me:$LINENO: checking for AIX" >&5
2600 echo $ECHO_N "checking for AIX... $ECHO_C" >&6
2601 cat >conftest.$ac_ext <<_ACEOF
2602 /* confdefs.h.  */
2603 _ACEOF
2604 cat confdefs.h >>conftest.$ac_ext
2605 cat >>conftest.$ac_ext <<_ACEOF
2606 /* end confdefs.h.  */
2607 #ifdef _AIX
2608   yes
2609 #endif
2610
2611 _ACEOF
2612 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2613   $EGREP "yes" >/dev/null 2>&1; then
2614   echo "$as_me:$LINENO: result: yes" >&5
2615 echo "${ECHO_T}yes" >&6
2616 cat >>confdefs.h <<\_ACEOF
2617 #define _ALL_SOURCE 1
2618 _ACEOF
2619
2620 else
2621   echo "$as_me:$LINENO: result: no" >&5
2622 echo "${ECHO_T}no" >&6
2623 fi
2624 rm -f conftest*
2625
2626
2627 echo "$as_me:$LINENO: checking for library containing strerror" >&5
2628 echo $ECHO_N "checking for library containing strerror... $ECHO_C" >&6
2629 if test "${ac_cv_search_strerror+set}" = set; then
2630   echo $ECHO_N "(cached) $ECHO_C" >&6
2631 else
2632   ac_func_search_save_LIBS=$LIBS
2633 ac_cv_search_strerror=no
2634 cat >conftest.$ac_ext <<_ACEOF
2635 /* confdefs.h.  */
2636 _ACEOF
2637 cat confdefs.h >>conftest.$ac_ext
2638 cat >>conftest.$ac_ext <<_ACEOF
2639 /* end confdefs.h.  */
2640
2641 /* Override any gcc2 internal prototype to avoid an error.  */
2642 #ifdef __cplusplus
2643 extern "C"
2644 #endif
2645 /* We use char because int might match the return type of a gcc2
2646    builtin and then its argument prototype would still apply.  */
2647 char strerror ();
2648 int
2649 main ()
2650 {
2651 strerror ();
2652   ;
2653   return 0;
2654 }
2655 _ACEOF
2656 rm -f conftest.$ac_objext conftest$ac_exeext
2657 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2658   (eval $ac_link) 2>conftest.er1
2659   ac_status=$?
2660   grep -v '^ *+' conftest.er1 >conftest.err
2661   rm -f conftest.er1
2662   cat conftest.err >&5
2663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2664   (exit $ac_status); } &&
2665          { ac_try='test -z "$ac_c_werror_flag"
2666                          || test ! -s conftest.err'
2667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2668   (eval $ac_try) 2>&5
2669   ac_status=$?
2670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2671   (exit $ac_status); }; } &&
2672          { ac_try='test -s conftest$ac_exeext'
2673   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2674   (eval $ac_try) 2>&5
2675   ac_status=$?
2676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2677   (exit $ac_status); }; }; then
2678   ac_cv_search_strerror="none required"
2679 else
2680   echo "$as_me: failed program was:" >&5
2681 sed 's/^/| /' conftest.$ac_ext >&5
2682
2683 fi
2684 rm -f conftest.err conftest.$ac_objext \
2685       conftest$ac_exeext conftest.$ac_ext
2686 if test "$ac_cv_search_strerror" = no; then
2687   for ac_lib in cposix; do
2688     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
2689     cat >conftest.$ac_ext <<_ACEOF
2690 /* confdefs.h.  */
2691 _ACEOF
2692 cat confdefs.h >>conftest.$ac_ext
2693 cat >>conftest.$ac_ext <<_ACEOF
2694 /* end confdefs.h.  */
2695
2696 /* Override any gcc2 internal prototype to avoid an error.  */
2697 #ifdef __cplusplus
2698 extern "C"
2699 #endif
2700 /* We use char because int might match the return type of a gcc2
2701    builtin and then its argument prototype would still apply.  */
2702 char strerror ();
2703 int
2704 main ()
2705 {
2706 strerror ();
2707   ;
2708   return 0;
2709 }
2710 _ACEOF
2711 rm -f conftest.$ac_objext conftest$ac_exeext
2712 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2713   (eval $ac_link) 2>conftest.er1
2714   ac_status=$?
2715   grep -v '^ *+' conftest.er1 >conftest.err
2716   rm -f conftest.er1
2717   cat conftest.err >&5
2718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2719   (exit $ac_status); } &&
2720          { ac_try='test -z "$ac_c_werror_flag"
2721                          || test ! -s conftest.err'
2722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2723   (eval $ac_try) 2>&5
2724   ac_status=$?
2725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2726   (exit $ac_status); }; } &&
2727          { ac_try='test -s conftest$ac_exeext'
2728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2729   (eval $ac_try) 2>&5
2730   ac_status=$?
2731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2732   (exit $ac_status); }; }; then
2733   ac_cv_search_strerror="-l$ac_lib"
2734 break
2735 else
2736   echo "$as_me: failed program was:" >&5
2737 sed 's/^/| /' conftest.$ac_ext >&5
2738
2739 fi
2740 rm -f conftest.err conftest.$ac_objext \
2741       conftest$ac_exeext conftest.$ac_ext
2742   done
2743 fi
2744 LIBS=$ac_func_search_save_LIBS
2745 fi
2746 echo "$as_me:$LINENO: result: $ac_cv_search_strerror" >&5
2747 echo "${ECHO_T}$ac_cv_search_strerror" >&6
2748 if test "$ac_cv_search_strerror" != no; then
2749   test "$ac_cv_search_strerror" = "none required" || LIBS="$ac_cv_search_strerror $LIBS"
2750
2751 fi
2752
2753 if test -n "$ac_tool_prefix"; then
2754   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
2755 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
2756 echo "$as_me:$LINENO: checking for $ac_word" >&5
2757 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2758 if test "${ac_cv_prog_RANLIB+set}" = set; then
2759   echo $ECHO_N "(cached) $ECHO_C" >&6
2760 else
2761   if test -n "$RANLIB"; then
2762   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
2763 else
2764 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2765 for as_dir in $PATH
2766 do
2767   IFS=$as_save_IFS
2768   test -z "$as_dir" && as_dir=.
2769   for ac_exec_ext in '' $ac_executable_extensions; do
2770   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2771     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
2772     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2773     break 2
2774   fi
2775 done
2776 done
2777
2778 fi
2779 fi
2780 RANLIB=$ac_cv_prog_RANLIB
2781 if test -n "$RANLIB"; then
2782   echo "$as_me:$LINENO: result: $RANLIB" >&5
2783 echo "${ECHO_T}$RANLIB" >&6
2784 else
2785   echo "$as_me:$LINENO: result: no" >&5
2786 echo "${ECHO_T}no" >&6
2787 fi
2788
2789 fi
2790 if test -z "$ac_cv_prog_RANLIB"; then
2791   ac_ct_RANLIB=$RANLIB
2792   # Extract the first word of "ranlib", so it can be a program name with args.
2793 set dummy ranlib; ac_word=$2
2794 echo "$as_me:$LINENO: checking for $ac_word" >&5
2795 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2796 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
2797   echo $ECHO_N "(cached) $ECHO_C" >&6
2798 else
2799   if test -n "$ac_ct_RANLIB"; then
2800   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
2801 else
2802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2803 for as_dir in $PATH
2804 do
2805   IFS=$as_save_IFS
2806   test -z "$as_dir" && as_dir=.
2807   for ac_exec_ext in '' $ac_executable_extensions; do
2808   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2809     ac_cv_prog_ac_ct_RANLIB="ranlib"
2810     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2811     break 2
2812   fi
2813 done
2814 done
2815
2816   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
2817 fi
2818 fi
2819 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
2820 if test -n "$ac_ct_RANLIB"; then
2821   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
2822 echo "${ECHO_T}$ac_ct_RANLIB" >&6
2823 else
2824   echo "$as_me:$LINENO: result: no" >&5
2825 echo "${ECHO_T}no" >&6
2826 fi
2827
2828   RANLIB=$ac_ct_RANLIB
2829 else
2830   RANLIB="$ac_cv_prog_RANLIB"
2831 fi
2832
2833 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
2834 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2835 if test "${ac_cv_header_stdc+set}" = set; then
2836   echo $ECHO_N "(cached) $ECHO_C" >&6
2837 else
2838   cat >conftest.$ac_ext <<_ACEOF
2839 /* confdefs.h.  */
2840 _ACEOF
2841 cat confdefs.h >>conftest.$ac_ext
2842 cat >>conftest.$ac_ext <<_ACEOF
2843 /* end confdefs.h.  */
2844 #include <stdlib.h>
2845 #include <stdarg.h>
2846 #include <string.h>
2847 #include <float.h>
2848
2849 int
2850 main ()
2851 {
2852
2853   ;
2854   return 0;
2855 }
2856 _ACEOF
2857 rm -f conftest.$ac_objext
2858 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2859   (eval $ac_compile) 2>conftest.er1
2860   ac_status=$?
2861   grep -v '^ *+' conftest.er1 >conftest.err
2862   rm -f conftest.er1
2863   cat conftest.err >&5
2864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2865   (exit $ac_status); } &&
2866          { ac_try='test -z "$ac_c_werror_flag"
2867                          || test ! -s conftest.err'
2868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2869   (eval $ac_try) 2>&5
2870   ac_status=$?
2871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2872   (exit $ac_status); }; } &&
2873          { ac_try='test -s conftest.$ac_objext'
2874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2875   (eval $ac_try) 2>&5
2876   ac_status=$?
2877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2878   (exit $ac_status); }; }; then
2879   ac_cv_header_stdc=yes
2880 else
2881   echo "$as_me: failed program was:" >&5
2882 sed 's/^/| /' conftest.$ac_ext >&5
2883
2884 ac_cv_header_stdc=no
2885 fi
2886 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2887
2888 if test $ac_cv_header_stdc = yes; then
2889   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2890   cat >conftest.$ac_ext <<_ACEOF
2891 /* confdefs.h.  */
2892 _ACEOF
2893 cat confdefs.h >>conftest.$ac_ext
2894 cat >>conftest.$ac_ext <<_ACEOF
2895 /* end confdefs.h.  */
2896 #include <string.h>
2897
2898 _ACEOF
2899 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2900   $EGREP "memchr" >/dev/null 2>&1; then
2901   :
2902 else
2903   ac_cv_header_stdc=no
2904 fi
2905 rm -f conftest*
2906
2907 fi
2908
2909 if test $ac_cv_header_stdc = yes; then
2910   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2911   cat >conftest.$ac_ext <<_ACEOF
2912 /* confdefs.h.  */
2913 _ACEOF
2914 cat confdefs.h >>conftest.$ac_ext
2915 cat >>conftest.$ac_ext <<_ACEOF
2916 /* end confdefs.h.  */
2917 #include <stdlib.h>
2918
2919 _ACEOF
2920 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2921   $EGREP "free" >/dev/null 2>&1; then
2922   :
2923 else
2924   ac_cv_header_stdc=no
2925 fi
2926 rm -f conftest*
2927
2928 fi
2929
2930 if test $ac_cv_header_stdc = yes; then
2931   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2932   if test "$cross_compiling" = yes; then
2933   :
2934 else
2935   cat >conftest.$ac_ext <<_ACEOF
2936 /* confdefs.h.  */
2937 _ACEOF
2938 cat confdefs.h >>conftest.$ac_ext
2939 cat >>conftest.$ac_ext <<_ACEOF
2940 /* end confdefs.h.  */
2941 #include <ctype.h>
2942 #if ((' ' & 0x0FF) == 0x020)
2943 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2944 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2945 #else
2946 # define ISLOWER(c) \
2947                    (('a' <= (c) && (c) <= 'i') \
2948                      || ('j' <= (c) && (c) <= 'r') \
2949                      || ('s' <= (c) && (c) <= 'z'))
2950 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2951 #endif
2952
2953 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2954 int
2955 main ()
2956 {
2957   int i;
2958   for (i = 0; i < 256; i++)
2959     if (XOR (islower (i), ISLOWER (i))
2960         || toupper (i) != TOUPPER (i))
2961       exit(2);
2962   exit (0);
2963 }
2964 _ACEOF
2965 rm -f conftest$ac_exeext
2966 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2967   (eval $ac_link) 2>&5
2968   ac_status=$?
2969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2970   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2972   (eval $ac_try) 2>&5
2973   ac_status=$?
2974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2975   (exit $ac_status); }; }; then
2976   :
2977 else
2978   echo "$as_me: program exited with status $ac_status" >&5
2979 echo "$as_me: failed program was:" >&5
2980 sed 's/^/| /' conftest.$ac_ext >&5
2981
2982 ( exit $ac_status )
2983 ac_cv_header_stdc=no
2984 fi
2985 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2986 fi
2987 fi
2988 fi
2989 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
2990 echo "${ECHO_T}$ac_cv_header_stdc" >&6
2991 if test $ac_cv_header_stdc = yes; then
2992
2993 cat >>confdefs.h <<\_ACEOF
2994 #define STDC_HEADERS 1
2995 _ACEOF
2996
2997 fi
2998
2999 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3010                   inttypes.h stdint.h unistd.h
3011 do
3012 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3013 echo "$as_me:$LINENO: checking for $ac_header" >&5
3014 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3015 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3016   echo $ECHO_N "(cached) $ECHO_C" >&6
3017 else
3018   cat >conftest.$ac_ext <<_ACEOF
3019 /* confdefs.h.  */
3020 _ACEOF
3021 cat confdefs.h >>conftest.$ac_ext
3022 cat >>conftest.$ac_ext <<_ACEOF
3023 /* end confdefs.h.  */
3024 $ac_includes_default
3025
3026 #include <$ac_header>
3027 _ACEOF
3028 rm -f conftest.$ac_objext
3029 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3030   (eval $ac_compile) 2>conftest.er1
3031   ac_status=$?
3032   grep -v '^ *+' conftest.er1 >conftest.err
3033   rm -f conftest.er1
3034   cat conftest.err >&5
3035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3036   (exit $ac_status); } &&
3037          { ac_try='test -z "$ac_c_werror_flag"
3038                          || test ! -s conftest.err'
3039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3040   (eval $ac_try) 2>&5
3041   ac_status=$?
3042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3043   (exit $ac_status); }; } &&
3044          { ac_try='test -s conftest.$ac_objext'
3045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3046   (eval $ac_try) 2>&5
3047   ac_status=$?
3048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3049   (exit $ac_status); }; }; then
3050   eval "$as_ac_Header=yes"
3051 else
3052   echo "$as_me: failed program was:" >&5
3053 sed 's/^/| /' conftest.$ac_ext >&5
3054
3055 eval "$as_ac_Header=no"
3056 fi
3057 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3058 fi
3059 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3060 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3061 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3062   cat >>confdefs.h <<_ACEOF
3063 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3064 _ACEOF
3065
3066 fi
3067
3068 done
3069
3070
3071
3072   if test "${ac_cv_header_minix_config_h+set}" = set; then
3073   echo "$as_me:$LINENO: checking for minix/config.h" >&5
3074 echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3075 if test "${ac_cv_header_minix_config_h+set}" = set; then
3076   echo $ECHO_N "(cached) $ECHO_C" >&6
3077 fi
3078 echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3079 echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3080 else
3081   # Is the header compilable?
3082 echo "$as_me:$LINENO: checking minix/config.h usability" >&5
3083 echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
3084 cat >conftest.$ac_ext <<_ACEOF
3085 /* confdefs.h.  */
3086 _ACEOF
3087 cat confdefs.h >>conftest.$ac_ext
3088 cat >>conftest.$ac_ext <<_ACEOF
3089 /* end confdefs.h.  */
3090 $ac_includes_default
3091 #include <minix/config.h>
3092 _ACEOF
3093 rm -f conftest.$ac_objext
3094 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3095   (eval $ac_compile) 2>conftest.er1
3096   ac_status=$?
3097   grep -v '^ *+' conftest.er1 >conftest.err
3098   rm -f conftest.er1
3099   cat conftest.err >&5
3100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3101   (exit $ac_status); } &&
3102          { ac_try='test -z "$ac_c_werror_flag"
3103                          || test ! -s conftest.err'
3104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3105   (eval $ac_try) 2>&5
3106   ac_status=$?
3107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3108   (exit $ac_status); }; } &&
3109          { ac_try='test -s conftest.$ac_objext'
3110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3111   (eval $ac_try) 2>&5
3112   ac_status=$?
3113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3114   (exit $ac_status); }; }; then
3115   ac_header_compiler=yes
3116 else
3117   echo "$as_me: failed program was:" >&5
3118 sed 's/^/| /' conftest.$ac_ext >&5
3119
3120 ac_header_compiler=no
3121 fi
3122 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3123 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3124 echo "${ECHO_T}$ac_header_compiler" >&6
3125
3126 # Is the header present?
3127 echo "$as_me:$LINENO: checking minix/config.h presence" >&5
3128 echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
3129 cat >conftest.$ac_ext <<_ACEOF
3130 /* confdefs.h.  */
3131 _ACEOF
3132 cat confdefs.h >>conftest.$ac_ext
3133 cat >>conftest.$ac_ext <<_ACEOF
3134 /* end confdefs.h.  */
3135 #include <minix/config.h>
3136 _ACEOF
3137 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3138   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3139   ac_status=$?
3140   grep -v '^ *+' conftest.er1 >conftest.err
3141   rm -f conftest.er1
3142   cat conftest.err >&5
3143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3144   (exit $ac_status); } >/dev/null; then
3145   if test -s conftest.err; then
3146     ac_cpp_err=$ac_c_preproc_warn_flag
3147     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3148   else
3149     ac_cpp_err=
3150   fi
3151 else
3152   ac_cpp_err=yes
3153 fi
3154 if test -z "$ac_cpp_err"; then
3155   ac_header_preproc=yes
3156 else
3157   echo "$as_me: failed program was:" >&5
3158 sed 's/^/| /' conftest.$ac_ext >&5
3159
3160   ac_header_preproc=no
3161 fi
3162 rm -f conftest.err conftest.$ac_ext
3163 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
3164 echo "${ECHO_T}$ac_header_preproc" >&6
3165
3166 # So?  What about this header?
3167 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
3168   yes:no: )
3169     { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
3170 echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
3171     { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the compiler's result" >&5
3172 echo "$as_me: WARNING: minix/config.h: proceeding with the compiler's result" >&2;}
3173     ac_header_preproc=yes
3174     ;;
3175   no:yes:* )
3176     { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
3177 echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
3178     { echo "$as_me:$LINENO: WARNING: minix/config.h:     check for missing prerequisite headers?" >&5
3179 echo "$as_me: WARNING: minix/config.h:     check for missing prerequisite headers?" >&2;}
3180     { echo "$as_me:$LINENO: WARNING: minix/config.h: see the Autoconf documentation" >&5
3181 echo "$as_me: WARNING: minix/config.h: see the Autoconf documentation" >&2;}
3182     { echo "$as_me:$LINENO: WARNING: minix/config.h:     section \"Present But Cannot Be Compiled\"" >&5
3183 echo "$as_me: WARNING: minix/config.h:     section \"Present But Cannot Be Compiled\"" >&2;}
3184     { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
3185 echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;}
3186     { echo "$as_me:$LINENO: WARNING: minix/config.h: in the future, the compiler will take precedence" >&5
3187 echo "$as_me: WARNING: minix/config.h: in the future, the compiler will take precedence" >&2;}
3188     (
3189       cat <<\_ASBOX
3190 ## ------------------------------------------ ##
3191 ## Report this to the AC_PACKAGE_NAME lists.  ##
3192 ## ------------------------------------------ ##
3193 _ASBOX
3194     ) |
3195       sed "s/^/$as_me: WARNING:     /" >&2
3196     ;;
3197 esac
3198 echo "$as_me:$LINENO: checking for minix/config.h" >&5
3199 echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3200 if test "${ac_cv_header_minix_config_h+set}" = set; then
3201   echo $ECHO_N "(cached) $ECHO_C" >&6
3202 else
3203   ac_cv_header_minix_config_h=$ac_header_preproc
3204 fi
3205 echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3206 echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3207
3208 fi
3209 if test $ac_cv_header_minix_config_h = yes; then
3210   MINIX=yes
3211 else
3212   MINIX=
3213 fi
3214
3215
3216   if test "$MINIX" = yes; then
3217
3218 cat >>confdefs.h <<\_ACEOF
3219 #define _POSIX_SOURCE 1
3220 _ACEOF
3221
3222
3223 cat >>confdefs.h <<\_ACEOF
3224 #define _POSIX_1_SOURCE 2
3225 _ACEOF
3226
3227
3228 cat >>confdefs.h <<\_ACEOF
3229 #define _MINIX 1
3230 _ACEOF
3231
3232   fi
3233
3234
3235
3236   echo "$as_me:$LINENO: checking whether it is safe to define __EXTENSIONS__" >&5
3237 echo $ECHO_N "checking whether it is safe to define __EXTENSIONS__... $ECHO_C" >&6
3238 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then
3239   echo $ECHO_N "(cached) $ECHO_C" >&6
3240 else
3241   cat >conftest.$ac_ext <<_ACEOF
3242 /* confdefs.h.  */
3243 _ACEOF
3244 cat confdefs.h >>conftest.$ac_ext
3245 cat >>conftest.$ac_ext <<_ACEOF
3246 /* end confdefs.h.  */
3247
3248 #         define __EXTENSIONS__ 1
3249           $ac_includes_default
3250 int
3251 main ()
3252 {
3253
3254   ;
3255   return 0;
3256 }
3257 _ACEOF
3258 rm -f conftest.$ac_objext
3259 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3260   (eval $ac_compile) 2>conftest.er1
3261   ac_status=$?
3262   grep -v '^ *+' conftest.er1 >conftest.err
3263   rm -f conftest.er1
3264   cat conftest.err >&5
3265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3266   (exit $ac_status); } &&
3267          { ac_try='test -z "$ac_c_werror_flag"
3268                          || test ! -s conftest.err'
3269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3270   (eval $ac_try) 2>&5
3271   ac_status=$?
3272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3273   (exit $ac_status); }; } &&
3274          { ac_try='test -s conftest.$ac_objext'
3275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3276   (eval $ac_try) 2>&5
3277   ac_status=$?
3278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3279   (exit $ac_status); }; }; then
3280   ac_cv_safe_to_define___extensions__=yes
3281 else
3282   echo "$as_me: failed program was:" >&5
3283 sed 's/^/| /' conftest.$ac_ext >&5
3284
3285 ac_cv_safe_to_define___extensions__=no
3286 fi
3287 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3288 fi
3289 echo "$as_me:$LINENO: result: $ac_cv_safe_to_define___extensions__" >&5
3290 echo "${ECHO_T}$ac_cv_safe_to_define___extensions__" >&6
3291   test $ac_cv_safe_to_define___extensions__ = yes &&
3292     cat >>confdefs.h <<\_ACEOF
3293 #define __EXTENSIONS__ 1
3294 _ACEOF
3295
3296   cat >>confdefs.h <<\_ACEOF
3297 #define _ALL_SOURCE 1
3298 _ACEOF
3299
3300   cat >>confdefs.h <<\_ACEOF
3301 #define _GNU_SOURCE 1
3302 _ACEOF
3303
3304   cat >>confdefs.h <<\_ACEOF
3305 #define _POSIX_PTHREAD_SEMANTICS 1
3306 _ACEOF
3307
3308   cat >>confdefs.h <<\_ACEOF
3309 #define _TANDEM_SOURCE 1
3310 _ACEOF
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321 echo "$as_me:$LINENO: checking for ${CC-cc} option to accept ANSI C" >&5
3322 echo $ECHO_N "checking for ${CC-cc} option to accept ANSI C... $ECHO_C" >&6
3323 if test "${am_cv_prog_cc_stdc+set}" = set; then
3324   echo $ECHO_N "(cached) $ECHO_C" >&6
3325 else
3326   am_cv_prog_cc_stdc=no
3327 ac_save_CC="$CC"
3328 # Don't try gcc -ansi; that turns off useful extensions and
3329 # breaks some systems' header files.
3330 # AIX                   -qlanglvl=ansi
3331 # Ultrix and OSF/1      -std1
3332 # HP-UX 10.20 and later -Ae
3333 # HP-UX older versions  -Aa -D_HPUX_SOURCE
3334 # SVR4                  -Xc -D__EXTENSIONS__
3335 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3336 do
3337   CC="$ac_save_CC $ac_arg"
3338   cat >conftest.$ac_ext <<_ACEOF
3339 /* confdefs.h.  */
3340 _ACEOF
3341 cat confdefs.h >>conftest.$ac_ext
3342 cat >>conftest.$ac_ext <<_ACEOF
3343 /* end confdefs.h.  */
3344 #include <stdarg.h>
3345 #include <stdio.h>
3346 #include <sys/types.h>
3347 #include <sys/stat.h>
3348 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3349 struct buf { int x; };
3350 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3351 static char *e (p, i)
3352      char **p;
3353      int i;
3354 {
3355   return p[i];
3356 }
3357 static char *f (char * (*g) (char **, int), char **p, ...)
3358 {
3359   char *s;
3360   va_list v;
3361   va_start (v,p);
3362   s = g (p, va_arg (v,int));
3363   va_end (v);
3364   return s;
3365 }
3366 int test (int i, double x);
3367 struct s1 {int (*f) (int a);};
3368 struct s2 {int (*f) (double a);};
3369 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3370 int argc;
3371 char **argv;
3372
3373 int
3374 main ()
3375 {
3376
3377 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3378
3379   ;
3380   return 0;
3381 }
3382 _ACEOF
3383 rm -f conftest.$ac_objext
3384 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3385   (eval $ac_compile) 2>conftest.er1
3386   ac_status=$?
3387   grep -v '^ *+' conftest.er1 >conftest.err
3388   rm -f conftest.er1
3389   cat conftest.err >&5
3390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3391   (exit $ac_status); } &&
3392          { ac_try='test -z "$ac_c_werror_flag"
3393                          || test ! -s conftest.err'
3394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3395   (eval $ac_try) 2>&5
3396   ac_status=$?
3397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3398   (exit $ac_status); }; } &&
3399          { ac_try='test -s conftest.$ac_objext'
3400   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3401   (eval $ac_try) 2>&5
3402   ac_status=$?
3403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3404   (exit $ac_status); }; }; then
3405   am_cv_prog_cc_stdc="$ac_arg"; break
3406 else
3407   echo "$as_me: failed program was:" >&5
3408 sed 's/^/| /' conftest.$ac_ext >&5
3409
3410 fi
3411 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3412 done
3413 CC="$ac_save_CC"
3414
3415 fi
3416
3417 if test -z "$am_cv_prog_cc_stdc"; then
3418   echo "$as_me:$LINENO: result: none needed" >&5
3419 echo "${ECHO_T}none needed" >&6
3420 else
3421   echo "$as_me:$LINENO: result: $am_cv_prog_cc_stdc" >&5
3422 echo "${ECHO_T}$am_cv_prog_cc_stdc" >&6
3423 fi
3424 case "x$am_cv_prog_cc_stdc" in
3425   x|xno) ;;
3426   *) CC="$CC $am_cv_prog_cc_stdc" ;;
3427 esac
3428
3429
3430 ac_aux_dir=
3431 for ac_dir in .. $srcdir/..; do
3432   if test -f $ac_dir/install-sh; then
3433     ac_aux_dir=$ac_dir
3434     ac_install_sh="$ac_aux_dir/install-sh -c"
3435     break
3436   elif test -f $ac_dir/install.sh; then
3437     ac_aux_dir=$ac_dir
3438     ac_install_sh="$ac_aux_dir/install.sh -c"
3439     break
3440   elif test -f $ac_dir/shtool; then
3441     ac_aux_dir=$ac_dir
3442     ac_install_sh="$ac_aux_dir/shtool install -c"
3443     break
3444   fi
3445 done
3446 if test -z "$ac_aux_dir"; then
3447   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in .. $srcdir/.." >&5
3448 echo "$as_me: error: cannot find install-sh or install.sh in .. $srcdir/.." >&2;}
3449    { (exit 1); exit 1; }; }
3450 fi
3451 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
3452 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
3453 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
3454
3455 # Make sure we can run config.sub.
3456 $ac_config_sub sun4 >/dev/null 2>&1 ||
3457   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
3458 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
3459    { (exit 1); exit 1; }; }
3460
3461 echo "$as_me:$LINENO: checking build system type" >&5
3462 echo $ECHO_N "checking build system type... $ECHO_C" >&6
3463 if test "${ac_cv_build+set}" = set; then
3464   echo $ECHO_N "(cached) $ECHO_C" >&6
3465 else
3466   ac_cv_build_alias=$build_alias
3467 test -z "$ac_cv_build_alias" &&
3468   ac_cv_build_alias=`$ac_config_guess`
3469 test -z "$ac_cv_build_alias" &&
3470   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
3471 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
3472    { (exit 1); exit 1; }; }
3473 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
3474   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
3475 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
3476    { (exit 1); exit 1; }; }
3477
3478 fi
3479 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
3480 echo "${ECHO_T}$ac_cv_build" >&6
3481 build=$ac_cv_build
3482 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3483 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3484 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3485
3486
3487 echo "$as_me:$LINENO: checking host system type" >&5
3488 echo $ECHO_N "checking host system type... $ECHO_C" >&6
3489 if test "${ac_cv_host+set}" = set; then
3490   echo $ECHO_N "(cached) $ECHO_C" >&6
3491 else
3492   ac_cv_host_alias=$host_alias
3493 test -z "$ac_cv_host_alias" &&
3494   ac_cv_host_alias=$ac_cv_build_alias
3495 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
3496   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
3497 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
3498    { (exit 1); exit 1; }; }
3499
3500 fi
3501 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
3502 echo "${ECHO_T}$ac_cv_host" >&6
3503 host=$ac_cv_host
3504 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3505 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3506 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3507
3508
3509 echo "$as_me:$LINENO: checking target system type" >&5
3510 echo $ECHO_N "checking target system type... $ECHO_C" >&6
3511 if test "${ac_cv_target+set}" = set; then
3512   echo $ECHO_N "(cached) $ECHO_C" >&6
3513 else
3514   ac_cv_target_alias=$target_alias
3515 test "x$ac_cv_target_alias" = "x" &&
3516   ac_cv_target_alias=$ac_cv_host_alias
3517 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
3518   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
3519 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
3520    { (exit 1); exit 1; }; }
3521
3522 fi
3523 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
3524 echo "${ECHO_T}$ac_cv_target" >&6
3525 target=$ac_cv_target
3526 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3527 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3528 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3529
3530
3531 # The aliases save the names the user supplied, while $host etc.
3532 # will get canonicalized.
3533 test -n "$target_alias" &&
3534   test "$program_prefix$program_suffix$program_transform_name" = \
3535     NONENONEs,x,x, &&
3536   program_prefix=${target_alias}-
3537
3538 # Dependency checking.
3539 rm -rf .tst 2>/dev/null
3540 mkdir .tst 2>/dev/null
3541 if test -d .tst; then
3542   am__leading_dot=.
3543 else
3544   am__leading_dot=_
3545 fi
3546 rmdir .tst 2>/dev/null
3547
3548 DEPDIR="${am__leading_dot}deps"
3549
3550           ac_config_commands="$ac_config_commands depdir"
3551
3552
3553 depcc="$CC"   am_compiler_list=
3554
3555 am_depcomp=$ac_aux_dir/depcomp
3556 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
3557 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
3558 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
3559   echo $ECHO_N "(cached) $ECHO_C" >&6
3560 else
3561   if test -f "$am_depcomp"; then
3562   # We make a subdir and do the tests there.  Otherwise we can end up
3563   # making bogus files that we don't know about and never remove.  For
3564   # instance it was reported that on HP-UX the gcc test will end up
3565   # making a dummy file named `D' -- because `-MD' means `put the output
3566   # in D'.
3567   mkdir conftest.dir
3568   # Copy depcomp to subdir because otherwise we won't find it if we're
3569   # using a relative directory.
3570   cp "$am_depcomp" conftest.dir
3571   cd conftest.dir
3572   # We will build objects and dependencies in a subdirectory because
3573   # it helps to detect inapplicable dependency modes.  For instance
3574   # both Tru64's cc and ICC support -MD to output dependencies as a
3575   # side effect of compilation, but ICC will put the dependencies in
3576   # the current directory while Tru64 will put them in the object
3577   # directory.
3578   mkdir sub
3579
3580   am_cv_CC_dependencies_compiler_type=none
3581   if test "$am_compiler_list" = ""; then
3582      am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
3583   fi
3584   for depmode in $am_compiler_list; do
3585     if test $depmode = none; then break; fi
3586
3587     echo "$as_me:$LINENO: trying $depmode" >&5
3588     # Setup a source with many dependencies, because some compilers
3589     # like to wrap large dependency lists on column 80 (with \), and
3590     # we should not choose a depcomp mode which is confused by this.
3591     #
3592     # We need to recreate these files for each test, as the compiler may
3593     # overwrite some of them when testing with obscure command lines.
3594     # This happens at least with the AIX C compiler.
3595     : > sub/conftest.c
3596     for i in 1 2 3 4 5 6; do
3597       echo '#include "conftst'$i'.h"' >> sub/conftest.c
3598       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
3599       # Solaris 8's {/usr,}/bin/sh.
3600       touch sub/conftst$i.h
3601     done
3602     echo "include sub/conftest.Po" > confmf
3603
3604     # We check with `-c' and `-o' for the sake of the "dashmstdout"
3605     # mode.  It turns out that the SunPro C++ compiler does not properly
3606     # handle `-M -o', and we need to detect this.
3607     depcmd="depmode=$depmode \
3608        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
3609        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
3610        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c"
3611     echo "| $depcmd" | sed -e 's/  */ /g' >&5
3612     if env $depcmd > conftest.err 2>&1 &&
3613        grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 &&
3614        grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 &&
3615        ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then
3616       # icc doesn't choke on unknown options, it will just issue warnings
3617       # or remarks (even with -Werror).  So we grep stderr for any message
3618       # that says an option was ignored or not supported.
3619       # When given -MP, icc 7.0 and 7.1 complain thusly:
3620       #   icc: Command line warning: ignoring option '-M'; no argument required
3621       # The diagnosis changed in icc 8.0:
3622       #   icc: Command line remark: option '-MP' not supported
3623       if (grep 'ignoring option' conftest.err ||
3624           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
3625         am_cv_CC_dependencies_compiler_type=$depmode
3626         echo "$as_me:$LINENO: success" >&5
3627         break
3628       fi
3629     fi
3630     echo "$as_me:$LINENO: failure, diagnostics are:" >&5
3631     sed -e 's/^/| /' < conftest.err >&5
3632   done
3633
3634   cd ..
3635   rm -rf conftest.dir
3636 else
3637   am_cv_CC_dependencies_compiler_type=none
3638 fi
3639
3640 fi
3641 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
3642 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
3643 if test x${am_cv_CC_dependencies_compiler_type-none} = xnone
3644 then { { echo "$as_me:$LINENO: error: no usable dependency style found" >&5
3645 echo "$as_me: error: no usable dependency style found" >&2;}
3646    { (exit 1); exit 1; }; }
3647 else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
3648
3649 fi
3650
3651
3652 # Check for the 'make' the user wants to use.
3653 for ac_prog in make
3654 do
3655   # Extract the first word of "$ac_prog", so it can be a program name with args.
3656 set dummy $ac_prog; ac_word=$2
3657 echo "$as_me:$LINENO: checking for $ac_word" >&5
3658 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3659 if test "${ac_cv_prog_MAKE+set}" = set; then
3660   echo $ECHO_N "(cached) $ECHO_C" >&6
3661 else
3662   if test -n "$MAKE"; then
3663   ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
3664 else
3665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3666 for as_dir in $PATH
3667 do
3668   IFS=$as_save_IFS
3669   test -z "$as_dir" && as_dir=.
3670   for ac_exec_ext in '' $ac_executable_extensions; do
3671   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3672     ac_cv_prog_MAKE="$ac_prog"
3673     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3674     break 2
3675   fi
3676 done
3677 done
3678
3679 fi
3680 fi
3681 MAKE=$ac_cv_prog_MAKE
3682 if test -n "$MAKE"; then
3683   echo "$as_me:$LINENO: result: $MAKE" >&5
3684 echo "${ECHO_T}$MAKE" >&6
3685 else
3686   echo "$as_me:$LINENO: result: no" >&5
3687 echo "${ECHO_T}no" >&6
3688 fi
3689
3690   test -n "$MAKE" && break
3691 done
3692
3693 MAKE_IS_GNU=
3694 case "`$MAKE --version 2>&1 | sed 1q`" in
3695   *GNU*)
3696     MAKE_IS_GNU=yes
3697     ;;
3698 esac
3699
3700
3701 if test "$MAKE_IS_GNU" = yes; then
3702   GMAKE_TRUE=
3703   GMAKE_FALSE='#'
3704 else
3705   GMAKE_TRUE='#'
3706   GMAKE_FALSE=
3707 fi
3708
3709 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3710 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
3711 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
3712 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3713   echo $ECHO_N "(cached) $ECHO_C" >&6
3714 else
3715   cat >conftest.make <<\_ACEOF
3716 all:
3717         @echo 'ac_maketemp="$(MAKE)"'
3718 _ACEOF
3719 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3720 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3721 if test -n "$ac_maketemp"; then
3722   eval ac_cv_prog_make_${ac_make}_set=yes
3723 else
3724   eval ac_cv_prog_make_${ac_make}_set=no
3725 fi
3726 rm -f conftest.make
3727 fi
3728 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3729   echo "$as_me:$LINENO: result: yes" >&5
3730 echo "${ECHO_T}yes" >&6
3731   SET_MAKE=
3732 else
3733   echo "$as_me:$LINENO: result: no" >&5
3734 echo "${ECHO_T}no" >&6
3735   SET_MAKE="MAKE=${MAKE-make}"
3736 fi
3737
3738
3739
3740 CONFIG_OBS=
3741 CONFIG_DEPS=
3742 CONFIG_SRCS=
3743 ENABLE_CFLAGS=
3744
3745 CONFIG_ALL=
3746 CONFIG_CLEAN=
3747 CONFIG_INSTALL=
3748 CONFIG_UNINSTALL=
3749
3750 # If we haven't got the data from the intl directory,
3751 # assume NLS is disabled.
3752 USE_NLS=no
3753 LIBINTL=
3754 LIBINTL_DEP=
3755 INCINTL=
3756 XGETTEXT=
3757 GMSGFMT=
3758 POSUB=
3759
3760 if test -f  ../intl/config.intl; then
3761   .  ../intl/config.intl
3762 fi
3763 echo "$as_me:$LINENO: checking whether NLS is requested" >&5
3764 echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6
3765 if test x"$USE_NLS" != xyes; then
3766   echo "$as_me:$LINENO: result: no" >&5
3767 echo "${ECHO_T}no" >&6
3768 else
3769   echo "$as_me:$LINENO: result: yes" >&5
3770 echo "${ECHO_T}yes" >&6
3771
3772 cat >>confdefs.h <<\_ACEOF
3773 #define ENABLE_NLS 1
3774 _ACEOF
3775
3776
3777   echo "$as_me:$LINENO: checking for catalogs to be installed" >&5
3778 echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6
3779   # Look for .po and .gmo files in the source directory.
3780   CATALOGS=
3781   XLINGUAS=
3782   for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
3783     # If there aren't any .gmo files the shell will give us the
3784     # literal string "../path/to/srcdir/po/*.gmo" which has to be
3785     # weeded out.
3786     case "$cat" in *\**)
3787       continue;;
3788     esac
3789     # The quadruple backslash is collapsed to a double backslash
3790     # by the backticks, then collapsed again by the double quotes,
3791     # leaving us with one backslash in the sed expression (right
3792     # before the dot that mustn't act as a wildcard).
3793     cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
3794     lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
3795     # The user is allowed to set LINGUAS to a list of languages to
3796     # install catalogs for.  If it's empty that means "all of them."
3797     if test "x$LINGUAS" = x; then
3798       CATALOGS="$CATALOGS $cat"
3799       XLINGUAS="$XLINGUAS $lang"
3800     else
3801       case "$LINGUAS" in *$lang*)
3802         CATALOGS="$CATALOGS $cat"
3803         XLINGUAS="$XLINGUAS $lang"
3804         ;;
3805       esac
3806     fi
3807   done
3808   LINGUAS="$XLINGUAS"
3809   echo "$as_me:$LINENO: result: $LINGUAS" >&5
3810 echo "${ECHO_T}$LINGUAS" >&6
3811
3812
3813     DATADIRNAME=share
3814
3815   INSTOBJEXT=.mo
3816
3817   GENCAT=gencat
3818
3819   CATOBJEXT=.gmo
3820
3821 fi
3822
3823 localedir='${datadir}/locale'
3824
3825
3826 if test x"$USE_NLS" = xyes; then
3827    CONFIG_ALL="$CONFIG_ALL all-po"
3828    CONFIG_CLEAN="$CONFIG_CLEAN clean-po"
3829    CONFIG_INSTALL="$CONFIG_INSTALL install-po"
3830    CONFIG_UNINSTALL="$CONFIG_UNINSTALL uninstall-po"
3831 fi
3832
3833
3834   GNULIB_MEMMEM=0;
3835   GNULIB_MEMPCPY=0;
3836   GNULIB_MEMRCHR=0;
3837   GNULIB_STPCPY=0;
3838   GNULIB_STPNCPY=0;
3839   GNULIB_STRCHRNUL=0;
3840   GNULIB_STRDUP=0;
3841   GNULIB_STRNDUP=0;
3842   GNULIB_STRNLEN=0;
3843   GNULIB_STRPBRK=0;
3844   GNULIB_STRSEP=0;
3845   GNULIB_STRSTR=0;
3846   GNULIB_STRCASESTR=0;
3847   GNULIB_STRTOK_R=0;
3848   GNULIB_MBSLEN=0;
3849   GNULIB_MBSNLEN=0;
3850   GNULIB_MBSCHR=0;
3851   GNULIB_MBSRCHR=0;
3852   GNULIB_MBSSTR=0;
3853   GNULIB_MBSCASECMP=0;
3854   GNULIB_MBSNCASECMP=0;
3855   GNULIB_MBSPCASECMP=0;
3856   GNULIB_MBSCASESTR=0;
3857   GNULIB_MBSCSPN=0;
3858   GNULIB_MBSPBRK=0;
3859   GNULIB_MBSSPN=0;
3860   GNULIB_MBSSEP=0;
3861   GNULIB_MBSTOK_R=0;
3862   GNULIB_STRERROR=0;
3863   GNULIB_STRSIGNAL=0;
3864     HAVE_DECL_MEMMEM=1;
3865   HAVE_MEMPCPY=1;
3866   HAVE_DECL_MEMRCHR=1;
3867   HAVE_STPCPY=1;
3868   HAVE_STPNCPY=1;
3869   HAVE_STRCHRNUL=1;
3870   HAVE_DECL_STRDUP=1;
3871   HAVE_STRNDUP=1;
3872   HAVE_DECL_STRNDUP=1;
3873   HAVE_DECL_STRNLEN=1;
3874   HAVE_STRPBRK=1;
3875   HAVE_STRSEP=1;
3876   HAVE_STRCASESTR=1;
3877   HAVE_DECL_STRTOK_R=1;
3878   HAVE_DECL_STRERROR=1;
3879   HAVE_DECL_STRSIGNAL=1;
3880   REPLACE_STRERROR=0;
3881   REPLACE_STRSIGNAL=0;
3882   REPLACE_MEMMEM=0;
3883   REPLACE_STRCASESTR=0;
3884   REPLACE_STRSTR=0;
3885
3886
3887       echo "$as_me:$LINENO: checking whether memmem is declared" >&5
3888 echo $ECHO_N "checking whether memmem is declared... $ECHO_C" >&6
3889 if test "${ac_cv_have_decl_memmem+set}" = set; then
3890   echo $ECHO_N "(cached) $ECHO_C" >&6
3891 else
3892   cat >conftest.$ac_ext <<_ACEOF
3893 /* confdefs.h.  */
3894 _ACEOF
3895 cat confdefs.h >>conftest.$ac_ext
3896 cat >>conftest.$ac_ext <<_ACEOF
3897 /* end confdefs.h.  */
3898 $ac_includes_default
3899 int
3900 main ()
3901 {
3902 #ifndef memmem
3903   char *p = (char *) memmem;
3904 #endif
3905
3906   ;
3907   return 0;
3908 }
3909 _ACEOF
3910 rm -f conftest.$ac_objext
3911 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3912   (eval $ac_compile) 2>conftest.er1
3913   ac_status=$?
3914   grep -v '^ *+' conftest.er1 >conftest.err
3915   rm -f conftest.er1
3916   cat conftest.err >&5
3917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3918   (exit $ac_status); } &&
3919          { ac_try='test -z "$ac_c_werror_flag"
3920                          || test ! -s conftest.err'
3921   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3922   (eval $ac_try) 2>&5
3923   ac_status=$?
3924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3925   (exit $ac_status); }; } &&
3926          { ac_try='test -s conftest.$ac_objext'
3927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3928   (eval $ac_try) 2>&5
3929   ac_status=$?
3930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3931   (exit $ac_status); }; }; then
3932   ac_cv_have_decl_memmem=yes
3933 else
3934   echo "$as_me: failed program was:" >&5
3935 sed 's/^/| /' conftest.$ac_ext >&5
3936
3937 ac_cv_have_decl_memmem=no
3938 fi
3939 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3940 fi
3941 echo "$as_me:$LINENO: result: $ac_cv_have_decl_memmem" >&5
3942 echo "${ECHO_T}$ac_cv_have_decl_memmem" >&6
3943 if test $ac_cv_have_decl_memmem = yes; then
3944
3945 cat >>confdefs.h <<_ACEOF
3946 #define HAVE_DECL_MEMMEM 1
3947 _ACEOF
3948
3949
3950 else
3951   cat >>confdefs.h <<_ACEOF
3952 #define HAVE_DECL_MEMMEM 0
3953 _ACEOF
3954
3955
3956 fi
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972 for ac_func in memmem
3973 do
3974 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
3975 echo "$as_me:$LINENO: checking for $ac_func" >&5
3976 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
3977 if eval "test \"\${$as_ac_var+set}\" = set"; then
3978   echo $ECHO_N "(cached) $ECHO_C" >&6
3979 else
3980   cat >conftest.$ac_ext <<_ACEOF
3981 /* confdefs.h.  */
3982 _ACEOF
3983 cat confdefs.h >>conftest.$ac_ext
3984 cat >>conftest.$ac_ext <<_ACEOF
3985 /* end confdefs.h.  */
3986 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
3987    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3988 #define $ac_func innocuous_$ac_func
3989
3990 /* System header to define __stub macros and hopefully few prototypes,
3991     which can conflict with char $ac_func (); below.
3992     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3993     <limits.h> exists even on freestanding compilers.  */
3994
3995 #ifdef __STDC__
3996 # include <limits.h>
3997 #else
3998 # include <assert.h>
3999 #endif
4000
4001 #undef $ac_func
4002
4003 /* Override any gcc2 internal prototype to avoid an error.  */
4004 #ifdef __cplusplus
4005 extern "C"
4006 {
4007 #endif
4008 /* We use char because int might match the return type of a gcc2
4009    builtin and then its argument prototype would still apply.  */
4010 char $ac_func ();
4011 /* The GNU C library defines this for functions which it implements
4012     to always fail with ENOSYS.  Some functions are actually named
4013     something starting with __ and the normal name is an alias.  */
4014 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4015 choke me
4016 #else
4017 char (*f) () = $ac_func;
4018 #endif
4019 #ifdef __cplusplus
4020 }
4021 #endif
4022
4023 int
4024 main ()
4025 {
4026 return f != $ac_func;
4027   ;
4028   return 0;
4029 }
4030 _ACEOF
4031 rm -f conftest.$ac_objext conftest$ac_exeext
4032 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4033   (eval $ac_link) 2>conftest.er1
4034   ac_status=$?
4035   grep -v '^ *+' conftest.er1 >conftest.err
4036   rm -f conftest.er1
4037   cat conftest.err >&5
4038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4039   (exit $ac_status); } &&
4040          { ac_try='test -z "$ac_c_werror_flag"
4041                          || test ! -s conftest.err'
4042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4043   (eval $ac_try) 2>&5
4044   ac_status=$?
4045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4046   (exit $ac_status); }; } &&
4047          { ac_try='test -s conftest$ac_exeext'
4048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4049   (eval $ac_try) 2>&5
4050   ac_status=$?
4051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4052   (exit $ac_status); }; }; then
4053   eval "$as_ac_var=yes"
4054 else
4055   echo "$as_me: failed program was:" >&5
4056 sed 's/^/| /' conftest.$ac_ext >&5
4057
4058 eval "$as_ac_var=no"
4059 fi
4060 rm -f conftest.err conftest.$ac_objext \
4061       conftest$ac_exeext conftest.$ac_ext
4062 fi
4063 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
4064 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
4065 if test `eval echo '${'$as_ac_var'}'` = yes; then
4066   cat >>confdefs.h <<_ACEOF
4067 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
4068 _ACEOF
4069
4070 else
4071
4072     gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
4073
4074 fi
4075 done
4076
4077
4078
4079   :
4080
4081
4082
4083
4084
4085   if test $ac_cv_have_decl_memmem = no; then
4086     HAVE_DECL_MEMMEM=0
4087   fi
4088   :
4089
4090
4091   echo "$as_me:$LINENO: checking for long long int" >&5
4092 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
4093 if test "${ac_cv_type_long_long_int+set}" = set; then
4094   echo $ECHO_N "(cached) $ECHO_C" >&6
4095 else
4096   cat >conftest.$ac_ext <<_ACEOF
4097
4098   /* confdefs.h.  */
4099 _ACEOF
4100 cat confdefs.h >>conftest.$ac_ext
4101 cat >>conftest.$ac_ext <<_ACEOF
4102 /* end confdefs.h.  */
4103 /* For now, do not test the preprocessor; as of 2007 there are too many
4104          implementations with broken preprocessors.  Perhaps this can
4105          be revisited in 2012.  In the meantime, code should not expect
4106          #if to work with literals wider than 32 bits.  */
4107       /* Test literals.  */
4108       long long int ll = 9223372036854775807ll;
4109       long long int nll = -9223372036854775807LL;
4110       unsigned long long int ull = 18446744073709551615ULL;
4111       /* Test constant expressions.   */
4112       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
4113                      ? 1 : -1)];
4114       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
4115                      ? 1 : -1)];
4116       int i = 63;
4117 int
4118 main ()
4119 {
4120 /* Test availability of runtime routines for shift and division.  */
4121       long long int llmax = 9223372036854775807ll;
4122       unsigned long long int ullmax = 18446744073709551615ull;
4123       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
4124               | (llmax / ll) | (llmax % ll)
4125               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
4126               | (ullmax / ull) | (ullmax % ull));
4127   ;
4128   return 0;
4129 }
4130
4131 _ACEOF
4132 rm -f conftest.$ac_objext conftest$ac_exeext
4133 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4134   (eval $ac_link) 2>conftest.er1
4135   ac_status=$?
4136   grep -v '^ *+' conftest.er1 >conftest.err
4137   rm -f conftest.er1
4138   cat conftest.err >&5
4139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4140   (exit $ac_status); } &&
4141          { ac_try='test -z "$ac_c_werror_flag"
4142                          || test ! -s conftest.err'
4143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4144   (eval $ac_try) 2>&5
4145   ac_status=$?
4146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4147   (exit $ac_status); }; } &&
4148          { ac_try='test -s conftest$ac_exeext'
4149   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4150   (eval $ac_try) 2>&5
4151   ac_status=$?
4152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4153   (exit $ac_status); }; }; then
4154                         if test "$cross_compiling" = yes; then
4155   ac_cv_type_long_long_int=yes
4156 else
4157   cat >conftest.$ac_ext <<_ACEOF
4158 /* confdefs.h.  */
4159 _ACEOF
4160 cat confdefs.h >>conftest.$ac_ext
4161 cat >>conftest.$ac_ext <<_ACEOF
4162 /* end confdefs.h.  */
4163 #include <limits.h>
4164                #ifndef LLONG_MAX
4165                # define HALF \
4166                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
4167                # define LLONG_MAX (HALF - 1 + HALF)
4168                #endif
4169 int
4170 main ()
4171 {
4172 long long int n = 1;
4173                int i;
4174                for (i = 0; ; i++)
4175                  {
4176                    long long int m = n << i;
4177                    if (m >> i != n)
4178                      return 1;
4179                    if (LLONG_MAX / 2 < m)
4180                      break;
4181                  }
4182                return 0;
4183   ;
4184   return 0;
4185 }
4186 _ACEOF
4187 rm -f conftest$ac_exeext
4188 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4189   (eval $ac_link) 2>&5
4190   ac_status=$?
4191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4192   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4194   (eval $ac_try) 2>&5
4195   ac_status=$?
4196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4197   (exit $ac_status); }; }; then
4198   ac_cv_type_long_long_int=yes
4199 else
4200   echo "$as_me: program exited with status $ac_status" >&5
4201 echo "$as_me: failed program was:" >&5
4202 sed 's/^/| /' conftest.$ac_ext >&5
4203
4204 ( exit $ac_status )
4205 ac_cv_type_long_long_int=no
4206 fi
4207 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4208 fi
4209 else
4210   echo "$as_me: failed program was:" >&5
4211 sed 's/^/| /' conftest.$ac_ext >&5
4212
4213 ac_cv_type_long_long_int=no
4214 fi
4215 rm -f conftest.err conftest.$ac_objext \
4216       conftest$ac_exeext conftest.$ac_ext
4217 fi
4218 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
4219 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
4220   if test $ac_cv_type_long_long_int = yes; then
4221
4222 cat >>confdefs.h <<\_ACEOF
4223 #define HAVE_LONG_LONG_INT 1
4224 _ACEOF
4225
4226   fi
4227
4228
4229   echo "$as_me:$LINENO: checking for unsigned long long int" >&5
4230 echo $ECHO_N "checking for unsigned long long int... $ECHO_C" >&6
4231 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then
4232   echo $ECHO_N "(cached) $ECHO_C" >&6
4233 else
4234   cat >conftest.$ac_ext <<_ACEOF
4235
4236   /* confdefs.h.  */
4237 _ACEOF
4238 cat confdefs.h >>conftest.$ac_ext
4239 cat >>conftest.$ac_ext <<_ACEOF
4240 /* end confdefs.h.  */
4241 /* For now, do not test the preprocessor; as of 2007 there are too many
4242          implementations with broken preprocessors.  Perhaps this can
4243          be revisited in 2012.  In the meantime, code should not expect
4244          #if to work with literals wider than 32 bits.  */
4245       /* Test literals.  */
4246       long long int ll = 9223372036854775807ll;
4247       long long int nll = -9223372036854775807LL;
4248       unsigned long long int ull = 18446744073709551615ULL;
4249       /* Test constant expressions.   */
4250       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
4251                      ? 1 : -1)];
4252       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
4253                      ? 1 : -1)];
4254       int i = 63;
4255 int
4256 main ()
4257 {
4258 /* Test availability of runtime routines for shift and division.  */
4259       long long int llmax = 9223372036854775807ll;
4260       unsigned long long int ullmax = 18446744073709551615ull;
4261       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
4262               | (llmax / ll) | (llmax % ll)
4263               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
4264               | (ullmax / ull) | (ullmax % ull));
4265   ;
4266   return 0;
4267 }
4268
4269 _ACEOF
4270 rm -f conftest.$ac_objext conftest$ac_exeext
4271 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4272   (eval $ac_link) 2>conftest.er1
4273   ac_status=$?
4274   grep -v '^ *+' conftest.er1 >conftest.err
4275   rm -f conftest.er1
4276   cat conftest.err >&5
4277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4278   (exit $ac_status); } &&
4279          { ac_try='test -z "$ac_c_werror_flag"
4280                          || test ! -s conftest.err'
4281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4282   (eval $ac_try) 2>&5
4283   ac_status=$?
4284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4285   (exit $ac_status); }; } &&
4286          { ac_try='test -s conftest$ac_exeext'
4287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4288   (eval $ac_try) 2>&5
4289   ac_status=$?
4290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4291   (exit $ac_status); }; }; then
4292   ac_cv_type_unsigned_long_long_int=yes
4293 else
4294   echo "$as_me: failed program was:" >&5
4295 sed 's/^/| /' conftest.$ac_ext >&5
4296
4297 ac_cv_type_unsigned_long_long_int=no
4298 fi
4299 rm -f conftest.err conftest.$ac_objext \
4300       conftest$ac_exeext conftest.$ac_ext
4301 fi
4302 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long_int" >&5
4303 echo "${ECHO_T}$ac_cv_type_unsigned_long_long_int" >&6
4304   if test $ac_cv_type_unsigned_long_long_int = yes; then
4305
4306 cat >>confdefs.h <<\_ACEOF
4307 #define HAVE_UNSIGNED_LONG_LONG_INT 1
4308 _ACEOF
4309
4310   fi
4311
4312
4313
4314   echo "$as_me:$LINENO: checking whether the preprocessor supports include_next" >&5
4315 echo $ECHO_N "checking whether the preprocessor supports include_next... $ECHO_C" >&6
4316 if test "${gl_cv_have_include_next+set}" = set; then
4317   echo $ECHO_N "(cached) $ECHO_C" >&6
4318 else
4319   rm -rf conftestd1 conftestd2
4320      mkdir conftestd1 conftestd2
4321      cat <<EOF > conftestd1/conftest.h
4322 #define DEFINED_IN_CONFTESTD1
4323 #include_next <conftest.h>
4324 #ifdef DEFINED_IN_CONFTESTD2
4325 int foo;
4326 #else
4327 #error "include_next doesn't work"
4328 #endif
4329 EOF
4330      cat <<EOF > conftestd2/conftest.h
4331 #ifndef DEFINED_IN_CONFTESTD1
4332 #error "include_next test doesn't work"
4333 #endif
4334 #define DEFINED_IN_CONFTESTD2
4335 EOF
4336      save_CPPFLAGS="$CPPFLAGS"
4337      CPPFLAGS="$CPPFLAGS -Iconftestd1 -Iconftestd2"
4338      cat >conftest.$ac_ext <<_ACEOF
4339 #include <conftest.h>
4340 _ACEOF
4341 rm -f conftest.$ac_objext
4342 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4343   (eval $ac_compile) 2>conftest.er1
4344   ac_status=$?
4345   grep -v '^ *+' conftest.er1 >conftest.err
4346   rm -f conftest.er1
4347   cat conftest.err >&5
4348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4349   (exit $ac_status); } &&
4350          { ac_try='test -z "$ac_c_werror_flag"
4351                          || test ! -s conftest.err'
4352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4353   (eval $ac_try) 2>&5
4354   ac_status=$?
4355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4356   (exit $ac_status); }; } &&
4357          { ac_try='test -s conftest.$ac_objext'
4358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4359   (eval $ac_try) 2>&5
4360   ac_status=$?
4361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4362   (exit $ac_status); }; }; then
4363   gl_cv_have_include_next=yes
4364 else
4365   echo "$as_me: failed program was:" >&5
4366 sed 's/^/| /' conftest.$ac_ext >&5
4367
4368 gl_cv_have_include_next=no
4369 fi
4370 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4371      CPPFLAGS="$save_CPPFLAGS"
4372      rm -rf conftestd1 conftestd2
4373
4374 fi
4375 echo "$as_me:$LINENO: result: $gl_cv_have_include_next" >&5
4376 echo "${ECHO_T}$gl_cv_have_include_next" >&6
4377   if test $gl_cv_have_include_next = yes; then
4378
4379
4380 cat >>confdefs.h <<\_ACEOF
4381 #define HAVE_INCLUDE_NEXT 1
4382 _ACEOF
4383
4384
4385     INCLUDE_NEXT=include_next
4386   else
4387     INCLUDE_NEXT=include
4388   fi
4389
4390
4391
4392
4393
4394
4395
4396 for ac_header in $gl_header_list
4397 do
4398 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4399 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4400   echo "$as_me:$LINENO: checking for $ac_header" >&5
4401 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4402 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4403   echo $ECHO_N "(cached) $ECHO_C" >&6
4404 fi
4405 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4406 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4407 else
4408   # Is the header compilable?
4409 echo "$as_me:$LINENO: checking $ac_header usability" >&5
4410 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4411 cat >conftest.$ac_ext <<_ACEOF
4412 /* confdefs.h.  */
4413 _ACEOF
4414 cat confdefs.h >>conftest.$ac_ext
4415 cat >>conftest.$ac_ext <<_ACEOF
4416 /* end confdefs.h.  */
4417 $ac_includes_default
4418 #include <$ac_header>
4419 _ACEOF
4420 rm -f conftest.$ac_objext
4421 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4422   (eval $ac_compile) 2>conftest.er1
4423   ac_status=$?
4424   grep -v '^ *+' conftest.er1 >conftest.err
4425   rm -f conftest.er1
4426   cat conftest.err >&5
4427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4428   (exit $ac_status); } &&
4429          { ac_try='test -z "$ac_c_werror_flag"
4430                          || test ! -s conftest.err'
4431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4432   (eval $ac_try) 2>&5
4433   ac_status=$?
4434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4435   (exit $ac_status); }; } &&
4436          { ac_try='test -s conftest.$ac_objext'
4437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4438   (eval $ac_try) 2>&5
4439   ac_status=$?
4440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4441   (exit $ac_status); }; }; then
4442   ac_header_compiler=yes
4443 else
4444   echo "$as_me: failed program was:" >&5
4445 sed 's/^/| /' conftest.$ac_ext >&5
4446
4447 ac_header_compiler=no
4448 fi
4449 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4450 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4451 echo "${ECHO_T}$ac_header_compiler" >&6
4452
4453 # Is the header present?
4454 echo "$as_me:$LINENO: checking $ac_header presence" >&5
4455 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4456 cat >conftest.$ac_ext <<_ACEOF
4457 /* confdefs.h.  */
4458 _ACEOF
4459 cat confdefs.h >>conftest.$ac_ext
4460 cat >>conftest.$ac_ext <<_ACEOF
4461 /* end confdefs.h.  */
4462 #include <$ac_header>
4463 _ACEOF
4464 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4465   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4466   ac_status=$?
4467   grep -v '^ *+' conftest.er1 >conftest.err
4468   rm -f conftest.er1
4469   cat conftest.err >&5
4470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4471   (exit $ac_status); } >/dev/null; then
4472   if test -s conftest.err; then
4473     ac_cpp_err=$ac_c_preproc_warn_flag
4474     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4475   else
4476     ac_cpp_err=
4477   fi
4478 else
4479   ac_cpp_err=yes
4480 fi
4481 if test -z "$ac_cpp_err"; then
4482   ac_header_preproc=yes
4483 else
4484   echo "$as_me: failed program was:" >&5
4485 sed 's/^/| /' conftest.$ac_ext >&5
4486
4487   ac_header_preproc=no
4488 fi
4489 rm -f conftest.err conftest.$ac_ext
4490 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4491 echo "${ECHO_T}$ac_header_preproc" >&6
4492
4493 # So?  What about this header?
4494 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
4495   yes:no: )
4496     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4497 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4498     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
4499 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
4500     ac_header_preproc=yes
4501     ;;
4502   no:yes:* )
4503     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4504 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4505     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
4506 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
4507     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
4508 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
4509     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
4510 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
4511     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4512 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4513     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
4514 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
4515     (
4516       cat <<\_ASBOX
4517 ## ------------------------------------------ ##
4518 ## Report this to the AC_PACKAGE_NAME lists.  ##
4519 ## ------------------------------------------ ##
4520 _ASBOX
4521     ) |
4522       sed "s/^/$as_me: WARNING:     /" >&2
4523     ;;
4524 esac
4525 echo "$as_me:$LINENO: checking for $ac_header" >&5
4526 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4527 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4528   echo $ECHO_N "(cached) $ECHO_C" >&6
4529 else
4530   eval "$as_ac_Header=\$ac_header_preproc"
4531 fi
4532 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4533 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4534
4535 fi
4536 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4537   cat >>confdefs.h <<_ACEOF
4538 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4539 _ACEOF
4540
4541 fi
4542
4543 done
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556 echo "$as_me:$LINENO: checking for C/C++ restrict keyword" >&5
4557 echo $ECHO_N "checking for C/C++ restrict keyword... $ECHO_C" >&6
4558 if test "${ac_cv_c_restrict+set}" = set; then
4559   echo $ECHO_N "(cached) $ECHO_C" >&6
4560 else
4561   ac_cv_c_restrict=no
4562    # The order here caters to the fact that C++ does not require restrict.
4563    for ac_kw in __restrict __restrict__ _Restrict restrict; do
4564      cat >conftest.$ac_ext <<_ACEOF
4565 /* confdefs.h.  */
4566 _ACEOF
4567 cat confdefs.h >>conftest.$ac_ext
4568 cat >>conftest.$ac_ext <<_ACEOF
4569 /* end confdefs.h.  */
4570 typedef int * int_ptr;
4571         int foo (int_ptr $ac_kw ip) {
4572         return ip[0];
4573        }
4574 int
4575 main ()
4576 {
4577 int s[1];
4578         int * $ac_kw t = s;
4579         t[0] = 0;
4580         return foo(t)
4581   ;
4582   return 0;
4583 }
4584 _ACEOF
4585 rm -f conftest.$ac_objext
4586 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4587   (eval $ac_compile) 2>conftest.er1
4588   ac_status=$?
4589   grep -v '^ *+' conftest.er1 >conftest.err
4590   rm -f conftest.er1
4591   cat conftest.err >&5
4592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4593   (exit $ac_status); } &&
4594          { ac_try='test -z "$ac_c_werror_flag"
4595                          || test ! -s conftest.err'
4596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4597   (eval $ac_try) 2>&5
4598   ac_status=$?
4599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4600   (exit $ac_status); }; } &&
4601          { ac_try='test -s conftest.$ac_objext'
4602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4603   (eval $ac_try) 2>&5
4604   ac_status=$?
4605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4606   (exit $ac_status); }; }; then
4607   ac_cv_c_restrict=$ac_kw
4608 else
4609   echo "$as_me: failed program was:" >&5
4610 sed 's/^/| /' conftest.$ac_ext >&5
4611
4612 fi
4613 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4614      test "$ac_cv_c_restrict" != no && break
4615    done
4616
4617 fi
4618 echo "$as_me:$LINENO: result: $ac_cv_c_restrict" >&5
4619 echo "${ECHO_T}$ac_cv_c_restrict" >&6
4620
4621
4622  case $ac_cv_c_restrict in
4623    restrict) ;;
4624    no) cat >>confdefs.h <<\_ACEOF
4625 #define restrict
4626 _ACEOF
4627  ;;
4628    *)  cat >>confdefs.h <<_ACEOF
4629 #define restrict $ac_cv_c_restrict
4630 _ACEOF
4631  ;;
4632  esac
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646   :
4647
4648
4649
4650
4651
4652
4653
4654      if test $gl_cv_have_include_next = yes; then
4655        gl_cv_next_string_h='<'string.h'>'
4656      else
4657        echo "$as_me:$LINENO: checking absolute name of <string.h>" >&5
4658 echo $ECHO_N "checking absolute name of <string.h>... $ECHO_C" >&6
4659 if test "${gl_cv_next_string_h+set}" = set; then
4660   echo $ECHO_N "(cached) $ECHO_C" >&6
4661 else
4662
4663           if test $ac_cv_header_string_h = yes; then
4664             cat >conftest.$ac_ext <<_ACEOF
4665 /* confdefs.h.  */
4666 _ACEOF
4667 cat confdefs.h >>conftest.$ac_ext
4668 cat >>conftest.$ac_ext <<_ACEOF
4669 /* end confdefs.h.  */
4670 #include <string.h>
4671
4672 _ACEOF
4673                                     gl_cv_next_string_h='"'`(eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4674                sed -n '\#/string.h#{
4675                  s#.*"\(.*/string.h\)".*#\1#
4676                  s#^/[^/]#//&#
4677                  p
4678                  q
4679                }'`'"'
4680           else
4681             gl_cv_next_string_h='<'string.h'>'
4682           fi
4683
4684 fi
4685 echo "$as_me:$LINENO: result: $gl_cv_next_string_h" >&5
4686 echo "${ECHO_T}$gl_cv_next_string_h" >&6
4687      fi
4688      NEXT_STRING_H=$gl_cv_next_string_h
4689
4690
4691
4692
4693
4694   GNULIB_WCWIDTH=0;
4695     HAVE_DECL_WCWIDTH=1;
4696   REPLACE_WCWIDTH=0;
4697   WCHAR_H=
4698
4699
4700
4701
4702
4703 if false; then
4704   GL_COND_LIBTOOL_TRUE=
4705   GL_COND_LIBTOOL_FALSE='#'
4706 else
4707   GL_COND_LIBTOOL_TRUE='#'
4708   GL_COND_LIBTOOL_FALSE=
4709 fi
4710
4711   gl_cond_libtool=false
4712   gl_libdeps=
4713   gl_ltlibdeps=
4714
4715
4716
4717   gl_source_base='gnulib'
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727 for ac_func in memchr
4728 do
4729 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
4730 echo "$as_me:$LINENO: checking for $ac_func" >&5
4731 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
4732 if eval "test \"\${$as_ac_var+set}\" = set"; then
4733   echo $ECHO_N "(cached) $ECHO_C" >&6
4734 else
4735   cat >conftest.$ac_ext <<_ACEOF
4736 /* confdefs.h.  */
4737 _ACEOF
4738 cat confdefs.h >>conftest.$ac_ext
4739 cat >>conftest.$ac_ext <<_ACEOF
4740 /* end confdefs.h.  */
4741 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
4742    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
4743 #define $ac_func innocuous_$ac_func
4744
4745 /* System header to define __stub macros and hopefully few prototypes,
4746     which can conflict with char $ac_func (); below.
4747     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4748     <limits.h> exists even on freestanding compilers.  */
4749
4750 #ifdef __STDC__
4751 # include <limits.h>
4752 #else
4753 # include <assert.h>
4754 #endif
4755
4756 #undef $ac_func
4757
4758 /* Override any gcc2 internal prototype to avoid an error.  */
4759 #ifdef __cplusplus
4760 extern "C"
4761 {
4762 #endif
4763 /* We use char because int might match the return type of a gcc2
4764    builtin and then its argument prototype would still apply.  */
4765 char $ac_func ();
4766 /* The GNU C library defines this for functions which it implements
4767     to always fail with ENOSYS.  Some functions are actually named
4768     something starting with __ and the normal name is an alias.  */
4769 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4770 choke me
4771 #else
4772 char (*f) () = $ac_func;
4773 #endif
4774 #ifdef __cplusplus
4775 }
4776 #endif
4777
4778 int
4779 main ()
4780 {
4781 return f != $ac_func;
4782   ;
4783   return 0;
4784 }
4785 _ACEOF
4786 rm -f conftest.$ac_objext conftest$ac_exeext
4787 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4788   (eval $ac_link) 2>conftest.er1
4789   ac_status=$?
4790   grep -v '^ *+' conftest.er1 >conftest.err
4791   rm -f conftest.er1
4792   cat conftest.err >&5
4793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4794   (exit $ac_status); } &&
4795          { ac_try='test -z "$ac_c_werror_flag"
4796                          || test ! -s conftest.err'
4797   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4798   (eval $ac_try) 2>&5
4799   ac_status=$?
4800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4801   (exit $ac_status); }; } &&
4802          { ac_try='test -s conftest$ac_exeext'
4803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4804   (eval $ac_try) 2>&5
4805   ac_status=$?
4806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4807   (exit $ac_status); }; }; then
4808   eval "$as_ac_var=yes"
4809 else
4810   echo "$as_me: failed program was:" >&5
4811 sed 's/^/| /' conftest.$ac_ext >&5
4812
4813 eval "$as_ac_var=no"
4814 fi
4815 rm -f conftest.err conftest.$ac_objext \
4816       conftest$ac_exeext conftest.$ac_ext
4817 fi
4818 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
4819 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
4820 if test `eval echo '${'$as_ac_var'}'` = yes; then
4821   cat >>confdefs.h <<_ACEOF
4822 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
4823 _ACEOF
4824
4825 else
4826
4827     gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
4828
4829 fi
4830 done
4831
4832
4833   if test $ac_cv_func_memchr = no; then
4834
4835
4836 for ac_header in bp-sym.h
4837 do
4838 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4839 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4840   echo "$as_me:$LINENO: checking for $ac_header" >&5
4841 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4842 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4843   echo $ECHO_N "(cached) $ECHO_C" >&6
4844 fi
4845 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4846 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4847 else
4848   # Is the header compilable?
4849 echo "$as_me:$LINENO: checking $ac_header usability" >&5
4850 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4851 cat >conftest.$ac_ext <<_ACEOF
4852 /* confdefs.h.  */
4853 _ACEOF
4854 cat confdefs.h >>conftest.$ac_ext
4855 cat >>conftest.$ac_ext <<_ACEOF
4856 /* end confdefs.h.  */
4857 $ac_includes_default
4858 #include <$ac_header>
4859 _ACEOF
4860 rm -f conftest.$ac_objext
4861 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4862   (eval $ac_compile) 2>conftest.er1
4863   ac_status=$?
4864   grep -v '^ *+' conftest.er1 >conftest.err
4865   rm -f conftest.er1
4866   cat conftest.err >&5
4867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4868   (exit $ac_status); } &&
4869          { ac_try='test -z "$ac_c_werror_flag"
4870                          || test ! -s conftest.err'
4871   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4872   (eval $ac_try) 2>&5
4873   ac_status=$?
4874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4875   (exit $ac_status); }; } &&
4876          { ac_try='test -s conftest.$ac_objext'
4877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4878   (eval $ac_try) 2>&5
4879   ac_status=$?
4880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4881   (exit $ac_status); }; }; then
4882   ac_header_compiler=yes
4883 else
4884   echo "$as_me: failed program was:" >&5
4885 sed 's/^/| /' conftest.$ac_ext >&5
4886
4887 ac_header_compiler=no
4888 fi
4889 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4890 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4891 echo "${ECHO_T}$ac_header_compiler" >&6
4892
4893 # Is the header present?
4894 echo "$as_me:$LINENO: checking $ac_header presence" >&5
4895 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4896 cat >conftest.$ac_ext <<_ACEOF
4897 /* confdefs.h.  */
4898 _ACEOF
4899 cat confdefs.h >>conftest.$ac_ext
4900 cat >>conftest.$ac_ext <<_ACEOF
4901 /* end confdefs.h.  */
4902 #include <$ac_header>
4903 _ACEOF
4904 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4905   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4906   ac_status=$?
4907   grep -v '^ *+' conftest.er1 >conftest.err
4908   rm -f conftest.er1
4909   cat conftest.err >&5
4910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4911   (exit $ac_status); } >/dev/null; then
4912   if test -s conftest.err; then
4913     ac_cpp_err=$ac_c_preproc_warn_flag
4914     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
4915   else
4916     ac_cpp_err=
4917   fi
4918 else
4919   ac_cpp_err=yes
4920 fi
4921 if test -z "$ac_cpp_err"; then
4922   ac_header_preproc=yes
4923 else
4924   echo "$as_me: failed program was:" >&5
4925 sed 's/^/| /' conftest.$ac_ext >&5
4926
4927   ac_header_preproc=no
4928 fi
4929 rm -f conftest.err conftest.$ac_ext
4930 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4931 echo "${ECHO_T}$ac_header_preproc" >&6
4932
4933 # So?  What about this header?
4934 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
4935   yes:no: )
4936     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4937 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4938     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
4939 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
4940     ac_header_preproc=yes
4941     ;;
4942   no:yes:* )
4943     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4944 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4945     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
4946 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
4947     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
4948 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
4949     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
4950 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
4951     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4952 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4953     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
4954 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
4955     (
4956       cat <<\_ASBOX
4957 ## ------------------------------------------ ##
4958 ## Report this to the AC_PACKAGE_NAME lists.  ##
4959 ## ------------------------------------------ ##
4960 _ASBOX
4961     ) |
4962       sed "s/^/$as_me: WARNING:     /" >&2
4963     ;;
4964 esac
4965 echo "$as_me:$LINENO: checking for $ac_header" >&5
4966 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4967 if eval "test \"\${$as_ac_Header+set}\" = set"; then
4968   echo $ECHO_N "(cached) $ECHO_C" >&6
4969 else
4970   eval "$as_ac_Header=\$ac_header_preproc"
4971 fi
4972 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4973 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4974
4975 fi
4976 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4977   cat >>confdefs.h <<_ACEOF
4978 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4979 _ACEOF
4980
4981 fi
4982
4983 done
4984
4985
4986   fi
4987
4988
4989   echo "$as_me:$LINENO: checking for working memcmp" >&5
4990 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
4991 if test "${ac_cv_func_memcmp_working+set}" = set; then
4992   echo $ECHO_N "(cached) $ECHO_C" >&6
4993 else
4994   if test "$cross_compiling" = yes; then
4995   ac_cv_func_memcmp_working=no
4996 else
4997   cat >conftest.$ac_ext <<_ACEOF
4998 /* confdefs.h.  */
4999 _ACEOF
5000 cat confdefs.h >>conftest.$ac_ext
5001 cat >>conftest.$ac_ext <<_ACEOF
5002 /* end confdefs.h.  */
5003 $ac_includes_default
5004 int
5005 main ()
5006 {
5007
5008   /* Some versions of memcmp are not 8-bit clean.  */
5009   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
5010   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
5011     exit (1);
5012
5013   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
5014      or more and with at least one buffer not starting on a 4-byte boundary.
5015      William Lewis provided this test program.   */
5016   {
5017     char foo[21];
5018     char bar[21];
5019     int i;
5020     for (i = 0; i < 4; i++)
5021       {
5022         char *a = foo + i;
5023         char *b = bar + i;
5024         strcpy (a, "--------01111111");
5025         strcpy (b, "--------10000000");
5026         if (memcmp (a, b, 16) >= 0)
5027           exit (1);
5028       }
5029     exit (0);
5030   }
5031
5032   ;
5033   return 0;
5034 }
5035 _ACEOF
5036 rm -f conftest$ac_exeext
5037 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5038   (eval $ac_link) 2>&5
5039   ac_status=$?
5040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5041   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5043   (eval $ac_try) 2>&5
5044   ac_status=$?
5045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5046   (exit $ac_status); }; }; then
5047   ac_cv_func_memcmp_working=yes
5048 else
5049   echo "$as_me: program exited with status $ac_status" >&5
5050 echo "$as_me: failed program was:" >&5
5051 sed 's/^/| /' conftest.$ac_ext >&5
5052
5053 ( exit $ac_status )
5054 ac_cv_func_memcmp_working=no
5055 fi
5056 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5057 fi
5058 fi
5059 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
5060 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
5061 test $ac_cv_func_memcmp_working = no &&
5062
5063
5064
5065
5066
5067
5068   gl_LIBOBJS="$gl_LIBOBJS memcmp.$ac_objext"
5069
5070
5071     if test $ac_cv_func_memcmp_working = no; then
5072
5073 cat >>confdefs.h <<\_ACEOF
5074 #define memcmp rpl_memcmp
5075 _ACEOF
5076
5077     :
5078   fi
5079
5080
5081
5082   if test $ac_cv_have_decl_memmem = yes; then
5083     echo "$as_me:$LINENO: checking whether memmem works in linear time" >&5
5084 echo $ECHO_N "checking whether memmem works in linear time... $ECHO_C" >&6
5085 if test "${gl_cv_func_memmem_works+set}" = set; then
5086   echo $ECHO_N "(cached) $ECHO_C" >&6
5087 else
5088   if test "$cross_compiling" = yes; then
5089                  gl_cv_func_memmem_works="guessing no"
5090 else
5091   cat >conftest.$ac_ext <<_ACEOF
5092 /* confdefs.h.  */
5093 _ACEOF
5094 cat confdefs.h >>conftest.$ac_ext
5095 cat >>conftest.$ac_ext <<_ACEOF
5096 /* end confdefs.h.  */
5097
5098 #include <string.h> /* for memmem */
5099 #include <stdlib.h> /* for malloc */
5100 #include <unistd.h> /* for alarm */
5101
5102 int
5103 main ()
5104 {
5105 size_t m = 1000000;
5106     char *haystack = (char *) malloc (2 * m + 1);
5107     char *needle = (char *) malloc (m + 1);
5108     void *result = 0;
5109     /* Failure to compile this test due to missing alarm is okay,
5110        since all such platforms (mingw) also lack memmem.  */
5111     alarm (5);
5112     /* Check for quadratic performance.  */
5113     if (haystack && needle)
5114       {
5115         memset (haystack, 'A', 2 * m);
5116         haystack[2 * m] = 'B';
5117         memset (needle, 'A', m);
5118         needle[m] = 'B';
5119         result = memmem (haystack, 2 * m + 1, needle, m + 1);
5120       }
5121     /* Check for empty needle behavior.  */
5122     return !result || !memmem ("a", 1, 0, 0);
5123   ;
5124   return 0;
5125 }
5126 _ACEOF
5127 rm -f conftest$ac_exeext
5128 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5129   (eval $ac_link) 2>&5
5130   ac_status=$?
5131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5132   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5134   (eval $ac_try) 2>&5
5135   ac_status=$?
5136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5137   (exit $ac_status); }; }; then
5138   gl_cv_func_memmem_works=yes
5139 else
5140   echo "$as_me: program exited with status $ac_status" >&5
5141 echo "$as_me: failed program was:" >&5
5142 sed 's/^/| /' conftest.$ac_ext >&5
5143
5144 ( exit $ac_status )
5145 gl_cv_func_memmem_works=no
5146 fi
5147 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5148 fi
5149 fi
5150 echo "$as_me:$LINENO: result: $gl_cv_func_memmem_works" >&5
5151 echo "${ECHO_T}$gl_cv_func_memmem_works" >&6
5152     if test "$gl_cv_func_memmem_works" != yes; then
5153       REPLACE_MEMMEM=1
5154
5155
5156
5157
5158
5159
5160
5161   gl_LIBOBJS="$gl_LIBOBJS memmem.$ac_objext"
5162
5163     fi
5164   fi
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178 for ac_func in memmem
5179 do
5180 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
5181 echo "$as_me:$LINENO: checking for $ac_func" >&5
5182 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
5183 if eval "test \"\${$as_ac_var+set}\" = set"; then
5184   echo $ECHO_N "(cached) $ECHO_C" >&6
5185 else
5186   cat >conftest.$ac_ext <<_ACEOF
5187 /* confdefs.h.  */
5188 _ACEOF
5189 cat confdefs.h >>conftest.$ac_ext
5190 cat >>conftest.$ac_ext <<_ACEOF
5191 /* end confdefs.h.  */
5192 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
5193    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
5194 #define $ac_func innocuous_$ac_func
5195
5196 /* System header to define __stub macros and hopefully few prototypes,
5197     which can conflict with char $ac_func (); below.
5198     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5199     <limits.h> exists even on freestanding compilers.  */
5200
5201 #ifdef __STDC__
5202 # include <limits.h>
5203 #else
5204 # include <assert.h>
5205 #endif
5206
5207 #undef $ac_func
5208
5209 /* Override any gcc2 internal prototype to avoid an error.  */
5210 #ifdef __cplusplus
5211 extern "C"
5212 {
5213 #endif
5214 /* We use char because int might match the return type of a gcc2
5215    builtin and then its argument prototype would still apply.  */
5216 char $ac_func ();
5217 /* The GNU C library defines this for functions which it implements
5218     to always fail with ENOSYS.  Some functions are actually named
5219     something starting with __ and the normal name is an alias.  */
5220 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5221 choke me
5222 #else
5223 char (*f) () = $ac_func;
5224 #endif
5225 #ifdef __cplusplus
5226 }
5227 #endif
5228
5229 int
5230 main ()
5231 {
5232 return f != $ac_func;
5233   ;
5234   return 0;
5235 }
5236 _ACEOF
5237 rm -f conftest.$ac_objext conftest$ac_exeext
5238 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5239   (eval $ac_link) 2>conftest.er1
5240   ac_status=$?
5241   grep -v '^ *+' conftest.er1 >conftest.err
5242   rm -f conftest.er1
5243   cat conftest.err >&5
5244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5245   (exit $ac_status); } &&
5246          { ac_try='test -z "$ac_c_werror_flag"
5247                          || test ! -s conftest.err'
5248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5249   (eval $ac_try) 2>&5
5250   ac_status=$?
5251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5252   (exit $ac_status); }; } &&
5253          { ac_try='test -s conftest$ac_exeext'
5254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5255   (eval $ac_try) 2>&5
5256   ac_status=$?
5257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5258   (exit $ac_status); }; }; then
5259   eval "$as_ac_var=yes"
5260 else
5261   echo "$as_me: failed program was:" >&5
5262 sed 's/^/| /' conftest.$ac_ext >&5
5263
5264 eval "$as_ac_var=no"
5265 fi
5266 rm -f conftest.err conftest.$ac_objext \
5267       conftest$ac_exeext conftest.$ac_ext
5268 fi
5269 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
5270 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
5271 if test `eval echo '${'$as_ac_var'}'` = yes; then
5272   cat >>confdefs.h <<_ACEOF
5273 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
5274 _ACEOF
5275
5276 else
5277
5278     gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
5279
5280 fi
5281 done
5282
5283
5284
5285   :
5286
5287
5288
5289
5290
5291   if test $ac_cv_have_decl_memmem = no; then
5292     HAVE_DECL_MEMMEM=0
5293   fi
5294   :
5295
5296
5297
5298   GNULIB_MEMMEM=1
5299
5300
5301
5302
5303   if test $ac_cv_type_long_long_int = yes; then
5304     HAVE_LONG_LONG_INT=1
5305   else
5306     HAVE_LONG_LONG_INT=0
5307   fi
5308
5309
5310   if test $ac_cv_type_unsigned_long_long_int = yes; then
5311     HAVE_UNSIGNED_LONG_LONG_INT=1
5312   else
5313     HAVE_UNSIGNED_LONG_LONG_INT=0
5314   fi
5315
5316
5317       if test $ac_cv_header_inttypes_h = yes; then
5318     HAVE_INTTYPES_H=1
5319   else
5320     HAVE_INTTYPES_H=0
5321   fi
5322
5323
5324       if test $ac_cv_header_sys_types_h = yes; then
5325     HAVE_SYS_TYPES_H=1
5326   else
5327     HAVE_SYS_TYPES_H=0
5328   fi
5329
5330
5331
5332
5333
5334   :
5335
5336
5337
5338
5339
5340
5341
5342      if test $gl_cv_have_include_next = yes; then
5343        gl_cv_next_stdint_h='<'stdint.h'>'
5344      else
5345        echo "$as_me:$LINENO: checking absolute name of <stdint.h>" >&5
5346 echo $ECHO_N "checking absolute name of <stdint.h>... $ECHO_C" >&6
5347 if test "${gl_cv_next_stdint_h+set}" = set; then
5348   echo $ECHO_N "(cached) $ECHO_C" >&6
5349 else
5350
5351           if test $ac_cv_header_stdint_h = yes; then
5352             cat >conftest.$ac_ext <<_ACEOF
5353 /* confdefs.h.  */
5354 _ACEOF
5355 cat confdefs.h >>conftest.$ac_ext
5356 cat >>conftest.$ac_ext <<_ACEOF
5357 /* end confdefs.h.  */
5358 #include <stdint.h>
5359
5360 _ACEOF
5361                                     gl_cv_next_stdint_h='"'`(eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5362                sed -n '\#/stdint.h#{
5363                  s#.*"\(.*/stdint.h\)".*#\1#
5364                  s#^/[^/]#//&#
5365                  p
5366                  q
5367                }'`'"'
5368           else
5369             gl_cv_next_stdint_h='<'stdint.h'>'
5370           fi
5371
5372 fi
5373 echo "$as_me:$LINENO: result: $gl_cv_next_stdint_h" >&5
5374 echo "${ECHO_T}$gl_cv_next_stdint_h" >&6
5375      fi
5376      NEXT_STDINT_H=$gl_cv_next_stdint_h
5377
5378
5379
5380   if test $ac_cv_header_stdint_h = yes; then
5381     HAVE_STDINT_H=1
5382   else
5383     HAVE_STDINT_H=0
5384   fi
5385
5386
5387     if test $ac_cv_header_stdint_h = yes; then
5388     echo "$as_me:$LINENO: checking whether stdint.h conforms to C99" >&5
5389 echo $ECHO_N "checking whether stdint.h conforms to C99... $ECHO_C" >&6
5390 if test "${gl_cv_header_working_stdint_h+set}" = set; then
5391   echo $ECHO_N "(cached) $ECHO_C" >&6
5392 else
5393   gl_cv_header_working_stdint_h=no
5394        cat >conftest.$ac_ext <<_ACEOF
5395
5396          /* confdefs.h.  */
5397 _ACEOF
5398 cat confdefs.h >>conftest.$ac_ext
5399 cat >>conftest.$ac_ext <<_ACEOF
5400 /* end confdefs.h.  */
5401
5402 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
5403 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
5404 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
5405 #include <stdint.h>
5406 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>.  */
5407 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
5408 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
5409 #endif
5410
5411
5412   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
5413      included before <wchar.h>.  */
5414   #include <stddef.h>
5415   #include <signal.h>
5416   #if HAVE_WCHAR_H
5417   # include <stdio.h>
5418   # include <time.h>
5419   # include <wchar.h>
5420   #endif
5421
5422
5423 #ifdef INT8_MAX
5424 int8_t a1 = INT8_MAX;
5425 int8_t a1min = INT8_MIN;
5426 #endif
5427 #ifdef INT16_MAX
5428 int16_t a2 = INT16_MAX;
5429 int16_t a2min = INT16_MIN;
5430 #endif
5431 #ifdef INT32_MAX
5432 int32_t a3 = INT32_MAX;
5433 int32_t a3min = INT32_MIN;
5434 #endif
5435 #ifdef INT64_MAX
5436 int64_t a4 = INT64_MAX;
5437 int64_t a4min = INT64_MIN;
5438 #endif
5439 #ifdef UINT8_MAX
5440 uint8_t b1 = UINT8_MAX;
5441 #else
5442 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
5443 #endif
5444 #ifdef UINT16_MAX
5445 uint16_t b2 = UINT16_MAX;
5446 #endif
5447 #ifdef UINT32_MAX
5448 uint32_t b3 = UINT32_MAX;
5449 #endif
5450 #ifdef UINT64_MAX
5451 uint64_t b4 = UINT64_MAX;
5452 #endif
5453 int_least8_t c1 = INT8_C (0x7f);
5454 int_least8_t c1max = INT_LEAST8_MAX;
5455 int_least8_t c1min = INT_LEAST8_MIN;
5456 int_least16_t c2 = INT16_C (0x7fff);
5457 int_least16_t c2max = INT_LEAST16_MAX;
5458 int_least16_t c2min = INT_LEAST16_MIN;
5459 int_least32_t c3 = INT32_C (0x7fffffff);
5460 int_least32_t c3max = INT_LEAST32_MAX;
5461 int_least32_t c3min = INT_LEAST32_MIN;
5462 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
5463 int_least64_t c4max = INT_LEAST64_MAX;
5464 int_least64_t c4min = INT_LEAST64_MIN;
5465 uint_least8_t d1 = UINT8_C (0xff);
5466 uint_least8_t d1max = UINT_LEAST8_MAX;
5467 uint_least16_t d2 = UINT16_C (0xffff);
5468 uint_least16_t d2max = UINT_LEAST16_MAX;
5469 uint_least32_t d3 = UINT32_C (0xffffffff);
5470 uint_least32_t d3max = UINT_LEAST32_MAX;
5471 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
5472 uint_least64_t d4max = UINT_LEAST64_MAX;
5473 int_fast8_t e1 = INT_FAST8_MAX;
5474 int_fast8_t e1min = INT_FAST8_MIN;
5475 int_fast16_t e2 = INT_FAST16_MAX;
5476 int_fast16_t e2min = INT_FAST16_MIN;
5477 int_fast32_t e3 = INT_FAST32_MAX;
5478 int_fast32_t e3min = INT_FAST32_MIN;
5479 int_fast64_t e4 = INT_FAST64_MAX;
5480 int_fast64_t e4min = INT_FAST64_MIN;
5481 uint_fast8_t f1 = UINT_FAST8_MAX;
5482 uint_fast16_t f2 = UINT_FAST16_MAX;
5483 uint_fast32_t f3 = UINT_FAST32_MAX;
5484 uint_fast64_t f4 = UINT_FAST64_MAX;
5485 #ifdef INTPTR_MAX
5486 intptr_t g = INTPTR_MAX;
5487 intptr_t gmin = INTPTR_MIN;
5488 #endif
5489 #ifdef UINTPTR_MAX
5490 uintptr_t h = UINTPTR_MAX;
5491 #endif
5492 intmax_t i = INTMAX_MAX;
5493 uintmax_t j = UINTMAX_MAX;
5494
5495 #include <limits.h> /* for CHAR_BIT */
5496 #define TYPE_MINIMUM(t) \
5497   ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ (t) 0 << (sizeof (t) * CHAR_BIT - 1)))
5498 #define TYPE_MAXIMUM(t) \
5499   ((t) ((t) 0 < (t) -1 ? (t) -1 : ~ (~ (t) 0 << (sizeof (t) * CHAR_BIT - 1))))
5500 struct s {
5501   int check_PTRDIFF:
5502       PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
5503       && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
5504       ? 1 : -1;
5505   /* Detect bug in FreeBSD 6.0 / ia64.  */
5506   int check_SIG_ATOMIC:
5507       SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
5508       && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
5509       ? 1 : -1;
5510   int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
5511   int check_WCHAR:
5512       WCHAR_MIN == TYPE_MINIMUM (wchar_t)
5513       && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
5514       ? 1 : -1;
5515   /* Detect bug in mingw.  */
5516   int check_WINT:
5517       WINT_MIN == TYPE_MINIMUM (wint_t)
5518       && WINT_MAX == TYPE_MAXIMUM (wint_t)
5519       ? 1 : -1;
5520
5521   /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others.  */
5522   int check_UINT8_C:
5523         (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
5524   int check_UINT16_C:
5525         (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
5526
5527   /* Detect bugs in OpenBSD 3.9 stdint.h.  */
5528 #ifdef UINT8_MAX
5529   int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
5530 #endif
5531 #ifdef UINT16_MAX
5532   int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
5533 #endif
5534 #ifdef UINT32_MAX
5535   int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
5536 #endif
5537 #ifdef UINT64_MAX
5538   int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
5539 #endif
5540   int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
5541   int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
5542   int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
5543   int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
5544   int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
5545   int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
5546   int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
5547   int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
5548   int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
5549   int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
5550   int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
5551 };
5552
5553 int
5554 main ()
5555 {
5556
5557   ;
5558   return 0;
5559 }
5560 _ACEOF
5561 rm -f conftest.$ac_objext
5562 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5563   (eval $ac_compile) 2>conftest.er1
5564   ac_status=$?
5565   grep -v '^ *+' conftest.er1 >conftest.err
5566   rm -f conftest.er1
5567   cat conftest.err >&5
5568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5569   (exit $ac_status); } &&
5570          { ac_try='test -z "$ac_c_werror_flag"
5571                          || test ! -s conftest.err'
5572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5573   (eval $ac_try) 2>&5
5574   ac_status=$?
5575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5576   (exit $ac_status); }; } &&
5577          { ac_try='test -s conftest.$ac_objext'
5578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5579   (eval $ac_try) 2>&5
5580   ac_status=$?
5581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5582   (exit $ac_status); }; }; then
5583   gl_cv_header_working_stdint_h=yes
5584 else
5585   echo "$as_me: failed program was:" >&5
5586 sed 's/^/| /' conftest.$ac_ext >&5
5587
5588 fi
5589 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5590 fi
5591 echo "$as_me:$LINENO: result: $gl_cv_header_working_stdint_h" >&5
5592 echo "${ECHO_T}$gl_cv_header_working_stdint_h" >&6
5593   fi
5594   if test "$gl_cv_header_working_stdint_h" = yes; then
5595     STDINT_H=
5596   else
5597
5598
5599 for ac_header in sys/inttypes.h sys/bitypes.h
5600 do
5601 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5602 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5603   echo "$as_me:$LINENO: checking for $ac_header" >&5
5604 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5605 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5606   echo $ECHO_N "(cached) $ECHO_C" >&6
5607 fi
5608 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5609 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5610 else
5611   # Is the header compilable?
5612 echo "$as_me:$LINENO: checking $ac_header usability" >&5
5613 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5614 cat >conftest.$ac_ext <<_ACEOF
5615 /* confdefs.h.  */
5616 _ACEOF
5617 cat confdefs.h >>conftest.$ac_ext
5618 cat >>conftest.$ac_ext <<_ACEOF
5619 /* end confdefs.h.  */
5620 $ac_includes_default
5621 #include <$ac_header>
5622 _ACEOF
5623 rm -f conftest.$ac_objext
5624 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5625   (eval $ac_compile) 2>conftest.er1
5626   ac_status=$?
5627   grep -v '^ *+' conftest.er1 >conftest.err
5628   rm -f conftest.er1
5629   cat conftest.err >&5
5630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5631   (exit $ac_status); } &&
5632          { ac_try='test -z "$ac_c_werror_flag"
5633                          || test ! -s conftest.err'
5634   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5635   (eval $ac_try) 2>&5
5636   ac_status=$?
5637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5638   (exit $ac_status); }; } &&
5639          { ac_try='test -s conftest.$ac_objext'
5640   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5641   (eval $ac_try) 2>&5
5642   ac_status=$?
5643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5644   (exit $ac_status); }; }; then
5645   ac_header_compiler=yes
5646 else
5647   echo "$as_me: failed program was:" >&5
5648 sed 's/^/| /' conftest.$ac_ext >&5
5649
5650 ac_header_compiler=no
5651 fi
5652 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5653 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5654 echo "${ECHO_T}$ac_header_compiler" >&6
5655
5656 # Is the header present?
5657 echo "$as_me:$LINENO: checking $ac_header presence" >&5
5658 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5659 cat >conftest.$ac_ext <<_ACEOF
5660 /* confdefs.h.  */
5661 _ACEOF
5662 cat confdefs.h >>conftest.$ac_ext
5663 cat >>conftest.$ac_ext <<_ACEOF
5664 /* end confdefs.h.  */
5665 #include <$ac_header>
5666 _ACEOF
5667 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5668   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5669   ac_status=$?
5670   grep -v '^ *+' conftest.er1 >conftest.err
5671   rm -f conftest.er1
5672   cat conftest.err >&5
5673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5674   (exit $ac_status); } >/dev/null; then
5675   if test -s conftest.err; then
5676     ac_cpp_err=$ac_c_preproc_warn_flag
5677     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
5678   else
5679     ac_cpp_err=
5680   fi
5681 else
5682   ac_cpp_err=yes
5683 fi
5684 if test -z "$ac_cpp_err"; then
5685   ac_header_preproc=yes
5686 else
5687   echo "$as_me: failed program was:" >&5
5688 sed 's/^/| /' conftest.$ac_ext >&5
5689
5690   ac_header_preproc=no
5691 fi
5692 rm -f conftest.err conftest.$ac_ext
5693 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5694 echo "${ECHO_T}$ac_header_preproc" >&6
5695
5696 # So?  What about this header?
5697 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5698   yes:no: )
5699     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5700 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
5701     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5702 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5703     ac_header_preproc=yes
5704     ;;
5705   no:yes:* )
5706     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5707 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
5708     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
5709 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
5710     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5711 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5712     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
5713 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
5714     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
5715 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5716     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5717 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
5718     (
5719       cat <<\_ASBOX
5720 ## ------------------------------------------ ##
5721 ## Report this to the AC_PACKAGE_NAME lists.  ##
5722 ## ------------------------------------------ ##
5723 _ASBOX
5724     ) |
5725       sed "s/^/$as_me: WARNING:     /" >&2
5726     ;;
5727 esac
5728 echo "$as_me:$LINENO: checking for $ac_header" >&5
5729 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5730 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5731   echo $ECHO_N "(cached) $ECHO_C" >&6
5732 else
5733   eval "$as_ac_Header=\$ac_header_preproc"
5734 fi
5735 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5736 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5737
5738 fi
5739 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5740   cat >>confdefs.h <<_ACEOF
5741 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5742 _ACEOF
5743
5744 fi
5745
5746 done
5747
5748     if test $ac_cv_header_sys_inttypes_h = yes; then
5749       HAVE_SYS_INTTYPES_H=1
5750     else
5751       HAVE_SYS_INTTYPES_H=0
5752     fi
5753
5754     if test $ac_cv_header_sys_bitypes_h = yes; then
5755       HAVE_SYS_BITYPES_H=1
5756     else
5757       HAVE_SYS_BITYPES_H=0
5758     fi
5759
5760
5761
5762   :
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777   for gltype in ptrdiff_t sig_atomic_t size_t wchar_t wint_t ; do
5778     echo "$as_me:$LINENO: checking for bit size of $gltype" >&5
5779 echo $ECHO_N "checking for bit size of $gltype... $ECHO_C" >&6
5780 if eval "test \"\${gl_cv_bitsizeof_${gltype}+set}\" = set"; then
5781   echo $ECHO_N "(cached) $ECHO_C" >&6
5782 else
5783   if test "$cross_compiling" = yes; then
5784   # Depending upon the size, compute the lo and hi bounds.
5785 cat >conftest.$ac_ext <<_ACEOF
5786 /* confdefs.h.  */
5787 _ACEOF
5788 cat confdefs.h >>conftest.$ac_ext
5789 cat >>conftest.$ac_ext <<_ACEOF
5790 /* end confdefs.h.  */
5791
5792   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
5793      included before <wchar.h>.  */
5794   #include <stddef.h>
5795   #include <signal.h>
5796   #if HAVE_WCHAR_H
5797   # include <stdio.h>
5798   # include <time.h>
5799   # include <wchar.h>
5800   #endif
5801
5802 #include <limits.h>
5803 int
5804 main ()
5805 {
5806 static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= 0)];
5807 test_array [0] = 0
5808
5809   ;
5810   return 0;
5811 }
5812 _ACEOF
5813 rm -f conftest.$ac_objext
5814 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5815   (eval $ac_compile) 2>conftest.er1
5816   ac_status=$?
5817   grep -v '^ *+' conftest.er1 >conftest.err
5818   rm -f conftest.er1
5819   cat conftest.err >&5
5820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5821   (exit $ac_status); } &&
5822          { ac_try='test -z "$ac_c_werror_flag"
5823                          || test ! -s conftest.err'
5824   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5825   (eval $ac_try) 2>&5
5826   ac_status=$?
5827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5828   (exit $ac_status); }; } &&
5829          { ac_try='test -s conftest.$ac_objext'
5830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5831   (eval $ac_try) 2>&5
5832   ac_status=$?
5833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5834   (exit $ac_status); }; }; then
5835   ac_lo=0 ac_mid=0
5836   while :; do
5837     cat >conftest.$ac_ext <<_ACEOF
5838 /* confdefs.h.  */
5839 _ACEOF
5840 cat confdefs.h >>conftest.$ac_ext
5841 cat >>conftest.$ac_ext <<_ACEOF
5842 /* end confdefs.h.  */
5843
5844   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
5845      included before <wchar.h>.  */
5846   #include <stddef.h>
5847   #include <signal.h>
5848   #if HAVE_WCHAR_H
5849   # include <stdio.h>
5850   # include <time.h>
5851   # include <wchar.h>
5852   #endif
5853
5854 #include <limits.h>
5855 int
5856 main ()
5857 {
5858 static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)];
5859 test_array [0] = 0
5860
5861   ;
5862   return 0;
5863 }
5864 _ACEOF
5865 rm -f conftest.$ac_objext
5866 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5867   (eval $ac_compile) 2>conftest.er1
5868   ac_status=$?
5869   grep -v '^ *+' conftest.er1 >conftest.err
5870   rm -f conftest.er1
5871   cat conftest.err >&5
5872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5873   (exit $ac_status); } &&
5874          { ac_try='test -z "$ac_c_werror_flag"
5875                          || test ! -s conftest.err'
5876   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5877   (eval $ac_try) 2>&5
5878   ac_status=$?
5879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5880   (exit $ac_status); }; } &&
5881          { ac_try='test -s conftest.$ac_objext'
5882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5883   (eval $ac_try) 2>&5
5884   ac_status=$?
5885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5886   (exit $ac_status); }; }; then
5887   ac_hi=$ac_mid; break
5888 else
5889   echo "$as_me: failed program was:" >&5
5890 sed 's/^/| /' conftest.$ac_ext >&5
5891
5892 ac_lo=`expr $ac_mid + 1`
5893                     if test $ac_lo -le $ac_mid; then
5894                       ac_lo= ac_hi=
5895                       break
5896                     fi
5897                     ac_mid=`expr 2 '*' $ac_mid + 1`
5898 fi
5899 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5900   done
5901 else
5902   echo "$as_me: failed program was:" >&5
5903 sed 's/^/| /' conftest.$ac_ext >&5
5904
5905 cat >conftest.$ac_ext <<_ACEOF
5906 /* confdefs.h.  */
5907 _ACEOF
5908 cat confdefs.h >>conftest.$ac_ext
5909 cat >>conftest.$ac_ext <<_ACEOF
5910 /* end confdefs.h.  */
5911
5912   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
5913      included before <wchar.h>.  */
5914   #include <stddef.h>
5915   #include <signal.h>
5916   #if HAVE_WCHAR_H
5917   # include <stdio.h>
5918   # include <time.h>
5919   # include <wchar.h>
5920   #endif
5921
5922 #include <limits.h>
5923 int
5924 main ()
5925 {
5926 static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) < 0)];
5927 test_array [0] = 0
5928
5929   ;
5930   return 0;
5931 }
5932 _ACEOF
5933 rm -f conftest.$ac_objext
5934 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5935   (eval $ac_compile) 2>conftest.er1
5936   ac_status=$?
5937   grep -v '^ *+' conftest.er1 >conftest.err
5938   rm -f conftest.er1
5939   cat conftest.err >&5
5940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5941   (exit $ac_status); } &&
5942          { ac_try='test -z "$ac_c_werror_flag"
5943                          || test ! -s conftest.err'
5944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5945   (eval $ac_try) 2>&5
5946   ac_status=$?
5947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5948   (exit $ac_status); }; } &&
5949          { ac_try='test -s conftest.$ac_objext'
5950   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5951   (eval $ac_try) 2>&5
5952   ac_status=$?
5953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5954   (exit $ac_status); }; }; then
5955   ac_hi=-1 ac_mid=-1
5956   while :; do
5957     cat >conftest.$ac_ext <<_ACEOF
5958 /* confdefs.h.  */
5959 _ACEOF
5960 cat confdefs.h >>conftest.$ac_ext
5961 cat >>conftest.$ac_ext <<_ACEOF
5962 /* end confdefs.h.  */
5963
5964   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
5965      included before <wchar.h>.  */
5966   #include <stddef.h>
5967   #include <signal.h>
5968   #if HAVE_WCHAR_H
5969   # include <stdio.h>
5970   # include <time.h>
5971   # include <wchar.h>
5972   #endif
5973
5974 #include <limits.h>
5975 int
5976 main ()
5977 {
5978 static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= $ac_mid)];
5979 test_array [0] = 0
5980
5981   ;
5982   return 0;
5983 }
5984 _ACEOF
5985 rm -f conftest.$ac_objext
5986 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5987   (eval $ac_compile) 2>conftest.er1
5988   ac_status=$?
5989   grep -v '^ *+' conftest.er1 >conftest.err
5990   rm -f conftest.er1
5991   cat conftest.err >&5
5992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5993   (exit $ac_status); } &&
5994          { ac_try='test -z "$ac_c_werror_flag"
5995                          || test ! -s conftest.err'
5996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5997   (eval $ac_try) 2>&5
5998   ac_status=$?
5999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6000   (exit $ac_status); }; } &&
6001          { ac_try='test -s conftest.$ac_objext'
6002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6003   (eval $ac_try) 2>&5
6004   ac_status=$?
6005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6006   (exit $ac_status); }; }; then
6007   ac_lo=$ac_mid; break
6008 else
6009   echo "$as_me: failed program was:" >&5
6010 sed 's/^/| /' conftest.$ac_ext >&5
6011
6012 ac_hi=`expr '(' $ac_mid ')' - 1`
6013                        if test $ac_mid -le $ac_hi; then
6014                          ac_lo= ac_hi=
6015                          break
6016                        fi
6017                        ac_mid=`expr 2 '*' $ac_mid`
6018 fi
6019 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6020   done
6021 else
6022   echo "$as_me: failed program was:" >&5
6023 sed 's/^/| /' conftest.$ac_ext >&5
6024
6025 ac_lo= ac_hi=
6026 fi
6027 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6028 fi
6029 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6030 # Binary search between lo and hi bounds.
6031 while test "x$ac_lo" != "x$ac_hi"; do
6032   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6033   cat >conftest.$ac_ext <<_ACEOF
6034 /* confdefs.h.  */
6035 _ACEOF
6036 cat confdefs.h >>conftest.$ac_ext
6037 cat >>conftest.$ac_ext <<_ACEOF
6038 /* end confdefs.h.  */
6039
6040   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6041      included before <wchar.h>.  */
6042   #include <stddef.h>
6043   #include <signal.h>
6044   #if HAVE_WCHAR_H
6045   # include <stdio.h>
6046   # include <time.h>
6047   # include <wchar.h>
6048   #endif
6049
6050 #include <limits.h>
6051 int
6052 main ()
6053 {
6054 static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)];
6055 test_array [0] = 0
6056
6057   ;
6058   return 0;
6059 }
6060 _ACEOF
6061 rm -f conftest.$ac_objext
6062 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6063   (eval $ac_compile) 2>conftest.er1
6064   ac_status=$?
6065   grep -v '^ *+' conftest.er1 >conftest.err
6066   rm -f conftest.er1
6067   cat conftest.err >&5
6068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6069   (exit $ac_status); } &&
6070          { ac_try='test -z "$ac_c_werror_flag"
6071                          || test ! -s conftest.err'
6072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6073   (eval $ac_try) 2>&5
6074   ac_status=$?
6075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6076   (exit $ac_status); }; } &&
6077          { ac_try='test -s conftest.$ac_objext'
6078   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6079   (eval $ac_try) 2>&5
6080   ac_status=$?
6081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6082   (exit $ac_status); }; }; then
6083   ac_hi=$ac_mid
6084 else
6085   echo "$as_me: failed program was:" >&5
6086 sed 's/^/| /' conftest.$ac_ext >&5
6087
6088 ac_lo=`expr '(' $ac_mid ')' + 1`
6089 fi
6090 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6091 done
6092 case $ac_lo in
6093 ?*) result=$ac_lo;;
6094 '') result=unknown ;;
6095 esac
6096 else
6097   if test "$cross_compiling" = yes; then
6098   { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
6099 echo "$as_me: error: in \`$ac_pwd':" >&2;}
6100 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
6101 See \`config.log' for more details." >&5
6102 echo "$as_me: error: cannot run test program while cross compiling
6103 See \`config.log' for more details." >&2;}
6104    { (exit 1); exit 1; }; }; }
6105 else
6106   cat >conftest.$ac_ext <<_ACEOF
6107 /* confdefs.h.  */
6108 _ACEOF
6109 cat confdefs.h >>conftest.$ac_ext
6110 cat >>conftest.$ac_ext <<_ACEOF
6111 /* end confdefs.h.  */
6112
6113   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6114      included before <wchar.h>.  */
6115   #include <stddef.h>
6116   #include <signal.h>
6117   #if HAVE_WCHAR_H
6118   # include <stdio.h>
6119   # include <time.h>
6120   # include <wchar.h>
6121   #endif
6122
6123 #include <limits.h>
6124 long longval () { return sizeof ($gltype) * CHAR_BIT; }
6125 unsigned long ulongval () { return sizeof ($gltype) * CHAR_BIT; }
6126 #include <stdio.h>
6127 #include <stdlib.h>
6128 int
6129 main ()
6130 {
6131
6132   FILE *f = fopen ("conftest.val", "w");
6133   if (! f)
6134     exit (1);
6135   if ((sizeof ($gltype) * CHAR_BIT) < 0)
6136     {
6137       long i = longval ();
6138       if (i != (sizeof ($gltype) * CHAR_BIT))
6139         exit (1);
6140       fprintf (f, "%ld\n", i);
6141     }
6142   else
6143     {
6144       unsigned long i = ulongval ();
6145       if (i != (sizeof ($gltype) * CHAR_BIT))
6146         exit (1);
6147       fprintf (f, "%lu\n", i);
6148     }
6149   exit (ferror (f) || fclose (f) != 0);
6150
6151   ;
6152   return 0;
6153 }
6154 _ACEOF
6155 rm -f conftest$ac_exeext
6156 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6157   (eval $ac_link) 2>&5
6158   ac_status=$?
6159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6160   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6162   (eval $ac_try) 2>&5
6163   ac_status=$?
6164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6165   (exit $ac_status); }; }; then
6166   result=`cat conftest.val`
6167 else
6168   echo "$as_me: program exited with status $ac_status" >&5
6169 echo "$as_me: failed program was:" >&5
6170 sed 's/^/| /' conftest.$ac_ext >&5
6171
6172 ( exit $ac_status )
6173 result=unknown
6174 fi
6175 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6176 fi
6177 fi
6178 rm -f conftest.val
6179        eval gl_cv_bitsizeof_${gltype}=\$result
6180
6181 fi
6182 echo "$as_me:$LINENO: result: `eval echo '${'gl_cv_bitsizeof_${gltype}'}'`" >&5
6183 echo "${ECHO_T}`eval echo '${'gl_cv_bitsizeof_${gltype}'}'`" >&6
6184     eval result=\$gl_cv_bitsizeof_${gltype}
6185     if test $result = unknown; then
6186                                                 result=0
6187     fi
6188     GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6189     cat >>confdefs.h <<_ACEOF
6190 #define BITSIZEOF_${GLTYPE} $result
6191 _ACEOF
6192
6193     eval BITSIZEOF_${GLTYPE}=\$result
6194   done
6195
6196
6197
6198
6199
6200
6201
6202   for gltype in sig_atomic_t wchar_t wint_t ; do
6203     echo "$as_me:$LINENO: checking whether $gltype is signed" >&5
6204 echo $ECHO_N "checking whether $gltype is signed... $ECHO_C" >&6
6205 if eval "test \"\${gl_cv_type_${gltype}_signed+set}\" = set"; then
6206   echo $ECHO_N "(cached) $ECHO_C" >&6
6207 else
6208   cat >conftest.$ac_ext <<_ACEOF
6209 /* confdefs.h.  */
6210 _ACEOF
6211 cat confdefs.h >>conftest.$ac_ext
6212 cat >>conftest.$ac_ext <<_ACEOF
6213 /* end confdefs.h.  */
6214
6215   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6216      included before <wchar.h>.  */
6217   #include <stddef.h>
6218   #include <signal.h>
6219   #if HAVE_WCHAR_H
6220   # include <stdio.h>
6221   # include <time.h>
6222   # include <wchar.h>
6223   #endif
6224
6225             int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
6226 int
6227 main ()
6228 {
6229
6230   ;
6231   return 0;
6232 }
6233 _ACEOF
6234 rm -f conftest.$ac_objext
6235 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6236   (eval $ac_compile) 2>conftest.er1
6237   ac_status=$?
6238   grep -v '^ *+' conftest.er1 >conftest.err
6239   rm -f conftest.er1
6240   cat conftest.err >&5
6241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6242   (exit $ac_status); } &&
6243          { ac_try='test -z "$ac_c_werror_flag"
6244                          || test ! -s conftest.err'
6245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6246   (eval $ac_try) 2>&5
6247   ac_status=$?
6248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6249   (exit $ac_status); }; } &&
6250          { ac_try='test -s conftest.$ac_objext'
6251   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6252   (eval $ac_try) 2>&5
6253   ac_status=$?
6254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6255   (exit $ac_status); }; }; then
6256   result=yes
6257 else
6258   echo "$as_me: failed program was:" >&5
6259 sed 's/^/| /' conftest.$ac_ext >&5
6260
6261 result=no
6262 fi
6263 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6264        eval gl_cv_type_${gltype}_signed=\$result
6265
6266 fi
6267 echo "$as_me:$LINENO: result: `eval echo '${'gl_cv_type_${gltype}_signed'}'`" >&5
6268 echo "${ECHO_T}`eval echo '${'gl_cv_type_${gltype}_signed'}'`" >&6
6269     eval result=\$gl_cv_type_${gltype}_signed
6270     GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6271     if test "$result" = yes; then
6272       cat >>confdefs.h <<_ACEOF
6273 #define HAVE_SIGNED_${GLTYPE} 1
6274 _ACEOF
6275
6276       eval HAVE_SIGNED_${GLTYPE}=1
6277     else
6278       eval HAVE_SIGNED_${GLTYPE}=0
6279     fi
6280   done
6281
6282
6283   gl_cv_type_ptrdiff_t_signed=yes
6284   gl_cv_type_size_t_signed=no
6285
6286
6287
6288
6289
6290
6291
6292   for gltype in ptrdiff_t sig_atomic_t size_t wchar_t wint_t ; do
6293     echo "$as_me:$LINENO: checking for $gltype integer literal suffix" >&5
6294 echo $ECHO_N "checking for $gltype integer literal suffix... $ECHO_C" >&6
6295 if eval "test \"\${gl_cv_type_${gltype}_suffix+set}\" = set"; then
6296   echo $ECHO_N "(cached) $ECHO_C" >&6
6297 else
6298   eval gl_cv_type_${gltype}_suffix=no
6299        eval result=\$gl_cv_type_${gltype}_signed
6300        if test "$result" = yes; then
6301          glsufu=
6302        else
6303          glsufu=u
6304        fi
6305        for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
6306          case $glsuf in
6307            '')  gltype1='int';;
6308            l)   gltype1='long int';;
6309            ll)  gltype1='long long int';;
6310            i64) gltype1='__int64';;
6311            u)   gltype1='unsigned int';;
6312            ul)  gltype1='unsigned long int';;
6313            ull) gltype1='unsigned long long int';;
6314            ui64)gltype1='unsigned __int64';;
6315          esac
6316          cat >conftest.$ac_ext <<_ACEOF
6317 /* confdefs.h.  */
6318 _ACEOF
6319 cat confdefs.h >>conftest.$ac_ext
6320 cat >>conftest.$ac_ext <<_ACEOF
6321 /* end confdefs.h.  */
6322
6323   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
6324      included before <wchar.h>.  */
6325   #include <stddef.h>
6326   #include <signal.h>
6327   #if HAVE_WCHAR_H
6328   # include <stdio.h>
6329   # include <time.h>
6330   # include <wchar.h>
6331   #endif
6332
6333               extern $gltype foo;
6334               extern $gltype1 foo;
6335 int
6336 main ()
6337 {
6338
6339   ;
6340   return 0;
6341 }
6342 _ACEOF
6343 rm -f conftest.$ac_objext
6344 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6345   (eval $ac_compile) 2>conftest.er1
6346   ac_status=$?
6347   grep -v '^ *+' conftest.er1 >conftest.err
6348   rm -f conftest.er1
6349   cat conftest.err >&5
6350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6351   (exit $ac_status); } &&
6352          { ac_try='test -z "$ac_c_werror_flag"
6353                          || test ! -s conftest.err'
6354   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6355   (eval $ac_try) 2>&5
6356   ac_status=$?
6357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6358   (exit $ac_status); }; } &&
6359          { ac_try='test -s conftest.$ac_objext'
6360   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6361   (eval $ac_try) 2>&5
6362   ac_status=$?
6363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6364   (exit $ac_status); }; }; then
6365   eval gl_cv_type_${gltype}_suffix=\$glsuf
6366 else
6367   echo "$as_me: failed program was:" >&5
6368 sed 's/^/| /' conftest.$ac_ext >&5
6369
6370 fi
6371 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6372          eval result=\$gl_cv_type_${gltype}_suffix
6373          test "$result" != no && break
6374        done
6375 fi
6376 echo "$as_me:$LINENO: result: `eval echo '${'gl_cv_type_${gltype}_suffix'}'`" >&5
6377 echo "${ECHO_T}`eval echo '${'gl_cv_type_${gltype}_suffix'}'`" >&6
6378     GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
6379     eval result=\$gl_cv_type_${gltype}_suffix
6380     test "$result" = no && result=
6381     eval ${GLTYPE}_SUFFIX=\$result
6382     cat >>confdefs.h <<_ACEOF
6383 #define ${GLTYPE}_SUFFIX $result
6384 _ACEOF
6385
6386   done
6387
6388
6389
6390     STDINT_H=stdint.h
6391   fi
6392
6393
6394
6395
6396
6397
6398
6399   echo "$as_me:$LINENO: checking whether <wchar.h> is standalone" >&5
6400 echo $ECHO_N "checking whether <wchar.h> is standalone... $ECHO_C" >&6
6401 if test "${gl_cv_header_wchar_h_standalone+set}" = set; then
6402   echo $ECHO_N "(cached) $ECHO_C" >&6
6403 else
6404   cat >conftest.$ac_ext <<_ACEOF
6405 #include <wchar.h>
6406 wchar_t w;
6407 _ACEOF
6408 rm -f conftest.$ac_objext
6409 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6410   (eval $ac_compile) 2>conftest.er1
6411   ac_status=$?
6412   grep -v '^ *+' conftest.er1 >conftest.err
6413   rm -f conftest.er1
6414   cat conftest.err >&5
6415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6416   (exit $ac_status); } &&
6417          { ac_try='test -z "$ac_c_werror_flag"
6418                          || test ! -s conftest.err'
6419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6420   (eval $ac_try) 2>&5
6421   ac_status=$?
6422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6423   (exit $ac_status); }; } &&
6424          { ac_try='test -s conftest.$ac_objext'
6425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6426   (eval $ac_try) 2>&5
6427   ac_status=$?
6428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6429   (exit $ac_status); }; }; then
6430   gl_cv_header_wchar_h_standalone=yes
6431 else
6432   echo "$as_me: failed program was:" >&5
6433 sed 's/^/| /' conftest.$ac_ext >&5
6434
6435 gl_cv_header_wchar_h_standalone=no
6436 fi
6437 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6438 fi
6439 echo "$as_me:$LINENO: result: $gl_cv_header_wchar_h_standalone" >&5
6440 echo "${ECHO_T}$gl_cv_header_wchar_h_standalone" >&6
6441   if test $gl_cv_header_wchar_h_standalone != yes; then
6442     WCHAR_H=wchar.h
6443   fi
6444
6445
6446   :
6447
6448
6449
6450
6451
6452   if test $ac_cv_header_wchar_h = yes; then
6453     HAVE_WCHAR_H=1
6454   else
6455     HAVE_WCHAR_H=0
6456   fi
6457
6458
6459
6460
6461   :
6462
6463
6464
6465
6466
6467
6468
6469      if test $gl_cv_have_include_next = yes; then
6470        gl_cv_next_wchar_h='<'wchar.h'>'
6471      else
6472        echo "$as_me:$LINENO: checking absolute name of <wchar.h>" >&5
6473 echo $ECHO_N "checking absolute name of <wchar.h>... $ECHO_C" >&6
6474 if test "${gl_cv_next_wchar_h+set}" = set; then
6475   echo $ECHO_N "(cached) $ECHO_C" >&6
6476 else
6477
6478           if test $ac_cv_header_wchar_h = yes; then
6479             cat >conftest.$ac_ext <<_ACEOF
6480 /* confdefs.h.  */
6481 _ACEOF
6482 cat confdefs.h >>conftest.$ac_ext
6483 cat >>conftest.$ac_ext <<_ACEOF
6484 /* end confdefs.h.  */
6485 #include <wchar.h>
6486
6487 _ACEOF
6488                                     gl_cv_next_wchar_h='"'`(eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6489                sed -n '\#/wchar.h#{
6490                  s#.*"\(.*/wchar.h\)".*#\1#
6491                  s#^/[^/]#//&#
6492                  p
6493                  q
6494                }'`'"'
6495           else
6496             gl_cv_next_wchar_h='<'wchar.h'>'
6497           fi
6498
6499 fi
6500 echo "$as_me:$LINENO: result: $gl_cv_next_wchar_h" >&5
6501 echo "${ECHO_T}$gl_cv_next_wchar_h" >&6
6502      fi
6503      NEXT_WCHAR_H=$gl_cv_next_wchar_h
6504
6505
6506
6507
6508
6509
6510
6511
6512   gltests_libdeps=
6513   gltests_ltlibdeps=
6514
6515
6516
6517   gl_source_base='tests'
6518
6519
6520
6521
6522   LIBGNU_LIBDEPS="$gl_libdeps"
6523
6524   LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
6525
6526
6527
6528 # For Makefile dependencies.
6529 GNULIB_STDINT_H=
6530 if test x"$STDINT_H" != x; then
6531   GNULIB_STDINT_H=gnulib/$STDINT_H
6532 fi
6533
6534
6535 PACKAGE=gdb
6536
6537 cat >>confdefs.h <<_ACEOF
6538 #define PACKAGE "$PACKAGE"
6539 _ACEOF
6540
6541
6542
6543 # GDB does not use automake, but gnulib does.  This line lets us
6544 # generate its Makefile.in.
6545 am__api_version="1.9"
6546 # Find a good install program.  We prefer a C program (faster),
6547 # so one script is as good as another.  But avoid the broken or
6548 # incompatible versions:
6549 # SysV /etc/install, /usr/sbin/install
6550 # SunOS /usr/etc/install
6551 # IRIX /sbin/install
6552 # AIX /bin/install
6553 # AmigaOS /C/install, which installs bootblocks on floppy discs
6554 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6555 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
6556 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6557 # OS/2's system install, which has a completely different semantic
6558 # ./install, which can be erroneously created by make from ./install.sh.
6559 # Reject install programs that cannot install multiple files.
6560 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
6561 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
6562 if test -z "$INSTALL"; then
6563 if test "${ac_cv_path_install+set}" = set; then
6564   echo $ECHO_N "(cached) $ECHO_C" >&6
6565 else
6566   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6567 for as_dir in $PATH
6568 do
6569   IFS=$as_save_IFS
6570   test -z "$as_dir" && as_dir=.
6571   # Account for people who put trailing slashes in PATH elements.
6572 case $as_dir/ in
6573   ./ | .// | /cC/* | \
6574   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
6575   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
6576   /usr/ucb/* ) ;;
6577   *)
6578     # OSF1 and SCO ODT 3.0 have their own names for install.
6579     # Don't use installbsd from OSF since it installs stuff as root
6580     # by default.
6581     for ac_prog in ginstall scoinst install; do
6582       for ac_exec_ext in '' $ac_executable_extensions; do
6583         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
6584           if test $ac_prog = install &&
6585             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6586             # AIX install.  It has an incompatible calling convention.
6587             :
6588           elif test $ac_prog = install &&
6589             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6590             # program-specific install script used by HP pwplus--don't use.
6591             :
6592           else
6593             rm -rf conftest.one conftest.two conftest.dir
6594             echo one > conftest.one
6595             echo two > conftest.two
6596             mkdir conftest.dir
6597             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
6598               test -s conftest.one && test -s conftest.two &&
6599               test -s conftest.dir/conftest.one &&
6600               test -s conftest.dir/conftest.two
6601             then
6602               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
6603               break 3
6604             fi
6605           fi
6606         fi
6607       done
6608     done
6609     ;;
6610 esac
6611 done
6612
6613 rm -rf conftest.one conftest.two conftest.dir
6614
6615 fi
6616   if test "${ac_cv_path_install+set}" = set; then
6617     INSTALL=$ac_cv_path_install
6618   else
6619     # As a last resort, use the slow shell script.  Don't cache a
6620     # value for INSTALL within a source directory, because that will
6621     # break other packages using the cache if that directory is
6622     # removed, or if the value is a relative name.
6623     INSTALL=$ac_install_sh
6624   fi
6625 fi
6626 echo "$as_me:$LINENO: result: $INSTALL" >&5
6627 echo "${ECHO_T}$INSTALL" >&6
6628
6629 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6630 # It thinks the first close brace ends the variable substitution.
6631 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6632
6633 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6634
6635 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6636
6637 echo "$as_me:$LINENO: checking whether build environment is sane" >&5
6638 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
6639 # Just in case
6640 sleep 1
6641 echo timestamp > conftest.file
6642 # Do `set' in a subshell so we don't clobber the current shell's
6643 # arguments.  Must try -L first in case configure is actually a
6644 # symlink; some systems play weird games with the mod time of symlinks
6645 # (eg FreeBSD returns the mod time of the symlink's containing
6646 # directory).
6647 if (
6648    set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
6649    if test "$*" = "X"; then
6650       # -L didn't work.
6651       set X `ls -t $srcdir/configure conftest.file`
6652    fi
6653    rm -f conftest.file
6654    if test "$*" != "X $srcdir/configure conftest.file" \
6655       && test "$*" != "X conftest.file $srcdir/configure"; then
6656
6657       # If neither matched, then we have a broken ls.  This can happen
6658       # if, for instance, CONFIG_SHELL is bash and it inherits a
6659       # broken ls alias from the environment.  This has actually
6660       # happened.  Such a system could not be considered "sane".
6661       { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
6662 alias in your environment" >&5
6663 echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
6664 alias in your environment" >&2;}
6665    { (exit 1); exit 1; }; }
6666    fi
6667
6668    test "$2" = conftest.file
6669    )
6670 then
6671    # Ok.
6672    :
6673 else
6674    { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
6675 Check your system clock" >&5
6676 echo "$as_me: error: newly created file is older than distributed files!
6677 Check your system clock" >&2;}
6678    { (exit 1); exit 1; }; }
6679 fi
6680 echo "$as_me:$LINENO: result: yes" >&5
6681 echo "${ECHO_T}yes" >&6
6682 test "$program_prefix" != NONE &&
6683   program_transform_name="s,^,$program_prefix,;$program_transform_name"
6684 # Use a double $ so make ignores it.
6685 test "$program_suffix" != NONE &&
6686   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
6687 # Double any \ or $.  echo might interpret backslashes.
6688 # By default was `s,x,x', remove it if useless.
6689 cat <<\_ACEOF >conftest.sed
6690 s/[\\$]/&&/g;s/;s,x,x,$//
6691 _ACEOF
6692 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
6693 rm conftest.sed
6694
6695 # expand $ac_aux_dir to an absolute path
6696 am_aux_dir=`cd $ac_aux_dir && pwd`
6697
6698 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
6699 # Use eval to expand $SHELL
6700 if eval "$MISSING --run true"; then
6701   am_missing_run="$MISSING --run "
6702 else
6703   am_missing_run=
6704   { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
6705 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
6706 fi
6707
6708 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
6709   # We used to keeping the `.' as first argument, in order to
6710   # allow $(mkdir_p) to be used without argument.  As in
6711   #   $(mkdir_p) $(somedir)
6712   # where $(somedir) is conditionally defined.  However this is wrong
6713   # for two reasons:
6714   #  1. if the package is installed by a user who cannot write `.'
6715   #     make install will fail,
6716   #  2. the above comment should most certainly read
6717   #     $(mkdir_p) $(DESTDIR)$(somedir)
6718   #     so it does not work when $(somedir) is undefined and
6719   #     $(DESTDIR) is not.
6720   #  To support the latter case, we have to write
6721   #     test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
6722   #  so the `.' trick is pointless.
6723   mkdir_p='mkdir -p --'
6724 else
6725   # On NextStep and OpenStep, the `mkdir' command does not
6726   # recognize any option.  It will interpret all options as
6727   # directories to create, and then abort because `.' already
6728   # exists.
6729   for d in ./-p ./--version;
6730   do
6731     test -d $d && rmdir $d
6732   done
6733   # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
6734   if test -f "$ac_aux_dir/mkinstalldirs"; then
6735     mkdir_p='$(mkinstalldirs)'
6736   else
6737     mkdir_p='$(install_sh) -d'
6738   fi
6739 fi
6740
6741 for ac_prog in gawk mawk nawk awk
6742 do
6743   # Extract the first word of "$ac_prog", so it can be a program name with args.
6744 set dummy $ac_prog; ac_word=$2
6745 echo "$as_me:$LINENO: checking for $ac_word" >&5
6746 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6747 if test "${ac_cv_prog_AWK+set}" = set; then
6748   echo $ECHO_N "(cached) $ECHO_C" >&6
6749 else
6750   if test -n "$AWK"; then
6751   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6752 else
6753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6754 for as_dir in $PATH
6755 do
6756   IFS=$as_save_IFS
6757   test -z "$as_dir" && as_dir=.
6758   for ac_exec_ext in '' $ac_executable_extensions; do
6759   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6760     ac_cv_prog_AWK="$ac_prog"
6761     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6762     break 2
6763   fi
6764 done
6765 done
6766
6767 fi
6768 fi
6769 AWK=$ac_cv_prog_AWK
6770 if test -n "$AWK"; then
6771   echo "$as_me:$LINENO: result: $AWK" >&5
6772 echo "${ECHO_T}$AWK" >&6
6773 else
6774   echo "$as_me:$LINENO: result: no" >&5
6775 echo "${ECHO_T}no" >&6
6776 fi
6777
6778   test -n "$AWK" && break
6779 done
6780
6781           ac_config_commands="$ac_config_commands depfiles"
6782
6783
6784 am_make=${MAKE-make}
6785 cat > confinc << 'END'
6786 am__doit:
6787         @echo done
6788 .PHONY: am__doit
6789 END
6790 # If we don't find an include directive, just comment out the code.
6791 echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
6792 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
6793 am__include="#"
6794 am__quote=
6795 _am_result=none
6796 # First try GNU make style include.
6797 echo "include confinc" > confmf
6798 # We grep out `Entering directory' and `Leaving directory'
6799 # messages which can occur if `w' ends up in MAKEFLAGS.
6800 # In particular we don't look at `^make:' because GNU make might
6801 # be invoked under some other name (usually "gmake"), in which
6802 # case it prints its new name instead of `make'.
6803 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
6804    am__include=include
6805    am__quote=
6806    _am_result=GNU
6807 fi
6808 # Now try BSD make style include.
6809 if test "$am__include" = "#"; then
6810    echo '.include "confinc"' > confmf
6811    if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
6812       am__include=.include
6813       am__quote="\""
6814       _am_result=BSD
6815    fi
6816 fi
6817
6818
6819 echo "$as_me:$LINENO: result: $_am_result" >&5
6820 echo "${ECHO_T}$_am_result" >&6
6821 rm -f confinc confmf
6822
6823 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
6824 if test "${enable_dependency_tracking+set}" = set; then
6825   enableval="$enable_dependency_tracking"
6826
6827 fi;
6828 if test "x$enable_dependency_tracking" != xno; then
6829   am_depcomp="$ac_aux_dir/depcomp"
6830   AMDEPBACKSLASH='\'
6831 fi
6832
6833
6834 if test "x$enable_dependency_tracking" != xno; then
6835   AMDEP_TRUE=
6836   AMDEP_FALSE='#'
6837 else
6838   AMDEP_TRUE='#'
6839   AMDEP_FALSE=
6840 fi
6841
6842
6843
6844 # test to see if srcdir already configured
6845 if test "`cd $srcdir && pwd`" != "`pwd`" &&
6846    test -f $srcdir/config.status; then
6847   { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
6848 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
6849    { (exit 1); exit 1; }; }
6850 fi
6851
6852 # test whether we have cygpath
6853 if test -z "$CYGPATH_W"; then
6854   if (cygpath --version) >/dev/null 2>/dev/null; then
6855     CYGPATH_W='cygpath -w'
6856   else
6857     CYGPATH_W=echo
6858   fi
6859 fi
6860
6861
6862 # Define the identity of the package.
6863  PACKAGE=gdb
6864  VERSION=UNUSED-VERSION
6865
6866
6867 # Some tools Automake needs.
6868
6869 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
6870
6871
6872 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
6873
6874
6875 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
6876
6877
6878 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
6879
6880
6881 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
6882
6883 install_sh=${install_sh-"$am_aux_dir/install-sh"}
6884
6885 # Installed binaries are usually stripped using `strip' when the user
6886 # run `make install-strip'.  However `strip' might not be the right
6887 # tool to use in cross-compilation environments, therefore Automake
6888 # will honor the `STRIP' environment variable to overrule this program.
6889 if test "$cross_compiling" != no; then
6890   if test -n "$ac_tool_prefix"; then
6891   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6892 set dummy ${ac_tool_prefix}strip; ac_word=$2
6893 echo "$as_me:$LINENO: checking for $ac_word" >&5
6894 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6895 if test "${ac_cv_prog_STRIP+set}" = set; then
6896   echo $ECHO_N "(cached) $ECHO_C" >&6
6897 else
6898   if test -n "$STRIP"; then
6899   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6900 else
6901 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6902 for as_dir in $PATH
6903 do
6904   IFS=$as_save_IFS
6905   test -z "$as_dir" && as_dir=.
6906   for ac_exec_ext in '' $ac_executable_extensions; do
6907   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6908     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6909     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6910     break 2
6911   fi
6912 done
6913 done
6914
6915 fi
6916 fi
6917 STRIP=$ac_cv_prog_STRIP
6918 if test -n "$STRIP"; then
6919   echo "$as_me:$LINENO: result: $STRIP" >&5
6920 echo "${ECHO_T}$STRIP" >&6
6921 else
6922   echo "$as_me:$LINENO: result: no" >&5
6923 echo "${ECHO_T}no" >&6
6924 fi
6925
6926 fi
6927 if test -z "$ac_cv_prog_STRIP"; then
6928   ac_ct_STRIP=$STRIP
6929   # Extract the first word of "strip", so it can be a program name with args.
6930 set dummy strip; ac_word=$2
6931 echo "$as_me:$LINENO: checking for $ac_word" >&5
6932 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6933 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6934   echo $ECHO_N "(cached) $ECHO_C" >&6
6935 else
6936   if test -n "$ac_ct_STRIP"; then
6937   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6938 else
6939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6940 for as_dir in $PATH
6941 do
6942   IFS=$as_save_IFS
6943   test -z "$as_dir" && as_dir=.
6944   for ac_exec_ext in '' $ac_executable_extensions; do
6945   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6946     ac_cv_prog_ac_ct_STRIP="strip"
6947     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6948     break 2
6949   fi
6950 done
6951 done
6952
6953   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
6954 fi
6955 fi
6956 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6957 if test -n "$ac_ct_STRIP"; then
6958   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6959 echo "${ECHO_T}$ac_ct_STRIP" >&6
6960 else
6961   echo "$as_me:$LINENO: result: no" >&5
6962 echo "${ECHO_T}no" >&6
6963 fi
6964
6965   STRIP=$ac_ct_STRIP
6966 else
6967   STRIP="$ac_cv_prog_STRIP"
6968 fi
6969
6970 fi
6971 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
6972
6973 # We need awk for the "check" target.  The system "awk" is bad on
6974 # some platforms.
6975 # Always define AMTAR for backward compatibility.
6976
6977 AMTAR=${AMTAR-"${am_missing_run}tar"}
6978
6979 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
6980
6981
6982
6983
6984 depcc="$CC"   am_compiler_list=
6985
6986 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
6987 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
6988 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
6989   echo $ECHO_N "(cached) $ECHO_C" >&6
6990 else
6991   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
6992   # We make a subdir and do the tests there.  Otherwise we can end up
6993   # making bogus files that we don't know about and never remove.  For
6994   # instance it was reported that on HP-UX the gcc test will end up
6995   # making a dummy file named `D' -- because `-MD' means `put the output
6996   # in D'.
6997   mkdir conftest.dir
6998   # Copy depcomp to subdir because otherwise we won't find it if we're
6999   # using a relative directory.
7000   cp "$am_depcomp" conftest.dir
7001   cd conftest.dir
7002   # We will build objects and dependencies in a subdirectory because
7003   # it helps to detect inapplicable dependency modes.  For instance
7004   # both Tru64's cc and ICC support -MD to output dependencies as a
7005   # side effect of compilation, but ICC will put the dependencies in
7006   # the current directory while Tru64 will put them in the object
7007   # directory.
7008   mkdir sub
7009
7010   am_cv_CC_dependencies_compiler_type=none
7011   if test "$am_compiler_list" = ""; then
7012      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
7013   fi
7014   for depmode in $am_compiler_list; do
7015     # Setup a source with many dependencies, because some compilers
7016     # like to wrap large dependency lists on column 80 (with \), and
7017     # we should not choose a depcomp mode which is confused by this.
7018     #
7019     # We need to recreate these files for each test, as the compiler may
7020     # overwrite some of them when testing with obscure command lines.
7021     # This happens at least with the AIX C compiler.
7022     : > sub/conftest.c
7023     for i in 1 2 3 4 5 6; do
7024       echo '#include "conftst'$i'.h"' >> sub/conftest.c
7025       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
7026       # Solaris 8's {/usr,}/bin/sh.
7027       touch sub/conftst$i.h
7028     done
7029     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
7030
7031     case $depmode in
7032     nosideeffect)
7033       # after this tag, mechanisms are not by side-effect, so they'll
7034       # only be used when explicitly requested
7035       if test "x$enable_dependency_tracking" = xyes; then
7036         continue
7037       else
7038         break
7039       fi
7040       ;;
7041     none) break ;;
7042     esac
7043     # We check with `-c' and `-o' for the sake of the "dashmstdout"
7044     # mode.  It turns out that the SunPro C++ compiler does not properly
7045     # handle `-M -o', and we need to detect this.
7046     if depmode=$depmode \
7047        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
7048        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
7049        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
7050          >/dev/null 2>conftest.err &&
7051        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
7052        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
7053        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
7054       # icc doesn't choke on unknown options, it will just issue warnings
7055       # or remarks (even with -Werror).  So we grep stderr for any message
7056       # that says an option was ignored or not supported.
7057       # When given -MP, icc 7.0 and 7.1 complain thusly:
7058       #   icc: Command line warning: ignoring option '-M'; no argument required
7059       # The diagnosis changed in icc 8.0:
7060       #   icc: Command line remark: option '-MP' not supported
7061       if (grep 'ignoring option' conftest.err ||
7062           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
7063         am_cv_CC_dependencies_compiler_type=$depmode
7064         break
7065       fi
7066     fi
7067   done
7068
7069   cd ..
7070   rm -rf conftest.dir
7071 else
7072   am_cv_CC_dependencies_compiler_type=none
7073 fi
7074
7075 fi
7076 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
7077 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
7078 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
7079
7080
7081
7082 if
7083   test "x$enable_dependency_tracking" != xno \
7084   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
7085   am__fastdepCC_TRUE=
7086   am__fastdepCC_FALSE='#'
7087 else
7088   am__fastdepCC_TRUE='#'
7089   am__fastdepCC_FALSE=
7090 fi
7091
7092
7093
7094
7095 debugdir=${libdir}/debug
7096
7097
7098 # Check whether --with-separate-debug-dir or --without-separate-debug-dir was given.
7099 if test "${with_separate_debug_dir+set}" = set; then
7100   withval="$with_separate_debug_dir"
7101   debugdir="${withval}"
7102 fi;
7103
7104
7105   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7106   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7107   ac_define_dir=`eval echo $debugdir`
7108   ac_define_dir=`eval echo $ac_define_dir`
7109
7110 cat >>confdefs.h <<_ACEOF
7111 #define DEBUGDIR "$ac_define_dir"
7112 _ACEOF
7113
7114
7115 #AC_DEFINE_UNQUOTED(DEBUGDIR, "$debugdir"),
7116
7117 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
7118   if test "x$prefix" = xNONE; then
7119     test_prefix=/usr/local
7120   else
7121     test_prefix=$prefix
7122   fi
7123 else
7124   test_prefix=$exec_prefix
7125 fi
7126 case ${debugdir} in
7127 "${test_prefix}"|"${test_prefix}/"*|\
7128 '${exec_prefix}'|'${exec_prefix}/'*)
7129
7130 cat >>confdefs.h <<\_ACEOF
7131 #define DEBUGDIR_RELOCATABLE 1
7132 _ACEOF
7133
7134   ;;
7135 esac
7136
7137
7138 # Check whether --with-relocated-sources or --without-relocated-sources was given.
7139 if test "${with_relocated_sources+set}" = set; then
7140   withval="$with_relocated_sources"
7141   reloc_srcdir="${withval}"
7142
7143   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
7144   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7145   ac_define_dir=`eval echo $reloc_srcdir`
7146   ac_define_dir=`eval echo $ac_define_dir`
7147
7148 cat >>confdefs.h <<_ACEOF
7149 #define RELOC_SRCDIR "$ac_define_dir"
7150 _ACEOF
7151
7152
7153
7154 fi;
7155
7156
7157
7158 subdirs="$subdirs doc testsuite"
7159
7160
7161 # Check whether to support alternative target configurations
7162 # Check whether --enable-targets or --disable-targets was given.
7163 if test "${enable_targets+set}" = set; then
7164   enableval="$enable_targets"
7165   case "${enableval}" in
7166   yes | "") { { echo "$as_me:$LINENO: error: enable-targets option must specify target names or 'all'" >&5
7167 echo "$as_me: error: enable-targets option must specify target names or 'all'" >&2;}
7168    { (exit 1); exit 1; }; }
7169             ;;
7170   no)       enable_targets= ;;
7171   *)        enable_targets=$enableval ;;
7172 esac
7173 fi;
7174
7175 # Check whether to enable 64-bit support on 32-bit hosts
7176 # Check whether --enable-64-bit-bfd or --disable-64-bit-bfd was given.
7177 if test "${enable_64_bit_bfd+set}" = set; then
7178   enableval="$enable_64_bit_bfd"
7179   case "${enableval}" in
7180   yes)  want64=true  ;;
7181   no)   want64=false ;;
7182   *)    { { echo "$as_me:$LINENO: error: bad value ${enableval} for 64-bit-bfd option" >&5
7183 echo "$as_me: error: bad value ${enableval} for 64-bit-bfd option" >&2;}
7184    { (exit 1); exit 1; }; } ;;
7185 esac
7186 else
7187   want64=false
7188 fi;
7189 # Provide defaults for some variables set by the per-host and per-target
7190 # configuration.
7191 gdb_host_obs=posix-hdep.o
7192
7193 if test "${target}" = "${host}"; then
7194   gdb_native=yes
7195 else
7196   gdb_native=no
7197 fi
7198
7199 . $srcdir/configure.host
7200
7201 # Accumulate some settings from configure.tgt over all enabled targets
7202
7203 TARGET_OBS=
7204 all_targets=
7205
7206 for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
7207 do
7208   if test "$targ_alias" = "all"; then
7209     all_targets=true
7210   else
7211     # Canonicalize the secondary target names.
7212     result=`$ac_config_sub $targ_alias 2>/dev/null`
7213     if test -n "$result"; then
7214         targ=$result
7215     else
7216         targ=$targ_alias
7217     fi
7218
7219     . ${srcdir}/configure.tgt
7220
7221     # Target-specific object files
7222     for i in ${gdb_target_obs}; do
7223         case " $TARGET_OBS " in
7224         *" ${i} "*) ;;
7225         *)
7226           TARGET_OBS="$TARGET_OBS ${i}"
7227           ;;
7228         esac
7229     done
7230
7231     # Check whether this target needs 64-bit CORE_ADDR
7232     if test x${want64} = xfalse; then
7233       . ${srcdir}/../bfd/config.bfd
7234     fi
7235   fi
7236 done
7237
7238 if test x${all_targets} = xtrue; then
7239
7240   # We want all 64-bit targets if we either:
7241   #  - run on a 64-bit host  or
7242   #  - already require 64-bit support for some other target  or
7243   #  - the --enable-64-bit-bfd option was supplied
7244   # Otherwise we only support all 32-bit targets.
7245   #
7246   # NOTE: This test must be in sync with the corresponding
7247   #       tests in BFD!
7248
7249   if test x${want64} = xfalse; then
7250     echo "$as_me:$LINENO: checking for long" >&5
7251 echo $ECHO_N "checking for long... $ECHO_C" >&6
7252 if test "${ac_cv_type_long+set}" = set; then
7253   echo $ECHO_N "(cached) $ECHO_C" >&6
7254 else
7255   cat >conftest.$ac_ext <<_ACEOF
7256 /* confdefs.h.  */
7257 _ACEOF
7258 cat confdefs.h >>conftest.$ac_ext
7259 cat >>conftest.$ac_ext <<_ACEOF
7260 /* end confdefs.h.  */
7261 $ac_includes_default
7262 int
7263 main ()
7264 {
7265 if ((long *) 0)
7266   return 0;
7267 if (sizeof (long))
7268   return 0;
7269   ;
7270   return 0;
7271 }
7272 _ACEOF
7273 rm -f conftest.$ac_objext
7274 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7275   (eval $ac_compile) 2>conftest.er1
7276   ac_status=$?
7277   grep -v '^ *+' conftest.er1 >conftest.err
7278   rm -f conftest.er1
7279   cat conftest.err >&5
7280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7281   (exit $ac_status); } &&
7282          { ac_try='test -z "$ac_c_werror_flag"
7283                          || test ! -s conftest.err'
7284   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7285   (eval $ac_try) 2>&5
7286   ac_status=$?
7287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7288   (exit $ac_status); }; } &&
7289          { ac_try='test -s conftest.$ac_objext'
7290   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7291   (eval $ac_try) 2>&5
7292   ac_status=$?
7293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7294   (exit $ac_status); }; }; then
7295   ac_cv_type_long=yes
7296 else
7297   echo "$as_me: failed program was:" >&5
7298 sed 's/^/| /' conftest.$ac_ext >&5
7299
7300 ac_cv_type_long=no
7301 fi
7302 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7303 fi
7304 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
7305 echo "${ECHO_T}$ac_cv_type_long" >&6
7306
7307 echo "$as_me:$LINENO: checking size of long" >&5
7308 echo $ECHO_N "checking size of long... $ECHO_C" >&6
7309 if test "${ac_cv_sizeof_long+set}" = set; then
7310   echo $ECHO_N "(cached) $ECHO_C" >&6
7311 else
7312   if test "$ac_cv_type_long" = yes; then
7313   # The cast to unsigned long works around a bug in the HP C Compiler
7314   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7315   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7316   # This bug is HP SR number 8606223364.
7317   if test "$cross_compiling" = yes; then
7318   # Depending upon the size, compute the lo and hi bounds.
7319 cat >conftest.$ac_ext <<_ACEOF
7320 /* confdefs.h.  */
7321 _ACEOF
7322 cat confdefs.h >>conftest.$ac_ext
7323 cat >>conftest.$ac_ext <<_ACEOF
7324 /* end confdefs.h.  */
7325 $ac_includes_default
7326 int
7327 main ()
7328 {
7329 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
7330 test_array [0] = 0
7331
7332   ;
7333   return 0;
7334 }
7335 _ACEOF
7336 rm -f conftest.$ac_objext
7337 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7338   (eval $ac_compile) 2>conftest.er1
7339   ac_status=$?
7340   grep -v '^ *+' conftest.er1 >conftest.err
7341   rm -f conftest.er1
7342   cat conftest.err >&5
7343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7344   (exit $ac_status); } &&
7345          { ac_try='test -z "$ac_c_werror_flag"
7346                          || test ! -s conftest.err'
7347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7348   (eval $ac_try) 2>&5
7349   ac_status=$?
7350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7351   (exit $ac_status); }; } &&
7352          { ac_try='test -s conftest.$ac_objext'
7353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7354   (eval $ac_try) 2>&5
7355   ac_status=$?
7356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7357   (exit $ac_status); }; }; then
7358   ac_lo=0 ac_mid=0
7359   while :; do
7360     cat >conftest.$ac_ext <<_ACEOF
7361 /* confdefs.h.  */
7362 _ACEOF
7363 cat confdefs.h >>conftest.$ac_ext
7364 cat >>conftest.$ac_ext <<_ACEOF
7365 /* end confdefs.h.  */
7366 $ac_includes_default
7367 int
7368 main ()
7369 {
7370 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
7371 test_array [0] = 0
7372
7373   ;
7374   return 0;
7375 }
7376 _ACEOF
7377 rm -f conftest.$ac_objext
7378 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7379   (eval $ac_compile) 2>conftest.er1
7380   ac_status=$?
7381   grep -v '^ *+' conftest.er1 >conftest.err
7382   rm -f conftest.er1
7383   cat conftest.err >&5
7384   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7385   (exit $ac_status); } &&
7386          { ac_try='test -z "$ac_c_werror_flag"
7387                          || test ! -s conftest.err'
7388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7389   (eval $ac_try) 2>&5
7390   ac_status=$?
7391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7392   (exit $ac_status); }; } &&
7393          { ac_try='test -s conftest.$ac_objext'
7394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7395   (eval $ac_try) 2>&5
7396   ac_status=$?
7397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7398   (exit $ac_status); }; }; then
7399   ac_hi=$ac_mid; break
7400 else
7401   echo "$as_me: failed program was:" >&5
7402 sed 's/^/| /' conftest.$ac_ext >&5
7403
7404 ac_lo=`expr $ac_mid + 1`
7405                     if test $ac_lo -le $ac_mid; then
7406                       ac_lo= ac_hi=
7407                       break
7408                     fi
7409                     ac_mid=`expr 2 '*' $ac_mid + 1`
7410 fi
7411 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7412   done
7413 else
7414   echo "$as_me: failed program was:" >&5
7415 sed 's/^/| /' conftest.$ac_ext >&5
7416
7417 cat >conftest.$ac_ext <<_ACEOF
7418 /* confdefs.h.  */
7419 _ACEOF
7420 cat confdefs.h >>conftest.$ac_ext
7421 cat >>conftest.$ac_ext <<_ACEOF
7422 /* end confdefs.h.  */
7423 $ac_includes_default
7424 int
7425 main ()
7426 {
7427 static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
7428 test_array [0] = 0
7429
7430   ;
7431   return 0;
7432 }
7433 _ACEOF
7434 rm -f conftest.$ac_objext
7435 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7436   (eval $ac_compile) 2>conftest.er1
7437   ac_status=$?
7438   grep -v '^ *+' conftest.er1 >conftest.err
7439   rm -f conftest.er1
7440   cat conftest.err >&5
7441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7442   (exit $ac_status); } &&
7443          { ac_try='test -z "$ac_c_werror_flag"
7444                          || test ! -s conftest.err'
7445   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7446   (eval $ac_try) 2>&5
7447   ac_status=$?
7448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7449   (exit $ac_status); }; } &&
7450          { ac_try='test -s conftest.$ac_objext'
7451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7452   (eval $ac_try) 2>&5
7453   ac_status=$?
7454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7455   (exit $ac_status); }; }; then
7456   ac_hi=-1 ac_mid=-1
7457   while :; do
7458     cat >conftest.$ac_ext <<_ACEOF
7459 /* confdefs.h.  */
7460 _ACEOF
7461 cat confdefs.h >>conftest.$ac_ext
7462 cat >>conftest.$ac_ext <<_ACEOF
7463 /* end confdefs.h.  */
7464 $ac_includes_default
7465 int
7466 main ()
7467 {
7468 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
7469 test_array [0] = 0
7470
7471   ;
7472   return 0;
7473 }
7474 _ACEOF
7475 rm -f conftest.$ac_objext
7476 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7477   (eval $ac_compile) 2>conftest.er1
7478   ac_status=$?
7479   grep -v '^ *+' conftest.er1 >conftest.err
7480   rm -f conftest.er1
7481   cat conftest.err >&5
7482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7483   (exit $ac_status); } &&
7484          { ac_try='test -z "$ac_c_werror_flag"
7485                          || test ! -s conftest.err'
7486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7487   (eval $ac_try) 2>&5
7488   ac_status=$?
7489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7490   (exit $ac_status); }; } &&
7491          { ac_try='test -s conftest.$ac_objext'
7492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7493   (eval $ac_try) 2>&5
7494   ac_status=$?
7495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7496   (exit $ac_status); }; }; then
7497   ac_lo=$ac_mid; break
7498 else
7499   echo "$as_me: failed program was:" >&5
7500 sed 's/^/| /' conftest.$ac_ext >&5
7501
7502 ac_hi=`expr '(' $ac_mid ')' - 1`
7503                        if test $ac_mid -le $ac_hi; then
7504                          ac_lo= ac_hi=
7505                          break
7506                        fi
7507                        ac_mid=`expr 2 '*' $ac_mid`
7508 fi
7509 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7510   done
7511 else
7512   echo "$as_me: failed program was:" >&5
7513 sed 's/^/| /' conftest.$ac_ext >&5
7514
7515 ac_lo= ac_hi=
7516 fi
7517 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7518 fi
7519 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7520 # Binary search between lo and hi bounds.
7521 while test "x$ac_lo" != "x$ac_hi"; do
7522   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7523   cat >conftest.$ac_ext <<_ACEOF
7524 /* confdefs.h.  */
7525 _ACEOF
7526 cat confdefs.h >>conftest.$ac_ext
7527 cat >>conftest.$ac_ext <<_ACEOF
7528 /* end confdefs.h.  */
7529 $ac_includes_default
7530 int
7531 main ()
7532 {
7533 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
7534 test_array [0] = 0
7535
7536   ;
7537   return 0;
7538 }
7539 _ACEOF
7540 rm -f conftest.$ac_objext
7541 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7542   (eval $ac_compile) 2>conftest.er1
7543   ac_status=$?
7544   grep -v '^ *+' conftest.er1 >conftest.err
7545   rm -f conftest.er1
7546   cat conftest.err >&5
7547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7548   (exit $ac_status); } &&
7549          { ac_try='test -z "$ac_c_werror_flag"
7550                          || test ! -s conftest.err'
7551   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7552   (eval $ac_try) 2>&5
7553   ac_status=$?
7554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7555   (exit $ac_status); }; } &&
7556          { ac_try='test -s conftest.$ac_objext'
7557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7558   (eval $ac_try) 2>&5
7559   ac_status=$?
7560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7561   (exit $ac_status); }; }; then
7562   ac_hi=$ac_mid
7563 else
7564   echo "$as_me: failed program was:" >&5
7565 sed 's/^/| /' conftest.$ac_ext >&5
7566
7567 ac_lo=`expr '(' $ac_mid ')' + 1`
7568 fi
7569 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7570 done
7571 case $ac_lo in
7572 ?*) ac_cv_sizeof_long=$ac_lo;;
7573 '') { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
7574 echo "$as_me: error: in \`$ac_pwd':" >&2;}
7575 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
7576 See \`config.log' for more details." >&5
7577 echo "$as_me: error: cannot compute sizeof (long), 77
7578 See \`config.log' for more details." >&2;}
7579    { (exit 1); exit 1; }; }; } ;;
7580 esac
7581 else
7582   if test "$cross_compiling" = yes; then
7583   { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
7584 echo "$as_me: error: in \`$ac_pwd':" >&2;}
7585 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
7586 See \`config.log' for more details." >&5
7587 echo "$as_me: error: cannot run test program while cross compiling
7588 See \`config.log' for more details." >&2;}
7589    { (exit 1); exit 1; }; }; }
7590 else
7591   cat >conftest.$ac_ext <<_ACEOF
7592 /* confdefs.h.  */
7593 _ACEOF
7594 cat confdefs.h >>conftest.$ac_ext
7595 cat >>conftest.$ac_ext <<_ACEOF
7596 /* end confdefs.h.  */
7597 $ac_includes_default
7598 long longval () { return (long) (sizeof (long)); }
7599 unsigned long ulongval () { return (long) (sizeof (long)); }
7600 #include <stdio.h>
7601 #include <stdlib.h>
7602 int
7603 main ()
7604 {
7605
7606   FILE *f = fopen ("conftest.val", "w");
7607   if (! f)
7608     exit (1);
7609   if (((long) (sizeof (long))) < 0)
7610     {
7611       long i = longval ();
7612       if (i != ((long) (sizeof (long))))
7613         exit (1);
7614       fprintf (f, "%ld\n", i);
7615     }
7616   else
7617     {
7618       unsigned long i = ulongval ();
7619       if (i != ((long) (sizeof (long))))
7620         exit (1);
7621       fprintf (f, "%lu\n", i);
7622     }
7623   exit (ferror (f) || fclose (f) != 0);
7624
7625   ;
7626   return 0;
7627 }
7628 _ACEOF
7629 rm -f conftest$ac_exeext
7630 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7631   (eval $ac_link) 2>&5
7632   ac_status=$?
7633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7634   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7635   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7636   (eval $ac_try) 2>&5
7637   ac_status=$?
7638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7639   (exit $ac_status); }; }; then
7640   ac_cv_sizeof_long=`cat conftest.val`
7641 else
7642   echo "$as_me: program exited with status $ac_status" >&5
7643 echo "$as_me: failed program was:" >&5
7644 sed 's/^/| /' conftest.$ac_ext >&5
7645
7646 ( exit $ac_status )
7647 { { echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
7648 echo "$as_me: error: in \`$ac_pwd':" >&2;}
7649 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
7650 See \`config.log' for more details." >&5
7651 echo "$as_me: error: cannot compute sizeof (long), 77
7652 See \`config.log' for more details." >&2;}
7653    { (exit 1); exit 1; }; }; }
7654 fi
7655 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7656 fi
7657 fi
7658 rm -f conftest.val
7659 else
7660   ac_cv_sizeof_long=0
7661 fi
7662 fi
7663 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
7664 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
7665 cat >>confdefs.h <<_ACEOF
7666 #define SIZEOF_LONG $ac_cv_sizeof_long
7667 _ACEOF
7668
7669
7670     if test "x${ac_cv_sizeof_long}" = "x8"; then
7671       want64=true
7672     fi
7673   fi
7674   if test x${want64} = xtrue; then
7675     TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)'
7676   else
7677     TARGET_OBS='$(ALL_TARGET_OBS)'
7678   fi
7679 fi
7680
7681
7682
7683 # For other settings, only the main target counts.
7684 gdb_sim=
7685 gdb_osabi=
7686 build_gdbserver=
7687 targ=$target; . ${srcdir}/configure.tgt
7688
7689 # Fetch the default architecture and default target vector from BFD.
7690 targ=$target; . $srcdir/../bfd/config.bfd
7691
7692 # We only want the first architecture, so strip off the others if
7693 # there is more than one.
7694 targ_archs=`echo $targ_archs | sed 's/ .*//'`
7695
7696 if test "x$targ_archs" != x; then
7697
7698 cat >>confdefs.h <<_ACEOF
7699 #define DEFAULT_BFD_ARCH $targ_archs
7700 _ACEOF
7701
7702 fi
7703 if test "x$targ_defvec" != x; then
7704
7705 cat >>confdefs.h <<_ACEOF
7706 #define DEFAULT_BFD_VEC $targ_defvec
7707 _ACEOF
7708
7709 fi
7710
7711 # The CLI cannot be disabled yet, but may be in the future.
7712
7713 # Enable CLI.
7714 # Check whether --enable-gdbcli or --disable-gdbcli was given.
7715 if test "${enable_gdbcli+set}" = set; then
7716   enableval="$enable_gdbcli"
7717   case $enableval in
7718     yes)
7719       ;;
7720     no)
7721       { { echo "$as_me:$LINENO: error: the command-line interface cannot be disabled yet" >&5
7722 echo "$as_me: error: the command-line interface cannot be disabled yet" >&2;}
7723    { (exit 1); exit 1; }; } ;;
7724     *)
7725       { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-gdbcli" >&5
7726 echo "$as_me: error: bad value $enableval for --enable-gdbcli" >&2;}
7727    { (exit 1); exit 1; }; } ;;
7728   esac
7729 else
7730   enable_gdbcli=yes
7731 fi;
7732 if test x"$enable_gdbcli" = xyes; then
7733   if test -d $srcdir/cli; then
7734     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_CLI_OBS)"
7735     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_CLI_DEPS)"
7736     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_CLI_SRCS)"
7737     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_CLI_CFLAGS)"
7738   fi
7739 fi
7740
7741 # Enable MI.
7742 # Check whether --enable-gdbmi or --disable-gdbmi was given.
7743 if test "${enable_gdbmi+set}" = set; then
7744   enableval="$enable_gdbmi"
7745   case $enableval in
7746     yes | no)
7747       ;;
7748     *)
7749       { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-gdbmi" >&5
7750 echo "$as_me: error: bad value $enableval for --enable-gdbmi" >&2;}
7751    { (exit 1); exit 1; }; } ;;
7752   esac
7753 else
7754   enable_gdbmi=yes
7755 fi;
7756 if test x"$enable_gdbmi" = xyes; then
7757   if test -d $srcdir/mi; then
7758     CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
7759     CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
7760     CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
7761     ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
7762   fi
7763 fi
7764
7765 # Enable TUI.
7766 # Check whether --enable-tui or --disable-tui was given.
7767 if test "${enable_tui+set}" = set; then
7768   enableval="$enable_tui"
7769   case $enableval in
7770     yes | no | auto)
7771       ;;
7772     *)
7773       { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-tui" >&5
7774 echo "$as_me: error: bad value $enableval for --enable-tui" >&2;}
7775    { (exit 1); exit 1; }; } ;;
7776   esac
7777 else
7778   enable_tui=auto
7779 fi;
7780
7781 # Enable gdbtk.
7782 # Check whether --enable-gdbtk or --disable-gdbtk was given.
7783 if test "${enable_gdbtk+set}" = set; then
7784   enableval="$enable_gdbtk"
7785   case $enableval in
7786     yes | no)
7787       ;;
7788     *)
7789       { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-gdbtk" >&5
7790 echo "$as_me: error: bad value $enableval for --enable-gdbtk" >&2;}
7791    { (exit 1); exit 1; }; } ;;
7792   esac
7793 else
7794   if test -d $srcdir/gdbtk; then
7795     enable_gdbtk=yes
7796   else
7797     enable_gdbtk=no
7798   fi
7799 fi;
7800 # We unconditionally disable gdbtk tests on selected platforms.
7801 case $host_os in
7802   go32* | windows*)
7803     { echo "$as_me:$LINENO: WARNING: gdbtk isn't supported on $host; disabling" >&5
7804 echo "$as_me: WARNING: gdbtk isn't supported on $host; disabling" >&2;}
7805     enable_gdbtk=no ;;
7806 esac
7807
7808 # Libunwind support.
7809
7810 # Check whether --with-libunwind or --without-libunwind was given.
7811 if test "${with_libunwind+set}" = set; then
7812   withval="$with_libunwind"
7813   case "${withval}" in
7814   yes)  enable_libunwind=yes ;;
7815   no)   enable_libunwind=no ;;
7816   *)    { { echo "$as_me:$LINENO: error: bad value ${withval} for GDB with-libunwind option" >&5
7817 echo "$as_me: error: bad value ${withval} for GDB with-libunwind option" >&2;}
7818    { (exit 1); exit 1; }; } ;;
7819 esac
7820 else
7821
7822
7823
7824 for ac_header in libunwind.h libunwind-ia64.h
7825 do
7826 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7827 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7828   echo "$as_me:$LINENO: checking for $ac_header" >&5
7829 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7830 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7831   echo $ECHO_N "(cached) $ECHO_C" >&6
7832 fi
7833 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7834 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7835 else
7836   # Is the header compilable?
7837 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7838 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7839 cat >conftest.$ac_ext <<_ACEOF
7840 /* confdefs.h.  */
7841 _ACEOF
7842 cat confdefs.h >>conftest.$ac_ext
7843 cat >>conftest.$ac_ext <<_ACEOF
7844 /* end confdefs.h.  */
7845 $ac_includes_default
7846 #include <$ac_header>
7847 _ACEOF
7848 rm -f conftest.$ac_objext
7849 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7850   (eval $ac_compile) 2>conftest.er1
7851   ac_status=$?
7852   grep -v '^ *+' conftest.er1 >conftest.err
7853   rm -f conftest.er1
7854   cat conftest.err >&5
7855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7856   (exit $ac_status); } &&
7857          { ac_try='test -z "$ac_c_werror_flag"
7858                          || test ! -s conftest.err'
7859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7860   (eval $ac_try) 2>&5
7861   ac_status=$?
7862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7863   (exit $ac_status); }; } &&
7864          { ac_try='test -s conftest.$ac_objext'
7865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7866   (eval $ac_try) 2>&5
7867   ac_status=$?
7868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7869   (exit $ac_status); }; }; then
7870   ac_header_compiler=yes
7871 else
7872   echo "$as_me: failed program was:" >&5
7873 sed 's/^/| /' conftest.$ac_ext >&5
7874
7875 ac_header_compiler=no
7876 fi
7877 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7878 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7879 echo "${ECHO_T}$ac_header_compiler" >&6
7880
7881 # Is the header present?
7882 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7883 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7884 cat >conftest.$ac_ext <<_ACEOF
7885 /* confdefs.h.  */
7886 _ACEOF
7887 cat confdefs.h >>conftest.$ac_ext
7888 cat >>conftest.$ac_ext <<_ACEOF
7889 /* end confdefs.h.  */
7890 #include <$ac_header>
7891 _ACEOF
7892 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7893   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7894   ac_status=$?
7895   grep -v '^ *+' conftest.er1 >conftest.err
7896   rm -f conftest.er1
7897   cat conftest.err >&5
7898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7899   (exit $ac_status); } >/dev/null; then
7900   if test -s conftest.err; then
7901     ac_cpp_err=$ac_c_preproc_warn_flag
7902     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7903   else
7904     ac_cpp_err=
7905   fi
7906 else
7907   ac_cpp_err=yes
7908 fi
7909 if test -z "$ac_cpp_err"; then
7910   ac_header_preproc=yes
7911 else
7912   echo "$as_me: failed program was:" >&5
7913 sed 's/^/| /' conftest.$ac_ext >&5
7914
7915   ac_header_preproc=no
7916 fi
7917 rm -f conftest.err conftest.$ac_ext
7918 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7919 echo "${ECHO_T}$ac_header_preproc" >&6
7920
7921 # So?  What about this header?
7922 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7923   yes:no: )
7924     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7925 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7926     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7927 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7928     ac_header_preproc=yes
7929     ;;
7930   no:yes:* )
7931     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7932 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7933     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7934 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7935     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7936 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7937     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7938 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7939     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7940 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7941     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7942 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7943     (
7944       cat <<\_ASBOX
7945 ## ------------------------------------------ ##
7946 ## Report this to the AC_PACKAGE_NAME lists.  ##
7947 ## ------------------------------------------ ##
7948 _ASBOX
7949     ) |
7950       sed "s/^/$as_me: WARNING:     /" >&2
7951     ;;
7952 esac
7953 echo "$as_me:$LINENO: checking for $ac_header" >&5
7954 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7955 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7956   echo $ECHO_N "(cached) $ECHO_C" >&6
7957 else
7958   eval "$as_ac_Header=\$ac_header_preproc"
7959 fi
7960 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7961 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7962
7963 fi
7964 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7965   cat >>confdefs.h <<_ACEOF
7966 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7967 _ACEOF
7968
7969 fi
7970
7971 done
7972
7973   if test x"$ac_cv_header_libunwind_h" = xyes -a x"$ac_cv_header_libunwind_ia64_h" = xyes; then
7974     enable_libunwind=yes;
7975   fi
7976
7977 fi;
7978
7979 if test x"$enable_libunwind" = xyes; then
7980
7981
7982 for ac_header in libunwind.h libunwind-ia64.h
7983 do
7984 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7985 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7986   echo "$as_me:$LINENO: checking for $ac_header" >&5
7987 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7988 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7989   echo $ECHO_N "(cached) $ECHO_C" >&6
7990 fi
7991 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7992 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7993 else
7994   # Is the header compilable?
7995 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7996 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7997 cat >conftest.$ac_ext <<_ACEOF
7998 /* confdefs.h.  */
7999 _ACEOF
8000 cat confdefs.h >>conftest.$ac_ext
8001 cat >>conftest.$ac_ext <<_ACEOF
8002 /* end confdefs.h.  */
8003 $ac_includes_default
8004 #include <$ac_header>
8005 _ACEOF
8006 rm -f conftest.$ac_objext
8007 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8008   (eval $ac_compile) 2>conftest.er1
8009   ac_status=$?
8010   grep -v '^ *+' conftest.er1 >conftest.err
8011   rm -f conftest.er1
8012   cat conftest.err >&5
8013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8014   (exit $ac_status); } &&
8015          { ac_try='test -z "$ac_c_werror_flag"
8016                          || test ! -s conftest.err'
8017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8018   (eval $ac_try) 2>&5
8019   ac_status=$?
8020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8021   (exit $ac_status); }; } &&
8022          { ac_try='test -s conftest.$ac_objext'
8023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8024   (eval $ac_try) 2>&5
8025   ac_status=$?
8026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8027   (exit $ac_status); }; }; then
8028   ac_header_compiler=yes
8029 else
8030   echo "$as_me: failed program was:" >&5
8031 sed 's/^/| /' conftest.$ac_ext >&5
8032
8033 ac_header_compiler=no
8034 fi
8035 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8036 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8037 echo "${ECHO_T}$ac_header_compiler" >&6
8038
8039 # Is the header present?
8040 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8041 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8042 cat >conftest.$ac_ext <<_ACEOF
8043 /* confdefs.h.  */
8044 _ACEOF
8045 cat confdefs.h >>conftest.$ac_ext
8046 cat >>conftest.$ac_ext <<_ACEOF
8047 /* end confdefs.h.  */
8048 #include <$ac_header>
8049 _ACEOF
8050 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8051   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8052   ac_status=$?
8053   grep -v '^ *+' conftest.er1 >conftest.err
8054   rm -f conftest.er1
8055   cat conftest.err >&5
8056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8057   (exit $ac_status); } >/dev/null; then
8058   if test -s conftest.err; then
8059     ac_cpp_err=$ac_c_preproc_warn_flag
8060     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8061   else
8062     ac_cpp_err=
8063   fi
8064 else
8065   ac_cpp_err=yes
8066 fi
8067 if test -z "$ac_cpp_err"; then
8068   ac_header_preproc=yes
8069 else
8070   echo "$as_me: failed program was:" >&5
8071 sed 's/^/| /' conftest.$ac_ext >&5
8072
8073   ac_header_preproc=no
8074 fi
8075 rm -f conftest.err conftest.$ac_ext
8076 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8077 echo "${ECHO_T}$ac_header_preproc" >&6
8078
8079 # So?  What about this header?
8080 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8081   yes:no: )
8082     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8083 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8084     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8085 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8086     ac_header_preproc=yes
8087     ;;
8088   no:yes:* )
8089     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8090 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8091     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8092 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8093     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8094 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8095     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8096 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8097     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8098 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8099     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8100 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8101     (
8102       cat <<\_ASBOX
8103 ## ------------------------------------------ ##
8104 ## Report this to the AC_PACKAGE_NAME lists.  ##
8105 ## ------------------------------------------ ##
8106 _ASBOX
8107     ) |
8108       sed "s/^/$as_me: WARNING:     /" >&2
8109     ;;
8110 esac
8111 echo "$as_me:$LINENO: checking for $ac_header" >&5
8112 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8113 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8114   echo $ECHO_N "(cached) $ECHO_C" >&6
8115 else
8116   eval "$as_ac_Header=\$ac_header_preproc"
8117 fi
8118 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8119 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8120
8121 fi
8122 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8123   cat >>confdefs.h <<_ACEOF
8124 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8125 _ACEOF
8126
8127 fi
8128
8129 done
8130
8131
8132 cat >>confdefs.h <<\_ACEOF
8133 #define HAVE_LIBUNWIND 1
8134 _ACEOF
8135
8136   CONFIG_OBS="$CONFIG_OBS libunwind-frame.o"
8137   CONFIG_DEPS="$CONFIG_DEPS libunwind-frame.o"
8138   CONFIG_SRCS="$CONFIG_SRCS libunwind-frame.c"
8139 fi
8140
8141 opt_curses=no
8142
8143 # Check whether --with-curses or --without-curses was given.
8144 if test "${with_curses+set}" = set; then
8145   withval="$with_curses"
8146   opt_curses=$withval
8147 fi;
8148
8149 prefer_curses=no
8150 if test "$opt_curses" = "yes"; then
8151   prefer_curses=yes
8152 fi
8153
8154 # Profiling support.
8155 # Check whether --enable-profiling or --disable-profiling was given.
8156 if test "${enable_profiling+set}" = set; then
8157   enableval="$enable_profiling"
8158   case $enableval in
8159     yes | no)
8160       ;;
8161     *)
8162       { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-profile" >&5
8163 echo "$as_me: error: bad value $enableval for --enable-profile" >&2;}
8164    { (exit 1); exit 1; }; } ;;
8165   esac
8166 else
8167   enable_profiling=no
8168 fi;
8169
8170
8171
8172 for ac_func in monstartup _mcleanup
8173 do
8174 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8175 echo "$as_me:$LINENO: checking for $ac_func" >&5
8176 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8177 if eval "test \"\${$as_ac_var+set}\" = set"; then
8178   echo $ECHO_N "(cached) $ECHO_C" >&6
8179 else
8180   cat >conftest.$ac_ext <<_ACEOF
8181 /* confdefs.h.  */
8182 _ACEOF
8183 cat confdefs.h >>conftest.$ac_ext
8184 cat >>conftest.$ac_ext <<_ACEOF
8185 /* end confdefs.h.  */
8186 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8187    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
8188 #define $ac_func innocuous_$ac_func
8189
8190 /* System header to define __stub macros and hopefully few prototypes,
8191     which can conflict with char $ac_func (); below.
8192     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8193     <limits.h> exists even on freestanding compilers.  */
8194
8195 #ifdef __STDC__
8196 # include <limits.h>
8197 #else
8198 # include <assert.h>
8199 #endif
8200
8201 #undef $ac_func
8202
8203 /* Override any gcc2 internal prototype to avoid an error.  */
8204 #ifdef __cplusplus
8205 extern "C"
8206 {
8207 #endif
8208 /* We use char because int might match the return type of a gcc2
8209    builtin and then its argument prototype would still apply.  */
8210 char $ac_func ();
8211 /* The GNU C library defines this for functions which it implements
8212     to always fail with ENOSYS.  Some functions are actually named
8213     something starting with __ and the normal name is an alias.  */
8214 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8215 choke me
8216 #else
8217 char (*f) () = $ac_func;
8218 #endif
8219 #ifdef __cplusplus
8220 }
8221 #endif
8222
8223 int
8224 main ()
8225 {
8226 return f != $ac_func;
8227   ;
8228   return 0;
8229 }
8230 _ACEOF
8231 rm -f conftest.$ac_objext conftest$ac_exeext
8232 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8233   (eval $ac_link) 2>conftest.er1
8234   ac_status=$?
8235   grep -v '^ *+' conftest.er1 >conftest.err
8236   rm -f conftest.er1
8237   cat conftest.err >&5
8238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8239   (exit $ac_status); } &&
8240          { ac_try='test -z "$ac_c_werror_flag"
8241                          || test ! -s conftest.err'
8242   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8243   (eval $ac_try) 2>&5
8244   ac_status=$?
8245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8246   (exit $ac_status); }; } &&
8247          { ac_try='test -s conftest$ac_exeext'
8248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8249   (eval $ac_try) 2>&5
8250   ac_status=$?
8251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8252   (exit $ac_status); }; }; then
8253   eval "$as_ac_var=yes"
8254 else
8255   echo "$as_me: failed program was:" >&5
8256 sed 's/^/| /' conftest.$ac_ext >&5
8257
8258 eval "$as_ac_var=no"
8259 fi
8260 rm -f conftest.err conftest.$ac_objext \
8261       conftest$ac_exeext conftest.$ac_ext
8262 fi
8263 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
8264 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8265 if test `eval echo '${'$as_ac_var'}'` = yes; then
8266   cat >>confdefs.h <<_ACEOF
8267 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8268 _ACEOF
8269
8270 fi
8271 done
8272
8273 echo "$as_me:$LINENO: checking for _etext" >&5
8274 echo $ECHO_N "checking for _etext... $ECHO_C" >&6
8275 if test "${ac_cv_var__etext+set}" = set; then
8276   echo $ECHO_N "(cached) $ECHO_C" >&6
8277 else
8278   cat >conftest.$ac_ext <<_ACEOF
8279 /* confdefs.h.  */
8280 _ACEOF
8281 cat confdefs.h >>conftest.$ac_ext
8282 cat >>conftest.$ac_ext <<_ACEOF
8283 /* end confdefs.h.  */
8284 #include <stdlib.h>
8285 extern char _etext;
8286
8287 int
8288 main ()
8289 {
8290 free (&_etext);
8291   ;
8292   return 0;
8293 }
8294 _ACEOF
8295 rm -f conftest.$ac_objext conftest$ac_exeext
8296 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8297   (eval $ac_link) 2>conftest.er1
8298   ac_status=$?
8299   grep -v '^ *+' conftest.er1 >conftest.err
8300   rm -f conftest.er1
8301   cat conftest.err >&5
8302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8303   (exit $ac_status); } &&
8304          { ac_try='test -z "$ac_c_werror_flag"
8305                          || test ! -s conftest.err'
8306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8307   (eval $ac_try) 2>&5
8308   ac_status=$?
8309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8310   (exit $ac_status); }; } &&
8311          { ac_try='test -s conftest$ac_exeext'
8312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8313   (eval $ac_try) 2>&5
8314   ac_status=$?
8315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8316   (exit $ac_status); }; }; then
8317   ac_cv_var__etext=yes
8318 else
8319   echo "$as_me: failed program was:" >&5
8320 sed 's/^/| /' conftest.$ac_ext >&5
8321
8322 ac_cv_var__etext=no
8323 fi
8324 rm -f conftest.err conftest.$ac_objext \
8325       conftest$ac_exeext conftest.$ac_ext
8326 fi
8327 echo "$as_me:$LINENO: result: $ac_cv_var__etext" >&5
8328 echo "${ECHO_T}$ac_cv_var__etext" >&6
8329 if test $ac_cv_var__etext = yes; then
8330
8331 cat >>confdefs.h <<\_ACEOF
8332 #define HAVE__ETEXT 1
8333 _ACEOF
8334
8335 fi
8336 echo "$as_me:$LINENO: checking for etext" >&5
8337 echo $ECHO_N "checking for etext... $ECHO_C" >&6
8338 if test "${ac_cv_var_etext+set}" = set; then
8339   echo $ECHO_N "(cached) $ECHO_C" >&6
8340 else
8341   cat >conftest.$ac_ext <<_ACEOF
8342 /* confdefs.h.  */
8343 _ACEOF
8344 cat confdefs.h >>conftest.$ac_ext
8345 cat >>conftest.$ac_ext <<_ACEOF
8346 /* end confdefs.h.  */
8347 #include <stdlib.h>
8348 extern char etext;
8349
8350 int
8351 main ()
8352 {
8353 free (&etext);
8354   ;
8355   return 0;
8356 }
8357 _ACEOF
8358 rm -f conftest.$ac_objext conftest$ac_exeext
8359 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8360   (eval $ac_link) 2>conftest.er1
8361   ac_status=$?
8362   grep -v '^ *+' conftest.er1 >conftest.err
8363   rm -f conftest.er1
8364   cat conftest.err >&5
8365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8366   (exit $ac_status); } &&
8367          { ac_try='test -z "$ac_c_werror_flag"
8368                          || test ! -s conftest.err'
8369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8370   (eval $ac_try) 2>&5
8371   ac_status=$?
8372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8373   (exit $ac_status); }; } &&
8374          { ac_try='test -s conftest$ac_exeext'
8375   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8376   (eval $ac_try) 2>&5
8377   ac_status=$?
8378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8379   (exit $ac_status); }; }; then
8380   ac_cv_var_etext=yes
8381 else
8382   echo "$as_me: failed program was:" >&5
8383 sed 's/^/| /' conftest.$ac_ext >&5
8384
8385 ac_cv_var_etext=no
8386 fi
8387 rm -f conftest.err conftest.$ac_objext \
8388       conftest$ac_exeext conftest.$ac_ext
8389 fi
8390 echo "$as_me:$LINENO: result: $ac_cv_var_etext" >&5
8391 echo "${ECHO_T}$ac_cv_var_etext" >&6
8392 if test $ac_cv_var_etext = yes; then
8393
8394 cat >>confdefs.h <<\_ACEOF
8395 #define HAVE_ETEXT 1
8396 _ACEOF
8397
8398 fi
8399 if test "$enable_profiling" = yes ; then
8400   if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
8401     { { echo "$as_me:$LINENO: error: --enable-profiling requires monstartup and _mcleanup" >&5
8402 echo "$as_me: error: --enable-profiling requires monstartup and _mcleanup" >&2;}
8403    { (exit 1); exit 1; }; }
8404   fi
8405   PROFILE_CFLAGS=-pg
8406   OLD_CFLAGS="$CFLAGS"
8407   CFLAGS="$CFLAGS $PROFILE_CFLAGS"
8408
8409   echo "$as_me:$LINENO: checking whether $CC supports -pg" >&5
8410 echo $ECHO_N "checking whether $CC supports -pg... $ECHO_C" >&6
8411 if test "${ac_cv_cc_supports_pg+set}" = set; then
8412   echo $ECHO_N "(cached) $ECHO_C" >&6
8413 else
8414   cat >conftest.$ac_ext <<_ACEOF
8415 /* confdefs.h.  */
8416 _ACEOF
8417 cat confdefs.h >>conftest.$ac_ext
8418 cat >>conftest.$ac_ext <<_ACEOF
8419 /* end confdefs.h.  */
8420
8421 int
8422 main ()
8423 {
8424 int x;
8425   ;
8426   return 0;
8427 }
8428 _ACEOF
8429 rm -f conftest.$ac_objext
8430 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8431   (eval $ac_compile) 2>conftest.er1
8432   ac_status=$?
8433   grep -v '^ *+' conftest.er1 >conftest.err
8434   rm -f conftest.er1
8435   cat conftest.err >&5
8436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8437   (exit $ac_status); } &&
8438          { ac_try='test -z "$ac_c_werror_flag"
8439                          || test ! -s conftest.err'
8440   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8441   (eval $ac_try) 2>&5
8442   ac_status=$?
8443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8444   (exit $ac_status); }; } &&
8445          { ac_try='test -s conftest.$ac_objext'
8446   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8447   (eval $ac_try) 2>&5
8448   ac_status=$?
8449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8450   (exit $ac_status); }; }; then
8451   ac_cv_cc_supports_pg=yes
8452 else
8453   echo "$as_me: failed program was:" >&5
8454 sed 's/^/| /' conftest.$ac_ext >&5
8455
8456 ac_cv_cc_supports_pg=no
8457 fi
8458 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8459 fi
8460 echo "$as_me:$LINENO: result: $ac_cv_cc_supports_pg" >&5
8461 echo "${ECHO_T}$ac_cv_cc_supports_pg" >&6
8462
8463   if test $ac_cv_cc_supports_pg = no; then
8464     { { echo "$as_me:$LINENO: error: --enable-profiling requires a compiler which supports -pg" >&5
8465 echo "$as_me: error: --enable-profiling requires a compiler which supports -pg" >&2;}
8466    { (exit 1); exit 1; }; }
8467   fi
8468
8469   CFLAGS="$OLD_CFLAGS"
8470 fi
8471
8472
8473
8474 # Check whether --with-pkgversion or --without-pkgversion was given.
8475 if test "${with_pkgversion+set}" = set; then
8476   withval="$with_pkgversion"
8477   case "$withval" in
8478       yes) { { echo "$as_me:$LINENO: error: package version not specified" >&5
8479 echo "$as_me: error: package version not specified" >&2;}
8480    { (exit 1); exit 1; }; } ;;
8481       no)  PKGVERSION= ;;
8482       *)   PKGVERSION="($withval) " ;;
8483      esac
8484 else
8485   PKGVERSION="(GDB) "
8486
8487 fi;
8488
8489
8490
8491
8492 # Check whether --with-bugurl or --without-bugurl was given.
8493 if test "${with_bugurl+set}" = set; then
8494   withval="$with_bugurl"
8495   case "$withval" in
8496       yes) { { echo "$as_me:$LINENO: error: bug URL not specified" >&5
8497 echo "$as_me: error: bug URL not specified" >&2;}
8498    { (exit 1); exit 1; }; } ;;
8499       no)  BUGURL=
8500            ;;
8501       *)   BUGURL="$withval"
8502            ;;
8503      esac
8504 else
8505   BUGURL="http://www.gnu.org/software/gdb/bugs/"
8506
8507 fi;
8508   case ${BUGURL} in
8509   "")
8510     REPORT_BUGS_TO=
8511     REPORT_BUGS_TEXI=
8512     ;;
8513   *)
8514     REPORT_BUGS_TO="<$BUGURL>"
8515     REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
8516     ;;
8517   esac;
8518
8519
8520
8521
8522 cat >>confdefs.h <<_ACEOF
8523 #define PKGVERSION "$PKGVERSION"
8524 _ACEOF
8525
8526
8527 cat >>confdefs.h <<_ACEOF
8528 #define REPORT_BUGS_TO "$REPORT_BUGS_TO"
8529 _ACEOF
8530
8531
8532 # --------------------- #
8533 # Checks for programs.  #
8534 # --------------------- #
8535
8536 for ac_prog in gawk mawk nawk awk
8537 do
8538   # Extract the first word of "$ac_prog", so it can be a program name with args.
8539 set dummy $ac_prog; ac_word=$2
8540 echo "$as_me:$LINENO: checking for $ac_word" >&5
8541 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8542 if test "${ac_cv_prog_AWK+set}" = set; then
8543   echo $ECHO_N "(cached) $ECHO_C" >&6
8544 else
8545   if test -n "$AWK"; then
8546   ac_cv_prog_AWK="$AWK" # Let the user override the test.
8547 else
8548 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8549 for as_dir in $PATH
8550 do
8551   IFS=$as_save_IFS
8552   test -z "$as_dir" && as_dir=.
8553   for ac_exec_ext in '' $ac_executable_extensions; do
8554   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8555     ac_cv_prog_AWK="$ac_prog"
8556     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8557     break 2
8558   fi
8559 done
8560 done
8561
8562 fi
8563 fi
8564 AWK=$ac_cv_prog_AWK
8565 if test -n "$AWK"; then
8566   echo "$as_me:$LINENO: result: $AWK" >&5
8567 echo "${ECHO_T}$AWK" >&6
8568 else
8569   echo "$as_me:$LINENO: result: no" >&5
8570 echo "${ECHO_T}no" >&6
8571 fi
8572
8573   test -n "$AWK" && break
8574 done
8575
8576 # Find a good install program.  We prefer a C program (faster),
8577 # so one script is as good as another.  But avoid the broken or
8578 # incompatible versions:
8579 # SysV /etc/install, /usr/sbin/install
8580 # SunOS /usr/etc/install
8581 # IRIX /sbin/install
8582 # AIX /bin/install
8583 # AmigaOS /C/install, which installs bootblocks on floppy discs
8584 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
8585 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
8586 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
8587 # OS/2's system install, which has a completely different semantic
8588 # ./install, which can be erroneously created by make from ./install.sh.
8589 # Reject install programs that cannot install multiple files.
8590 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
8591 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
8592 if test -z "$INSTALL"; then
8593 if test "${ac_cv_path_install+set}" = set; then
8594   echo $ECHO_N "(cached) $ECHO_C" >&6
8595 else
8596   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8597 for as_dir in $PATH
8598 do
8599   IFS=$as_save_IFS
8600   test -z "$as_dir" && as_dir=.
8601   # Account for people who put trailing slashes in PATH elements.
8602 case $as_dir/ in
8603   ./ | .// | /cC/* | \
8604   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
8605   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
8606   /usr/ucb/* ) ;;
8607   *)
8608     # OSF1 and SCO ODT 3.0 have their own names for install.
8609     # Don't use installbsd from OSF since it installs stuff as root
8610     # by default.
8611     for ac_prog in ginstall scoinst install; do
8612       for ac_exec_ext in '' $ac_executable_extensions; do
8613         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
8614           if test $ac_prog = install &&
8615             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8616             # AIX install.  It has an incompatible calling convention.
8617             :
8618           elif test $ac_prog = install &&
8619             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
8620             # program-specific install script used by HP pwplus--don't use.
8621             :
8622           else
8623             rm -rf conftest.one conftest.two conftest.dir
8624             echo one > conftest.one
8625             echo two > conftest.two
8626             mkdir conftest.dir
8627             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
8628               test -s conftest.one && test -s conftest.two &&
8629               test -s conftest.dir/conftest.one &&
8630               test -s conftest.dir/conftest.two
8631             then
8632               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
8633               break 3
8634             fi
8635           fi
8636         fi
8637       done
8638     done
8639     ;;
8640 esac
8641 done
8642
8643 rm -rf conftest.one conftest.two conftest.dir
8644
8645 fi
8646   if test "${ac_cv_path_install+set}" = set; then
8647     INSTALL=$ac_cv_path_install
8648   else
8649     # As a last resort, use the slow shell script.  Don't cache a
8650     # value for INSTALL within a source directory, because that will
8651     # break other packages using the cache if that directory is
8652     # removed, or if the value is a relative name.
8653     INSTALL=$ac_install_sh
8654   fi
8655 fi
8656 echo "$as_me:$LINENO: result: $INSTALL" >&5
8657 echo "${ECHO_T}$INSTALL" >&6
8658
8659 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
8660 # It thinks the first close brace ends the variable substitution.
8661 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
8662
8663 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
8664
8665 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
8666
8667 echo "$as_me:$LINENO: checking whether ln -s works" >&5
8668 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
8669 LN_S=$as_ln_s
8670 if test "$LN_S" = "ln -s"; then
8671   echo "$as_me:$LINENO: result: yes" >&5
8672 echo "${ECHO_T}yes" >&6
8673 else
8674   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
8675 echo "${ECHO_T}no, using $LN_S" >&6
8676 fi
8677
8678 if test -n "$ac_tool_prefix"; then
8679   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8680 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8681 echo "$as_me:$LINENO: checking for $ac_word" >&5
8682 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8683 if test "${ac_cv_prog_RANLIB+set}" = set; then
8684   echo $ECHO_N "(cached) $ECHO_C" >&6
8685 else
8686   if test -n "$RANLIB"; then
8687   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8688 else
8689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8690 for as_dir in $PATH
8691 do
8692   IFS=$as_save_IFS
8693   test -z "$as_dir" && as_dir=.
8694   for ac_exec_ext in '' $ac_executable_extensions; do
8695   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8696     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8697     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8698     break 2
8699   fi
8700 done
8701 done
8702
8703 fi
8704 fi
8705 RANLIB=$ac_cv_prog_RANLIB
8706 if test -n "$RANLIB"; then
8707   echo "$as_me:$LINENO: result: $RANLIB" >&5
8708 echo "${ECHO_T}$RANLIB" >&6
8709 else
8710   echo "$as_me:$LINENO: result: no" >&5
8711 echo "${ECHO_T}no" >&6
8712 fi
8713
8714 fi
8715 if test -z "$ac_cv_prog_RANLIB"; then
8716   ac_ct_RANLIB=$RANLIB
8717   # Extract the first word of "ranlib", so it can be a program name with args.
8718 set dummy ranlib; ac_word=$2
8719 echo "$as_me:$LINENO: checking for $ac_word" >&5
8720 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8721 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
8722   echo $ECHO_N "(cached) $ECHO_C" >&6
8723 else
8724   if test -n "$ac_ct_RANLIB"; then
8725   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8726 else
8727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8728 for as_dir in $PATH
8729 do
8730   IFS=$as_save_IFS
8731   test -z "$as_dir" && as_dir=.
8732   for ac_exec_ext in '' $ac_executable_extensions; do
8733   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8734     ac_cv_prog_ac_ct_RANLIB="ranlib"
8735     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8736     break 2
8737   fi
8738 done
8739 done
8740
8741   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
8742 fi
8743 fi
8744 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8745 if test -n "$ac_ct_RANLIB"; then
8746   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
8747 echo "${ECHO_T}$ac_ct_RANLIB" >&6
8748 else
8749   echo "$as_me:$LINENO: result: no" >&5
8750 echo "${ECHO_T}no" >&6
8751 fi
8752
8753   RANLIB=$ac_ct_RANLIB
8754 else
8755   RANLIB="$ac_cv_prog_RANLIB"
8756 fi
8757
8758 for ac_prog in 'bison -y' byacc
8759 do
8760   # Extract the first word of "$ac_prog", so it can be a program name with args.
8761 set dummy $ac_prog; ac_word=$2
8762 echo "$as_me:$LINENO: checking for $ac_word" >&5
8763 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8764 if test "${ac_cv_prog_YACC+set}" = set; then
8765   echo $ECHO_N "(cached) $ECHO_C" >&6
8766 else
8767   if test -n "$YACC"; then
8768   ac_cv_prog_YACC="$YACC" # Let the user override the test.
8769 else
8770 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8771 for as_dir in $PATH
8772 do
8773   IFS=$as_save_IFS
8774   test -z "$as_dir" && as_dir=.
8775   for ac_exec_ext in '' $ac_executable_extensions; do
8776   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8777     ac_cv_prog_YACC="$ac_prog"
8778     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8779     break 2
8780   fi
8781 done
8782 done
8783
8784 fi
8785 fi
8786 YACC=$ac_cv_prog_YACC
8787 if test -n "$YACC"; then
8788   echo "$as_me:$LINENO: result: $YACC" >&5
8789 echo "${ECHO_T}$YACC" >&6
8790 else
8791   echo "$as_me:$LINENO: result: no" >&5
8792 echo "${ECHO_T}no" >&6
8793 fi
8794
8795   test -n "$YACC" && break
8796 done
8797 test -n "$YACC" || YACC="yacc"
8798
8799
8800 if test -n "$ac_tool_prefix"; then
8801   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
8802 set dummy ${ac_tool_prefix}ar; ac_word=$2
8803 echo "$as_me:$LINENO: checking for $ac_word" >&5
8804 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8805 if test "${ac_cv_prog_AR+set}" = set; then
8806   echo $ECHO_N "(cached) $ECHO_C" >&6
8807 else
8808   if test -n "$AR"; then
8809   ac_cv_prog_AR="$AR" # Let the user override the test.
8810 else
8811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8812 for as_dir in $PATH
8813 do
8814   IFS=$as_save_IFS
8815   test -z "$as_dir" && as_dir=.
8816   for ac_exec_ext in '' $ac_executable_extensions; do
8817   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8818     ac_cv_prog_AR="${ac_tool_prefix}ar"
8819     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8820     break 2
8821   fi
8822 done
8823 done
8824
8825 fi
8826 fi
8827 AR=$ac_cv_prog_AR
8828 if test -n "$AR"; then
8829   echo "$as_me:$LINENO: result: $AR" >&5
8830 echo "${ECHO_T}$AR" >&6
8831 else
8832   echo "$as_me:$LINENO: result: no" >&5
8833 echo "${ECHO_T}no" >&6
8834 fi
8835
8836 fi
8837 if test -z "$ac_cv_prog_AR"; then
8838   ac_ct_AR=$AR
8839   # Extract the first word of "ar", so it can be a program name with args.
8840 set dummy ar; ac_word=$2
8841 echo "$as_me:$LINENO: checking for $ac_word" >&5
8842 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8843 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
8844   echo $ECHO_N "(cached) $ECHO_C" >&6
8845 else
8846   if test -n "$ac_ct_AR"; then
8847   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8848 else
8849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8850 for as_dir in $PATH
8851 do
8852   IFS=$as_save_IFS
8853   test -z "$as_dir" && as_dir=.
8854   for ac_exec_ext in '' $ac_executable_extensions; do
8855   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8856     ac_cv_prog_ac_ct_AR="ar"
8857     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8858     break 2
8859   fi
8860 done
8861 done
8862
8863 fi
8864 fi
8865 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8866 if test -n "$ac_ct_AR"; then
8867   echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
8868 echo "${ECHO_T}$ac_ct_AR" >&6
8869 else
8870   echo "$as_me:$LINENO: result: no" >&5
8871 echo "${ECHO_T}no" >&6
8872 fi
8873
8874   AR=$ac_ct_AR
8875 else
8876   AR="$ac_cv_prog_AR"
8877 fi
8878
8879 if test -n "$ac_tool_prefix"; then
8880   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8881 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8882 echo "$as_me:$LINENO: checking for $ac_word" >&5
8883 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8884 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
8885   echo $ECHO_N "(cached) $ECHO_C" >&6
8886 else
8887   if test -n "$DLLTOOL"; then
8888   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8889 else
8890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8891 for as_dir in $PATH
8892 do
8893   IFS=$as_save_IFS
8894   test -z "$as_dir" && as_dir=.
8895   for ac_exec_ext in '' $ac_executable_extensions; do
8896   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8897     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8898     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8899     break 2
8900   fi
8901 done
8902 done
8903
8904 fi
8905 fi
8906 DLLTOOL=$ac_cv_prog_DLLTOOL
8907 if test -n "$DLLTOOL"; then
8908   echo "$as_me:$LINENO: result: $DLLTOOL" >&5
8909 echo "${ECHO_T}$DLLTOOL" >&6
8910 else
8911   echo "$as_me:$LINENO: result: no" >&5
8912 echo "${ECHO_T}no" >&6
8913 fi
8914
8915 fi
8916 if test -z "$ac_cv_prog_DLLTOOL"; then
8917   ac_ct_DLLTOOL=$DLLTOOL
8918   # Extract the first word of "dlltool", so it can be a program name with args.
8919 set dummy dlltool; ac_word=$2
8920 echo "$as_me:$LINENO: checking for $ac_word" >&5
8921 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8922 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
8923   echo $ECHO_N "(cached) $ECHO_C" >&6
8924 else
8925   if test -n "$ac_ct_DLLTOOL"; then
8926   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8927 else
8928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8929 for as_dir in $PATH
8930 do
8931   IFS=$as_save_IFS
8932   test -z "$as_dir" && as_dir=.
8933   for ac_exec_ext in '' $ac_executable_extensions; do
8934   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8935     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8936     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8937     break 2
8938   fi
8939 done
8940 done
8941
8942 fi
8943 fi
8944 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8945 if test -n "$ac_ct_DLLTOOL"; then
8946   echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
8947 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6
8948 else
8949   echo "$as_me:$LINENO: result: no" >&5
8950 echo "${ECHO_T}no" >&6
8951 fi
8952
8953   DLLTOOL=$ac_ct_DLLTOOL
8954 else
8955   DLLTOOL="$ac_cv_prog_DLLTOOL"
8956 fi
8957
8958 if test -n "$ac_tool_prefix"; then
8959   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
8960 set dummy ${ac_tool_prefix}windres; ac_word=$2
8961 echo "$as_me:$LINENO: checking for $ac_word" >&5
8962 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8963 if test "${ac_cv_prog_WINDRES+set}" = set; then
8964   echo $ECHO_N "(cached) $ECHO_C" >&6
8965 else
8966   if test -n "$WINDRES"; then
8967   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
8968 else
8969 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8970 for as_dir in $PATH
8971 do
8972   IFS=$as_save_IFS
8973   test -z "$as_dir" && as_dir=.
8974   for ac_exec_ext in '' $ac_executable_extensions; do
8975   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8976     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
8977     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8978     break 2
8979   fi
8980 done
8981 done
8982
8983 fi
8984 fi
8985 WINDRES=$ac_cv_prog_WINDRES
8986 if test -n "$WINDRES"; then
8987   echo "$as_me:$LINENO: result: $WINDRES" >&5
8988 echo "${ECHO_T}$WINDRES" >&6
8989 else
8990   echo "$as_me:$LINENO: result: no" >&5
8991 echo "${ECHO_T}no" >&6
8992 fi
8993
8994 fi
8995 if test -z "$ac_cv_prog_WINDRES"; then
8996   ac_ct_WINDRES=$WINDRES
8997   # Extract the first word of "windres", so it can be a program name with args.
8998 set dummy windres; ac_word=$2
8999 echo "$as_me:$LINENO: checking for $ac_word" >&5
9000 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9001 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
9002   echo $ECHO_N "(cached) $ECHO_C" >&6
9003 else
9004   if test -n "$ac_ct_WINDRES"; then
9005   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
9006 else
9007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9008 for as_dir in $PATH
9009 do
9010   IFS=$as_save_IFS
9011   test -z "$as_dir" && as_dir=.
9012   for ac_exec_ext in '' $ac_executable_extensions; do
9013   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9014     ac_cv_prog_ac_ct_WINDRES="windres"
9015     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9016     break 2
9017   fi
9018 done
9019 done
9020
9021 fi
9022 fi
9023 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
9024 if test -n "$ac_ct_WINDRES"; then
9025   echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
9026 echo "${ECHO_T}$ac_ct_WINDRES" >&6
9027 else
9028   echo "$as_me:$LINENO: result: no" >&5
9029 echo "${ECHO_T}no" >&6
9030 fi
9031
9032   WINDRES=$ac_ct_WINDRES
9033 else
9034   WINDRES="$ac_cv_prog_WINDRES"
9035 fi
9036
9037
9038 # Needed for GNU/Hurd.
9039 if test -n "$ac_tool_prefix"; then
9040   # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
9041 set dummy ${ac_tool_prefix}mig; ac_word=$2
9042 echo "$as_me:$LINENO: checking for $ac_word" >&5
9043 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9044 if test "${ac_cv_prog_MIG+set}" = set; then
9045   echo $ECHO_N "(cached) $ECHO_C" >&6
9046 else
9047   if test -n "$MIG"; then
9048   ac_cv_prog_MIG="$MIG" # Let the user override the test.
9049 else
9050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9051 for as_dir in $PATH
9052 do
9053   IFS=$as_save_IFS
9054   test -z "$as_dir" && as_dir=.
9055   for ac_exec_ext in '' $ac_executable_extensions; do
9056   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9057     ac_cv_prog_MIG="${ac_tool_prefix}mig"
9058     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9059     break 2
9060   fi
9061 done
9062 done
9063
9064 fi
9065 fi
9066 MIG=$ac_cv_prog_MIG
9067 if test -n "$MIG"; then
9068   echo "$as_me:$LINENO: result: $MIG" >&5
9069 echo "${ECHO_T}$MIG" >&6
9070 else
9071   echo "$as_me:$LINENO: result: no" >&5
9072 echo "${ECHO_T}no" >&6
9073 fi
9074
9075 fi
9076 if test -z "$ac_cv_prog_MIG"; then
9077   ac_ct_MIG=$MIG
9078   # Extract the first word of "mig", so it can be a program name with args.
9079 set dummy mig; ac_word=$2
9080 echo "$as_me:$LINENO: checking for $ac_word" >&5
9081 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9082 if test "${ac_cv_prog_ac_ct_MIG+set}" = set; then
9083   echo $ECHO_N "(cached) $ECHO_C" >&6
9084 else
9085   if test -n "$ac_ct_MIG"; then
9086   ac_cv_prog_ac_ct_MIG="$ac_ct_MIG" # Let the user override the test.
9087 else
9088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9089 for as_dir in $PATH
9090 do
9091   IFS=$as_save_IFS
9092   test -z "$as_dir" && as_dir=.
9093   for ac_exec_ext in '' $ac_executable_extensions; do
9094   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9095     ac_cv_prog_ac_ct_MIG="mig"
9096     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9097     break 2
9098   fi
9099 done
9100 done
9101
9102 fi
9103 fi
9104 ac_ct_MIG=$ac_cv_prog_ac_ct_MIG
9105 if test -n "$ac_ct_MIG"; then
9106   echo "$as_me:$LINENO: result: $ac_ct_MIG" >&5
9107 echo "${ECHO_T}$ac_ct_MIG" >&6
9108 else
9109   echo "$as_me:$LINENO: result: no" >&5
9110 echo "${ECHO_T}no" >&6
9111 fi
9112
9113   MIG=$ac_ct_MIG
9114 else
9115   MIG="$ac_cv_prog_MIG"
9116 fi
9117
9118
9119 # ---------------------- #
9120 # Checks for libraries.  #
9121 # ---------------------- #
9122
9123 # We might need to link with -lm; most simulators need it.
9124
9125 echo "$as_me:$LINENO: checking for main in -lm" >&5
9126 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6
9127 if test "${ac_cv_lib_m_main+set}" = set; then
9128   echo $ECHO_N "(cached) $ECHO_C" >&6
9129 else
9130   ac_check_lib_save_LIBS=$LIBS
9131 LIBS="-lm  $LIBS"
9132 cat >conftest.$ac_ext <<_ACEOF
9133 /* confdefs.h.  */
9134 _ACEOF
9135 cat confdefs.h >>conftest.$ac_ext
9136 cat >>conftest.$ac_ext <<_ACEOF
9137 /* end confdefs.h.  */
9138
9139
9140 int
9141 main ()
9142 {
9143 main ();
9144   ;
9145   return 0;
9146 }
9147 _ACEOF
9148 rm -f conftest.$ac_objext conftest$ac_exeext
9149 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9150   (eval $ac_link) 2>conftest.er1
9151   ac_status=$?
9152   grep -v '^ *+' conftest.er1 >conftest.err
9153   rm -f conftest.er1
9154   cat conftest.err >&5
9155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9156   (exit $ac_status); } &&
9157          { ac_try='test -z "$ac_c_werror_flag"
9158                          || test ! -s conftest.err'
9159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9160   (eval $ac_try) 2>&5
9161   ac_status=$?
9162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9163   (exit $ac_status); }; } &&
9164          { ac_try='test -s conftest$ac_exeext'
9165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9166   (eval $ac_try) 2>&5
9167   ac_status=$?
9168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9169   (exit $ac_status); }; }; then
9170   ac_cv_lib_m_main=yes
9171 else
9172   echo "$as_me: failed program was:" >&5
9173 sed 's/^/| /' conftest.$ac_ext >&5
9174
9175 ac_cv_lib_m_main=no
9176 fi
9177 rm -f conftest.err conftest.$ac_objext \
9178       conftest$ac_exeext conftest.$ac_ext
9179 LIBS=$ac_check_lib_save_LIBS
9180 fi
9181 echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
9182 echo "${ECHO_T}$ac_cv_lib_m_main" >&6
9183 if test $ac_cv_lib_m_main = yes; then
9184   cat >>confdefs.h <<_ACEOF
9185 #define HAVE_LIBM 1
9186 _ACEOF
9187
9188   LIBS="-lm $LIBS"
9189
9190 fi
9191
9192
9193 # We need to link with -lw to get `wctype' on Solaris before Solaris
9194 # 2.6.  Solaris 2.6 and beyond have this function in libc, and have a
9195 # libw that some versions of the GNU linker cannot hanle (GNU ld 2.9.1
9196 # is known to have this problem).  Therefore we avoid libw if we can.
9197 echo "$as_me:$LINENO: checking for wctype" >&5
9198 echo $ECHO_N "checking for wctype... $ECHO_C" >&6
9199 if test "${ac_cv_func_wctype+set}" = set; then
9200   echo $ECHO_N "(cached) $ECHO_C" >&6
9201 else
9202   cat >conftest.$ac_ext <<_ACEOF
9203 /* confdefs.h.  */
9204 _ACEOF
9205 cat confdefs.h >>conftest.$ac_ext
9206 cat >>conftest.$ac_ext <<_ACEOF
9207 /* end confdefs.h.  */
9208 /* Define wctype to an innocuous variant, in case <limits.h> declares wctype.
9209    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9210 #define wctype innocuous_wctype
9211
9212 /* System header to define __stub macros and hopefully few prototypes,
9213     which can conflict with char wctype (); below.
9214     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9215     <limits.h> exists even on freestanding compilers.  */
9216
9217 #ifdef __STDC__
9218 # include <limits.h>
9219 #else
9220 # include <assert.h>
9221 #endif
9222
9223 #undef wctype
9224
9225 /* Override any gcc2 internal prototype to avoid an error.  */
9226 #ifdef __cplusplus
9227 extern "C"
9228 {
9229 #endif
9230 /* We use char because int might match the return type of a gcc2
9231    builtin and then its argument prototype would still apply.  */
9232 char wctype ();
9233 /* The GNU C library defines this for functions which it implements
9234     to always fail with ENOSYS.  Some functions are actually named
9235     something starting with __ and the normal name is an alias.  */
9236 #if defined (__stub_wctype) || defined (__stub___wctype)
9237 choke me
9238 #else
9239 char (*f) () = wctype;
9240 #endif
9241 #ifdef __cplusplus
9242 }
9243 #endif
9244
9245 int
9246 main ()
9247 {
9248 return f != wctype;
9249   ;
9250   return 0;
9251 }
9252 _ACEOF
9253 rm -f conftest.$ac_objext conftest$ac_exeext
9254 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9255   (eval $ac_link) 2>conftest.er1
9256   ac_status=$?
9257   grep -v '^ *+' conftest.er1 >conftest.err
9258   rm -f conftest.er1
9259   cat conftest.err >&5
9260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9261   (exit $ac_status); } &&
9262          { ac_try='test -z "$ac_c_werror_flag"
9263                          || test ! -s conftest.err'
9264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9265   (eval $ac_try) 2>&5
9266   ac_status=$?
9267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9268   (exit $ac_status); }; } &&
9269          { ac_try='test -s conftest$ac_exeext'
9270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9271   (eval $ac_try) 2>&5
9272   ac_status=$?
9273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9274   (exit $ac_status); }; }; then
9275   ac_cv_func_wctype=yes
9276 else
9277   echo "$as_me: failed program was:" >&5
9278 sed 's/^/| /' conftest.$ac_ext >&5
9279
9280 ac_cv_func_wctype=no
9281 fi
9282 rm -f conftest.err conftest.$ac_objext \
9283       conftest$ac_exeext conftest.$ac_ext
9284 fi
9285 echo "$as_me:$LINENO: result: $ac_cv_func_wctype" >&5
9286 echo "${ECHO_T}$ac_cv_func_wctype" >&6
9287 if test $ac_cv_func_wctype = yes; then
9288   :
9289 else
9290
9291 echo "$as_me:$LINENO: checking for wctype in -lw" >&5
9292 echo $ECHO_N "checking for wctype in -lw... $ECHO_C" >&6
9293 if test "${ac_cv_lib_w_wctype+set}" = set; then
9294   echo $ECHO_N "(cached) $ECHO_C" >&6
9295 else
9296   ac_check_lib_save_LIBS=$LIBS
9297 LIBS="-lw  $LIBS"
9298 cat >conftest.$ac_ext <<_ACEOF
9299 /* confdefs.h.  */
9300 _ACEOF
9301 cat confdefs.h >>conftest.$ac_ext
9302 cat >>conftest.$ac_ext <<_ACEOF
9303 /* end confdefs.h.  */
9304
9305 /* Override any gcc2 internal prototype to avoid an error.  */
9306 #ifdef __cplusplus
9307 extern "C"
9308 #endif
9309 /* We use char because int might match the return type of a gcc2
9310    builtin and then its argument prototype would still apply.  */
9311 char wctype ();
9312 int
9313 main ()
9314 {
9315 wctype ();
9316   ;
9317   return 0;
9318 }
9319 _ACEOF
9320 rm -f conftest.$ac_objext conftest$ac_exeext
9321 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9322   (eval $ac_link) 2>conftest.er1
9323   ac_status=$?
9324   grep -v '^ *+' conftest.er1 >conftest.err
9325   rm -f conftest.er1
9326   cat conftest.err >&5
9327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9328   (exit $ac_status); } &&
9329          { ac_try='test -z "$ac_c_werror_flag"
9330                          || test ! -s conftest.err'
9331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9332   (eval $ac_try) 2>&5
9333   ac_status=$?
9334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9335   (exit $ac_status); }; } &&
9336          { ac_try='test -s conftest$ac_exeext'
9337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9338   (eval $ac_try) 2>&5
9339   ac_status=$?
9340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9341   (exit $ac_status); }; }; then
9342   ac_cv_lib_w_wctype=yes
9343 else
9344   echo "$as_me: failed program was:" >&5
9345 sed 's/^/| /' conftest.$ac_ext >&5
9346
9347 ac_cv_lib_w_wctype=no
9348 fi
9349 rm -f conftest.err conftest.$ac_objext \
9350       conftest$ac_exeext conftest.$ac_ext
9351 LIBS=$ac_check_lib_save_LIBS
9352 fi
9353 echo "$as_me:$LINENO: result: $ac_cv_lib_w_wctype" >&5
9354 echo "${ECHO_T}$ac_cv_lib_w_wctype" >&6
9355 if test $ac_cv_lib_w_wctype = yes; then
9356   cat >>confdefs.h <<_ACEOF
9357 #define HAVE_LIBW 1
9358 _ACEOF
9359
9360   LIBS="-lw $LIBS"
9361
9362 fi
9363
9364 fi
9365
9366
9367 # Some systems (e.g. Solaris) have `gethostbyname' in libnsl.
9368 echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5
9369 echo $ECHO_N "checking for library containing gethostbyname... $ECHO_C" >&6
9370 if test "${ac_cv_search_gethostbyname+set}" = set; then
9371   echo $ECHO_N "(cached) $ECHO_C" >&6
9372 else
9373   ac_func_search_save_LIBS=$LIBS
9374 ac_cv_search_gethostbyname=no
9375 cat >conftest.$ac_ext <<_ACEOF
9376 /* confdefs.h.  */
9377 _ACEOF
9378 cat confdefs.h >>conftest.$ac_ext
9379 cat >>conftest.$ac_ext <<_ACEOF
9380 /* end confdefs.h.  */
9381
9382 /* Override any gcc2 internal prototype to avoid an error.  */
9383 #ifdef __cplusplus
9384 extern "C"
9385 #endif
9386 /* We use char because int might match the return type of a gcc2
9387    builtin and then its argument prototype would still apply.  */
9388 char gethostbyname ();
9389 int
9390 main ()
9391 {
9392 gethostbyname ();
9393   ;
9394   return 0;
9395 }
9396 _ACEOF
9397 rm -f conftest.$ac_objext conftest$ac_exeext
9398 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9399   (eval $ac_link) 2>conftest.er1
9400   ac_status=$?
9401   grep -v '^ *+' conftest.er1 >conftest.err
9402   rm -f conftest.er1
9403   cat conftest.err >&5
9404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9405   (exit $ac_status); } &&
9406          { ac_try='test -z "$ac_c_werror_flag"
9407                          || test ! -s conftest.err'
9408   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9409   (eval $ac_try) 2>&5
9410   ac_status=$?
9411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9412   (exit $ac_status); }; } &&
9413          { ac_try='test -s conftest$ac_exeext'
9414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9415   (eval $ac_try) 2>&5
9416   ac_status=$?
9417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9418   (exit $ac_status); }; }; then
9419   ac_cv_search_gethostbyname="none required"
9420 else
9421   echo "$as_me: failed program was:" >&5
9422 sed 's/^/| /' conftest.$ac_ext >&5
9423
9424 fi
9425 rm -f conftest.err conftest.$ac_objext \
9426       conftest$ac_exeext conftest.$ac_ext
9427 if test "$ac_cv_search_gethostbyname" = no; then
9428   for ac_lib in nsl; do
9429     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9430     cat >conftest.$ac_ext <<_ACEOF
9431 /* confdefs.h.  */
9432 _ACEOF
9433 cat confdefs.h >>conftest.$ac_ext
9434 cat >>conftest.$ac_ext <<_ACEOF
9435 /* end confdefs.h.  */
9436
9437 /* Override any gcc2 internal prototype to avoid an error.  */
9438 #ifdef __cplusplus
9439 extern "C"
9440 #endif
9441 /* We use char because int might match the return type of a gcc2
9442    builtin and then its argument prototype would still apply.  */
9443 char gethostbyname ();
9444 int
9445 main ()
9446 {
9447 gethostbyname ();
9448   ;
9449   return 0;
9450 }
9451 _ACEOF
9452 rm -f conftest.$ac_objext conftest$ac_exeext
9453 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9454   (eval $ac_link) 2>conftest.er1
9455   ac_status=$?
9456   grep -v '^ *+' conftest.er1 >conftest.err
9457   rm -f conftest.er1
9458   cat conftest.err >&5
9459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9460   (exit $ac_status); } &&
9461          { ac_try='test -z "$ac_c_werror_flag"
9462                          || test ! -s conftest.err'
9463   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9464   (eval $ac_try) 2>&5
9465   ac_status=$?
9466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9467   (exit $ac_status); }; } &&
9468          { ac_try='test -s conftest$ac_exeext'
9469   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9470   (eval $ac_try) 2>&5
9471   ac_status=$?
9472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9473   (exit $ac_status); }; }; then
9474   ac_cv_search_gethostbyname="-l$ac_lib"
9475 break
9476 else
9477   echo "$as_me: failed program was:" >&5
9478 sed 's/^/| /' conftest.$ac_ext >&5
9479
9480 fi
9481 rm -f conftest.err conftest.$ac_objext \
9482       conftest$ac_exeext conftest.$ac_ext
9483   done
9484 fi
9485 LIBS=$ac_func_search_save_LIBS
9486 fi
9487 echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5
9488 echo "${ECHO_T}$ac_cv_search_gethostbyname" >&6
9489 if test "$ac_cv_search_gethostbyname" != no; then
9490   test "$ac_cv_search_gethostbyname" = "none required" || LIBS="$ac_cv_search_gethostbyname $LIBS"
9491
9492 fi
9493
9494
9495 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
9496 echo "$as_me:$LINENO: checking for library containing socketpair" >&5
9497 echo $ECHO_N "checking for library containing socketpair... $ECHO_C" >&6
9498 if test "${ac_cv_search_socketpair+set}" = set; then
9499   echo $ECHO_N "(cached) $ECHO_C" >&6
9500 else
9501   ac_func_search_save_LIBS=$LIBS
9502 ac_cv_search_socketpair=no
9503 cat >conftest.$ac_ext <<_ACEOF
9504 /* confdefs.h.  */
9505 _ACEOF
9506 cat confdefs.h >>conftest.$ac_ext
9507 cat >>conftest.$ac_ext <<_ACEOF
9508 /* end confdefs.h.  */
9509
9510 /* Override any gcc2 internal prototype to avoid an error.  */
9511 #ifdef __cplusplus
9512 extern "C"
9513 #endif
9514 /* We use char because int might match the return type of a gcc2
9515    builtin and then its argument prototype would still apply.  */
9516 char socketpair ();
9517 int
9518 main ()
9519 {
9520 socketpair ();
9521   ;
9522   return 0;
9523 }
9524 _ACEOF
9525 rm -f conftest.$ac_objext conftest$ac_exeext
9526 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9527   (eval $ac_link) 2>conftest.er1
9528   ac_status=$?
9529   grep -v '^ *+' conftest.er1 >conftest.err
9530   rm -f conftest.er1
9531   cat conftest.err >&5
9532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9533   (exit $ac_status); } &&
9534          { ac_try='test -z "$ac_c_werror_flag"
9535                          || test ! -s conftest.err'
9536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9537   (eval $ac_try) 2>&5
9538   ac_status=$?
9539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9540   (exit $ac_status); }; } &&
9541          { ac_try='test -s conftest$ac_exeext'
9542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9543   (eval $ac_try) 2>&5
9544   ac_status=$?
9545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9546   (exit $ac_status); }; }; then
9547   ac_cv_search_socketpair="none required"
9548 else
9549   echo "$as_me: failed program was:" >&5
9550 sed 's/^/| /' conftest.$ac_ext >&5
9551
9552 fi
9553 rm -f conftest.err conftest.$ac_objext \
9554       conftest$ac_exeext conftest.$ac_ext
9555 if test "$ac_cv_search_socketpair" = no; then
9556   for ac_lib in socket; do
9557     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9558     cat >conftest.$ac_ext <<_ACEOF
9559 /* confdefs.h.  */
9560 _ACEOF
9561 cat confdefs.h >>conftest.$ac_ext
9562 cat >>conftest.$ac_ext <<_ACEOF
9563 /* end confdefs.h.  */
9564
9565 /* Override any gcc2 internal prototype to avoid an error.  */
9566 #ifdef __cplusplus
9567 extern "C"
9568 #endif
9569 /* We use char because int might match the return type of a gcc2
9570    builtin and then its argument prototype would still apply.  */
9571 char socketpair ();
9572 int
9573 main ()
9574 {
9575 socketpair ();
9576   ;
9577   return 0;
9578 }
9579 _ACEOF
9580 rm -f conftest.$ac_objext conftest$ac_exeext
9581 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9582   (eval $ac_link) 2>conftest.er1
9583   ac_status=$?
9584   grep -v '^ *+' conftest.er1 >conftest.err
9585   rm -f conftest.er1
9586   cat conftest.err >&5
9587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9588   (exit $ac_status); } &&
9589          { ac_try='test -z "$ac_c_werror_flag"
9590                          || test ! -s conftest.err'
9591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9592   (eval $ac_try) 2>&5
9593   ac_status=$?
9594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9595   (exit $ac_status); }; } &&
9596          { ac_try='test -s conftest$ac_exeext'
9597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9598   (eval $ac_try) 2>&5
9599   ac_status=$?
9600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9601   (exit $ac_status); }; }; then
9602   ac_cv_search_socketpair="-l$ac_lib"
9603 break
9604 else
9605   echo "$as_me: failed program was:" >&5
9606 sed 's/^/| /' conftest.$ac_ext >&5
9607
9608 fi
9609 rm -f conftest.err conftest.$ac_objext \
9610       conftest$ac_exeext conftest.$ac_ext
9611   done
9612 fi
9613 LIBS=$ac_func_search_save_LIBS
9614 fi
9615 echo "$as_me:$LINENO: result: $ac_cv_search_socketpair" >&5
9616 echo "${ECHO_T}$ac_cv_search_socketpair" >&6
9617 if test "$ac_cv_search_socketpair" != no; then
9618   test "$ac_cv_search_socketpair" = "none required" || LIBS="$ac_cv_search_socketpair $LIBS"
9619
9620 fi
9621
9622
9623 # Link in zlib if we can.  This allows us to read compressed debug sections.
9624 echo "$as_me:$LINENO: checking for library containing zlibVersion" >&5
9625 echo $ECHO_N "checking for library containing zlibVersion... $ECHO_C" >&6
9626 if test "${ac_cv_search_zlibVersion+set}" = set; then
9627   echo $ECHO_N "(cached) $ECHO_C" >&6
9628 else
9629   ac_func_search_save_LIBS=$LIBS
9630 ac_cv_search_zlibVersion=no
9631 cat >conftest.$ac_ext <<_ACEOF
9632 /* confdefs.h.  */
9633 _ACEOF
9634 cat confdefs.h >>conftest.$ac_ext
9635 cat >>conftest.$ac_ext <<_ACEOF
9636 /* end confdefs.h.  */
9637
9638 /* Override any gcc2 internal prototype to avoid an error.  */
9639 #ifdef __cplusplus
9640 extern "C"
9641 #endif
9642 /* We use char because int might match the return type of a gcc2
9643    builtin and then its argument prototype would still apply.  */
9644 char zlibVersion ();
9645 int
9646 main ()
9647 {
9648 zlibVersion ();
9649   ;
9650   return 0;
9651 }
9652 _ACEOF
9653 rm -f conftest.$ac_objext conftest$ac_exeext
9654 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9655   (eval $ac_link) 2>conftest.er1
9656   ac_status=$?
9657   grep -v '^ *+' conftest.er1 >conftest.err
9658   rm -f conftest.er1
9659   cat conftest.err >&5
9660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9661   (exit $ac_status); } &&
9662          { ac_try='test -z "$ac_c_werror_flag"
9663                          || test ! -s conftest.err'
9664   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9665   (eval $ac_try) 2>&5
9666   ac_status=$?
9667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9668   (exit $ac_status); }; } &&
9669          { ac_try='test -s conftest$ac_exeext'
9670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9671   (eval $ac_try) 2>&5
9672   ac_status=$?
9673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9674   (exit $ac_status); }; }; then
9675   ac_cv_search_zlibVersion="none required"
9676 else
9677   echo "$as_me: failed program was:" >&5
9678 sed 's/^/| /' conftest.$ac_ext >&5
9679
9680 fi
9681 rm -f conftest.err conftest.$ac_objext \
9682       conftest$ac_exeext conftest.$ac_ext
9683 if test "$ac_cv_search_zlibVersion" = no; then
9684   for ac_lib in z; do
9685     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9686     cat >conftest.$ac_ext <<_ACEOF
9687 /* confdefs.h.  */
9688 _ACEOF
9689 cat confdefs.h >>conftest.$ac_ext
9690 cat >>conftest.$ac_ext <<_ACEOF
9691 /* end confdefs.h.  */
9692
9693 /* Override any gcc2 internal prototype to avoid an error.  */
9694 #ifdef __cplusplus
9695 extern "C"
9696 #endif
9697 /* We use char because int might match the return type of a gcc2
9698    builtin and then its argument prototype would still apply.  */
9699 char zlibVersion ();
9700 int
9701 main ()
9702 {
9703 zlibVersion ();
9704   ;
9705   return 0;
9706 }
9707 _ACEOF
9708 rm -f conftest.$ac_objext conftest$ac_exeext
9709 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9710   (eval $ac_link) 2>conftest.er1
9711   ac_status=$?
9712   grep -v '^ *+' conftest.er1 >conftest.err
9713   rm -f conftest.er1
9714   cat conftest.err >&5
9715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9716   (exit $ac_status); } &&
9717          { ac_try='test -z "$ac_c_werror_flag"
9718                          || test ! -s conftest.err'
9719   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9720   (eval $ac_try) 2>&5
9721   ac_status=$?
9722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9723   (exit $ac_status); }; } &&
9724          { ac_try='test -s conftest$ac_exeext'
9725   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9726   (eval $ac_try) 2>&5
9727   ac_status=$?
9728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9729   (exit $ac_status); }; }; then
9730   ac_cv_search_zlibVersion="-l$ac_lib"
9731 break
9732 else
9733   echo "$as_me: failed program was:" >&5
9734 sed 's/^/| /' conftest.$ac_ext >&5
9735
9736 fi
9737 rm -f conftest.err conftest.$ac_objext \
9738       conftest$ac_exeext conftest.$ac_ext
9739   done
9740 fi
9741 LIBS=$ac_func_search_save_LIBS
9742 fi
9743 echo "$as_me:$LINENO: result: $ac_cv_search_zlibVersion" >&5
9744 echo "${ECHO_T}$ac_cv_search_zlibVersion" >&6
9745 if test "$ac_cv_search_zlibVersion" != no; then
9746   test "$ac_cv_search_zlibVersion" = "none required" || LIBS="$ac_cv_search_zlibVersion $LIBS"
9747
9748 for ac_header in zlib.h
9749 do
9750 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9751 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9752   echo "$as_me:$LINENO: checking for $ac_header" >&5
9753 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9754 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9755   echo $ECHO_N "(cached) $ECHO_C" >&6
9756 fi
9757 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9758 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9759 else
9760   # Is the header compilable?
9761 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9762 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9763 cat >conftest.$ac_ext <<_ACEOF
9764 /* confdefs.h.  */
9765 _ACEOF
9766 cat confdefs.h >>conftest.$ac_ext
9767 cat >>conftest.$ac_ext <<_ACEOF
9768 /* end confdefs.h.  */
9769 $ac_includes_default
9770 #include <$ac_header>
9771 _ACEOF
9772 rm -f conftest.$ac_objext
9773 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9774   (eval $ac_compile) 2>conftest.er1
9775   ac_status=$?
9776   grep -v '^ *+' conftest.er1 >conftest.err
9777   rm -f conftest.er1
9778   cat conftest.err >&5
9779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9780   (exit $ac_status); } &&
9781          { ac_try='test -z "$ac_c_werror_flag"
9782                          || test ! -s conftest.err'
9783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9784   (eval $ac_try) 2>&5
9785   ac_status=$?
9786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9787   (exit $ac_status); }; } &&
9788          { ac_try='test -s conftest.$ac_objext'
9789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9790   (eval $ac_try) 2>&5
9791   ac_status=$?
9792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9793   (exit $ac_status); }; }; then
9794   ac_header_compiler=yes
9795 else
9796   echo "$as_me: failed program was:" >&5
9797 sed 's/^/| /' conftest.$ac_ext >&5
9798
9799 ac_header_compiler=no
9800 fi
9801 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9802 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9803 echo "${ECHO_T}$ac_header_compiler" >&6
9804
9805 # Is the header present?
9806 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9807 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9808 cat >conftest.$ac_ext <<_ACEOF
9809 /* confdefs.h.  */
9810 _ACEOF
9811 cat confdefs.h >>conftest.$ac_ext
9812 cat >>conftest.$ac_ext <<_ACEOF
9813 /* end confdefs.h.  */
9814 #include <$ac_header>
9815 _ACEOF
9816 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9817   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9818   ac_status=$?
9819   grep -v '^ *+' conftest.er1 >conftest.err
9820   rm -f conftest.er1
9821   cat conftest.err >&5
9822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9823   (exit $ac_status); } >/dev/null; then
9824   if test -s conftest.err; then
9825     ac_cpp_err=$ac_c_preproc_warn_flag
9826     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9827   else
9828     ac_cpp_err=
9829   fi
9830 else
9831   ac_cpp_err=yes
9832 fi
9833 if test -z "$ac_cpp_err"; then
9834   ac_header_preproc=yes
9835 else
9836   echo "$as_me: failed program was:" >&5
9837 sed 's/^/| /' conftest.$ac_ext >&5
9838
9839   ac_header_preproc=no
9840 fi
9841 rm -f conftest.err conftest.$ac_ext
9842 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9843 echo "${ECHO_T}$ac_header_preproc" >&6
9844
9845 # So?  What about this header?
9846 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9847   yes:no: )
9848     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9849 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9850     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9851 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9852     ac_header_preproc=yes
9853     ;;
9854   no:yes:* )
9855     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9856 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9857     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9858 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9859     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9860 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9861     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9862 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9863     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9864 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9865     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9866 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9867     (
9868       cat <<\_ASBOX
9869 ## ------------------------------------------ ##
9870 ## Report this to the AC_PACKAGE_NAME lists.  ##
9871 ## ------------------------------------------ ##
9872 _ASBOX
9873     ) |
9874       sed "s/^/$as_me: WARNING:     /" >&2
9875     ;;
9876 esac
9877 echo "$as_me:$LINENO: checking for $ac_header" >&5
9878 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9879 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9880   echo $ECHO_N "(cached) $ECHO_C" >&6
9881 else
9882   eval "$as_ac_Header=\$ac_header_preproc"
9883 fi
9884 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9885 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9886
9887 fi
9888 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9889   cat >>confdefs.h <<_ACEOF
9890 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9891 _ACEOF
9892
9893 fi
9894
9895 done
9896
9897 fi
9898
9899
9900 # On HP/UX we may need libxpdl for dlgetmodinfo (used by solib-pa64.c).
9901 echo "$as_me:$LINENO: checking for library containing dlgetmodinfo" >&5
9902 echo $ECHO_N "checking for library containing dlgetmodinfo... $ECHO_C" >&6
9903 if test "${ac_cv_search_dlgetmodinfo+set}" = set; then
9904   echo $ECHO_N "(cached) $ECHO_C" >&6
9905 else
9906   ac_func_search_save_LIBS=$LIBS
9907 ac_cv_search_dlgetmodinfo=no
9908 cat >conftest.$ac_ext <<_ACEOF
9909 /* confdefs.h.  */
9910 _ACEOF
9911 cat confdefs.h >>conftest.$ac_ext
9912 cat >>conftest.$ac_ext <<_ACEOF
9913 /* end confdefs.h.  */
9914
9915 /* Override any gcc2 internal prototype to avoid an error.  */
9916 #ifdef __cplusplus
9917 extern "C"
9918 #endif
9919 /* We use char because int might match the return type of a gcc2
9920    builtin and then its argument prototype would still apply.  */
9921 char dlgetmodinfo ();
9922 int
9923 main ()
9924 {
9925 dlgetmodinfo ();
9926   ;
9927   return 0;
9928 }
9929 _ACEOF
9930 rm -f conftest.$ac_objext conftest$ac_exeext
9931 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9932   (eval $ac_link) 2>conftest.er1
9933   ac_status=$?
9934   grep -v '^ *+' conftest.er1 >conftest.err
9935   rm -f conftest.er1
9936   cat conftest.err >&5
9937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9938   (exit $ac_status); } &&
9939          { ac_try='test -z "$ac_c_werror_flag"
9940                          || test ! -s conftest.err'
9941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9942   (eval $ac_try) 2>&5
9943   ac_status=$?
9944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9945   (exit $ac_status); }; } &&
9946          { ac_try='test -s conftest$ac_exeext'
9947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9948   (eval $ac_try) 2>&5
9949   ac_status=$?
9950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9951   (exit $ac_status); }; }; then
9952   ac_cv_search_dlgetmodinfo="none required"
9953 else
9954   echo "$as_me: failed program was:" >&5
9955 sed 's/^/| /' conftest.$ac_ext >&5
9956
9957 fi
9958 rm -f conftest.err conftest.$ac_objext \
9959       conftest$ac_exeext conftest.$ac_ext
9960 if test "$ac_cv_search_dlgetmodinfo" = no; then
9961   for ac_lib in dl xpdl; do
9962     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9963     cat >conftest.$ac_ext <<_ACEOF
9964 /* confdefs.h.  */
9965 _ACEOF
9966 cat confdefs.h >>conftest.$ac_ext
9967 cat >>conftest.$ac_ext <<_ACEOF
9968 /* end confdefs.h.  */
9969
9970 /* Override any gcc2 internal prototype to avoid an error.  */
9971 #ifdef __cplusplus
9972 extern "C"
9973 #endif
9974 /* We use char because int might match the return type of a gcc2
9975    builtin and then its argument prototype would still apply.  */
9976 char dlgetmodinfo ();
9977 int
9978 main ()
9979 {
9980 dlgetmodinfo ();
9981   ;
9982   return 0;
9983 }
9984 _ACEOF
9985 rm -f conftest.$ac_objext conftest$ac_exeext
9986 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9987   (eval $ac_link) 2>conftest.er1
9988   ac_status=$?
9989   grep -v '^ *+' conftest.er1 >conftest.err
9990   rm -f conftest.er1
9991   cat conftest.err >&5
9992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9993   (exit $ac_status); } &&
9994          { ac_try='test -z "$ac_c_werror_flag"
9995                          || test ! -s conftest.err'
9996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9997   (eval $ac_try) 2>&5
9998   ac_status=$?
9999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10000   (exit $ac_status); }; } &&
10001          { ac_try='test -s conftest$ac_exeext'
10002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10003   (eval $ac_try) 2>&5
10004   ac_status=$?
10005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10006   (exit $ac_status); }; }; then
10007   ac_cv_search_dlgetmodinfo="-l$ac_lib"
10008 break
10009 else
10010   echo "$as_me: failed program was:" >&5
10011 sed 's/^/| /' conftest.$ac_ext >&5
10012
10013 fi
10014 rm -f conftest.err conftest.$ac_objext \
10015       conftest$ac_exeext conftest.$ac_ext
10016   done
10017 fi
10018 LIBS=$ac_func_search_save_LIBS
10019 fi
10020 echo "$as_me:$LINENO: result: $ac_cv_search_dlgetmodinfo" >&5
10021 echo "${ECHO_T}$ac_cv_search_dlgetmodinfo" >&6
10022 if test "$ac_cv_search_dlgetmodinfo" != no; then
10023   test "$ac_cv_search_dlgetmodinfo" = "none required" || LIBS="$ac_cv_search_dlgetmodinfo $LIBS"
10024
10025 fi
10026
10027
10028
10029
10030
10031 # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
10032 if test "${with_libiconv_prefix+set}" = set; then
10033   withval="$with_libiconv_prefix"
10034
10035     for dir in `echo "$withval" | tr : ' '`; do
10036       if test -d $dir/include; then LIBICONV_INCLUDE="-I$dir/include"; fi
10037       if test -d $dir/lib; then LIBICONV_LIBDIR="-L$dir/lib"; fi
10038     done
10039
10040 fi;
10041
10042   BUILD_LIBICONV_LIBDIR="-L../libiconv/lib/.libs -L../libiconv/lib/_libs"
10043   BUILD_LIBICONV_INCLUDE="-I../libiconv/include"
10044
10045   echo "$as_me:$LINENO: checking for iconv" >&5
10046 echo $ECHO_N "checking for iconv... $ECHO_C" >&6
10047 if test "${am_cv_func_iconv+set}" = set; then
10048   echo $ECHO_N "(cached) $ECHO_C" >&6
10049 else
10050
10051     am_cv_func_iconv="no, consider installing GNU libiconv"
10052     am_cv_lib_iconv=no
10053     am_cv_use_build_libiconv=no
10054     # First, try to find iconv in libc.
10055     cat >conftest.$ac_ext <<_ACEOF
10056 /* confdefs.h.  */
10057 _ACEOF
10058 cat confdefs.h >>conftest.$ac_ext
10059 cat >>conftest.$ac_ext <<_ACEOF
10060 /* end confdefs.h.  */
10061 #include <stdlib.h>
10062 #include <iconv.h>
10063 int
10064 main ()
10065 {
10066 iconv_t cd = iconv_open("","");
10067        iconv(cd,NULL,NULL,NULL,NULL);
10068        iconv_close(cd);
10069   ;
10070   return 0;
10071 }
10072 _ACEOF
10073 rm -f conftest.$ac_objext conftest$ac_exeext
10074 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10075   (eval $ac_link) 2>conftest.er1
10076   ac_status=$?
10077   grep -v '^ *+' conftest.er1 >conftest.err
10078   rm -f conftest.er1
10079   cat conftest.err >&5
10080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10081   (exit $ac_status); } &&
10082          { ac_try='test -z "$ac_c_werror_flag"
10083                          || test ! -s conftest.err'
10084   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10085   (eval $ac_try) 2>&5
10086   ac_status=$?
10087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10088   (exit $ac_status); }; } &&
10089          { ac_try='test -s conftest$ac_exeext'
10090   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10091   (eval $ac_try) 2>&5
10092   ac_status=$?
10093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10094   (exit $ac_status); }; }; then
10095   am_cv_func_iconv=yes
10096 else
10097   echo "$as_me: failed program was:" >&5
10098 sed 's/^/| /' conftest.$ac_ext >&5
10099
10100 fi
10101 rm -f conftest.err conftest.$ac_objext \
10102       conftest$ac_exeext conftest.$ac_ext
10103
10104     # If iconv was not in libc, try -liconv.  In this case, arrange to
10105     # look in the libiconv prefix, if it was specified by the user.
10106     if test "$am_cv_func_iconv" != yes; then
10107       am_save_CPPFLAGS="$CPPFLAGS"
10108       am_save_LIBS="$LIBS"
10109       if test -n "$LIBICONV_INCLUDE"; then
10110         CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
10111         LIBS="$LIBS $LIBICONV_LIBDIR"
10112       fi
10113       LIBS="$LIBS -liconv"
10114       cat >conftest.$ac_ext <<_ACEOF
10115 /* confdefs.h.  */
10116 _ACEOF
10117 cat confdefs.h >>conftest.$ac_ext
10118 cat >>conftest.$ac_ext <<_ACEOF
10119 /* end confdefs.h.  */
10120 #include <stdlib.h>
10121 #include <iconv.h>
10122 int
10123 main ()
10124 {
10125 iconv_t cd = iconv_open("","");
10126          iconv(cd,NULL,NULL,NULL,NULL);
10127          iconv_close(cd);
10128   ;
10129   return 0;
10130 }
10131 _ACEOF
10132 rm -f conftest.$ac_objext conftest$ac_exeext
10133 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10134   (eval $ac_link) 2>conftest.er1
10135   ac_status=$?
10136   grep -v '^ *+' conftest.er1 >conftest.err
10137   rm -f conftest.er1
10138   cat conftest.err >&5
10139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10140   (exit $ac_status); } &&
10141          { ac_try='test -z "$ac_c_werror_flag"
10142                          || test ! -s conftest.err'
10143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10144   (eval $ac_try) 2>&5
10145   ac_status=$?
10146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10147   (exit $ac_status); }; } &&
10148          { ac_try='test -s conftest$ac_exeext'
10149   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10150   (eval $ac_try) 2>&5
10151   ac_status=$?
10152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10153   (exit $ac_status); }; }; then
10154   am_cv_lib_iconv=yes
10155         am_cv_func_iconv=yes
10156 else
10157   echo "$as_me: failed program was:" >&5
10158 sed 's/^/| /' conftest.$ac_ext >&5
10159
10160 fi
10161 rm -f conftest.err conftest.$ac_objext \
10162       conftest$ac_exeext conftest.$ac_ext
10163       LIBS="$am_save_LIBS"
10164       CPPFLAGS="$am_save_CPPFLAGS"
10165     fi
10166
10167     # If that didn't work, try to find libiconv in the build tree.
10168     if test "$am_cv_func_iconv" != yes && test -d ../libiconv; then
10169       am_save_LIBS="$LIBS"
10170       am_save_CPPFLAGS="$CPPFLAGS"
10171       LIBS="$LIBS $BUILD_LIBICONV_LIBDIR -liconv"
10172       CPPFLAGS="$CPPFLAGS $BUILD_LIBICONV_INCLUDE"
10173       cat >conftest.$ac_ext <<_ACEOF
10174 /* confdefs.h.  */
10175 _ACEOF
10176 cat confdefs.h >>conftest.$ac_ext
10177 cat >>conftest.$ac_ext <<_ACEOF
10178 /* end confdefs.h.  */
10179 #include <stdlib.h>
10180 #include <iconv.h>
10181 int
10182 main ()
10183 {
10184 iconv_t cd = iconv_open("","");
10185          iconv(cd,NULL,NULL,NULL,NULL);
10186          iconv_close(cd);
10187   ;
10188   return 0;
10189 }
10190 _ACEOF
10191 rm -f conftest.$ac_objext conftest$ac_exeext
10192 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10193   (eval $ac_link) 2>conftest.er1
10194   ac_status=$?
10195   grep -v '^ *+' conftest.er1 >conftest.err
10196   rm -f conftest.er1
10197   cat conftest.err >&5
10198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10199   (exit $ac_status); } &&
10200          { ac_try='test -z "$ac_c_werror_flag"
10201                          || test ! -s conftest.err'
10202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10203   (eval $ac_try) 2>&5
10204   ac_status=$?
10205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10206   (exit $ac_status); }; } &&
10207          { ac_try='test -s conftest$ac_exeext'
10208   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10209   (eval $ac_try) 2>&5
10210   ac_status=$?
10211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10212   (exit $ac_status); }; }; then
10213   am_cv_use_build_libiconv=yes
10214         am_cv_lib_iconv=yes
10215         am_cv_func_iconv=yes
10216 else
10217   echo "$as_me: failed program was:" >&5
10218 sed 's/^/| /' conftest.$ac_ext >&5
10219
10220 fi
10221 rm -f conftest.err conftest.$ac_objext \
10222       conftest$ac_exeext conftest.$ac_ext
10223       LIBS="$am_save_LIBS"
10224       CPPFLAGS="$am_save_CPPFLAGS"
10225     fi
10226
10227 fi
10228 echo "$as_me:$LINENO: result: $am_cv_func_iconv" >&5
10229 echo "${ECHO_T}$am_cv_func_iconv" >&6
10230
10231   # Set the various flags based on the cache variables.  We can't rely
10232   # on the flags to remain set from the above code, due to caching.
10233   LIBICONV=
10234   if test "$am_cv_lib_iconv" = yes; then
10235     LIBICONV="-liconv"
10236   else
10237     LIBICONV_LIBDIR=
10238     LIBICONV_INCLUDE=
10239   fi
10240   if test "$am_cv_use_build_libiconv" = yes; then
10241     LIBICONV_LIBDIR="$BUILD_LIBICONV_LIBDIR"
10242     LIBICONV_INCLUDE="$BUILD_LIBICONV_INCLUDE"
10243   fi
10244   CPPFLAGS="$CPPFLAGS $LIBICONV_INCLUDE"
10245   LIBS="$LIBS $LIBICONV_LIBDIR $LIBICONV"
10246
10247   if test "$am_cv_func_iconv" = yes; then
10248
10249 cat >>confdefs.h <<\_ACEOF
10250 #define HAVE_ICONV 1
10251 _ACEOF
10252
10253     echo "$as_me:$LINENO: checking for iconv declaration" >&5
10254 echo $ECHO_N "checking for iconv declaration... $ECHO_C" >&6
10255     if test "${am_cv_proto_iconv+set}" = set; then
10256   echo $ECHO_N "(cached) $ECHO_C" >&6
10257 else
10258
10259       cat >conftest.$ac_ext <<_ACEOF
10260 /* confdefs.h.  */
10261 _ACEOF
10262 cat confdefs.h >>conftest.$ac_ext
10263 cat >>conftest.$ac_ext <<_ACEOF
10264 /* end confdefs.h.  */
10265
10266 #include <stdlib.h>
10267 #include <iconv.h>
10268 extern
10269 #ifdef __cplusplus
10270 "C"
10271 #endif
10272 #if defined(__STDC__) || defined(__cplusplus)
10273 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
10274 #else
10275 size_t iconv();
10276 #endif
10277
10278 int
10279 main ()
10280 {
10281
10282   ;
10283   return 0;
10284 }
10285 _ACEOF
10286 rm -f conftest.$ac_objext
10287 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10288   (eval $ac_compile) 2>conftest.er1
10289   ac_status=$?
10290   grep -v '^ *+' conftest.er1 >conftest.err
10291   rm -f conftest.er1
10292   cat conftest.err >&5
10293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10294   (exit $ac_status); } &&
10295          { ac_try='test -z "$ac_c_werror_flag"
10296                          || test ! -s conftest.err'
10297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10298   (eval $ac_try) 2>&5
10299   ac_status=$?
10300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10301   (exit $ac_status); }; } &&
10302          { ac_try='test -s conftest.$ac_objext'
10303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10304   (eval $ac_try) 2>&5
10305   ac_status=$?
10306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10307   (exit $ac_status); }; }; then
10308   am_cv_proto_iconv_arg1=""
10309 else
10310   echo "$as_me: failed program was:" >&5
10311 sed 's/^/| /' conftest.$ac_ext >&5
10312
10313 am_cv_proto_iconv_arg1="const"
10314 fi
10315 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10316       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);"
10317 fi
10318
10319     am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
10320     echo "$as_me:$LINENO: result: ${ac_t:-
10321          }$am_cv_proto_iconv" >&5
10322 echo "${ECHO_T}${ac_t:-
10323          }$am_cv_proto_iconv" >&6
10324
10325 cat >>confdefs.h <<_ACEOF
10326 #define ICONV_CONST $am_cv_proto_iconv_arg1
10327 _ACEOF
10328
10329   fi
10330
10331
10332 # On alpha-osf, it appears that libtermcap and libcurses are not compatible.
10333 # There is a very specific comment in /usr/include/curses.h explaining that
10334 # termcap routines built into libcurses must not be used.
10335 #
10336 # The symptoms we observed so far is GDB unexpectedly changing
10337 # the terminal settings when tgetent is called - this is particularly
10338 # visible as the output is missing carriage returns, and so rapidly
10339 # becomes very hard to read.
10340 #
10341 # The readline configure script has already decided that libtermcap
10342 # was enough for its purposes, and so decided to build readline using
10343 # libtermcap.  Since the TUI mode requires curses, building GDB with
10344 # TUI enabled results in both libraries to be used at the same time,
10345 # which is not allowed.  This basically means that GDB with TUI is
10346 # broken on alpha-osf.
10347
10348 case $host_os in
10349   alpha*-*-osf* )
10350     if "$enable_tui" = "yes"; then
10351       { { echo "$as_me:$LINENO: error: Building GDB with TUI mode is not supported on this host" >&5
10352 echo "$as_me: error: Building GDB with TUI mode is not supported on this host" >&2;}
10353    { (exit 1); exit 1; }; }
10354     fi
10355     if "$enable_tui" = "auto"; then
10356       enable_tui=no
10357     fi
10358     ;;
10359 esac
10360
10361 # For the TUI, we need enhanced curses functionality.
10362 if test x"$enable_tui" != xno; then
10363   prefer_curses=yes
10364 fi
10365
10366 curses_found=no
10367 if test x"$prefer_curses" = xyes; then
10368   # FIXME: kettenis/20040905: We prefer ncurses over the vendor-supplied
10369   # curses library because the latter might not provide all the
10370   # functionality we need.  However, this leads to problems on systems
10371   # where the linker searches /usr/local/lib, but the compiler doesn't
10372   # search /usr/local/include, if ncurses is installed in /usr/local.  A
10373   # default installation of ncurses on alpha*-dec-osf* will lead to such
10374   # a situation.
10375   echo "$as_me:$LINENO: checking for library containing waddstr" >&5
10376 echo $ECHO_N "checking for library containing waddstr... $ECHO_C" >&6
10377 if test "${ac_cv_search_waddstr+set}" = set; then
10378   echo $ECHO_N "(cached) $ECHO_C" >&6
10379 else
10380   ac_func_search_save_LIBS=$LIBS
10381 ac_cv_search_waddstr=no
10382 cat >conftest.$ac_ext <<_ACEOF
10383 /* confdefs.h.  */
10384 _ACEOF
10385 cat confdefs.h >>conftest.$ac_ext
10386 cat >>conftest.$ac_ext <<_ACEOF
10387 /* end confdefs.h.  */
10388
10389 /* Override any gcc2 internal prototype to avoid an error.  */
10390 #ifdef __cplusplus
10391 extern "C"
10392 #endif
10393 /* We use char because int might match the return type of a gcc2
10394    builtin and then its argument prototype would still apply.  */
10395 char waddstr ();
10396 int
10397 main ()
10398 {
10399 waddstr ();
10400   ;
10401   return 0;
10402 }
10403 _ACEOF
10404 rm -f conftest.$ac_objext conftest$ac_exeext
10405 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10406   (eval $ac_link) 2>conftest.er1
10407   ac_status=$?
10408   grep -v '^ *+' conftest.er1 >conftest.err
10409   rm -f conftest.er1
10410   cat conftest.err >&5
10411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10412   (exit $ac_status); } &&
10413          { ac_try='test -z "$ac_c_werror_flag"
10414                          || test ! -s conftest.err'
10415   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10416   (eval $ac_try) 2>&5
10417   ac_status=$?
10418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10419   (exit $ac_status); }; } &&
10420          { ac_try='test -s conftest$ac_exeext'
10421   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10422   (eval $ac_try) 2>&5
10423   ac_status=$?
10424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10425   (exit $ac_status); }; }; then
10426   ac_cv_search_waddstr="none required"
10427 else
10428   echo "$as_me: failed program was:" >&5
10429 sed 's/^/| /' conftest.$ac_ext >&5
10430
10431 fi
10432 rm -f conftest.err conftest.$ac_objext \
10433       conftest$ac_exeext conftest.$ac_ext
10434 if test "$ac_cv_search_waddstr" = no; then
10435   for ac_lib in ncurses cursesX curses; do
10436     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
10437     cat >conftest.$ac_ext <<_ACEOF
10438 /* confdefs.h.  */
10439 _ACEOF
10440 cat confdefs.h >>conftest.$ac_ext
10441 cat >>conftest.$ac_ext <<_ACEOF
10442 /* end confdefs.h.  */
10443
10444 /* Override any gcc2 internal prototype to avoid an error.  */
10445 #ifdef __cplusplus
10446 extern "C"
10447 #endif
10448 /* We use char because int might match the return type of a gcc2
10449    builtin and then its argument prototype would still apply.  */
10450 char waddstr ();
10451 int
10452 main ()
10453 {
10454 waddstr ();
10455   ;
10456   return 0;
10457 }
10458 _ACEOF
10459 rm -f conftest.$ac_objext conftest$ac_exeext
10460 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10461   (eval $ac_link) 2>conftest.er1
10462   ac_status=$?
10463   grep -v '^ *+' conftest.er1 >conftest.err
10464   rm -f conftest.er1
10465   cat conftest.err >&5
10466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10467   (exit $ac_status); } &&
10468          { ac_try='test -z "$ac_c_werror_flag"
10469                          || test ! -s conftest.err'
10470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10471   (eval $ac_try) 2>&5
10472   ac_status=$?
10473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10474   (exit $ac_status); }; } &&
10475          { ac_try='test -s conftest$ac_exeext'
10476   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10477   (eval $ac_try) 2>&5
10478   ac_status=$?
10479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10480   (exit $ac_status); }; }; then
10481   ac_cv_search_waddstr="-l$ac_lib"
10482 break
10483 else
10484   echo "$as_me: failed program was:" >&5
10485 sed 's/^/| /' conftest.$ac_ext >&5
10486
10487 fi
10488 rm -f conftest.err conftest.$ac_objext \
10489       conftest$ac_exeext conftest.$ac_ext
10490   done
10491 fi
10492 LIBS=$ac_func_search_save_LIBS
10493 fi
10494 echo "$as_me:$LINENO: result: $ac_cv_search_waddstr" >&5
10495 echo "${ECHO_T}$ac_cv_search_waddstr" >&6
10496 if test "$ac_cv_search_waddstr" != no; then
10497   test "$ac_cv_search_waddstr" = "none required" || LIBS="$ac_cv_search_waddstr $LIBS"
10498
10499 fi
10500
10501
10502   if test "$ac_cv_search_waddstr" != no; then
10503     curses_found=yes
10504   fi
10505 fi
10506
10507 # Check whether we should enable the TUI, but only do so if we really
10508 # can.
10509 if test x"$enable_tui" != xno; then
10510   if test -d $srcdir/tui; then
10511     if test "$curses_found" != no; then
10512       CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
10513       CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
10514       CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
10515       ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
10516       CONFIG_ALL="${CONFIG_ALL} all-tui"
10517       CONFIG_CLEAN="${CONFIG_CLEAN} clean-tui"
10518       CONFIG_INSTALL="${CONFIG_INSTALL} install-tui"
10519       CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-tui"
10520     else
10521       if test x"$enable_tui" = xyes; then
10522         { { echo "$as_me:$LINENO: error: no enhanced curses library found; disable TUI" >&5
10523 echo "$as_me: error: no enhanced curses library found; disable TUI" >&2;}
10524    { (exit 1); exit 1; }; }
10525       else
10526         { echo "$as_me:$LINENO: WARNING: no enhanced curses library found; disabling TUI" >&5
10527 echo "$as_me: WARNING: no enhanced curses library found; disabling TUI" >&2;}
10528       fi
10529     fi
10530   fi
10531 fi
10532
10533 # Since GDB uses Readline, we need termcap functionality.  In many
10534 # cases this will be provided by the curses library, but some systems
10535 # have a seperate termcap library, or no curses library at all.
10536
10537 case $host_os in
10538   cygwin*)
10539     if test -d $srcdir/libtermcap; then
10540       LIBS="../libtermcap/libtermcap.a $LIBS"
10541       ac_cv_search_tgetent="../libtermcap/libtermcap.a"
10542     fi ;;
10543   go32* | *djgpp*)
10544     ac_cv_search_tgetent="none required"
10545     ;;
10546   *mingw32*)
10547     ac_cv_search_tgetent="none required"
10548     CONFIG_OBS="$CONFIG_OBS windows-termcap.o"
10549     ;;
10550 esac
10551
10552 # These are the libraries checked by Readline.
10553 echo "$as_me:$LINENO: checking for library containing tgetent" >&5
10554 echo $ECHO_N "checking for library containing tgetent... $ECHO_C" >&6
10555 if test "${ac_cv_search_tgetent+set}" = set; then
10556   echo $ECHO_N "(cached) $ECHO_C" >&6
10557 else
10558   ac_func_search_save_LIBS=$LIBS
10559 ac_cv_search_tgetent=no
10560 cat >conftest.$ac_ext <<_ACEOF
10561 /* confdefs.h.  */
10562 _ACEOF
10563 cat confdefs.h >>conftest.$ac_ext
10564 cat >>conftest.$ac_ext <<_ACEOF
10565 /* end confdefs.h.  */
10566
10567 /* Override any gcc2 internal prototype to avoid an error.  */
10568 #ifdef __cplusplus
10569 extern "C"
10570 #endif
10571 /* We use char because int might match the return type of a gcc2
10572    builtin and then its argument prototype would still apply.  */
10573 char tgetent ();
10574 int
10575 main ()
10576 {
10577 tgetent ();
10578   ;
10579   return 0;
10580 }
10581 _ACEOF
10582 rm -f conftest.$ac_objext conftest$ac_exeext
10583 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10584   (eval $ac_link) 2>conftest.er1
10585   ac_status=$?
10586   grep -v '^ *+' conftest.er1 >conftest.err
10587   rm -f conftest.er1
10588   cat conftest.err >&5
10589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10590   (exit $ac_status); } &&
10591          { ac_try='test -z "$ac_c_werror_flag"
10592                          || test ! -s conftest.err'
10593   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10594   (eval $ac_try) 2>&5
10595   ac_status=$?
10596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10597   (exit $ac_status); }; } &&
10598          { ac_try='test -s conftest$ac_exeext'
10599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10600   (eval $ac_try) 2>&5
10601   ac_status=$?
10602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10603   (exit $ac_status); }; }; then
10604   ac_cv_search_tgetent="none required"
10605 else
10606   echo "$as_me: failed program was:" >&5
10607 sed 's/^/| /' conftest.$ac_ext >&5
10608
10609 fi
10610 rm -f conftest.err conftest.$ac_objext \
10611       conftest$ac_exeext conftest.$ac_ext
10612 if test "$ac_cv_search_tgetent" = no; then
10613   for ac_lib in termcap tinfo curses ncurses; do
10614     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
10615     cat >conftest.$ac_ext <<_ACEOF
10616 /* confdefs.h.  */
10617 _ACEOF
10618 cat confdefs.h >>conftest.$ac_ext
10619 cat >>conftest.$ac_ext <<_ACEOF
10620 /* end confdefs.h.  */
10621
10622 /* Override any gcc2 internal prototype to avoid an error.  */
10623 #ifdef __cplusplus
10624 extern "C"
10625 #endif
10626 /* We use char because int might match the return type of a gcc2
10627    builtin and then its argument prototype would still apply.  */
10628 char tgetent ();
10629 int
10630 main ()
10631 {
10632 tgetent ();
10633   ;
10634   return 0;
10635 }
10636 _ACEOF
10637 rm -f conftest.$ac_objext conftest$ac_exeext
10638 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10639   (eval $ac_link) 2>conftest.er1
10640   ac_status=$?
10641   grep -v '^ *+' conftest.er1 >conftest.err
10642   rm -f conftest.er1
10643   cat conftest.err >&5
10644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10645   (exit $ac_status); } &&
10646          { ac_try='test -z "$ac_c_werror_flag"
10647                          || test ! -s conftest.err'
10648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10649   (eval $ac_try) 2>&5
10650   ac_status=$?
10651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10652   (exit $ac_status); }; } &&
10653          { ac_try='test -s conftest$ac_exeext'
10654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10655   (eval $ac_try) 2>&5
10656   ac_status=$?
10657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10658   (exit $ac_status); }; }; then
10659   ac_cv_search_tgetent="-l$ac_lib"
10660 break
10661 else
10662   echo "$as_me: failed program was:" >&5
10663 sed 's/^/| /' conftest.$ac_ext >&5
10664
10665 fi
10666 rm -f conftest.err conftest.$ac_objext \
10667       conftest$ac_exeext conftest.$ac_ext
10668   done
10669 fi
10670 LIBS=$ac_func_search_save_LIBS
10671 fi
10672 echo "$as_me:$LINENO: result: $ac_cv_search_tgetent" >&5
10673 echo "${ECHO_T}$ac_cv_search_tgetent" >&6
10674 if test "$ac_cv_search_tgetent" != no; then
10675   test "$ac_cv_search_tgetent" = "none required" || LIBS="$ac_cv_search_tgetent $LIBS"
10676
10677 fi
10678
10679
10680 if test "$ac_cv_search_tgetent" = no; then
10681   { { echo "$as_me:$LINENO: error: no termcap library found" >&5
10682 echo "$as_me: error: no termcap library found" >&2;}
10683    { (exit 1); exit 1; }; }
10684 fi
10685
10686
10687 # Check whether --with-system-readline or --without-system-readline was given.
10688 if test "${with_system_readline+set}" = set; then
10689   withval="$with_system_readline"
10690
10691 fi;
10692
10693 if test "$with_system_readline" = yes; then
10694   READLINE=-lreadline
10695   READLINE_DEPS=
10696   READLINE_CFLAGS=
10697 else
10698   READLINE='$(READLINE_DIR)/libreadline.a'
10699   READLINE_DEPS='$(READLINE)'
10700   READLINE_CFLAGS='-I$(READLINE_SRC)/..'
10701 fi
10702
10703
10704
10705
10706
10707 # Check whether --with-expat or --without-expat was given.
10708 if test "${with_expat+set}" = set; then
10709   withval="$with_expat"
10710
10711 else
10712   with_expat=auto
10713 fi;
10714 echo "$as_me:$LINENO: checking whether to use expat" >&5
10715 echo $ECHO_N "checking whether to use expat... $ECHO_C" >&6
10716 echo "$as_me:$LINENO: result: $with_expat" >&5
10717 echo "${ECHO_T}$with_expat" >&6
10718
10719 if test "${with_expat}" = no; then
10720   { echo "$as_me:$LINENO: WARNING: expat support disabled; some features may be unavailable." >&5
10721 echo "$as_me: WARNING: expat support disabled; some features may be unavailable." >&2;}
10722   HAVE_LIBEXPAT=no
10723 else
10724
10725       if test "X$prefix" = "XNONE"; then
10726     acl_final_prefix="$ac_default_prefix"
10727   else
10728     acl_final_prefix="$prefix"
10729   fi
10730   if test "X$exec_prefix" = "XNONE"; then
10731     acl_final_exec_prefix='${prefix}'
10732   else
10733     acl_final_exec_prefix="$exec_prefix"
10734   fi
10735   acl_save_prefix="$prefix"
10736   prefix="$acl_final_prefix"
10737   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
10738   prefix="$acl_save_prefix"
10739
10740
10741 # Check whether --with-gnu-ld or --without-gnu-ld was given.
10742 if test "${with_gnu_ld+set}" = set; then
10743   withval="$with_gnu_ld"
10744   test "$withval" = no || with_gnu_ld=yes
10745 else
10746   with_gnu_ld=no
10747 fi;
10748 # Prepare PATH_SEPARATOR.
10749 # The user is always right.
10750 if test "${PATH_SEPARATOR+set}" != set; then
10751   echo "#! /bin/sh" >conf$$.sh
10752   echo  "exit 0"   >>conf$$.sh
10753   chmod +x conf$$.sh
10754   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
10755     PATH_SEPARATOR=';'
10756   else
10757     PATH_SEPARATOR=:
10758   fi
10759   rm -f conf$$.sh
10760 fi
10761 ac_prog=ld
10762 if test "$GCC" = yes; then
10763   # Check if gcc -print-prog-name=ld gives a path.
10764   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
10765 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
10766   case $host in
10767   *-*-mingw*)
10768     # gcc leaves a trailing carriage return which upsets mingw
10769     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
10770   *)
10771     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
10772   esac
10773   case $ac_prog in
10774     # Accept absolute paths.
10775     [\\/]* | [A-Za-z]:[\\/]*)
10776       re_direlt='/[^/][^/]*/\.\./'
10777       # Canonicalize the path of ld
10778       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
10779       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
10780         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
10781       done
10782       test -z "$LD" && LD="$ac_prog"
10783       ;;
10784   "")
10785     # If it fails, then pretend we aren't using GCC.
10786     ac_prog=ld
10787     ;;
10788   *)
10789     # If it is relative, then search for the first ld in PATH.
10790     with_gnu_ld=unknown
10791     ;;
10792   esac
10793 elif test "$with_gnu_ld" = yes; then
10794   echo "$as_me:$LINENO: checking for GNU ld" >&5
10795 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
10796 else
10797   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
10798 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
10799 fi
10800 if test "${acl_cv_path_LD+set}" = set; then
10801   echo $ECHO_N "(cached) $ECHO_C" >&6
10802 else
10803   if test -z "$LD"; then
10804   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
10805   for ac_dir in $PATH; do
10806     test -z "$ac_dir" && ac_dir=.
10807     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
10808       acl_cv_path_LD="$ac_dir/$ac_prog"
10809       # Check to see if the program is GNU ld.  I'd rather use --version,
10810       # but apparently some GNU ld's only accept -v.
10811       # Break only if it was the GNU/non-GNU ld that we prefer.
10812       if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
10813         test "$with_gnu_ld" != no && break
10814       else
10815         test "$with_gnu_ld" != yes && break
10816       fi
10817     fi
10818   done
10819   IFS="$ac_save_ifs"
10820 else
10821   acl_cv_path_LD="$LD" # Let the user override the test with a path.
10822 fi
10823 fi
10824
10825 LD="$acl_cv_path_LD"
10826 if test -n "$LD"; then
10827   echo "$as_me:$LINENO: result: $LD" >&5
10828 echo "${ECHO_T}$LD" >&6
10829 else
10830   echo "$as_me:$LINENO: result: no" >&5
10831 echo "${ECHO_T}no" >&6
10832 fi
10833 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
10834 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
10835    { (exit 1); exit 1; }; }
10836 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
10837 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
10838 if test "${acl_cv_prog_gnu_ld+set}" = set; then
10839   echo $ECHO_N "(cached) $ECHO_C" >&6
10840 else
10841   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
10842 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
10843   acl_cv_prog_gnu_ld=yes
10844 else
10845   acl_cv_prog_gnu_ld=no
10846 fi
10847 fi
10848 echo "$as_me:$LINENO: result: $acl_cv_prog_gnu_ld" >&5
10849 echo "${ECHO_T}$acl_cv_prog_gnu_ld" >&6
10850 with_gnu_ld=$acl_cv_prog_gnu_ld
10851
10852
10853
10854                                                 echo "$as_me:$LINENO: checking for shared library run path origin" >&5
10855 echo $ECHO_N "checking for shared library run path origin... $ECHO_C" >&6
10856 if test "${acl_cv_rpath+set}" = set; then
10857   echo $ECHO_N "(cached) $ECHO_C" >&6
10858 else
10859
10860     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
10861     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
10862     . ./conftest.sh
10863     rm -f ./conftest.sh
10864     acl_cv_rpath=done
10865
10866 fi
10867 echo "$as_me:$LINENO: result: $acl_cv_rpath" >&5
10868 echo "${ECHO_T}$acl_cv_rpath" >&6
10869   wl="$acl_cv_wl"
10870   libext="$acl_cv_libext"
10871   shlibext="$acl_cv_shlibext"
10872   hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
10873   hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
10874   hardcode_direct="$acl_cv_hardcode_direct"
10875   hardcode_minus_L="$acl_cv_hardcode_minus_L"
10876     # Check whether --enable-rpath or --disable-rpath was given.
10877 if test "${enable_rpath+set}" = set; then
10878   enableval="$enable_rpath"
10879   :
10880 else
10881   enable_rpath=yes
10882 fi;
10883
10884
10885
10886
10887
10888
10889
10890
10891
10892     use_additional=yes
10893
10894   acl_save_prefix="$prefix"
10895   prefix="$acl_final_prefix"
10896   acl_save_exec_prefix="$exec_prefix"
10897   exec_prefix="$acl_final_exec_prefix"
10898
10899     eval additional_includedir=\"$includedir\"
10900     eval additional_libdir=\"$libdir\"
10901
10902   exec_prefix="$acl_save_exec_prefix"
10903   prefix="$acl_save_prefix"
10904
10905
10906 # Check whether --with-libexpat-prefix or --without-libexpat-prefix was given.
10907 if test "${with_libexpat_prefix+set}" = set; then
10908   withval="$with_libexpat_prefix"
10909
10910     if test "X$withval" = "Xno"; then
10911       use_additional=no
10912     else
10913       if test "X$withval" = "X"; then
10914
10915   acl_save_prefix="$prefix"
10916   prefix="$acl_final_prefix"
10917   acl_save_exec_prefix="$exec_prefix"
10918   exec_prefix="$acl_final_exec_prefix"
10919
10920           eval additional_includedir=\"$includedir\"
10921           eval additional_libdir=\"$libdir\"
10922
10923   exec_prefix="$acl_save_exec_prefix"
10924   prefix="$acl_save_prefix"
10925
10926       else
10927         additional_includedir="$withval/include"
10928         additional_libdir="$withval/lib"
10929       fi
10930     fi
10931
10932 fi;
10933       LIBEXPAT=
10934   LTLIBEXPAT=
10935   INCEXPAT=
10936   rpathdirs=
10937   ltrpathdirs=
10938   names_already_handled=
10939   names_next_round='expat '
10940   while test -n "$names_next_round"; do
10941     names_this_round="$names_next_round"
10942     names_next_round=
10943     for name in $names_this_round; do
10944       already_handled=
10945       for n in $names_already_handled; do
10946         if test "$n" = "$name"; then
10947           already_handled=yes
10948           break
10949         fi
10950       done
10951       if test -z "$already_handled"; then
10952         names_already_handled="$names_already_handled $name"
10953                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
10954         eval value=\"\$HAVE_LIB$uppername\"
10955         if test -n "$value"; then
10956           if test "$value" = yes; then
10957             eval value=\"\$LIB$uppername\"
10958             test -z "$value" || LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$value"
10959             eval value=\"\$LTLIB$uppername\"
10960             test -z "$value" || LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$value"
10961           else
10962                                     :
10963           fi
10964         else
10965                               found_dir=
10966           found_la=
10967           found_so=
10968           found_a=
10969           if test $use_additional = yes; then
10970             if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then
10971               found_dir="$additional_libdir"
10972               found_so="$additional_libdir/lib$name.$shlibext"
10973               if test -f "$additional_libdir/lib$name.la"; then
10974                 found_la="$additional_libdir/lib$name.la"
10975               fi
10976             else
10977               if test -f "$additional_libdir/lib$name.$libext"; then
10978                 found_dir="$additional_libdir"
10979                 found_a="$additional_libdir/lib$name.$libext"
10980                 if test -f "$additional_libdir/lib$name.la"; then
10981                   found_la="$additional_libdir/lib$name.la"
10982                 fi
10983               fi
10984             fi
10985           fi
10986           if test "X$found_dir" = "X"; then
10987             for x in $LDFLAGS $LTLIBEXPAT; do
10988
10989   acl_save_prefix="$prefix"
10990   prefix="$acl_final_prefix"
10991   acl_save_exec_prefix="$exec_prefix"
10992   exec_prefix="$acl_final_exec_prefix"
10993   eval x=\"$x\"
10994   exec_prefix="$acl_save_exec_prefix"
10995   prefix="$acl_save_prefix"
10996
10997               case "$x" in
10998                 -L*)
10999                   dir=`echo "X$x" | sed -e 's/^X-L//'`
11000                   if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then
11001                     found_dir="$dir"
11002                     found_so="$dir/lib$name.$shlibext"
11003                     if test -f "$dir/lib$name.la"; then
11004                       found_la="$dir/lib$name.la"
11005                     fi
11006                   else
11007                     if test -f "$dir/lib$name.$libext"; then
11008                       found_dir="$dir"
11009                       found_a="$dir/lib$name.$libext"
11010                       if test -f "$dir/lib$name.la"; then
11011                         found_la="$dir/lib$name.la"
11012                       fi
11013                     fi
11014                   fi
11015                   ;;
11016               esac
11017               if test "X$found_dir" != "X"; then
11018                 break
11019               fi
11020             done
11021           fi
11022           if test "X$found_dir" != "X"; then
11023                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$found_dir -l$name"
11024             if test "X$found_so" != "X"; then
11025                                                         if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
11026                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
11027               else
11028                                                                                 haveit=
11029                 for x in $ltrpathdirs; do
11030                   if test "X$x" = "X$found_dir"; then
11031                     haveit=yes
11032                     break
11033                   fi
11034                 done
11035                 if test -z "$haveit"; then
11036                   ltrpathdirs="$ltrpathdirs $found_dir"
11037                 fi
11038                                 if test "$hardcode_direct" = yes; then
11039                                                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
11040                 else
11041                   if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
11042                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
11043                                                             haveit=
11044                     for x in $rpathdirs; do
11045                       if test "X$x" = "X$found_dir"; then
11046                         haveit=yes
11047                         break
11048                       fi
11049                     done
11050                     if test -z "$haveit"; then
11051                       rpathdirs="$rpathdirs $found_dir"
11052                     fi
11053                   else
11054                                                                                 haveit=
11055                     for x in $LDFLAGS $LIBEXPAT; do
11056
11057   acl_save_prefix="$prefix"
11058   prefix="$acl_final_prefix"
11059   acl_save_exec_prefix="$exec_prefix"
11060   exec_prefix="$acl_final_exec_prefix"
11061   eval x=\"$x\"
11062   exec_prefix="$acl_save_exec_prefix"
11063   prefix="$acl_save_prefix"
11064
11065                       if test "X$x" = "X-L$found_dir"; then
11066                         haveit=yes
11067                         break
11068                       fi
11069                     done
11070                     if test -z "$haveit"; then
11071                       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir"
11072                     fi
11073                     if test "$hardcode_minus_L" != no; then
11074                                                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_so"
11075                     else
11076                                                                                                                                                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
11077                     fi
11078                   fi
11079                 fi
11080               fi
11081             else
11082               if test "X$found_a" != "X"; then
11083                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$found_a"
11084               else
11085                                                 LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$found_dir -l$name"
11086               fi
11087             fi
11088                         additional_includedir=
11089             case "$found_dir" in
11090               */lib | */lib/)
11091                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
11092                 additional_includedir="$basedir/include"
11093                 ;;
11094             esac
11095             if test "X$additional_includedir" != "X"; then
11096                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
11097                 haveit=
11098                 if test "X$additional_includedir" = "X/usr/local/include"; then
11099                   if test -n "$GCC"; then
11100                     case $host_os in
11101                       linux*) haveit=yes;;
11102                     esac
11103                   fi
11104                 fi
11105                 if test -z "$haveit"; then
11106                   for x in $CPPFLAGS $INCEXPAT; do
11107
11108   acl_save_prefix="$prefix"
11109   prefix="$acl_final_prefix"
11110   acl_save_exec_prefix="$exec_prefix"
11111   exec_prefix="$acl_final_exec_prefix"
11112   eval x=\"$x\"
11113   exec_prefix="$acl_save_exec_prefix"
11114   prefix="$acl_save_prefix"
11115
11116                     if test "X$x" = "X-I$additional_includedir"; then
11117                       haveit=yes
11118                       break
11119                     fi
11120                   done
11121                   if test -z "$haveit"; then
11122                     if test -d "$additional_includedir"; then
11123                                             INCEXPAT="${INCEXPAT}${INCEXPAT:+ }-I$additional_includedir"
11124                     fi
11125                   fi
11126                 fi
11127               fi
11128             fi
11129                         if test -n "$found_la"; then
11130                                                         save_libdir="$libdir"
11131               case "$found_la" in
11132                 */* | *\\*) . "$found_la" ;;
11133                 *) . "./$found_la" ;;
11134               esac
11135               libdir="$save_libdir"
11136                             for dep in $dependency_libs; do
11137                 case "$dep" in
11138                   -L*)
11139                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11140                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/lib"; then
11141                       haveit=
11142                       if test "X$additional_libdir" = "X/usr/local/lib"; then
11143                         if test -n "$GCC"; then
11144                           case $host_os in
11145                             linux*) haveit=yes;;
11146                           esac
11147                         fi
11148                       fi
11149                       if test -z "$haveit"; then
11150                         haveit=
11151                         for x in $LDFLAGS $LIBEXPAT; do
11152
11153   acl_save_prefix="$prefix"
11154   prefix="$acl_final_prefix"
11155   acl_save_exec_prefix="$exec_prefix"
11156   exec_prefix="$acl_final_exec_prefix"
11157   eval x=\"$x\"
11158   exec_prefix="$acl_save_exec_prefix"
11159   prefix="$acl_save_prefix"
11160
11161                           if test "X$x" = "X-L$additional_libdir"; then
11162                             haveit=yes
11163                             break
11164                           fi
11165                         done
11166                         if test -z "$haveit"; then
11167                           if test -d "$additional_libdir"; then
11168                                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-L$additional_libdir"
11169                           fi
11170                         fi
11171                         haveit=
11172                         for x in $LDFLAGS $LTLIBEXPAT; do
11173
11174   acl_save_prefix="$prefix"
11175   prefix="$acl_final_prefix"
11176   acl_save_exec_prefix="$exec_prefix"
11177   exec_prefix="$acl_final_exec_prefix"
11178   eval x=\"$x\"
11179   exec_prefix="$acl_save_exec_prefix"
11180   prefix="$acl_save_prefix"
11181
11182                           if test "X$x" = "X-L$additional_libdir"; then
11183                             haveit=yes
11184                             break
11185                           fi
11186                         done
11187                         if test -z "$haveit"; then
11188                           if test -d "$additional_libdir"; then
11189                                                         LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-L$additional_libdir"
11190                           fi
11191                         fi
11192                       fi
11193                     fi
11194                     ;;
11195                   -R*)
11196                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
11197                     if test "$enable_rpath" != no; then
11198                                                                   haveit=
11199                       for x in $rpathdirs; do
11200                         if test "X$x" = "X$dir"; then
11201                           haveit=yes
11202                           break
11203                         fi
11204                       done
11205                       if test -z "$haveit"; then
11206                         rpathdirs="$rpathdirs $dir"
11207                       fi
11208                                                                   haveit=
11209                       for x in $ltrpathdirs; do
11210                         if test "X$x" = "X$dir"; then
11211                           haveit=yes
11212                           break
11213                         fi
11214                       done
11215                       if test -z "$haveit"; then
11216                         ltrpathdirs="$ltrpathdirs $dir"
11217                       fi
11218                     fi
11219                     ;;
11220                   -l*)
11221                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
11222                     ;;
11223                   *.la)
11224                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11225                     ;;
11226                   *)
11227                                         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$dep"
11228                     LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }$dep"
11229                     ;;
11230                 esac
11231               done
11232             fi
11233           else
11234                                                             LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }-l$name"
11235             LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-l$name"
11236           fi
11237         fi
11238       fi
11239     done
11240   done
11241   if test "X$rpathdirs" != "X"; then
11242     if test -n "$hardcode_libdir_separator"; then
11243                         alldirs=
11244       for found_dir in $rpathdirs; do
11245         alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
11246       done
11247             acl_save_libdir="$libdir"
11248       libdir="$alldirs"
11249       eval flag=\"$hardcode_libdir_flag_spec\"
11250       libdir="$acl_save_libdir"
11251       LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
11252     else
11253             for found_dir in $rpathdirs; do
11254         acl_save_libdir="$libdir"
11255         libdir="$found_dir"
11256         eval flag=\"$hardcode_libdir_flag_spec\"
11257         libdir="$acl_save_libdir"
11258         LIBEXPAT="${LIBEXPAT}${LIBEXPAT:+ }$flag"
11259       done
11260     fi
11261   fi
11262   if test "X$ltrpathdirs" != "X"; then
11263             for found_dir in $ltrpathdirs; do
11264       LTLIBEXPAT="${LTLIBEXPAT}${LTLIBEXPAT:+ }-R$found_dir"
11265     done
11266   fi
11267
11268
11269         ac_save_CPPFLAGS="$CPPFLAGS"
11270
11271   for element in $INCEXPAT; do
11272     haveit=
11273     for x in $CPPFLAGS; do
11274
11275   acl_save_prefix="$prefix"
11276   prefix="$acl_final_prefix"
11277   acl_save_exec_prefix="$exec_prefix"
11278   exec_prefix="$acl_final_exec_prefix"
11279   eval x=\"$x\"
11280   exec_prefix="$acl_save_exec_prefix"
11281   prefix="$acl_save_prefix"
11282
11283       if test "X$x" = "X$element"; then
11284         haveit=yes
11285         break
11286       fi
11287     done
11288     if test -z "$haveit"; then
11289       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11290     fi
11291   done
11292
11293
11294   echo "$as_me:$LINENO: checking for libexpat" >&5
11295 echo $ECHO_N "checking for libexpat... $ECHO_C" >&6
11296 if test "${ac_cv_libexpat+set}" = set; then
11297   echo $ECHO_N "(cached) $ECHO_C" >&6
11298 else
11299
11300     ac_save_LIBS="$LIBS"
11301     LIBS="$LIBS $LIBEXPAT"
11302     cat >conftest.$ac_ext <<_ACEOF
11303 /* confdefs.h.  */
11304 _ACEOF
11305 cat confdefs.h >>conftest.$ac_ext
11306 cat >>conftest.$ac_ext <<_ACEOF
11307 /* end confdefs.h.  */
11308 #include "expat.h"
11309 int
11310 main ()
11311 {
11312 XML_Parser p = XML_ParserCreate (0);
11313   ;
11314   return 0;
11315 }
11316 _ACEOF
11317 rm -f conftest.$ac_objext conftest$ac_exeext
11318 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11319   (eval $ac_link) 2>conftest.er1
11320   ac_status=$?
11321   grep -v '^ *+' conftest.er1 >conftest.err
11322   rm -f conftest.er1
11323   cat conftest.err >&5
11324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11325   (exit $ac_status); } &&
11326          { ac_try='test -z "$ac_c_werror_flag"
11327                          || test ! -s conftest.err'
11328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11329   (eval $ac_try) 2>&5
11330   ac_status=$?
11331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11332   (exit $ac_status); }; } &&
11333          { ac_try='test -s conftest$ac_exeext'
11334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11335   (eval $ac_try) 2>&5
11336   ac_status=$?
11337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11338   (exit $ac_status); }; }; then
11339   ac_cv_libexpat=yes
11340 else
11341   echo "$as_me: failed program was:" >&5
11342 sed 's/^/| /' conftest.$ac_ext >&5
11343
11344 ac_cv_libexpat=no
11345 fi
11346 rm -f conftest.err conftest.$ac_objext \
11347       conftest$ac_exeext conftest.$ac_ext
11348     LIBS="$ac_save_LIBS"
11349
11350 fi
11351 echo "$as_me:$LINENO: result: $ac_cv_libexpat" >&5
11352 echo "${ECHO_T}$ac_cv_libexpat" >&6
11353   if test "$ac_cv_libexpat" = yes; then
11354     HAVE_LIBEXPAT=yes
11355
11356 cat >>confdefs.h <<\_ACEOF
11357 #define HAVE_LIBEXPAT 1
11358 _ACEOF
11359
11360     echo "$as_me:$LINENO: checking how to link with libexpat" >&5
11361 echo $ECHO_N "checking how to link with libexpat... $ECHO_C" >&6
11362     echo "$as_me:$LINENO: result: $LIBEXPAT" >&5
11363 echo "${ECHO_T}$LIBEXPAT" >&6
11364   else
11365     HAVE_LIBEXPAT=no
11366             CPPFLAGS="$ac_save_CPPFLAGS"
11367     LIBEXPAT=
11368     LTLIBEXPAT=
11369   fi
11370
11371
11372
11373
11374
11375
11376   if test "$HAVE_LIBEXPAT" != yes; then
11377     if test "$with_expat" = yes; then
11378       { { echo "$as_me:$LINENO: error: expat is missing or unusable" >&5
11379 echo "$as_me: error: expat is missing or unusable" >&2;}
11380    { (exit 1); exit 1; }; }
11381     else
11382       { echo "$as_me:$LINENO: WARNING: expat is missing or unusable; some features may be unavailable." >&5
11383 echo "$as_me: WARNING: expat is missing or unusable; some features may be unavailable." >&2;}
11384     fi
11385   else
11386     save_LIBS=$LIBS
11387     LIBS="$LIBS $LIBEXPAT"
11388
11389 for ac_func in XML_StopParser
11390 do
11391 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11392 echo "$as_me:$LINENO: checking for $ac_func" >&5
11393 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11394 if eval "test \"\${$as_ac_var+set}\" = set"; then
11395   echo $ECHO_N "(cached) $ECHO_C" >&6
11396 else
11397   cat >conftest.$ac_ext <<_ACEOF
11398 /* confdefs.h.  */
11399 _ACEOF
11400 cat confdefs.h >>conftest.$ac_ext
11401 cat >>conftest.$ac_ext <<_ACEOF
11402 /* end confdefs.h.  */
11403 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11404    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11405 #define $ac_func innocuous_$ac_func
11406
11407 /* System header to define __stub macros and hopefully few prototypes,
11408     which can conflict with char $ac_func (); below.
11409     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11410     <limits.h> exists even on freestanding compilers.  */
11411
11412 #ifdef __STDC__
11413 # include <limits.h>
11414 #else
11415 # include <assert.h>
11416 #endif
11417
11418 #undef $ac_func
11419
11420 /* Override any gcc2 internal prototype to avoid an error.  */
11421 #ifdef __cplusplus
11422 extern "C"
11423 {
11424 #endif
11425 /* We use char because int might match the return type of a gcc2
11426    builtin and then its argument prototype would still apply.  */
11427 char $ac_func ();
11428 /* The GNU C library defines this for functions which it implements
11429     to always fail with ENOSYS.  Some functions are actually named
11430     something starting with __ and the normal name is an alias.  */
11431 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11432 choke me
11433 #else
11434 char (*f) () = $ac_func;
11435 #endif
11436 #ifdef __cplusplus
11437 }
11438 #endif
11439
11440 int
11441 main ()
11442 {
11443 return f != $ac_func;
11444   ;
11445   return 0;
11446 }
11447 _ACEOF
11448 rm -f conftest.$ac_objext conftest$ac_exeext
11449 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11450   (eval $ac_link) 2>conftest.er1
11451   ac_status=$?
11452   grep -v '^ *+' conftest.er1 >conftest.err
11453   rm -f conftest.er1
11454   cat conftest.err >&5
11455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11456   (exit $ac_status); } &&
11457          { ac_try='test -z "$ac_c_werror_flag"
11458                          || test ! -s conftest.err'
11459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11460   (eval $ac_try) 2>&5
11461   ac_status=$?
11462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11463   (exit $ac_status); }; } &&
11464          { ac_try='test -s conftest$ac_exeext'
11465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11466   (eval $ac_try) 2>&5
11467   ac_status=$?
11468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11469   (exit $ac_status); }; }; then
11470   eval "$as_ac_var=yes"
11471 else
11472   echo "$as_me: failed program was:" >&5
11473 sed 's/^/| /' conftest.$ac_ext >&5
11474
11475 eval "$as_ac_var=no"
11476 fi
11477 rm -f conftest.err conftest.$ac_objext \
11478       conftest$ac_exeext conftest.$ac_ext
11479 fi
11480 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11481 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11482 if test `eval echo '${'$as_ac_var'}'` = yes; then
11483   cat >>confdefs.h <<_ACEOF
11484 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11485 _ACEOF
11486
11487 fi
11488 done
11489
11490     LIBS=$save_LIBS
11491   fi
11492 fi
11493
11494
11495
11496
11497 # Check whether --with-python or --without-python was given.
11498 if test "${with_python+set}" = set; then
11499   withval="$with_python"
11500
11501 else
11502   with_python=auto
11503 fi;
11504 echo "$as_me:$LINENO: checking whether to use python" >&5
11505 echo $ECHO_N "checking whether to use python... $ECHO_C" >&6
11506 echo "$as_me:$LINENO: result: $with_python" >&5
11507 echo "${ECHO_T}$with_python" >&6
11508
11509 if test "${with_python}" = no; then
11510   { echo "$as_me:$LINENO: WARNING: python support disabled; some features may be unavailable." >&5
11511 echo "$as_me: WARNING: python support disabled; some features may be unavailable." >&2;}
11512   have_libpython=no
11513 else
11514   case "${with_python}" in
11515   yes | auto)
11516     # Leave as empty, use defaults.
11517     python_includes=
11518     python_libs=
11519     ;;
11520   /*)
11521     python_includes="-I${with_python}/include"
11522     python_libs="-L${with_python}/lib"
11523     ;;
11524   *)
11525     { { echo "$as_me:$LINENO: error: invalid value for --with-python" >&5
11526 echo "$as_me: error: invalid value for --with-python" >&2;}
11527    { (exit 1); exit 1; }; }
11528     ;;
11529   esac
11530
11531   save_CPPFLAGS=$CPPFLAGS
11532   CPPFLAGS="$CPPFLAGS ${python_includes}"
11533   save_LIBS=$LIBS
11534   LIBS="$LIBS ${python_libs}"
11535   have_libpython=no
11536   if test "${have_libpython}" = no; then
11537
11538   version=python2.6
11539
11540
11541   HAVE_LIBPYTHON2_6=no
11542   echo "$as_me:$LINENO: checking for ${version}" >&5
11543 echo $ECHO_N "checking for ${version}... $ECHO_C" >&6
11544   save_LIBS=$LIBS
11545   LIBS="$LIBS -l${version}"
11546   cat >conftest.$ac_ext <<_ACEOF
11547 /* confdefs.h.  */
11548 _ACEOF
11549 cat confdefs.h >>conftest.$ac_ext
11550 cat >>conftest.$ac_ext <<_ACEOF
11551 /* end confdefs.h.  */
11552 #include "${version}/Python.h"
11553 int
11554 main ()
11555 {
11556 Py_Initialize ();
11557   ;
11558   return 0;
11559 }
11560 _ACEOF
11561 rm -f conftest.$ac_objext conftest$ac_exeext
11562 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11563   (eval $ac_link) 2>conftest.er1
11564   ac_status=$?
11565   grep -v '^ *+' conftest.er1 >conftest.err
11566   rm -f conftest.er1
11567   cat conftest.err >&5
11568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11569   (exit $ac_status); } &&
11570          { ac_try='test -z "$ac_c_werror_flag"
11571                          || test ! -s conftest.err'
11572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11573   (eval $ac_try) 2>&5
11574   ac_status=$?
11575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11576   (exit $ac_status); }; } &&
11577          { ac_try='test -s conftest$ac_exeext'
11578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11579   (eval $ac_try) 2>&5
11580   ac_status=$?
11581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11582   (exit $ac_status); }; }; then
11583   HAVE_LIBPYTHON2_6=yes
11584                   have_libpython=yes
11585 else
11586   echo "$as_me: failed program was:" >&5
11587 sed 's/^/| /' conftest.$ac_ext >&5
11588
11589 LIBS=$save_LIBS
11590 fi
11591 rm -f conftest.err conftest.$ac_objext \
11592       conftest$ac_exeext conftest.$ac_ext
11593   echo "$as_me:$LINENO: result: $HAVE_LIBPYTHON2_6" >&5
11594 echo "${ECHO_T}$HAVE_LIBPYTHON2_6" >&6
11595
11596     if test "${HAVE_LIBPYTHON2_6}" = yes; then
11597
11598 cat >>confdefs.h <<\_ACEOF
11599 #define HAVE_LIBPYTHON2_6 1
11600 _ACEOF
11601
11602     fi
11603   fi
11604   if test ${have_libpython} = no; then
11605
11606   version=python2.5
11607
11608
11609   HAVE_LIBPYTHON2_5=no
11610   echo "$as_me:$LINENO: checking for ${version}" >&5
11611 echo $ECHO_N "checking for ${version}... $ECHO_C" >&6
11612   save_LIBS=$LIBS
11613   LIBS="$LIBS -l${version}"
11614   cat >conftest.$ac_ext <<_ACEOF
11615 /* confdefs.h.  */
11616 _ACEOF
11617 cat confdefs.h >>conftest.$ac_ext
11618 cat >>conftest.$ac_ext <<_ACEOF
11619 /* end confdefs.h.  */
11620 #include "${version}/Python.h"
11621 int
11622 main ()
11623 {
11624 Py_Initialize ();
11625   ;
11626   return 0;
11627 }
11628 _ACEOF
11629 rm -f conftest.$ac_objext conftest$ac_exeext
11630 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11631   (eval $ac_link) 2>conftest.er1
11632   ac_status=$?
11633   grep -v '^ *+' conftest.er1 >conftest.err
11634   rm -f conftest.er1
11635   cat conftest.err >&5
11636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11637   (exit $ac_status); } &&
11638          { ac_try='test -z "$ac_c_werror_flag"
11639                          || test ! -s conftest.err'
11640   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11641   (eval $ac_try) 2>&5
11642   ac_status=$?
11643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11644   (exit $ac_status); }; } &&
11645          { ac_try='test -s conftest$ac_exeext'
11646   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11647   (eval $ac_try) 2>&5
11648   ac_status=$?
11649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11650   (exit $ac_status); }; }; then
11651   HAVE_LIBPYTHON2_5=yes
11652                   have_libpython=yes
11653 else
11654   echo "$as_me: failed program was:" >&5
11655 sed 's/^/| /' conftest.$ac_ext >&5
11656
11657 LIBS=$save_LIBS
11658 fi
11659 rm -f conftest.err conftest.$ac_objext \
11660       conftest$ac_exeext conftest.$ac_ext
11661   echo "$as_me:$LINENO: result: $HAVE_LIBPYTHON2_5" >&5
11662 echo "${ECHO_T}$HAVE_LIBPYTHON2_5" >&6
11663
11664     if test "${HAVE_LIBPYTHON2_5}" = yes; then
11665
11666 cat >>confdefs.h <<\_ACEOF
11667 #define HAVE_LIBPYTHON2_5 1
11668 _ACEOF
11669
11670     fi
11671   fi
11672   if test ${have_libpython} = no; then
11673
11674   version=python2.4
11675
11676
11677   HAVE_LIBPYTHON2_4=no
11678   echo "$as_me:$LINENO: checking for ${version}" >&5
11679 echo $ECHO_N "checking for ${version}... $ECHO_C" >&6
11680   save_LIBS=$LIBS
11681   LIBS="$LIBS -l${version}"
11682   cat >conftest.$ac_ext <<_ACEOF
11683 /* confdefs.h.  */
11684 _ACEOF
11685 cat confdefs.h >>conftest.$ac_ext
11686 cat >>conftest.$ac_ext <<_ACEOF
11687 /* end confdefs.h.  */
11688 #include "${version}/Python.h"
11689 int
11690 main ()
11691 {
11692 Py_Initialize ();
11693   ;
11694   return 0;
11695 }
11696 _ACEOF
11697 rm -f conftest.$ac_objext conftest$ac_exeext
11698 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11699   (eval $ac_link) 2>conftest.er1
11700   ac_status=$?
11701   grep -v '^ *+' conftest.er1 >conftest.err
11702   rm -f conftest.er1
11703   cat conftest.err >&5
11704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11705   (exit $ac_status); } &&
11706          { ac_try='test -z "$ac_c_werror_flag"
11707                          || test ! -s conftest.err'
11708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11709   (eval $ac_try) 2>&5
11710   ac_status=$?
11711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11712   (exit $ac_status); }; } &&
11713          { ac_try='test -s conftest$ac_exeext'
11714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11715   (eval $ac_try) 2>&5
11716   ac_status=$?
11717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11718   (exit $ac_status); }; }; then
11719   HAVE_LIBPYTHON2_4=yes
11720                   have_libpython=yes
11721 else
11722   echo "$as_me: failed program was:" >&5
11723 sed 's/^/| /' conftest.$ac_ext >&5
11724
11725 LIBS=$save_LIBS
11726 fi
11727 rm -f conftest.err conftest.$ac_objext \
11728       conftest$ac_exeext conftest.$ac_ext
11729   echo "$as_me:$LINENO: result: $HAVE_LIBPYTHON2_4" >&5
11730 echo "${ECHO_T}$HAVE_LIBPYTHON2_4" >&6
11731
11732     if test "${HAVE_LIBPYTHON2_4}" = yes; then
11733
11734 cat >>confdefs.h <<\_ACEOF
11735 #define HAVE_LIBPYTHON2_4 1
11736 _ACEOF
11737
11738     fi
11739   fi
11740   if test ${have_libpython} = no; then
11741     case "${with_python}" in
11742     yes)
11743       { { echo "$as_me:$LINENO: error: python is missing or unusable" >&5
11744 echo "$as_me: error: python is missing or unusable" >&2;}
11745    { (exit 1); exit 1; }; }
11746       ;;
11747     auto)
11748       { echo "$as_me:$LINENO: WARNING: python is missing or unusable; some features may be unavailable." >&5
11749 echo "$as_me: WARNING: python is missing or unusable; some features may be unavailable." >&2;}
11750       ;;
11751     *)
11752       { { echo "$as_me:$LINENO: error: no usable python found at ${with_python}" >&5
11753 echo "$as_me: error: no usable python found at ${with_python}" >&2;}
11754    { (exit 1); exit 1; }; }
11755       ;;
11756     esac
11757     CPPFLAGS=$save_CPPFLAGS
11758     LIBS=$save_LIBS
11759   fi
11760 fi
11761
11762 if test "${have_libpython}" = yes; then
11763
11764 cat >>confdefs.h <<\_ACEOF
11765 #define HAVE_PYTHON 1
11766 _ACEOF
11767
11768   CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_PYTHON_OBS)"
11769   CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_PYTHON_DEPS)"
11770   CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_PYTHON_SRCS)"
11771   ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_PYTHON_CFLAGS)"
11772
11773   # Flags needed to compile Python code (taken from python-config --cflags).
11774   # We cannot call python-config directly because it will output whatever was
11775   # used when compiling the Python interpreter itself, including flags which
11776   # would make the python-related objects be compiled differently from the
11777   # rest of GDB (e.g., -O2 and -fPIC).
11778   if test "${GCC}" = yes; then
11779     tentative_python_cflags="-fno-strict-aliasing -DNDEBUG -fwrapv"
11780   fi
11781
11782   if test "x${tentative_python_cflags}" != x; then
11783     echo "$as_me:$LINENO: checking compiler flags for python code" >&5
11784 echo $ECHO_N "checking compiler flags for python code... $ECHO_C" >&6
11785     for flag in ${tentative_python_cflags}; do
11786       # Check that the compiler accepts it
11787       saved_CFLAGS="$CFLAGS"
11788       CFLAGS="$CFLAGS $flag"
11789       cat >conftest.$ac_ext <<_ACEOF
11790 /* confdefs.h.  */
11791 _ACEOF
11792 cat confdefs.h >>conftest.$ac_ext
11793 cat >>conftest.$ac_ext <<_ACEOF
11794 /* end confdefs.h.  */
11795
11796 int
11797 main ()
11798 {
11799
11800   ;
11801   return 0;
11802 }
11803 _ACEOF
11804 rm -f conftest.$ac_objext
11805 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11806   (eval $ac_compile) 2>conftest.er1
11807   ac_status=$?
11808   grep -v '^ *+' conftest.er1 >conftest.err
11809   rm -f conftest.er1
11810   cat conftest.err >&5
11811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11812   (exit $ac_status); } &&
11813          { ac_try='test -z "$ac_c_werror_flag"
11814                          || test ! -s conftest.err'
11815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11816   (eval $ac_try) 2>&5
11817   ac_status=$?
11818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11819   (exit $ac_status); }; } &&
11820          { ac_try='test -s conftest.$ac_objext'
11821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11822   (eval $ac_try) 2>&5
11823   ac_status=$?
11824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11825   (exit $ac_status); }; }; then
11826   PYTHON_CFLAGS="${PYTHON_CFLAGS} $flag"
11827 else
11828   echo "$as_me: failed program was:" >&5
11829 sed 's/^/| /' conftest.$ac_ext >&5
11830
11831 fi
11832 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11833       CFLAGS="$saved_CFLAGS"
11834     done
11835     echo "$as_me:$LINENO: result: ${PYTHON_CFLAGS}" >&5
11836 echo "${ECHO_T}${PYTHON_CFLAGS}" >&6
11837   fi
11838 else
11839   # Even if Python support is not compiled in, we need to have these files
11840   # included in order to recognize the GDB command "python".
11841   CONFIG_OBS="$CONFIG_OBS python.o python-value.o"
11842   CONFIG_SRCS="$CONFIG_SRCS python/python.c python/python-value.c"
11843 fi
11844
11845
11846 # ------------------------- #
11847 # Checks for header files.  #
11848 # ------------------------- #
11849
11850
11851
11852
11853
11854
11855 ac_header_dirent=no
11856 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
11857   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
11858 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
11859 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
11860 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11861   echo $ECHO_N "(cached) $ECHO_C" >&6
11862 else
11863   cat >conftest.$ac_ext <<_ACEOF
11864 /* confdefs.h.  */
11865 _ACEOF
11866 cat confdefs.h >>conftest.$ac_ext
11867 cat >>conftest.$ac_ext <<_ACEOF
11868 /* end confdefs.h.  */
11869 #include <sys/types.h>
11870 #include <$ac_hdr>
11871
11872 int
11873 main ()
11874 {
11875 if ((DIR *) 0)
11876 return 0;
11877   ;
11878   return 0;
11879 }
11880 _ACEOF
11881 rm -f conftest.$ac_objext
11882 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11883   (eval $ac_compile) 2>conftest.er1
11884   ac_status=$?
11885   grep -v '^ *+' conftest.er1 >conftest.err
11886   rm -f conftest.er1
11887   cat conftest.err >&5
11888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11889   (exit $ac_status); } &&
11890          { ac_try='test -z "$ac_c_werror_flag"
11891                          || test ! -s conftest.err'
11892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11893   (eval $ac_try) 2>&5
11894   ac_status=$?
11895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11896   (exit $ac_status); }; } &&
11897          { ac_try='test -s conftest.$ac_objext'
11898   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11899   (eval $ac_try) 2>&5
11900   ac_status=$?
11901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11902   (exit $ac_status); }; }; then
11903   eval "$as_ac_Header=yes"
11904 else
11905   echo "$as_me: failed program was:" >&5
11906 sed 's/^/| /' conftest.$ac_ext >&5
11907
11908 eval "$as_ac_Header=no"
11909 fi
11910 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11911 fi
11912 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11913 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11914 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11915   cat >>confdefs.h <<_ACEOF
11916 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
11917 _ACEOF
11918
11919 ac_header_dirent=$ac_hdr; break
11920 fi
11921
11922 done
11923 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
11924 if test $ac_header_dirent = dirent.h; then
11925   echo "$as_me:$LINENO: checking for library containing opendir" >&5
11926 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
11927 if test "${ac_cv_search_opendir+set}" = set; then
11928   echo $ECHO_N "(cached) $ECHO_C" >&6
11929 else
11930   ac_func_search_save_LIBS=$LIBS
11931 ac_cv_search_opendir=no
11932 cat >conftest.$ac_ext <<_ACEOF
11933 /* confdefs.h.  */
11934 _ACEOF
11935 cat confdefs.h >>conftest.$ac_ext
11936 cat >>conftest.$ac_ext <<_ACEOF
11937 /* end confdefs.h.  */
11938
11939 /* Override any gcc2 internal prototype to avoid an error.  */
11940 #ifdef __cplusplus
11941 extern "C"
11942 #endif
11943 /* We use char because int might match the return type of a gcc2
11944    builtin and then its argument prototype would still apply.  */
11945 char opendir ();
11946 int
11947 main ()
11948 {
11949 opendir ();
11950   ;
11951   return 0;
11952 }
11953 _ACEOF
11954 rm -f conftest.$ac_objext conftest$ac_exeext
11955 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11956   (eval $ac_link) 2>conftest.er1
11957   ac_status=$?
11958   grep -v '^ *+' conftest.er1 >conftest.err
11959   rm -f conftest.er1
11960   cat conftest.err >&5
11961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11962   (exit $ac_status); } &&
11963          { ac_try='test -z "$ac_c_werror_flag"
11964                          || test ! -s conftest.err'
11965   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11966   (eval $ac_try) 2>&5
11967   ac_status=$?
11968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11969   (exit $ac_status); }; } &&
11970          { ac_try='test -s conftest$ac_exeext'
11971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11972   (eval $ac_try) 2>&5
11973   ac_status=$?
11974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11975   (exit $ac_status); }; }; then
11976   ac_cv_search_opendir="none required"
11977 else
11978   echo "$as_me: failed program was:" >&5
11979 sed 's/^/| /' conftest.$ac_ext >&5
11980
11981 fi
11982 rm -f conftest.err conftest.$ac_objext \
11983       conftest$ac_exeext conftest.$ac_ext
11984 if test "$ac_cv_search_opendir" = no; then
11985   for ac_lib in dir; do
11986     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
11987     cat >conftest.$ac_ext <<_ACEOF
11988 /* confdefs.h.  */
11989 _ACEOF
11990 cat confdefs.h >>conftest.$ac_ext
11991 cat >>conftest.$ac_ext <<_ACEOF
11992 /* end confdefs.h.  */
11993
11994 /* Override any gcc2 internal prototype to avoid an error.  */
11995 #ifdef __cplusplus
11996 extern "C"
11997 #endif
11998 /* We use char because int might match the return type of a gcc2
11999    builtin and then its argument prototype would still apply.  */
12000 char opendir ();
12001 int
12002 main ()
12003 {
12004 opendir ();
12005   ;
12006   return 0;
12007 }
12008 _ACEOF
12009 rm -f conftest.$ac_objext conftest$ac_exeext
12010 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12011   (eval $ac_link) 2>conftest.er1
12012   ac_status=$?
12013   grep -v '^ *+' conftest.er1 >conftest.err
12014   rm -f conftest.er1
12015   cat conftest.err >&5
12016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12017   (exit $ac_status); } &&
12018          { ac_try='test -z "$ac_c_werror_flag"
12019                          || test ! -s conftest.err'
12020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12021   (eval $ac_try) 2>&5
12022   ac_status=$?
12023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12024   (exit $ac_status); }; } &&
12025          { ac_try='test -s conftest$ac_exeext'
12026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12027   (eval $ac_try) 2>&5
12028   ac_status=$?
12029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12030   (exit $ac_status); }; }; then
12031   ac_cv_search_opendir="-l$ac_lib"
12032 break
12033 else
12034   echo "$as_me: failed program was:" >&5
12035 sed 's/^/| /' conftest.$ac_ext >&5
12036
12037 fi
12038 rm -f conftest.err conftest.$ac_objext \
12039       conftest$ac_exeext conftest.$ac_ext
12040   done
12041 fi
12042 LIBS=$ac_func_search_save_LIBS
12043 fi
12044 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
12045 echo "${ECHO_T}$ac_cv_search_opendir" >&6
12046 if test "$ac_cv_search_opendir" != no; then
12047   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
12048
12049 fi
12050
12051 else
12052   echo "$as_me:$LINENO: checking for library containing opendir" >&5
12053 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
12054 if test "${ac_cv_search_opendir+set}" = set; then
12055   echo $ECHO_N "(cached) $ECHO_C" >&6
12056 else
12057   ac_func_search_save_LIBS=$LIBS
12058 ac_cv_search_opendir=no
12059 cat >conftest.$ac_ext <<_ACEOF
12060 /* confdefs.h.  */
12061 _ACEOF
12062 cat confdefs.h >>conftest.$ac_ext
12063 cat >>conftest.$ac_ext <<_ACEOF
12064 /* end confdefs.h.  */
12065
12066 /* Override any gcc2 internal prototype to avoid an error.  */
12067 #ifdef __cplusplus
12068 extern "C"
12069 #endif
12070 /* We use char because int might match the return type of a gcc2
12071    builtin and then its argument prototype would still apply.  */
12072 char opendir ();
12073 int
12074 main ()
12075 {
12076 opendir ();
12077   ;
12078   return 0;
12079 }
12080 _ACEOF
12081 rm -f conftest.$ac_objext conftest$ac_exeext
12082 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12083   (eval $ac_link) 2>conftest.er1
12084   ac_status=$?
12085   grep -v '^ *+' conftest.er1 >conftest.err
12086   rm -f conftest.er1
12087   cat conftest.err >&5
12088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12089   (exit $ac_status); } &&
12090          { ac_try='test -z "$ac_c_werror_flag"
12091                          || test ! -s conftest.err'
12092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12093   (eval $ac_try) 2>&5
12094   ac_status=$?
12095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12096   (exit $ac_status); }; } &&
12097          { ac_try='test -s conftest$ac_exeext'
12098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12099   (eval $ac_try) 2>&5
12100   ac_status=$?
12101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12102   (exit $ac_status); }; }; then
12103   ac_cv_search_opendir="none required"
12104 else
12105   echo "$as_me: failed program was:" >&5
12106 sed 's/^/| /' conftest.$ac_ext >&5
12107
12108 fi
12109 rm -f conftest.err conftest.$ac_objext \
12110       conftest$ac_exeext conftest.$ac_ext
12111 if test "$ac_cv_search_opendir" = no; then
12112   for ac_lib in x; do
12113     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12114     cat >conftest.$ac_ext <<_ACEOF
12115 /* confdefs.h.  */
12116 _ACEOF
12117 cat confdefs.h >>conftest.$ac_ext
12118 cat >>conftest.$ac_ext <<_ACEOF
12119 /* end confdefs.h.  */
12120
12121 /* Override any gcc2 internal prototype to avoid an error.  */
12122 #ifdef __cplusplus
12123 extern "C"
12124 #endif
12125 /* We use char because int might match the return type of a gcc2
12126    builtin and then its argument prototype would still apply.  */
12127 char opendir ();
12128 int
12129 main ()
12130 {
12131 opendir ();
12132   ;
12133   return 0;
12134 }
12135 _ACEOF
12136 rm -f conftest.$ac_objext conftest$ac_exeext
12137 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12138   (eval $ac_link) 2>conftest.er1
12139   ac_status=$?
12140   grep -v '^ *+' conftest.er1 >conftest.err
12141   rm -f conftest.er1
12142   cat conftest.err >&5
12143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12144   (exit $ac_status); } &&
12145          { ac_try='test -z "$ac_c_werror_flag"
12146                          || test ! -s conftest.err'
12147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12148   (eval $ac_try) 2>&5
12149   ac_status=$?
12150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12151   (exit $ac_status); }; } &&
12152          { ac_try='test -s conftest$ac_exeext'
12153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12154   (eval $ac_try) 2>&5
12155   ac_status=$?
12156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12157   (exit $ac_status); }; }; then
12158   ac_cv_search_opendir="-l$ac_lib"
12159 break
12160 else
12161   echo "$as_me: failed program was:" >&5
12162 sed 's/^/| /' conftest.$ac_ext >&5
12163
12164 fi
12165 rm -f conftest.err conftest.$ac_objext \
12166       conftest$ac_exeext conftest.$ac_ext
12167   done
12168 fi
12169 LIBS=$ac_func_search_save_LIBS
12170 fi
12171 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
12172 echo "${ECHO_T}$ac_cv_search_opendir" >&6
12173 if test "$ac_cv_search_opendir" != no; then
12174   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
12175
12176 fi
12177
12178 fi
12179
12180 echo "$as_me:$LINENO: checking whether stat file-mode macros are broken" >&5
12181 echo $ECHO_N "checking whether stat file-mode macros are broken... $ECHO_C" >&6
12182 if test "${ac_cv_header_stat_broken+set}" = set; then
12183   echo $ECHO_N "(cached) $ECHO_C" >&6
12184 else
12185   cat >conftest.$ac_ext <<_ACEOF
12186 /* confdefs.h.  */
12187 _ACEOF
12188 cat confdefs.h >>conftest.$ac_ext
12189 cat >>conftest.$ac_ext <<_ACEOF
12190 /* end confdefs.h.  */
12191 #include <sys/types.h>
12192 #include <sys/stat.h>
12193
12194 #if defined(S_ISBLK) && defined(S_IFDIR)
12195 # if S_ISBLK (S_IFDIR)
12196 You lose.
12197 # endif
12198 #endif
12199
12200 #if defined(S_ISBLK) && defined(S_IFCHR)
12201 # if S_ISBLK (S_IFCHR)
12202 You lose.
12203 # endif
12204 #endif
12205
12206 #if defined(S_ISLNK) && defined(S_IFREG)
12207 # if S_ISLNK (S_IFREG)
12208 You lose.
12209 # endif
12210 #endif
12211
12212 #if defined(S_ISSOCK) && defined(S_IFREG)
12213 # if S_ISSOCK (S_IFREG)
12214 You lose.
12215 # endif
12216 #endif
12217
12218 _ACEOF
12219 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12220   $EGREP "You lose" >/dev/null 2>&1; then
12221   ac_cv_header_stat_broken=yes
12222 else
12223   ac_cv_header_stat_broken=no
12224 fi
12225 rm -f conftest*
12226
12227 fi
12228 echo "$as_me:$LINENO: result: $ac_cv_header_stat_broken" >&5
12229 echo "${ECHO_T}$ac_cv_header_stat_broken" >&6
12230 if test $ac_cv_header_stat_broken = yes; then
12231
12232 cat >>confdefs.h <<\_ACEOF
12233 #define STAT_MACROS_BROKEN 1
12234 _ACEOF
12235
12236 fi
12237
12238 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
12239 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
12240 if test "${ac_cv_header_stdc+set}" = set; then
12241   echo $ECHO_N "(cached) $ECHO_C" >&6
12242 else
12243   cat >conftest.$ac_ext <<_ACEOF
12244 /* confdefs.h.  */
12245 _ACEOF
12246 cat confdefs.h >>conftest.$ac_ext
12247 cat >>conftest.$ac_ext <<_ACEOF
12248 /* end confdefs.h.  */
12249 #include <stdlib.h>
12250 #include <stdarg.h>
12251 #include <string.h>
12252 #include <float.h>
12253
12254 int
12255 main ()
12256 {
12257
12258   ;
12259   return 0;
12260 }
12261 _ACEOF
12262 rm -f conftest.$ac_objext
12263 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12264   (eval $ac_compile) 2>conftest.er1
12265   ac_status=$?
12266   grep -v '^ *+' conftest.er1 >conftest.err
12267   rm -f conftest.er1
12268   cat conftest.err >&5
12269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12270   (exit $ac_status); } &&
12271          { ac_try='test -z "$ac_c_werror_flag"
12272                          || test ! -s conftest.err'
12273   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12274   (eval $ac_try) 2>&5
12275   ac_status=$?
12276   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12277   (exit $ac_status); }; } &&
12278          { ac_try='test -s conftest.$ac_objext'
12279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12280   (eval $ac_try) 2>&5
12281   ac_status=$?
12282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12283   (exit $ac_status); }; }; then
12284   ac_cv_header_stdc=yes
12285 else
12286   echo "$as_me: failed program was:" >&5
12287 sed 's/^/| /' conftest.$ac_ext >&5
12288
12289 ac_cv_header_stdc=no
12290 fi
12291 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12292
12293 if test $ac_cv_header_stdc = yes; then
12294   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
12295   cat >conftest.$ac_ext <<_ACEOF
12296 /* confdefs.h.  */
12297 _ACEOF
12298 cat confdefs.h >>conftest.$ac_ext
12299 cat >>conftest.$ac_ext <<_ACEOF
12300 /* end confdefs.h.  */
12301 #include <string.h>
12302
12303 _ACEOF
12304 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12305   $EGREP "memchr" >/dev/null 2>&1; then
12306   :
12307 else
12308   ac_cv_header_stdc=no
12309 fi
12310 rm -f conftest*
12311
12312 fi
12313
12314 if test $ac_cv_header_stdc = yes; then
12315   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
12316   cat >conftest.$ac_ext <<_ACEOF
12317 /* confdefs.h.  */
12318 _ACEOF
12319 cat confdefs.h >>conftest.$ac_ext
12320 cat >>conftest.$ac_ext <<_ACEOF
12321 /* end confdefs.h.  */
12322 #include <stdlib.h>
12323
12324 _ACEOF
12325 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12326   $EGREP "free" >/dev/null 2>&1; then
12327   :
12328 else
12329   ac_cv_header_stdc=no
12330 fi
12331 rm -f conftest*
12332
12333 fi
12334
12335 if test $ac_cv_header_stdc = yes; then
12336   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
12337   if test "$cross_compiling" = yes; then
12338   :
12339 else
12340   cat >conftest.$ac_ext <<_ACEOF
12341 /* confdefs.h.  */
12342 _ACEOF
12343 cat confdefs.h >>conftest.$ac_ext
12344 cat >>conftest.$ac_ext <<_ACEOF
12345 /* end confdefs.h.  */
12346 #include <ctype.h>
12347 #if ((' ' & 0x0FF) == 0x020)
12348 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
12349 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
12350 #else
12351 # define ISLOWER(c) \
12352                    (('a' <= (c) && (c) <= 'i') \
12353                      || ('j' <= (c) && (c) <= 'r') \
12354                      || ('s' <= (c) && (c) <= 'z'))
12355 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
12356 #endif
12357
12358 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
12359 int
12360 main ()
12361 {
12362   int i;
12363   for (i = 0; i < 256; i++)
12364     if (XOR (islower (i), ISLOWER (i))
12365         || toupper (i) != TOUPPER (i))
12366       exit(2);
12367   exit (0);
12368 }
12369 _ACEOF
12370 rm -f conftest$ac_exeext
12371 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12372   (eval $ac_link) 2>&5
12373   ac_status=$?
12374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12375   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12377   (eval $ac_try) 2>&5
12378   ac_status=$?
12379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12380   (exit $ac_status); }; }; then
12381   :
12382 else
12383   echo "$as_me: program exited with status $ac_status" >&5
12384 echo "$as_me: failed program was:" >&5
12385 sed 's/^/| /' conftest.$ac_ext >&5
12386
12387 ( exit $ac_status )
12388 ac_cv_header_stdc=no
12389 fi
12390 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12391 fi
12392 fi
12393 fi
12394 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
12395 echo "${ECHO_T}$ac_cv_header_stdc" >&6
12396 if test $ac_cv_header_stdc = yes; then
12397
12398 cat >>confdefs.h <<\_ACEOF
12399 #define STDC_HEADERS 1
12400 _ACEOF
12401
12402 fi
12403
12404 # elf_hp.h is for HP/UX 64-bit shared library support.
12405 # FIXME: kettenis/20030102: In most cases we include these (ctype.h, time.h)
12406 # unconditionally, so what's the point in checking these?
12407
12408
12409
12410
12411
12412
12413
12414
12415
12416
12417
12418
12419
12420
12421
12422
12423
12424
12425
12426
12427
12428
12429
12430
12431
12432
12433
12434
12435
12436
12437
12438
12439
12440
12441
12442
12443
12444 for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
12445                   thread_db.h gnu/libc-version.h signal.h stddef.h \
12446                   stdlib.h string.h memory.h strings.h sys/fault.h \
12447                   sys/file.h sys/filio.h sys/ioctl.h sys/param.h \
12448                   sys/resource.h sys/procfs.h sys/ptrace.h ptrace.h \
12449                   sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
12450                   sys/types.h sys/wait.h wait.h termios.h termio.h \
12451                   sgtty.h unistd.h elf_hp.h ctype.h time.h locale.h
12452 do
12453 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12454 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12455   echo "$as_me:$LINENO: checking for $ac_header" >&5
12456 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12457 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12458   echo $ECHO_N "(cached) $ECHO_C" >&6
12459 fi
12460 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12461 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12462 else
12463   # Is the header compilable?
12464 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12465 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12466 cat >conftest.$ac_ext <<_ACEOF
12467 /* confdefs.h.  */
12468 _ACEOF
12469 cat confdefs.h >>conftest.$ac_ext
12470 cat >>conftest.$ac_ext <<_ACEOF
12471 /* end confdefs.h.  */
12472 $ac_includes_default
12473 #include <$ac_header>
12474 _ACEOF
12475 rm -f conftest.$ac_objext
12476 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12477   (eval $ac_compile) 2>conftest.er1
12478   ac_status=$?
12479   grep -v '^ *+' conftest.er1 >conftest.err
12480   rm -f conftest.er1
12481   cat conftest.err >&5
12482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12483   (exit $ac_status); } &&
12484          { ac_try='test -z "$ac_c_werror_flag"
12485                          || test ! -s conftest.err'
12486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12487   (eval $ac_try) 2>&5
12488   ac_status=$?
12489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12490   (exit $ac_status); }; } &&
12491          { ac_try='test -s conftest.$ac_objext'
12492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12493   (eval $ac_try) 2>&5
12494   ac_status=$?
12495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12496   (exit $ac_status); }; }; then
12497   ac_header_compiler=yes
12498 else
12499   echo "$as_me: failed program was:" >&5
12500 sed 's/^/| /' conftest.$ac_ext >&5
12501
12502 ac_header_compiler=no
12503 fi
12504 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12505 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12506 echo "${ECHO_T}$ac_header_compiler" >&6
12507
12508 # Is the header present?
12509 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12510 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12511 cat >conftest.$ac_ext <<_ACEOF
12512 /* confdefs.h.  */
12513 _ACEOF
12514 cat confdefs.h >>conftest.$ac_ext
12515 cat >>conftest.$ac_ext <<_ACEOF
12516 /* end confdefs.h.  */
12517 #include <$ac_header>
12518 _ACEOF
12519 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12520   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12521   ac_status=$?
12522   grep -v '^ *+' conftest.er1 >conftest.err
12523   rm -f conftest.er1
12524   cat conftest.err >&5
12525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12526   (exit $ac_status); } >/dev/null; then
12527   if test -s conftest.err; then
12528     ac_cpp_err=$ac_c_preproc_warn_flag
12529     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12530   else
12531     ac_cpp_err=
12532   fi
12533 else
12534   ac_cpp_err=yes
12535 fi
12536 if test -z "$ac_cpp_err"; then
12537   ac_header_preproc=yes
12538 else
12539   echo "$as_me: failed program was:" >&5
12540 sed 's/^/| /' conftest.$ac_ext >&5
12541
12542   ac_header_preproc=no
12543 fi
12544 rm -f conftest.err conftest.$ac_ext
12545 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12546 echo "${ECHO_T}$ac_header_preproc" >&6
12547
12548 # So?  What about this header?
12549 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12550   yes:no: )
12551     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12552 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12553     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12554 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12555     ac_header_preproc=yes
12556     ;;
12557   no:yes:* )
12558     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12559 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12560     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12561 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12562     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12563 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12564     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12565 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12566     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12567 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12568     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12569 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12570     (
12571       cat <<\_ASBOX
12572 ## ------------------------------------------ ##
12573 ## Report this to the AC_PACKAGE_NAME lists.  ##
12574 ## ------------------------------------------ ##
12575 _ASBOX
12576     ) |
12577       sed "s/^/$as_me: WARNING:     /" >&2
12578     ;;
12579 esac
12580 echo "$as_me:$LINENO: checking for $ac_header" >&5
12581 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12582 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12583   echo $ECHO_N "(cached) $ECHO_C" >&6
12584 else
12585   eval "$as_ac_Header=\$ac_header_preproc"
12586 fi
12587 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12588 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12589
12590 fi
12591 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12592   cat >>confdefs.h <<_ACEOF
12593 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12594 _ACEOF
12595
12596 fi
12597
12598 done
12599
12600
12601 for ac_header in link.h
12602 do
12603 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12604 echo "$as_me:$LINENO: checking for $ac_header" >&5
12605 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12606 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12607   echo $ECHO_N "(cached) $ECHO_C" >&6
12608 else
12609   cat >conftest.$ac_ext <<_ACEOF
12610 /* confdefs.h.  */
12611 _ACEOF
12612 cat confdefs.h >>conftest.$ac_ext
12613 cat >>conftest.$ac_ext <<_ACEOF
12614 /* end confdefs.h.  */
12615 #if HAVE_SYS_TYPES_H
12616 # include <sys/types.h>
12617 #endif
12618 #if HAVE_NLIST_H
12619 # include <nlist.h>
12620 #endif
12621
12622
12623 #include <$ac_header>
12624 _ACEOF
12625 rm -f conftest.$ac_objext
12626 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12627   (eval $ac_compile) 2>conftest.er1
12628   ac_status=$?
12629   grep -v '^ *+' conftest.er1 >conftest.err
12630   rm -f conftest.er1
12631   cat conftest.err >&5
12632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12633   (exit $ac_status); } &&
12634          { ac_try='test -z "$ac_c_werror_flag"
12635                          || test ! -s conftest.err'
12636   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12637   (eval $ac_try) 2>&5
12638   ac_status=$?
12639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12640   (exit $ac_status); }; } &&
12641          { ac_try='test -s conftest.$ac_objext'
12642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12643   (eval $ac_try) 2>&5
12644   ac_status=$?
12645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12646   (exit $ac_status); }; }; then
12647   eval "$as_ac_Header=yes"
12648 else
12649   echo "$as_me: failed program was:" >&5
12650 sed 's/^/| /' conftest.$ac_ext >&5
12651
12652 eval "$as_ac_Header=no"
12653 fi
12654 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12655 fi
12656 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12657 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12658 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12659   cat >>confdefs.h <<_ACEOF
12660 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12661 _ACEOF
12662
12663 fi
12664
12665 done
12666
12667
12668 for ac_header in sys/proc.h
12669 do
12670 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12671 echo "$as_me:$LINENO: checking for $ac_header" >&5
12672 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12673 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12674   echo $ECHO_N "(cached) $ECHO_C" >&6
12675 else
12676   cat >conftest.$ac_ext <<_ACEOF
12677 /* confdefs.h.  */
12678 _ACEOF
12679 cat confdefs.h >>conftest.$ac_ext
12680 cat >>conftest.$ac_ext <<_ACEOF
12681 /* end confdefs.h.  */
12682 #if HAVE_SYS_PARAM_H
12683 # include <sys/param.h>
12684 #endif
12685
12686
12687 #include <$ac_header>
12688 _ACEOF
12689 rm -f conftest.$ac_objext
12690 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12691   (eval $ac_compile) 2>conftest.er1
12692   ac_status=$?
12693   grep -v '^ *+' conftest.er1 >conftest.err
12694   rm -f conftest.er1
12695   cat conftest.err >&5
12696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12697   (exit $ac_status); } &&
12698          { ac_try='test -z "$ac_c_werror_flag"
12699                          || test ! -s conftest.err'
12700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12701   (eval $ac_try) 2>&5
12702   ac_status=$?
12703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12704   (exit $ac_status); }; } &&
12705          { ac_try='test -s conftest.$ac_objext'
12706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12707   (eval $ac_try) 2>&5
12708   ac_status=$?
12709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12710   (exit $ac_status); }; }; then
12711   eval "$as_ac_Header=yes"
12712 else
12713   echo "$as_me: failed program was:" >&5
12714 sed 's/^/| /' conftest.$ac_ext >&5
12715
12716 eval "$as_ac_Header=no"
12717 fi
12718 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12719 fi
12720 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12721 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12722 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12723   cat >>confdefs.h <<_ACEOF
12724 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12725 _ACEOF
12726
12727 fi
12728
12729 done
12730
12731
12732 for ac_header in sys/user.h
12733 do
12734 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12735 echo "$as_me:$LINENO: checking for $ac_header" >&5
12736 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12737 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12738   echo $ECHO_N "(cached) $ECHO_C" >&6
12739 else
12740   cat >conftest.$ac_ext <<_ACEOF
12741 /* confdefs.h.  */
12742 _ACEOF
12743 cat confdefs.h >>conftest.$ac_ext
12744 cat >>conftest.$ac_ext <<_ACEOF
12745 /* end confdefs.h.  */
12746 #if HAVE_SYS_PARAM_H
12747 # include <sys/param.h>
12748 #endif
12749
12750
12751 #include <$ac_header>
12752 _ACEOF
12753 rm -f conftest.$ac_objext
12754 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12755   (eval $ac_compile) 2>conftest.er1
12756   ac_status=$?
12757   grep -v '^ *+' conftest.er1 >conftest.err
12758   rm -f conftest.er1
12759   cat conftest.err >&5
12760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12761   (exit $ac_status); } &&
12762          { ac_try='test -z "$ac_c_werror_flag"
12763                          || test ! -s conftest.err'
12764   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12765   (eval $ac_try) 2>&5
12766   ac_status=$?
12767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12768   (exit $ac_status); }; } &&
12769          { ac_try='test -s conftest.$ac_objext'
12770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12771   (eval $ac_try) 2>&5
12772   ac_status=$?
12773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12774   (exit $ac_status); }; }; then
12775   eval "$as_ac_Header=yes"
12776 else
12777   echo "$as_me: failed program was:" >&5
12778 sed 's/^/| /' conftest.$ac_ext >&5
12779
12780 eval "$as_ac_Header=no"
12781 fi
12782 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12783 fi
12784 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12785 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12786 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12787   cat >>confdefs.h <<_ACEOF
12788 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12789 _ACEOF
12790
12791 fi
12792
12793 done
12794
12795
12796 # On Solaris 2.[789], we need to define _MSE_INT_H to avoid a clash
12797 # between <widec.h> and <wchar.h> that would cause AC_CHECK_HEADERS to
12798 # think that we don't have <curses.h> if we're using GCC.
12799 case $host_os in
12800   solaris2.[789])
12801     if test "$GCC" = yes; then
12802
12803 cat >>confdefs.h <<\_ACEOF
12804 #define _MSE_INT_H 1
12805 _ACEOF
12806
12807     fi ;;
12808 esac
12809
12810
12811
12812
12813
12814 for ac_header in curses.h cursesX.h ncurses.h ncurses/ncurses.h ncurses/term.h
12815 do
12816 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12817 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12818   echo "$as_me:$LINENO: checking for $ac_header" >&5
12819 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12820 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12821   echo $ECHO_N "(cached) $ECHO_C" >&6
12822 fi
12823 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12824 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12825 else
12826   # Is the header compilable?
12827 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12828 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12829 cat >conftest.$ac_ext <<_ACEOF
12830 /* confdefs.h.  */
12831 _ACEOF
12832 cat confdefs.h >>conftest.$ac_ext
12833 cat >>conftest.$ac_ext <<_ACEOF
12834 /* end confdefs.h.  */
12835 $ac_includes_default
12836 #include <$ac_header>
12837 _ACEOF
12838 rm -f conftest.$ac_objext
12839 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12840   (eval $ac_compile) 2>conftest.er1
12841   ac_status=$?
12842   grep -v '^ *+' conftest.er1 >conftest.err
12843   rm -f conftest.er1
12844   cat conftest.err >&5
12845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12846   (exit $ac_status); } &&
12847          { ac_try='test -z "$ac_c_werror_flag"
12848                          || test ! -s conftest.err'
12849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12850   (eval $ac_try) 2>&5
12851   ac_status=$?
12852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12853   (exit $ac_status); }; } &&
12854          { ac_try='test -s conftest.$ac_objext'
12855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12856   (eval $ac_try) 2>&5
12857   ac_status=$?
12858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12859   (exit $ac_status); }; }; then
12860   ac_header_compiler=yes
12861 else
12862   echo "$as_me: failed program was:" >&5
12863 sed 's/^/| /' conftest.$ac_ext >&5
12864
12865 ac_header_compiler=no
12866 fi
12867 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12868 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12869 echo "${ECHO_T}$ac_header_compiler" >&6
12870
12871 # Is the header present?
12872 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12873 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12874 cat >conftest.$ac_ext <<_ACEOF
12875 /* confdefs.h.  */
12876 _ACEOF
12877 cat confdefs.h >>conftest.$ac_ext
12878 cat >>conftest.$ac_ext <<_ACEOF
12879 /* end confdefs.h.  */
12880 #include <$ac_header>
12881 _ACEOF
12882 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12883   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12884   ac_status=$?
12885   grep -v '^ *+' conftest.er1 >conftest.err
12886   rm -f conftest.er1
12887   cat conftest.err >&5
12888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12889   (exit $ac_status); } >/dev/null; then
12890   if test -s conftest.err; then
12891     ac_cpp_err=$ac_c_preproc_warn_flag
12892     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12893   else
12894     ac_cpp_err=
12895   fi
12896 else
12897   ac_cpp_err=yes
12898 fi
12899 if test -z "$ac_cpp_err"; then
12900   ac_header_preproc=yes
12901 else
12902   echo "$as_me: failed program was:" >&5
12903 sed 's/^/| /' conftest.$ac_ext >&5
12904
12905   ac_header_preproc=no
12906 fi
12907 rm -f conftest.err conftest.$ac_ext
12908 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12909 echo "${ECHO_T}$ac_header_preproc" >&6
12910
12911 # So?  What about this header?
12912 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12913   yes:no: )
12914     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12915 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12916     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12917 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12918     ac_header_preproc=yes
12919     ;;
12920   no:yes:* )
12921     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12922 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12923     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12924 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12925     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12926 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12927     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12928 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12929     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12930 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12931     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12932 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12933     (
12934       cat <<\_ASBOX
12935 ## ------------------------------------------ ##
12936 ## Report this to the AC_PACKAGE_NAME lists.  ##
12937 ## ------------------------------------------ ##
12938 _ASBOX
12939     ) |
12940       sed "s/^/$as_me: WARNING:     /" >&2
12941     ;;
12942 esac
12943 echo "$as_me:$LINENO: checking for $ac_header" >&5
12944 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12946   echo $ECHO_N "(cached) $ECHO_C" >&6
12947 else
12948   eval "$as_ac_Header=\$ac_header_preproc"
12949 fi
12950 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12951 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12952
12953 fi
12954 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12955   cat >>confdefs.h <<_ACEOF
12956 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12957 _ACEOF
12958
12959 fi
12960
12961 done
12962
12963
12964 for ac_header in term.h
12965 do
12966 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12967 echo "$as_me:$LINENO: checking for $ac_header" >&5
12968 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12969 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12970   echo $ECHO_N "(cached) $ECHO_C" >&6
12971 else
12972   cat >conftest.$ac_ext <<_ACEOF
12973 /* confdefs.h.  */
12974 _ACEOF
12975 cat confdefs.h >>conftest.$ac_ext
12976 cat >>conftest.$ac_ext <<_ACEOF
12977 /* end confdefs.h.  */
12978 #if HAVE_CURSES_H
12979 # include <curses.h>
12980 #endif
12981
12982
12983 #include <$ac_header>
12984 _ACEOF
12985 rm -f conftest.$ac_objext
12986 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12987   (eval $ac_compile) 2>conftest.er1
12988   ac_status=$?
12989   grep -v '^ *+' conftest.er1 >conftest.err
12990   rm -f conftest.er1
12991   cat conftest.err >&5
12992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12993   (exit $ac_status); } &&
12994          { ac_try='test -z "$ac_c_werror_flag"
12995                          || test ! -s conftest.err'
12996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12997   (eval $ac_try) 2>&5
12998   ac_status=$?
12999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13000   (exit $ac_status); }; } &&
13001          { ac_try='test -s conftest.$ac_objext'
13002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13003   (eval $ac_try) 2>&5
13004   ac_status=$?
13005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13006   (exit $ac_status); }; }; then
13007   eval "$as_ac_Header=yes"
13008 else
13009   echo "$as_me: failed program was:" >&5
13010 sed 's/^/| /' conftest.$ac_ext >&5
13011
13012 eval "$as_ac_Header=no"
13013 fi
13014 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13015 fi
13016 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13017 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13018 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13019   cat >>confdefs.h <<_ACEOF
13020 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13021 _ACEOF
13022
13023 fi
13024
13025 done
13026
13027
13028 # ------------------------- #
13029 # Checks for declarations.  #
13030 # ------------------------- #
13031
13032 echo "$as_me:$LINENO: checking whether free is declared" >&5
13033 echo $ECHO_N "checking whether free is declared... $ECHO_C" >&6
13034 if test "${ac_cv_have_decl_free+set}" = set; then
13035   echo $ECHO_N "(cached) $ECHO_C" >&6
13036 else
13037   cat >conftest.$ac_ext <<_ACEOF
13038 /* confdefs.h.  */
13039 _ACEOF
13040 cat confdefs.h >>conftest.$ac_ext
13041 cat >>conftest.$ac_ext <<_ACEOF
13042 /* end confdefs.h.  */
13043 $ac_includes_default
13044 int
13045 main ()
13046 {
13047 #ifndef free
13048   char *p = (char *) free;
13049 #endif
13050
13051   ;
13052   return 0;
13053 }
13054 _ACEOF
13055 rm -f conftest.$ac_objext
13056 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13057   (eval $ac_compile) 2>conftest.er1
13058   ac_status=$?
13059   grep -v '^ *+' conftest.er1 >conftest.err
13060   rm -f conftest.er1
13061   cat conftest.err >&5
13062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13063   (exit $ac_status); } &&
13064          { ac_try='test -z "$ac_c_werror_flag"
13065                          || test ! -s conftest.err'
13066   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13067   (eval $ac_try) 2>&5
13068   ac_status=$?
13069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13070   (exit $ac_status); }; } &&
13071          { ac_try='test -s conftest.$ac_objext'
13072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13073   (eval $ac_try) 2>&5
13074   ac_status=$?
13075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13076   (exit $ac_status); }; }; then
13077   ac_cv_have_decl_free=yes
13078 else
13079   echo "$as_me: failed program was:" >&5
13080 sed 's/^/| /' conftest.$ac_ext >&5
13081
13082 ac_cv_have_decl_free=no
13083 fi
13084 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13085 fi
13086 echo "$as_me:$LINENO: result: $ac_cv_have_decl_free" >&5
13087 echo "${ECHO_T}$ac_cv_have_decl_free" >&6
13088 if test $ac_cv_have_decl_free = yes; then
13089
13090 cat >>confdefs.h <<_ACEOF
13091 #define HAVE_DECL_FREE 1
13092 _ACEOF
13093
13094
13095 else
13096   cat >>confdefs.h <<_ACEOF
13097 #define HAVE_DECL_FREE 0
13098 _ACEOF
13099
13100
13101 fi
13102 echo "$as_me:$LINENO: checking whether malloc is declared" >&5
13103 echo $ECHO_N "checking whether malloc is declared... $ECHO_C" >&6
13104 if test "${ac_cv_have_decl_malloc+set}" = set; then
13105   echo $ECHO_N "(cached) $ECHO_C" >&6
13106 else
13107   cat >conftest.$ac_ext <<_ACEOF
13108 /* confdefs.h.  */
13109 _ACEOF
13110 cat confdefs.h >>conftest.$ac_ext
13111 cat >>conftest.$ac_ext <<_ACEOF
13112 /* end confdefs.h.  */
13113 $ac_includes_default
13114 int
13115 main ()
13116 {
13117 #ifndef malloc
13118   char *p = (char *) malloc;
13119 #endif
13120
13121   ;
13122   return 0;
13123 }
13124 _ACEOF
13125 rm -f conftest.$ac_objext
13126 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13127   (eval $ac_compile) 2>conftest.er1
13128   ac_status=$?
13129   grep -v '^ *+' conftest.er1 >conftest.err
13130   rm -f conftest.er1
13131   cat conftest.err >&5
13132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13133   (exit $ac_status); } &&
13134          { ac_try='test -z "$ac_c_werror_flag"
13135                          || test ! -s conftest.err'
13136   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13137   (eval $ac_try) 2>&5
13138   ac_status=$?
13139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13140   (exit $ac_status); }; } &&
13141          { ac_try='test -s conftest.$ac_objext'
13142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13143   (eval $ac_try) 2>&5
13144   ac_status=$?
13145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13146   (exit $ac_status); }; }; then
13147   ac_cv_have_decl_malloc=yes
13148 else
13149   echo "$as_me: failed program was:" >&5
13150 sed 's/^/| /' conftest.$ac_ext >&5
13151
13152 ac_cv_have_decl_malloc=no
13153 fi
13154 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13155 fi
13156 echo "$as_me:$LINENO: result: $ac_cv_have_decl_malloc" >&5
13157 echo "${ECHO_T}$ac_cv_have_decl_malloc" >&6
13158 if test $ac_cv_have_decl_malloc = yes; then
13159
13160 cat >>confdefs.h <<_ACEOF
13161 #define HAVE_DECL_MALLOC 1
13162 _ACEOF
13163
13164
13165 else
13166   cat >>confdefs.h <<_ACEOF
13167 #define HAVE_DECL_MALLOC 0
13168 _ACEOF
13169
13170
13171 fi
13172 echo "$as_me:$LINENO: checking whether realloc is declared" >&5
13173 echo $ECHO_N "checking whether realloc is declared... $ECHO_C" >&6
13174 if test "${ac_cv_have_decl_realloc+set}" = set; then
13175   echo $ECHO_N "(cached) $ECHO_C" >&6
13176 else
13177   cat >conftest.$ac_ext <<_ACEOF
13178 /* confdefs.h.  */
13179 _ACEOF
13180 cat confdefs.h >>conftest.$ac_ext
13181 cat >>conftest.$ac_ext <<_ACEOF
13182 /* end confdefs.h.  */
13183 $ac_includes_default
13184 int
13185 main ()
13186 {
13187 #ifndef realloc
13188   char *p = (char *) realloc;
13189 #endif
13190
13191   ;
13192   return 0;
13193 }
13194 _ACEOF
13195 rm -f conftest.$ac_objext
13196 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13197   (eval $ac_compile) 2>conftest.er1
13198   ac_status=$?
13199   grep -v '^ *+' conftest.er1 >conftest.err
13200   rm -f conftest.er1
13201   cat conftest.err >&5
13202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13203   (exit $ac_status); } &&
13204          { ac_try='test -z "$ac_c_werror_flag"
13205                          || test ! -s conftest.err'
13206   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13207   (eval $ac_try) 2>&5
13208   ac_status=$?
13209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13210   (exit $ac_status); }; } &&
13211          { ac_try='test -s conftest.$ac_objext'
13212   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13213   (eval $ac_try) 2>&5
13214   ac_status=$?
13215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13216   (exit $ac_status); }; }; then
13217   ac_cv_have_decl_realloc=yes
13218 else
13219   echo "$as_me: failed program was:" >&5
13220 sed 's/^/| /' conftest.$ac_ext >&5
13221
13222 ac_cv_have_decl_realloc=no
13223 fi
13224 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13225 fi
13226 echo "$as_me:$LINENO: result: $ac_cv_have_decl_realloc" >&5
13227 echo "${ECHO_T}$ac_cv_have_decl_realloc" >&6
13228 if test $ac_cv_have_decl_realloc = yes; then
13229
13230 cat >>confdefs.h <<_ACEOF
13231 #define HAVE_DECL_REALLOC 1
13232 _ACEOF
13233
13234
13235 else
13236   cat >>confdefs.h <<_ACEOF
13237 #define HAVE_DECL_REALLOC 0
13238 _ACEOF
13239
13240
13241 fi
13242 echo "$as_me:$LINENO: checking whether strerror is declared" >&5
13243 echo $ECHO_N "checking whether strerror is declared... $ECHO_C" >&6
13244 if test "${ac_cv_have_decl_strerror+set}" = set; then
13245   echo $ECHO_N "(cached) $ECHO_C" >&6
13246 else
13247   cat >conftest.$ac_ext <<_ACEOF
13248 /* confdefs.h.  */
13249 _ACEOF
13250 cat confdefs.h >>conftest.$ac_ext
13251 cat >>conftest.$ac_ext <<_ACEOF
13252 /* end confdefs.h.  */
13253 $ac_includes_default
13254 int
13255 main ()
13256 {
13257 #ifndef strerror
13258   char *p = (char *) strerror;
13259 #endif
13260
13261   ;
13262   return 0;
13263 }
13264 _ACEOF
13265 rm -f conftest.$ac_objext
13266 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13267   (eval $ac_compile) 2>conftest.er1
13268   ac_status=$?
13269   grep -v '^ *+' conftest.er1 >conftest.err
13270   rm -f conftest.er1
13271   cat conftest.err >&5
13272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13273   (exit $ac_status); } &&
13274          { ac_try='test -z "$ac_c_werror_flag"
13275                          || test ! -s conftest.err'
13276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13277   (eval $ac_try) 2>&5
13278   ac_status=$?
13279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13280   (exit $ac_status); }; } &&
13281          { ac_try='test -s conftest.$ac_objext'
13282   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13283   (eval $ac_try) 2>&5
13284   ac_status=$?
13285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13286   (exit $ac_status); }; }; then
13287   ac_cv_have_decl_strerror=yes
13288 else
13289   echo "$as_me: failed program was:" >&5
13290 sed 's/^/| /' conftest.$ac_ext >&5
13291
13292 ac_cv_have_decl_strerror=no
13293 fi
13294 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13295 fi
13296 echo "$as_me:$LINENO: result: $ac_cv_have_decl_strerror" >&5
13297 echo "${ECHO_T}$ac_cv_have_decl_strerror" >&6
13298 if test $ac_cv_have_decl_strerror = yes; then
13299
13300 cat >>confdefs.h <<_ACEOF
13301 #define HAVE_DECL_STRERROR 1
13302 _ACEOF
13303
13304
13305 else
13306   cat >>confdefs.h <<_ACEOF
13307 #define HAVE_DECL_STRERROR 0
13308 _ACEOF
13309
13310
13311 fi
13312 echo "$as_me:$LINENO: checking whether strstr is declared" >&5
13313 echo $ECHO_N "checking whether strstr is declared... $ECHO_C" >&6
13314 if test "${ac_cv_have_decl_strstr+set}" = set; then
13315   echo $ECHO_N "(cached) $ECHO_C" >&6
13316 else
13317   cat >conftest.$ac_ext <<_ACEOF
13318 /* confdefs.h.  */
13319 _ACEOF
13320 cat confdefs.h >>conftest.$ac_ext
13321 cat >>conftest.$ac_ext <<_ACEOF
13322 /* end confdefs.h.  */
13323 $ac_includes_default
13324 int
13325 main ()
13326 {
13327 #ifndef strstr
13328   char *p = (char *) strstr;
13329 #endif
13330
13331   ;
13332   return 0;
13333 }
13334 _ACEOF
13335 rm -f conftest.$ac_objext
13336 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13337   (eval $ac_compile) 2>conftest.er1
13338   ac_status=$?
13339   grep -v '^ *+' conftest.er1 >conftest.err
13340   rm -f conftest.er1
13341   cat conftest.err >&5
13342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13343   (exit $ac_status); } &&
13344          { ac_try='test -z "$ac_c_werror_flag"
13345                          || test ! -s conftest.err'
13346   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13347   (eval $ac_try) 2>&5
13348   ac_status=$?
13349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13350   (exit $ac_status); }; } &&
13351          { ac_try='test -s conftest.$ac_objext'
13352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13353   (eval $ac_try) 2>&5
13354   ac_status=$?
13355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13356   (exit $ac_status); }; }; then
13357   ac_cv_have_decl_strstr=yes
13358 else
13359   echo "$as_me: failed program was:" >&5
13360 sed 's/^/| /' conftest.$ac_ext >&5
13361
13362 ac_cv_have_decl_strstr=no
13363 fi
13364 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13365 fi
13366 echo "$as_me:$LINENO: result: $ac_cv_have_decl_strstr" >&5
13367 echo "${ECHO_T}$ac_cv_have_decl_strstr" >&6
13368 if test $ac_cv_have_decl_strstr = yes; then
13369
13370 cat >>confdefs.h <<_ACEOF
13371 #define HAVE_DECL_STRSTR 1
13372 _ACEOF
13373
13374
13375 else
13376   cat >>confdefs.h <<_ACEOF
13377 #define HAVE_DECL_STRSTR 0
13378 _ACEOF
13379
13380
13381 fi
13382 echo "$as_me:$LINENO: checking whether getopt is declared" >&5
13383 echo $ECHO_N "checking whether getopt is declared... $ECHO_C" >&6
13384 if test "${ac_cv_have_decl_getopt+set}" = set; then
13385   echo $ECHO_N "(cached) $ECHO_C" >&6
13386 else
13387   cat >conftest.$ac_ext <<_ACEOF
13388 /* confdefs.h.  */
13389 _ACEOF
13390 cat confdefs.h >>conftest.$ac_ext
13391 cat >>conftest.$ac_ext <<_ACEOF
13392 /* end confdefs.h.  */
13393 $ac_includes_default
13394 int
13395 main ()
13396 {
13397 #ifndef getopt
13398   char *p = (char *) getopt;
13399 #endif
13400
13401   ;
13402   return 0;
13403 }
13404 _ACEOF
13405 rm -f conftest.$ac_objext
13406 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13407   (eval $ac_compile) 2>conftest.er1
13408   ac_status=$?
13409   grep -v '^ *+' conftest.er1 >conftest.err
13410   rm -f conftest.er1
13411   cat conftest.err >&5
13412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13413   (exit $ac_status); } &&
13414          { ac_try='test -z "$ac_c_werror_flag"
13415                          || test ! -s conftest.err'
13416   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13417   (eval $ac_try) 2>&5
13418   ac_status=$?
13419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13420   (exit $ac_status); }; } &&
13421          { ac_try='test -s conftest.$ac_objext'
13422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13423   (eval $ac_try) 2>&5
13424   ac_status=$?
13425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13426   (exit $ac_status); }; }; then
13427   ac_cv_have_decl_getopt=yes
13428 else
13429   echo "$as_me: failed program was:" >&5
13430 sed 's/^/| /' conftest.$ac_ext >&5
13431
13432 ac_cv_have_decl_getopt=no
13433 fi
13434 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13435 fi
13436 echo "$as_me:$LINENO: result: $ac_cv_have_decl_getopt" >&5
13437 echo "${ECHO_T}$ac_cv_have_decl_getopt" >&6
13438 if test $ac_cv_have_decl_getopt = yes; then
13439
13440 cat >>confdefs.h <<_ACEOF
13441 #define HAVE_DECL_GETOPT 1
13442 _ACEOF
13443
13444
13445 else
13446   cat >>confdefs.h <<_ACEOF
13447 #define HAVE_DECL_GETOPT 0
13448 _ACEOF
13449
13450
13451 fi
13452 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
13453 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
13454 if test "${ac_cv_have_decl_snprintf+set}" = set; then
13455   echo $ECHO_N "(cached) $ECHO_C" >&6
13456 else
13457   cat >conftest.$ac_ext <<_ACEOF
13458 /* confdefs.h.  */
13459 _ACEOF
13460 cat confdefs.h >>conftest.$ac_ext
13461 cat >>conftest.$ac_ext <<_ACEOF
13462 /* end confdefs.h.  */
13463 $ac_includes_default
13464 int
13465 main ()
13466 {
13467 #ifndef snprintf
13468   char *p = (char *) snprintf;
13469 #endif
13470
13471   ;
13472   return 0;
13473 }
13474 _ACEOF
13475 rm -f conftest.$ac_objext
13476 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13477   (eval $ac_compile) 2>conftest.er1
13478   ac_status=$?
13479   grep -v '^ *+' conftest.er1 >conftest.err
13480   rm -f conftest.er1
13481   cat conftest.err >&5
13482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13483   (exit $ac_status); } &&
13484          { ac_try='test -z "$ac_c_werror_flag"
13485                          || test ! -s conftest.err'
13486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13487   (eval $ac_try) 2>&5
13488   ac_status=$?
13489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13490   (exit $ac_status); }; } &&
13491          { ac_try='test -s conftest.$ac_objext'
13492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13493   (eval $ac_try) 2>&5
13494   ac_status=$?
13495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13496   (exit $ac_status); }; }; then
13497   ac_cv_have_decl_snprintf=yes
13498 else
13499   echo "$as_me: failed program was:" >&5
13500 sed 's/^/| /' conftest.$ac_ext >&5
13501
13502 ac_cv_have_decl_snprintf=no
13503 fi
13504 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13505 fi
13506 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
13507 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
13508 if test $ac_cv_have_decl_snprintf = yes; then
13509
13510 cat >>confdefs.h <<_ACEOF
13511 #define HAVE_DECL_SNPRINTF 1
13512 _ACEOF
13513
13514
13515 else
13516   cat >>confdefs.h <<_ACEOF
13517 #define HAVE_DECL_SNPRINTF 0
13518 _ACEOF
13519
13520
13521 fi
13522 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
13523 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
13524 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
13525   echo $ECHO_N "(cached) $ECHO_C" >&6
13526 else
13527   cat >conftest.$ac_ext <<_ACEOF
13528 /* confdefs.h.  */
13529 _ACEOF
13530 cat confdefs.h >>conftest.$ac_ext
13531 cat >>conftest.$ac_ext <<_ACEOF
13532 /* end confdefs.h.  */
13533 $ac_includes_default
13534 int
13535 main ()
13536 {
13537 #ifndef vsnprintf
13538   char *p = (char *) vsnprintf;
13539 #endif
13540
13541   ;
13542   return 0;
13543 }
13544 _ACEOF
13545 rm -f conftest.$ac_objext
13546 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13547   (eval $ac_compile) 2>conftest.er1
13548   ac_status=$?
13549   grep -v '^ *+' conftest.er1 >conftest.err
13550   rm -f conftest.er1
13551   cat conftest.err >&5
13552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13553   (exit $ac_status); } &&
13554          { ac_try='test -z "$ac_c_werror_flag"
13555                          || test ! -s conftest.err'
13556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13557   (eval $ac_try) 2>&5
13558   ac_status=$?
13559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13560   (exit $ac_status); }; } &&
13561          { ac_try='test -s conftest.$ac_objext'
13562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13563   (eval $ac_try) 2>&5
13564   ac_status=$?
13565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13566   (exit $ac_status); }; }; then
13567   ac_cv_have_decl_vsnprintf=yes
13568 else
13569   echo "$as_me: failed program was:" >&5
13570 sed 's/^/| /' conftest.$ac_ext >&5
13571
13572 ac_cv_have_decl_vsnprintf=no
13573 fi
13574 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13575 fi
13576 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
13577 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
13578 if test $ac_cv_have_decl_vsnprintf = yes; then
13579
13580 cat >>confdefs.h <<_ACEOF
13581 #define HAVE_DECL_VSNPRINTF 1
13582 _ACEOF
13583
13584
13585 else
13586   cat >>confdefs.h <<_ACEOF
13587 #define HAVE_DECL_VSNPRINTF 0
13588 _ACEOF
13589
13590
13591 fi
13592
13593
13594
13595   echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5
13596 echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6
13597 if test "${am_cv_val_LC_MESSAGES+set}" = set; then
13598   echo $ECHO_N "(cached) $ECHO_C" >&6
13599 else
13600   cat >conftest.$ac_ext <<_ACEOF
13601 /* confdefs.h.  */
13602 _ACEOF
13603 cat confdefs.h >>conftest.$ac_ext
13604 cat >>conftest.$ac_ext <<_ACEOF
13605 /* end confdefs.h.  */
13606 #include <locale.h>
13607 int
13608 main ()
13609 {
13610 return LC_MESSAGES
13611   ;
13612   return 0;
13613 }
13614 _ACEOF
13615 rm -f conftest.$ac_objext conftest$ac_exeext
13616 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13617   (eval $ac_link) 2>conftest.er1
13618   ac_status=$?
13619   grep -v '^ *+' conftest.er1 >conftest.err
13620   rm -f conftest.er1
13621   cat conftest.err >&5
13622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13623   (exit $ac_status); } &&
13624          { ac_try='test -z "$ac_c_werror_flag"
13625                          || test ! -s conftest.err'
13626   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13627   (eval $ac_try) 2>&5
13628   ac_status=$?
13629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13630   (exit $ac_status); }; } &&
13631          { ac_try='test -s conftest$ac_exeext'
13632   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13633   (eval $ac_try) 2>&5
13634   ac_status=$?
13635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13636   (exit $ac_status); }; }; then
13637   am_cv_val_LC_MESSAGES=yes
13638 else
13639   echo "$as_me: failed program was:" >&5
13640 sed 's/^/| /' conftest.$ac_ext >&5
13641
13642 am_cv_val_LC_MESSAGES=no
13643 fi
13644 rm -f conftest.err conftest.$ac_objext \
13645       conftest$ac_exeext conftest.$ac_ext
13646 fi
13647 echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5
13648 echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6
13649   if test $am_cv_val_LC_MESSAGES = yes; then
13650
13651 cat >>confdefs.h <<\_ACEOF
13652 #define HAVE_LC_MESSAGES 1
13653 _ACEOF
13654
13655   fi
13656
13657
13658 # ----------------------- #
13659 # Checks for structures.  #
13660 # ----------------------- #
13661
13662 echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
13663 echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
13664 if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
13665   echo $ECHO_N "(cached) $ECHO_C" >&6
13666 else
13667   cat >conftest.$ac_ext <<_ACEOF
13668 /* confdefs.h.  */
13669 _ACEOF
13670 cat confdefs.h >>conftest.$ac_ext
13671 cat >>conftest.$ac_ext <<_ACEOF
13672 /* end confdefs.h.  */
13673 $ac_includes_default
13674 int
13675 main ()
13676 {
13677 static struct stat ac_aggr;
13678 if (ac_aggr.st_blocks)
13679 return 0;
13680   ;
13681   return 0;
13682 }
13683 _ACEOF
13684 rm -f conftest.$ac_objext
13685 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13686   (eval $ac_compile) 2>conftest.er1
13687   ac_status=$?
13688   grep -v '^ *+' conftest.er1 >conftest.err
13689   rm -f conftest.er1
13690   cat conftest.err >&5
13691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13692   (exit $ac_status); } &&
13693          { ac_try='test -z "$ac_c_werror_flag"
13694                          || test ! -s conftest.err'
13695   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13696   (eval $ac_try) 2>&5
13697   ac_status=$?
13698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13699   (exit $ac_status); }; } &&
13700          { ac_try='test -s conftest.$ac_objext'
13701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13702   (eval $ac_try) 2>&5
13703   ac_status=$?
13704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13705   (exit $ac_status); }; }; then
13706   ac_cv_member_struct_stat_st_blocks=yes
13707 else
13708   echo "$as_me: failed program was:" >&5
13709 sed 's/^/| /' conftest.$ac_ext >&5
13710
13711 cat >conftest.$ac_ext <<_ACEOF
13712 /* confdefs.h.  */
13713 _ACEOF
13714 cat confdefs.h >>conftest.$ac_ext
13715 cat >>conftest.$ac_ext <<_ACEOF
13716 /* end confdefs.h.  */
13717 $ac_includes_default
13718 int
13719 main ()
13720 {
13721 static struct stat ac_aggr;
13722 if (sizeof ac_aggr.st_blocks)
13723 return 0;
13724   ;
13725   return 0;
13726 }
13727 _ACEOF
13728 rm -f conftest.$ac_objext
13729 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13730   (eval $ac_compile) 2>conftest.er1
13731   ac_status=$?
13732   grep -v '^ *+' conftest.er1 >conftest.err
13733   rm -f conftest.er1
13734   cat conftest.err >&5
13735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13736   (exit $ac_status); } &&
13737          { ac_try='test -z "$ac_c_werror_flag"
13738                          || test ! -s conftest.err'
13739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13740   (eval $ac_try) 2>&5
13741   ac_status=$?
13742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13743   (exit $ac_status); }; } &&
13744          { ac_try='test -s conftest.$ac_objext'
13745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13746   (eval $ac_try) 2>&5
13747   ac_status=$?
13748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13749   (exit $ac_status); }; }; then
13750   ac_cv_member_struct_stat_st_blocks=yes
13751 else
13752   echo "$as_me: failed program was:" >&5
13753 sed 's/^/| /' conftest.$ac_ext >&5
13754
13755 ac_cv_member_struct_stat_st_blocks=no
13756 fi
13757 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13758 fi
13759 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13760 fi
13761 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
13762 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
13763 if test $ac_cv_member_struct_stat_st_blocks = yes; then
13764
13765 cat >>confdefs.h <<_ACEOF
13766 #define HAVE_STRUCT_STAT_ST_BLOCKS 1
13767 _ACEOF
13768
13769
13770 fi
13771 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
13772 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
13773 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
13774   echo $ECHO_N "(cached) $ECHO_C" >&6
13775 else
13776   cat >conftest.$ac_ext <<_ACEOF
13777 /* confdefs.h.  */
13778 _ACEOF
13779 cat confdefs.h >>conftest.$ac_ext
13780 cat >>conftest.$ac_ext <<_ACEOF
13781 /* end confdefs.h.  */
13782 $ac_includes_default
13783 int
13784 main ()
13785 {
13786 static struct stat ac_aggr;
13787 if (ac_aggr.st_blksize)
13788 return 0;
13789   ;
13790   return 0;
13791 }
13792 _ACEOF
13793 rm -f conftest.$ac_objext
13794 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13795   (eval $ac_compile) 2>conftest.er1
13796   ac_status=$?
13797   grep -v '^ *+' conftest.er1 >conftest.err
13798   rm -f conftest.er1
13799   cat conftest.err >&5
13800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13801   (exit $ac_status); } &&
13802          { ac_try='test -z "$ac_c_werror_flag"
13803                          || test ! -s conftest.err'
13804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13805   (eval $ac_try) 2>&5
13806   ac_status=$?
13807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13808   (exit $ac_status); }; } &&
13809          { ac_try='test -s conftest.$ac_objext'
13810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13811   (eval $ac_try) 2>&5
13812   ac_status=$?
13813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13814   (exit $ac_status); }; }; then
13815   ac_cv_member_struct_stat_st_blksize=yes
13816 else
13817   echo "$as_me: failed program was:" >&5
13818 sed 's/^/| /' conftest.$ac_ext >&5
13819
13820 cat >conftest.$ac_ext <<_ACEOF
13821 /* confdefs.h.  */
13822 _ACEOF
13823 cat confdefs.h >>conftest.$ac_ext
13824 cat >>conftest.$ac_ext <<_ACEOF
13825 /* end confdefs.h.  */
13826 $ac_includes_default
13827 int
13828 main ()
13829 {
13830 static struct stat ac_aggr;
13831 if (sizeof ac_aggr.st_blksize)
13832 return 0;
13833   ;
13834   return 0;
13835 }
13836 _ACEOF
13837 rm -f conftest.$ac_objext
13838 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13839   (eval $ac_compile) 2>conftest.er1
13840   ac_status=$?
13841   grep -v '^ *+' conftest.er1 >conftest.err
13842   rm -f conftest.er1
13843   cat conftest.err >&5
13844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13845   (exit $ac_status); } &&
13846          { ac_try='test -z "$ac_c_werror_flag"
13847                          || test ! -s conftest.err'
13848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13849   (eval $ac_try) 2>&5
13850   ac_status=$?
13851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13852   (exit $ac_status); }; } &&
13853          { ac_try='test -s conftest.$ac_objext'
13854   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13855   (eval $ac_try) 2>&5
13856   ac_status=$?
13857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13858   (exit $ac_status); }; }; then
13859   ac_cv_member_struct_stat_st_blksize=yes
13860 else
13861   echo "$as_me: failed program was:" >&5
13862 sed 's/^/| /' conftest.$ac_ext >&5
13863
13864 ac_cv_member_struct_stat_st_blksize=no
13865 fi
13866 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13867 fi
13868 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13869 fi
13870 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
13871 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
13872 if test $ac_cv_member_struct_stat_st_blksize = yes; then
13873
13874 cat >>confdefs.h <<_ACEOF
13875 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13876 _ACEOF
13877
13878
13879 fi
13880
13881
13882 # ------------------ #
13883 # Checks for types.  #
13884 # ------------------ #
13885
13886 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
13887 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
13888 if test "${ac_cv_type_signal+set}" = set; then
13889   echo $ECHO_N "(cached) $ECHO_C" >&6
13890 else
13891   cat >conftest.$ac_ext <<_ACEOF
13892 /* confdefs.h.  */
13893 _ACEOF
13894 cat confdefs.h >>conftest.$ac_ext
13895 cat >>conftest.$ac_ext <<_ACEOF
13896 /* end confdefs.h.  */
13897 #include <sys/types.h>
13898 #include <signal.h>
13899 #ifdef signal
13900 # undef signal
13901 #endif
13902 #ifdef __cplusplus
13903 extern "C" void (*signal (int, void (*)(int)))(int);
13904 #else
13905 void (*signal ()) ();
13906 #endif
13907
13908 int
13909 main ()
13910 {
13911 int i;
13912   ;
13913   return 0;
13914 }
13915 _ACEOF
13916 rm -f conftest.$ac_objext
13917 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13918   (eval $ac_compile) 2>conftest.er1
13919   ac_status=$?
13920   grep -v '^ *+' conftest.er1 >conftest.err
13921   rm -f conftest.er1
13922   cat conftest.err >&5
13923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13924   (exit $ac_status); } &&
13925          { ac_try='test -z "$ac_c_werror_flag"
13926                          || test ! -s conftest.err'
13927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13928   (eval $ac_try) 2>&5
13929   ac_status=$?
13930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13931   (exit $ac_status); }; } &&
13932          { ac_try='test -s conftest.$ac_objext'
13933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13934   (eval $ac_try) 2>&5
13935   ac_status=$?
13936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13937   (exit $ac_status); }; }; then
13938   ac_cv_type_signal=void
13939 else
13940   echo "$as_me: failed program was:" >&5
13941 sed 's/^/| /' conftest.$ac_ext >&5
13942
13943 ac_cv_type_signal=int
13944 fi
13945 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13946 fi
13947 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
13948 echo "${ECHO_T}$ac_cv_type_signal" >&6
13949
13950 cat >>confdefs.h <<_ACEOF
13951 #define RETSIGTYPE $ac_cv_type_signal
13952 _ACEOF
13953
13954
13955 echo "$as_me:$LINENO: checking for socklen_t" >&5
13956 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
13957 if test "${ac_cv_type_socklen_t+set}" = set; then
13958   echo $ECHO_N "(cached) $ECHO_C" >&6
13959 else
13960   cat >conftest.$ac_ext <<_ACEOF
13961 /* confdefs.h.  */
13962 _ACEOF
13963 cat confdefs.h >>conftest.$ac_ext
13964 cat >>conftest.$ac_ext <<_ACEOF
13965 /* end confdefs.h.  */
13966 #include <sys/types.h>
13967 #include <sys/socket.h>
13968
13969
13970 int
13971 main ()
13972 {
13973 if ((socklen_t *) 0)
13974   return 0;
13975 if (sizeof (socklen_t))
13976   return 0;
13977   ;
13978   return 0;
13979 }
13980 _ACEOF
13981 rm -f conftest.$ac_objext
13982 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13983   (eval $ac_compile) 2>conftest.er1
13984   ac_status=$?
13985   grep -v '^ *+' conftest.er1 >conftest.err
13986   rm -f conftest.er1
13987   cat conftest.err >&5
13988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13989   (exit $ac_status); } &&
13990          { ac_try='test -z "$ac_c_werror_flag"
13991                          || test ! -s conftest.err'
13992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13993   (eval $ac_try) 2>&5
13994   ac_status=$?
13995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13996   (exit $ac_status); }; } &&
13997          { ac_try='test -s conftest.$ac_objext'
13998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13999   (eval $ac_try) 2>&5
14000   ac_status=$?
14001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14002   (exit $ac_status); }; }; then
14003   ac_cv_type_socklen_t=yes
14004 else
14005   echo "$as_me: failed program was:" >&5
14006 sed 's/^/| /' conftest.$ac_ext >&5
14007
14008 ac_cv_type_socklen_t=no
14009 fi
14010 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14011 fi
14012 echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
14013 echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
14014 if test $ac_cv_type_socklen_t = yes; then
14015
14016 cat >>confdefs.h <<_ACEOF
14017 #define HAVE_SOCKLEN_T 1
14018 _ACEOF
14019
14020
14021 fi
14022
14023
14024 # ------------------------------------- #
14025 # Checks for compiler characteristics.  #
14026 # ------------------------------------- #
14027
14028 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14029 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
14030 if test "${ac_cv_c_const+set}" = set; then
14031   echo $ECHO_N "(cached) $ECHO_C" >&6
14032 else
14033   cat >conftest.$ac_ext <<_ACEOF
14034 /* confdefs.h.  */
14035 _ACEOF
14036 cat confdefs.h >>conftest.$ac_ext
14037 cat >>conftest.$ac_ext <<_ACEOF
14038 /* end confdefs.h.  */
14039
14040 int
14041 main ()
14042 {
14043 /* FIXME: Include the comments suggested by Paul. */
14044 #ifndef __cplusplus
14045   /* Ultrix mips cc rejects this.  */
14046   typedef int charset[2];
14047   const charset x;
14048   /* SunOS 4.1.1 cc rejects this.  */
14049   char const *const *ccp;
14050   char **p;
14051   /* NEC SVR4.0.2 mips cc rejects this.  */
14052   struct point {int x, y;};
14053   static struct point const zero = {0,0};
14054   /* AIX XL C 1.02.0.0 rejects this.
14055      It does not let you subtract one const X* pointer from another in
14056      an arm of an if-expression whose if-part is not a constant
14057      expression */
14058   const char *g = "string";
14059   ccp = &g + (g ? g-g : 0);
14060   /* HPUX 7.0 cc rejects these. */
14061   ++ccp;
14062   p = (char**) ccp;
14063   ccp = (char const *const *) p;
14064   { /* SCO 3.2v4 cc rejects this.  */
14065     char *t;
14066     char const *s = 0 ? (char *) 0 : (char const *) 0;
14067
14068     *t++ = 0;
14069   }
14070   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14071     int x[] = {25, 17};
14072     const int *foo = &x[0];
14073     ++foo;
14074   }
14075   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14076     typedef const int *iptr;
14077     iptr p = 0;
14078     ++p;
14079   }
14080   { /* AIX XL C 1.02.0.0 rejects this saying
14081        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14082     struct s { int j; const int *ap[3]; };
14083     struct s *b; b->j = 5;
14084   }
14085   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14086     const int foo = 10;
14087   }
14088 #endif
14089
14090   ;
14091   return 0;
14092 }
14093 _ACEOF
14094 rm -f conftest.$ac_objext
14095 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14096   (eval $ac_compile) 2>conftest.er1
14097   ac_status=$?
14098   grep -v '^ *+' conftest.er1 >conftest.err
14099   rm -f conftest.er1
14100   cat conftest.err >&5
14101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14102   (exit $ac_status); } &&
14103          { ac_try='test -z "$ac_c_werror_flag"
14104                          || test ! -s conftest.err'
14105   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14106   (eval $ac_try) 2>&5
14107   ac_status=$?
14108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14109   (exit $ac_status); }; } &&
14110          { ac_try='test -s conftest.$ac_objext'
14111   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14112   (eval $ac_try) 2>&5
14113   ac_status=$?
14114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14115   (exit $ac_status); }; }; then
14116   ac_cv_c_const=yes
14117 else
14118   echo "$as_me: failed program was:" >&5
14119 sed 's/^/| /' conftest.$ac_ext >&5
14120
14121 ac_cv_c_const=no
14122 fi
14123 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14124 fi
14125 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14126 echo "${ECHO_T}$ac_cv_c_const" >&6
14127 if test $ac_cv_c_const = no; then
14128
14129 cat >>confdefs.h <<\_ACEOF
14130 #define const
14131 _ACEOF
14132
14133 fi
14134
14135 echo "$as_me:$LINENO: checking for inline" >&5
14136 echo $ECHO_N "checking for inline... $ECHO_C" >&6
14137 if test "${ac_cv_c_inline+set}" = set; then
14138   echo $ECHO_N "(cached) $ECHO_C" >&6
14139 else
14140   ac_cv_c_inline=no
14141 for ac_kw in inline __inline__ __inline; do
14142   cat >conftest.$ac_ext <<_ACEOF
14143 /* confdefs.h.  */
14144 _ACEOF
14145 cat confdefs.h >>conftest.$ac_ext
14146 cat >>conftest.$ac_ext <<_ACEOF
14147 /* end confdefs.h.  */
14148 #ifndef __cplusplus
14149 typedef int foo_t;
14150 static $ac_kw foo_t static_foo () {return 0; }
14151 $ac_kw foo_t foo () {return 0; }
14152 #endif
14153
14154 _ACEOF
14155 rm -f conftest.$ac_objext
14156 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14157   (eval $ac_compile) 2>conftest.er1
14158   ac_status=$?
14159   grep -v '^ *+' conftest.er1 >conftest.err
14160   rm -f conftest.er1
14161   cat conftest.err >&5
14162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14163   (exit $ac_status); } &&
14164          { ac_try='test -z "$ac_c_werror_flag"
14165                          || test ! -s conftest.err'
14166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14167   (eval $ac_try) 2>&5
14168   ac_status=$?
14169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14170   (exit $ac_status); }; } &&
14171          { ac_try='test -s conftest.$ac_objext'
14172   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14173   (eval $ac_try) 2>&5
14174   ac_status=$?
14175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14176   (exit $ac_status); }; }; then
14177   ac_cv_c_inline=$ac_kw; break
14178 else
14179   echo "$as_me: failed program was:" >&5
14180 sed 's/^/| /' conftest.$ac_ext >&5
14181
14182 fi
14183 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14184 done
14185
14186 fi
14187 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14188 echo "${ECHO_T}$ac_cv_c_inline" >&6
14189
14190
14191 case $ac_cv_c_inline in
14192   inline | yes) ;;
14193   *)
14194     case $ac_cv_c_inline in
14195       no) ac_val=;;
14196       *) ac_val=$ac_cv_c_inline;;
14197     esac
14198     cat >>confdefs.h <<_ACEOF
14199 #ifndef __cplusplus
14200 #define inline $ac_val
14201 #endif
14202 _ACEOF
14203     ;;
14204 esac
14205
14206 echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14207 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
14208 if test "${ac_cv_c_bigendian+set}" = set; then
14209   echo $ECHO_N "(cached) $ECHO_C" >&6
14210 else
14211   # See if sys/param.h defines the BYTE_ORDER macro.
14212 cat >conftest.$ac_ext <<_ACEOF
14213 /* confdefs.h.  */
14214 _ACEOF
14215 cat confdefs.h >>conftest.$ac_ext
14216 cat >>conftest.$ac_ext <<_ACEOF
14217 /* end confdefs.h.  */
14218 #include <sys/types.h>
14219 #include <sys/param.h>
14220
14221 int
14222 main ()
14223 {
14224 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
14225  bogus endian macros
14226 #endif
14227
14228   ;
14229   return 0;
14230 }
14231 _ACEOF
14232 rm -f conftest.$ac_objext
14233 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14234   (eval $ac_compile) 2>conftest.er1
14235   ac_status=$?
14236   grep -v '^ *+' conftest.er1 >conftest.err
14237   rm -f conftest.er1
14238   cat conftest.err >&5
14239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14240   (exit $ac_status); } &&
14241          { ac_try='test -z "$ac_c_werror_flag"
14242                          || test ! -s conftest.err'
14243   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14244   (eval $ac_try) 2>&5
14245   ac_status=$?
14246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14247   (exit $ac_status); }; } &&
14248          { ac_try='test -s conftest.$ac_objext'
14249   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14250   (eval $ac_try) 2>&5
14251   ac_status=$?
14252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14253   (exit $ac_status); }; }; then
14254   # It does; now see whether it defined to BIG_ENDIAN or not.
14255 cat >conftest.$ac_ext <<_ACEOF
14256 /* confdefs.h.  */
14257 _ACEOF
14258 cat confdefs.h >>conftest.$ac_ext
14259 cat >>conftest.$ac_ext <<_ACEOF
14260 /* end confdefs.h.  */
14261 #include <sys/types.h>
14262 #include <sys/param.h>
14263
14264 int
14265 main ()
14266 {
14267 #if BYTE_ORDER != BIG_ENDIAN
14268  not big endian
14269 #endif
14270
14271   ;
14272   return 0;
14273 }
14274 _ACEOF
14275 rm -f conftest.$ac_objext
14276 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14277   (eval $ac_compile) 2>conftest.er1
14278   ac_status=$?
14279   grep -v '^ *+' conftest.er1 >conftest.err
14280   rm -f conftest.er1
14281   cat conftest.err >&5
14282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14283   (exit $ac_status); } &&
14284          { ac_try='test -z "$ac_c_werror_flag"
14285                          || test ! -s conftest.err'
14286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14287   (eval $ac_try) 2>&5
14288   ac_status=$?
14289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14290   (exit $ac_status); }; } &&
14291          { ac_try='test -s conftest.$ac_objext'
14292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14293   (eval $ac_try) 2>&5
14294   ac_status=$?
14295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14296   (exit $ac_status); }; }; then
14297   ac_cv_c_bigendian=yes
14298 else
14299   echo "$as_me: failed program was:" >&5
14300 sed 's/^/| /' conftest.$ac_ext >&5
14301
14302 ac_cv_c_bigendian=no
14303 fi
14304 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14305 else
14306   echo "$as_me: failed program was:" >&5
14307 sed 's/^/| /' conftest.$ac_ext >&5
14308
14309 # It does not; compile a test program.
14310 if test "$cross_compiling" = yes; then
14311   # try to guess the endianness by grepping values into an object file
14312   ac_cv_c_bigendian=unknown
14313   cat >conftest.$ac_ext <<_ACEOF
14314 /* confdefs.h.  */
14315 _ACEOF
14316 cat confdefs.h >>conftest.$ac_ext
14317 cat >>conftest.$ac_ext <<_ACEOF
14318 /* end confdefs.h.  */
14319 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14320 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14321 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
14322 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14323 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14324 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
14325 int
14326 main ()
14327 {
14328  _ascii (); _ebcdic ();
14329   ;
14330   return 0;
14331 }
14332 _ACEOF
14333 rm -f conftest.$ac_objext
14334 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14335   (eval $ac_compile) 2>conftest.er1
14336   ac_status=$?
14337   grep -v '^ *+' conftest.er1 >conftest.err
14338   rm -f conftest.er1
14339   cat conftest.err >&5
14340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14341   (exit $ac_status); } &&
14342          { ac_try='test -z "$ac_c_werror_flag"
14343                          || test ! -s conftest.err'
14344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14345   (eval $ac_try) 2>&5
14346   ac_status=$?
14347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14348   (exit $ac_status); }; } &&
14349          { ac_try='test -s conftest.$ac_objext'
14350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14351   (eval $ac_try) 2>&5
14352   ac_status=$?
14353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14354   (exit $ac_status); }; }; then
14355   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
14356   ac_cv_c_bigendian=yes
14357 fi
14358 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14359   if test "$ac_cv_c_bigendian" = unknown; then
14360     ac_cv_c_bigendian=no
14361   else
14362     # finding both strings is unlikely to happen, but who knows?
14363     ac_cv_c_bigendian=unknown
14364   fi
14365 fi
14366 else
14367   echo "$as_me: failed program was:" >&5
14368 sed 's/^/| /' conftest.$ac_ext >&5
14369
14370 fi
14371 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14372 else
14373   cat >conftest.$ac_ext <<_ACEOF
14374 /* confdefs.h.  */
14375 _ACEOF
14376 cat confdefs.h >>conftest.$ac_ext
14377 cat >>conftest.$ac_ext <<_ACEOF
14378 /* end confdefs.h.  */
14379 int
14380 main ()
14381 {
14382   /* Are we little or big endian?  From Harbison&Steele.  */
14383   union
14384   {
14385     long l;
14386     char c[sizeof (long)];
14387   } u;
14388   u.l = 1;
14389   exit (u.c[sizeof (long) - 1] == 1);
14390 }
14391 _ACEOF
14392 rm -f conftest$ac_exeext
14393 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14394   (eval $ac_link) 2>&5
14395   ac_status=$?
14396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14397   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14398   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14399   (eval $ac_try) 2>&5
14400   ac_status=$?
14401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14402   (exit $ac_status); }; }; then
14403   ac_cv_c_bigendian=no
14404 else
14405   echo "$as_me: program exited with status $ac_status" >&5
14406 echo "$as_me: failed program was:" >&5
14407 sed 's/^/| /' conftest.$ac_ext >&5
14408
14409 ( exit $ac_status )
14410 ac_cv_c_bigendian=yes
14411 fi
14412 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14413 fi
14414 fi
14415 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14416 fi
14417 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14418 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
14419 case $ac_cv_c_bigendian in
14420   yes)
14421
14422 cat >>confdefs.h <<\_ACEOF
14423 #define WORDS_BIGENDIAN 1
14424 _ACEOF
14425  ;;
14426   no)
14427      ;;
14428   *)
14429     { { echo "$as_me:$LINENO: error: unknown endianness
14430 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14431 echo "$as_me: error: unknown endianness
14432 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14433    { (exit 1); exit 1; }; } ;;
14434 esac
14435
14436
14437 # ------------------------------ #
14438 # Checks for library functions.  #
14439 # ------------------------------ #
14440
14441 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
14442 # for constant arguments.  Useless!
14443 echo "$as_me:$LINENO: checking for working alloca.h" >&5
14444 echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
14445 if test "${ac_cv_working_alloca_h+set}" = set; then
14446   echo $ECHO_N "(cached) $ECHO_C" >&6
14447 else
14448   cat >conftest.$ac_ext <<_ACEOF
14449 /* confdefs.h.  */
14450 _ACEOF
14451 cat confdefs.h >>conftest.$ac_ext
14452 cat >>conftest.$ac_ext <<_ACEOF
14453 /* end confdefs.h.  */
14454 #include <alloca.h>
14455 int
14456 main ()
14457 {
14458 char *p = (char *) alloca (2 * sizeof (int));
14459   ;
14460   return 0;
14461 }
14462 _ACEOF
14463 rm -f conftest.$ac_objext conftest$ac_exeext
14464 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14465   (eval $ac_link) 2>conftest.er1
14466   ac_status=$?
14467   grep -v '^ *+' conftest.er1 >conftest.err
14468   rm -f conftest.er1
14469   cat conftest.err >&5
14470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14471   (exit $ac_status); } &&
14472          { ac_try='test -z "$ac_c_werror_flag"
14473                          || test ! -s conftest.err'
14474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14475   (eval $ac_try) 2>&5
14476   ac_status=$?
14477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14478   (exit $ac_status); }; } &&
14479          { ac_try='test -s conftest$ac_exeext'
14480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14481   (eval $ac_try) 2>&5
14482   ac_status=$?
14483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14484   (exit $ac_status); }; }; then
14485   ac_cv_working_alloca_h=yes
14486 else
14487   echo "$as_me: failed program was:" >&5
14488 sed 's/^/| /' conftest.$ac_ext >&5
14489
14490 ac_cv_working_alloca_h=no
14491 fi
14492 rm -f conftest.err conftest.$ac_objext \
14493       conftest$ac_exeext conftest.$ac_ext
14494 fi
14495 echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
14496 echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
14497 if test $ac_cv_working_alloca_h = yes; then
14498
14499 cat >>confdefs.h <<\_ACEOF
14500 #define HAVE_ALLOCA_H 1
14501 _ACEOF
14502
14503 fi
14504
14505 echo "$as_me:$LINENO: checking for alloca" >&5
14506 echo $ECHO_N "checking for alloca... $ECHO_C" >&6
14507 if test "${ac_cv_func_alloca_works+set}" = set; then
14508   echo $ECHO_N "(cached) $ECHO_C" >&6
14509 else
14510   cat >conftest.$ac_ext <<_ACEOF
14511 /* confdefs.h.  */
14512 _ACEOF
14513 cat confdefs.h >>conftest.$ac_ext
14514 cat >>conftest.$ac_ext <<_ACEOF
14515 /* end confdefs.h.  */
14516 #ifdef __GNUC__
14517 # define alloca __builtin_alloca
14518 #else
14519 # ifdef _MSC_VER
14520 #  include <malloc.h>
14521 #  define alloca _alloca
14522 # else
14523 #  if HAVE_ALLOCA_H
14524 #   include <alloca.h>
14525 #  else
14526 #   ifdef _AIX
14527  #pragma alloca
14528 #   else
14529 #    ifndef alloca /* predefined by HP cc +Olibcalls */
14530 char *alloca ();
14531 #    endif
14532 #   endif
14533 #  endif
14534 # endif
14535 #endif
14536
14537 int
14538 main ()
14539 {
14540 char *p = (char *) alloca (1);
14541   ;
14542   return 0;
14543 }
14544 _ACEOF
14545 rm -f conftest.$ac_objext conftest$ac_exeext
14546 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14547   (eval $ac_link) 2>conftest.er1
14548   ac_status=$?
14549   grep -v '^ *+' conftest.er1 >conftest.err
14550   rm -f conftest.er1
14551   cat conftest.err >&5
14552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14553   (exit $ac_status); } &&
14554          { ac_try='test -z "$ac_c_werror_flag"
14555                          || test ! -s conftest.err'
14556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14557   (eval $ac_try) 2>&5
14558   ac_status=$?
14559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14560   (exit $ac_status); }; } &&
14561          { ac_try='test -s conftest$ac_exeext'
14562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14563   (eval $ac_try) 2>&5
14564   ac_status=$?
14565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14566   (exit $ac_status); }; }; then
14567   ac_cv_func_alloca_works=yes
14568 else
14569   echo "$as_me: failed program was:" >&5
14570 sed 's/^/| /' conftest.$ac_ext >&5
14571
14572 ac_cv_func_alloca_works=no
14573 fi
14574 rm -f conftest.err conftest.$ac_objext \
14575       conftest$ac_exeext conftest.$ac_ext
14576 fi
14577 echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
14578 echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
14579
14580 if test $ac_cv_func_alloca_works = yes; then
14581
14582 cat >>confdefs.h <<\_ACEOF
14583 #define HAVE_ALLOCA 1
14584 _ACEOF
14585
14586 else
14587   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
14588 # that cause trouble.  Some versions do not even contain alloca or
14589 # contain a buggy version.  If you still want to use their alloca,
14590 # use ar to extract alloca.o from them instead of compiling alloca.c.
14591
14592 ALLOCA=alloca.$ac_objext
14593
14594 cat >>confdefs.h <<\_ACEOF
14595 #define C_ALLOCA 1
14596 _ACEOF
14597
14598
14599 echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
14600 echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
14601 if test "${ac_cv_os_cray+set}" = set; then
14602   echo $ECHO_N "(cached) $ECHO_C" >&6
14603 else
14604   cat >conftest.$ac_ext <<_ACEOF
14605 /* confdefs.h.  */
14606 _ACEOF
14607 cat confdefs.h >>conftest.$ac_ext
14608 cat >>conftest.$ac_ext <<_ACEOF
14609 /* end confdefs.h.  */
14610 #if defined(CRAY) && ! defined(CRAY2)
14611 webecray
14612 #else
14613 wenotbecray
14614 #endif
14615
14616 _ACEOF
14617 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14618   $EGREP "webecray" >/dev/null 2>&1; then
14619   ac_cv_os_cray=yes
14620 else
14621   ac_cv_os_cray=no
14622 fi
14623 rm -f conftest*
14624
14625 fi
14626 echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
14627 echo "${ECHO_T}$ac_cv_os_cray" >&6
14628 if test $ac_cv_os_cray = yes; then
14629   for ac_func in _getb67 GETB67 getb67; do
14630     as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14631 echo "$as_me:$LINENO: checking for $ac_func" >&5
14632 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14633 if eval "test \"\${$as_ac_var+set}\" = set"; then
14634   echo $ECHO_N "(cached) $ECHO_C" >&6
14635 else
14636   cat >conftest.$ac_ext <<_ACEOF
14637 /* confdefs.h.  */
14638 _ACEOF
14639 cat confdefs.h >>conftest.$ac_ext
14640 cat >>conftest.$ac_ext <<_ACEOF
14641 /* end confdefs.h.  */
14642 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14643    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14644 #define $ac_func innocuous_$ac_func
14645
14646 /* System header to define __stub macros and hopefully few prototypes,
14647     which can conflict with char $ac_func (); below.
14648     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14649     <limits.h> exists even on freestanding compilers.  */
14650
14651 #ifdef __STDC__
14652 # include <limits.h>
14653 #else
14654 # include <assert.h>
14655 #endif
14656
14657 #undef $ac_func
14658
14659 /* Override any gcc2 internal prototype to avoid an error.  */
14660 #ifdef __cplusplus
14661 extern "C"
14662 {
14663 #endif
14664 /* We use char because int might match the return type of a gcc2
14665    builtin and then its argument prototype would still apply.  */
14666 char $ac_func ();
14667 /* The GNU C library defines this for functions which it implements
14668     to always fail with ENOSYS.  Some functions are actually named
14669     something starting with __ and the normal name is an alias.  */
14670 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14671 choke me
14672 #else
14673 char (*f) () = $ac_func;
14674 #endif
14675 #ifdef __cplusplus
14676 }
14677 #endif
14678
14679 int
14680 main ()
14681 {
14682 return f != $ac_func;
14683   ;
14684   return 0;
14685 }
14686 _ACEOF
14687 rm -f conftest.$ac_objext conftest$ac_exeext
14688 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14689   (eval $ac_link) 2>conftest.er1
14690   ac_status=$?
14691   grep -v '^ *+' conftest.er1 >conftest.err
14692   rm -f conftest.er1
14693   cat conftest.err >&5
14694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14695   (exit $ac_status); } &&
14696          { ac_try='test -z "$ac_c_werror_flag"
14697                          || test ! -s conftest.err'
14698   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14699   (eval $ac_try) 2>&5
14700   ac_status=$?
14701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14702   (exit $ac_status); }; } &&
14703          { ac_try='test -s conftest$ac_exeext'
14704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14705   (eval $ac_try) 2>&5
14706   ac_status=$?
14707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14708   (exit $ac_status); }; }; then
14709   eval "$as_ac_var=yes"
14710 else
14711   echo "$as_me: failed program was:" >&5
14712 sed 's/^/| /' conftest.$ac_ext >&5
14713
14714 eval "$as_ac_var=no"
14715 fi
14716 rm -f conftest.err conftest.$ac_objext \
14717       conftest$ac_exeext conftest.$ac_ext
14718 fi
14719 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14720 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14721 if test `eval echo '${'$as_ac_var'}'` = yes; then
14722
14723 cat >>confdefs.h <<_ACEOF
14724 #define CRAY_STACKSEG_END $ac_func
14725 _ACEOF
14726
14727     break
14728 fi
14729
14730   done
14731 fi
14732
14733 echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
14734 echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
14735 if test "${ac_cv_c_stack_direction+set}" = set; then
14736   echo $ECHO_N "(cached) $ECHO_C" >&6
14737 else
14738   if test "$cross_compiling" = yes; then
14739   ac_cv_c_stack_direction=0
14740 else
14741   cat >conftest.$ac_ext <<_ACEOF
14742 /* confdefs.h.  */
14743 _ACEOF
14744 cat confdefs.h >>conftest.$ac_ext
14745 cat >>conftest.$ac_ext <<_ACEOF
14746 /* end confdefs.h.  */
14747 int
14748 find_stack_direction ()
14749 {
14750   static char *addr = 0;
14751   auto char dummy;
14752   if (addr == 0)
14753     {
14754       addr = &dummy;
14755       return find_stack_direction ();
14756     }
14757   else
14758     return (&dummy > addr) ? 1 : -1;
14759 }
14760
14761 int
14762 main ()
14763 {
14764   exit (find_stack_direction () < 0);
14765 }
14766 _ACEOF
14767 rm -f conftest$ac_exeext
14768 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14769   (eval $ac_link) 2>&5
14770   ac_status=$?
14771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14772   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14774   (eval $ac_try) 2>&5
14775   ac_status=$?
14776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14777   (exit $ac_status); }; }; then
14778   ac_cv_c_stack_direction=1
14779 else
14780   echo "$as_me: program exited with status $ac_status" >&5
14781 echo "$as_me: failed program was:" >&5
14782 sed 's/^/| /' conftest.$ac_ext >&5
14783
14784 ( exit $ac_status )
14785 ac_cv_c_stack_direction=-1
14786 fi
14787 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14788 fi
14789 fi
14790 echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
14791 echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
14792
14793 cat >>confdefs.h <<_ACEOF
14794 #define STACK_DIRECTION $ac_cv_c_stack_direction
14795 _ACEOF
14796
14797
14798 fi
14799
14800
14801
14802 for ac_header in stdlib.h unistd.h
14803 do
14804 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14805 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14806   echo "$as_me:$LINENO: checking for $ac_header" >&5
14807 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14808 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14809   echo $ECHO_N "(cached) $ECHO_C" >&6
14810 fi
14811 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14812 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14813 else
14814   # Is the header compilable?
14815 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14816 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14817 cat >conftest.$ac_ext <<_ACEOF
14818 /* confdefs.h.  */
14819 _ACEOF
14820 cat confdefs.h >>conftest.$ac_ext
14821 cat >>conftest.$ac_ext <<_ACEOF
14822 /* end confdefs.h.  */
14823 $ac_includes_default
14824 #include <$ac_header>
14825 _ACEOF
14826 rm -f conftest.$ac_objext
14827 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14828   (eval $ac_compile) 2>conftest.er1
14829   ac_status=$?
14830   grep -v '^ *+' conftest.er1 >conftest.err
14831   rm -f conftest.er1
14832   cat conftest.err >&5
14833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14834   (exit $ac_status); } &&
14835          { ac_try='test -z "$ac_c_werror_flag"
14836                          || test ! -s conftest.err'
14837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14838   (eval $ac_try) 2>&5
14839   ac_status=$?
14840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14841   (exit $ac_status); }; } &&
14842          { ac_try='test -s conftest.$ac_objext'
14843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14844   (eval $ac_try) 2>&5
14845   ac_status=$?
14846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14847   (exit $ac_status); }; }; then
14848   ac_header_compiler=yes
14849 else
14850   echo "$as_me: failed program was:" >&5
14851 sed 's/^/| /' conftest.$ac_ext >&5
14852
14853 ac_header_compiler=no
14854 fi
14855 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14856 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14857 echo "${ECHO_T}$ac_header_compiler" >&6
14858
14859 # Is the header present?
14860 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14861 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14862 cat >conftest.$ac_ext <<_ACEOF
14863 /* confdefs.h.  */
14864 _ACEOF
14865 cat confdefs.h >>conftest.$ac_ext
14866 cat >>conftest.$ac_ext <<_ACEOF
14867 /* end confdefs.h.  */
14868 #include <$ac_header>
14869 _ACEOF
14870 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14871   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14872   ac_status=$?
14873   grep -v '^ *+' conftest.er1 >conftest.err
14874   rm -f conftest.er1
14875   cat conftest.err >&5
14876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14877   (exit $ac_status); } >/dev/null; then
14878   if test -s conftest.err; then
14879     ac_cpp_err=$ac_c_preproc_warn_flag
14880     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14881   else
14882     ac_cpp_err=
14883   fi
14884 else
14885   ac_cpp_err=yes
14886 fi
14887 if test -z "$ac_cpp_err"; then
14888   ac_header_preproc=yes
14889 else
14890   echo "$as_me: failed program was:" >&5
14891 sed 's/^/| /' conftest.$ac_ext >&5
14892
14893   ac_header_preproc=no
14894 fi
14895 rm -f conftest.err conftest.$ac_ext
14896 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14897 echo "${ECHO_T}$ac_header_preproc" >&6
14898
14899 # So?  What about this header?
14900 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14901   yes:no: )
14902     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14903 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14904     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14905 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14906     ac_header_preproc=yes
14907     ;;
14908   no:yes:* )
14909     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14910 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14911     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14912 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14913     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14914 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14915     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14916 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14917     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14918 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14919     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14920 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14921     (
14922       cat <<\_ASBOX
14923 ## ------------------------------------------ ##
14924 ## Report this to the AC_PACKAGE_NAME lists.  ##
14925 ## ------------------------------------------ ##
14926 _ASBOX
14927     ) |
14928       sed "s/^/$as_me: WARNING:     /" >&2
14929     ;;
14930 esac
14931 echo "$as_me:$LINENO: checking for $ac_header" >&5
14932 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14933 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14934   echo $ECHO_N "(cached) $ECHO_C" >&6
14935 else
14936   eval "$as_ac_Header=\$ac_header_preproc"
14937 fi
14938 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14939 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14940
14941 fi
14942 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14943   cat >>confdefs.h <<_ACEOF
14944 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14945 _ACEOF
14946
14947 fi
14948
14949 done
14950
14951
14952 for ac_func in getpagesize
14953 do
14954 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14955 echo "$as_me:$LINENO: checking for $ac_func" >&5
14956 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14957 if eval "test \"\${$as_ac_var+set}\" = set"; then
14958   echo $ECHO_N "(cached) $ECHO_C" >&6
14959 else
14960   cat >conftest.$ac_ext <<_ACEOF
14961 /* confdefs.h.  */
14962 _ACEOF
14963 cat confdefs.h >>conftest.$ac_ext
14964 cat >>conftest.$ac_ext <<_ACEOF
14965 /* end confdefs.h.  */
14966 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14967    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14968 #define $ac_func innocuous_$ac_func
14969
14970 /* System header to define __stub macros and hopefully few prototypes,
14971     which can conflict with char $ac_func (); below.
14972     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14973     <limits.h> exists even on freestanding compilers.  */
14974
14975 #ifdef __STDC__
14976 # include <limits.h>
14977 #else
14978 # include <assert.h>
14979 #endif
14980
14981 #undef $ac_func
14982
14983 /* Override any gcc2 internal prototype to avoid an error.  */
14984 #ifdef __cplusplus
14985 extern "C"
14986 {
14987 #endif
14988 /* We use char because int might match the return type of a gcc2
14989    builtin and then its argument prototype would still apply.  */
14990 char $ac_func ();
14991 /* The GNU C library defines this for functions which it implements
14992     to always fail with ENOSYS.  Some functions are actually named
14993     something starting with __ and the normal name is an alias.  */
14994 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14995 choke me
14996 #else
14997 char (*f) () = $ac_func;
14998 #endif
14999 #ifdef __cplusplus
15000 }
15001 #endif
15002
15003 int
15004 main ()
15005 {
15006 return f != $ac_func;
15007   ;
15008   return 0;
15009 }
15010 _ACEOF
15011 rm -f conftest.$ac_objext conftest$ac_exeext
15012 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15013   (eval $ac_link) 2>conftest.er1
15014   ac_status=$?
15015   grep -v '^ *+' conftest.er1 >conftest.err
15016   rm -f conftest.er1
15017   cat conftest.err >&5
15018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15019   (exit $ac_status); } &&
15020          { ac_try='test -z "$ac_c_werror_flag"
15021                          || test ! -s conftest.err'
15022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15023   (eval $ac_try) 2>&5
15024   ac_status=$?
15025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15026   (exit $ac_status); }; } &&
15027          { ac_try='test -s conftest$ac_exeext'
15028   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15029   (eval $ac_try) 2>&5
15030   ac_status=$?
15031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15032   (exit $ac_status); }; }; then
15033   eval "$as_ac_var=yes"
15034 else
15035   echo "$as_me: failed program was:" >&5
15036 sed 's/^/| /' conftest.$ac_ext >&5
15037
15038 eval "$as_ac_var=no"
15039 fi
15040 rm -f conftest.err conftest.$ac_objext \
15041       conftest$ac_exeext conftest.$ac_ext
15042 fi
15043 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15044 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15045 if test `eval echo '${'$as_ac_var'}'` = yes; then
15046   cat >>confdefs.h <<_ACEOF
15047 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15048 _ACEOF
15049
15050 fi
15051 done
15052
15053 echo "$as_me:$LINENO: checking for working mmap" >&5
15054 echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
15055 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
15056   echo $ECHO_N "(cached) $ECHO_C" >&6
15057 else
15058   if test "$cross_compiling" = yes; then
15059   ac_cv_func_mmap_fixed_mapped=no
15060 else
15061   cat >conftest.$ac_ext <<_ACEOF
15062 /* confdefs.h.  */
15063 _ACEOF
15064 cat confdefs.h >>conftest.$ac_ext
15065 cat >>conftest.$ac_ext <<_ACEOF
15066 /* end confdefs.h.  */
15067 $ac_includes_default
15068 /* malloc might have been renamed as rpl_malloc. */
15069 #undef malloc
15070
15071 /* Thanks to Mike Haertel and Jim Avera for this test.
15072    Here is a matrix of mmap possibilities:
15073         mmap private not fixed
15074         mmap private fixed at somewhere currently unmapped
15075         mmap private fixed at somewhere already mapped
15076         mmap shared not fixed
15077         mmap shared fixed at somewhere currently unmapped
15078         mmap shared fixed at somewhere already mapped
15079    For private mappings, we should verify that changes cannot be read()
15080    back from the file, nor mmap's back from the file at a different
15081    address.  (There have been systems where private was not correctly
15082    implemented like the infamous i386 svr4.0, and systems where the
15083    VM page cache was not coherent with the file system buffer cache
15084    like early versions of FreeBSD and possibly contemporary NetBSD.)
15085    For shared mappings, we should conversely verify that changes get
15086    propagated back to all the places they're supposed to be.
15087
15088    Grep wants private fixed already mapped.
15089    The main things grep needs to know about mmap are:
15090    * does it exist and is it safe to write into the mmap'd area
15091    * how to use it (BSD variants)  */
15092
15093 #include <fcntl.h>
15094 #include <sys/mman.h>
15095
15096 #if !STDC_HEADERS && !HAVE_STDLIB_H
15097 char *malloc ();
15098 #endif
15099
15100 /* This mess was copied from the GNU getpagesize.h.  */
15101 #if !HAVE_GETPAGESIZE
15102 /* Assume that all systems that can run configure have sys/param.h.  */
15103 # if !HAVE_SYS_PARAM_H
15104 #  define HAVE_SYS_PARAM_H 1
15105 # endif
15106
15107 # ifdef _SC_PAGESIZE
15108 #  define getpagesize() sysconf(_SC_PAGESIZE)
15109 # else /* no _SC_PAGESIZE */
15110 #  if HAVE_SYS_PARAM_H
15111 #   include <sys/param.h>
15112 #   ifdef EXEC_PAGESIZE
15113 #    define getpagesize() EXEC_PAGESIZE
15114 #   else /* no EXEC_PAGESIZE */
15115 #    ifdef NBPG
15116 #     define getpagesize() NBPG * CLSIZE
15117 #     ifndef CLSIZE
15118 #      define CLSIZE 1
15119 #     endif /* no CLSIZE */
15120 #    else /* no NBPG */
15121 #     ifdef NBPC
15122 #      define getpagesize() NBPC
15123 #     else /* no NBPC */
15124 #      ifdef PAGESIZE
15125 #       define getpagesize() PAGESIZE
15126 #      endif /* PAGESIZE */
15127 #     endif /* no NBPC */
15128 #    endif /* no NBPG */
15129 #   endif /* no EXEC_PAGESIZE */
15130 #  else /* no HAVE_SYS_PARAM_H */
15131 #   define getpagesize() 8192   /* punt totally */
15132 #  endif /* no HAVE_SYS_PARAM_H */
15133 # endif /* no _SC_PAGESIZE */
15134
15135 #endif /* no HAVE_GETPAGESIZE */
15136
15137 int
15138 main ()
15139 {
15140   char *data, *data2, *data3;
15141   int i, pagesize;
15142   int fd;
15143
15144   pagesize = getpagesize ();
15145
15146   /* First, make a file with some known garbage in it. */
15147   data = (char *) malloc (pagesize);
15148   if (!data)
15149     exit (1);
15150   for (i = 0; i < pagesize; ++i)
15151     *(data + i) = rand ();
15152   umask (0);
15153   fd = creat ("conftest.mmap", 0600);
15154   if (fd < 0)
15155     exit (1);
15156   if (write (fd, data, pagesize) != pagesize)
15157     exit (1);
15158   close (fd);
15159
15160   /* Next, try to mmap the file at a fixed address which already has
15161      something else allocated at it.  If we can, also make sure that
15162      we see the same garbage.  */
15163   fd = open ("conftest.mmap", O_RDWR);
15164   if (fd < 0)
15165     exit (1);
15166   data2 = (char *) malloc (2 * pagesize);
15167   if (!data2)
15168     exit (1);
15169   data2 += (pagesize - ((long) data2 & (pagesize - 1))) & (pagesize - 1);
15170   if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
15171                      MAP_PRIVATE | MAP_FIXED, fd, 0L))
15172     exit (1);
15173   for (i = 0; i < pagesize; ++i)
15174     if (*(data + i) != *(data2 + i))
15175       exit (1);
15176
15177   /* Finally, make sure that changes to the mapped area do not
15178      percolate back to the file as seen by read().  (This is a bug on
15179      some variants of i386 svr4.0.)  */
15180   for (i = 0; i < pagesize; ++i)
15181     *(data2 + i) = *(data2 + i) + 1;
15182   data3 = (char *) malloc (pagesize);
15183   if (!data3)
15184     exit (1);
15185   if (read (fd, data3, pagesize) != pagesize)
15186     exit (1);
15187   for (i = 0; i < pagesize; ++i)
15188     if (*(data + i) != *(data3 + i))
15189       exit (1);
15190   close (fd);
15191   exit (0);
15192 }
15193 _ACEOF
15194 rm -f conftest$ac_exeext
15195 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15196   (eval $ac_link) 2>&5
15197   ac_status=$?
15198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15199   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15200   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15201   (eval $ac_try) 2>&5
15202   ac_status=$?
15203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15204   (exit $ac_status); }; }; then
15205   ac_cv_func_mmap_fixed_mapped=yes
15206 else
15207   echo "$as_me: program exited with status $ac_status" >&5
15208 echo "$as_me: failed program was:" >&5
15209 sed 's/^/| /' conftest.$ac_ext >&5
15210
15211 ( exit $ac_status )
15212 ac_cv_func_mmap_fixed_mapped=no
15213 fi
15214 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15215 fi
15216 fi
15217 echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
15218 echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
15219 if test $ac_cv_func_mmap_fixed_mapped = yes; then
15220
15221 cat >>confdefs.h <<\_ACEOF
15222 #define HAVE_MMAP 1
15223 _ACEOF
15224
15225 fi
15226 rm -f conftest.mmap
15227
15228 echo "$as_me:$LINENO: checking for pid_t" >&5
15229 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
15230 if test "${ac_cv_type_pid_t+set}" = set; then
15231   echo $ECHO_N "(cached) $ECHO_C" >&6
15232 else
15233   cat >conftest.$ac_ext <<_ACEOF
15234 /* confdefs.h.  */
15235 _ACEOF
15236 cat confdefs.h >>conftest.$ac_ext
15237 cat >>conftest.$ac_ext <<_ACEOF
15238 /* end confdefs.h.  */
15239 $ac_includes_default
15240 int
15241 main ()
15242 {
15243 if ((pid_t *) 0)
15244   return 0;
15245 if (sizeof (pid_t))
15246   return 0;
15247   ;
15248   return 0;
15249 }
15250 _ACEOF
15251 rm -f conftest.$ac_objext
15252 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15253   (eval $ac_compile) 2>conftest.er1
15254   ac_status=$?
15255   grep -v '^ *+' conftest.er1 >conftest.err
15256   rm -f conftest.er1
15257   cat conftest.err >&5
15258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15259   (exit $ac_status); } &&
15260          { ac_try='test -z "$ac_c_werror_flag"
15261                          || test ! -s conftest.err'
15262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15263   (eval $ac_try) 2>&5
15264   ac_status=$?
15265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15266   (exit $ac_status); }; } &&
15267          { ac_try='test -s conftest.$ac_objext'
15268   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15269   (eval $ac_try) 2>&5
15270   ac_status=$?
15271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15272   (exit $ac_status); }; }; then
15273   ac_cv_type_pid_t=yes
15274 else
15275   echo "$as_me: failed program was:" >&5
15276 sed 's/^/| /' conftest.$ac_ext >&5
15277
15278 ac_cv_type_pid_t=no
15279 fi
15280 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15281 fi
15282 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
15283 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
15284 if test $ac_cv_type_pid_t = yes; then
15285   :
15286 else
15287
15288 cat >>confdefs.h <<_ACEOF
15289 #define pid_t int
15290 _ACEOF
15291
15292 fi
15293
15294
15295
15296 for ac_header in unistd.h vfork.h
15297 do
15298 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15299 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15300   echo "$as_me:$LINENO: checking for $ac_header" >&5
15301 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15302 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15303   echo $ECHO_N "(cached) $ECHO_C" >&6
15304 fi
15305 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15306 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15307 else
15308   # Is the header compilable?
15309 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15310 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15311 cat >conftest.$ac_ext <<_ACEOF
15312 /* confdefs.h.  */
15313 _ACEOF
15314 cat confdefs.h >>conftest.$ac_ext
15315 cat >>conftest.$ac_ext <<_ACEOF
15316 /* end confdefs.h.  */
15317 $ac_includes_default
15318 #include <$ac_header>
15319 _ACEOF
15320 rm -f conftest.$ac_objext
15321 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15322   (eval $ac_compile) 2>conftest.er1
15323   ac_status=$?
15324   grep -v '^ *+' conftest.er1 >conftest.err
15325   rm -f conftest.er1
15326   cat conftest.err >&5
15327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15328   (exit $ac_status); } &&
15329          { ac_try='test -z "$ac_c_werror_flag"
15330                          || test ! -s conftest.err'
15331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15332   (eval $ac_try) 2>&5
15333   ac_status=$?
15334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15335   (exit $ac_status); }; } &&
15336          { ac_try='test -s conftest.$ac_objext'
15337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15338   (eval $ac_try) 2>&5
15339   ac_status=$?
15340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15341   (exit $ac_status); }; }; then
15342   ac_header_compiler=yes
15343 else
15344   echo "$as_me: failed program was:" >&5
15345 sed 's/^/| /' conftest.$ac_ext >&5
15346
15347 ac_header_compiler=no
15348 fi
15349 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15350 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15351 echo "${ECHO_T}$ac_header_compiler" >&6
15352
15353 # Is the header present?
15354 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15355 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15356 cat >conftest.$ac_ext <<_ACEOF
15357 /* confdefs.h.  */
15358 _ACEOF
15359 cat confdefs.h >>conftest.$ac_ext
15360 cat >>conftest.$ac_ext <<_ACEOF
15361 /* end confdefs.h.  */
15362 #include <$ac_header>
15363 _ACEOF
15364 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15365   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15366   ac_status=$?
15367   grep -v '^ *+' conftest.er1 >conftest.err
15368   rm -f conftest.er1
15369   cat conftest.err >&5
15370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15371   (exit $ac_status); } >/dev/null; then
15372   if test -s conftest.err; then
15373     ac_cpp_err=$ac_c_preproc_warn_flag
15374     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15375   else
15376     ac_cpp_err=
15377   fi
15378 else
15379   ac_cpp_err=yes
15380 fi
15381 if test -z "$ac_cpp_err"; then
15382   ac_header_preproc=yes
15383 else
15384   echo "$as_me: failed program was:" >&5
15385 sed 's/^/| /' conftest.$ac_ext >&5
15386
15387   ac_header_preproc=no
15388 fi
15389 rm -f conftest.err conftest.$ac_ext
15390 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15391 echo "${ECHO_T}$ac_header_preproc" >&6
15392
15393 # So?  What about this header?
15394 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15395   yes:no: )
15396     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15397 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15398     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15399 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15400     ac_header_preproc=yes
15401     ;;
15402   no:yes:* )
15403     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15404 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15405     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15406 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15407     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15408 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15409     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15410 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15411     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15412 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15413     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15414 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15415     (
15416       cat <<\_ASBOX
15417 ## ------------------------------------------ ##
15418 ## Report this to the AC_PACKAGE_NAME lists.  ##
15419 ## ------------------------------------------ ##
15420 _ASBOX
15421     ) |
15422       sed "s/^/$as_me: WARNING:     /" >&2
15423     ;;
15424 esac
15425 echo "$as_me:$LINENO: checking for $ac_header" >&5
15426 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15427 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15428   echo $ECHO_N "(cached) $ECHO_C" >&6
15429 else
15430   eval "$as_ac_Header=\$ac_header_preproc"
15431 fi
15432 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15433 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15434
15435 fi
15436 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15437   cat >>confdefs.h <<_ACEOF
15438 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15439 _ACEOF
15440
15441 fi
15442
15443 done
15444
15445
15446
15447 for ac_func in fork vfork
15448 do
15449 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15450 echo "$as_me:$LINENO: checking for $ac_func" >&5
15451 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15452 if eval "test \"\${$as_ac_var+set}\" = set"; then
15453   echo $ECHO_N "(cached) $ECHO_C" >&6
15454 else
15455   cat >conftest.$ac_ext <<_ACEOF
15456 /* confdefs.h.  */
15457 _ACEOF
15458 cat confdefs.h >>conftest.$ac_ext
15459 cat >>conftest.$ac_ext <<_ACEOF
15460 /* end confdefs.h.  */
15461 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15462    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15463 #define $ac_func innocuous_$ac_func
15464
15465 /* System header to define __stub macros and hopefully few prototypes,
15466     which can conflict with char $ac_func (); below.
15467     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15468     <limits.h> exists even on freestanding compilers.  */
15469
15470 #ifdef __STDC__
15471 # include <limits.h>
15472 #else
15473 # include <assert.h>
15474 #endif
15475
15476 #undef $ac_func
15477
15478 /* Override any gcc2 internal prototype to avoid an error.  */
15479 #ifdef __cplusplus
15480 extern "C"
15481 {
15482 #endif
15483 /* We use char because int might match the return type of a gcc2
15484    builtin and then its argument prototype would still apply.  */
15485 char $ac_func ();
15486 /* The GNU C library defines this for functions which it implements
15487     to always fail with ENOSYS.  Some functions are actually named
15488     something starting with __ and the normal name is an alias.  */
15489 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15490 choke me
15491 #else
15492 char (*f) () = $ac_func;
15493 #endif
15494 #ifdef __cplusplus
15495 }
15496 #endif
15497
15498 int
15499 main ()
15500 {
15501 return f != $ac_func;
15502   ;
15503   return 0;
15504 }
15505 _ACEOF
15506 rm -f conftest.$ac_objext conftest$ac_exeext
15507 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15508   (eval $ac_link) 2>conftest.er1
15509   ac_status=$?
15510   grep -v '^ *+' conftest.er1 >conftest.err
15511   rm -f conftest.er1
15512   cat conftest.err >&5
15513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15514   (exit $ac_status); } &&
15515          { ac_try='test -z "$ac_c_werror_flag"
15516                          || test ! -s conftest.err'
15517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15518   (eval $ac_try) 2>&5
15519   ac_status=$?
15520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15521   (exit $ac_status); }; } &&
15522          { ac_try='test -s conftest$ac_exeext'
15523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15524   (eval $ac_try) 2>&5
15525   ac_status=$?
15526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15527   (exit $ac_status); }; }; then
15528   eval "$as_ac_var=yes"
15529 else
15530   echo "$as_me: failed program was:" >&5
15531 sed 's/^/| /' conftest.$ac_ext >&5
15532
15533 eval "$as_ac_var=no"
15534 fi
15535 rm -f conftest.err conftest.$ac_objext \
15536       conftest$ac_exeext conftest.$ac_ext
15537 fi
15538 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15539 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15540 if test `eval echo '${'$as_ac_var'}'` = yes; then
15541   cat >>confdefs.h <<_ACEOF
15542 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15543 _ACEOF
15544
15545 fi
15546 done
15547
15548 if test "x$ac_cv_func_fork" = xyes; then
15549   echo "$as_me:$LINENO: checking for working fork" >&5
15550 echo $ECHO_N "checking for working fork... $ECHO_C" >&6
15551 if test "${ac_cv_func_fork_works+set}" = set; then
15552   echo $ECHO_N "(cached) $ECHO_C" >&6
15553 else
15554   if test "$cross_compiling" = yes; then
15555   ac_cv_func_fork_works=cross
15556 else
15557   cat >conftest.$ac_ext <<_ACEOF
15558 /* By Ruediger Kuhlmann. */
15559       #include <sys/types.h>
15560       #if HAVE_UNISTD_H
15561       # include <unistd.h>
15562       #endif
15563       /* Some systems only have a dummy stub for fork() */
15564       int main ()
15565       {
15566         if (fork() < 0)
15567           exit (1);
15568         exit (0);
15569       }
15570 _ACEOF
15571 rm -f conftest$ac_exeext
15572 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15573   (eval $ac_link) 2>&5
15574   ac_status=$?
15575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15576   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15578   (eval $ac_try) 2>&5
15579   ac_status=$?
15580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15581   (exit $ac_status); }; }; then
15582   ac_cv_func_fork_works=yes
15583 else
15584   echo "$as_me: program exited with status $ac_status" >&5
15585 echo "$as_me: failed program was:" >&5
15586 sed 's/^/| /' conftest.$ac_ext >&5
15587
15588 ( exit $ac_status )
15589 ac_cv_func_fork_works=no
15590 fi
15591 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15592 fi
15593 fi
15594 echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
15595 echo "${ECHO_T}$ac_cv_func_fork_works" >&6
15596
15597 else
15598   ac_cv_func_fork_works=$ac_cv_func_fork
15599 fi
15600 if test "x$ac_cv_func_fork_works" = xcross; then
15601   case $host in
15602     *-*-amigaos* | *-*-msdosdjgpp*)
15603       # Override, as these systems have only a dummy fork() stub
15604       ac_cv_func_fork_works=no
15605       ;;
15606     *)
15607       ac_cv_func_fork_works=yes
15608       ;;
15609   esac
15610   { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15611 echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15612 fi
15613 ac_cv_func_vfork_works=$ac_cv_func_vfork
15614 if test "x$ac_cv_func_vfork" = xyes; then
15615   echo "$as_me:$LINENO: checking for working vfork" >&5
15616 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
15617 if test "${ac_cv_func_vfork_works+set}" = set; then
15618   echo $ECHO_N "(cached) $ECHO_C" >&6
15619 else
15620   if test "$cross_compiling" = yes; then
15621   ac_cv_func_vfork_works=cross
15622 else
15623   cat >conftest.$ac_ext <<_ACEOF
15624 /* confdefs.h.  */
15625 _ACEOF
15626 cat confdefs.h >>conftest.$ac_ext
15627 cat >>conftest.$ac_ext <<_ACEOF
15628 /* end confdefs.h.  */
15629 /* Thanks to Paul Eggert for this test.  */
15630 #include <stdio.h>
15631 #include <stdlib.h>
15632 #include <sys/types.h>
15633 #include <sys/stat.h>
15634 #include <sys/wait.h>
15635 #if HAVE_UNISTD_H
15636 # include <unistd.h>
15637 #endif
15638 #if HAVE_VFORK_H
15639 # include <vfork.h>
15640 #endif
15641 /* On some sparc systems, changes by the child to local and incoming
15642    argument registers are propagated back to the parent.  The compiler
15643    is told about this with #include <vfork.h>, but some compilers
15644    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
15645    static variable whose address is put into a register that is
15646    clobbered by the vfork.  */
15647 static void
15648 #ifdef __cplusplus
15649 sparc_address_test (int arg)
15650 # else
15651 sparc_address_test (arg) int arg;
15652 #endif
15653 {
15654   static pid_t child;
15655   if (!child) {
15656     child = vfork ();
15657     if (child < 0) {
15658       perror ("vfork");
15659       _exit(2);
15660     }
15661     if (!child) {
15662       arg = getpid();
15663       write(-1, "", 0);
15664       _exit (arg);
15665     }
15666   }
15667 }
15668
15669 int
15670 main ()
15671 {
15672   pid_t parent = getpid ();
15673   pid_t child;
15674
15675   sparc_address_test (0);
15676
15677   child = vfork ();
15678
15679   if (child == 0) {
15680     /* Here is another test for sparc vfork register problems.  This
15681        test uses lots of local variables, at least as many local
15682        variables as main has allocated so far including compiler
15683        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
15684        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
15685        reuse the register of parent for one of the local variables,
15686        since it will think that parent can't possibly be used any more
15687        in this routine.  Assigning to the local variable will thus
15688        munge parent in the parent process.  */
15689     pid_t
15690       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15691       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15692     /* Convince the compiler that p..p7 are live; otherwise, it might
15693        use the same hardware register for all 8 local variables.  */
15694     if (p != p1 || p != p2 || p != p3 || p != p4
15695         || p != p5 || p != p6 || p != p7)
15696       _exit(1);
15697
15698     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15699        from child file descriptors.  If the child closes a descriptor
15700        before it execs or exits, this munges the parent's descriptor
15701        as well.  Test for this by closing stdout in the child.  */
15702     _exit(close(fileno(stdout)) != 0);
15703   } else {
15704     int status;
15705     struct stat st;
15706
15707     while (wait(&status) != child)
15708       ;
15709     exit(
15710          /* Was there some problem with vforking?  */
15711          child < 0
15712
15713          /* Did the child fail?  (This shouldn't happen.)  */
15714          || status
15715
15716          /* Did the vfork/compiler bug occur?  */
15717          || parent != getpid()
15718
15719          /* Did the file descriptor bug occur?  */
15720          || fstat(fileno(stdout), &st) != 0
15721          );
15722   }
15723 }
15724 _ACEOF
15725 rm -f conftest$ac_exeext
15726 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15727   (eval $ac_link) 2>&5
15728   ac_status=$?
15729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15730   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15731   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15732   (eval $ac_try) 2>&5
15733   ac_status=$?
15734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15735   (exit $ac_status); }; }; then
15736   ac_cv_func_vfork_works=yes
15737 else
15738   echo "$as_me: program exited with status $ac_status" >&5
15739 echo "$as_me: failed program was:" >&5
15740 sed 's/^/| /' conftest.$ac_ext >&5
15741
15742 ( exit $ac_status )
15743 ac_cv_func_vfork_works=no
15744 fi
15745 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15746 fi
15747 fi
15748 echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
15749 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
15750
15751 fi;
15752 if test "x$ac_cv_func_fork_works" = xcross; then
15753   ac_cv_func_vfork_works=$ac_cv_func_vfork
15754   { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15755 echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15756 fi
15757
15758 if test "x$ac_cv_func_vfork_works" = xyes; then
15759
15760 cat >>confdefs.h <<\_ACEOF
15761 #define HAVE_WORKING_VFORK 1
15762 _ACEOF
15763
15764 else
15765
15766 cat >>confdefs.h <<\_ACEOF
15767 #define vfork fork
15768 _ACEOF
15769
15770 fi
15771 if test "x$ac_cv_func_fork_works" = xyes; then
15772
15773 cat >>confdefs.h <<\_ACEOF
15774 #define HAVE_WORKING_FORK 1
15775 _ACEOF
15776
15777 fi
15778
15779
15780
15781
15782
15783
15784
15785
15786
15787
15788
15789
15790
15791
15792
15793
15794
15795
15796
15797
15798
15799
15800
15801 for ac_func in canonicalize_file_name realpath getrusage getuid \
15802                 getgid poll pread64 sbrk setpgid setpgrp setsid \
15803                 sigaction sigprocmask sigsetmask socketpair syscall \
15804                 ttrace wborder setlocale iconvlist libiconvlist btowc
15805 do
15806 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15807 echo "$as_me:$LINENO: checking for $ac_func" >&5
15808 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15809 if eval "test \"\${$as_ac_var+set}\" = set"; then
15810   echo $ECHO_N "(cached) $ECHO_C" >&6
15811 else
15812   cat >conftest.$ac_ext <<_ACEOF
15813 /* confdefs.h.  */
15814 _ACEOF
15815 cat confdefs.h >>conftest.$ac_ext
15816 cat >>conftest.$ac_ext <<_ACEOF
15817 /* end confdefs.h.  */
15818 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15819    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15820 #define $ac_func innocuous_$ac_func
15821
15822 /* System header to define __stub macros and hopefully few prototypes,
15823     which can conflict with char $ac_func (); below.
15824     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15825     <limits.h> exists even on freestanding compilers.  */
15826
15827 #ifdef __STDC__
15828 # include <limits.h>
15829 #else
15830 # include <assert.h>
15831 #endif
15832
15833 #undef $ac_func
15834
15835 /* Override any gcc2 internal prototype to avoid an error.  */
15836 #ifdef __cplusplus
15837 extern "C"
15838 {
15839 #endif
15840 /* We use char because int might match the return type of a gcc2
15841    builtin and then its argument prototype would still apply.  */
15842 char $ac_func ();
15843 /* The GNU C library defines this for functions which it implements
15844     to always fail with ENOSYS.  Some functions are actually named
15845     something starting with __ and the normal name is an alias.  */
15846 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15847 choke me
15848 #else
15849 char (*f) () = $ac_func;
15850 #endif
15851 #ifdef __cplusplus
15852 }
15853 #endif
15854
15855 int
15856 main ()
15857 {
15858 return f != $ac_func;
15859   ;
15860   return 0;
15861 }
15862 _ACEOF
15863 rm -f conftest.$ac_objext conftest$ac_exeext
15864 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15865   (eval $ac_link) 2>conftest.er1
15866   ac_status=$?
15867   grep -v '^ *+' conftest.er1 >conftest.err
15868   rm -f conftest.er1
15869   cat conftest.err >&5
15870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15871   (exit $ac_status); } &&
15872          { ac_try='test -z "$ac_c_werror_flag"
15873                          || test ! -s conftest.err'
15874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15875   (eval $ac_try) 2>&5
15876   ac_status=$?
15877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15878   (exit $ac_status); }; } &&
15879          { ac_try='test -s conftest$ac_exeext'
15880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15881   (eval $ac_try) 2>&5
15882   ac_status=$?
15883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15884   (exit $ac_status); }; }; then
15885   eval "$as_ac_var=yes"
15886 else
15887   echo "$as_me: failed program was:" >&5
15888 sed 's/^/| /' conftest.$ac_ext >&5
15889
15890 eval "$as_ac_var=no"
15891 fi
15892 rm -f conftest.err conftest.$ac_objext \
15893       conftest$ac_exeext conftest.$ac_ext
15894 fi
15895 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15896 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15897 if test `eval echo '${'$as_ac_var'}'` = yes; then
15898   cat >>confdefs.h <<_ACEOF
15899 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15900 _ACEOF
15901
15902 fi
15903 done
15904
15905
15906   echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
15907 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
15908 if test "${am_cv_langinfo_codeset+set}" = set; then
15909   echo $ECHO_N "(cached) $ECHO_C" >&6
15910 else
15911   cat >conftest.$ac_ext <<_ACEOF
15912 /* confdefs.h.  */
15913 _ACEOF
15914 cat confdefs.h >>conftest.$ac_ext
15915 cat >>conftest.$ac_ext <<_ACEOF
15916 /* end confdefs.h.  */
15917 #include <langinfo.h>
15918 int
15919 main ()
15920 {
15921 char* cs = nl_langinfo(CODESET);
15922   ;
15923   return 0;
15924 }
15925 _ACEOF
15926 rm -f conftest.$ac_objext conftest$ac_exeext
15927 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15928   (eval $ac_link) 2>conftest.er1
15929   ac_status=$?
15930   grep -v '^ *+' conftest.er1 >conftest.err
15931   rm -f conftest.er1
15932   cat conftest.err >&5
15933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15934   (exit $ac_status); } &&
15935          { ac_try='test -z "$ac_c_werror_flag"
15936                          || test ! -s conftest.err'
15937   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15938   (eval $ac_try) 2>&5
15939   ac_status=$?
15940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15941   (exit $ac_status); }; } &&
15942          { ac_try='test -s conftest$ac_exeext'
15943   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15944   (eval $ac_try) 2>&5
15945   ac_status=$?
15946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15947   (exit $ac_status); }; }; then
15948   am_cv_langinfo_codeset=yes
15949 else
15950   echo "$as_me: failed program was:" >&5
15951 sed 's/^/| /' conftest.$ac_ext >&5
15952
15953 am_cv_langinfo_codeset=no
15954 fi
15955 rm -f conftest.err conftest.$ac_objext \
15956       conftest$ac_exeext conftest.$ac_ext
15957
15958 fi
15959 echo "$as_me:$LINENO: result: $am_cv_langinfo_codeset" >&5
15960 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
15961   if test $am_cv_langinfo_codeset = yes; then
15962
15963 cat >>confdefs.h <<\_ACEOF
15964 #define HAVE_LANGINFO_CODESET 1
15965 _ACEOF
15966
15967   fi
15968
15969
15970 # Check the return and argument types of ptrace.  No canned test for
15971 # this, so roll our own.
15972 gdb_ptrace_headers='
15973 #if HAVE_SYS_TYPES_H
15974 # include <sys/types.h>
15975 #endif
15976 #if HAVE_SYS_PTRACE_H
15977 # include <sys/ptrace.h>
15978 #endif
15979 #if HAVE_UNISTD_H
15980 # include <unistd.h>
15981 #endif
15982 '
15983 # There is no point in checking if we don't have a prototype.
15984 echo "$as_me:$LINENO: checking whether ptrace is declared" >&5
15985 echo $ECHO_N "checking whether ptrace is declared... $ECHO_C" >&6
15986 if test "${ac_cv_have_decl_ptrace+set}" = set; then
15987   echo $ECHO_N "(cached) $ECHO_C" >&6
15988 else
15989   cat >conftest.$ac_ext <<_ACEOF
15990 /* confdefs.h.  */
15991 _ACEOF
15992 cat confdefs.h >>conftest.$ac_ext
15993 cat >>conftest.$ac_ext <<_ACEOF
15994 /* end confdefs.h.  */
15995 $gdb_ptrace_headers
15996
15997 int
15998 main ()
15999 {
16000 #ifndef ptrace
16001   char *p = (char *) ptrace;
16002 #endif
16003
16004   ;
16005   return 0;
16006 }
16007 _ACEOF
16008 rm -f conftest.$ac_objext
16009 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16010   (eval $ac_compile) 2>conftest.er1
16011   ac_status=$?
16012   grep -v '^ *+' conftest.er1 >conftest.err
16013   rm -f conftest.er1
16014   cat conftest.err >&5
16015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16016   (exit $ac_status); } &&
16017          { ac_try='test -z "$ac_c_werror_flag"
16018                          || test ! -s conftest.err'
16019   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16020   (eval $ac_try) 2>&5
16021   ac_status=$?
16022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16023   (exit $ac_status); }; } &&
16024          { ac_try='test -s conftest.$ac_objext'
16025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16026   (eval $ac_try) 2>&5
16027   ac_status=$?
16028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16029   (exit $ac_status); }; }; then
16030   ac_cv_have_decl_ptrace=yes
16031 else
16032   echo "$as_me: failed program was:" >&5
16033 sed 's/^/| /' conftest.$ac_ext >&5
16034
16035 ac_cv_have_decl_ptrace=no
16036 fi
16037 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16038 fi
16039 echo "$as_me:$LINENO: result: $ac_cv_have_decl_ptrace" >&5
16040 echo "${ECHO_T}$ac_cv_have_decl_ptrace" >&6
16041 if test $ac_cv_have_decl_ptrace = yes; then
16042
16043 cat >>confdefs.h <<_ACEOF
16044 #define HAVE_DECL_PTRACE 1
16045 _ACEOF
16046
16047
16048 else
16049   cat >>confdefs.h <<_ACEOF
16050 #define HAVE_DECL_PTRACE 0
16051 _ACEOF
16052
16053
16054   : ${gdb_cv_func_ptrace_ret='int'}
16055   : ${gdb_cv_func_ptrace_args='int,int,long,long'}
16056
16057 fi
16058
16059
16060 # Check return type.  Varargs (used on GNU/Linux) conflict with the
16061 # empty argument list, so check for that explicitly.
16062 echo "$as_me:$LINENO: checking return type of ptrace" >&5
16063 echo $ECHO_N "checking return type of ptrace... $ECHO_C" >&6
16064 if test "${gdb_cv_func_ptrace_ret+set}" = set; then
16065   echo $ECHO_N "(cached) $ECHO_C" >&6
16066 else
16067   cat >conftest.$ac_ext <<_ACEOF
16068 /* confdefs.h.  */
16069 _ACEOF
16070 cat confdefs.h >>conftest.$ac_ext
16071 cat >>conftest.$ac_ext <<_ACEOF
16072 /* end confdefs.h.  */
16073 $gdb_ptrace_headers
16074 int
16075 main ()
16076 {
16077 extern long ptrace (enum __ptrace_request, ...);
16078   ;
16079   return 0;
16080 }
16081 _ACEOF
16082 rm -f conftest.$ac_objext
16083 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16084   (eval $ac_compile) 2>conftest.er1
16085   ac_status=$?
16086   grep -v '^ *+' conftest.er1 >conftest.err
16087   rm -f conftest.er1
16088   cat conftest.err >&5
16089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16090   (exit $ac_status); } &&
16091          { ac_try='test -z "$ac_c_werror_flag"
16092                          || test ! -s conftest.err'
16093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16094   (eval $ac_try) 2>&5
16095   ac_status=$?
16096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16097   (exit $ac_status); }; } &&
16098          { ac_try='test -s conftest.$ac_objext'
16099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16100   (eval $ac_try) 2>&5
16101   ac_status=$?
16102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16103   (exit $ac_status); }; }; then
16104   gdb_cv_func_ptrace_ret='long'
16105 else
16106   echo "$as_me: failed program was:" >&5
16107 sed 's/^/| /' conftest.$ac_ext >&5
16108
16109 cat >conftest.$ac_ext <<_ACEOF
16110 /* confdefs.h.  */
16111 _ACEOF
16112 cat confdefs.h >>conftest.$ac_ext
16113 cat >>conftest.$ac_ext <<_ACEOF
16114 /* end confdefs.h.  */
16115 $gdb_ptrace_headers
16116 int
16117 main ()
16118 {
16119 extern int ptrace ();
16120   ;
16121   return 0;
16122 }
16123 _ACEOF
16124 rm -f conftest.$ac_objext
16125 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16126   (eval $ac_compile) 2>conftest.er1
16127   ac_status=$?
16128   grep -v '^ *+' conftest.er1 >conftest.err
16129   rm -f conftest.er1
16130   cat conftest.err >&5
16131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16132   (exit $ac_status); } &&
16133          { ac_try='test -z "$ac_c_werror_flag"
16134                          || test ! -s conftest.err'
16135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16136   (eval $ac_try) 2>&5
16137   ac_status=$?
16138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16139   (exit $ac_status); }; } &&
16140          { ac_try='test -s conftest.$ac_objext'
16141   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16142   (eval $ac_try) 2>&5
16143   ac_status=$?
16144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16145   (exit $ac_status); }; }; then
16146   gdb_cv_func_ptrace_ret='int'
16147 else
16148   echo "$as_me: failed program was:" >&5
16149 sed 's/^/| /' conftest.$ac_ext >&5
16150
16151 gdb_cv_func_ptrace_ret='long'
16152 fi
16153 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16154 fi
16155 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16156 fi
16157 echo "$as_me:$LINENO: result: $gdb_cv_func_ptrace_ret" >&5
16158 echo "${ECHO_T}$gdb_cv_func_ptrace_ret" >&6
16159
16160 cat >>confdefs.h <<_ACEOF
16161 #define PTRACE_TYPE_RET $gdb_cv_func_ptrace_ret
16162 _ACEOF
16163
16164 # Check argument types.
16165 echo "$as_me:$LINENO: checking types of arguments for ptrace" >&5
16166 echo $ECHO_N "checking types of arguments for ptrace... $ECHO_C" >&6
16167 if test "${gdb_cv_func_ptrace_args+set}" = set; then
16168   echo $ECHO_N "(cached) $ECHO_C" >&6
16169 else
16170
16171   cat >conftest.$ac_ext <<_ACEOF
16172 /* confdefs.h.  */
16173 _ACEOF
16174 cat confdefs.h >>conftest.$ac_ext
16175 cat >>conftest.$ac_ext <<_ACEOF
16176 /* end confdefs.h.  */
16177 $gdb_ptrace_headers
16178 int
16179 main ()
16180 {
16181 extern long ptrace (enum __ptrace_request, ...);
16182   ;
16183   return 0;
16184 }
16185 _ACEOF
16186 rm -f conftest.$ac_objext
16187 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16188   (eval $ac_compile) 2>conftest.er1
16189   ac_status=$?
16190   grep -v '^ *+' conftest.er1 >conftest.err
16191   rm -f conftest.er1
16192   cat conftest.err >&5
16193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16194   (exit $ac_status); } &&
16195          { ac_try='test -z "$ac_c_werror_flag"
16196                          || test ! -s conftest.err'
16197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16198   (eval $ac_try) 2>&5
16199   ac_status=$?
16200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16201   (exit $ac_status); }; } &&
16202          { ac_try='test -s conftest.$ac_objext'
16203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16204   (eval $ac_try) 2>&5
16205   ac_status=$?
16206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16207   (exit $ac_status); }; }; then
16208   gdb_cv_func_ptrace_args='int,int,long,long'
16209 else
16210   echo "$as_me: failed program was:" >&5
16211 sed 's/^/| /' conftest.$ac_ext >&5
16212
16213
16214 for gdb_arg1 in 'int' 'long'; do
16215  for gdb_arg2 in 'pid_t' 'int' 'long'; do
16216   for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
16217    for gdb_arg4 in 'int' 'long'; do
16218      cat >conftest.$ac_ext <<_ACEOF
16219 /* confdefs.h.  */
16220 _ACEOF
16221 cat confdefs.h >>conftest.$ac_ext
16222 cat >>conftest.$ac_ext <<_ACEOF
16223 /* end confdefs.h.  */
16224 $gdb_ptrace_headers
16225 int
16226 main ()
16227 {
16228
16229 extern $gdb_cv_func_ptrace_ret
16230   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4);
16231
16232   ;
16233   return 0;
16234 }
16235 _ACEOF
16236 rm -f conftest.$ac_objext
16237 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16238   (eval $ac_compile) 2>conftest.er1
16239   ac_status=$?
16240   grep -v '^ *+' conftest.er1 >conftest.err
16241   rm -f conftest.er1
16242   cat conftest.err >&5
16243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16244   (exit $ac_status); } &&
16245          { ac_try='test -z "$ac_c_werror_flag"
16246                          || test ! -s conftest.err'
16247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16248   (eval $ac_try) 2>&5
16249   ac_status=$?
16250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16251   (exit $ac_status); }; } &&
16252          { ac_try='test -s conftest.$ac_objext'
16253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16254   (eval $ac_try) 2>&5
16255   ac_status=$?
16256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16257   (exit $ac_status); }; }; then
16258   gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4";
16259     break 4;
16260 else
16261   echo "$as_me: failed program was:" >&5
16262 sed 's/^/| /' conftest.$ac_ext >&5
16263
16264 fi
16265 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16266     for gdb_arg5 in 'int *' 'int' 'long'; do
16267      cat >conftest.$ac_ext <<_ACEOF
16268 /* confdefs.h.  */
16269 _ACEOF
16270 cat confdefs.h >>conftest.$ac_ext
16271 cat >>conftest.$ac_ext <<_ACEOF
16272 /* end confdefs.h.  */
16273 $gdb_ptrace_headers
16274 int
16275 main ()
16276 {
16277
16278 extern $gdb_cv_func_ptrace_ret
16279   ptrace ($gdb_arg1, $gdb_arg2, $gdb_arg3, $gdb_arg4, $gdb_arg5);
16280
16281   ;
16282   return 0;
16283 }
16284 _ACEOF
16285 rm -f conftest.$ac_objext
16286 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16287   (eval $ac_compile) 2>conftest.er1
16288   ac_status=$?
16289   grep -v '^ *+' conftest.er1 >conftest.err
16290   rm -f conftest.er1
16291   cat conftest.err >&5
16292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16293   (exit $ac_status); } &&
16294          { ac_try='test -z "$ac_c_werror_flag"
16295                          || test ! -s conftest.err'
16296   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16297   (eval $ac_try) 2>&5
16298   ac_status=$?
16299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16300   (exit $ac_status); }; } &&
16301          { ac_try='test -s conftest.$ac_objext'
16302   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16303   (eval $ac_try) 2>&5
16304   ac_status=$?
16305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16306   (exit $ac_status); }; }; then
16307
16308 gdb_cv_func_ptrace_args="$gdb_arg1,$gdb_arg2,$gdb_arg3,$gdb_arg4,$gdb_arg5";
16309     break 5;
16310 else
16311   echo "$as_me: failed program was:" >&5
16312 sed 's/^/| /' conftest.$ac_ext >&5
16313
16314 fi
16315 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16316     done
16317    done
16318   done
16319  done
16320 done
16321 # Provide a safe default value.
16322 : ${gdb_cv_func_ptrace_args='int,int,long,long'}
16323
16324 fi
16325 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16326 fi
16327 echo "$as_me:$LINENO: result: $gdb_cv_func_ptrace_args" >&5
16328 echo "${ECHO_T}$gdb_cv_func_ptrace_args" >&6
16329 ac_save_IFS=$IFS; IFS=','
16330 set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
16331 IFS=$ac_save_IFS
16332 shift
16333
16334 cat >>confdefs.h <<_ACEOF
16335 #define PTRACE_TYPE_ARG3 $3
16336 _ACEOF
16337
16338 if test -n "$5"; then
16339
16340 cat >>confdefs.h <<_ACEOF
16341 #define PTRACE_TYPE_ARG5 $5
16342 _ACEOF
16343
16344 fi
16345
16346 if test "$cross_compiling" = no; then
16347   echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
16348 echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
16349 if test "${ac_cv_func_setpgrp_void+set}" = set; then
16350   echo $ECHO_N "(cached) $ECHO_C" >&6
16351 else
16352   if test "$cross_compiling" = yes; then
16353   { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5
16354 echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
16355    { (exit 1); exit 1; }; }
16356 else
16357   cat >conftest.$ac_ext <<_ACEOF
16358 /* confdefs.h.  */
16359 _ACEOF
16360 cat confdefs.h >>conftest.$ac_ext
16361 cat >>conftest.$ac_ext <<_ACEOF
16362 /* end confdefs.h.  */
16363 #if HAVE_UNISTD_H
16364 # include <unistd.h>
16365 #endif
16366
16367 int
16368 main ()
16369 {
16370 /* If this system has a BSD-style setpgrp which takes arguments,
16371   setpgrp(1, 1) will fail with ESRCH and return -1, in that case
16372   exit successfully. */
16373   exit (setpgrp (1,1) == -1 ? 0 : 1);
16374   ;
16375   return 0;
16376 }
16377 _ACEOF
16378 rm -f conftest$ac_exeext
16379 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16380   (eval $ac_link) 2>&5
16381   ac_status=$?
16382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16383   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16384   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16385   (eval $ac_try) 2>&5
16386   ac_status=$?
16387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16388   (exit $ac_status); }; }; then
16389   ac_cv_func_setpgrp_void=no
16390 else
16391   echo "$as_me: program exited with status $ac_status" >&5
16392 echo "$as_me: failed program was:" >&5
16393 sed 's/^/| /' conftest.$ac_ext >&5
16394
16395 ( exit $ac_status )
16396 ac_cv_func_setpgrp_void=yes
16397 fi
16398 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16399 fi
16400 fi
16401 echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
16402 echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
16403 if test $ac_cv_func_setpgrp_void = yes; then
16404
16405 cat >>confdefs.h <<\_ACEOF
16406 #define SETPGRP_VOID 1
16407 _ACEOF
16408
16409 fi
16410
16411 else
16412   echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
16413 echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
16414 if test "${ac_cv_func_setpgrp_void+set}" = set; then
16415   echo $ECHO_N "(cached) $ECHO_C" >&6
16416 else
16417   cat >conftest.$ac_ext <<_ACEOF
16418 /* confdefs.h.  */
16419 _ACEOF
16420 cat confdefs.h >>conftest.$ac_ext
16421 cat >>conftest.$ac_ext <<_ACEOF
16422 /* end confdefs.h.  */
16423
16424 #include <unistd.h>
16425
16426 int
16427 main ()
16428 {
16429
16430   if (setpgrp(1,1) == -1)
16431     exit (0);
16432   else
16433     exit (1);
16434
16435   ;
16436   return 0;
16437 }
16438 _ACEOF
16439 rm -f conftest.$ac_objext
16440 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16441   (eval $ac_compile) 2>conftest.er1
16442   ac_status=$?
16443   grep -v '^ *+' conftest.er1 >conftest.err
16444   rm -f conftest.er1
16445   cat conftest.err >&5
16446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16447   (exit $ac_status); } &&
16448          { ac_try='test -z "$ac_c_werror_flag"
16449                          || test ! -s conftest.err'
16450   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16451   (eval $ac_try) 2>&5
16452   ac_status=$?
16453   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16454   (exit $ac_status); }; } &&
16455          { ac_try='test -s conftest.$ac_objext'
16456   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16457   (eval $ac_try) 2>&5
16458   ac_status=$?
16459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16460   (exit $ac_status); }; }; then
16461   ac_cv_func_setpgrp_void=no
16462 else
16463   echo "$as_me: failed program was:" >&5
16464 sed 's/^/| /' conftest.$ac_ext >&5
16465
16466 ac_cv_func_setpgrp_void=yes
16467 fi
16468 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16469 fi
16470 echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
16471 echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
16472 if test $ac_cv_func_setpgrp_void = yes; then
16473   cat >>confdefs.h <<\_ACEOF
16474 #define SETPGRP_VOID 1
16475 _ACEOF
16476
16477 fi
16478 fi
16479
16480 # Check if sigsetjmp is available.  Using AC_CHECK_FUNCS won't do
16481 # since sigsetjmp might only be defined as a macro.
16482 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
16483 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
16484 if test "${gdb_cv_func_sigsetjmp+set}" = set; then
16485   echo $ECHO_N "(cached) $ECHO_C" >&6
16486 else
16487   cat >conftest.$ac_ext <<_ACEOF
16488 /* confdefs.h.  */
16489 _ACEOF
16490 cat confdefs.h >>conftest.$ac_ext
16491 cat >>conftest.$ac_ext <<_ACEOF
16492 /* end confdefs.h.  */
16493
16494 #include <setjmp.h>
16495
16496 int
16497 main ()
16498 {
16499 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
16500   ;
16501   return 0;
16502 }
16503 _ACEOF
16504 rm -f conftest.$ac_objext
16505 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16506   (eval $ac_compile) 2>conftest.er1
16507   ac_status=$?
16508   grep -v '^ *+' conftest.er1 >conftest.err
16509   rm -f conftest.er1
16510   cat conftest.err >&5
16511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16512   (exit $ac_status); } &&
16513          { ac_try='test -z "$ac_c_werror_flag"
16514                          || test ! -s conftest.err'
16515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16516   (eval $ac_try) 2>&5
16517   ac_status=$?
16518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16519   (exit $ac_status); }; } &&
16520          { ac_try='test -s conftest.$ac_objext'
16521   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16522   (eval $ac_try) 2>&5
16523   ac_status=$?
16524   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16525   (exit $ac_status); }; }; then
16526   gdb_cv_func_sigsetjmp=yes
16527 else
16528   echo "$as_me: failed program was:" >&5
16529 sed 's/^/| /' conftest.$ac_ext >&5
16530
16531 gdb_cv_func_sigsetjmp=no
16532 fi
16533 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16534 fi
16535 echo "$as_me:$LINENO: result: $gdb_cv_func_sigsetjmp" >&5
16536 echo "${ECHO_T}$gdb_cv_func_sigsetjmp" >&6
16537 if test $gdb_cv_func_sigsetjmp = yes; then
16538
16539 cat >>confdefs.h <<\_ACEOF
16540 #define HAVE_SIGSETJMP 1
16541 _ACEOF
16542
16543 fi
16544
16545 # Assume we'll default to using the included libiberty regex.
16546 gdb_use_included_regex=yes
16547
16548 # However, if the system regex is GNU regex, then default to *not*
16549 # using the included regex.
16550 echo "$as_me:$LINENO: checking for GNU regex" >&5
16551 echo $ECHO_N "checking for GNU regex... $ECHO_C" >&6
16552 if test "${gdb_cv_have_gnu_regex+set}" = set; then
16553   echo $ECHO_N "(cached) $ECHO_C" >&6
16554 else
16555   cat >conftest.$ac_ext <<_ACEOF
16556 /* confdefs.h.  */
16557 _ACEOF
16558 cat confdefs.h >>conftest.$ac_ext
16559 cat >>conftest.$ac_ext <<_ACEOF
16560 /* end confdefs.h.  */
16561 #include <gnu-versions.h>
16562 int
16563 main ()
16564 {
16565 #define REGEX_INTERFACE_VERSION 1
16566 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
16567 # error "Version mismatch"
16568 #endif
16569   ;
16570   return 0;
16571 }
16572 _ACEOF
16573 rm -f conftest.$ac_objext
16574 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16575   (eval $ac_compile) 2>conftest.er1
16576   ac_status=$?
16577   grep -v '^ *+' conftest.er1 >conftest.err
16578   rm -f conftest.er1
16579   cat conftest.err >&5
16580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16581   (exit $ac_status); } &&
16582          { ac_try='test -z "$ac_c_werror_flag"
16583                          || test ! -s conftest.err'
16584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16585   (eval $ac_try) 2>&5
16586   ac_status=$?
16587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16588   (exit $ac_status); }; } &&
16589          { ac_try='test -s conftest.$ac_objext'
16590   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16591   (eval $ac_try) 2>&5
16592   ac_status=$?
16593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16594   (exit $ac_status); }; }; then
16595   gdb_cv_have_gnu_regex=yes
16596 else
16597   echo "$as_me: failed program was:" >&5
16598 sed 's/^/| /' conftest.$ac_ext >&5
16599
16600 gdb_cv_have_gnu_regex=no
16601 fi
16602 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16603 fi
16604 echo "$as_me:$LINENO: result: $gdb_cv_have_gnu_regex" >&5
16605 echo "${ECHO_T}$gdb_cv_have_gnu_regex" >&6
16606 if test $gdb_cv_have_gnu_regex = yes; then
16607   gdb_use_included_regex=no
16608 fi
16609
16610
16611 # Check whether --with-included-regex or --without-included-regex was given.
16612 if test "${with_included_regex+set}" = set; then
16613   withval="$with_included_regex"
16614   gdb_with_regex=$withval
16615 else
16616   gdb_with_regex=$gdb_use_included_regex
16617 fi;
16618 if test "$gdb_with_regex" = yes; then
16619
16620 cat >>confdefs.h <<\_ACEOF
16621 #define USE_INCLUDED_REGEX 1
16622 _ACEOF
16623
16624 fi
16625
16626 # Check if <sys/proc.h> defines `struct thread' with a td_pcb member.
16627 echo "$as_me:$LINENO: checking for struct thread.td_pcb" >&5
16628 echo $ECHO_N "checking for struct thread.td_pcb... $ECHO_C" >&6
16629 if test "${ac_cv_member_struct_thread_td_pcb+set}" = set; then
16630   echo $ECHO_N "(cached) $ECHO_C" >&6
16631 else
16632   cat >conftest.$ac_ext <<_ACEOF
16633 /* confdefs.h.  */
16634 _ACEOF
16635 cat confdefs.h >>conftest.$ac_ext
16636 cat >>conftest.$ac_ext <<_ACEOF
16637 /* end confdefs.h.  */
16638 #include <sys/param.h>
16639 #include <sys/proc.h>
16640
16641
16642 int
16643 main ()
16644 {
16645 static struct thread ac_aggr;
16646 if (ac_aggr.td_pcb)
16647 return 0;
16648   ;
16649   return 0;
16650 }
16651 _ACEOF
16652 rm -f conftest.$ac_objext
16653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16654   (eval $ac_compile) 2>conftest.er1
16655   ac_status=$?
16656   grep -v '^ *+' conftest.er1 >conftest.err
16657   rm -f conftest.er1
16658   cat conftest.err >&5
16659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16660   (exit $ac_status); } &&
16661          { ac_try='test -z "$ac_c_werror_flag"
16662                          || test ! -s conftest.err'
16663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16664   (eval $ac_try) 2>&5
16665   ac_status=$?
16666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16667   (exit $ac_status); }; } &&
16668          { ac_try='test -s conftest.$ac_objext'
16669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16670   (eval $ac_try) 2>&5
16671   ac_status=$?
16672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16673   (exit $ac_status); }; }; then
16674   ac_cv_member_struct_thread_td_pcb=yes
16675 else
16676   echo "$as_me: failed program was:" >&5
16677 sed 's/^/| /' conftest.$ac_ext >&5
16678
16679 cat >conftest.$ac_ext <<_ACEOF
16680 /* confdefs.h.  */
16681 _ACEOF
16682 cat confdefs.h >>conftest.$ac_ext
16683 cat >>conftest.$ac_ext <<_ACEOF
16684 /* end confdefs.h.  */
16685 #include <sys/param.h>
16686 #include <sys/proc.h>
16687
16688
16689 int
16690 main ()
16691 {
16692 static struct thread ac_aggr;
16693 if (sizeof ac_aggr.td_pcb)
16694 return 0;
16695   ;
16696   return 0;
16697 }
16698 _ACEOF
16699 rm -f conftest.$ac_objext
16700 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16701   (eval $ac_compile) 2>conftest.er1
16702   ac_status=$?
16703   grep -v '^ *+' conftest.er1 >conftest.err
16704   rm -f conftest.er1
16705   cat conftest.err >&5
16706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16707   (exit $ac_status); } &&
16708          { ac_try='test -z "$ac_c_werror_flag"
16709                          || test ! -s conftest.err'
16710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16711   (eval $ac_try) 2>&5
16712   ac_status=$?
16713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16714   (exit $ac_status); }; } &&
16715          { ac_try='test -s conftest.$ac_objext'
16716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16717   (eval $ac_try) 2>&5
16718   ac_status=$?
16719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16720   (exit $ac_status); }; }; then
16721   ac_cv_member_struct_thread_td_pcb=yes
16722 else
16723   echo "$as_me: failed program was:" >&5
16724 sed 's/^/| /' conftest.$ac_ext >&5
16725
16726 ac_cv_member_struct_thread_td_pcb=no
16727 fi
16728 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16729 fi
16730 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16731 fi
16732 echo "$as_me:$LINENO: result: $ac_cv_member_struct_thread_td_pcb" >&5
16733 echo "${ECHO_T}$ac_cv_member_struct_thread_td_pcb" >&6
16734 if test $ac_cv_member_struct_thread_td_pcb = yes; then
16735
16736 cat >>confdefs.h <<_ACEOF
16737 #define HAVE_STRUCT_THREAD_TD_PCB 1
16738 _ACEOF
16739
16740
16741 fi
16742
16743
16744 # See if <sys/lwp.h> defines `struct lwp`.
16745 echo "$as_me:$LINENO: checking for struct lwp" >&5
16746 echo $ECHO_N "checking for struct lwp... $ECHO_C" >&6
16747 if test "${gdb_cv_struct_lwp+set}" = set; then
16748   echo $ECHO_N "(cached) $ECHO_C" >&6
16749 else
16750   cat >conftest.$ac_ext <<_ACEOF
16751 /* confdefs.h.  */
16752 _ACEOF
16753 cat confdefs.h >>conftest.$ac_ext
16754 cat >>conftest.$ac_ext <<_ACEOF
16755 /* end confdefs.h.  */
16756 #include <sys/param.h>
16757 #include <sys/lwp.h>
16758 int
16759 main ()
16760 {
16761 struct lwp l;
16762   ;
16763   return 0;
16764 }
16765 _ACEOF
16766 rm -f conftest.$ac_objext
16767 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16768   (eval $ac_compile) 2>conftest.er1
16769   ac_status=$?
16770   grep -v '^ *+' conftest.er1 >conftest.err
16771   rm -f conftest.er1
16772   cat conftest.err >&5
16773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16774   (exit $ac_status); } &&
16775          { ac_try='test -z "$ac_c_werror_flag"
16776                          || test ! -s conftest.err'
16777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16778   (eval $ac_try) 2>&5
16779   ac_status=$?
16780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16781   (exit $ac_status); }; } &&
16782          { ac_try='test -s conftest.$ac_objext'
16783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16784   (eval $ac_try) 2>&5
16785   ac_status=$?
16786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16787   (exit $ac_status); }; }; then
16788   gdb_cv_struct_lwp=yes
16789 else
16790   echo "$as_me: failed program was:" >&5
16791 sed 's/^/| /' conftest.$ac_ext >&5
16792
16793 gdb_cv_struct_lwp=no
16794 fi
16795 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16796 fi
16797 echo "$as_me:$LINENO: result: $gdb_cv_struct_lwp" >&5
16798 echo "${ECHO_T}$gdb_cv_struct_lwp" >&6
16799 if test $gdb_cv_struct_lwp = yes; then
16800
16801 cat >>confdefs.h <<\_ACEOF
16802 #define HAVE_STRUCT_LWP 1
16803 _ACEOF
16804
16805 fi
16806
16807 # See if <machine/reg.h> degines `struct reg'.
16808 echo "$as_me:$LINENO: checking for struct reg in machine/reg.h" >&5
16809 echo $ECHO_N "checking for struct reg in machine/reg.h... $ECHO_C" >&6
16810 if test "${gdb_cv_struct_reg+set}" = set; then
16811   echo $ECHO_N "(cached) $ECHO_C" >&6
16812 else
16813   cat >conftest.$ac_ext <<_ACEOF
16814 /* confdefs.h.  */
16815 _ACEOF
16816 cat confdefs.h >>conftest.$ac_ext
16817 cat >>conftest.$ac_ext <<_ACEOF
16818 /* end confdefs.h.  */
16819 #include <sys/types.h>
16820 #include <machine/reg.h>
16821 int
16822 main ()
16823 {
16824 struct reg r;
16825   ;
16826   return 0;
16827 }
16828 _ACEOF
16829 rm -f conftest.$ac_objext
16830 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16831   (eval $ac_compile) 2>conftest.er1
16832   ac_status=$?
16833   grep -v '^ *+' conftest.er1 >conftest.err
16834   rm -f conftest.er1
16835   cat conftest.err >&5
16836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16837   (exit $ac_status); } &&
16838          { ac_try='test -z "$ac_c_werror_flag"
16839                          || test ! -s conftest.err'
16840   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16841   (eval $ac_try) 2>&5
16842   ac_status=$?
16843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16844   (exit $ac_status); }; } &&
16845          { ac_try='test -s conftest.$ac_objext'
16846   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16847   (eval $ac_try) 2>&5
16848   ac_status=$?
16849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16850   (exit $ac_status); }; }; then
16851   gdb_cv_struct_reg=yes
16852 else
16853   echo "$as_me: failed program was:" >&5
16854 sed 's/^/| /' conftest.$ac_ext >&5
16855
16856 gdb_cv_struct_reg=no
16857 fi
16858 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16859 fi
16860 echo "$as_me:$LINENO: result: $gdb_cv_struct_reg" >&5
16861 echo "${ECHO_T}$gdb_cv_struct_reg" >&6
16862 if test $gdb_cv_struct_reg = yes; then
16863
16864 cat >>confdefs.h <<\_ACEOF
16865 #define HAVE_STRUCT_REG 1
16866 _ACEOF
16867
16868 fi
16869
16870 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
16871 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
16872 echo "$as_me:$LINENO: checking for struct reg.r_fs" >&5
16873 echo $ECHO_N "checking for struct reg.r_fs... $ECHO_C" >&6
16874 if test "${ac_cv_member_struct_reg_r_fs+set}" = set; then
16875   echo $ECHO_N "(cached) $ECHO_C" >&6
16876 else
16877   cat >conftest.$ac_ext <<_ACEOF
16878 /* confdefs.h.  */
16879 _ACEOF
16880 cat confdefs.h >>conftest.$ac_ext
16881 cat >>conftest.$ac_ext <<_ACEOF
16882 /* end confdefs.h.  */
16883 #include <machine/reg.h>
16884
16885 int
16886 main ()
16887 {
16888 static struct reg ac_aggr;
16889 if (ac_aggr.r_fs)
16890 return 0;
16891   ;
16892   return 0;
16893 }
16894 _ACEOF
16895 rm -f conftest.$ac_objext
16896 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16897   (eval $ac_compile) 2>conftest.er1
16898   ac_status=$?
16899   grep -v '^ *+' conftest.er1 >conftest.err
16900   rm -f conftest.er1
16901   cat conftest.err >&5
16902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16903   (exit $ac_status); } &&
16904          { ac_try='test -z "$ac_c_werror_flag"
16905                          || test ! -s conftest.err'
16906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16907   (eval $ac_try) 2>&5
16908   ac_status=$?
16909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16910   (exit $ac_status); }; } &&
16911          { ac_try='test -s conftest.$ac_objext'
16912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16913   (eval $ac_try) 2>&5
16914   ac_status=$?
16915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16916   (exit $ac_status); }; }; then
16917   ac_cv_member_struct_reg_r_fs=yes
16918 else
16919   echo "$as_me: failed program was:" >&5
16920 sed 's/^/| /' conftest.$ac_ext >&5
16921
16922 cat >conftest.$ac_ext <<_ACEOF
16923 /* confdefs.h.  */
16924 _ACEOF
16925 cat confdefs.h >>conftest.$ac_ext
16926 cat >>conftest.$ac_ext <<_ACEOF
16927 /* end confdefs.h.  */
16928 #include <machine/reg.h>
16929
16930 int
16931 main ()
16932 {
16933 static struct reg ac_aggr;
16934 if (sizeof ac_aggr.r_fs)
16935 return 0;
16936   ;
16937   return 0;
16938 }
16939 _ACEOF
16940 rm -f conftest.$ac_objext
16941 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16942   (eval $ac_compile) 2>conftest.er1
16943   ac_status=$?
16944   grep -v '^ *+' conftest.er1 >conftest.err
16945   rm -f conftest.er1
16946   cat conftest.err >&5
16947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16948   (exit $ac_status); } &&
16949          { ac_try='test -z "$ac_c_werror_flag"
16950                          || test ! -s conftest.err'
16951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16952   (eval $ac_try) 2>&5
16953   ac_status=$?
16954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16955   (exit $ac_status); }; } &&
16956          { ac_try='test -s conftest.$ac_objext'
16957   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16958   (eval $ac_try) 2>&5
16959   ac_status=$?
16960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16961   (exit $ac_status); }; }; then
16962   ac_cv_member_struct_reg_r_fs=yes
16963 else
16964   echo "$as_me: failed program was:" >&5
16965 sed 's/^/| /' conftest.$ac_ext >&5
16966
16967 ac_cv_member_struct_reg_r_fs=no
16968 fi
16969 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16970 fi
16971 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16972 fi
16973 echo "$as_me:$LINENO: result: $ac_cv_member_struct_reg_r_fs" >&5
16974 echo "${ECHO_T}$ac_cv_member_struct_reg_r_fs" >&6
16975 if test $ac_cv_member_struct_reg_r_fs = yes; then
16976
16977 cat >>confdefs.h <<_ACEOF
16978 #define HAVE_STRUCT_REG_R_FS 1
16979 _ACEOF
16980
16981
16982 fi
16983 echo "$as_me:$LINENO: checking for struct reg.r_gs" >&5
16984 echo $ECHO_N "checking for struct reg.r_gs... $ECHO_C" >&6
16985 if test "${ac_cv_member_struct_reg_r_gs+set}" = set; then
16986   echo $ECHO_N "(cached) $ECHO_C" >&6
16987 else
16988   cat >conftest.$ac_ext <<_ACEOF
16989 /* confdefs.h.  */
16990 _ACEOF
16991 cat confdefs.h >>conftest.$ac_ext
16992 cat >>conftest.$ac_ext <<_ACEOF
16993 /* end confdefs.h.  */
16994 #include <machine/reg.h>
16995
16996 int
16997 main ()
16998 {
16999 static struct reg ac_aggr;
17000 if (ac_aggr.r_gs)
17001 return 0;
17002   ;
17003   return 0;
17004 }
17005 _ACEOF
17006 rm -f conftest.$ac_objext
17007 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17008   (eval $ac_compile) 2>conftest.er1
17009   ac_status=$?
17010   grep -v '^ *+' conftest.er1 >conftest.err
17011   rm -f conftest.er1
17012   cat conftest.err >&5
17013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17014   (exit $ac_status); } &&
17015          { ac_try='test -z "$ac_c_werror_flag"
17016                          || test ! -s conftest.err'
17017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17018   (eval $ac_try) 2>&5
17019   ac_status=$?
17020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17021   (exit $ac_status); }; } &&
17022          { ac_try='test -s conftest.$ac_objext'
17023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17024   (eval $ac_try) 2>&5
17025   ac_status=$?
17026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17027   (exit $ac_status); }; }; then
17028   ac_cv_member_struct_reg_r_gs=yes
17029 else
17030   echo "$as_me: failed program was:" >&5
17031 sed 's/^/| /' conftest.$ac_ext >&5
17032
17033 cat >conftest.$ac_ext <<_ACEOF
17034 /* confdefs.h.  */
17035 _ACEOF
17036 cat confdefs.h >>conftest.$ac_ext
17037 cat >>conftest.$ac_ext <<_ACEOF
17038 /* end confdefs.h.  */
17039 #include <machine/reg.h>
17040
17041 int
17042 main ()
17043 {
17044 static struct reg ac_aggr;
17045 if (sizeof ac_aggr.r_gs)
17046 return 0;
17047   ;
17048   return 0;
17049 }
17050 _ACEOF
17051 rm -f conftest.$ac_objext
17052 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17053   (eval $ac_compile) 2>conftest.er1
17054   ac_status=$?
17055   grep -v '^ *+' conftest.er1 >conftest.err
17056   rm -f conftest.er1
17057   cat conftest.err >&5
17058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17059   (exit $ac_status); } &&
17060          { ac_try='test -z "$ac_c_werror_flag"
17061                          || test ! -s conftest.err'
17062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17063   (eval $ac_try) 2>&5
17064   ac_status=$?
17065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17066   (exit $ac_status); }; } &&
17067          { ac_try='test -s conftest.$ac_objext'
17068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17069   (eval $ac_try) 2>&5
17070   ac_status=$?
17071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17072   (exit $ac_status); }; }; then
17073   ac_cv_member_struct_reg_r_gs=yes
17074 else
17075   echo "$as_me: failed program was:" >&5
17076 sed 's/^/| /' conftest.$ac_ext >&5
17077
17078 ac_cv_member_struct_reg_r_gs=no
17079 fi
17080 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17081 fi
17082 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17083 fi
17084 echo "$as_me:$LINENO: result: $ac_cv_member_struct_reg_r_gs" >&5
17085 echo "${ECHO_T}$ac_cv_member_struct_reg_r_gs" >&6
17086 if test $ac_cv_member_struct_reg_r_gs = yes; then
17087
17088 cat >>confdefs.h <<_ACEOF
17089 #define HAVE_STRUCT_REG_R_GS 1
17090 _ACEOF
17091
17092
17093 fi
17094
17095
17096 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
17097 echo "$as_me:$LINENO: checking for PTRACE_GETREGS" >&5
17098 echo $ECHO_N "checking for PTRACE_GETREGS... $ECHO_C" >&6
17099 if test "${gdb_cv_have_ptrace_getregs+set}" = set; then
17100   echo $ECHO_N "(cached) $ECHO_C" >&6
17101 else
17102   cat >conftest.$ac_ext <<_ACEOF
17103 /* confdefs.h.  */
17104 _ACEOF
17105 cat confdefs.h >>conftest.$ac_ext
17106 cat >>conftest.$ac_ext <<_ACEOF
17107 /* end confdefs.h.  */
17108 #include <sys/ptrace.h>
17109 int
17110 main ()
17111 {
17112 PTRACE_GETREGS;
17113   ;
17114   return 0;
17115 }
17116 _ACEOF
17117 rm -f conftest.$ac_objext
17118 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17119   (eval $ac_compile) 2>conftest.er1
17120   ac_status=$?
17121   grep -v '^ *+' conftest.er1 >conftest.err
17122   rm -f conftest.er1
17123   cat conftest.err >&5
17124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17125   (exit $ac_status); } &&
17126          { ac_try='test -z "$ac_c_werror_flag"
17127                          || test ! -s conftest.err'
17128   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17129   (eval $ac_try) 2>&5
17130   ac_status=$?
17131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17132   (exit $ac_status); }; } &&
17133          { ac_try='test -s conftest.$ac_objext'
17134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17135   (eval $ac_try) 2>&5
17136   ac_status=$?
17137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17138   (exit $ac_status); }; }; then
17139   gdb_cv_have_ptrace_getregs=yes
17140 else
17141   echo "$as_me: failed program was:" >&5
17142 sed 's/^/| /' conftest.$ac_ext >&5
17143
17144 gdb_cv_have_ptrace_getregs=no
17145 fi
17146 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17147 fi
17148
17149 echo "$as_me:$LINENO: result: $gdb_cv_have_ptrace_getregs" >&5
17150 echo "${ECHO_T}$gdb_cv_have_ptrace_getregs" >&6
17151 if test $gdb_cv_have_ptrace_getregs = yes; then
17152
17153 cat >>confdefs.h <<\_ACEOF
17154 #define HAVE_PTRACE_GETREGS 1
17155 _ACEOF
17156
17157 fi
17158
17159 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
17160 echo "$as_me:$LINENO: checking for PTRACE_GETFPXREGS" >&5
17161 echo $ECHO_N "checking for PTRACE_GETFPXREGS... $ECHO_C" >&6
17162 if test "${gdb_cv_have_ptrace_getfpxregs+set}" = set; then
17163   echo $ECHO_N "(cached) $ECHO_C" >&6
17164 else
17165   cat >conftest.$ac_ext <<_ACEOF
17166 /* confdefs.h.  */
17167 _ACEOF
17168 cat confdefs.h >>conftest.$ac_ext
17169 cat >>conftest.$ac_ext <<_ACEOF
17170 /* end confdefs.h.  */
17171 #include <sys/ptrace.h>
17172 int
17173 main ()
17174 {
17175 PTRACE_GETFPXREGS;
17176   ;
17177   return 0;
17178 }
17179 _ACEOF
17180 rm -f conftest.$ac_objext
17181 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17182   (eval $ac_compile) 2>conftest.er1
17183   ac_status=$?
17184   grep -v '^ *+' conftest.er1 >conftest.err
17185   rm -f conftest.er1
17186   cat conftest.err >&5
17187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17188   (exit $ac_status); } &&
17189          { ac_try='test -z "$ac_c_werror_flag"
17190                          || test ! -s conftest.err'
17191   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17192   (eval $ac_try) 2>&5
17193   ac_status=$?
17194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17195   (exit $ac_status); }; } &&
17196          { ac_try='test -s conftest.$ac_objext'
17197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17198   (eval $ac_try) 2>&5
17199   ac_status=$?
17200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17201   (exit $ac_status); }; }; then
17202   gdb_cv_have_ptrace_getfpxregs=yes
17203 else
17204   echo "$as_me: failed program was:" >&5
17205 sed 's/^/| /' conftest.$ac_ext >&5
17206
17207 gdb_cv_have_ptrace_getfpxregs=no
17208 fi
17209 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17210 fi
17211
17212 echo "$as_me:$LINENO: result: $gdb_cv_have_ptrace_getfpxregs" >&5
17213 echo "${ECHO_T}$gdb_cv_have_ptrace_getfpxregs" >&6
17214 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
17215
17216 cat >>confdefs.h <<\_ACEOF
17217 #define HAVE_PTRACE_GETFPXREGS 1
17218 _ACEOF
17219
17220 fi
17221
17222 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
17223 echo "$as_me:$LINENO: checking for PT_GETDBREGS" >&5
17224 echo $ECHO_N "checking for PT_GETDBREGS... $ECHO_C" >&6
17225 if test "${gdb_cv_have_pt_getdbregs+set}" = set; then
17226   echo $ECHO_N "(cached) $ECHO_C" >&6
17227 else
17228   cat >conftest.$ac_ext <<_ACEOF
17229 /* confdefs.h.  */
17230 _ACEOF
17231 cat confdefs.h >>conftest.$ac_ext
17232 cat >>conftest.$ac_ext <<_ACEOF
17233 /* end confdefs.h.  */
17234 #include <sys/types.h>
17235 #include <sys/ptrace.h>
17236 int
17237 main ()
17238 {
17239 PT_GETDBREGS;
17240   ;
17241   return 0;
17242 }
17243 _ACEOF
17244 rm -f conftest.$ac_objext
17245 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17246   (eval $ac_compile) 2>conftest.er1
17247   ac_status=$?
17248   grep -v '^ *+' conftest.er1 >conftest.err
17249   rm -f conftest.er1
17250   cat conftest.err >&5
17251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17252   (exit $ac_status); } &&
17253          { ac_try='test -z "$ac_c_werror_flag"
17254                          || test ! -s conftest.err'
17255   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17256   (eval $ac_try) 2>&5
17257   ac_status=$?
17258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17259   (exit $ac_status); }; } &&
17260          { ac_try='test -s conftest.$ac_objext'
17261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17262   (eval $ac_try) 2>&5
17263   ac_status=$?
17264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17265   (exit $ac_status); }; }; then
17266   gdb_cv_have_pt_getdbregs=yes
17267 else
17268   echo "$as_me: failed program was:" >&5
17269 sed 's/^/| /' conftest.$ac_ext >&5
17270
17271 gdb_cv_have_pt_getdbregs=no
17272 fi
17273 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17274 fi
17275
17276 echo "$as_me:$LINENO: result: $gdb_cv_have_pt_getdbregs" >&5
17277 echo "${ECHO_T}$gdb_cv_have_pt_getdbregs" >&6
17278 if test $gdb_cv_have_pt_getdbregs = yes; then
17279
17280 cat >>confdefs.h <<\_ACEOF
17281 #define HAVE_PT_GETDBREGS 1
17282 _ACEOF
17283
17284 fi
17285
17286 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
17287 echo "$as_me:$LINENO: checking for PT_GETXMMREGS" >&5
17288 echo $ECHO_N "checking for PT_GETXMMREGS... $ECHO_C" >&6
17289 if test "${gdb_cv_have_pt_getxmmregs+set}" = set; then
17290   echo $ECHO_N "(cached) $ECHO_C" >&6
17291 else
17292   cat >conftest.$ac_ext <<_ACEOF
17293 /* confdefs.h.  */
17294 _ACEOF
17295 cat confdefs.h >>conftest.$ac_ext
17296 cat >>conftest.$ac_ext <<_ACEOF
17297 /* end confdefs.h.  */
17298 #include <sys/types.h>
17299 #include <sys/ptrace.h>
17300 int
17301 main ()
17302 {
17303 PT_GETXMMREGS;
17304   ;
17305   return 0;
17306 }
17307 _ACEOF
17308 rm -f conftest.$ac_objext
17309 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17310   (eval $ac_compile) 2>conftest.er1
17311   ac_status=$?
17312   grep -v '^ *+' conftest.er1 >conftest.err
17313   rm -f conftest.er1
17314   cat conftest.err >&5
17315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17316   (exit $ac_status); } &&
17317          { ac_try='test -z "$ac_c_werror_flag"
17318                          || test ! -s conftest.err'
17319   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17320   (eval $ac_try) 2>&5
17321   ac_status=$?
17322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17323   (exit $ac_status); }; } &&
17324          { ac_try='test -s conftest.$ac_objext'
17325   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17326   (eval $ac_try) 2>&5
17327   ac_status=$?
17328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17329   (exit $ac_status); }; }; then
17330   gdb_cv_have_pt_getxmmregs=yes
17331 else
17332   echo "$as_me: failed program was:" >&5
17333 sed 's/^/| /' conftest.$ac_ext >&5
17334
17335 gdb_cv_have_pt_getxmmregs=no
17336 fi
17337 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17338 fi
17339
17340 echo "$as_me:$LINENO: result: $gdb_cv_have_pt_getxmmregs" >&5
17341 echo "${ECHO_T}$gdb_cv_have_pt_getxmmregs" >&6
17342 if test $gdb_cv_have_pt_getxmmregs = yes; then
17343
17344 cat >>confdefs.h <<\_ACEOF
17345 #define HAVE_PT_GETXMMREGS 1
17346 _ACEOF
17347
17348 fi
17349
17350 # Detect which type of /proc is in use, such as for Unixware or Solaris.
17351
17352 if test "${target}" = "${host}"; then
17353   case "${host}" in
17354   *-*-unixware* | *-*-sysv4.2* | *-*-sysv5* | *-*-interix* )
17355
17356 cat >>confdefs.h <<\_ACEOF
17357 #define NEW_PROC_API 1
17358 _ACEOF
17359
17360       ;;
17361   *-*-solaris2.[6789] | *-*-solaris2.1[0-9]*)
17362
17363 cat >>confdefs.h <<\_ACEOF
17364 #define NEW_PROC_API 1
17365 _ACEOF
17366
17367       ;;
17368   mips-sgi-irix5*)
17369       # Work around <sys/proc.h> needing _KMEMUSER problem on IRIX 5.
17370
17371 cat >>confdefs.h <<\_ACEOF
17372 #define _KMEMUSER 1
17373 _ACEOF
17374
17375       ;;
17376   esac
17377 fi
17378
17379 if test "$ac_cv_header_sys_procfs_h" = yes; then
17380   echo "$as_me:$LINENO: checking for pstatus_t in sys/procfs.h" >&5
17381 echo $ECHO_N "checking for pstatus_t in sys/procfs.h... $ECHO_C" >&6
17382  if test "${bfd_cv_have_sys_procfs_type_pstatus_t+set}" = set; then
17383   echo $ECHO_N "(cached) $ECHO_C" >&6
17384 else
17385   cat >conftest.$ac_ext <<_ACEOF
17386 /* confdefs.h.  */
17387 _ACEOF
17388 cat confdefs.h >>conftest.$ac_ext
17389 cat >>conftest.$ac_ext <<_ACEOF
17390 /* end confdefs.h.  */
17391
17392 #define _SYSCALL32
17393 #include <sys/procfs.h>
17394 int
17395 main ()
17396 {
17397 pstatus_t avar
17398   ;
17399   return 0;
17400 }
17401 _ACEOF
17402 rm -f conftest.$ac_objext
17403 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17404   (eval $ac_compile) 2>conftest.er1
17405   ac_status=$?
17406   grep -v '^ *+' conftest.er1 >conftest.err
17407   rm -f conftest.er1
17408   cat conftest.err >&5
17409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17410   (exit $ac_status); } &&
17411          { ac_try='test -z "$ac_c_werror_flag"
17412                          || test ! -s conftest.err'
17413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17414   (eval $ac_try) 2>&5
17415   ac_status=$?
17416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17417   (exit $ac_status); }; } &&
17418          { ac_try='test -s conftest.$ac_objext'
17419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17420   (eval $ac_try) 2>&5
17421   ac_status=$?
17422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17423   (exit $ac_status); }; }; then
17424   bfd_cv_have_sys_procfs_type_pstatus_t=yes
17425 else
17426   echo "$as_me: failed program was:" >&5
17427 sed 's/^/| /' conftest.$ac_ext >&5
17428
17429 bfd_cv_have_sys_procfs_type_pstatus_t=no
17430
17431 fi
17432 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17433 fi
17434
17435  if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
17436
17437 cat >>confdefs.h <<\_ACEOF
17438 #define HAVE_PSTATUS_T 1
17439 _ACEOF
17440
17441  fi
17442  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_pstatus_t" >&5
17443 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_pstatus_t" >&6
17444
17445   echo "$as_me:$LINENO: checking for prrun_t in sys/procfs.h" >&5
17446 echo $ECHO_N "checking for prrun_t in sys/procfs.h... $ECHO_C" >&6
17447  if test "${bfd_cv_have_sys_procfs_type_prrun_t+set}" = set; then
17448   echo $ECHO_N "(cached) $ECHO_C" >&6
17449 else
17450   cat >conftest.$ac_ext <<_ACEOF
17451 /* confdefs.h.  */
17452 _ACEOF
17453 cat confdefs.h >>conftest.$ac_ext
17454 cat >>conftest.$ac_ext <<_ACEOF
17455 /* end confdefs.h.  */
17456
17457 #define _SYSCALL32
17458 #include <sys/procfs.h>
17459 int
17460 main ()
17461 {
17462 prrun_t avar
17463   ;
17464   return 0;
17465 }
17466 _ACEOF
17467 rm -f conftest.$ac_objext
17468 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17469   (eval $ac_compile) 2>conftest.er1
17470   ac_status=$?
17471   grep -v '^ *+' conftest.er1 >conftest.err
17472   rm -f conftest.er1
17473   cat conftest.err >&5
17474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17475   (exit $ac_status); } &&
17476          { ac_try='test -z "$ac_c_werror_flag"
17477                          || test ! -s conftest.err'
17478   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17479   (eval $ac_try) 2>&5
17480   ac_status=$?
17481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17482   (exit $ac_status); }; } &&
17483          { ac_try='test -s conftest.$ac_objext'
17484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17485   (eval $ac_try) 2>&5
17486   ac_status=$?
17487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17488   (exit $ac_status); }; }; then
17489   bfd_cv_have_sys_procfs_type_prrun_t=yes
17490 else
17491   echo "$as_me: failed program was:" >&5
17492 sed 's/^/| /' conftest.$ac_ext >&5
17493
17494 bfd_cv_have_sys_procfs_type_prrun_t=no
17495
17496 fi
17497 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17498 fi
17499
17500  if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then
17501
17502 cat >>confdefs.h <<\_ACEOF
17503 #define HAVE_PRRUN_T 1
17504 _ACEOF
17505
17506  fi
17507  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prrun_t" >&5
17508 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prrun_t" >&6
17509
17510   echo "$as_me:$LINENO: checking for gregset_t in sys/procfs.h" >&5
17511 echo $ECHO_N "checking for gregset_t in sys/procfs.h... $ECHO_C" >&6
17512  if test "${bfd_cv_have_sys_procfs_type_gregset_t+set}" = set; then
17513   echo $ECHO_N "(cached) $ECHO_C" >&6
17514 else
17515   cat >conftest.$ac_ext <<_ACEOF
17516 /* confdefs.h.  */
17517 _ACEOF
17518 cat confdefs.h >>conftest.$ac_ext
17519 cat >>conftest.$ac_ext <<_ACEOF
17520 /* end confdefs.h.  */
17521
17522 #define _SYSCALL32
17523 #include <sys/procfs.h>
17524 int
17525 main ()
17526 {
17527 gregset_t avar
17528   ;
17529   return 0;
17530 }
17531 _ACEOF
17532 rm -f conftest.$ac_objext
17533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17534   (eval $ac_compile) 2>conftest.er1
17535   ac_status=$?
17536   grep -v '^ *+' conftest.er1 >conftest.err
17537   rm -f conftest.er1
17538   cat conftest.err >&5
17539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17540   (exit $ac_status); } &&
17541          { ac_try='test -z "$ac_c_werror_flag"
17542                          || test ! -s conftest.err'
17543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17544   (eval $ac_try) 2>&5
17545   ac_status=$?
17546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17547   (exit $ac_status); }; } &&
17548          { ac_try='test -s conftest.$ac_objext'
17549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17550   (eval $ac_try) 2>&5
17551   ac_status=$?
17552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17553   (exit $ac_status); }; }; then
17554   bfd_cv_have_sys_procfs_type_gregset_t=yes
17555 else
17556   echo "$as_me: failed program was:" >&5
17557 sed 's/^/| /' conftest.$ac_ext >&5
17558
17559 bfd_cv_have_sys_procfs_type_gregset_t=no
17560
17561 fi
17562 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17563 fi
17564
17565  if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
17566
17567 cat >>confdefs.h <<\_ACEOF
17568 #define HAVE_GREGSET_T 1
17569 _ACEOF
17570
17571  fi
17572  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_gregset_t" >&5
17573 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_gregset_t" >&6
17574
17575   echo "$as_me:$LINENO: checking for fpregset_t in sys/procfs.h" >&5
17576 echo $ECHO_N "checking for fpregset_t in sys/procfs.h... $ECHO_C" >&6
17577  if test "${bfd_cv_have_sys_procfs_type_fpregset_t+set}" = set; then
17578   echo $ECHO_N "(cached) $ECHO_C" >&6
17579 else
17580   cat >conftest.$ac_ext <<_ACEOF
17581 /* confdefs.h.  */
17582 _ACEOF
17583 cat confdefs.h >>conftest.$ac_ext
17584 cat >>conftest.$ac_ext <<_ACEOF
17585 /* end confdefs.h.  */
17586
17587 #define _SYSCALL32
17588 #include <sys/procfs.h>
17589 int
17590 main ()
17591 {
17592 fpregset_t avar
17593   ;
17594   return 0;
17595 }
17596 _ACEOF
17597 rm -f conftest.$ac_objext
17598 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17599   (eval $ac_compile) 2>conftest.er1
17600   ac_status=$?
17601   grep -v '^ *+' conftest.er1 >conftest.err
17602   rm -f conftest.er1
17603   cat conftest.err >&5
17604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17605   (exit $ac_status); } &&
17606          { ac_try='test -z "$ac_c_werror_flag"
17607                          || test ! -s conftest.err'
17608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17609   (eval $ac_try) 2>&5
17610   ac_status=$?
17611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17612   (exit $ac_status); }; } &&
17613          { ac_try='test -s conftest.$ac_objext'
17614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17615   (eval $ac_try) 2>&5
17616   ac_status=$?
17617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17618   (exit $ac_status); }; }; then
17619   bfd_cv_have_sys_procfs_type_fpregset_t=yes
17620 else
17621   echo "$as_me: failed program was:" >&5
17622 sed 's/^/| /' conftest.$ac_ext >&5
17623
17624 bfd_cv_have_sys_procfs_type_fpregset_t=no
17625
17626 fi
17627 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17628 fi
17629
17630  if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
17631
17632 cat >>confdefs.h <<\_ACEOF
17633 #define HAVE_FPREGSET_T 1
17634 _ACEOF
17635
17636  fi
17637  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_fpregset_t" >&5
17638 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_fpregset_t" >&6
17639
17640   echo "$as_me:$LINENO: checking for prgregset_t in sys/procfs.h" >&5
17641 echo $ECHO_N "checking for prgregset_t in sys/procfs.h... $ECHO_C" >&6
17642  if test "${bfd_cv_have_sys_procfs_type_prgregset_t+set}" = set; then
17643   echo $ECHO_N "(cached) $ECHO_C" >&6
17644 else
17645   cat >conftest.$ac_ext <<_ACEOF
17646 /* confdefs.h.  */
17647 _ACEOF
17648 cat confdefs.h >>conftest.$ac_ext
17649 cat >>conftest.$ac_ext <<_ACEOF
17650 /* end confdefs.h.  */
17651
17652 #define _SYSCALL32
17653 #include <sys/procfs.h>
17654 int
17655 main ()
17656 {
17657 prgregset_t avar
17658   ;
17659   return 0;
17660 }
17661 _ACEOF
17662 rm -f conftest.$ac_objext
17663 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17664   (eval $ac_compile) 2>conftest.er1
17665   ac_status=$?
17666   grep -v '^ *+' conftest.er1 >conftest.err
17667   rm -f conftest.er1
17668   cat conftest.err >&5
17669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17670   (exit $ac_status); } &&
17671          { ac_try='test -z "$ac_c_werror_flag"
17672                          || test ! -s conftest.err'
17673   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17674   (eval $ac_try) 2>&5
17675   ac_status=$?
17676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17677   (exit $ac_status); }; } &&
17678          { ac_try='test -s conftest.$ac_objext'
17679   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17680   (eval $ac_try) 2>&5
17681   ac_status=$?
17682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17683   (exit $ac_status); }; }; then
17684   bfd_cv_have_sys_procfs_type_prgregset_t=yes
17685 else
17686   echo "$as_me: failed program was:" >&5
17687 sed 's/^/| /' conftest.$ac_ext >&5
17688
17689 bfd_cv_have_sys_procfs_type_prgregset_t=no
17690
17691 fi
17692 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17693 fi
17694
17695  if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
17696
17697 cat >>confdefs.h <<\_ACEOF
17698 #define HAVE_PRGREGSET_T 1
17699 _ACEOF
17700
17701  fi
17702  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prgregset_t" >&5
17703 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prgregset_t" >&6
17704
17705   echo "$as_me:$LINENO: checking for prfpregset_t in sys/procfs.h" >&5
17706 echo $ECHO_N "checking for prfpregset_t in sys/procfs.h... $ECHO_C" >&6
17707  if test "${bfd_cv_have_sys_procfs_type_prfpregset_t+set}" = set; then
17708   echo $ECHO_N "(cached) $ECHO_C" >&6
17709 else
17710   cat >conftest.$ac_ext <<_ACEOF
17711 /* confdefs.h.  */
17712 _ACEOF
17713 cat confdefs.h >>conftest.$ac_ext
17714 cat >>conftest.$ac_ext <<_ACEOF
17715 /* end confdefs.h.  */
17716
17717 #define _SYSCALL32
17718 #include <sys/procfs.h>
17719 int
17720 main ()
17721 {
17722 prfpregset_t avar
17723   ;
17724   return 0;
17725 }
17726 _ACEOF
17727 rm -f conftest.$ac_objext
17728 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17729   (eval $ac_compile) 2>conftest.er1
17730   ac_status=$?
17731   grep -v '^ *+' conftest.er1 >conftest.err
17732   rm -f conftest.er1
17733   cat conftest.err >&5
17734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17735   (exit $ac_status); } &&
17736          { ac_try='test -z "$ac_c_werror_flag"
17737                          || test ! -s conftest.err'
17738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17739   (eval $ac_try) 2>&5
17740   ac_status=$?
17741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17742   (exit $ac_status); }; } &&
17743          { ac_try='test -s conftest.$ac_objext'
17744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17745   (eval $ac_try) 2>&5
17746   ac_status=$?
17747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17748   (exit $ac_status); }; }; then
17749   bfd_cv_have_sys_procfs_type_prfpregset_t=yes
17750 else
17751   echo "$as_me: failed program was:" >&5
17752 sed 's/^/| /' conftest.$ac_ext >&5
17753
17754 bfd_cv_have_sys_procfs_type_prfpregset_t=no
17755
17756 fi
17757 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17758 fi
17759
17760  if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
17761
17762 cat >>confdefs.h <<\_ACEOF
17763 #define HAVE_PRFPREGSET_T 1
17764 _ACEOF
17765
17766  fi
17767  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prfpregset_t" >&5
17768 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prfpregset_t" >&6
17769
17770   echo "$as_me:$LINENO: checking for prgregset32_t in sys/procfs.h" >&5
17771 echo $ECHO_N "checking for prgregset32_t in sys/procfs.h... $ECHO_C" >&6
17772  if test "${bfd_cv_have_sys_procfs_type_prgregset32_t+set}" = set; then
17773   echo $ECHO_N "(cached) $ECHO_C" >&6
17774 else
17775   cat >conftest.$ac_ext <<_ACEOF
17776 /* confdefs.h.  */
17777 _ACEOF
17778 cat confdefs.h >>conftest.$ac_ext
17779 cat >>conftest.$ac_ext <<_ACEOF
17780 /* end confdefs.h.  */
17781
17782 #define _SYSCALL32
17783 #include <sys/procfs.h>
17784 int
17785 main ()
17786 {
17787 prgregset32_t avar
17788   ;
17789   return 0;
17790 }
17791 _ACEOF
17792 rm -f conftest.$ac_objext
17793 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17794   (eval $ac_compile) 2>conftest.er1
17795   ac_status=$?
17796   grep -v '^ *+' conftest.er1 >conftest.err
17797   rm -f conftest.er1
17798   cat conftest.err >&5
17799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17800   (exit $ac_status); } &&
17801          { ac_try='test -z "$ac_c_werror_flag"
17802                          || test ! -s conftest.err'
17803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17804   (eval $ac_try) 2>&5
17805   ac_status=$?
17806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17807   (exit $ac_status); }; } &&
17808          { ac_try='test -s conftest.$ac_objext'
17809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17810   (eval $ac_try) 2>&5
17811   ac_status=$?
17812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17813   (exit $ac_status); }; }; then
17814   bfd_cv_have_sys_procfs_type_prgregset32_t=yes
17815 else
17816   echo "$as_me: failed program was:" >&5
17817 sed 's/^/| /' conftest.$ac_ext >&5
17818
17819 bfd_cv_have_sys_procfs_type_prgregset32_t=no
17820
17821 fi
17822 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17823 fi
17824
17825  if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
17826
17827 cat >>confdefs.h <<\_ACEOF
17828 #define HAVE_PRGREGSET32_T 1
17829 _ACEOF
17830
17831  fi
17832  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prgregset32_t" >&5
17833 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prgregset32_t" >&6
17834
17835   echo "$as_me:$LINENO: checking for prfpregset32_t in sys/procfs.h" >&5
17836 echo $ECHO_N "checking for prfpregset32_t in sys/procfs.h... $ECHO_C" >&6
17837  if test "${bfd_cv_have_sys_procfs_type_prfpregset32_t+set}" = set; then
17838   echo $ECHO_N "(cached) $ECHO_C" >&6
17839 else
17840   cat >conftest.$ac_ext <<_ACEOF
17841 /* confdefs.h.  */
17842 _ACEOF
17843 cat confdefs.h >>conftest.$ac_ext
17844 cat >>conftest.$ac_ext <<_ACEOF
17845 /* end confdefs.h.  */
17846
17847 #define _SYSCALL32
17848 #include <sys/procfs.h>
17849 int
17850 main ()
17851 {
17852 prfpregset32_t avar
17853   ;
17854   return 0;
17855 }
17856 _ACEOF
17857 rm -f conftest.$ac_objext
17858 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17859   (eval $ac_compile) 2>conftest.er1
17860   ac_status=$?
17861   grep -v '^ *+' conftest.er1 >conftest.err
17862   rm -f conftest.er1
17863   cat conftest.err >&5
17864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17865   (exit $ac_status); } &&
17866          { ac_try='test -z "$ac_c_werror_flag"
17867                          || test ! -s conftest.err'
17868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17869   (eval $ac_try) 2>&5
17870   ac_status=$?
17871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17872   (exit $ac_status); }; } &&
17873          { ac_try='test -s conftest.$ac_objext'
17874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17875   (eval $ac_try) 2>&5
17876   ac_status=$?
17877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17878   (exit $ac_status); }; }; then
17879   bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
17880 else
17881   echo "$as_me: failed program was:" >&5
17882 sed 's/^/| /' conftest.$ac_ext >&5
17883
17884 bfd_cv_have_sys_procfs_type_prfpregset32_t=no
17885
17886 fi
17887 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17888 fi
17889
17890  if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then
17891
17892 cat >>confdefs.h <<\_ACEOF
17893 #define HAVE_PRFPREGSET32_T 1
17894 _ACEOF
17895
17896  fi
17897  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prfpregset32_t" >&5
17898 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prfpregset32_t" >&6
17899
17900   echo "$as_me:$LINENO: checking for lwpid_t in sys/procfs.h" >&5
17901 echo $ECHO_N "checking for lwpid_t in sys/procfs.h... $ECHO_C" >&6
17902  if test "${bfd_cv_have_sys_procfs_type_lwpid_t+set}" = set; then
17903   echo $ECHO_N "(cached) $ECHO_C" >&6
17904 else
17905   cat >conftest.$ac_ext <<_ACEOF
17906 /* confdefs.h.  */
17907 _ACEOF
17908 cat confdefs.h >>conftest.$ac_ext
17909 cat >>conftest.$ac_ext <<_ACEOF
17910 /* end confdefs.h.  */
17911
17912 #define _SYSCALL32
17913 #include <sys/procfs.h>
17914 int
17915 main ()
17916 {
17917 lwpid_t avar
17918   ;
17919   return 0;
17920 }
17921 _ACEOF
17922 rm -f conftest.$ac_objext
17923 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17924   (eval $ac_compile) 2>conftest.er1
17925   ac_status=$?
17926   grep -v '^ *+' conftest.er1 >conftest.err
17927   rm -f conftest.er1
17928   cat conftest.err >&5
17929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17930   (exit $ac_status); } &&
17931          { ac_try='test -z "$ac_c_werror_flag"
17932                          || test ! -s conftest.err'
17933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17934   (eval $ac_try) 2>&5
17935   ac_status=$?
17936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17937   (exit $ac_status); }; } &&
17938          { ac_try='test -s conftest.$ac_objext'
17939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17940   (eval $ac_try) 2>&5
17941   ac_status=$?
17942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17943   (exit $ac_status); }; }; then
17944   bfd_cv_have_sys_procfs_type_lwpid_t=yes
17945 else
17946   echo "$as_me: failed program was:" >&5
17947 sed 's/^/| /' conftest.$ac_ext >&5
17948
17949 bfd_cv_have_sys_procfs_type_lwpid_t=no
17950
17951 fi
17952 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17953 fi
17954
17955  if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
17956
17957 cat >>confdefs.h <<\_ACEOF
17958 #define HAVE_LWPID_T 1
17959 _ACEOF
17960
17961  fi
17962  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_lwpid_t" >&5
17963 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_lwpid_t" >&6
17964
17965   echo "$as_me:$LINENO: checking for psaddr_t in sys/procfs.h" >&5
17966 echo $ECHO_N "checking for psaddr_t in sys/procfs.h... $ECHO_C" >&6
17967  if test "${bfd_cv_have_sys_procfs_type_psaddr_t+set}" = set; then
17968   echo $ECHO_N "(cached) $ECHO_C" >&6
17969 else
17970   cat >conftest.$ac_ext <<_ACEOF
17971 /* confdefs.h.  */
17972 _ACEOF
17973 cat confdefs.h >>conftest.$ac_ext
17974 cat >>conftest.$ac_ext <<_ACEOF
17975 /* end confdefs.h.  */
17976
17977 #define _SYSCALL32
17978 #include <sys/procfs.h>
17979 int
17980 main ()
17981 {
17982 psaddr_t avar
17983   ;
17984   return 0;
17985 }
17986 _ACEOF
17987 rm -f conftest.$ac_objext
17988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17989   (eval $ac_compile) 2>conftest.er1
17990   ac_status=$?
17991   grep -v '^ *+' conftest.er1 >conftest.err
17992   rm -f conftest.er1
17993   cat conftest.err >&5
17994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17995   (exit $ac_status); } &&
17996          { ac_try='test -z "$ac_c_werror_flag"
17997                          || test ! -s conftest.err'
17998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17999   (eval $ac_try) 2>&5
18000   ac_status=$?
18001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18002   (exit $ac_status); }; } &&
18003          { ac_try='test -s conftest.$ac_objext'
18004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18005   (eval $ac_try) 2>&5
18006   ac_status=$?
18007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18008   (exit $ac_status); }; }; then
18009   bfd_cv_have_sys_procfs_type_psaddr_t=yes
18010 else
18011   echo "$as_me: failed program was:" >&5
18012 sed 's/^/| /' conftest.$ac_ext >&5
18013
18014 bfd_cv_have_sys_procfs_type_psaddr_t=no
18015
18016 fi
18017 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18018 fi
18019
18020  if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
18021
18022 cat >>confdefs.h <<\_ACEOF
18023 #define HAVE_PSADDR_T 1
18024 _ACEOF
18025
18026  fi
18027  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_psaddr_t" >&5
18028 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_psaddr_t" >&6
18029
18030   echo "$as_me:$LINENO: checking for prsysent_t in sys/procfs.h" >&5
18031 echo $ECHO_N "checking for prsysent_t in sys/procfs.h... $ECHO_C" >&6
18032  if test "${bfd_cv_have_sys_procfs_type_prsysent_t+set}" = set; then
18033   echo $ECHO_N "(cached) $ECHO_C" >&6
18034 else
18035   cat >conftest.$ac_ext <<_ACEOF
18036 /* confdefs.h.  */
18037 _ACEOF
18038 cat confdefs.h >>conftest.$ac_ext
18039 cat >>conftest.$ac_ext <<_ACEOF
18040 /* end confdefs.h.  */
18041
18042 #define _SYSCALL32
18043 #include <sys/procfs.h>
18044 int
18045 main ()
18046 {
18047 prsysent_t avar
18048   ;
18049   return 0;
18050 }
18051 _ACEOF
18052 rm -f conftest.$ac_objext
18053 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18054   (eval $ac_compile) 2>conftest.er1
18055   ac_status=$?
18056   grep -v '^ *+' conftest.er1 >conftest.err
18057   rm -f conftest.er1
18058   cat conftest.err >&5
18059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18060   (exit $ac_status); } &&
18061          { ac_try='test -z "$ac_c_werror_flag"
18062                          || test ! -s conftest.err'
18063   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18064   (eval $ac_try) 2>&5
18065   ac_status=$?
18066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18067   (exit $ac_status); }; } &&
18068          { ac_try='test -s conftest.$ac_objext'
18069   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18070   (eval $ac_try) 2>&5
18071   ac_status=$?
18072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18073   (exit $ac_status); }; }; then
18074   bfd_cv_have_sys_procfs_type_prsysent_t=yes
18075 else
18076   echo "$as_me: failed program was:" >&5
18077 sed 's/^/| /' conftest.$ac_ext >&5
18078
18079 bfd_cv_have_sys_procfs_type_prsysent_t=no
18080
18081 fi
18082 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18083 fi
18084
18085  if test $bfd_cv_have_sys_procfs_type_prsysent_t = yes; then
18086
18087 cat >>confdefs.h <<\_ACEOF
18088 #define HAVE_PRSYSENT_T 1
18089 _ACEOF
18090
18091  fi
18092  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_prsysent_t" >&5
18093 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_prsysent_t" >&6
18094
18095   echo "$as_me:$LINENO: checking for pr_sigset_t in sys/procfs.h" >&5
18096 echo $ECHO_N "checking for pr_sigset_t in sys/procfs.h... $ECHO_C" >&6
18097  if test "${bfd_cv_have_sys_procfs_type_pr_sigset_t+set}" = set; then
18098   echo $ECHO_N "(cached) $ECHO_C" >&6
18099 else
18100   cat >conftest.$ac_ext <<_ACEOF
18101 /* confdefs.h.  */
18102 _ACEOF
18103 cat confdefs.h >>conftest.$ac_ext
18104 cat >>conftest.$ac_ext <<_ACEOF
18105 /* end confdefs.h.  */
18106
18107 #define _SYSCALL32
18108 #include <sys/procfs.h>
18109 int
18110 main ()
18111 {
18112 pr_sigset_t avar
18113   ;
18114   return 0;
18115 }
18116 _ACEOF
18117 rm -f conftest.$ac_objext
18118 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18119   (eval $ac_compile) 2>conftest.er1
18120   ac_status=$?
18121   grep -v '^ *+' conftest.er1 >conftest.err
18122   rm -f conftest.er1
18123   cat conftest.err >&5
18124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18125   (exit $ac_status); } &&
18126          { ac_try='test -z "$ac_c_werror_flag"
18127                          || test ! -s conftest.err'
18128   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18129   (eval $ac_try) 2>&5
18130   ac_status=$?
18131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18132   (exit $ac_status); }; } &&
18133          { ac_try='test -s conftest.$ac_objext'
18134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18135   (eval $ac_try) 2>&5
18136   ac_status=$?
18137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18138   (exit $ac_status); }; }; then
18139   bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
18140 else
18141   echo "$as_me: failed program was:" >&5
18142 sed 's/^/| /' conftest.$ac_ext >&5
18143
18144 bfd_cv_have_sys_procfs_type_pr_sigset_t=no
18145
18146 fi
18147 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18148 fi
18149
18150  if test $bfd_cv_have_sys_procfs_type_pr_sigset_t = yes; then
18151
18152 cat >>confdefs.h <<\_ACEOF
18153 #define HAVE_PR_SIGSET_T 1
18154 _ACEOF
18155
18156  fi
18157  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_pr_sigset_t" >&5
18158 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_pr_sigset_t" >&6
18159
18160   echo "$as_me:$LINENO: checking for pr_sigaction64_t in sys/procfs.h" >&5
18161 echo $ECHO_N "checking for pr_sigaction64_t in sys/procfs.h... $ECHO_C" >&6
18162  if test "${bfd_cv_have_sys_procfs_type_pr_sigaction64_t+set}" = set; then
18163   echo $ECHO_N "(cached) $ECHO_C" >&6
18164 else
18165   cat >conftest.$ac_ext <<_ACEOF
18166 /* confdefs.h.  */
18167 _ACEOF
18168 cat confdefs.h >>conftest.$ac_ext
18169 cat >>conftest.$ac_ext <<_ACEOF
18170 /* end confdefs.h.  */
18171
18172 #define _SYSCALL32
18173 #include <sys/procfs.h>
18174 int
18175 main ()
18176 {
18177 pr_sigaction64_t avar
18178   ;
18179   return 0;
18180 }
18181 _ACEOF
18182 rm -f conftest.$ac_objext
18183 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18184   (eval $ac_compile) 2>conftest.er1
18185   ac_status=$?
18186   grep -v '^ *+' conftest.er1 >conftest.err
18187   rm -f conftest.er1
18188   cat conftest.err >&5
18189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18190   (exit $ac_status); } &&
18191          { ac_try='test -z "$ac_c_werror_flag"
18192                          || test ! -s conftest.err'
18193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18194   (eval $ac_try) 2>&5
18195   ac_status=$?
18196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18197   (exit $ac_status); }; } &&
18198          { ac_try='test -s conftest.$ac_objext'
18199   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18200   (eval $ac_try) 2>&5
18201   ac_status=$?
18202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18203   (exit $ac_status); }; }; then
18204   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
18205 else
18206   echo "$as_me: failed program was:" >&5
18207 sed 's/^/| /' conftest.$ac_ext >&5
18208
18209 bfd_cv_have_sys_procfs_type_pr_sigaction64_t=no
18210
18211 fi
18212 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18213 fi
18214
18215  if test $bfd_cv_have_sys_procfs_type_pr_sigaction64_t = yes; then
18216
18217 cat >>confdefs.h <<\_ACEOF
18218 #define HAVE_PR_SIGACTION64_T 1
18219 _ACEOF
18220
18221  fi
18222  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&5
18223 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" >&6
18224
18225   echo "$as_me:$LINENO: checking for pr_siginfo64_t in sys/procfs.h" >&5
18226 echo $ECHO_N "checking for pr_siginfo64_t in sys/procfs.h... $ECHO_C" >&6
18227  if test "${bfd_cv_have_sys_procfs_type_pr_siginfo64_t+set}" = set; then
18228   echo $ECHO_N "(cached) $ECHO_C" >&6
18229 else
18230   cat >conftest.$ac_ext <<_ACEOF
18231 /* confdefs.h.  */
18232 _ACEOF
18233 cat confdefs.h >>conftest.$ac_ext
18234 cat >>conftest.$ac_ext <<_ACEOF
18235 /* end confdefs.h.  */
18236
18237 #define _SYSCALL32
18238 #include <sys/procfs.h>
18239 int
18240 main ()
18241 {
18242 pr_siginfo64_t avar
18243   ;
18244   return 0;
18245 }
18246 _ACEOF
18247 rm -f conftest.$ac_objext
18248 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18249   (eval $ac_compile) 2>conftest.er1
18250   ac_status=$?
18251   grep -v '^ *+' conftest.er1 >conftest.err
18252   rm -f conftest.er1
18253   cat conftest.err >&5
18254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18255   (exit $ac_status); } &&
18256          { ac_try='test -z "$ac_c_werror_flag"
18257                          || test ! -s conftest.err'
18258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18259   (eval $ac_try) 2>&5
18260   ac_status=$?
18261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18262   (exit $ac_status); }; } &&
18263          { ac_try='test -s conftest.$ac_objext'
18264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18265   (eval $ac_try) 2>&5
18266   ac_status=$?
18267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18268   (exit $ac_status); }; }; then
18269   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
18270 else
18271   echo "$as_me: failed program was:" >&5
18272 sed 's/^/| /' conftest.$ac_ext >&5
18273
18274 bfd_cv_have_sys_procfs_type_pr_siginfo64_t=no
18275
18276 fi
18277 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18278 fi
18279
18280  if test $bfd_cv_have_sys_procfs_type_pr_siginfo64_t = yes; then
18281
18282 cat >>confdefs.h <<\_ACEOF
18283 #define HAVE_PR_SIGINFO64_T 1
18284 _ACEOF
18285
18286  fi
18287  echo "$as_me:$LINENO: result: $bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&5
18288 echo "${ECHO_T}$bfd_cv_have_sys_procfs_type_pr_siginfo64_t" >&6
18289
18290
18291
18292
18293
18294   if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
18295     echo "$as_me:$LINENO: checking whether prfpregset_t type is broken" >&5
18296 echo $ECHO_N "checking whether prfpregset_t type is broken... $ECHO_C" >&6
18297     if test "${gdb_cv_prfpregset_t_broken+set}" = set; then
18298   echo $ECHO_N "(cached) $ECHO_C" >&6
18299 else
18300   if test "$cross_compiling" = yes; then
18301   gdb_cv_prfpregset_t_broken=yes
18302 else
18303   cat >conftest.$ac_ext <<_ACEOF
18304 /* confdefs.h.  */
18305 _ACEOF
18306 cat confdefs.h >>conftest.$ac_ext
18307 cat >>conftest.$ac_ext <<_ACEOF
18308 /* end confdefs.h.  */
18309 #include <sys/procfs.h>
18310        int main ()
18311        {
18312          if (sizeof (prfpregset_t) == sizeof (void *))
18313            return 1;
18314          return 0;
18315        }
18316 _ACEOF
18317 rm -f conftest$ac_exeext
18318 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18319   (eval $ac_link) 2>&5
18320   ac_status=$?
18321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18322   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18323   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18324   (eval $ac_try) 2>&5
18325   ac_status=$?
18326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18327   (exit $ac_status); }; }; then
18328   gdb_cv_prfpregset_t_broken=no
18329 else
18330   echo "$as_me: program exited with status $ac_status" >&5
18331 echo "$as_me: failed program was:" >&5
18332 sed 's/^/| /' conftest.$ac_ext >&5
18333
18334 ( exit $ac_status )
18335 gdb_cv_prfpregset_t_broken=yes
18336 fi
18337 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18338 fi
18339 fi
18340
18341     echo "$as_me:$LINENO: result: $gdb_cv_prfpregset_t_broken" >&5
18342 echo "${ECHO_T}$gdb_cv_prfpregset_t_broken" >&6
18343     if test $gdb_cv_prfpregset_t_broken = yes; then
18344
18345 cat >>confdefs.h <<\_ACEOF
18346 #define PRFPREGSET_T_BROKEN 1
18347 _ACEOF
18348
18349     fi
18350   fi
18351
18352
18353   echo "$as_me:$LINENO: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
18354 echo $ECHO_N "checking for PIOCSET ioctl entry in sys/procfs.h... $ECHO_C" >&6
18355   if test "${gdb_cv_have_procfs_piocset+set}" = set; then
18356   echo $ECHO_N "(cached) $ECHO_C" >&6
18357 else
18358   cat >conftest.$ac_ext <<_ACEOF
18359 /* confdefs.h.  */
18360 _ACEOF
18361 cat confdefs.h >>conftest.$ac_ext
18362 cat >>conftest.$ac_ext <<_ACEOF
18363 /* end confdefs.h.  */
18364 #include <unistd.h>
18365 #include <sys/types.h>
18366 #include <sys/procfs.h>
18367
18368 int
18369 main ()
18370 {
18371
18372     int dummy;;
18373     dummy = ioctl(0, PIOCSET, &dummy);
18374
18375   ;
18376   return 0;
18377 }
18378 _ACEOF
18379 rm -f conftest.$ac_objext
18380 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18381   (eval $ac_compile) 2>conftest.er1
18382   ac_status=$?
18383   grep -v '^ *+' conftest.er1 >conftest.err
18384   rm -f conftest.er1
18385   cat conftest.err >&5
18386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18387   (exit $ac_status); } &&
18388          { ac_try='test -z "$ac_c_werror_flag"
18389                          || test ! -s conftest.err'
18390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18391   (eval $ac_try) 2>&5
18392   ac_status=$?
18393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18394   (exit $ac_status); }; } &&
18395          { ac_try='test -s conftest.$ac_objext'
18396   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18397   (eval $ac_try) 2>&5
18398   ac_status=$?
18399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18400   (exit $ac_status); }; }; then
18401   gdb_cv_have_procfs_piocset=yes
18402 else
18403   echo "$as_me: failed program was:" >&5
18404 sed 's/^/| /' conftest.$ac_ext >&5
18405
18406 gdb_cv_have_procfs_piocset=no
18407 fi
18408 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18409 fi
18410
18411   echo "$as_me:$LINENO: result: $gdb_cv_have_procfs_piocset" >&5
18412 echo "${ECHO_T}$gdb_cv_have_procfs_piocset" >&6
18413   if test $gdb_cv_have_procfs_piocset = yes; then
18414
18415 cat >>confdefs.h <<\_ACEOF
18416 #define HAVE_PROCFS_PIOCSET 1
18417 _ACEOF
18418
18419   fi
18420 fi
18421
18422 if test ${host} = ${target} ; then
18423
18424   echo "$as_me:$LINENO: checking for member l_addr in struct link_map" >&5
18425 echo $ECHO_N "checking for member l_addr in struct link_map... $ECHO_C" >&6
18426   if test "${gdb_cv_have_struct_link_map_with_l_members+set}" = set; then
18427   echo $ECHO_N "(cached) $ECHO_C" >&6
18428 else
18429   cat >conftest.$ac_ext <<_ACEOF
18430 /* confdefs.h.  */
18431 _ACEOF
18432 cat confdefs.h >>conftest.$ac_ext
18433 cat >>conftest.$ac_ext <<_ACEOF
18434 /* end confdefs.h.  */
18435 #include <link.h>
18436 int
18437 main ()
18438 {
18439 struct link_map lm; (void) lm.l_addr;
18440   ;
18441   return 0;
18442 }
18443 _ACEOF
18444 rm -f conftest.$ac_objext
18445 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18446   (eval $ac_compile) 2>conftest.er1
18447   ac_status=$?
18448   grep -v '^ *+' conftest.er1 >conftest.err
18449   rm -f conftest.er1
18450   cat conftest.err >&5
18451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18452   (exit $ac_status); } &&
18453          { ac_try='test -z "$ac_c_werror_flag"
18454                          || test ! -s conftest.err'
18455   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18456   (eval $ac_try) 2>&5
18457   ac_status=$?
18458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18459   (exit $ac_status); }; } &&
18460          { ac_try='test -s conftest.$ac_objext'
18461   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18462   (eval $ac_try) 2>&5
18463   ac_status=$?
18464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18465   (exit $ac_status); }; }; then
18466   gdb_cv_have_struct_link_map_with_l_members=yes
18467 else
18468   echo "$as_me: failed program was:" >&5
18469 sed 's/^/| /' conftest.$ac_ext >&5
18470
18471 gdb_cv_have_struct_link_map_with_l_members=no
18472 fi
18473 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18474 fi
18475
18476   echo "$as_me:$LINENO: result: $gdb_cv_have_struct_link_map_with_l_members" >&5
18477 echo "${ECHO_T}$gdb_cv_have_struct_link_map_with_l_members" >&6
18478   if test $gdb_cv_have_struct_link_map_with_l_members = yes; then
18479
18480 cat >>confdefs.h <<\_ACEOF
18481 #define HAVE_STRUCT_LINK_MAP_WITH_L_MEMBERS 1
18482 _ACEOF
18483
18484   fi
18485
18486
18487   echo "$as_me:$LINENO: checking for member lm_addr in struct link_map" >&5
18488 echo $ECHO_N "checking for member lm_addr in struct link_map... $ECHO_C" >&6
18489   if test "${gdb_cv_have_struct_link_map_with_lm_members+set}" = set; then
18490   echo $ECHO_N "(cached) $ECHO_C" >&6
18491 else
18492   cat >conftest.$ac_ext <<_ACEOF
18493 /* confdefs.h.  */
18494 _ACEOF
18495 cat confdefs.h >>conftest.$ac_ext
18496 cat >>conftest.$ac_ext <<_ACEOF
18497 /* end confdefs.h.  */
18498 #include <sys/types.h>
18499 #include <link.h>
18500 int
18501 main ()
18502 {
18503 struct link_map lm; (void) lm.lm_addr;
18504   ;
18505   return 0;
18506 }
18507 _ACEOF
18508 rm -f conftest.$ac_objext
18509 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18510   (eval $ac_compile) 2>conftest.er1
18511   ac_status=$?
18512   grep -v '^ *+' conftest.er1 >conftest.err
18513   rm -f conftest.er1
18514   cat conftest.err >&5
18515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18516   (exit $ac_status); } &&
18517          { ac_try='test -z "$ac_c_werror_flag"
18518                          || test ! -s conftest.err'
18519   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18520   (eval $ac_try) 2>&5
18521   ac_status=$?
18522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18523   (exit $ac_status); }; } &&
18524          { ac_try='test -s conftest.$ac_objext'
18525   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18526   (eval $ac_try) 2>&5
18527   ac_status=$?
18528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18529   (exit $ac_status); }; }; then
18530   gdb_cv_have_struct_link_map_with_lm_members=yes
18531 else
18532   echo "$as_me: failed program was:" >&5
18533 sed 's/^/| /' conftest.$ac_ext >&5
18534
18535 gdb_cv_have_struct_link_map_with_lm_members=no
18536 fi
18537 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18538 fi
18539
18540   echo "$as_me:$LINENO: result: $gdb_cv_have_struct_link_map_with_lm_members" >&5
18541 echo "${ECHO_T}$gdb_cv_have_struct_link_map_with_lm_members" >&6
18542   if test $gdb_cv_have_struct_link_map_with_lm_members = yes; then
18543
18544 cat >>confdefs.h <<\_ACEOF
18545 #define HAVE_STRUCT_LINK_MAP_WITH_LM_MEMBERS 1
18546 _ACEOF
18547
18548   fi
18549
18550
18551   echo "$as_me:$LINENO: checking for member som_addr in struct so_map" >&5
18552 echo $ECHO_N "checking for member som_addr in struct so_map... $ECHO_C" >&6
18553   if test "${gdb_cv_have_struct_so_map_with_som_members+set}" = set; then
18554   echo $ECHO_N "(cached) $ECHO_C" >&6
18555 else
18556   cat >conftest.$ac_ext <<_ACEOF
18557 /* confdefs.h.  */
18558 _ACEOF
18559 cat confdefs.h >>conftest.$ac_ext
18560 cat >>conftest.$ac_ext <<_ACEOF
18561 /* end confdefs.h.  */
18562 #include <sys/types.h>
18563 #ifdef HAVE_NLIST_H
18564 #include <nlist.h>
18565 #endif
18566 #include <link.h>
18567 int
18568 main ()
18569 {
18570 struct so_map lm; (void) lm.som_addr;
18571   ;
18572   return 0;
18573 }
18574 _ACEOF
18575 rm -f conftest.$ac_objext
18576 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18577   (eval $ac_compile) 2>conftest.er1
18578   ac_status=$?
18579   grep -v '^ *+' conftest.er1 >conftest.err
18580   rm -f conftest.er1
18581   cat conftest.err >&5
18582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18583   (exit $ac_status); } &&
18584          { ac_try='test -z "$ac_c_werror_flag"
18585                          || test ! -s conftest.err'
18586   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18587   (eval $ac_try) 2>&5
18588   ac_status=$?
18589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18590   (exit $ac_status); }; } &&
18591          { ac_try='test -s conftest.$ac_objext'
18592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18593   (eval $ac_try) 2>&5
18594   ac_status=$?
18595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18596   (exit $ac_status); }; }; then
18597   gdb_cv_have_struct_so_map_with_som_members=yes
18598 else
18599   echo "$as_me: failed program was:" >&5
18600 sed 's/^/| /' conftest.$ac_ext >&5
18601
18602 gdb_cv_have_struct_so_map_with_som_members=no
18603 fi
18604 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18605 fi
18606
18607   echo "$as_me:$LINENO: result: $gdb_cv_have_struct_so_map_with_som_members" >&5
18608 echo "${ECHO_T}$gdb_cv_have_struct_so_map_with_som_members" >&6
18609   if test $gdb_cv_have_struct_so_map_with_som_members = yes; then
18610
18611 cat >>confdefs.h <<\_ACEOF
18612 #define HAVE_STRUCT_SO_MAP_WITH_SOM_MEMBERS 1
18613 _ACEOF
18614
18615   fi
18616
18617
18618   echo "$as_me:$LINENO: checking for struct link_map32 in sys/link.h" >&5
18619 echo $ECHO_N "checking for struct link_map32 in sys/link.h... $ECHO_C" >&6
18620   if test "${gdb_cv_have_struct_link_map32+set}" = set; then
18621   echo $ECHO_N "(cached) $ECHO_C" >&6
18622 else
18623   cat >conftest.$ac_ext <<_ACEOF
18624 /* confdefs.h.  */
18625 _ACEOF
18626 cat confdefs.h >>conftest.$ac_ext
18627 cat >>conftest.$ac_ext <<_ACEOF
18628 /* end confdefs.h.  */
18629 #define _SYSCALL32
18630 #include <sys/link.h>
18631 int
18632 main ()
18633 {
18634 struct link_map32 l;
18635   ;
18636   return 0;
18637 }
18638 _ACEOF
18639 rm -f conftest.$ac_objext
18640 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18641   (eval $ac_compile) 2>conftest.er1
18642   ac_status=$?
18643   grep -v '^ *+' conftest.er1 >conftest.err
18644   rm -f conftest.er1
18645   cat conftest.err >&5
18646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18647   (exit $ac_status); } &&
18648          { ac_try='test -z "$ac_c_werror_flag"
18649                          || test ! -s conftest.err'
18650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18651   (eval $ac_try) 2>&5
18652   ac_status=$?
18653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18654   (exit $ac_status); }; } &&
18655          { ac_try='test -s conftest.$ac_objext'
18656   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18657   (eval $ac_try) 2>&5
18658   ac_status=$?
18659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18660   (exit $ac_status); }; }; then
18661   gdb_cv_have_struct_link_map32=yes
18662 else
18663   echo "$as_me: failed program was:" >&5
18664 sed 's/^/| /' conftest.$ac_ext >&5
18665
18666 gdb_cv_have_struct_link_map32=no
18667 fi
18668 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18669 fi
18670
18671   echo "$as_me:$LINENO: result: $gdb_cv_have_struct_link_map32" >&5
18672 echo "${ECHO_T}$gdb_cv_have_struct_link_map32" >&6
18673   if test $gdb_cv_have_struct_link_map32 = yes; then
18674
18675 cat >>confdefs.h <<\_ACEOF
18676 #define HAVE_STRUCT_LINK_MAP32 1
18677 _ACEOF
18678
18679
18680 cat >>confdefs.h <<\_ACEOF
18681 #define _SYSCALL32 1
18682 _ACEOF
18683
18684   fi
18685 fi
18686
18687 # Check if the compiler supports the `long long' type.
18688
18689 echo "$as_me:$LINENO: checking for long long support in compiler" >&5
18690 echo $ECHO_N "checking for long long support in compiler... $ECHO_C" >&6
18691 if test "${gdb_cv_c_long_long+set}" = set; then
18692   echo $ECHO_N "(cached) $ECHO_C" >&6
18693 else
18694   cat >conftest.$ac_ext <<_ACEOF
18695 /* confdefs.h.  */
18696 _ACEOF
18697 cat confdefs.h >>conftest.$ac_ext
18698 cat >>conftest.$ac_ext <<_ACEOF
18699 /* end confdefs.h.  */
18700 extern long long foo;
18701 int
18702 main ()
18703 {
18704 switch (foo & 2) { case 0: return 1; }
18705   ;
18706   return 0;
18707 }
18708 _ACEOF
18709 rm -f conftest.$ac_objext
18710 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18711   (eval $ac_compile) 2>conftest.er1
18712   ac_status=$?
18713   grep -v '^ *+' conftest.er1 >conftest.err
18714   rm -f conftest.er1
18715   cat conftest.err >&5
18716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18717   (exit $ac_status); } &&
18718          { ac_try='test -z "$ac_c_werror_flag"
18719                          || test ! -s conftest.err'
18720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18721   (eval $ac_try) 2>&5
18722   ac_status=$?
18723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18724   (exit $ac_status); }; } &&
18725          { ac_try='test -s conftest.$ac_objext'
18726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18727   (eval $ac_try) 2>&5
18728   ac_status=$?
18729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18730   (exit $ac_status); }; }; then
18731   gdb_cv_c_long_long=yes
18732 else
18733   echo "$as_me: failed program was:" >&5
18734 sed 's/^/| /' conftest.$ac_ext >&5
18735
18736 gdb_cv_c_long_long=no
18737 fi
18738 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18739 fi
18740 echo "$as_me:$LINENO: result: $gdb_cv_c_long_long" >&5
18741 echo "${ECHO_T}$gdb_cv_c_long_long" >&6
18742 if test $gdb_cv_c_long_long = yes; then
18743
18744 cat >>confdefs.h <<\_ACEOF
18745 #define CC_HAS_LONG_LONG 1
18746 _ACEOF
18747
18748 fi
18749
18750 # Check if the compiler and runtime support printing long longs.
18751
18752 echo "$as_me:$LINENO: checking for long long support in printf" >&5
18753 echo $ECHO_N "checking for long long support in printf... $ECHO_C" >&6
18754 if test "${gdb_cv_printf_has_long_long+set}" = set; then
18755   echo $ECHO_N "(cached) $ECHO_C" >&6
18756 else
18757   if test "$cross_compiling" = yes; then
18758   gdb_cv_printf_has_long_long=no
18759 else
18760   cat >conftest.$ac_ext <<_ACEOF
18761 /* confdefs.h.  */
18762 _ACEOF
18763 cat confdefs.h >>conftest.$ac_ext
18764 cat >>conftest.$ac_ext <<_ACEOF
18765 /* end confdefs.h.  */
18766 $ac_includes_default
18767 int
18768 main ()
18769 {
18770 char buf[32];
18771   long long l = 0;
18772   l = (l << 16) + 0x0123;
18773   l = (l << 16) + 0x4567;
18774   l = (l << 16) + 0x89ab;
18775   l = (l << 16) + 0xcdef;
18776   sprintf (buf, "0x%016llx", l);
18777   return (strcmp ("0x0123456789abcdef", buf));
18778   ;
18779   return 0;
18780 }
18781 _ACEOF
18782 rm -f conftest$ac_exeext
18783 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18784   (eval $ac_link) 2>&5
18785   ac_status=$?
18786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18787   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18789   (eval $ac_try) 2>&5
18790   ac_status=$?
18791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18792   (exit $ac_status); }; }; then
18793   gdb_cv_printf_has_long_long=yes
18794 else
18795   echo "$as_me: program exited with status $ac_status" >&5
18796 echo "$as_me: failed program was:" >&5
18797 sed 's/^/| /' conftest.$ac_ext >&5
18798
18799 ( exit $ac_status )
18800 gdb_cv_printf_has_long_long=no
18801 fi
18802 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18803 fi
18804 fi
18805 echo "$as_me:$LINENO: result: $gdb_cv_printf_has_long_long" >&5
18806 echo "${ECHO_T}$gdb_cv_printf_has_long_long" >&6
18807 if test $gdb_cv_printf_has_long_long = yes; then
18808
18809 cat >>confdefs.h <<\_ACEOF
18810 #define PRINTF_HAS_LONG_LONG 1
18811 _ACEOF
18812
18813 fi
18814
18815 # Check if the compiler and runtime support printing decfloats.
18816
18817 echo "$as_me:$LINENO: checking for decfloat support in printf" >&5
18818 echo $ECHO_N "checking for decfloat support in printf... $ECHO_C" >&6
18819 if test "${gdb_cv_printf_has_decfloat+set}" = set; then
18820   echo $ECHO_N "(cached) $ECHO_C" >&6
18821 else
18822   if test "$cross_compiling" = yes; then
18823   gdb_cv_printf_has_decfloat=no
18824 else
18825   cat >conftest.$ac_ext <<_ACEOF
18826 /* confdefs.h.  */
18827 _ACEOF
18828 cat confdefs.h >>conftest.$ac_ext
18829 cat >>conftest.$ac_ext <<_ACEOF
18830 /* end confdefs.h.  */
18831 $ac_includes_default
18832 int
18833 main ()
18834 {
18835 char buf[64];
18836   _Decimal32 d32 = 1.2345df;
18837   _Decimal64 d64 = 1.2345dd;
18838   _Decimal128 d128 = 1.2345dl;
18839   sprintf (buf, "Decimal32: %H\nDecimal64: %D\nDecimal128: %DD", d32, d64, d128);
18840   return (strcmp ("Decimal32: 1.2345\nDecimal64: 1.2345\nDecimal128: 1.2345", buf));
18841   ;
18842   return 0;
18843 }
18844 _ACEOF
18845 rm -f conftest$ac_exeext
18846 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18847   (eval $ac_link) 2>&5
18848   ac_status=$?
18849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18850   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18852   (eval $ac_try) 2>&5
18853   ac_status=$?
18854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18855   (exit $ac_status); }; }; then
18856   gdb_cv_printf_has_decfloat=yes
18857 else
18858   echo "$as_me: program exited with status $ac_status" >&5
18859 echo "$as_me: failed program was:" >&5
18860 sed 's/^/| /' conftest.$ac_ext >&5
18861
18862 ( exit $ac_status )
18863 gdb_cv_printf_has_decfloat=no
18864 fi
18865 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18866 fi
18867 fi
18868 echo "$as_me:$LINENO: result: $gdb_cv_printf_has_decfloat" >&5
18869 echo "${ECHO_T}$gdb_cv_printf_has_decfloat" >&6
18870 if test $gdb_cv_printf_has_decfloat = yes; then
18871
18872 cat >>confdefs.h <<\_ACEOF
18873 #define PRINTF_HAS_DECFLOAT 1
18874 _ACEOF
18875
18876 fi
18877
18878 # Check if the compiler supports the `long double' type.  We can't use
18879 # AC_C_LONG_DOUBLE because that one does additional checks on the
18880 # constants defined in <float.h> that fail on some systems,
18881 # e.g. FreeBSD/i386 4.7 and OpenBSD/i386 3.6.
18882
18883 echo "$as_me:$LINENO: checking for long double support in compiler" >&5
18884 echo $ECHO_N "checking for long double support in compiler... $ECHO_C" >&6
18885 if test "${gdb_cv_c_long_double+set}" = set; then
18886   echo $ECHO_N "(cached) $ECHO_C" >&6
18887 else
18888   cat >conftest.$ac_ext <<_ACEOF
18889 /* confdefs.h.  */
18890 _ACEOF
18891 cat confdefs.h >>conftest.$ac_ext
18892 cat >>conftest.$ac_ext <<_ACEOF
18893 /* end confdefs.h.  */
18894 long double foo;
18895 _ACEOF
18896 rm -f conftest.$ac_objext
18897 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18898   (eval $ac_compile) 2>conftest.er1
18899   ac_status=$?
18900   grep -v '^ *+' conftest.er1 >conftest.err
18901   rm -f conftest.er1
18902   cat conftest.err >&5
18903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18904   (exit $ac_status); } &&
18905          { ac_try='test -z "$ac_c_werror_flag"
18906                          || test ! -s conftest.err'
18907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18908   (eval $ac_try) 2>&5
18909   ac_status=$?
18910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18911   (exit $ac_status); }; } &&
18912          { ac_try='test -s conftest.$ac_objext'
18913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18914   (eval $ac_try) 2>&5
18915   ac_status=$?
18916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18917   (exit $ac_status); }; }; then
18918   gdb_cv_c_long_double=yes
18919 else
18920   echo "$as_me: failed program was:" >&5
18921 sed 's/^/| /' conftest.$ac_ext >&5
18922
18923 gdb_cv_c_long_double=no
18924 fi
18925 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18926 fi
18927 echo "$as_me:$LINENO: result: $gdb_cv_c_long_double" >&5
18928 echo "${ECHO_T}$gdb_cv_c_long_double" >&6
18929 if test $gdb_cv_c_long_double = yes; then
18930
18931 cat >>confdefs.h <<\_ACEOF
18932 #define HAVE_LONG_DOUBLE 1
18933 _ACEOF
18934
18935 fi
18936
18937 # Check if the compiler and runtime support printing long doubles.
18938
18939 echo "$as_me:$LINENO: checking for long double support in printf" >&5
18940 echo $ECHO_N "checking for long double support in printf... $ECHO_C" >&6
18941 if test "${gdb_cv_printf_has_long_double+set}" = set; then
18942   echo $ECHO_N "(cached) $ECHO_C" >&6
18943 else
18944   if test "$cross_compiling" = yes; then
18945   gdb_cv_printf_has_long_double=no
18946 else
18947   cat >conftest.$ac_ext <<_ACEOF
18948 /* confdefs.h.  */
18949 _ACEOF
18950 cat confdefs.h >>conftest.$ac_ext
18951 cat >>conftest.$ac_ext <<_ACEOF
18952 /* end confdefs.h.  */
18953 $ac_includes_default
18954 int
18955 main ()
18956 {
18957 char buf[16];
18958   long double f = 3.141592653;
18959   sprintf (buf, "%Lg", f);
18960   return (strncmp ("3.14159", buf, 7));
18961   ;
18962   return 0;
18963 }
18964 _ACEOF
18965 rm -f conftest$ac_exeext
18966 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18967   (eval $ac_link) 2>&5
18968   ac_status=$?
18969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18970   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18972   (eval $ac_try) 2>&5
18973   ac_status=$?
18974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18975   (exit $ac_status); }; }; then
18976   gdb_cv_printf_has_long_double=yes
18977 else
18978   echo "$as_me: program exited with status $ac_status" >&5
18979 echo "$as_me: failed program was:" >&5
18980 sed 's/^/| /' conftest.$ac_ext >&5
18981
18982 ( exit $ac_status )
18983 gdb_cv_printf_has_long_double=no
18984 fi
18985 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18986 fi
18987 fi
18988 echo "$as_me:$LINENO: result: $gdb_cv_printf_has_long_double" >&5
18989 echo "${ECHO_T}$gdb_cv_printf_has_long_double" >&6
18990 if test $gdb_cv_printf_has_long_double = yes; then
18991
18992 cat >>confdefs.h <<\_ACEOF
18993 #define PRINTF_HAS_LONG_DOUBLE 1
18994 _ACEOF
18995
18996 fi
18997
18998 # Check if the compiler and runtime support scanning long doubles.
18999
19000 echo "$as_me:$LINENO: checking for long double support in scanf" >&5
19001 echo $ECHO_N "checking for long double support in scanf... $ECHO_C" >&6
19002 if test "${gdb_cv_scanf_has_long_double+set}" = set; then
19003   echo $ECHO_N "(cached) $ECHO_C" >&6
19004 else
19005   if test "$cross_compiling" = yes; then
19006   gdb_cv_scanf_has_long_double=no
19007 else
19008   cat >conftest.$ac_ext <<_ACEOF
19009 /* confdefs.h.  */
19010 _ACEOF
19011 cat confdefs.h >>conftest.$ac_ext
19012 cat >>conftest.$ac_ext <<_ACEOF
19013 /* end confdefs.h.  */
19014 #include <stdio.h>
19015 int
19016 main ()
19017 {
19018 char *buf = "3.141592653";
19019   long double f = 0;
19020   sscanf (buf, "%Lg", &f);
19021   return !(f > 3.14159 && f < 3.14160);
19022   ;
19023   return 0;
19024 }
19025 _ACEOF
19026 rm -f conftest$ac_exeext
19027 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19028   (eval $ac_link) 2>&5
19029   ac_status=$?
19030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19031   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19032   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19033   (eval $ac_try) 2>&5
19034   ac_status=$?
19035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19036   (exit $ac_status); }; }; then
19037   gdb_cv_scanf_has_long_double=yes
19038 else
19039   echo "$as_me: program exited with status $ac_status" >&5
19040 echo "$as_me: failed program was:" >&5
19041 sed 's/^/| /' conftest.$ac_ext >&5
19042
19043 ( exit $ac_status )
19044 gdb_cv_scanf_has_long_double=no
19045 fi
19046 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19047 fi
19048 fi
19049 echo "$as_me:$LINENO: result: $gdb_cv_scanf_has_long_double" >&5
19050 echo "${ECHO_T}$gdb_cv_scanf_has_long_double" >&6
19051 if test $gdb_cv_scanf_has_long_double = yes; then
19052
19053 cat >>confdefs.h <<\_ACEOF
19054 #define SCANF_HAS_LONG_DOUBLE 1
19055 _ACEOF
19056
19057 fi
19058
19059 case ${host_os} in
19060 aix*)
19061   echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
19062 echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
19063 if test "${gdb_cv_bigtoc+set}" = set; then
19064   echo $ECHO_N "(cached) $ECHO_C" >&6
19065 else
19066
19067     SAVE_LDFLAGS=$LDFLAGS
19068
19069     case $GCC in
19070     yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
19071     *) gdb_cv_bigtoc=-bbigtoc ;;
19072     esac
19073
19074     LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
19075     cat >conftest.$ac_ext <<_ACEOF
19076 /* confdefs.h.  */
19077 _ACEOF
19078 cat confdefs.h >>conftest.$ac_ext
19079 cat >>conftest.$ac_ext <<_ACEOF
19080 /* end confdefs.h.  */
19081
19082 int
19083 main ()
19084 {
19085 int i;
19086   ;
19087   return 0;
19088 }
19089 _ACEOF
19090 rm -f conftest.$ac_objext conftest$ac_exeext
19091 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19092   (eval $ac_link) 2>conftest.er1
19093   ac_status=$?
19094   grep -v '^ *+' conftest.er1 >conftest.err
19095   rm -f conftest.er1
19096   cat conftest.err >&5
19097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19098   (exit $ac_status); } &&
19099          { ac_try='test -z "$ac_c_werror_flag"
19100                          || test ! -s conftest.err'
19101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19102   (eval $ac_try) 2>&5
19103   ac_status=$?
19104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19105   (exit $ac_status); }; } &&
19106          { ac_try='test -s conftest$ac_exeext'
19107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19108   (eval $ac_try) 2>&5
19109   ac_status=$?
19110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19111   (exit $ac_status); }; }; then
19112   :
19113 else
19114   echo "$as_me: failed program was:" >&5
19115 sed 's/^/| /' conftest.$ac_ext >&5
19116
19117 gdb_cv_bigtoc=
19118 fi
19119 rm -f conftest.err conftest.$ac_objext \
19120       conftest$ac_exeext conftest.$ac_ext
19121     LDFLAGS="${SAVE_LDFLAGS}"
19122
19123 fi
19124 echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
19125 echo "${ECHO_T}$gdb_cv_bigtoc" >&6
19126   CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
19127   ;;
19128 esac
19129
19130
19131
19132 if test ${build} = ${host} -a ${host} = ${target} ; then
19133    case ${host_os} in
19134    hpux*)
19135       echo "$as_me:$LINENO: checking for HPUX/OSF thread support" >&5
19136 echo $ECHO_N "checking for HPUX/OSF thread support... $ECHO_C" >&6
19137       if test -f /usr/include/dce/cma_config.h ; then
19138          if test "$GCC" = "yes" ; then
19139             echo "$as_me:$LINENO: result: yes" >&5
19140 echo "${ECHO_T}yes" >&6
19141
19142 cat >>confdefs.h <<\_ACEOF
19143 #define HAVE_HPUX_THREAD_SUPPORT 1
19144 _ACEOF
19145
19146             CONFIG_OBS="${CONFIG_OBS} hpux-thread.o"
19147             CONFIG_SRCS="${CONFIG_SRCS} hpux-thread.c"
19148          else
19149             echo "$as_me:$LINENO: result: no (suppressed because you are not using GCC)" >&5
19150 echo "${ECHO_T}no (suppressed because you are not using GCC)" >&6
19151          fi
19152       else
19153          echo "$as_me:$LINENO: result: no" >&5
19154 echo "${ECHO_T}no" >&6
19155       fi
19156       ;;
19157    solaris*)
19158       # See if thread_db library is around for Solaris thread debugging.
19159       # Note that we must explicitly test for version 1 of the library
19160       # because version 0 (present on Solaris 2.4 or earlier) doesn't have
19161       # the same API.
19162       echo "$as_me:$LINENO: checking for Solaris thread debugging library" >&5
19163 echo $ECHO_N "checking for Solaris thread debugging library... $ECHO_C" >&6
19164       if test -f /usr/lib/libthread_db.so.1 ; then
19165          echo "$as_me:$LINENO: result: yes" >&5
19166 echo "${ECHO_T}yes" >&6
19167
19168 cat >>confdefs.h <<\_ACEOF
19169 #define HAVE_THREAD_DB_LIB 1
19170 _ACEOF
19171
19172          CONFIG_OBS="${CONFIG_OBS} sol-thread.o"
19173          CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
19174
19175 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
19176 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
19177 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
19178   echo $ECHO_N "(cached) $ECHO_C" >&6
19179 else
19180   ac_check_lib_save_LIBS=$LIBS
19181 LIBS="-ldl  $LIBS"
19182 cat >conftest.$ac_ext <<_ACEOF
19183 /* confdefs.h.  */
19184 _ACEOF
19185 cat confdefs.h >>conftest.$ac_ext
19186 cat >>conftest.$ac_ext <<_ACEOF
19187 /* end confdefs.h.  */
19188
19189 /* Override any gcc2 internal prototype to avoid an error.  */
19190 #ifdef __cplusplus
19191 extern "C"
19192 #endif
19193 /* We use char because int might match the return type of a gcc2
19194    builtin and then its argument prototype would still apply.  */
19195 char dlopen ();
19196 int
19197 main ()
19198 {
19199 dlopen ();
19200   ;
19201   return 0;
19202 }
19203 _ACEOF
19204 rm -f conftest.$ac_objext conftest$ac_exeext
19205 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19206   (eval $ac_link) 2>conftest.er1
19207   ac_status=$?
19208   grep -v '^ *+' conftest.er1 >conftest.err
19209   rm -f conftest.er1
19210   cat conftest.err >&5
19211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19212   (exit $ac_status); } &&
19213          { ac_try='test -z "$ac_c_werror_flag"
19214                          || test ! -s conftest.err'
19215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19216   (eval $ac_try) 2>&5
19217   ac_status=$?
19218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19219   (exit $ac_status); }; } &&
19220          { ac_try='test -s conftest$ac_exeext'
19221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19222   (eval $ac_try) 2>&5
19223   ac_status=$?
19224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19225   (exit $ac_status); }; }; then
19226   ac_cv_lib_dl_dlopen=yes
19227 else
19228   echo "$as_me: failed program was:" >&5
19229 sed 's/^/| /' conftest.$ac_ext >&5
19230
19231 ac_cv_lib_dl_dlopen=no
19232 fi
19233 rm -f conftest.err conftest.$ac_objext \
19234       conftest$ac_exeext conftest.$ac_ext
19235 LIBS=$ac_check_lib_save_LIBS
19236 fi
19237 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
19238 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
19239 if test $ac_cv_lib_dl_dlopen = yes; then
19240   cat >>confdefs.h <<_ACEOF
19241 #define HAVE_LIBDL 1
19242 _ACEOF
19243
19244   LIBS="-ldl $LIBS"
19245
19246 fi
19247
19248          if test "$GCC" = "yes" ; then
19249             # The GNU linker requires the -export-dynamic option to make
19250             # all symbols visible in the dynamic symbol table.
19251             hold_ldflags=$LDFLAGS
19252             echo "$as_me:$LINENO: checking for the ld -export-dynamic flag" >&5
19253 echo $ECHO_N "checking for the ld -export-dynamic flag... $ECHO_C" >&6
19254             LDFLAGS="${LDFLAGS} -Wl,-export-dynamic"
19255             cat >conftest.$ac_ext <<_ACEOF
19256 /* confdefs.h.  */
19257 _ACEOF
19258 cat confdefs.h >>conftest.$ac_ext
19259 cat >>conftest.$ac_ext <<_ACEOF
19260 /* end confdefs.h.  */
19261
19262 int
19263 main ()
19264 {
19265 int i;
19266   ;
19267   return 0;
19268 }
19269 _ACEOF
19270 rm -f conftest.$ac_objext conftest$ac_exeext
19271 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19272   (eval $ac_link) 2>conftest.er1
19273   ac_status=$?
19274   grep -v '^ *+' conftest.er1 >conftest.err
19275   rm -f conftest.er1
19276   cat conftest.err >&5
19277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19278   (exit $ac_status); } &&
19279          { ac_try='test -z "$ac_c_werror_flag"
19280                          || test ! -s conftest.err'
19281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19282   (eval $ac_try) 2>&5
19283   ac_status=$?
19284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19285   (exit $ac_status); }; } &&
19286          { ac_try='test -s conftest$ac_exeext'
19287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19288   (eval $ac_try) 2>&5
19289   ac_status=$?
19290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19291   (exit $ac_status); }; }; then
19292   found=yes
19293 else
19294   echo "$as_me: failed program was:" >&5
19295 sed 's/^/| /' conftest.$ac_ext >&5
19296
19297 found=no
19298 fi
19299 rm -f conftest.err conftest.$ac_objext \
19300       conftest$ac_exeext conftest.$ac_ext
19301             LDFLAGS=$hold_ldflags
19302             echo "$as_me:$LINENO: result: $found" >&5
19303 echo "${ECHO_T}$found" >&6
19304             if test $found = yes; then
19305                CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -Wl,-export-dynamic"
19306             fi
19307          fi
19308          # Sun randomly tweaked the prototypes in <proc_service.h>
19309          # at one point.
19310          echo "$as_me:$LINENO: checking if <proc_service.h> is old" >&5
19311 echo $ECHO_N "checking if <proc_service.h> is old... $ECHO_C" >&6
19312          if test "${gdb_cv_proc_service_is_old+set}" = set; then
19313   echo $ECHO_N "(cached) $ECHO_C" >&6
19314 else
19315
19316             cat >conftest.$ac_ext <<_ACEOF
19317 /* confdefs.h.  */
19318 _ACEOF
19319 cat confdefs.h >>conftest.$ac_ext
19320 cat >>conftest.$ac_ext <<_ACEOF
19321 /* end confdefs.h.  */
19322
19323                 #include <proc_service.h>
19324                 ps_err_e ps_pdwrite
19325                     (struct ps_prochandle*, psaddr_t, const void*, size_t);
19326
19327 int
19328 main ()
19329 {
19330
19331   ;
19332   return 0;
19333 }
19334 _ACEOF
19335 rm -f conftest.$ac_objext
19336 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19337   (eval $ac_compile) 2>conftest.er1
19338   ac_status=$?
19339   grep -v '^ *+' conftest.er1 >conftest.err
19340   rm -f conftest.er1
19341   cat conftest.err >&5
19342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19343   (exit $ac_status); } &&
19344          { ac_try='test -z "$ac_c_werror_flag"
19345                          || test ! -s conftest.err'
19346   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19347   (eval $ac_try) 2>&5
19348   ac_status=$?
19349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19350   (exit $ac_status); }; } &&
19351          { ac_try='test -s conftest.$ac_objext'
19352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19353   (eval $ac_try) 2>&5
19354   ac_status=$?
19355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19356   (exit $ac_status); }; }; then
19357   gdb_cv_proc_service_is_old=no
19358 else
19359   echo "$as_me: failed program was:" >&5
19360 sed 's/^/| /' conftest.$ac_ext >&5
19361
19362 gdb_cv_proc_service_is_old=yes
19363 fi
19364 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19365
19366 fi
19367
19368          echo "$as_me:$LINENO: result: $gdb_cv_proc_service_is_old" >&5
19369 echo "${ECHO_T}$gdb_cv_proc_service_is_old" >&6
19370          if test $gdb_cv_proc_service_is_old = yes; then
19371
19372 cat >>confdefs.h <<\_ACEOF
19373 #define PROC_SERVICE_IS_OLD 1
19374 _ACEOF
19375
19376          fi
19377       else
19378          echo "$as_me:$LINENO: result: no" >&5
19379 echo "${ECHO_T}no" >&6
19380       fi
19381       ;;
19382    aix*)
19383       echo "$as_me:$LINENO: checking for AiX thread debugging library" >&5
19384 echo $ECHO_N "checking for AiX thread debugging library... $ECHO_C" >&6
19385       if test "${gdb_cv_have_aix_thread_debug+set}" = set; then
19386   echo $ECHO_N "(cached) $ECHO_C" >&6
19387 else
19388   cat >conftest.$ac_ext <<_ACEOF
19389 /* confdefs.h.  */
19390 _ACEOF
19391 cat confdefs.h >>conftest.$ac_ext
19392 cat >>conftest.$ac_ext <<_ACEOF
19393 /* end confdefs.h.  */
19394 #include <sys/pthdebug.h>
19395 int
19396 main ()
19397 {
19398 #ifndef PTHDB_VERSION_3
19399                                     #error
19400                                     #endif
19401   ;
19402   return 0;
19403 }
19404 _ACEOF
19405 rm -f conftest.$ac_objext
19406 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19407   (eval $ac_compile) 2>conftest.er1
19408   ac_status=$?
19409   grep -v '^ *+' conftest.er1 >conftest.err
19410   rm -f conftest.er1
19411   cat conftest.err >&5
19412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19413   (exit $ac_status); } &&
19414          { ac_try='test -z "$ac_c_werror_flag"
19415                          || test ! -s conftest.err'
19416   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19417   (eval $ac_try) 2>&5
19418   ac_status=$?
19419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19420   (exit $ac_status); }; } &&
19421          { ac_try='test -s conftest.$ac_objext'
19422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19423   (eval $ac_try) 2>&5
19424   ac_status=$?
19425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19426   (exit $ac_status); }; }; then
19427   gdb_cv_have_aix_thread_debug=yes
19428 else
19429   echo "$as_me: failed program was:" >&5
19430 sed 's/^/| /' conftest.$ac_ext >&5
19431
19432 gdb_cv_have_aix_thread_debug=no
19433 fi
19434 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19435 fi
19436
19437       echo "$as_me:$LINENO: result: $gdb_cv_have_aix_thread_debug" >&5
19438 echo "${ECHO_T}$gdb_cv_have_aix_thread_debug" >&6
19439       if test $gdb_cv_have_aix_thread_debug = yes; then
19440          CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
19441          CONFIG_OBS="${CONFIG_OBS} aix-thread.o"
19442          CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -lpthdebug"
19443       fi
19444       ;;
19445    esac
19446
19447 fi
19448
19449 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
19450    echo "$as_me:$LINENO: checking whether <thread_db.h> has TD_NOTALLOC" >&5
19451 echo $ECHO_N "checking whether <thread_db.h> has TD_NOTALLOC... $ECHO_C" >&6
19452 if test "${gdb_cv_thread_db_h_has_td_notalloc+set}" = set; then
19453   echo $ECHO_N "(cached) $ECHO_C" >&6
19454 else
19455   cat >conftest.$ac_ext <<_ACEOF
19456 /* confdefs.h.  */
19457 _ACEOF
19458 cat confdefs.h >>conftest.$ac_ext
19459 cat >>conftest.$ac_ext <<_ACEOF
19460 /* end confdefs.h.  */
19461 #include <thread_db.h>
19462 int
19463 main ()
19464 {
19465 int i = TD_NOTALLOC;
19466   ;
19467   return 0;
19468 }
19469 _ACEOF
19470 rm -f conftest.$ac_objext
19471 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19472   (eval $ac_compile) 2>conftest.er1
19473   ac_status=$?
19474   grep -v '^ *+' conftest.er1 >conftest.err
19475   rm -f conftest.er1
19476   cat conftest.err >&5
19477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19478   (exit $ac_status); } &&
19479          { ac_try='test -z "$ac_c_werror_flag"
19480                          || test ! -s conftest.err'
19481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19482   (eval $ac_try) 2>&5
19483   ac_status=$?
19484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19485   (exit $ac_status); }; } &&
19486          { ac_try='test -s conftest.$ac_objext'
19487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19488   (eval $ac_try) 2>&5
19489   ac_status=$?
19490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19491   (exit $ac_status); }; }; then
19492   gdb_cv_thread_db_h_has_td_notalloc=yes
19493 else
19494   echo "$as_me: failed program was:" >&5
19495 sed 's/^/| /' conftest.$ac_ext >&5
19496
19497 gdb_cv_thread_db_h_has_td_notalloc=no
19498
19499 fi
19500 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19501
19502 fi
19503 echo "$as_me:$LINENO: result: $gdb_cv_thread_db_h_has_td_notalloc" >&5
19504 echo "${ECHO_T}$gdb_cv_thread_db_h_has_td_notalloc" >&6
19505    echo "$as_me:$LINENO: checking whether <thread_db.h> has TD_VERSION" >&5
19506 echo $ECHO_N "checking whether <thread_db.h> has TD_VERSION... $ECHO_C" >&6
19507 if test "${gdb_cv_thread_db_h_has_td_version+set}" = set; then
19508   echo $ECHO_N "(cached) $ECHO_C" >&6
19509 else
19510   cat >conftest.$ac_ext <<_ACEOF
19511 /* confdefs.h.  */
19512 _ACEOF
19513 cat confdefs.h >>conftest.$ac_ext
19514 cat >>conftest.$ac_ext <<_ACEOF
19515 /* end confdefs.h.  */
19516 #include <thread_db.h>
19517 int
19518 main ()
19519 {
19520 int i = TD_VERSION;
19521   ;
19522   return 0;
19523 }
19524 _ACEOF
19525 rm -f conftest.$ac_objext
19526 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19527   (eval $ac_compile) 2>conftest.er1
19528   ac_status=$?
19529   grep -v '^ *+' conftest.er1 >conftest.err
19530   rm -f conftest.er1
19531   cat conftest.err >&5
19532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19533   (exit $ac_status); } &&
19534          { ac_try='test -z "$ac_c_werror_flag"
19535                          || test ! -s conftest.err'
19536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19537   (eval $ac_try) 2>&5
19538   ac_status=$?
19539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19540   (exit $ac_status); }; } &&
19541          { ac_try='test -s conftest.$ac_objext'
19542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19543   (eval $ac_try) 2>&5
19544   ac_status=$?
19545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19546   (exit $ac_status); }; }; then
19547   gdb_cv_thread_db_h_has_td_version=yes
19548 else
19549   echo "$as_me: failed program was:" >&5
19550 sed 's/^/| /' conftest.$ac_ext >&5
19551
19552 gdb_cv_thread_db_h_has_td_version=no
19553
19554 fi
19555 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19556
19557 fi
19558 echo "$as_me:$LINENO: result: $gdb_cv_thread_db_h_has_td_version" >&5
19559 echo "${ECHO_T}$gdb_cv_thread_db_h_has_td_version" >&6
19560    echo "$as_me:$LINENO: checking whether <thread_db.h> has TD_NOTLS" >&5
19561 echo $ECHO_N "checking whether <thread_db.h> has TD_NOTLS... $ECHO_C" >&6
19562 if test "${gdb_cv_thread_db_h_has_td_notls+set}" = set; then
19563   echo $ECHO_N "(cached) $ECHO_C" >&6
19564 else
19565   cat >conftest.$ac_ext <<_ACEOF
19566 /* confdefs.h.  */
19567 _ACEOF
19568 cat confdefs.h >>conftest.$ac_ext
19569 cat >>conftest.$ac_ext <<_ACEOF
19570 /* end confdefs.h.  */
19571 #include <thread_db.h>
19572 int
19573 main ()
19574 {
19575 int i = TD_NOTLS;
19576   ;
19577   return 0;
19578 }
19579 _ACEOF
19580 rm -f conftest.$ac_objext
19581 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19582   (eval $ac_compile) 2>conftest.er1
19583   ac_status=$?
19584   grep -v '^ *+' conftest.er1 >conftest.err
19585   rm -f conftest.er1
19586   cat conftest.err >&5
19587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19588   (exit $ac_status); } &&
19589          { ac_try='test -z "$ac_c_werror_flag"
19590                          || test ! -s conftest.err'
19591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19592   (eval $ac_try) 2>&5
19593   ac_status=$?
19594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19595   (exit $ac_status); }; } &&
19596          { ac_try='test -s conftest.$ac_objext'
19597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19598   (eval $ac_try) 2>&5
19599   ac_status=$?
19600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19601   (exit $ac_status); }; }; then
19602   gdb_cv_thread_db_h_has_td_notls=yes
19603 else
19604   echo "$as_me: failed program was:" >&5
19605 sed 's/^/| /' conftest.$ac_ext >&5
19606
19607 gdb_cv_thread_db_h_has_td_notls=no
19608
19609 fi
19610 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19611
19612 fi
19613 echo "$as_me:$LINENO: result: $gdb_cv_thread_db_h_has_td_notls" >&5
19614 echo "${ECHO_T}$gdb_cv_thread_db_h_has_td_notls" >&6
19615 fi
19616 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
19617
19618 cat >>confdefs.h <<\_ACEOF
19619 #define THREAD_DB_HAS_TD_NOTALLOC 1
19620 _ACEOF
19621
19622 fi
19623 if test "x$gdb_cv_thread_db_h_has_td_version" = "xyes"; then
19624
19625 cat >>confdefs.h <<\_ACEOF
19626 #define THREAD_DB_HAS_TD_VERSION 1
19627 _ACEOF
19628
19629 fi
19630 if test "x$gdb_cv_thread_db_h_has_td_notls" = "xyes"; then
19631
19632 cat >>confdefs.h <<\_ACEOF
19633 #define THREAD_DB_HAS_TD_NOTLS 1
19634 _ACEOF
19635
19636 fi
19637
19638 if test "x$ac_cv_header_sys_syscall_h" = "xyes"; then
19639    echo "$as_me:$LINENO: checking whether <sys/syscall.h> has __NR_tkill" >&5
19640 echo $ECHO_N "checking whether <sys/syscall.h> has __NR_tkill... $ECHO_C" >&6
19641 if test "${gdb_cv_sys_syscall_h_has_tkill+set}" = set; then
19642   echo $ECHO_N "(cached) $ECHO_C" >&6
19643 else
19644   cat >conftest.$ac_ext <<_ACEOF
19645 /* confdefs.h.  */
19646 _ACEOF
19647 cat confdefs.h >>conftest.$ac_ext
19648 cat >>conftest.$ac_ext <<_ACEOF
19649 /* end confdefs.h.  */
19650 #include <sys/syscall.h>
19651 int
19652 main ()
19653 {
19654 int i = __NR_tkill;
19655   ;
19656   return 0;
19657 }
19658 _ACEOF
19659 rm -f conftest.$ac_objext
19660 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19661   (eval $ac_compile) 2>conftest.er1
19662   ac_status=$?
19663   grep -v '^ *+' conftest.er1 >conftest.err
19664   rm -f conftest.er1
19665   cat conftest.err >&5
19666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19667   (exit $ac_status); } &&
19668          { ac_try='test -z "$ac_c_werror_flag"
19669                          || test ! -s conftest.err'
19670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19671   (eval $ac_try) 2>&5
19672   ac_status=$?
19673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19674   (exit $ac_status); }; } &&
19675          { ac_try='test -s conftest.$ac_objext'
19676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19677   (eval $ac_try) 2>&5
19678   ac_status=$?
19679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19680   (exit $ac_status); }; }; then
19681   gdb_cv_sys_syscall_h_has_tkill=yes
19682 else
19683   echo "$as_me: failed program was:" >&5
19684 sed 's/^/| /' conftest.$ac_ext >&5
19685
19686 gdb_cv_sys_syscall_h_has_tkill=no
19687
19688 fi
19689 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19690
19691 fi
19692 echo "$as_me:$LINENO: result: $gdb_cv_sys_syscall_h_has_tkill" >&5
19693 echo "${ECHO_T}$gdb_cv_sys_syscall_h_has_tkill" >&6
19694 fi
19695 if test "x$gdb_cv_sys_syscall_h_has_tkill" = "xyes" && test "x$ac_cv_func_syscall" = "xyes"; then
19696
19697 cat >>confdefs.h <<\_ACEOF
19698 #define HAVE_TKILL_SYSCALL 1
19699 _ACEOF
19700
19701 fi
19702
19703 echo "$as_me:$LINENO: checking whether ADDR_NO_RANDOMIZE is declared" >&5
19704 echo $ECHO_N "checking whether ADDR_NO_RANDOMIZE is declared... $ECHO_C" >&6
19705 if test "${ac_cv_have_decl_ADDR_NO_RANDOMIZE+set}" = set; then
19706   echo $ECHO_N "(cached) $ECHO_C" >&6
19707 else
19708   cat >conftest.$ac_ext <<_ACEOF
19709 /* confdefs.h.  */
19710 _ACEOF
19711 cat confdefs.h >>conftest.$ac_ext
19712 cat >>conftest.$ac_ext <<_ACEOF
19713 /* end confdefs.h.  */
19714 #include <sys/personality.h>
19715
19716 int
19717 main ()
19718 {
19719 #ifndef ADDR_NO_RANDOMIZE
19720   char *p = (char *) ADDR_NO_RANDOMIZE;
19721 #endif
19722
19723   ;
19724   return 0;
19725 }
19726 _ACEOF
19727 rm -f conftest.$ac_objext
19728 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19729   (eval $ac_compile) 2>conftest.er1
19730   ac_status=$?
19731   grep -v '^ *+' conftest.er1 >conftest.err
19732   rm -f conftest.er1
19733   cat conftest.err >&5
19734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19735   (exit $ac_status); } &&
19736          { ac_try='test -z "$ac_c_werror_flag"
19737                          || test ! -s conftest.err'
19738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19739   (eval $ac_try) 2>&5
19740   ac_status=$?
19741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19742   (exit $ac_status); }; } &&
19743          { ac_try='test -s conftest.$ac_objext'
19744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19745   (eval $ac_try) 2>&5
19746   ac_status=$?
19747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19748   (exit $ac_status); }; }; then
19749   ac_cv_have_decl_ADDR_NO_RANDOMIZE=yes
19750 else
19751   echo "$as_me: failed program was:" >&5
19752 sed 's/^/| /' conftest.$ac_ext >&5
19753
19754 ac_cv_have_decl_ADDR_NO_RANDOMIZE=no
19755 fi
19756 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19757 fi
19758 echo "$as_me:$LINENO: result: $ac_cv_have_decl_ADDR_NO_RANDOMIZE" >&5
19759 echo "${ECHO_T}$ac_cv_have_decl_ADDR_NO_RANDOMIZE" >&6
19760 if test $ac_cv_have_decl_ADDR_NO_RANDOMIZE = yes; then
19761
19762 cat >>confdefs.h <<_ACEOF
19763 #define HAVE_DECL_ADDR_NO_RANDOMIZE 1
19764 _ACEOF
19765
19766
19767 else
19768   cat >>confdefs.h <<_ACEOF
19769 #define HAVE_DECL_ADDR_NO_RANDOMIZE 0
19770 _ACEOF
19771
19772
19773 fi
19774
19775
19776
19777 if test "$cross_compiling" = yes; then
19778   cat >conftest.$ac_ext <<_ACEOF
19779 /* confdefs.h.  */
19780 _ACEOF
19781 cat confdefs.h >>conftest.$ac_ext
19782 cat >>conftest.$ac_ext <<_ACEOF
19783 /* end confdefs.h.  */
19784 #include <sys/personality.h>
19785 int
19786 main ()
19787 {
19788
19789 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
19790 #       define ADDR_NO_RANDOMIZE 0x0040000
19791 #      endif
19792        /* Test the flag could be set and stays set.  */
19793        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
19794        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
19795            return 1
19796   ;
19797   return 0;
19798 }
19799 _ACEOF
19800 rm -f conftest.$ac_objext conftest$ac_exeext
19801 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19802   (eval $ac_link) 2>conftest.er1
19803   ac_status=$?
19804   grep -v '^ *+' conftest.er1 >conftest.err
19805   rm -f conftest.er1
19806   cat conftest.err >&5
19807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19808   (exit $ac_status); } &&
19809          { ac_try='test -z "$ac_c_werror_flag"
19810                          || test ! -s conftest.err'
19811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19812   (eval $ac_try) 2>&5
19813   ac_status=$?
19814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19815   (exit $ac_status); }; } &&
19816          { ac_try='test -s conftest$ac_exeext'
19817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19818   (eval $ac_try) 2>&5
19819   ac_status=$?
19820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19821   (exit $ac_status); }; }; then
19822   have_personality=true
19823 else
19824   echo "$as_me: failed program was:" >&5
19825 sed 's/^/| /' conftest.$ac_ext >&5
19826
19827 have_personality=false
19828 fi
19829 rm -f conftest.err conftest.$ac_objext \
19830       conftest$ac_exeext conftest.$ac_ext
19831 else
19832   cat >conftest.$ac_ext <<_ACEOF
19833 /* confdefs.h.  */
19834 _ACEOF
19835 cat confdefs.h >>conftest.$ac_ext
19836 cat >>conftest.$ac_ext <<_ACEOF
19837 /* end confdefs.h.  */
19838 #include <sys/personality.h>
19839 int
19840 main ()
19841 {
19842
19843 #      if !HAVE_DECL_ADDR_NO_RANDOMIZE
19844 #       define ADDR_NO_RANDOMIZE 0x0040000
19845 #      endif
19846        /* Test the flag could be set and stays set.  */
19847        personality (personality (0xffffffff) | ADDR_NO_RANDOMIZE);
19848        if (!(personality (personality (0xffffffff)) & ADDR_NO_RANDOMIZE))
19849            return 1
19850   ;
19851   return 0;
19852 }
19853 _ACEOF
19854 rm -f conftest$ac_exeext
19855 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19856   (eval $ac_link) 2>&5
19857   ac_status=$?
19858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19859   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19860   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19861   (eval $ac_try) 2>&5
19862   ac_status=$?
19863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19864   (exit $ac_status); }; }; then
19865   have_personality=true
19866 else
19867   echo "$as_me: program exited with status $ac_status" >&5
19868 echo "$as_me: failed program was:" >&5
19869 sed 's/^/| /' conftest.$ac_ext >&5
19870
19871 ( exit $ac_status )
19872 have_personality=false
19873 fi
19874 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19875 fi
19876 if $have_personality
19877 then
19878
19879 cat >>confdefs.h <<\_ACEOF
19880 #define HAVE_PERSONALITY 1
19881 _ACEOF
19882
19883 fi
19884
19885
19886
19887 # Check whether --with-sysroot or --without-sysroot was given.
19888 if test "${with_sysroot+set}" = set; then
19889   withval="$with_sysroot"
19890
19891  case ${with_sysroot} in
19892  yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
19893  *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
19894  esac
19895
19896  TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
19897
19898  if test "x$prefix" = xNONE; then
19899   test_prefix=/usr/local
19900  else
19901   test_prefix=$prefix
19902  fi
19903  if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
19904   test_exec_prefix=$test_prefix
19905  else
19906   test_exec_prefix=$exec_prefix
19907  fi
19908  case ${TARGET_SYSTEM_ROOT} in
19909  "${test_prefix}"|"${test_prefix}/"*|\
19910  "${test_exec_prefix}"|"${test_exec_prefix}/"*|\
19911  '${prefix}'|'${prefix}/'*|\
19912  '${exec_prefix}'|'${exec_prefix}/'*)
19913    t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
19914    TARGET_SYSTEM_ROOT_DEFINE="$t"
19915    ;;
19916  esac
19917
19918 else
19919
19920  TARGET_SYSTEM_ROOT=
19921  TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
19922
19923 fi;
19924
19925
19926
19927 system_gdbinit=
19928
19929 # Check whether --with-system-gdbinit or --without-system-gdbinit was given.
19930 if test "${with_system_gdbinit+set}" = set; then
19931   withval="$with_system_gdbinit"
19932   system_gdbinit=${withval}
19933 fi;
19934
19935
19936   test "x$prefix" = xNONE && prefix="$ac_default_prefix"
19937   test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19938   ac_define_dir=`eval echo $system_gdbinit`
19939   ac_define_dir=`eval echo $ac_define_dir`
19940
19941 cat >>confdefs.h <<_ACEOF
19942 #define SYSTEM_GDBINIT "$ac_define_dir"
19943 _ACEOF
19944
19945
19946
19947 if test "x$prefix" = xNONE; then
19948   test_prefix=$ac_default_prefix
19949 else
19950   test_prefix=$prefix
19951 fi
19952 if test "x$exec_prefix" = xNONE || test "x$exec_prefix" = 'x${prefix}'; then
19953   test_exec_prefix=$test_prefix
19954 else
19955   test_exec_prefix=$exec_prefix
19956 fi
19957 case ${system_gdbinit} in
19958  "${test_prefix}"|"${test_prefix}/"*|\
19959  "${test_exec_prefix}"|"${test_exec_prefix}/"*|\
19960  '${prefix}'|'${prefix}/'*|\
19961  '${exec_prefix}'|'${exec_prefix}/'*)
19962
19963 cat >>confdefs.h <<\_ACEOF
19964 #define SYSTEM_GDBINIT_RELOCATABLE 1
19965 _ACEOF
19966
19967    ;;
19968 esac
19969
19970 # Check whether --enable-werror or --disable-werror was given.
19971 if test "${enable_werror+set}" = set; then
19972   enableval="$enable_werror"
19973   case "${enableval}" in
19974      yes | y) ERROR_ON_WARNING="yes" ;;
19975      no | n)  ERROR_ON_WARNING="no" ;;
19976      *) { { echo "$as_me:$LINENO: error: bad value ${enableval} for --enable-werror" >&5
19977 echo "$as_me: error: bad value ${enableval} for --enable-werror" >&2;}
19978    { (exit 1); exit 1; }; } ;;
19979    esac
19980 fi;
19981
19982 # Enable -Werror by default when using gcc
19983 if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
19984     ERROR_ON_WARNING=yes
19985 fi
19986
19987 WERROR_CFLAGS=""
19988 if test "${ERROR_ON_WARNING}" = yes ; then
19989     WERROR_CFLAGS="-Werror"
19990 fi
19991
19992 # The entries after -Wno-pointer-sign are disabled warnings which may
19993 # be enabled in the future, which can not currently be used to build
19994 # GDB.
19995 # NOTE: If you change this list, remember to update
19996 # gdb/doc/gdbint.texinfo.
19997 build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
19998 -Wformat-nonliteral -Wno-pointer-sign \
19999 -Wno-unused -Wno-switch -Wno-char-subscripts"
20000
20001 # Enable -Wno-format by default when using gcc on mingw since many
20002 # GCC versions complain about %I64.
20003 case "${host}" in
20004   *-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
20005 esac
20006
20007 # Check whether --enable-build-warnings or --disable-build-warnings was given.
20008 if test "${enable_build_warnings+set}" = set; then
20009   enableval="$enable_build_warnings"
20010   case "${enableval}" in
20011   yes)  ;;
20012   no)   build_warnings="-w";;
20013   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
20014         build_warnings="${build_warnings} ${t}";;
20015   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
20016         build_warnings="${t} ${build_warnings}";;
20017   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
20018 esac
20019 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
20020   echo "Setting compiler warning flags = $build_warnings" 6>&1
20021 fi
20022 fi; # Check whether --enable-gdb-build-warnings or --disable-gdb-build-warnings was given.
20023 if test "${enable_gdb_build_warnings+set}" = set; then
20024   enableval="$enable_gdb_build_warnings"
20025   case "${enableval}" in
20026   yes)  ;;
20027   no)   build_warnings="-w";;
20028   ,*)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
20029         build_warnings="${build_warnings} ${t}";;
20030   *,)   t=`echo "${enableval}" | sed -e "s/,/ /g"`
20031         build_warnings="${t} ${build_warnings}";;
20032   *)    build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
20033 esac
20034 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
20035   echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
20036 fi
20037 fi; WARN_CFLAGS=""
20038 if test "x${build_warnings}" != x -a "x$GCC" = xyes
20039 then
20040     echo "$as_me:$LINENO: checking compiler warning flags" >&5
20041 echo $ECHO_N "checking compiler warning flags... $ECHO_C" >&6
20042     # Separate out the -Werror flag as some files just cannot be
20043     # compiled with it enabled.
20044     for w in ${build_warnings}; do
20045         case $w in
20046         -Werr*) WERROR_CFLAGS=-Werror ;;
20047         *) # Check that GCC accepts it
20048             saved_CFLAGS="$CFLAGS"
20049             CFLAGS="$CFLAGS $w"
20050             cat >conftest.$ac_ext <<_ACEOF
20051 /* confdefs.h.  */
20052 _ACEOF
20053 cat confdefs.h >>conftest.$ac_ext
20054 cat >>conftest.$ac_ext <<_ACEOF
20055 /* end confdefs.h.  */
20056
20057 int
20058 main ()
20059 {
20060
20061   ;
20062   return 0;
20063 }
20064 _ACEOF
20065 rm -f conftest.$ac_objext
20066 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20067   (eval $ac_compile) 2>conftest.er1
20068   ac_status=$?
20069   grep -v '^ *+' conftest.er1 >conftest.err
20070   rm -f conftest.er1
20071   cat conftest.err >&5
20072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20073   (exit $ac_status); } &&
20074          { ac_try='test -z "$ac_c_werror_flag"
20075                          || test ! -s conftest.err'
20076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20077   (eval $ac_try) 2>&5
20078   ac_status=$?
20079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20080   (exit $ac_status); }; } &&
20081          { ac_try='test -s conftest.$ac_objext'
20082   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20083   (eval $ac_try) 2>&5
20084   ac_status=$?
20085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20086   (exit $ac_status); }; }; then
20087   WARN_CFLAGS="${WARN_CFLAGS} $w"
20088 else
20089   echo "$as_me: failed program was:" >&5
20090 sed 's/^/| /' conftest.$ac_ext >&5
20091
20092 fi
20093 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20094             CFLAGS="$saved_CFLAGS"
20095         esac
20096     done
20097     echo "$as_me:$LINENO: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
20098 echo "${ECHO_T}${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6
20099 fi
20100
20101
20102
20103 # In the Cygwin environment, we need some additional flags.
20104 echo "$as_me:$LINENO: checking for cygwin" >&5
20105 echo $ECHO_N "checking for cygwin... $ECHO_C" >&6
20106 if test "${gdb_cv_os_cygwin+set}" = set; then
20107   echo $ECHO_N "(cached) $ECHO_C" >&6
20108 else
20109   cat >conftest.$ac_ext <<_ACEOF
20110 /* confdefs.h.  */
20111 _ACEOF
20112 cat confdefs.h >>conftest.$ac_ext
20113 cat >>conftest.$ac_ext <<_ACEOF
20114 /* end confdefs.h.  */
20115
20116 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
20117 lose
20118 #endif
20119 _ACEOF
20120 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20121   $EGREP "lose" >/dev/null 2>&1; then
20122   gdb_cv_os_cygwin=yes
20123 else
20124   gdb_cv_os_cygwin=no
20125 fi
20126 rm -f conftest*
20127
20128 fi
20129 echo "$as_me:$LINENO: result: $gdb_cv_os_cygwin" >&5
20130 echo "${ECHO_T}$gdb_cv_os_cygwin" >&6
20131
20132
20133 SER_HARDWIRE="ser-base.o ser-unix.o ser-pipe.o ser-tcp.o"
20134 case ${host} in
20135   *go32* ) SER_HARDWIRE=ser-go32.o ;;
20136   *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
20137   *mingw32*) SER_HARDWIRE="ser-base.o ser-tcp.o ser-mingw.o" ;;
20138 esac
20139
20140
20141 # libreadline needs libuser32.a in a cygwin environment
20142 WIN32LIBS=
20143 if test x$gdb_cv_os_cygwin = xyes; then
20144     WIN32LIBS="-luser32"
20145     case "${target}" in
20146         *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
20147         ;;
20148     esac
20149 fi
20150
20151 # The ser-tcp.c module requires sockets.
20152 case ${host} in
20153   *mingw32*)
20154
20155 cat >>confdefs.h <<\_ACEOF
20156 #define USE_WIN32API 1
20157 _ACEOF
20158
20159     WIN32LIBS="$WIN32LIBS -lws2_32"
20160     ;;
20161 esac
20162
20163
20164 # Add ELF support to GDB, but only if BFD includes ELF support.
20165 OLD_CFLAGS=$CFLAGS
20166 OLD_LDFLAGS=$LDFLAGS
20167 OLD_LIBS=$LIBS
20168 CFLAGS="$CFLAGS -I${srcdir}/../include -I../bfd -I${srcdir}/../bfd"
20169 LDFLAGS="$LDFLAGS -L../bfd -L../libiberty"
20170 intl=`echo $LIBINTL | sed 's,${top_builddir}/,,g'`
20171 LIBS="-lbfd -liberty $intl $LIBS"
20172 echo "$as_me:$LINENO: checking for ELF support in BFD" >&5
20173 echo $ECHO_N "checking for ELF support in BFD... $ECHO_C" >&6
20174 if test "${gdb_cv_var_elf+set}" = set; then
20175   echo $ECHO_N "(cached) $ECHO_C" >&6
20176 else
20177   cat >conftest.$ac_ext <<_ACEOF
20178 /* confdefs.h.  */
20179 _ACEOF
20180 cat confdefs.h >>conftest.$ac_ext
20181 cat >>conftest.$ac_ext <<_ACEOF
20182 /* end confdefs.h.  */
20183 #include <stdlib.h>
20184 #include "bfd.h"
20185 #include "elf-bfd.h"
20186
20187 int
20188 main ()
20189 {
20190 bfd *abfd = NULL; bfd_get_elf_phdr_upper_bound (abfd);
20191   ;
20192   return 0;
20193 }
20194 _ACEOF
20195 rm -f conftest.$ac_objext conftest$ac_exeext
20196 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20197   (eval $ac_link) 2>conftest.er1
20198   ac_status=$?
20199   grep -v '^ *+' conftest.er1 >conftest.err
20200   rm -f conftest.er1
20201   cat conftest.err >&5
20202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20203   (exit $ac_status); } &&
20204          { ac_try='test -z "$ac_c_werror_flag"
20205                          || test ! -s conftest.err'
20206   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20207   (eval $ac_try) 2>&5
20208   ac_status=$?
20209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20210   (exit $ac_status); }; } &&
20211          { ac_try='test -s conftest$ac_exeext'
20212   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20213   (eval $ac_try) 2>&5
20214   ac_status=$?
20215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20216   (exit $ac_status); }; }; then
20217   gdb_cv_var_elf=yes
20218 else
20219   echo "$as_me: failed program was:" >&5
20220 sed 's/^/| /' conftest.$ac_ext >&5
20221
20222 gdb_cv_var_elf=no
20223 fi
20224 rm -f conftest.err conftest.$ac_objext \
20225       conftest$ac_exeext conftest.$ac_ext
20226 fi
20227 echo "$as_me:$LINENO: result: $gdb_cv_var_elf" >&5
20228 echo "${ECHO_T}$gdb_cv_var_elf" >&6
20229 if test $gdb_cv_var_elf = yes; then
20230   CONFIG_OBS="$CONFIG_OBS elfread.o"
20231
20232 cat >>confdefs.h <<\_ACEOF
20233 #define HAVE_ELF 1
20234 _ACEOF
20235
20236 fi
20237 CFLAGS=$OLD_CFLAGS
20238 LDFLAGS=$OLD_LDFLAGS
20239 LIBS=$OLD_LIBS
20240
20241 # Add any host-specific objects to GDB.
20242 CONFIG_OBS="${CONFIG_OBS} ${gdb_host_obs}"
20243
20244 LIBGUI="../libgui/src/libgui.a"
20245 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
20246
20247
20248
20249 WIN32LDAPP=
20250
20251
20252
20253 case "${host}" in
20254 *-*-cygwin* | *-*-mingw* )
20255     configdir="win"
20256     ;;
20257 *)
20258     configdir="unix"
20259     ;;
20260 esac
20261
20262 GDBTKLIBS=
20263 if test "${enable_gdbtk}" = "yes"; then
20264
20265     # Gdbtk must have an absolute path to srcdir in order to run
20266     # properly when not installed.
20267     here=`pwd`
20268     cd ${srcdir}
20269     GDBTK_SRC_DIR=`pwd`
20270     cd $here
20271
20272
20273     #
20274     # Ok, lets find the tcl configuration
20275     # First, look for one uninstalled.
20276     # the alternative search directory is invoked by --with-tcl
20277     #
20278
20279     if test x"${no_tcl}" = x ; then
20280         # we reset no_tcl in case something fails here
20281         no_tcl=true
20282
20283 # Check whether --with-tcl or --without-tcl was given.
20284 if test "${with_tcl+set}" = set; then
20285   withval="$with_tcl"
20286   with_tclconfig=${withval}
20287 fi;
20288         echo "$as_me:$LINENO: checking for Tcl configuration" >&5
20289 echo $ECHO_N "checking for Tcl configuration... $ECHO_C" >&6
20290         if test "${ac_cv_c_tclconfig+set}" = set; then
20291   echo $ECHO_N "(cached) $ECHO_C" >&6
20292 else
20293
20294
20295             # First check to see if --with-tcl was specified.
20296             case "${host}" in
20297                 *-*-cygwin*) platDir="win" ;;
20298                 *) platDir="unix" ;;
20299             esac
20300             if test x"${with_tclconfig}" != x ; then
20301                 if test -f "${with_tclconfig}/tclConfig.sh" ; then
20302                     ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
20303                 else
20304                     { { echo "$as_me:$LINENO: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&5
20305 echo "$as_me: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&2;}
20306    { (exit 1); exit 1; }; }
20307                 fi
20308             fi
20309
20310             # then check for a private Tcl installation
20311             if test x"${ac_cv_c_tclconfig}" = x ; then
20312                 for i in \
20313                         ../tcl \
20314                         `ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
20315                         `ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
20316                         `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
20317                         ../../tcl \
20318                         `ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
20319                         `ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
20320                         `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
20321                         ../../../tcl \
20322                         `ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
20323                         `ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
20324                         `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
20325                     if test -f "$i/$platDir/tclConfig.sh" ; then
20326                         ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
20327                         break
20328                     fi
20329                 done
20330             fi
20331
20332             # on Darwin, check in Framework installation locations
20333             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
20334                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
20335                         `ls -d /Library/Frameworks 2>/dev/null` \
20336                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
20337                         `ls -d /System/Library/Frameworks 2>/dev/null` \
20338                         ; do
20339                     if test -f "$i/Tcl.framework/tclConfig.sh" ; then
20340                         ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
20341                         break
20342                     fi
20343                 done
20344             fi
20345
20346             # check in a few common install locations
20347             if test x"${ac_cv_c_tclconfig}" = x ; then
20348                 for i in `ls -d ${libdir} 2>/dev/null` \
20349                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
20350                         `ls -d ${prefix}/lib 2>/dev/null` \
20351                         `ls -d /usr/local/lib 2>/dev/null` \
20352                         `ls -d /usr/contrib/lib 2>/dev/null` \
20353                         `ls -d /usr/lib 2>/dev/null` \
20354                         ; do
20355                     if test -f "$i/tclConfig.sh" ; then
20356                         ac_cv_c_tclconfig=`(cd $i; pwd)`
20357                         break
20358                     fi
20359                 done
20360             fi
20361
20362             # check in a few other private locations
20363             if test x"${ac_cv_c_tclconfig}" = x ; then
20364                 for i in \
20365                         ${srcdir}/../tcl \
20366                         `ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
20367                         `ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
20368                         `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
20369                     if test -f "$i/$platDir/tclConfig.sh" ; then
20370                     ac_cv_c_tclconfig=`(cd $i/$platDir; pwd)`
20371                     break
20372                 fi
20373                 done
20374             fi
20375
20376 fi
20377
20378
20379         if test x"${ac_cv_c_tclconfig}" = x ; then
20380             TCL_BIN_DIR="# no Tcl configs found"
20381             { echo "$as_me:$LINENO: WARNING: Can't find Tcl configuration definitions" >&5
20382 echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
20383         else
20384             no_tcl=
20385             TCL_BIN_DIR=${ac_cv_c_tclconfig}
20386             echo "$as_me:$LINENO: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
20387 echo "${ECHO_T}found ${TCL_BIN_DIR}/tclConfig.sh" >&6
20388         fi
20389     fi
20390
20391
20392     # If $no_tk is nonempty, then we can't do Tk, and there is no
20393     # point to doing Tcl.
20394
20395     #
20396     # Ok, lets find the tk configuration
20397     # First, look for one uninstalled.
20398     # the alternative search directory is invoked by --with-tk
20399     #
20400
20401     if test x"${no_tk}" = x ; then
20402         # we reset no_tk in case something fails here
20403         no_tk=true
20404
20405 # Check whether --with-tk or --without-tk was given.
20406 if test "${with_tk+set}" = set; then
20407   withval="$with_tk"
20408   with_tkconfig=${withval}
20409 fi;
20410         echo "$as_me:$LINENO: checking for Tk configuration" >&5
20411 echo $ECHO_N "checking for Tk configuration... $ECHO_C" >&6
20412         if test "${ac_cv_c_tkconfig+set}" = set; then
20413   echo $ECHO_N "(cached) $ECHO_C" >&6
20414 else
20415
20416
20417             # First check to see if --with-tkconfig was specified.
20418             if test x"${with_tkconfig}" != x ; then
20419                 if test -f "${with_tkconfig}/tkConfig.sh" ; then
20420                     ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
20421                 else
20422                     { { echo "$as_me:$LINENO: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" >&5
20423 echo "$as_me: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" >&2;}
20424    { (exit 1); exit 1; }; }
20425                 fi
20426             fi
20427
20428             # then check for a private Tk library
20429             case "${host}" in
20430                 *-*-cygwin*) platDir="win" ;;
20431                 *) platDir="unix" ;;
20432             esac
20433             if test x"${ac_cv_c_tkconfig}" = x ; then
20434                 for i in \
20435                         ../tk \
20436                         `ls -dr ../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
20437                         `ls -dr ../tk[8-9].[0-9] 2>/dev/null` \
20438                         `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
20439                         ../../tk \
20440                         `ls -dr ../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
20441                         `ls -dr ../../tk[8-9].[0-9] 2>/dev/null` \
20442                         `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
20443                         ../../../tk \
20444                         `ls -dr ../../../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
20445                         `ls -dr ../../../tk[8-9].[0-9] 2>/dev/null` \
20446                         `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
20447                     if test -f "$i/$platDir/tkConfig.sh" ; then
20448                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
20449                         break
20450                     fi
20451                 done
20452             fi
20453
20454             # on Darwin, check in Framework installation locations
20455             if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
20456                 for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
20457                         `ls -d /Library/Frameworks 2>/dev/null` \
20458                         `ls -d /Network/Library/Frameworks 2>/dev/null` \
20459                         `ls -d /System/Library/Frameworks 2>/dev/null` \
20460                         ; do
20461                     if test -f "$i/Tk.framework/tkConfig.sh" ; then
20462                         ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
20463                         break
20464                     fi
20465                 done
20466             fi
20467
20468             # check in a few common install locations
20469             if test x"${ac_cv_c_tkconfig}" = x ; then
20470                 for i in `ls -d ${libdir} 2>/dev/null` \
20471                         `ls -d ${exec_prefix}/lib 2>/dev/null` \
20472                         `ls -d ${prefix}/lib 2>/dev/null` \
20473                         `ls -d /usr/local/lib 2>/dev/null` \
20474                         `ls -d /usr/contrib/lib 2>/dev/null` \
20475                         `ls -d /usr/lib 2>/dev/null` \
20476                         ; do
20477                     if test -f "$i/tkConfig.sh" ; then
20478                         ac_cv_c_tkconfig=`(cd $i; pwd)`
20479                         break
20480                     fi
20481                 done
20482             fi
20483             # check in a few other private locations
20484             if test x"${ac_cv_c_tkconfig}" = x ; then
20485                 for i in \
20486                         ${srcdir}/../tk \
20487                         `ls -dr ${srcdir}/../tk[8-9].[0-9].[0-9]* 2>/dev/null` \
20488                         `ls -dr ${srcdir}/../tk[8-9].[0-9] 2>/dev/null` \
20489                         `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
20490                     if test -f "$i/$platDir/tkConfig.sh" ; then
20491                         ac_cv_c_tkconfig=`(cd $i/$platDir; pwd)`
20492                         break
20493                     fi
20494                 done
20495             fi
20496
20497 fi
20498
20499
20500         if test x"${ac_cv_c_tkconfig}" = x ; then
20501             TK_BIN_DIR="# no Tk configs found"
20502             { echo "$as_me:$LINENO: WARNING: Can't find Tk configuration definitions" >&5
20503 echo "$as_me: WARNING: Can't find Tk configuration definitions" >&2;}
20504         else
20505             no_tk=
20506             TK_BIN_DIR=${ac_cv_c_tkconfig}
20507             echo "$as_me:$LINENO: result: found ${TK_BIN_DIR}/tkConfig.sh" >&5
20508 echo "${ECHO_T}found ${TK_BIN_DIR}/tkConfig.sh" >&6
20509         fi
20510     fi
20511
20512
20513     if test -z "${no_tcl}" -a -z "${no_tk}"; then
20514
20515     echo "$as_me:$LINENO: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
20516 echo $ECHO_N "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... $ECHO_C" >&6
20517
20518     if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
20519         echo "$as_me:$LINENO: result: loading" >&5
20520 echo "${ECHO_T}loading" >&6
20521         . ${TCL_BIN_DIR}/tclConfig.sh
20522     else
20523         echo "$as_me:$LINENO: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
20524 echo "${ECHO_T}could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6
20525     fi
20526
20527     # eval is required to do the TCL_DBGX substitution
20528     eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
20529     eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
20530
20531     # If the TCL_BIN_DIR is the build directory (not the install directory),
20532     # then set the common variable name to the value of the build variables.
20533     # For example, the variable TCL_LIB_SPEC will be set to the value
20534     # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
20535     # instead of TCL_BUILD_LIB_SPEC since it will work with both an
20536     # installed and uninstalled version of Tcl.
20537     if test -f "${TCL_BIN_DIR}/Makefile" ; then
20538         TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
20539         TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
20540         TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
20541     elif test "`uname -s`" = "Darwin"; then
20542         # If Tcl was built as a framework, attempt to use the libraries
20543         # from the framework at the given location so that linking works
20544         # against Tcl.framework installed in an arbitary location.
20545         case ${TCL_DEFS} in
20546             *TCL_FRAMEWORK*)
20547                 if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
20548                     for i in "`cd ${TCL_BIN_DIR}; pwd`" \
20549                              "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
20550                         if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
20551                             TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
20552                             break
20553                         fi
20554                     done
20555                 fi
20556                 if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
20557                     TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
20558                     TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
20559                 fi
20560                 ;;
20561         esac
20562     fi
20563
20564     # eval is required to do the TCL_DBGX substitution
20565     eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
20566     eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
20567     eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
20568     eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
20569
20570
20571
20572
20573
20574
20575
20576
20577
20578
20579
20580
20581
20582
20583
20584         # Check for in-tree tcl
20585         here=`pwd`
20586         cd ${srcdir}/..
20587         topdir=`pwd`
20588         cd ${here}
20589
20590         intree="no"
20591         if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
20592           intree="yes"
20593         fi
20594
20595         # Find Tcl private headers
20596         if test x"${intree}" = xno; then
20597
20598   echo "$as_me:$LINENO: checking for Tcl private headers" >&5
20599 echo $ECHO_N "checking for Tcl private headers... $ECHO_C" >&6
20600   private_dir=""
20601   dir=`echo ${TCL_INCLUDE_SPEC}/tcl-private/generic | sed -e s/-I//`
20602   if test -f ${dir}/tclInt.h ; then
20603     private_dir=${dir}
20604   fi
20605
20606   if test x"${private_dir}" = x; then
20607     { { echo "$as_me:$LINENO: error: could not find private Tcl headers" >&5
20608 echo "$as_me: error: could not find private Tcl headers" >&2;}
20609    { (exit 1); exit 1; }; }
20610   else
20611     TCL_PRIVATE_INCLUDE="-I${private_dir}"
20612     echo "$as_me:$LINENO: result: ${private_dir}" >&5
20613 echo "${ECHO_T}${private_dir}" >&6
20614   fi
20615
20616           TCL_INCLUDE="${TCL_INCLUDE_SPEC} ${TCL_PRIVATE_INCLUDE}"
20617           TCL_LIBRARY="${TCL_LIB_SPEC}"
20618           TCL_DEPS=""
20619         else
20620           # If building tcl in the same src tree, private headers
20621           # are not needed, but we need to be sure to use the right
20622           # headers library
20623           TCL_INCLUDE="-I${TCL_SRC_DIR}/generic"
20624           TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
20625           TCL_DEPS="../tcl/${configdir}${TCL_LIB_FILE}"
20626         fi
20627
20628
20629
20630
20631
20632     echo "$as_me:$LINENO: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
20633 echo $ECHO_N "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... $ECHO_C" >&6
20634
20635     if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
20636         echo "$as_me:$LINENO: result: loading" >&5
20637 echo "${ECHO_T}loading" >&6
20638         . ${TK_BIN_DIR}/tkConfig.sh
20639     else
20640         echo "$as_me:$LINENO: result: could not find ${TK_BIN_DIR}/tkConfig.sh" >&5
20641 echo "${ECHO_T}could not find ${TK_BIN_DIR}/tkConfig.sh" >&6
20642     fi
20643
20644     # eval is required to do the TK_DBGX substitution
20645     eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
20646     eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
20647
20648     # If the TK_BIN_DIR is the build directory (not the install directory),
20649     # then set the common variable name to the value of the build variables.
20650     # For example, the variable TK_LIB_SPEC will be set to the value
20651     # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
20652     # instead of TK_BUILD_LIB_SPEC since it will work with both an
20653     # installed and uninstalled version of Tcl.
20654     if test -f "${TK_BIN_DIR}/Makefile" ; then
20655         TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
20656         TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
20657         TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
20658     elif test "`uname -s`" = "Darwin"; then
20659         # If Tk was built as a framework, attempt to use the libraries
20660         # from the framework at the given location so that linking works
20661         # against Tk.framework installed in an arbitary location.
20662         case ${TK_DEFS} in
20663             *TK_FRAMEWORK*)
20664                 if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
20665                     for i in "`cd ${TK_BIN_DIR}; pwd`" \
20666                              "`cd ${TK_BIN_DIR}/../..; pwd`"; do
20667                         if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
20668                             TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
20669                             break
20670                         fi
20671                     done
20672                 fi
20673                 if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
20674                     TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
20675                     TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
20676                 fi
20677                 ;;
20678         esac
20679     fi
20680
20681     # eval is required to do the TK_DBGX substitution
20682     eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
20683     eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
20684     eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
20685     eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
20686
20687
20688
20689
20690
20691
20692
20693
20694
20695
20696
20697
20698
20699
20700         # Check for in-tree Tk
20701         intree="no"
20702         if test "${TK_SRC_DIR}" = "${topdir}/tk"; then
20703           intree="yes"
20704         fi
20705
20706         # Find Tk private headers
20707         if test x"${intree}" = xno; then
20708
20709   echo "$as_me:$LINENO: checking for Tk private headers" >&5
20710 echo $ECHO_N "checking for Tk private headers... $ECHO_C" >&6
20711   private_dir=""
20712   dir=`echo ${TK_INCLUDE_SPEC}/tk-private/generic | sed -e s/-I//`
20713   if test -f ${dir}/tkInt.h; then
20714     private_dir=${dir}
20715   fi
20716
20717   if test x"${private_dir}" = x; then
20718     { { echo "$as_me:$LINENO: error: could not find Tk private headers" >&5
20719 echo "$as_me: error: could not find Tk private headers" >&2;}
20720    { (exit 1); exit 1; }; }
20721   else
20722     TK_PRIVATE_INCLUDE="-I${private_dir}"
20723     echo "$as_me:$LINENO: result: ${private_dir}" >&5
20724 echo "${ECHO_T}${private_dir}" >&6
20725   fi
20726
20727           TK_INCLUDE="${TK_INCLUDE_SPEC} ${TK_PRIVATE_INCLUDE}"
20728           TK_LIBRARY=${TK_LIB_SPEC}
20729           TK_DEPS=""
20730         else
20731           TK_INCLUDE="-I${TK_SRC_DIR}/generic"
20732           TK_LIBRARY="${TK_BUILD_LIB_SPEC}"
20733           TK_DEPS="../tk/${configdir}/${TK_LIB_FILE}"
20734         fi
20735
20736
20737
20738
20739
20740         ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
20741
20742         # Include some libraries that Tcl and Tk want.
20743         TCL_LIBS='$(LIBGUI) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
20744         # Yes, the ordering seems wrong here.  But it isn't.
20745         # TK_LIBS is the list of libraries that need to be linked
20746         # after Tcl/Tk.  Note that this isn't put into LIBS.  If it
20747         # were in LIBS then any link tests after this point would
20748         # try to include things like `$(LIBGUI)', which wouldn't work.
20749         GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
20750
20751         CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
20752         CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
20753         CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
20754         CONFIG_ALL="${CONFIG_ALL} all-gdbtk"
20755         CONFIG_CLEAN="${CONFIG_CLEAN} clean-gdbtk"
20756         CONFIG_INSTALL="${CONFIG_INSTALL} install-gdbtk"
20757         CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-gdbtk"
20758
20759         if test x$gdb_cv_os_cygwin = xyes; then
20760           WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
20761           WIN32LDAPP="-Wl,--subsystem,console"
20762           CONFIG_OBS="${CONFIG_OBS} gdbres.o"
20763         fi
20764
20765
20766
20767 subdirs="$subdirs gdbtk"
20768
20769     fi
20770 fi
20771
20772
20773
20774
20775
20776
20777
20778
20779 echo "$as_me:$LINENO: checking for X" >&5
20780 echo $ECHO_N "checking for X... $ECHO_C" >&6
20781
20782
20783 # Check whether --with-x or --without-x was given.
20784 if test "${with_x+set}" = set; then
20785   withval="$with_x"
20786
20787 fi;
20788 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
20789 if test "x$with_x" = xno; then
20790   # The user explicitly disabled X.
20791   have_x=disabled
20792 else
20793   if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
20794     # Both variables are already set.
20795     have_x=yes
20796   else
20797     if test "${ac_cv_have_x+set}" = set; then
20798   echo $ECHO_N "(cached) $ECHO_C" >&6
20799 else
20800   # One or both of the vars are not set, and there is no cached value.
20801 ac_x_includes=no ac_x_libraries=no
20802 rm -fr conftest.dir
20803 if mkdir conftest.dir; then
20804   cd conftest.dir
20805   # Make sure to not put "make" in the Imakefile rules, since we grep it out.
20806   cat >Imakefile <<'_ACEOF'
20807 acfindx:
20808         @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
20809 _ACEOF
20810   if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
20811     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
20812     eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
20813     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
20814     for ac_extension in a so sl; do
20815       if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
20816          test -f $ac_im_libdir/libX11.$ac_extension; then
20817         ac_im_usrlibdir=$ac_im_libdir; break
20818       fi
20819     done
20820     # Screen out bogus values from the imake configuration.  They are
20821     # bogus both because they are the default anyway, and because
20822     # using them would break gcc on systems where it needs fixed includes.
20823     case $ac_im_incroot in
20824         /usr/include) ;;
20825         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
20826     esac
20827     case $ac_im_usrlibdir in
20828         /usr/lib | /lib) ;;
20829         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
20830     esac
20831   fi
20832   cd ..
20833   rm -fr conftest.dir
20834 fi
20835
20836 # Standard set of common directories for X headers.
20837 # Check X11 before X11Rn because it is often a symlink to the current release.
20838 ac_x_header_dirs='
20839 /usr/X11/include
20840 /usr/X11R6/include
20841 /usr/X11R5/include
20842 /usr/X11R4/include
20843
20844 /usr/include/X11
20845 /usr/include/X11R6
20846 /usr/include/X11R5
20847 /usr/include/X11R4
20848
20849 /usr/local/X11/include
20850 /usr/local/X11R6/include
20851 /usr/local/X11R5/include
20852 /usr/local/X11R4/include
20853
20854 /usr/local/include/X11
20855 /usr/local/include/X11R6
20856 /usr/local/include/X11R5
20857 /usr/local/include/X11R4
20858
20859 /usr/X386/include
20860 /usr/x386/include
20861 /usr/XFree86/include/X11
20862
20863 /usr/include
20864 /usr/local/include
20865 /usr/unsupported/include
20866 /usr/athena/include
20867 /usr/local/x11r5/include
20868 /usr/lpp/Xamples/include
20869
20870 /usr/openwin/include
20871 /usr/openwin/share/include'
20872
20873 if test "$ac_x_includes" = no; then
20874   # Guess where to find include files, by looking for Intrinsic.h.
20875   # First, try using that file with no special directory specified.
20876   cat >conftest.$ac_ext <<_ACEOF
20877 /* confdefs.h.  */
20878 _ACEOF
20879 cat confdefs.h >>conftest.$ac_ext
20880 cat >>conftest.$ac_ext <<_ACEOF
20881 /* end confdefs.h.  */
20882 #include <X11/Intrinsic.h>
20883 _ACEOF
20884 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20885   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20886   ac_status=$?
20887   grep -v '^ *+' conftest.er1 >conftest.err
20888   rm -f conftest.er1
20889   cat conftest.err >&5
20890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20891   (exit $ac_status); } >/dev/null; then
20892   if test -s conftest.err; then
20893     ac_cpp_err=$ac_c_preproc_warn_flag
20894     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
20895   else
20896     ac_cpp_err=
20897   fi
20898 else
20899   ac_cpp_err=yes
20900 fi
20901 if test -z "$ac_cpp_err"; then
20902   # We can compile using X headers with no special include directory.
20903 ac_x_includes=
20904 else
20905   echo "$as_me: failed program was:" >&5
20906 sed 's/^/| /' conftest.$ac_ext >&5
20907
20908   for ac_dir in $ac_x_header_dirs; do
20909   if test -r "$ac_dir/X11/Intrinsic.h"; then
20910     ac_x_includes=$ac_dir
20911     break
20912   fi
20913 done
20914 fi
20915 rm -f conftest.err conftest.$ac_ext
20916 fi # $ac_x_includes = no
20917
20918 if test "$ac_x_libraries" = no; then
20919   # Check for the libraries.
20920   # See if we find them without any special options.
20921   # Don't add to $LIBS permanently.
20922   ac_save_LIBS=$LIBS
20923   LIBS="-lXt $LIBS"
20924   cat >conftest.$ac_ext <<_ACEOF
20925 /* confdefs.h.  */
20926 _ACEOF
20927 cat confdefs.h >>conftest.$ac_ext
20928 cat >>conftest.$ac_ext <<_ACEOF
20929 /* end confdefs.h.  */
20930 #include <X11/Intrinsic.h>
20931 int
20932 main ()
20933 {
20934 XtMalloc (0)
20935   ;
20936   return 0;
20937 }
20938 _ACEOF
20939 rm -f conftest.$ac_objext conftest$ac_exeext
20940 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20941   (eval $ac_link) 2>conftest.er1
20942   ac_status=$?
20943   grep -v '^ *+' conftest.er1 >conftest.err
20944   rm -f conftest.er1
20945   cat conftest.err >&5
20946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20947   (exit $ac_status); } &&
20948          { ac_try='test -z "$ac_c_werror_flag"
20949                          || test ! -s conftest.err'
20950   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20951   (eval $ac_try) 2>&5
20952   ac_status=$?
20953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20954   (exit $ac_status); }; } &&
20955          { ac_try='test -s conftest$ac_exeext'
20956   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20957   (eval $ac_try) 2>&5
20958   ac_status=$?
20959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20960   (exit $ac_status); }; }; then
20961   LIBS=$ac_save_LIBS
20962 # We can link X programs with no special library path.
20963 ac_x_libraries=
20964 else
20965   echo "$as_me: failed program was:" >&5
20966 sed 's/^/| /' conftest.$ac_ext >&5
20967
20968 LIBS=$ac_save_LIBS
20969 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
20970 do
20971   # Don't even attempt the hair of trying to link an X program!
20972   for ac_extension in a so sl; do
20973     if test -r $ac_dir/libXt.$ac_extension; then
20974       ac_x_libraries=$ac_dir
20975       break 2
20976     fi
20977   done
20978 done
20979 fi
20980 rm -f conftest.err conftest.$ac_objext \
20981       conftest$ac_exeext conftest.$ac_ext
20982 fi # $ac_x_libraries = no
20983
20984 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
20985   # Didn't find X anywhere.  Cache the known absence of X.
20986   ac_cv_have_x="have_x=no"
20987 else
20988   # Record where we found X for the cache.
20989   ac_cv_have_x="have_x=yes \
20990                 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
20991 fi
20992 fi
20993
20994   fi
20995   eval "$ac_cv_have_x"
20996 fi # $with_x != no
20997
20998 if test "$have_x" != yes; then
20999   echo "$as_me:$LINENO: result: $have_x" >&5
21000 echo "${ECHO_T}$have_x" >&6
21001   no_x=yes
21002 else
21003   # If each of the values was on the command line, it overrides each guess.
21004   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
21005   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
21006   # Update the cache value to reflect the command line values.
21007   ac_cv_have_x="have_x=yes \
21008                 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
21009   echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
21010 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
21011 fi
21012
21013
21014 # Unlike the sim directory, whether a simulator is linked is controlled by
21015 # presence of a gdb_sim definition in the target configure.tgt entry.
21016 # This code just checks for a few cases where we'd like to ignore those
21017 # definitions, even when they're present in the '.mt' file.  These cases
21018 # are when --disable-sim is specified, or if the simulator directory is
21019 # not part of the source tree.
21020 #
21021 # Check whether --enable-sim or --disable-sim was given.
21022 if test "${enable_sim+set}" = set; then
21023   enableval="$enable_sim"
21024   echo "enable_sim = $enable_sim";
21025  echo "enableval = ${enableval}";
21026  case "${enableval}" in
21027   yes) ignore_sim=false ;;
21028   no)  ignore_sim=true ;;
21029   *)   ignore_sim=false ;;
21030  esac
21031 else
21032   ignore_sim=false
21033 fi;
21034
21035 if test ! -d "${srcdir}/../sim"; then
21036   ignore_sim=true
21037 fi
21038
21039 SIM=
21040 SIM_OBS=
21041 if test "${ignore_sim}" = "false"; then
21042   if test x"${gdb_sim}" != x ; then
21043     SIM="${gdb_sim}"
21044     SIM_OBS="remote-sim.o"
21045
21046 cat >>confdefs.h <<\_ACEOF
21047 #define WITH_SIM 1
21048 _ACEOF
21049
21050   fi
21051 fi
21052
21053
21054
21055
21056
21057
21058
21059
21060
21061
21062
21063
21064
21065
21066 # List of host floatformats.
21067
21068 cat >>confdefs.h <<_ACEOF
21069 #define GDB_HOST_FLOAT_FORMAT $gdb_host_float_format
21070 _ACEOF
21071
21072
21073 cat >>confdefs.h <<_ACEOF
21074 #define GDB_HOST_DOUBLE_FORMAT $gdb_host_double_format
21075 _ACEOF
21076
21077
21078 cat >>confdefs.h <<_ACEOF
21079 #define GDB_HOST_LONG_DOUBLE_FORMAT $gdb_host_long_double_format
21080 _ACEOF
21081
21082
21083 # target_subdir is used by the testsuite to find the target libraries.
21084 target_subdir=
21085 if test "${host}" != "${target}"; then
21086     target_subdir="${target_alias}/"
21087 fi
21088
21089
21090 frags=
21091 if test "${gdb_native}" = "yes"; then
21092   host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
21093   if test ! -f ${host_makefile_frag}; then
21094     { { echo "$as_me:$LINENO: error: \"*** Gdb does not support native target ${host}\"" >&5
21095 echo "$as_me: error: \"*** Gdb does not support native target ${host}\"" >&2;}
21096    { (exit 1); exit 1; }; }
21097   fi
21098   frags="$frags $host_makefile_frag"
21099 else
21100   host_makefile_frag=/dev/null
21101 fi
21102
21103
21104
21105
21106 if test "${gdb_native}" = "yes"; then
21107 # We pick this up from the host configuration file (.mh) because we
21108 # do not have a native configuration Makefile fragment.
21109 nativefile=`sed -n '
21110 s/NAT_FILE[     ]*=[    ]*\([^  ]*\)/\1/p
21111 ' ${host_makefile_frag}`
21112 fi
21113
21114
21115 if test x"${gdb_osabi}" != x ; then
21116
21117 cat >>confdefs.h <<_ACEOF
21118 #define GDB_OSABI_DEFAULT $gdb_osabi
21119 _ACEOF
21120
21121 fi
21122
21123 # Enable multi-ice-gdb-server.
21124 # Check whether --enable-multi-ice or --disable-multi-ice was given.
21125 if test "${enable_multi_ice+set}" = set; then
21126   enableval="$enable_multi_ice"
21127   case $enableval in
21128     yes | no)
21129       ;;
21130     *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-multi-ice" >&5
21131 echo "$as_me: error: bad value $enableval for --enable-multi-ice" >&2;}
21132    { (exit 1); exit 1; }; } ;;
21133   esac
21134 fi;
21135 if test "x$enable_multi_ice" = xyes; then
21136
21137
21138 subdirs="$subdirs multi-ice"
21139
21140 fi
21141
21142 # We only build gdbserver automatically in a native configuration.
21143 if test "$gdb_native" = "yes"; then
21144   echo "$as_me:$LINENO: checking whether gdbserver is supported on this host" >&5
21145 echo $ECHO_N "checking whether gdbserver is supported on this host... $ECHO_C" >&6
21146   if test "x$build_gdbserver" = xyes; then
21147     echo "$as_me:$LINENO: result: yes" >&5
21148 echo "${ECHO_T}yes" >&6
21149
21150
21151 subdirs="$subdirs gdbserver"
21152
21153   else
21154     echo "$as_me:$LINENO: result: no" >&5
21155 echo "${ECHO_T}no" >&6
21156   fi
21157 fi
21158
21159 # If nativefile (NAT_FILE) is not set in config/*/*.m[ht] files, we link
21160 # to an empty version.
21161
21162 files=
21163 links=
21164
21165 rm -f nm.h
21166 nm_h=""
21167 if test "${nativefile}" != ""; then
21168     nm_h=nm.h
21169     case "${nativefile}" in
21170       nm-*.h ) GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}" ;;
21171       * ) GDB_NM_FILE="${nativefile}"
21172     esac
21173     files="${files} ${GDB_NM_FILE}"
21174     links="${links} nm.h"
21175
21176 cat >>confdefs.h <<_ACEOF
21177 #define GDB_NM_FILE "${GDB_NM_FILE}"
21178 _ACEOF
21179
21180 fi
21181
21182
21183 ac_sources="$files"
21184 ac_dests="$links"
21185 while test -n "$ac_sources"; do
21186   set $ac_dests; ac_dest=$1; shift; ac_dests=$*
21187   set $ac_sources; ac_source=$1; shift; ac_sources=$*
21188   ac_config_links_1="$ac_config_links_1 $ac_dest:$ac_source"
21189 done
21190           ac_config_links="$ac_config_links $ac_config_links_1"
21191
21192
21193
21194
21195
21196 cat >>confdefs.h <<\_ACEOF
21197 #define GDB_DEFAULT_HOST_CHARSET "UTF-8"
21198 _ACEOF
21199
21200
21201
21202
21203
21204
21205
21206                               ac_config_files="$ac_config_files Makefile .gdbinit:gdbinit.in gnulib/Makefile"
21207           ac_config_commands="$ac_config_commands default"
21208 cat >confcache <<\_ACEOF
21209 # This file is a shell script that caches the results of configure
21210 # tests run on this system so they can be shared between configure
21211 # scripts and configure runs, see configure's option --config-cache.
21212 # It is not useful on other systems.  If it contains results you don't
21213 # want to keep, you may remove or edit it.
21214 #
21215 # config.status only pays attention to the cache file if you give it
21216 # the --recheck option to rerun configure.
21217 #
21218 # `ac_cv_env_foo' variables (set or unset) will be overridden when
21219 # loading this file, other *unset* `ac_cv_foo' will be assigned the
21220 # following values.
21221
21222 _ACEOF
21223
21224 # The following way of writing the cache mishandles newlines in values,
21225 # but we know of no workaround that is simple, portable, and efficient.
21226 # So, don't put newlines in cache variables' values.
21227 # Ultrix sh set writes to stderr and can't be redirected directly,
21228 # and sets the high bit in the cache file unless we assign to the vars.
21229 {
21230   (set) 2>&1 |
21231     case `(ac_space=' '; set | grep ac_space) 2>&1` in
21232     *ac_space=\ *)
21233       # `set' does not quote correctly, so add quotes (double-quote
21234       # substitution turns \\\\ into \\, and sed turns \\ into \).
21235       sed -n \
21236         "s/'/'\\\\''/g;
21237           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
21238       ;;
21239     *)
21240       # `set' quotes correctly as required by POSIX, so do not add quotes.
21241       sed -n \
21242         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
21243       ;;
21244     esac;
21245 } |
21246   sed '
21247      t clear
21248      : clear
21249      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21250      t end
21251      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21252      : end' >>confcache
21253 if diff $cache_file confcache >/dev/null 2>&1; then :; else
21254   if test -w $cache_file; then
21255     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
21256     cat confcache >$cache_file
21257   else
21258     echo "not updating unwritable cache $cache_file"
21259   fi
21260 fi
21261 rm -f confcache
21262
21263 test "x$prefix" = xNONE && prefix=$ac_default_prefix
21264 # Let make expand exec_prefix.
21265 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21266
21267 # VPATH may cause trouble with some makes, so we remove $(srcdir),
21268 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
21269 # trailing colons and then remove the whole line if VPATH becomes empty
21270 # (actually we leave an empty line to preserve line numbers).
21271 if test "x$srcdir" = x.; then
21272   ac_vpsub='/^[  ]*VPATH[        ]*=/{
21273 s/:*\$(srcdir):*/:/;
21274 s/:*\${srcdir}:*/:/;
21275 s/:*@srcdir@:*/:/;
21276 s/^\([^=]*=[     ]*\):*/\1/;
21277 s/:*$//;
21278 s/^[^=]*=[       ]*$//;
21279 }'
21280 fi
21281
21282 DEFS=-DHAVE_CONFIG_H
21283
21284 ac_libobjs=
21285 ac_ltlibobjs=
21286 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21287   # 1. Remove the extension, and $U if already installed.
21288   ac_i=`echo "$ac_i" |
21289          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
21290   # 2. Add them.
21291   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
21292   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
21293 done
21294 LIBOBJS=$ac_libobjs
21295
21296 LTLIBOBJS=$ac_ltlibobjs
21297
21298
21299 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
21300   { { echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
21301 Usually this means the macro was only invoked conditionally." >&5
21302 echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
21303 Usually this means the macro was only invoked conditionally." >&2;}
21304    { (exit 1); exit 1; }; }
21305 fi
21306 if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
21307   { { echo "$as_me:$LINENO: error: conditional \"GMAKE\" was never defined.
21308 Usually this means the macro was only invoked conditionally." >&5
21309 echo "$as_me: error: conditional \"GMAKE\" was never defined.
21310 Usually this means the macro was only invoked conditionally." >&2;}
21311    { (exit 1); exit 1; }; }
21312 fi
21313 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
21314   { { echo "$as_me:$LINENO: error: conditional \"GL_COND_LIBTOOL\" was never defined.
21315 Usually this means the macro was only invoked conditionally." >&5
21316 echo "$as_me: error: conditional \"GL_COND_LIBTOOL\" was never defined.
21317 Usually this means the macro was only invoked conditionally." >&2;}
21318    { (exit 1); exit 1; }; }
21319 fi
21320
21321     gl_libobjs=
21322     gl_ltlibobjs=
21323     if test -n "$gl_LIBOBJS"; then
21324       # Remove the extension.
21325       sed_drop_objext='s/\.o$//;s/\.obj$//'
21326       for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed "$sed_drop_objext" | sort | uniq`; do
21327         gl_libobjs="$gl_libobjs $i.$ac_objext"
21328         gl_ltlibobjs="$gl_ltlibobjs $i.lo"
21329       done
21330     fi
21331     gl_LIBOBJS=$gl_libobjs
21332
21333     gl_LTLIBOBJS=$gl_ltlibobjs
21334
21335
21336
21337     gltests_libobjs=
21338     gltests_ltlibobjs=
21339     if test -n "$gltests_LIBOBJS"; then
21340       # Remove the extension.
21341       sed_drop_objext='s/\.o$//;s/\.obj$//'
21342       for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed "$sed_drop_objext" | sort | uniq`; do
21343         gltests_libobjs="$gltests_libobjs $i.$ac_objext"
21344         gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
21345       done
21346     fi
21347     gltests_LIBOBJS=$gltests_libobjs
21348
21349     gltests_LTLIBOBJS=$gltests_ltlibobjs
21350
21351
21352 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
21353   { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
21354 Usually this means the macro was only invoked conditionally." >&5
21355 echo "$as_me: error: conditional \"AMDEP\" was never defined.
21356 Usually this means the macro was only invoked conditionally." >&2;}
21357    { (exit 1); exit 1; }; }
21358 fi
21359 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
21360   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
21361 Usually this means the macro was only invoked conditionally." >&5
21362 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
21363 Usually this means the macro was only invoked conditionally." >&2;}
21364    { (exit 1); exit 1; }; }
21365 fi
21366
21367 : ${CONFIG_STATUS=./config.status}
21368 ac_clean_files_save=$ac_clean_files
21369 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
21370 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
21371 echo "$as_me: creating $CONFIG_STATUS" >&6;}
21372 cat >$CONFIG_STATUS <<_ACEOF
21373 #! $SHELL
21374 # Generated by $as_me.
21375 # Run this file to recreate the current configuration.
21376 # Compiler output produced by configure, useful for debugging
21377 # configure, is in config.log if it exists.
21378
21379 debug=false
21380 ac_cs_recheck=false
21381 ac_cs_silent=false
21382 SHELL=\${CONFIG_SHELL-$SHELL}
21383 _ACEOF
21384
21385 cat >>$CONFIG_STATUS <<\_ACEOF
21386 ## --------------------- ##
21387 ## M4sh Initialization.  ##
21388 ## --------------------- ##
21389
21390 # Be Bourne compatible
21391 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
21392   emulate sh
21393   NULLCMD=:
21394   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21395   # is contrary to our usage.  Disable this feature.
21396   alias -g '${1+"$@"}'='"$@"'
21397 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21398   set -o posix
21399 fi
21400 DUALCASE=1; export DUALCASE # for MKS sh
21401
21402 # Support unset when possible.
21403 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
21404   as_unset=unset
21405 else
21406   as_unset=false
21407 fi
21408
21409
21410 # Work around bugs in pre-3.0 UWIN ksh.
21411 $as_unset ENV MAIL MAILPATH
21412 PS1='$ '
21413 PS2='> '
21414 PS4='+ '
21415
21416 # NLS nuisances.
21417 for as_var in \
21418   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
21419   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
21420   LC_TELEPHONE LC_TIME
21421 do
21422   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
21423     eval $as_var=C; export $as_var
21424   else
21425     $as_unset $as_var
21426   fi
21427 done
21428
21429 # Required to use basename.
21430 if expr a : '\(a\)' >/dev/null 2>&1; then
21431   as_expr=expr
21432 else
21433   as_expr=false
21434 fi
21435
21436 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
21437   as_basename=basename
21438 else
21439   as_basename=false
21440 fi
21441
21442
21443 # Name of the executable.
21444 as_me=`$as_basename "$0" ||
21445 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21446          X"$0" : 'X\(//\)$' \| \
21447          X"$0" : 'X\(/\)$' \| \
21448          .     : '\(.\)' 2>/dev/null ||
21449 echo X/"$0" |
21450     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
21451           /^X\/\(\/\/\)$/{ s//\1/; q; }
21452           /^X\/\(\/\).*/{ s//\1/; q; }
21453           s/.*/./; q'`
21454
21455
21456 # PATH needs CR, and LINENO needs CR and PATH.
21457 # Avoid depending upon Character Ranges.
21458 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21459 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21460 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21461 as_cr_digits='0123456789'
21462 as_cr_alnum=$as_cr_Letters$as_cr_digits
21463
21464 # The user is always right.
21465 if test "${PATH_SEPARATOR+set}" != set; then
21466   echo "#! /bin/sh" >conf$$.sh
21467   echo  "exit 0"   >>conf$$.sh
21468   chmod +x conf$$.sh
21469   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
21470     PATH_SEPARATOR=';'
21471   else
21472     PATH_SEPARATOR=:
21473   fi
21474   rm -f conf$$.sh
21475 fi
21476
21477
21478   as_lineno_1=$LINENO
21479   as_lineno_2=$LINENO
21480   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21481   test "x$as_lineno_1" != "x$as_lineno_2" &&
21482   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
21483   # Find who we are.  Look in the path if we contain no path at all
21484   # relative or not.
21485   case $0 in
21486     *[\\/]* ) as_myself=$0 ;;
21487     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21488 for as_dir in $PATH
21489 do
21490   IFS=$as_save_IFS
21491   test -z "$as_dir" && as_dir=.
21492   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21493 done
21494
21495        ;;
21496   esac
21497   # We did not find ourselves, most probably we were run as `sh COMMAND'
21498   # in which case we are not to be found in the path.
21499   if test "x$as_myself" = x; then
21500     as_myself=$0
21501   fi
21502   if test ! -f "$as_myself"; then
21503     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
21504 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
21505    { (exit 1); exit 1; }; }
21506   fi
21507   case $CONFIG_SHELL in
21508   '')
21509     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21510 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
21511 do
21512   IFS=$as_save_IFS
21513   test -z "$as_dir" && as_dir=.
21514   for as_base in sh bash ksh sh5; do
21515          case $as_dir in
21516          /*)
21517            if ("$as_dir/$as_base" -c '
21518   as_lineno_1=$LINENO
21519   as_lineno_2=$LINENO
21520   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21521   test "x$as_lineno_1" != "x$as_lineno_2" &&
21522   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
21523              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
21524              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
21525              CONFIG_SHELL=$as_dir/$as_base
21526              export CONFIG_SHELL
21527              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
21528            fi;;
21529          esac
21530        done
21531 done
21532 ;;
21533   esac
21534
21535   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
21536   # uniformly replaced by the line number.  The first 'sed' inserts a
21537   # line-number line before each line; the second 'sed' does the real
21538   # work.  The second script uses 'N' to pair each line-number line
21539   # with the numbered line, and appends trailing '-' during
21540   # substitution so that $LINENO is not a special case at line end.
21541   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
21542   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
21543   sed '=' <$as_myself |
21544     sed '
21545       N
21546       s,$,-,
21547       : loop
21548       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
21549       t loop
21550       s,-$,,
21551       s,^['$as_cr_digits']*\n,,
21552     ' >$as_me.lineno &&
21553   chmod +x $as_me.lineno ||
21554     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
21555 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
21556    { (exit 1); exit 1; }; }
21557
21558   # Don't try to exec as it changes $[0], causing all sort of problems
21559   # (the dirname of $[0] is not the place where we might find the
21560   # original and so on.  Autoconf is especially sensible to this).
21561   . ./$as_me.lineno
21562   # Exit status is that of the last command.
21563   exit
21564 }
21565
21566
21567 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
21568   *c*,-n*) ECHO_N= ECHO_C='
21569 ' ECHO_T='      ' ;;
21570   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
21571   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
21572 esac
21573
21574 if expr a : '\(a\)' >/dev/null 2>&1; then
21575   as_expr=expr
21576 else
21577   as_expr=false
21578 fi
21579
21580 rm -f conf$$ conf$$.exe conf$$.file
21581 echo >conf$$.file
21582 if ln -s conf$$.file conf$$ 2>/dev/null; then
21583   # We could just check for DJGPP; but this test a) works b) is more generic
21584   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
21585   if test -f conf$$.exe; then
21586     # Don't use ln at all; we don't have any links
21587     as_ln_s='cp -p'
21588   else
21589     as_ln_s='ln -s'
21590   fi
21591 elif ln conf$$.file conf$$ 2>/dev/null; then
21592   as_ln_s=ln
21593 else
21594   as_ln_s='cp -p'
21595 fi
21596 rm -f conf$$ conf$$.exe conf$$.file
21597
21598 if mkdir -p . 2>/dev/null; then
21599   as_mkdir_p=:
21600 else
21601   test -d ./-p && rmdir ./-p
21602   as_mkdir_p=false
21603 fi
21604
21605 as_executable_p="test -f"
21606
21607 # Sed expression to map a string onto a valid CPP name.
21608 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
21609
21610 # Sed expression to map a string onto a valid variable name.
21611 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
21612
21613
21614 # IFS
21615 # We need space, tab and new line, in precisely that order.
21616 as_nl='
21617 '
21618 IFS="   $as_nl"
21619
21620 # CDPATH.
21621 $as_unset CDPATH
21622
21623 exec 6>&1
21624
21625 # Open the log real soon, to keep \$[0] and so on meaningful, and to
21626 # report actual input values of CONFIG_FILES etc. instead of their
21627 # values after options handling.  Logging --version etc. is OK.
21628 exec 5>>config.log
21629 {
21630   echo
21631   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
21632 ## Running $as_me. ##
21633 _ASBOX
21634 } >&5
21635 cat >&5 <<_CSEOF
21636
21637 This file was extended by $as_me, which was
21638 generated by GNU Autoconf 2.59.  Invocation command line was
21639
21640   CONFIG_FILES    = $CONFIG_FILES
21641   CONFIG_HEADERS  = $CONFIG_HEADERS
21642   CONFIG_LINKS    = $CONFIG_LINKS
21643   CONFIG_COMMANDS = $CONFIG_COMMANDS
21644   $ $0 $@
21645
21646 _CSEOF
21647 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
21648 echo >&5
21649 _ACEOF
21650
21651 # Files that config.status was made for.
21652 if test -n "$ac_config_files"; then
21653   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
21654 fi
21655
21656 if test -n "$ac_config_headers"; then
21657   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
21658 fi
21659
21660 if test -n "$ac_config_links"; then
21661   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
21662 fi
21663
21664 if test -n "$ac_config_commands"; then
21665   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
21666 fi
21667
21668 cat >>$CONFIG_STATUS <<\_ACEOF
21669
21670 ac_cs_usage="\
21671 \`$as_me' instantiates files from templates according to the
21672 current configuration.
21673
21674 Usage: $0 [OPTIONS] [FILE]...
21675
21676   -h, --help       print this help, then exit
21677   -V, --version    print version number, then exit
21678   -q, --quiet      do not print progress messages
21679   -d, --debug      don't remove temporary files
21680       --recheck    update $as_me by reconfiguring in the same conditions
21681   --file=FILE[:TEMPLATE]
21682                    instantiate the configuration file FILE
21683   --header=FILE[:TEMPLATE]
21684                    instantiate the configuration header FILE
21685
21686 Configuration files:
21687 $config_files
21688
21689 Configuration headers:
21690 $config_headers
21691
21692 Configuration links:
21693 $config_links
21694
21695 Configuration commands:
21696 $config_commands
21697
21698 Report bugs to <bug-autoconf@gnu.org>."
21699 _ACEOF
21700
21701 cat >>$CONFIG_STATUS <<_ACEOF
21702 ac_cs_version="\\
21703 config.status
21704 configured by $0, generated by GNU Autoconf 2.59,
21705   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
21706
21707 Copyright (C) 2003 Free Software Foundation, Inc.
21708 This config.status script is free software; the Free Software Foundation
21709 gives unlimited permission to copy, distribute and modify it."
21710 srcdir=$srcdir
21711 INSTALL="$INSTALL"
21712 _ACEOF
21713
21714 cat >>$CONFIG_STATUS <<\_ACEOF
21715 # If no file are specified by the user, then we need to provide default
21716 # value.  By we need to know if files were specified by the user.
21717 ac_need_defaults=:
21718 while test $# != 0
21719 do
21720   case $1 in
21721   --*=*)
21722     ac_option=`expr "x$1" : 'x\([^=]*\)='`
21723     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
21724     ac_shift=:
21725     ;;
21726   -*)
21727     ac_option=$1
21728     ac_optarg=$2
21729     ac_shift=shift
21730     ;;
21731   *) # This is not an option, so the user has probably given explicit
21732      # arguments.
21733      ac_option=$1
21734      ac_need_defaults=false;;
21735   esac
21736
21737   case $ac_option in
21738   # Handling of the options.
21739 _ACEOF
21740 cat >>$CONFIG_STATUS <<\_ACEOF
21741   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
21742     ac_cs_recheck=: ;;
21743   --version | --vers* | -V )
21744     echo "$ac_cs_version"; exit 0 ;;
21745   --he | --h)
21746     # Conflict between --help and --header
21747     { { echo "$as_me:$LINENO: error: ambiguous option: $1
21748 Try \`$0 --help' for more information." >&5
21749 echo "$as_me: error: ambiguous option: $1
21750 Try \`$0 --help' for more information." >&2;}
21751    { (exit 1); exit 1; }; };;
21752   --help | --hel | -h )
21753     echo "$ac_cs_usage"; exit 0 ;;
21754   --debug | --d* | -d )
21755     debug=: ;;
21756   --file | --fil | --fi | --f )
21757     $ac_shift
21758     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
21759     ac_need_defaults=false;;
21760   --header | --heade | --head | --hea )
21761     $ac_shift
21762     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
21763     ac_need_defaults=false;;
21764   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
21765   | -silent | --silent | --silen | --sile | --sil | --si | --s)
21766     ac_cs_silent=: ;;
21767
21768   # This is an error.
21769   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
21770 Try \`$0 --help' for more information." >&5
21771 echo "$as_me: error: unrecognized option: $1
21772 Try \`$0 --help' for more information." >&2;}
21773    { (exit 1); exit 1; }; } ;;
21774
21775   *) ac_config_targets="$ac_config_targets $1" ;;
21776
21777   esac
21778   shift
21779 done
21780
21781 ac_configure_extra_args=
21782
21783 if $ac_cs_silent; then
21784   exec 6>/dev/null
21785   ac_configure_extra_args="$ac_configure_extra_args --silent"
21786 fi
21787
21788 _ACEOF
21789 cat >>$CONFIG_STATUS <<_ACEOF
21790 if \$ac_cs_recheck; then
21791   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
21792   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
21793 fi
21794
21795 _ACEOF
21796
21797 cat >>$CONFIG_STATUS <<_ACEOF
21798 #
21799 # INIT-COMMANDS section.
21800 #
21801
21802 ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
21803 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
21804
21805 gdb_host_cpu=$gdb_host_cpu
21806 nativefile=$nativefile
21807
21808
21809 _ACEOF
21810
21811
21812
21813 cat >>$CONFIG_STATUS <<\_ACEOF
21814 for ac_config_target in $ac_config_targets
21815 do
21816   case "$ac_config_target" in
21817   # Handling of arguments.
21818   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
21819   ".gdbinit" ) CONFIG_FILES="$CONFIG_FILES .gdbinit:gdbinit.in" ;;
21820   "gnulib/Makefile" ) CONFIG_FILES="$CONFIG_FILES gnulib/Makefile" ;;
21821   "$ac_config_links_1" ) CONFIG_LINKS="$CONFIG_LINKS $ac_config_links_1" ;;
21822   "depdir" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;;
21823   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
21824   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
21825   "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
21826   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
21827 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
21828    { (exit 1); exit 1; }; };;
21829   esac
21830 done
21831
21832 # If the user did not use the arguments to specify the items to instantiate,
21833 # then the envvar interface is used.  Set only those that are not.
21834 # We use the long form for the default assignment because of an extremely
21835 # bizarre bug on SunOS 4.1.3.
21836 if $ac_need_defaults; then
21837   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
21838   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
21839   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
21840   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
21841 fi
21842
21843 # Have a temporary directory for convenience.  Make it in the build tree
21844 # simply because there is no reason to put it here, and in addition,
21845 # creating and moving files from /tmp can sometimes cause problems.
21846 # Create a temporary directory, and hook for its removal unless debugging.
21847 $debug ||
21848 {
21849   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
21850   trap '{ (exit 1); exit 1; }' 1 2 13 15
21851 }
21852
21853 # Create a (secure) tmp directory for tmp files.
21854
21855 {
21856   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
21857   test -n "$tmp" && test -d "$tmp"
21858 }  ||
21859 {
21860   tmp=./confstat$$-$RANDOM
21861   (umask 077 && mkdir $tmp)
21862 } ||
21863 {
21864    echo "$me: cannot create a temporary directory in ." >&2
21865    { (exit 1); exit 1; }
21866 }
21867
21868 _ACEOF
21869
21870 cat >>$CONFIG_STATUS <<_ACEOF
21871
21872 #
21873 # CONFIG_FILES section.
21874 #
21875
21876 # No need to generate the scripts if there are no CONFIG_FILES.
21877 # This happens for instance when ./config.status config.h
21878 if test -n "\$CONFIG_FILES"; then
21879   # Protect against being on the right side of a sed subst in config.status.
21880   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
21881    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
21882 s,@SHELL@,$SHELL,;t t
21883 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
21884 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
21885 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
21886 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
21887 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
21888 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
21889 s,@exec_prefix@,$exec_prefix,;t t
21890 s,@prefix@,$prefix,;t t
21891 s,@program_transform_name@,$program_transform_name,;t t
21892 s,@bindir@,$bindir,;t t
21893 s,@sbindir@,$sbindir,;t t
21894 s,@libexecdir@,$libexecdir,;t t
21895 s,@datadir@,$datadir,;t t
21896 s,@sysconfdir@,$sysconfdir,;t t
21897 s,@sharedstatedir@,$sharedstatedir,;t t
21898 s,@localstatedir@,$localstatedir,;t t
21899 s,@libdir@,$libdir,;t t
21900 s,@includedir@,$includedir,;t t
21901 s,@oldincludedir@,$oldincludedir,;t t
21902 s,@infodir@,$infodir,;t t
21903 s,@mandir@,$mandir,;t t
21904 s,@build_alias@,$build_alias,;t t
21905 s,@host_alias@,$host_alias,;t t
21906 s,@target_alias@,$target_alias,;t t
21907 s,@DEFS@,$DEFS,;t t
21908 s,@ECHO_C@,$ECHO_C,;t t
21909 s,@ECHO_N@,$ECHO_N,;t t
21910 s,@ECHO_T@,$ECHO_T,;t t
21911 s,@LIBS@,$LIBS,;t t
21912 s,@MAINTAINER_MODE_TRUE@,$MAINTAINER_MODE_TRUE,;t t
21913 s,@MAINTAINER_MODE_FALSE@,$MAINTAINER_MODE_FALSE,;t t
21914 s,@MAINT@,$MAINT,;t t
21915 s,@CC@,$CC,;t t
21916 s,@CFLAGS@,$CFLAGS,;t t
21917 s,@LDFLAGS@,$LDFLAGS,;t t
21918 s,@CPPFLAGS@,$CPPFLAGS,;t t
21919 s,@ac_ct_CC@,$ac_ct_CC,;t t
21920 s,@EXEEXT@,$EXEEXT,;t t
21921 s,@OBJEXT@,$OBJEXT,;t t
21922 s,@CPP@,$CPP,;t t
21923 s,@EGREP@,$EGREP,;t t
21924 s,@RANLIB@,$RANLIB,;t t
21925 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
21926 s,@build@,$build,;t t
21927 s,@build_cpu@,$build_cpu,;t t
21928 s,@build_vendor@,$build_vendor,;t t
21929 s,@build_os@,$build_os,;t t
21930 s,@host@,$host,;t t
21931 s,@host_cpu@,$host_cpu,;t t
21932 s,@host_vendor@,$host_vendor,;t t
21933 s,@host_os@,$host_os,;t t
21934 s,@target@,$target,;t t
21935 s,@target_cpu@,$target_cpu,;t t
21936 s,@target_vendor@,$target_vendor,;t t
21937 s,@target_os@,$target_os,;t t
21938 s,@am__leading_dot@,$am__leading_dot,;t t
21939 s,@DEPDIR@,$DEPDIR,;t t
21940 s,@CCDEPMODE@,$CCDEPMODE,;t t
21941 s,@MAKE@,$MAKE,;t t
21942 s,@GMAKE_TRUE@,$GMAKE_TRUE,;t t
21943 s,@GMAKE_FALSE@,$GMAKE_FALSE,;t t
21944 s,@SET_MAKE@,$SET_MAKE,;t t
21945 s,@USE_NLS@,$USE_NLS,;t t
21946 s,@LIBINTL@,$LIBINTL,;t t
21947 s,@LIBINTL_DEP@,$LIBINTL_DEP,;t t
21948 s,@INCINTL@,$INCINTL,;t t
21949 s,@XGETTEXT@,$XGETTEXT,;t t
21950 s,@GMSGFMT@,$GMSGFMT,;t t
21951 s,@POSUB@,$POSUB,;t t
21952 s,@CATALOGS@,$CATALOGS,;t t
21953 s,@DATADIRNAME@,$DATADIRNAME,;t t
21954 s,@INSTOBJEXT@,$INSTOBJEXT,;t t
21955 s,@GENCAT@,$GENCAT,;t t
21956 s,@CATOBJEXT@,$CATOBJEXT,;t t
21957 s,@localedir@,$localedir,;t t
21958 s,@GL_COND_LIBTOOL_TRUE@,$GL_COND_LIBTOOL_TRUE,;t t
21959 s,@GL_COND_LIBTOOL_FALSE@,$GL_COND_LIBTOOL_FALSE,;t t
21960 s,@GNULIB_MEMMEM@,$GNULIB_MEMMEM,;t t
21961 s,@GNULIB_MEMPCPY@,$GNULIB_MEMPCPY,;t t
21962 s,@GNULIB_MEMRCHR@,$GNULIB_MEMRCHR,;t t
21963 s,@GNULIB_STPCPY@,$GNULIB_STPCPY,;t t
21964 s,@GNULIB_STPNCPY@,$GNULIB_STPNCPY,;t t
21965 s,@GNULIB_STRCHRNUL@,$GNULIB_STRCHRNUL,;t t
21966 s,@GNULIB_STRDUP@,$GNULIB_STRDUP,;t t
21967 s,@GNULIB_STRNDUP@,$GNULIB_STRNDUP,;t t
21968 s,@GNULIB_STRNLEN@,$GNULIB_STRNLEN,;t t
21969 s,@GNULIB_STRPBRK@,$GNULIB_STRPBRK,;t t
21970 s,@GNULIB_STRSEP@,$GNULIB_STRSEP,;t t
21971 s,@GNULIB_STRSTR@,$GNULIB_STRSTR,;t t
21972 s,@GNULIB_STRCASESTR@,$GNULIB_STRCASESTR,;t t
21973 s,@GNULIB_STRTOK_R@,$GNULIB_STRTOK_R,;t t
21974 s,@GNULIB_MBSLEN@,$GNULIB_MBSLEN,;t t
21975 s,@GNULIB_MBSNLEN@,$GNULIB_MBSNLEN,;t t
21976 s,@GNULIB_MBSCHR@,$GNULIB_MBSCHR,;t t
21977 s,@GNULIB_MBSRCHR@,$GNULIB_MBSRCHR,;t t
21978 s,@GNULIB_MBSSTR@,$GNULIB_MBSSTR,;t t
21979 s,@GNULIB_MBSCASECMP@,$GNULIB_MBSCASECMP,;t t
21980 s,@GNULIB_MBSNCASECMP@,$GNULIB_MBSNCASECMP,;t t
21981 s,@GNULIB_MBSPCASECMP@,$GNULIB_MBSPCASECMP,;t t
21982 s,@GNULIB_MBSCASESTR@,$GNULIB_MBSCASESTR,;t t
21983 s,@GNULIB_MBSCSPN@,$GNULIB_MBSCSPN,;t t
21984 s,@GNULIB_MBSPBRK@,$GNULIB_MBSPBRK,;t t
21985 s,@GNULIB_MBSSPN@,$GNULIB_MBSSPN,;t t
21986 s,@GNULIB_MBSSEP@,$GNULIB_MBSSEP,;t t
21987 s,@GNULIB_MBSTOK_R@,$GNULIB_MBSTOK_R,;t t
21988 s,@GNULIB_STRERROR@,$GNULIB_STRERROR,;t t
21989 s,@GNULIB_STRSIGNAL@,$GNULIB_STRSIGNAL,;t t
21990 s,@HAVE_DECL_MEMMEM@,$HAVE_DECL_MEMMEM,;t t
21991 s,@HAVE_MEMPCPY@,$HAVE_MEMPCPY,;t t
21992 s,@HAVE_DECL_MEMRCHR@,$HAVE_DECL_MEMRCHR,;t t
21993 s,@HAVE_STPCPY@,$HAVE_STPCPY,;t t
21994 s,@HAVE_STPNCPY@,$HAVE_STPNCPY,;t t
21995 s,@HAVE_STRCHRNUL@,$HAVE_STRCHRNUL,;t t
21996 s,@HAVE_DECL_STRDUP@,$HAVE_DECL_STRDUP,;t t
21997 s,@HAVE_STRNDUP@,$HAVE_STRNDUP,;t t
21998 s,@HAVE_DECL_STRNDUP@,$HAVE_DECL_STRNDUP,;t t
21999 s,@HAVE_DECL_STRNLEN@,$HAVE_DECL_STRNLEN,;t t
22000 s,@HAVE_STRPBRK@,$HAVE_STRPBRK,;t t
22001 s,@HAVE_STRSEP@,$HAVE_STRSEP,;t t
22002 s,@HAVE_STRCASESTR@,$HAVE_STRCASESTR,;t t
22003 s,@HAVE_DECL_STRTOK_R@,$HAVE_DECL_STRTOK_R,;t t
22004 s,@HAVE_DECL_STRERROR@,$HAVE_DECL_STRERROR,;t t
22005 s,@HAVE_DECL_STRSIGNAL@,$HAVE_DECL_STRSIGNAL,;t t
22006 s,@REPLACE_STRERROR@,$REPLACE_STRERROR,;t t
22007 s,@REPLACE_STRSIGNAL@,$REPLACE_STRSIGNAL,;t t
22008 s,@REPLACE_MEMMEM@,$REPLACE_MEMMEM,;t t
22009 s,@REPLACE_STRCASESTR@,$REPLACE_STRCASESTR,;t t
22010 s,@REPLACE_STRSTR@,$REPLACE_STRSTR,;t t
22011 s,@HAVE_LONG_LONG_INT@,$HAVE_LONG_LONG_INT,;t t
22012 s,@HAVE_UNSIGNED_LONG_LONG_INT@,$HAVE_UNSIGNED_LONG_LONG_INT,;t t
22013 s,@HAVE_INTTYPES_H@,$HAVE_INTTYPES_H,;t t
22014 s,@HAVE_SYS_TYPES_H@,$HAVE_SYS_TYPES_H,;t t
22015 s,@INCLUDE_NEXT@,$INCLUDE_NEXT,;t t
22016 s,@NEXT_STDINT_H@,$NEXT_STDINT_H,;t t
22017 s,@HAVE_STDINT_H@,$HAVE_STDINT_H,;t t
22018 s,@HAVE_SYS_INTTYPES_H@,$HAVE_SYS_INTTYPES_H,;t t
22019 s,@HAVE_SYS_BITYPES_H@,$HAVE_SYS_BITYPES_H,;t t
22020 s,@BITSIZEOF_PTRDIFF_T@,$BITSIZEOF_PTRDIFF_T,;t t
22021 s,@BITSIZEOF_SIG_ATOMIC_T@,$BITSIZEOF_SIG_ATOMIC_T,;t t
22022 s,@BITSIZEOF_SIZE_T@,$BITSIZEOF_SIZE_T,;t t
22023 s,@BITSIZEOF_WCHAR_T@,$BITSIZEOF_WCHAR_T,;t t
22024 s,@BITSIZEOF_WINT_T@,$BITSIZEOF_WINT_T,;t t
22025 s,@HAVE_SIGNED_SIG_ATOMIC_T@,$HAVE_SIGNED_SIG_ATOMIC_T,;t t
22026 s,@HAVE_SIGNED_WCHAR_T@,$HAVE_SIGNED_WCHAR_T,;t t
22027 s,@HAVE_SIGNED_WINT_T@,$HAVE_SIGNED_WINT_T,;t t
22028 s,@PTRDIFF_T_SUFFIX@,$PTRDIFF_T_SUFFIX,;t t
22029 s,@SIG_ATOMIC_T_SUFFIX@,$SIG_ATOMIC_T_SUFFIX,;t t
22030 s,@SIZE_T_SUFFIX@,$SIZE_T_SUFFIX,;t t
22031 s,@WCHAR_T_SUFFIX@,$WCHAR_T_SUFFIX,;t t
22032 s,@WINT_T_SUFFIX@,$WINT_T_SUFFIX,;t t
22033 s,@STDINT_H@,$STDINT_H,;t t
22034 s,@NEXT_STRING_H@,$NEXT_STRING_H,;t t
22035 s,@GNULIB_WCWIDTH@,$GNULIB_WCWIDTH,;t t
22036 s,@HAVE_DECL_WCWIDTH@,$HAVE_DECL_WCWIDTH,;t t
22037 s,@REPLACE_WCWIDTH@,$REPLACE_WCWIDTH,;t t
22038 s,@WCHAR_H@,$WCHAR_H,;t t
22039 s,@HAVE_WCHAR_H@,$HAVE_WCHAR_H,;t t
22040 s,@NEXT_WCHAR_H@,$NEXT_WCHAR_H,;t t
22041 s,@LIBGNU_LIBDEPS@,$LIBGNU_LIBDEPS,;t t
22042 s,@LIBGNU_LTLIBDEPS@,$LIBGNU_LTLIBDEPS,;t t
22043 s,@GNULIB_STDINT_H@,$GNULIB_STDINT_H,;t t
22044 s,@PACKAGE@,$PACKAGE,;t t
22045 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
22046 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
22047 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
22048 s,@CYGPATH_W@,$CYGPATH_W,;t t
22049 s,@PYTHON2_4@,$PYTHON2_4,;t t
22050 s,@ACLOCAL@,$ACLOCAL,;t t
22051 s,@AUTOCONF@,$AUTOCONF,;t t
22052 s,@AUTOMAKE@,$AUTOMAKE,;t t
22053 s,@AUTOHEADER@,$AUTOHEADER,;t t
22054 s,@MAKEINFO@,$MAKEINFO,;t t
22055 s,@install_sh@,$install_sh,;t t
22056 s,@STRIP@,$STRIP,;t t
22057 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
22058 s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
22059 s,@mkdir_p@,$mkdir_p,;t t
22060 s,@AWK@,$AWK,;t t
22061 s,@AMTAR@,$AMTAR,;t t
22062 s,@am__tar@,$am__tar,;t t
22063 s,@am__untar@,$am__untar,;t t
22064 s,@am__include@,$am__include,;t t
22065 s,@am__quote@,$am__quote,;t t
22066 s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t
22067 s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t
22068 s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
22069 s,@am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
22070 s,@am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
22071 s,@subdirs@,$subdirs,;t t
22072 s,@TARGET_OBS@,$TARGET_OBS,;t t
22073 s,@PKGVERSION@,$PKGVERSION,;t t
22074 s,@REPORT_BUGS_TO@,$REPORT_BUGS_TO,;t t
22075 s,@REPORT_BUGS_TEXI@,$REPORT_BUGS_TEXI,;t t
22076 s,@LN_S@,$LN_S,;t t
22077 s,@YACC@,$YACC,;t t
22078 s,@AR@,$AR,;t t
22079 s,@ac_ct_AR@,$ac_ct_AR,;t t
22080 s,@DLLTOOL@,$DLLTOOL,;t t
22081 s,@ac_ct_DLLTOOL@,$ac_ct_DLLTOOL,;t t
22082 s,@WINDRES@,$WINDRES,;t t
22083 s,@ac_ct_WINDRES@,$ac_ct_WINDRES,;t t
22084 s,@MIG@,$MIG,;t t
22085 s,@ac_ct_MIG@,$ac_ct_MIG,;t t
22086 s,@READLINE@,$READLINE,;t t
22087 s,@READLINE_DEPS@,$READLINE_DEPS,;t t
22088 s,@READLINE_CFLAGS@,$READLINE_CFLAGS,;t t
22089 s,@HAVE_LIBEXPAT@,$HAVE_LIBEXPAT,;t t
22090 s,@LIBEXPAT@,$LIBEXPAT,;t t
22091 s,@LTLIBEXPAT@,$LTLIBEXPAT,;t t
22092 s,@PYTHON_CFLAGS@,$PYTHON_CFLAGS,;t t
22093 s,@ALLOCA@,$ALLOCA,;t t
22094 s,@CONFIG_LDFLAGS@,$CONFIG_LDFLAGS,;t t
22095 s,@TARGET_SYSTEM_ROOT@,$TARGET_SYSTEM_ROOT,;t t
22096 s,@TARGET_SYSTEM_ROOT_DEFINE@,$TARGET_SYSTEM_ROOT_DEFINE,;t t
22097 s,@WARN_CFLAGS@,$WARN_CFLAGS,;t t
22098 s,@WERROR_CFLAGS@,$WERROR_CFLAGS,;t t
22099 s,@SER_HARDWIRE@,$SER_HARDWIRE,;t t
22100 s,@WIN32LIBS@,$WIN32LIBS,;t t
22101 s,@LIBGUI@,$LIBGUI,;t t
22102 s,@GUI_CFLAGS_X@,$GUI_CFLAGS_X,;t t
22103 s,@WIN32LDAPP@,$WIN32LDAPP,;t t
22104 s,@TCL_VERSION@,$TCL_VERSION,;t t
22105 s,@TCL_PATCH_LEVEL@,$TCL_PATCH_LEVEL,;t t
22106 s,@TCL_BIN_DIR@,$TCL_BIN_DIR,;t t
22107 s,@TCL_SRC_DIR@,$TCL_SRC_DIR,;t t
22108 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
22109 s,@TCL_LIB_FLAG@,$TCL_LIB_FLAG,;t t
22110 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
22111 s,@TCL_STUB_LIB_FILE@,$TCL_STUB_LIB_FILE,;t t
22112 s,@TCL_STUB_LIB_FLAG@,$TCL_STUB_LIB_FLAG,;t t
22113 s,@TCL_STUB_LIB_SPEC@,$TCL_STUB_LIB_SPEC,;t t
22114 s,@TCL_INCLUDE@,$TCL_INCLUDE,;t t
22115 s,@TCL_LIBRARY@,$TCL_LIBRARY,;t t
22116 s,@TCL_DEPS@,$TCL_DEPS,;t t
22117 s,@TK_VERSION@,$TK_VERSION,;t t
22118 s,@TK_BIN_DIR@,$TK_BIN_DIR,;t t
22119 s,@TK_SRC_DIR@,$TK_SRC_DIR,;t t
22120 s,@TK_LIB_FILE@,$TK_LIB_FILE,;t t
22121 s,@TK_LIB_FLAG@,$TK_LIB_FLAG,;t t
22122 s,@TK_LIB_SPEC@,$TK_LIB_SPEC,;t t
22123 s,@TK_STUB_LIB_FILE@,$TK_STUB_LIB_FILE,;t t
22124 s,@TK_STUB_LIB_FLAG@,$TK_STUB_LIB_FLAG,;t t
22125 s,@TK_STUB_LIB_SPEC@,$TK_STUB_LIB_SPEC,;t t
22126 s,@TK_INCLUDE@,$TK_INCLUDE,;t t
22127 s,@TK_LIBRARY@,$TK_LIBRARY,;t t
22128 s,@TK_DEPS@,$TK_DEPS,;t t
22129 s,@TK_XINCLUDES@,$TK_XINCLUDES,;t t
22130 s,@X_CFLAGS@,$X_CFLAGS,;t t
22131 s,@X_LDFLAGS@,$X_LDFLAGS,;t t
22132 s,@X_LIBS@,$X_LIBS,;t t
22133 s,@GDBTKLIBS@,$GDBTKLIBS,;t t
22134 s,@GDBTK_CFLAGS@,$GDBTK_CFLAGS,;t t
22135 s,@GDBTK_SRC_DIR@,$GDBTK_SRC_DIR,;t t
22136 s,@SIM@,$SIM,;t t
22137 s,@SIM_OBS@,$SIM_OBS,;t t
22138 s,@ENABLE_CFLAGS@,$ENABLE_CFLAGS,;t t
22139 s,@PROFILE_CFLAGS@,$PROFILE_CFLAGS,;t t
22140 s,@CONFIG_OBS@,$CONFIG_OBS,;t t
22141 s,@CONFIG_DEPS@,$CONFIG_DEPS,;t t
22142 s,@CONFIG_SRCS@,$CONFIG_SRCS,;t t
22143 s,@CONFIG_ALL@,$CONFIG_ALL,;t t
22144 s,@CONFIG_CLEAN@,$CONFIG_CLEAN,;t t
22145 s,@CONFIG_INSTALL@,$CONFIG_INSTALL,;t t
22146 s,@CONFIG_UNINSTALL@,$CONFIG_UNINSTALL,;t t
22147 s,@target_subdir@,$target_subdir,;t t
22148 s,@frags@,$frags,;t t
22149 s,@nm_h@,$nm_h,;t t
22150 s,@datarootdir@,$datarootdir,;t t
22151 s,@docdir@,$docdir,;t t
22152 s,@htmldir@,$htmldir,;t t
22153 s,@pdfdir@,$pdfdir,;t t
22154 s,@LIBOBJS@,$LIBOBJS,;t t
22155 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
22156 s,@gl_LIBOBJS@,$gl_LIBOBJS,;t t
22157 s,@gl_LTLIBOBJS@,$gl_LTLIBOBJS,;t t
22158 s,@gltests_LIBOBJS@,$gltests_LIBOBJS,;t t
22159 s,@gltests_LTLIBOBJS@,$gltests_LTLIBOBJS,;t t
22160 /@host_makefile_frag@/r $host_makefile_frag
22161 s,@host_makefile_frag@,,;t t
22162 CEOF
22163
22164 _ACEOF
22165
22166   cat >>$CONFIG_STATUS <<\_ACEOF
22167   # Split the substitutions into bite-sized pieces for seds with
22168   # small command number limits, like on Digital OSF/1 and HP-UX.
22169   ac_max_sed_lines=48
22170   ac_sed_frag=1 # Number of current file.
22171   ac_beg=1 # First line for current file.
22172   ac_end=$ac_max_sed_lines # Line after last line for current file.
22173   ac_more_lines=:
22174   ac_sed_cmds=
22175   while $ac_more_lines; do
22176     if test $ac_beg -gt 1; then
22177       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22178     else
22179       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22180     fi
22181     if test ! -s $tmp/subs.frag; then
22182       ac_more_lines=false
22183     else
22184       # The purpose of the label and of the branching condition is to
22185       # speed up the sed processing (if there are no `@' at all, there
22186       # is no need to browse any of the substitutions).
22187       # These are the two extra sed commands mentioned above.
22188       (echo ':t
22189   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22190       if test -z "$ac_sed_cmds"; then
22191         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
22192       else
22193         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
22194       fi
22195       ac_sed_frag=`expr $ac_sed_frag + 1`
22196       ac_beg=$ac_end
22197       ac_end=`expr $ac_end + $ac_max_sed_lines`
22198     fi
22199   done
22200   if test -z "$ac_sed_cmds"; then
22201     ac_sed_cmds=cat
22202   fi
22203 fi # test -n "$CONFIG_FILES"
22204
22205 _ACEOF
22206 cat >>$CONFIG_STATUS <<\_ACEOF
22207 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
22208   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
22209   case $ac_file in
22210   - | *:- | *:-:* ) # input from stdin
22211         cat >$tmp/stdin
22212         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22213         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22214   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22215         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22216   * )   ac_file_in=$ac_file.in ;;
22217   esac
22218
22219   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
22220   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22221 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22222          X"$ac_file" : 'X\(//\)[^/]' \| \
22223          X"$ac_file" : 'X\(//\)$' \| \
22224          X"$ac_file" : 'X\(/\)' \| \
22225          .     : '\(.\)' 2>/dev/null ||
22226 echo X"$ac_file" |
22227     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22228           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22229           /^X\(\/\/\)$/{ s//\1/; q; }
22230           /^X\(\/\).*/{ s//\1/; q; }
22231           s/.*/./; q'`
22232   { if $as_mkdir_p; then
22233     mkdir -p "$ac_dir"
22234   else
22235     as_dir="$ac_dir"
22236     as_dirs=
22237     while test ! -d "$as_dir"; do
22238       as_dirs="$as_dir $as_dirs"
22239       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22240 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22241          X"$as_dir" : 'X\(//\)[^/]' \| \
22242          X"$as_dir" : 'X\(//\)$' \| \
22243          X"$as_dir" : 'X\(/\)' \| \
22244          .     : '\(.\)' 2>/dev/null ||
22245 echo X"$as_dir" |
22246     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22247           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22248           /^X\(\/\/\)$/{ s//\1/; q; }
22249           /^X\(\/\).*/{ s//\1/; q; }
22250           s/.*/./; q'`
22251     done
22252     test ! -n "$as_dirs" || mkdir $as_dirs
22253   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22254 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22255    { (exit 1); exit 1; }; }; }
22256
22257   ac_builddir=.
22258
22259 if test "$ac_dir" != .; then
22260   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22261   # A "../" for each directory in $ac_dir_suffix.
22262   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22263 else
22264   ac_dir_suffix= ac_top_builddir=
22265 fi
22266
22267 case $srcdir in
22268   .)  # No --srcdir option.  We are building in place.
22269     ac_srcdir=.
22270     if test -z "$ac_top_builddir"; then
22271        ac_top_srcdir=.
22272     else
22273        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22274     fi ;;
22275   [\\/]* | ?:[\\/]* )  # Absolute path.
22276     ac_srcdir=$srcdir$ac_dir_suffix;
22277     ac_top_srcdir=$srcdir ;;
22278   *) # Relative path.
22279     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22280     ac_top_srcdir=$ac_top_builddir$srcdir ;;
22281 esac
22282
22283 # Do not use `cd foo && pwd` to compute absolute paths, because
22284 # the directories may not exist.
22285 case `pwd` in
22286 .) ac_abs_builddir="$ac_dir";;
22287 *)
22288   case "$ac_dir" in
22289   .) ac_abs_builddir=`pwd`;;
22290   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22291   *) ac_abs_builddir=`pwd`/"$ac_dir";;
22292   esac;;
22293 esac
22294 case $ac_abs_builddir in
22295 .) ac_abs_top_builddir=${ac_top_builddir}.;;
22296 *)
22297   case ${ac_top_builddir}. in
22298   .) ac_abs_top_builddir=$ac_abs_builddir;;
22299   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22300   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22301   esac;;
22302 esac
22303 case $ac_abs_builddir in
22304 .) ac_abs_srcdir=$ac_srcdir;;
22305 *)
22306   case $ac_srcdir in
22307   .) ac_abs_srcdir=$ac_abs_builddir;;
22308   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22309   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22310   esac;;
22311 esac
22312 case $ac_abs_builddir in
22313 .) ac_abs_top_srcdir=$ac_top_srcdir;;
22314 *)
22315   case $ac_top_srcdir in
22316   .) ac_abs_top_srcdir=$ac_abs_builddir;;
22317   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22318   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22319   esac;;
22320 esac
22321
22322
22323   case $INSTALL in
22324   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
22325   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
22326   esac
22327
22328   if test x"$ac_file" != x-; then
22329     { echo "$as_me:$LINENO: creating $ac_file" >&5
22330 echo "$as_me: creating $ac_file" >&6;}
22331     rm -f "$ac_file"
22332   fi
22333   # Let's still pretend it is `configure' which instantiates (i.e., don't
22334   # use $as_me), people would be surprised to read:
22335   #    /* config.h.  Generated by config.status.  */
22336   if test x"$ac_file" = x-; then
22337     configure_input=
22338   else
22339     configure_input="$ac_file.  "
22340   fi
22341   configure_input=$configure_input"Generated from `echo $ac_file_in |
22342                                      sed 's,.*/,,'` by configure."
22343
22344   # First look for the input files in the build tree, otherwise in the
22345   # src tree.
22346   ac_file_inputs=`IFS=:
22347     for f in $ac_file_in; do
22348       case $f in
22349       -) echo $tmp/stdin ;;
22350       [\\/$]*)
22351          # Absolute (can't be DOS-style, as IFS=:)
22352          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
22353 echo "$as_me: error: cannot find input file: $f" >&2;}
22354    { (exit 1); exit 1; }; }
22355          echo "$f";;
22356       *) # Relative
22357          if test -f "$f"; then
22358            # Build tree
22359            echo "$f"
22360          elif test -f "$srcdir/$f"; then
22361            # Source tree
22362            echo "$srcdir/$f"
22363          else
22364            # /dev/null tree
22365            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
22366 echo "$as_me: error: cannot find input file: $f" >&2;}
22367    { (exit 1); exit 1; }; }
22368          fi;;
22369       esac
22370     done` || { (exit 1); exit 1; }
22371 _ACEOF
22372 cat >>$CONFIG_STATUS <<_ACEOF
22373   sed "$ac_vpsub
22374 $extrasub
22375 _ACEOF
22376 cat >>$CONFIG_STATUS <<\_ACEOF
22377 :t
22378 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22379 s,@configure_input@,$configure_input,;t t
22380 s,@srcdir@,$ac_srcdir,;t t
22381 s,@abs_srcdir@,$ac_abs_srcdir,;t t
22382 s,@top_srcdir@,$ac_top_srcdir,;t t
22383 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
22384 s,@builddir@,$ac_builddir,;t t
22385 s,@abs_builddir@,$ac_abs_builddir,;t t
22386 s,@top_builddir@,$ac_top_builddir,;t t
22387 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
22388 s,@INSTALL@,$ac_INSTALL,;t t
22389 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
22390   rm -f $tmp/stdin
22391   if test x"$ac_file" != x-; then
22392     mv $tmp/out $ac_file
22393   else
22394     cat $tmp/out
22395     rm -f $tmp/out
22396   fi
22397
22398 done
22399 _ACEOF
22400 cat >>$CONFIG_STATUS <<\_ACEOF
22401
22402 #
22403 # CONFIG_HEADER section.
22404 #
22405
22406 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
22407 # NAME is the cpp macro being defined and VALUE is the value it is being given.
22408 #
22409 # ac_d sets the value in "#define NAME VALUE" lines.
22410 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
22411 ac_dB='[         ].*$,\1#\2'
22412 ac_dC=' '
22413 ac_dD=',;t'
22414 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
22415 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
22416 ac_uB='$,\1#\2define\3'
22417 ac_uC=' '
22418 ac_uD=',;t'
22419
22420 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
22421   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
22422   case $ac_file in
22423   - | *:- | *:-:* ) # input from stdin
22424         cat >$tmp/stdin
22425         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22426         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22427   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22428         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22429   * )   ac_file_in=$ac_file.in ;;
22430   esac
22431
22432   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
22433 echo "$as_me: creating $ac_file" >&6;}
22434
22435   # First look for the input files in the build tree, otherwise in the
22436   # src tree.
22437   ac_file_inputs=`IFS=:
22438     for f in $ac_file_in; do
22439       case $f in
22440       -) echo $tmp/stdin ;;
22441       [\\/$]*)
22442          # Absolute (can't be DOS-style, as IFS=:)
22443          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
22444 echo "$as_me: error: cannot find input file: $f" >&2;}
22445    { (exit 1); exit 1; }; }
22446          # Do quote $f, to prevent DOS paths from being IFS'd.
22447          echo "$f";;
22448       *) # Relative
22449          if test -f "$f"; then
22450            # Build tree
22451            echo "$f"
22452          elif test -f "$srcdir/$f"; then
22453            # Source tree
22454            echo "$srcdir/$f"
22455          else
22456            # /dev/null tree
22457            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
22458 echo "$as_me: error: cannot find input file: $f" >&2;}
22459    { (exit 1); exit 1; }; }
22460          fi;;
22461       esac
22462     done` || { (exit 1); exit 1; }
22463   # Remove the trailing spaces.
22464   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
22465
22466 _ACEOF
22467
22468 # Transform confdefs.h into two sed scripts, `conftest.defines' and
22469 # `conftest.undefs', that substitutes the proper values into
22470 # config.h.in to produce config.h.  The first handles `#define'
22471 # templates, and the second `#undef' templates.
22472 # And first: Protect against being on the right side of a sed subst in
22473 # config.status.  Protect against being in an unquoted here document
22474 # in config.status.
22475 rm -f conftest.defines conftest.undefs
22476 # Using a here document instead of a string reduces the quoting nightmare.
22477 # Putting comments in sed scripts is not portable.
22478 #
22479 # `end' is used to avoid that the second main sed command (meant for
22480 # 0-ary CPP macros) applies to n-ary macro definitions.
22481 # See the Autoconf documentation for `clear'.
22482 cat >confdef2sed.sed <<\_ACEOF
22483 s/[\\&,]/\\&/g
22484 s,[\\$`],\\&,g
22485 t clear
22486 : clear
22487 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
22488 t end
22489 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
22490 : end
22491 _ACEOF
22492 # If some macros were called several times there might be several times
22493 # the same #defines, which is useless.  Nevertheless, we may not want to
22494 # sort them, since we want the *last* AC-DEFINE to be honored.
22495 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
22496 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
22497 rm -f confdef2sed.sed
22498
22499 # This sed command replaces #undef with comments.  This is necessary, for
22500 # example, in the case of _POSIX_SOURCE, which is predefined and required
22501 # on some systems where configure will not decide to define it.
22502 cat >>conftest.undefs <<\_ACEOF
22503 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
22504 _ACEOF
22505
22506 # Break up conftest.defines because some shells have a limit on the size
22507 # of here documents, and old seds have small limits too (100 cmds).
22508 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
22509 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
22510 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
22511 echo '  :' >>$CONFIG_STATUS
22512 rm -f conftest.tail
22513 while grep . conftest.defines >/dev/null
22514 do
22515   # Write a limited-size here document to $tmp/defines.sed.
22516   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
22517   # Speed up: don't consider the non `#define' lines.
22518   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
22519   # Work around the forget-to-reset-the-flag bug.
22520   echo 't clr' >>$CONFIG_STATUS
22521   echo ': clr' >>$CONFIG_STATUS
22522   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
22523   echo 'CEOF
22524   sed -f $tmp/defines.sed $tmp/in >$tmp/out
22525   rm -f $tmp/in
22526   mv $tmp/out $tmp/in
22527 ' >>$CONFIG_STATUS
22528   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
22529   rm -f conftest.defines
22530   mv conftest.tail conftest.defines
22531 done
22532 rm -f conftest.defines
22533 echo '  fi # grep' >>$CONFIG_STATUS
22534 echo >>$CONFIG_STATUS
22535
22536 # Break up conftest.undefs because some shells have a limit on the size
22537 # of here documents, and old seds have small limits too (100 cmds).
22538 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
22539 rm -f conftest.tail
22540 while grep . conftest.undefs >/dev/null
22541 do
22542   # Write a limited-size here document to $tmp/undefs.sed.
22543   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
22544   # Speed up: don't consider the non `#undef'
22545   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
22546   # Work around the forget-to-reset-the-flag bug.
22547   echo 't clr' >>$CONFIG_STATUS
22548   echo ': clr' >>$CONFIG_STATUS
22549   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
22550   echo 'CEOF
22551   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
22552   rm -f $tmp/in
22553   mv $tmp/out $tmp/in
22554 ' >>$CONFIG_STATUS
22555   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
22556   rm -f conftest.undefs
22557   mv conftest.tail conftest.undefs
22558 done
22559 rm -f conftest.undefs
22560
22561 cat >>$CONFIG_STATUS <<\_ACEOF
22562   # Let's still pretend it is `configure' which instantiates (i.e., don't
22563   # use $as_me), people would be surprised to read:
22564   #    /* config.h.  Generated by config.status.  */
22565   if test x"$ac_file" = x-; then
22566     echo "/* Generated by configure.  */" >$tmp/config.h
22567   else
22568     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
22569   fi
22570   cat $tmp/in >>$tmp/config.h
22571   rm -f $tmp/in
22572   if test x"$ac_file" != x-; then
22573     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
22574       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
22575 echo "$as_me: $ac_file is unchanged" >&6;}
22576     else
22577       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22578 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22579          X"$ac_file" : 'X\(//\)[^/]' \| \
22580          X"$ac_file" : 'X\(//\)$' \| \
22581          X"$ac_file" : 'X\(/\)' \| \
22582          .     : '\(.\)' 2>/dev/null ||
22583 echo X"$ac_file" |
22584     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22585           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22586           /^X\(\/\/\)$/{ s//\1/; q; }
22587           /^X\(\/\).*/{ s//\1/; q; }
22588           s/.*/./; q'`
22589       { if $as_mkdir_p; then
22590     mkdir -p "$ac_dir"
22591   else
22592     as_dir="$ac_dir"
22593     as_dirs=
22594     while test ! -d "$as_dir"; do
22595       as_dirs="$as_dir $as_dirs"
22596       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22597 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22598          X"$as_dir" : 'X\(//\)[^/]' \| \
22599          X"$as_dir" : 'X\(//\)$' \| \
22600          X"$as_dir" : 'X\(/\)' \| \
22601          .     : '\(.\)' 2>/dev/null ||
22602 echo X"$as_dir" |
22603     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22604           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22605           /^X\(\/\/\)$/{ s//\1/; q; }
22606           /^X\(\/\).*/{ s//\1/; q; }
22607           s/.*/./; q'`
22608     done
22609     test ! -n "$as_dirs" || mkdir $as_dirs
22610   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22611 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22612    { (exit 1); exit 1; }; }; }
22613
22614       rm -f $ac_file
22615       mv $tmp/config.h $ac_file
22616     fi
22617   else
22618     cat $tmp/config.h
22619     rm -f $tmp/config.h
22620   fi
22621 # Compute $ac_file's index in $config_headers.
22622 _am_stamp_count=1
22623 for _am_header in $config_headers :; do
22624   case $_am_header in
22625     $ac_file | $ac_file:* )
22626       break ;;
22627     * )
22628       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
22629   esac
22630 done
22631 echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
22632 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22633          X$ac_file : 'X\(//\)[^/]' \| \
22634          X$ac_file : 'X\(//\)$' \| \
22635          X$ac_file : 'X\(/\)' \| \
22636          .     : '\(.\)' 2>/dev/null ||
22637 echo X$ac_file |
22638     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22639           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22640           /^X\(\/\/\)$/{ s//\1/; q; }
22641           /^X\(\/\).*/{ s//\1/; q; }
22642           s/.*/./; q'`/stamp-h$_am_stamp_count
22643 done
22644 _ACEOF
22645 cat >>$CONFIG_STATUS <<\_ACEOF
22646
22647 #
22648 # CONFIG_LINKS section.
22649 #
22650
22651 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
22652   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
22653   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
22654
22655   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
22656 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
22657
22658   if test ! -r $srcdir/$ac_source; then
22659     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
22660 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
22661    { (exit 1); exit 1; }; }
22662   fi
22663   rm -f $ac_dest
22664
22665   # Make relative symlinks.
22666   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
22667 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22668          X"$ac_dest" : 'X\(//\)[^/]' \| \
22669          X"$ac_dest" : 'X\(//\)$' \| \
22670          X"$ac_dest" : 'X\(/\)' \| \
22671          .     : '\(.\)' 2>/dev/null ||
22672 echo X"$ac_dest" |
22673     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22674           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22675           /^X\(\/\/\)$/{ s//\1/; q; }
22676           /^X\(\/\).*/{ s//\1/; q; }
22677           s/.*/./; q'`
22678   { if $as_mkdir_p; then
22679     mkdir -p "$ac_dest_dir"
22680   else
22681     as_dir="$ac_dest_dir"
22682     as_dirs=
22683     while test ! -d "$as_dir"; do
22684       as_dirs="$as_dir $as_dirs"
22685       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22686 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22687          X"$as_dir" : 'X\(//\)[^/]' \| \
22688          X"$as_dir" : 'X\(//\)$' \| \
22689          X"$as_dir" : 'X\(/\)' \| \
22690          .     : '\(.\)' 2>/dev/null ||
22691 echo X"$as_dir" |
22692     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22693           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22694           /^X\(\/\/\)$/{ s//\1/; q; }
22695           /^X\(\/\).*/{ s//\1/; q; }
22696           s/.*/./; q'`
22697     done
22698     test ! -n "$as_dirs" || mkdir $as_dirs
22699   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
22700 echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
22701    { (exit 1); exit 1; }; }; }
22702
22703   ac_builddir=.
22704
22705 if test "$ac_dest_dir" != .; then
22706   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
22707   # A "../" for each directory in $ac_dir_suffix.
22708   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22709 else
22710   ac_dir_suffix= ac_top_builddir=
22711 fi
22712
22713 case $srcdir in
22714   .)  # No --srcdir option.  We are building in place.
22715     ac_srcdir=.
22716     if test -z "$ac_top_builddir"; then
22717        ac_top_srcdir=.
22718     else
22719        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22720     fi ;;
22721   [\\/]* | ?:[\\/]* )  # Absolute path.
22722     ac_srcdir=$srcdir$ac_dir_suffix;
22723     ac_top_srcdir=$srcdir ;;
22724   *) # Relative path.
22725     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22726     ac_top_srcdir=$ac_top_builddir$srcdir ;;
22727 esac
22728
22729 # Do not use `cd foo && pwd` to compute absolute paths, because
22730 # the directories may not exist.
22731 case `pwd` in
22732 .) ac_abs_builddir="$ac_dest_dir";;
22733 *)
22734   case "$ac_dest_dir" in
22735   .) ac_abs_builddir=`pwd`;;
22736   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
22737   *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
22738   esac;;
22739 esac
22740 case $ac_abs_builddir in
22741 .) ac_abs_top_builddir=${ac_top_builddir}.;;
22742 *)
22743   case ${ac_top_builddir}. in
22744   .) ac_abs_top_builddir=$ac_abs_builddir;;
22745   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22746   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22747   esac;;
22748 esac
22749 case $ac_abs_builddir in
22750 .) ac_abs_srcdir=$ac_srcdir;;
22751 *)
22752   case $ac_srcdir in
22753   .) ac_abs_srcdir=$ac_abs_builddir;;
22754   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22755   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22756   esac;;
22757 esac
22758 case $ac_abs_builddir in
22759 .) ac_abs_top_srcdir=$ac_top_srcdir;;
22760 *)
22761   case $ac_top_srcdir in
22762   .) ac_abs_top_srcdir=$ac_abs_builddir;;
22763   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22764   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22765   esac;;
22766 esac
22767
22768
22769   case $srcdir in
22770   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
22771       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
22772   esac
22773
22774   # Try a symlink, then a hard link, then a copy.
22775   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
22776     ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
22777     cp -p $srcdir/$ac_source $ac_dest ||
22778     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
22779 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
22780    { (exit 1); exit 1; }; }
22781 done
22782 _ACEOF
22783 cat >>$CONFIG_STATUS <<\_ACEOF
22784
22785 #
22786 # CONFIG_COMMANDS section.
22787 #
22788 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
22789   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
22790   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
22791   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
22792 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22793          X"$ac_dest" : 'X\(//\)[^/]' \| \
22794          X"$ac_dest" : 'X\(//\)$' \| \
22795          X"$ac_dest" : 'X\(/\)' \| \
22796          .     : '\(.\)' 2>/dev/null ||
22797 echo X"$ac_dest" |
22798     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22799           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22800           /^X\(\/\/\)$/{ s//\1/; q; }
22801           /^X\(\/\).*/{ s//\1/; q; }
22802           s/.*/./; q'`
22803   { if $as_mkdir_p; then
22804     mkdir -p "$ac_dir"
22805   else
22806     as_dir="$ac_dir"
22807     as_dirs=
22808     while test ! -d "$as_dir"; do
22809       as_dirs="$as_dir $as_dirs"
22810       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22811 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22812          X"$as_dir" : 'X\(//\)[^/]' \| \
22813          X"$as_dir" : 'X\(//\)$' \| \
22814          X"$as_dir" : 'X\(/\)' \| \
22815          .     : '\(.\)' 2>/dev/null ||
22816 echo X"$as_dir" |
22817     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22818           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22819           /^X\(\/\/\)$/{ s//\1/; q; }
22820           /^X\(\/\).*/{ s//\1/; q; }
22821           s/.*/./; q'`
22822     done
22823     test ! -n "$as_dirs" || mkdir $as_dirs
22824   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22825 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22826    { (exit 1); exit 1; }; }; }
22827
22828   ac_builddir=.
22829
22830 if test "$ac_dir" != .; then
22831   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22832   # A "../" for each directory in $ac_dir_suffix.
22833   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22834 else
22835   ac_dir_suffix= ac_top_builddir=
22836 fi
22837
22838 case $srcdir in
22839   .)  # No --srcdir option.  We are building in place.
22840     ac_srcdir=.
22841     if test -z "$ac_top_builddir"; then
22842        ac_top_srcdir=.
22843     else
22844        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22845     fi ;;
22846   [\\/]* | ?:[\\/]* )  # Absolute path.
22847     ac_srcdir=$srcdir$ac_dir_suffix;
22848     ac_top_srcdir=$srcdir ;;
22849   *) # Relative path.
22850     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22851     ac_top_srcdir=$ac_top_builddir$srcdir ;;
22852 esac
22853
22854 # Do not use `cd foo && pwd` to compute absolute paths, because
22855 # the directories may not exist.
22856 case `pwd` in
22857 .) ac_abs_builddir="$ac_dir";;
22858 *)
22859   case "$ac_dir" in
22860   .) ac_abs_builddir=`pwd`;;
22861   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22862   *) ac_abs_builddir=`pwd`/"$ac_dir";;
22863   esac;;
22864 esac
22865 case $ac_abs_builddir in
22866 .) ac_abs_top_builddir=${ac_top_builddir}.;;
22867 *)
22868   case ${ac_top_builddir}. in
22869   .) ac_abs_top_builddir=$ac_abs_builddir;;
22870   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22871   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22872   esac;;
22873 esac
22874 case $ac_abs_builddir in
22875 .) ac_abs_srcdir=$ac_srcdir;;
22876 *)
22877   case $ac_srcdir in
22878   .) ac_abs_srcdir=$ac_abs_builddir;;
22879   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22880   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22881   esac;;
22882 esac
22883 case $ac_abs_builddir in
22884 .) ac_abs_top_srcdir=$ac_top_srcdir;;
22885 *)
22886   case $ac_top_srcdir in
22887   .) ac_abs_top_srcdir=$ac_abs_builddir;;
22888   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22889   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22890   esac;;
22891 esac
22892
22893
22894   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
22895 echo "$as_me: executing $ac_dest commands" >&6;}
22896   case $ac_dest in
22897     depdir ) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
22898     depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
22899   # Strip MF so we end up with the name of the file.
22900   mf=`echo "$mf" | sed -e 's/:.*$//'`
22901   # Check whether this is an Automake generated Makefile or not.
22902   # We used to match only the files named `Makefile.in', but
22903   # some people rename them; so instead we look at the file content.
22904   # Grep'ing the first line is not enough: some people post-process
22905   # each Makefile.in and add a new line on top of each file to say so.
22906   # So let's grep whole file.
22907   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
22908     dirpart=`(dirname "$mf") 2>/dev/null ||
22909 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22910          X"$mf" : 'X\(//\)[^/]' \| \
22911          X"$mf" : 'X\(//\)$' \| \
22912          X"$mf" : 'X\(/\)' \| \
22913          .     : '\(.\)' 2>/dev/null ||
22914 echo X"$mf" |
22915     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22916           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22917           /^X\(\/\/\)$/{ s//\1/; q; }
22918           /^X\(\/\).*/{ s//\1/; q; }
22919           s/.*/./; q'`
22920   else
22921     continue
22922   fi
22923   # Extract the definition of DEPDIR, am__include, and am__quote
22924   # from the Makefile without running `make'.
22925   DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
22926   test -z "$DEPDIR" && continue
22927   am__include=`sed -n 's/^am__include = //p' < "$mf"`
22928   test -z "am__include" && continue
22929   am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
22930   # When using ansi2knr, U may be empty or an underscore; expand it
22931   U=`sed -n 's/^U = //p' < "$mf"`
22932   # Find all dependency output files, they are included files with
22933   # $(DEPDIR) in their names.  We invoke sed twice because it is the
22934   # simplest approach to changing $(DEPDIR) to its actual value in the
22935   # expansion.
22936   for file in `sed -n "
22937     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
22938        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
22939     # Make sure the directory exists.
22940     test -f "$dirpart/$file" && continue
22941     fdir=`(dirname "$file") 2>/dev/null ||
22942 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22943          X"$file" : 'X\(//\)[^/]' \| \
22944          X"$file" : 'X\(//\)$' \| \
22945          X"$file" : 'X\(/\)' \| \
22946          .     : '\(.\)' 2>/dev/null ||
22947 echo X"$file" |
22948     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22949           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22950           /^X\(\/\/\)$/{ s//\1/; q; }
22951           /^X\(\/\).*/{ s//\1/; q; }
22952           s/.*/./; q'`
22953     { if $as_mkdir_p; then
22954     mkdir -p $dirpart/$fdir
22955   else
22956     as_dir=$dirpart/$fdir
22957     as_dirs=
22958     while test ! -d "$as_dir"; do
22959       as_dirs="$as_dir $as_dirs"
22960       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22961 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22962          X"$as_dir" : 'X\(//\)[^/]' \| \
22963          X"$as_dir" : 'X\(//\)$' \| \
22964          X"$as_dir" : 'X\(/\)' \| \
22965          .     : '\(.\)' 2>/dev/null ||
22966 echo X"$as_dir" |
22967     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22968           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22969           /^X\(\/\/\)$/{ s//\1/; q; }
22970           /^X\(\/\).*/{ s//\1/; q; }
22971           s/.*/./; q'`
22972     done
22973     test ! -n "$as_dirs" || mkdir $as_dirs
22974   fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
22975 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
22976    { (exit 1); exit 1; }; }; }
22977
22978     # echo "creating $dirpart/$file"
22979     echo '# dummy' > "$dirpart/$file"
22980   done
22981 done
22982  ;;
22983     default )
22984
22985 sed -e '/^NAT_FILE[     ]*=/s,^NAT_FILE[        ]*=[    ]*,&config/'"${gdb_host_cpu}"'/,' <Makefile >Makefile.tmp
22986 mv -f Makefile.tmp Makefile
22987
22988
22989 case x$CONFIG_HEADERS in
22990 xconfig.h:config.in)
22991 echo > stamp-h ;;
22992 esac
22993  ;;
22994   esac
22995 done
22996 _ACEOF
22997
22998 cat >>$CONFIG_STATUS <<\_ACEOF
22999
23000 { (exit 0); exit 0; }
23001 _ACEOF
23002 chmod +x $CONFIG_STATUS
23003 ac_clean_files=$ac_clean_files_save
23004
23005
23006 # configure is writing to config.log, and then calls config.status.
23007 # config.status does its own redirection, appending to config.log.
23008 # Unfortunately, on DOS this fails, as config.log is still kept open
23009 # by configure, so config.status won't be able to write to it; its
23010 # output is simply discarded.  So we exec the FD to /dev/null,
23011 # effectively closing config.log, so it can be properly (re)opened and
23012 # appended to by config.status.  When coming back to configure, we
23013 # need to make the FD available again.
23014 if test "$no_create" != yes; then
23015   ac_cs_success=:
23016   ac_config_status_args=
23017   test "$silent" = yes &&
23018     ac_config_status_args="$ac_config_status_args --quiet"
23019   exec 5>/dev/null
23020   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
23021   exec 5>>config.log
23022   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23023   # would make configure fail if this is the last instruction.
23024   $ac_cs_success || { (exit 1); exit 1; }
23025 fi
23026
23027 #
23028 # CONFIG_SUBDIRS section, as fixed in confsubdir.m4.
23029 #
23030 if test "$no_recursion" != yes; then
23031
23032   # Remove --cache-file and --srcdir arguments so they do not pile up.
23033   ac_sub_configure_args=
23034   ac_prev=
23035   eval "set x $ac_configure_args"
23036   shift
23037   for ac_arg
23038   do
23039     if test -n "$ac_prev"; then
23040       ac_prev=
23041       continue
23042     fi
23043     case $ac_arg in
23044     -cache-file | --cache-file | --cache-fil | --cache-fi \
23045     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
23046       ac_prev=cache_file ;;
23047     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
23048     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
23049     | --c=*)
23050       ;;
23051     --config-cache | -C)
23052       ;;
23053     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
23054       ac_prev=srcdir ;;
23055     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
23056       ;;
23057     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
23058       ac_prev=prefix ;;
23059     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
23060       ;;
23061     *)
23062       case $ac_arg in
23063       *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
23064       esac
23065       ac_sub_configure_args="$ac_sub_configure_args '$ac_arg'" ;;
23066     esac
23067   done
23068
23069   # Always prepend --prefix to ensure using the same prefix
23070   # in subdir configurations.
23071   ac_arg="--prefix=$prefix"
23072   case $ac_arg in
23073   *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
23074   esac
23075   ac_sub_configure_args="$ac_arg $ac_sub_configure_args"
23076
23077   ac_popdir=`pwd`
23078   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
23079
23080     # Do not complain, so a configure script can configure whichever
23081     # parts of a large source tree are present.
23082     test -d "$srcdir/$ac_dir" || continue
23083
23084     { echo "$as_me:$LINENO: configuring in $ac_dir" >&5
23085 echo "$as_me: configuring in $ac_dir" >&6;}
23086     { if $as_mkdir_p; then
23087     mkdir -p "$ac_dir"
23088   else
23089     as_dir="$ac_dir"
23090     as_dirs=
23091     while test ! -d "$as_dir"; do
23092       as_dirs="$as_dir $as_dirs"
23093       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23094 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23095          X"$as_dir" : 'X\(//\)[^/]' \| \
23096          X"$as_dir" : 'X\(//\)$' \| \
23097          X"$as_dir" : 'X\(/\)' \| \
23098          .     : '\(.\)' 2>/dev/null ||
23099 echo X"$as_dir" |
23100     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23101           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23102           /^X\(\/\/\)$/{ s//\1/; q; }
23103           /^X\(\/\).*/{ s//\1/; q; }
23104           s/.*/./; q'`
23105     done
23106     test ! -n "$as_dirs" || mkdir $as_dirs
23107   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23108 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23109    { (exit 1); exit 1; }; }; }
23110
23111     ac_builddir=.
23112
23113 if test "$ac_dir" != .; then
23114   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23115   # A "../" for each directory in $ac_dir_suffix.
23116   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23117 else
23118   ac_dir_suffix= ac_top_builddir=
23119 fi
23120
23121 case $srcdir in
23122   .)  # No --srcdir option.  We are building in place.
23123     ac_srcdir=.
23124     if test -z "$ac_top_builddir"; then
23125        ac_top_srcdir=.
23126     else
23127        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23128     fi ;;
23129   [\\/]* | ?:[\\/]* )  # Absolute path.
23130     ac_srcdir=$srcdir$ac_dir_suffix;
23131     ac_top_srcdir=$srcdir ;;
23132   *) # Relative path.
23133     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23134     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23135 esac
23136
23137 # Do not use `cd foo && pwd` to compute absolute paths, because
23138 # the directories may not exist.
23139 case `pwd` in
23140 .) ac_abs_builddir="$ac_dir";;
23141 *)
23142   case "$ac_dir" in
23143   .) ac_abs_builddir=`pwd`;;
23144   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23145   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23146   esac;;
23147 esac
23148 case $ac_abs_builddir in
23149 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23150 *)
23151   case ${ac_top_builddir}. in
23152   .) ac_abs_top_builddir=$ac_abs_builddir;;
23153   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23154   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23155   esac;;
23156 esac
23157 case $ac_abs_builddir in
23158 .) ac_abs_srcdir=$ac_srcdir;;
23159 *)
23160   case $ac_srcdir in
23161   .) ac_abs_srcdir=$ac_abs_builddir;;
23162   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23163   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23164   esac;;
23165 esac
23166 case $ac_abs_builddir in
23167 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23168 *)
23169   case $ac_top_srcdir in
23170   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23171   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23172   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23173   esac;;
23174 esac
23175
23176
23177     cd "$ac_dir"
23178
23179     # Check for guested configure; otherwise get Cygnus style configure.
23180     if test -f "$ac_srcdir/configure.gnu"; then
23181       ac_sub_configure=$ac_srcdir/configure.gnu
23182     elif test -f "$ac_srcdir/configure"; then
23183       ac_sub_configure=$ac_srcdir/configure
23184     elif test -f "$ac_srcdir/configure.in"; then
23185       # This should be Cygnus configure.
23186       ac_sub_configure=$ac_aux_dir/configure
23187     else
23188       { echo "$as_me:$LINENO: WARNING: no configuration information is in $ac_dir" >&5
23189 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
23190       ac_sub_configure=
23191     fi
23192
23193     # The recursion is here.
23194     if test -n "$ac_sub_configure"; then
23195       # Make the cache file name correct relative to the subdirectory.
23196       case $cache_file in
23197       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
23198       *) # Relative path.
23199         ac_sub_cache_file=$ac_top_builddir$cache_file ;;
23200       esac
23201
23202       { echo "$as_me:$LINENO: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
23203 echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
23204       # The eval makes quoting arguments work.
23205       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
23206            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
23207         { { echo "$as_me:$LINENO: error: $ac_sub_configure failed for $ac_dir" >&5
23208 echo "$as_me: error: $ac_sub_configure failed for $ac_dir" >&2;}
23209    { (exit 1); exit 1; }; }
23210     fi
23211
23212     cd "$ac_popdir"
23213   done
23214 fi
23215
23216
23217 exit 0