* configure.in (TARGET_SYSTEM_ROOT): Set default to
[binutils-gdb.git] / gdb / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --enable-maintainer-mode enable make rules and dependencies not useful
16 (and sometimes confusing) to the casual installer"
17 ac_help="$ac_help
18 --disable-nls do not use Native Language Support"
19 ac_help="$ac_help
20 --with-included-gettext use the GNU gettext library included here"
21 ac_help="$ac_help
22 --with-separate-debug-dir=path Look for global separate debug info in this path [LIBDIR/debug]"
23 ac_help="$ac_help
24 --disable-gdbcli disable command-line interface (CLI)"
25 ac_help="$ac_help
26 --disable-gdbmi disable machine-interface (MI)"
27 ac_help="$ac_help
28 --enable-tui enable full-screen terminal user interface (TUI)"
29 ac_help="$ac_help
30 --enable-gdbtk enable gdbtk graphical user interface (GUI)"
31 ac_help="$ac_help
32 --enable-profiling enable profiling of GDB"
33 ac_help="$ac_help
34 --without-included-regex don't use included regex; this is the default
35 on systems with version 2 of the GNU C library
36 (use with caution on other system)"
37 ac_help="$ac_help
38 --with-sysroot[=DIR] Search for usr/lib et al within DIR."
39 ac_help="$ac_help
40 --enable-build-warnings Enable build-time compiler warnings if gcc is used"
41 ac_help="$ac_help
42 --enable-gdb-build-warnings Enable GDB specific build-time compiler warnings if gcc is used"
43 ac_help="$ac_help
44 --with-mmalloc Use memory mapped malloc package"
45 ac_help="$ac_help
46 --with-tclconfig=DIR Directory containing tcl configuration (tclConfig.sh)"
47 ac_help="$ac_help
48 --with-tkconfig=DIR Directory containing tk configuration (tkConfig.sh)"
49 ac_help="$ac_help
50 --with-tclinclude=DIR Directory where tcl private headers are"
51 ac_help="$ac_help
52 --with-tkinclude=DIR Directory where tk private headers are"
53 ac_help="$ac_help
54 --with-itclconfig Directory containing itcl configuration (itclConfig.sh)"
55 ac_help="$ac_help
56 --with-itkconfig Directory containing itk configuration (itkConfig.sh)"
57 ac_help="$ac_help
58 --with-x use the X Window System"
59 ac_help="$ac_help
60 --enable-sim Link gdb with simulator"
61 ac_help="$ac_help
62 --enable-multi-ice build the multi-ice-gdb-server"
63 ac_help="$ac_help
64 --with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib"
65
66 # Initialize some variables set by options.
67 # The variables have the same names as the options, with
68 # dashes changed to underlines.
69 build=NONE
70 cache_file=./config.cache
71 exec_prefix=NONE
72 host=NONE
73 no_create=
74 nonopt=NONE
75 no_recursion=
76 prefix=NONE
77 program_prefix=NONE
78 program_suffix=NONE
79 program_transform_name=s,x,x,
80 silent=
81 site=
82 srcdir=
83 target=NONE
84 verbose=
85 x_includes=NONE
86 x_libraries=NONE
87 bindir='${exec_prefix}/bin'
88 sbindir='${exec_prefix}/sbin'
89 libexecdir='${exec_prefix}/libexec'
90 datadir='${prefix}/share'
91 sysconfdir='${prefix}/etc'
92 sharedstatedir='${prefix}/com'
93 localstatedir='${prefix}/var'
94 libdir='${exec_prefix}/lib'
95 includedir='${prefix}/include'
96 oldincludedir='/usr/include'
97 infodir='${prefix}/info'
98 mandir='${prefix}/man'
99
100 # Initialize some other variables.
101 subdirs=
102 MFLAGS= MAKEFLAGS=
103 SHELL=${CONFIG_SHELL-/bin/sh}
104 # Maximum number of lines to put in a shell here document.
105 ac_max_here_lines=12
106
107 ac_prev=
108 for ac_option
109 do
110
111 # If the previous option needs an argument, assign it.
112 if test -n "$ac_prev"; then
113 eval "$ac_prev=\$ac_option"
114 ac_prev=
115 continue
116 fi
117
118 case "$ac_option" in
119 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
120 *) ac_optarg= ;;
121 esac
122
123 # Accept the important Cygnus configure options, so we can diagnose typos.
124
125 case "$ac_option" in
126
127 -bindir | --bindir | --bindi | --bind | --bin | --bi)
128 ac_prev=bindir ;;
129 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
130 bindir="$ac_optarg" ;;
131
132 -build | --build | --buil | --bui | --bu)
133 ac_prev=build ;;
134 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
135 build="$ac_optarg" ;;
136
137 -cache-file | --cache-file | --cache-fil | --cache-fi \
138 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
139 ac_prev=cache_file ;;
140 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
141 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
142 cache_file="$ac_optarg" ;;
143
144 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
145 ac_prev=datadir ;;
146 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
147 | --da=*)
148 datadir="$ac_optarg" ;;
149
150 -disable-* | --disable-*)
151 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
152 # Reject names that are not valid shell variable names.
153 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
154 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
155 fi
156 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
157 eval "enable_${ac_feature}=no" ;;
158
159 -enable-* | --enable-*)
160 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
161 # Reject names that are not valid shell variable names.
162 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
163 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
164 fi
165 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
166 case "$ac_option" in
167 *=*) ;;
168 *) ac_optarg=yes ;;
169 esac
170 eval "enable_${ac_feature}='$ac_optarg'" ;;
171
172 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
173 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
174 | --exec | --exe | --ex)
175 ac_prev=exec_prefix ;;
176 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
177 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
178 | --exec=* | --exe=* | --ex=*)
179 exec_prefix="$ac_optarg" ;;
180
181 -gas | --gas | --ga | --g)
182 # Obsolete; use --with-gas.
183 with_gas=yes ;;
184
185 -help | --help | --hel | --he)
186 # Omit some internal or obsolete options to make the list less imposing.
187 # This message is too long to be a string in the A/UX 3.1 sh.
188 cat << EOF
189 Usage: configure [options] [host]
190 Options: [defaults in brackets after descriptions]
191 Configuration:
192 --cache-file=FILE cache test results in FILE
193 --help print this message
194 --no-create do not create output files
195 --quiet, --silent do not print \`checking...' messages
196 --version print the version of autoconf that created configure
197 Directory and file names:
198 --prefix=PREFIX install architecture-independent files in PREFIX
199 [$ac_default_prefix]
200 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
201 [same as prefix]
202 --bindir=DIR user executables in DIR [EPREFIX/bin]
203 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
204 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
205 --datadir=DIR read-only architecture-independent data in DIR
206 [PREFIX/share]
207 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
208 --sharedstatedir=DIR modifiable architecture-independent data in DIR
209 [PREFIX/com]
210 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
211 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
212 --includedir=DIR C header files in DIR [PREFIX/include]
213 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
214 --infodir=DIR info documentation in DIR [PREFIX/info]
215 --mandir=DIR man documentation in DIR [PREFIX/man]
216 --srcdir=DIR find the sources in DIR [configure dir or ..]
217 --program-prefix=PREFIX prepend PREFIX to installed program names
218 --program-suffix=SUFFIX append SUFFIX to installed program names
219 --program-transform-name=PROGRAM
220 run sed PROGRAM on installed program names
221 EOF
222 cat << EOF
223 Host type:
224 --build=BUILD configure for building on BUILD [BUILD=HOST]
225 --host=HOST configure for HOST [guessed]
226 --target=TARGET configure for TARGET [TARGET=HOST]
227 Features and packages:
228 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
229 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
230 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
231 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
232 --x-includes=DIR X include files are in DIR
233 --x-libraries=DIR X library files are in DIR
234 EOF
235 if test -n "$ac_help"; then
236 echo "--enable and --with options recognized:$ac_help"
237 fi
238 exit 0 ;;
239
240 -host | --host | --hos | --ho)
241 ac_prev=host ;;
242 -host=* | --host=* | --hos=* | --ho=*)
243 host="$ac_optarg" ;;
244
245 -includedir | --includedir | --includedi | --included | --include \
246 | --includ | --inclu | --incl | --inc)
247 ac_prev=includedir ;;
248 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
249 | --includ=* | --inclu=* | --incl=* | --inc=*)
250 includedir="$ac_optarg" ;;
251
252 -infodir | --infodir | --infodi | --infod | --info | --inf)
253 ac_prev=infodir ;;
254 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
255 infodir="$ac_optarg" ;;
256
257 -libdir | --libdir | --libdi | --libd)
258 ac_prev=libdir ;;
259 -libdir=* | --libdir=* | --libdi=* | --libd=*)
260 libdir="$ac_optarg" ;;
261
262 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
263 | --libexe | --libex | --libe)
264 ac_prev=libexecdir ;;
265 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
266 | --libexe=* | --libex=* | --libe=*)
267 libexecdir="$ac_optarg" ;;
268
269 -localstatedir | --localstatedir | --localstatedi | --localstated \
270 | --localstate | --localstat | --localsta | --localst \
271 | --locals | --local | --loca | --loc | --lo)
272 ac_prev=localstatedir ;;
273 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
274 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
275 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
276 localstatedir="$ac_optarg" ;;
277
278 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
279 ac_prev=mandir ;;
280 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
281 mandir="$ac_optarg" ;;
282
283 -nfp | --nfp | --nf)
284 # Obsolete; use --without-fp.
285 with_fp=no ;;
286
287 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
288 | --no-cr | --no-c)
289 no_create=yes ;;
290
291 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
292 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
293 no_recursion=yes ;;
294
295 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
296 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
297 | --oldin | --oldi | --old | --ol | --o)
298 ac_prev=oldincludedir ;;
299 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
300 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
301 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
302 oldincludedir="$ac_optarg" ;;
303
304 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
305 ac_prev=prefix ;;
306 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
307 prefix="$ac_optarg" ;;
308
309 -program-prefix | --program-prefix | --program-prefi | --program-pref \
310 | --program-pre | --program-pr | --program-p)
311 ac_prev=program_prefix ;;
312 -program-prefix=* | --program-prefix=* | --program-prefi=* \
313 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
314 program_prefix="$ac_optarg" ;;
315
316 -program-suffix | --program-suffix | --program-suffi | --program-suff \
317 | --program-suf | --program-su | --program-s)
318 ac_prev=program_suffix ;;
319 -program-suffix=* | --program-suffix=* | --program-suffi=* \
320 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
321 program_suffix="$ac_optarg" ;;
322
323 -program-transform-name | --program-transform-name \
324 | --program-transform-nam | --program-transform-na \
325 | --program-transform-n | --program-transform- \
326 | --program-transform | --program-transfor \
327 | --program-transfo | --program-transf \
328 | --program-trans | --program-tran \
329 | --progr-tra | --program-tr | --program-t)
330 ac_prev=program_transform_name ;;
331 -program-transform-name=* | --program-transform-name=* \
332 | --program-transform-nam=* | --program-transform-na=* \
333 | --program-transform-n=* | --program-transform-=* \
334 | --program-transform=* | --program-transfor=* \
335 | --program-transfo=* | --program-transf=* \
336 | --program-trans=* | --program-tran=* \
337 | --progr-tra=* | --program-tr=* | --program-t=*)
338 program_transform_name="$ac_optarg" ;;
339
340 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
341 | -silent | --silent | --silen | --sile | --sil)
342 silent=yes ;;
343
344 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
345 ac_prev=sbindir ;;
346 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
347 | --sbi=* | --sb=*)
348 sbindir="$ac_optarg" ;;
349
350 -sharedstatedir | --sharedstatedir | --sharedstatedi \
351 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
352 | --sharedst | --shareds | --shared | --share | --shar \
353 | --sha | --sh)
354 ac_prev=sharedstatedir ;;
355 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
356 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
357 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
358 | --sha=* | --sh=*)
359 sharedstatedir="$ac_optarg" ;;
360
361 -site | --site | --sit)
362 ac_prev=site ;;
363 -site=* | --site=* | --sit=*)
364 site="$ac_optarg" ;;
365
366 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
367 ac_prev=srcdir ;;
368 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
369 srcdir="$ac_optarg" ;;
370
371 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
372 | --syscon | --sysco | --sysc | --sys | --sy)
373 ac_prev=sysconfdir ;;
374 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
375 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
376 sysconfdir="$ac_optarg" ;;
377
378 -target | --target | --targe | --targ | --tar | --ta | --t)
379 ac_prev=target ;;
380 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
381 target="$ac_optarg" ;;
382
383 -v | -verbose | --verbose | --verbos | --verbo | --verb)
384 verbose=yes ;;
385
386 -version | --version | --versio | --versi | --vers)
387 echo "configure generated by autoconf version 2.13"
388 exit 0 ;;
389
390 -with-* | --with-*)
391 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
392 # Reject names that are not valid shell variable names.
393 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
394 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
395 fi
396 ac_package=`echo $ac_package| sed 's/-/_/g'`
397 case "$ac_option" in
398 *=*) ;;
399 *) ac_optarg=yes ;;
400 esac
401 eval "with_${ac_package}='$ac_optarg'" ;;
402
403 -without-* | --without-*)
404 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
405 # Reject names that are not valid shell variable names.
406 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
407 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
408 fi
409 ac_package=`echo $ac_package| sed 's/-/_/g'`
410 eval "with_${ac_package}=no" ;;
411
412 --x)
413 # Obsolete; use --with-x.
414 with_x=yes ;;
415
416 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
417 | --x-incl | --x-inc | --x-in | --x-i)
418 ac_prev=x_includes ;;
419 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
420 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
421 x_includes="$ac_optarg" ;;
422
423 -x-libraries | --x-libraries | --x-librarie | --x-librari \
424 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
425 ac_prev=x_libraries ;;
426 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
427 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
428 x_libraries="$ac_optarg" ;;
429
430 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
431 ;;
432
433 *)
434 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
435 echo "configure: warning: $ac_option: invalid host type" 1>&2
436 fi
437 if test "x$nonopt" != xNONE; then
438 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
439 fi
440 nonopt="$ac_option"
441 ;;
442
443 esac
444 done
445
446 if test -n "$ac_prev"; then
447 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
448 fi
449
450 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
451
452 # File descriptor usage:
453 # 0 standard input
454 # 1 file creation
455 # 2 errors and warnings
456 # 3 some systems may open it to /dev/tty
457 # 4 used on the Kubota Titan
458 # 6 checking for... messages and results
459 # 5 compiler messages saved in config.log
460 if test "$silent" = yes; then
461 exec 6>/dev/null
462 else
463 exec 6>&1
464 fi
465 exec 5>./config.log
466
467 echo "\
468 This file contains any messages produced by compilers while
469 running configure, to aid debugging if configure makes a mistake.
470 " 1>&5
471
472 # Strip out --no-create and --no-recursion so they do not pile up.
473 # Also quote any args containing shell metacharacters.
474 ac_configure_args=
475 for ac_arg
476 do
477 case "$ac_arg" in
478 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
479 | --no-cr | --no-c) ;;
480 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
481 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
482 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
483 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
484 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
485 esac
486 done
487
488 # NLS nuisances.
489 # Only set these to C if already set. These must not be set unconditionally
490 # because not all systems understand e.g. LANG=C (notably SCO).
491 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
492 # Non-C LC_CTYPE values break the ctype check.
493 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
494 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
495 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
496 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
497
498 # confdefs.h avoids OS command line length limits that DEFS can exceed.
499 rm -rf conftest* confdefs.h
500 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
501 echo > confdefs.h
502
503 # A filename unique to this package, relative to the directory that
504 # configure is in, which we can look for to find out if srcdir is correct.
505 ac_unique_file=main.c
506
507 # Find the source files, if location was not specified.
508 if test -z "$srcdir"; then
509 ac_srcdir_defaulted=yes
510 # Try the directory containing this script, then its parent.
511 ac_prog=$0
512 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
513 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
514 srcdir=$ac_confdir
515 if test ! -r $srcdir/$ac_unique_file; then
516 srcdir=..
517 fi
518 else
519 ac_srcdir_defaulted=no
520 fi
521 if test ! -r $srcdir/$ac_unique_file; then
522 if test "$ac_srcdir_defaulted" = yes; then
523 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
524 else
525 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
526 fi
527 fi
528 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
529
530 # Prefer explicitly selected file to automatically selected ones.
531 if test -z "$CONFIG_SITE"; then
532 if test "x$prefix" != xNONE; then
533 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
534 else
535 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
536 fi
537 fi
538 for ac_site_file in $CONFIG_SITE; do
539 if test -r "$ac_site_file"; then
540 echo "loading site script $ac_site_file"
541 . "$ac_site_file"
542 fi
543 done
544
545 if test -r "$cache_file"; then
546 echo "loading cache $cache_file"
547 . $cache_file
548 else
549 echo "creating cache $cache_file"
550 > $cache_file
551 fi
552
553 ac_ext=c
554 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
555 ac_cpp='$CPP $CPPFLAGS'
556 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
557 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
558 cross_compiling=$ac_cv_prog_cc_cross
559
560 ac_exeext=
561 ac_objext=o
562 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
563 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
564 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
565 ac_n= ac_c='
566 ' ac_t=' '
567 else
568 ac_n=-n ac_c= ac_t=
569 fi
570 else
571 ac_n= ac_c='\c' ac_t=
572 fi
573
574
575
576 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
577 echo "configure:578: checking whether to enable maintainer-specific portions of Makefiles" >&5
578 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
579 if test "${enable_maintainer_mode+set}" = set; then
580 enableval="$enable_maintainer_mode"
581 USE_MAINTAINER_MODE=$enableval
582 else
583 USE_MAINTAINER_MODE=no
584 fi
585
586 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
587
588
589 if test $USE_MAINTAINER_MODE = yes; then
590 MAINTAINER_MODE_TRUE=
591 MAINTAINER_MODE_FALSE='#'
592 else
593 MAINTAINER_MODE_TRUE='#'
594 MAINTAINER_MODE_FALSE=
595 fi
596 MAINT=$MAINTAINER_MODE_TRUE
597
598
599
600 # Extract the first word of "gcc", so it can be a program name with args.
601 set dummy gcc; ac_word=$2
602 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
603 echo "configure:604: checking for $ac_word" >&5
604 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
605 echo $ac_n "(cached) $ac_c" 1>&6
606 else
607 if test -n "$CC"; then
608 ac_cv_prog_CC="$CC" # Let the user override the test.
609 else
610 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
611 ac_dummy="$PATH"
612 for ac_dir in $ac_dummy; do
613 test -z "$ac_dir" && ac_dir=.
614 if test -f $ac_dir/$ac_word; then
615 ac_cv_prog_CC="gcc"
616 break
617 fi
618 done
619 IFS="$ac_save_ifs"
620 fi
621 fi
622 CC="$ac_cv_prog_CC"
623 if test -n "$CC"; then
624 echo "$ac_t""$CC" 1>&6
625 else
626 echo "$ac_t""no" 1>&6
627 fi
628
629 if test -z "$CC"; then
630 # Extract the first word of "cc", so it can be a program name with args.
631 set dummy cc; ac_word=$2
632 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
633 echo "configure:634: checking for $ac_word" >&5
634 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
635 echo $ac_n "(cached) $ac_c" 1>&6
636 else
637 if test -n "$CC"; then
638 ac_cv_prog_CC="$CC" # Let the user override the test.
639 else
640 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
641 ac_prog_rejected=no
642 ac_dummy="$PATH"
643 for ac_dir in $ac_dummy; do
644 test -z "$ac_dir" && ac_dir=.
645 if test -f $ac_dir/$ac_word; then
646 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
647 ac_prog_rejected=yes
648 continue
649 fi
650 ac_cv_prog_CC="cc"
651 break
652 fi
653 done
654 IFS="$ac_save_ifs"
655 if test $ac_prog_rejected = yes; then
656 # We found a bogon in the path, so make sure we never use it.
657 set dummy $ac_cv_prog_CC
658 shift
659 if test $# -gt 0; then
660 # We chose a different compiler from the bogus one.
661 # However, it has the same basename, so the bogon will be chosen
662 # first if we set CC to just the basename; use the full file name.
663 shift
664 set dummy "$ac_dir/$ac_word" "$@"
665 shift
666 ac_cv_prog_CC="$@"
667 fi
668 fi
669 fi
670 fi
671 CC="$ac_cv_prog_CC"
672 if test -n "$CC"; then
673 echo "$ac_t""$CC" 1>&6
674 else
675 echo "$ac_t""no" 1>&6
676 fi
677
678 if test -z "$CC"; then
679 case "`uname -s`" in
680 *win32* | *WIN32*)
681 # Extract the first word of "cl", so it can be a program name with args.
682 set dummy cl; ac_word=$2
683 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
684 echo "configure:685: checking for $ac_word" >&5
685 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
686 echo $ac_n "(cached) $ac_c" 1>&6
687 else
688 if test -n "$CC"; then
689 ac_cv_prog_CC="$CC" # Let the user override the test.
690 else
691 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
692 ac_dummy="$PATH"
693 for ac_dir in $ac_dummy; do
694 test -z "$ac_dir" && ac_dir=.
695 if test -f $ac_dir/$ac_word; then
696 ac_cv_prog_CC="cl"
697 break
698 fi
699 done
700 IFS="$ac_save_ifs"
701 fi
702 fi
703 CC="$ac_cv_prog_CC"
704 if test -n "$CC"; then
705 echo "$ac_t""$CC" 1>&6
706 else
707 echo "$ac_t""no" 1>&6
708 fi
709 ;;
710 esac
711 fi
712 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
713 fi
714
715 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
716 echo "configure:717: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
717
718 ac_ext=c
719 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
720 ac_cpp='$CPP $CPPFLAGS'
721 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
722 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
723 cross_compiling=$ac_cv_prog_cc_cross
724
725 cat > conftest.$ac_ext << EOF
726
727 #line 728 "configure"
728 #include "confdefs.h"
729
730 main(){return(0);}
731 EOF
732 if { (eval echo configure:733: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
733 ac_cv_prog_cc_works=yes
734 # If we can't run a trivial program, we are probably using a cross compiler.
735 if (./conftest; exit) 2>/dev/null; then
736 ac_cv_prog_cc_cross=no
737 else
738 ac_cv_prog_cc_cross=yes
739 fi
740 else
741 echo "configure: failed program was:" >&5
742 cat conftest.$ac_ext >&5
743 ac_cv_prog_cc_works=no
744 fi
745 rm -fr conftest*
746 ac_ext=c
747 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
748 ac_cpp='$CPP $CPPFLAGS'
749 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
750 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
751 cross_compiling=$ac_cv_prog_cc_cross
752
753 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
754 if test $ac_cv_prog_cc_works = no; then
755 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
756 fi
757 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
758 echo "configure:759: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
759 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
760 cross_compiling=$ac_cv_prog_cc_cross
761
762 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
763 echo "configure:764: checking whether we are using GNU C" >&5
764 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
765 echo $ac_n "(cached) $ac_c" 1>&6
766 else
767 cat > conftest.c <<EOF
768 #ifdef __GNUC__
769 yes;
770 #endif
771 EOF
772 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:773: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
773 ac_cv_prog_gcc=yes
774 else
775 ac_cv_prog_gcc=no
776 fi
777 fi
778
779 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
780
781 if test $ac_cv_prog_gcc = yes; then
782 GCC=yes
783 else
784 GCC=
785 fi
786
787 ac_test_CFLAGS="${CFLAGS+set}"
788 ac_save_CFLAGS="$CFLAGS"
789 CFLAGS=
790 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
791 echo "configure:792: checking whether ${CC-cc} accepts -g" >&5
792 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
793 echo $ac_n "(cached) $ac_c" 1>&6
794 else
795 echo 'void f(){}' > conftest.c
796 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
797 ac_cv_prog_cc_g=yes
798 else
799 ac_cv_prog_cc_g=no
800 fi
801 rm -f conftest*
802
803 fi
804
805 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
806 if test "$ac_test_CFLAGS" = set; then
807 CFLAGS="$ac_save_CFLAGS"
808 elif test $ac_cv_prog_cc_g = yes; then
809 if test "$GCC" = yes; then
810 CFLAGS="-g -O2"
811 else
812 CFLAGS="-g"
813 fi
814 else
815 if test "$GCC" = yes; then
816 CFLAGS="-O2"
817 else
818 CFLAGS=
819 fi
820 fi
821
822 cat >> confdefs.h <<\EOF
823 #define _GNU_SOURCE 1
824 EOF
825
826
827 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
828 echo "configure:829: checking how to run the C preprocessor" >&5
829 # On Suns, sometimes $CPP names a directory.
830 if test -n "$CPP" && test -d "$CPP"; then
831 CPP=
832 fi
833 if test -z "$CPP"; then
834 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
835 echo $ac_n "(cached) $ac_c" 1>&6
836 else
837 # This must be in double quotes, not single quotes, because CPP may get
838 # substituted into the Makefile and "${CC-cc}" will confuse make.
839 CPP="${CC-cc} -E"
840 # On the NeXT, cc -E runs the code through the compiler's parser,
841 # not just through cpp.
842 cat > conftest.$ac_ext <<EOF
843 #line 844 "configure"
844 #include "confdefs.h"
845 #include <assert.h>
846 Syntax Error
847 EOF
848 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
849 { (eval echo configure:850: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
850 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
851 if test -z "$ac_err"; then
852 :
853 else
854 echo "$ac_err" >&5
855 echo "configure: failed program was:" >&5
856 cat conftest.$ac_ext >&5
857 rm -rf conftest*
858 CPP="${CC-cc} -E -traditional-cpp"
859 cat > conftest.$ac_ext <<EOF
860 #line 861 "configure"
861 #include "confdefs.h"
862 #include <assert.h>
863 Syntax Error
864 EOF
865 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
866 { (eval echo configure:867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
867 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
868 if test -z "$ac_err"; then
869 :
870 else
871 echo "$ac_err" >&5
872 echo "configure: failed program was:" >&5
873 cat conftest.$ac_ext >&5
874 rm -rf conftest*
875 CPP="${CC-cc} -nologo -E"
876 cat > conftest.$ac_ext <<EOF
877 #line 878 "configure"
878 #include "confdefs.h"
879 #include <assert.h>
880 Syntax Error
881 EOF
882 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
883 { (eval echo configure:884: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
884 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
885 if test -z "$ac_err"; then
886 :
887 else
888 echo "$ac_err" >&5
889 echo "configure: failed program was:" >&5
890 cat conftest.$ac_ext >&5
891 rm -rf conftest*
892 CPP=/lib/cpp
893 fi
894 rm -f conftest*
895 fi
896 rm -f conftest*
897 fi
898 rm -f conftest*
899 ac_cv_prog_CPP="$CPP"
900 fi
901 CPP="$ac_cv_prog_CPP"
902 else
903 ac_cv_prog_CPP="$CPP"
904 fi
905 echo "$ac_t""$CPP" 1>&6
906
907 echo $ac_n "checking for AIX""... $ac_c" 1>&6
908 echo "configure:909: checking for AIX" >&5
909 cat > conftest.$ac_ext <<EOF
910 #line 911 "configure"
911 #include "confdefs.h"
912 #ifdef _AIX
913 yes
914 #endif
915
916 EOF
917 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
918 egrep "yes" >/dev/null 2>&1; then
919 rm -rf conftest*
920 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
921 #define _ALL_SOURCE 1
922 EOF
923
924 else
925 rm -rf conftest*
926 echo "$ac_t""no" 1>&6
927 fi
928 rm -f conftest*
929
930
931 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
932 echo "configure:933: checking for POSIXized ISC" >&5
933 if test -d /etc/conf/kconfig.d &&
934 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
935 then
936 echo "$ac_t""yes" 1>&6
937 ISC=yes # If later tests want to check for ISC.
938 cat >> confdefs.h <<\EOF
939 #define _POSIX_SOURCE 1
940 EOF
941
942 if test "$GCC" = yes; then
943 CC="$CC -posix"
944 else
945 CC="$CC -Xp"
946 fi
947 else
948 echo "$ac_t""no" 1>&6
949 ISC=
950 fi
951
952
953
954
955 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
956 echo "configure:957: checking for ${CC-cc} option to accept ANSI C" >&5
957 if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then
958 echo $ac_n "(cached) $ac_c" 1>&6
959 else
960 am_cv_prog_cc_stdc=no
961 ac_save_CC="$CC"
962 # Don't try gcc -ansi; that turns off useful extensions and
963 # breaks some systems' header files.
964 # AIX -qlanglvl=ansi
965 # Ultrix and OSF/1 -std1
966 # HP-UX 10.20 and later -Ae
967 # HP-UX older versions -Aa -D_HPUX_SOURCE
968 # SVR4 -Xc -D__EXTENSIONS__
969 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
970 do
971 CC="$ac_save_CC $ac_arg"
972 cat > conftest.$ac_ext <<EOF
973 #line 974 "configure"
974 #include "confdefs.h"
975 #include <stdarg.h>
976 #include <stdio.h>
977 #include <sys/types.h>
978 #include <sys/stat.h>
979 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
980 struct buf { int x; };
981 FILE * (*rcsopen) (struct buf *, struct stat *, int);
982 static char *e (p, i)
983 char **p;
984 int i;
985 {
986 return p[i];
987 }
988 static char *f (char * (*g) (char **, int), char **p, ...)
989 {
990 char *s;
991 va_list v;
992 va_start (v,p);
993 s = g (p, va_arg (v,int));
994 va_end (v);
995 return s;
996 }
997 int test (int i, double x);
998 struct s1 {int (*f) (int a);};
999 struct s2 {int (*f) (double a);};
1000 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1001 int argc;
1002 char **argv;
1003
1004 int main() {
1005
1006 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
1007
1008 ; return 0; }
1009 EOF
1010 if { (eval echo configure:1011: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1011 rm -rf conftest*
1012 am_cv_prog_cc_stdc="$ac_arg"; break
1013 else
1014 echo "configure: failed program was:" >&5
1015 cat conftest.$ac_ext >&5
1016 fi
1017 rm -f conftest*
1018 done
1019 CC="$ac_save_CC"
1020
1021 fi
1022
1023 if test -z "$am_cv_prog_cc_stdc"; then
1024 echo "$ac_t""none needed" 1>&6
1025 else
1026 echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
1027 fi
1028 case "x$am_cv_prog_cc_stdc" in
1029 x|xno) ;;
1030 *) CC="$CC $am_cv_prog_cc_stdc" ;;
1031 esac
1032
1033
1034 ac_aux_dir=
1035 for ac_dir in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/..; do
1036 if test -f $ac_dir/install-sh; then
1037 ac_aux_dir=$ac_dir
1038 ac_install_sh="$ac_aux_dir/install-sh -c"
1039 break
1040 elif test -f $ac_dir/install.sh; then
1041 ac_aux_dir=$ac_dir
1042 ac_install_sh="$ac_aux_dir/install.sh -c"
1043 break
1044 fi
1045 done
1046 if test -z "$ac_aux_dir"; then
1047 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/.." 1>&2; exit 1; }
1048 fi
1049 ac_config_guess=$ac_aux_dir/config.guess
1050 ac_config_sub=$ac_aux_dir/config.sub
1051 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1052
1053
1054 # Do some error checking and defaulting for the host and target type.
1055 # The inputs are:
1056 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
1057 #
1058 # The rules are:
1059 # 1. You are not allowed to specify --host, --target, and nonopt at the
1060 # same time.
1061 # 2. Host defaults to nonopt.
1062 # 3. If nonopt is not specified, then host defaults to the current host,
1063 # as determined by config.guess.
1064 # 4. Target and build default to nonopt.
1065 # 5. If nonopt is not specified, then target and build default to host.
1066
1067 # The aliases save the names the user supplied, while $host etc.
1068 # will get canonicalized.
1069 case $host---$target---$nonopt in
1070 NONE---*---* | *---NONE---* | *---*---NONE) ;;
1071 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
1072 esac
1073
1074
1075 # Make sure we can run config.sub.
1076 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
1077 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1078 fi
1079
1080 echo $ac_n "checking host system type""... $ac_c" 1>&6
1081 echo "configure:1082: checking host system type" >&5
1082
1083 host_alias=$host
1084 case "$host_alias" in
1085 NONE)
1086 case $nonopt in
1087 NONE)
1088 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
1089 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1090 fi ;;
1091 *) host_alias=$nonopt ;;
1092 esac ;;
1093 esac
1094
1095 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
1096 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1097 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1098 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1099 echo "$ac_t""$host" 1>&6
1100
1101 echo $ac_n "checking target system type""... $ac_c" 1>&6
1102 echo "configure:1103: checking target system type" >&5
1103
1104 target_alias=$target
1105 case "$target_alias" in
1106 NONE)
1107 case $nonopt in
1108 NONE) target_alias=$host_alias ;;
1109 *) target_alias=$nonopt ;;
1110 esac ;;
1111 esac
1112
1113 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
1114 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1115 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1116 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1117 echo "$ac_t""$target" 1>&6
1118
1119 echo $ac_n "checking build system type""... $ac_c" 1>&6
1120 echo "configure:1121: checking build system type" >&5
1121
1122 build_alias=$build
1123 case "$build_alias" in
1124 NONE)
1125 case $nonopt in
1126 NONE) build_alias=$host_alias ;;
1127 *) build_alias=$nonopt ;;
1128 esac ;;
1129 esac
1130
1131 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1132 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1133 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1134 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1135 echo "$ac_t""$build" 1>&6
1136
1137 test "$host_alias" != "$target_alias" &&
1138 test "$program_prefix$program_suffix$program_transform_name" = \
1139 NONENONEs,x,x, &&
1140 program_prefix=${target_alias}-
1141
1142
1143 # FIXME: kettenis/20030102: The AC_PROG_RANLIB from Autoconf 2.13
1144 # doesn't support cross-compilation, but the one from Autoconf 2.5x
1145 # does. Override RANLIB here (i.e. before running AC_PROG_RANLIB) to
1146 # deal with the lossage. Note that CY_GNU_GETTEXT currently calls
1147 # AC_PROG_RANLIB. This can be removed when we switch to Autoconf
1148 # 2.5x.
1149 if test $host != $build; then
1150 ac_tool_prefix=${host_alias}-
1151 else
1152 ac_tool_prefix=
1153 fi
1154
1155 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
1156 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1157 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1158 echo "configure:1159: checking for $ac_word" >&5
1159 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1160 echo $ac_n "(cached) $ac_c" 1>&6
1161 else
1162 if test -n "$RANLIB"; then
1163 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1164 else
1165 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1166 ac_dummy="$PATH"
1167 for ac_dir in $ac_dummy; do
1168 test -z "$ac_dir" && ac_dir=.
1169 if test -f $ac_dir/$ac_word; then
1170 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
1171 break
1172 fi
1173 done
1174 IFS="$ac_save_ifs"
1175 fi
1176 fi
1177 RANLIB="$ac_cv_prog_RANLIB"
1178 if test -n "$RANLIB"; then
1179 echo "$ac_t""$RANLIB" 1>&6
1180 else
1181 echo "$ac_t""no" 1>&6
1182 fi
1183
1184
1185 if test -z "$ac_cv_prog_RANLIB"; then
1186 if test -n "$ac_tool_prefix"; then
1187 # Extract the first word of "ranlib", so it can be a program name with args.
1188 set dummy ranlib; ac_word=$2
1189 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1190 echo "configure:1191: checking for $ac_word" >&5
1191 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1192 echo $ac_n "(cached) $ac_c" 1>&6
1193 else
1194 if test -n "$RANLIB"; then
1195 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1196 else
1197 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1198 ac_dummy="$PATH"
1199 for ac_dir in $ac_dummy; do
1200 test -z "$ac_dir" && ac_dir=.
1201 if test -f $ac_dir/$ac_word; then
1202 ac_cv_prog_RANLIB="ranlib"
1203 break
1204 fi
1205 done
1206 IFS="$ac_save_ifs"
1207 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1208 fi
1209 fi
1210 RANLIB="$ac_cv_prog_RANLIB"
1211 if test -n "$RANLIB"; then
1212 echo "$ac_t""$RANLIB" 1>&6
1213 else
1214 echo "$ac_t""no" 1>&6
1215 fi
1216
1217 else
1218 RANLIB=":"
1219 fi
1220 fi
1221
1222
1223 ALL_LINGUAS=
1224 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1225 echo "configure:1226: checking whether ${MAKE-make} sets \${MAKE}" >&5
1226 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1227 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1228 echo $ac_n "(cached) $ac_c" 1>&6
1229 else
1230 cat > conftestmake <<\EOF
1231 all:
1232 @echo 'ac_maketemp="${MAKE}"'
1233 EOF
1234 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1235 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1236 if test -n "$ac_maketemp"; then
1237 eval ac_cv_prog_make_${ac_make}_set=yes
1238 else
1239 eval ac_cv_prog_make_${ac_make}_set=no
1240 fi
1241 rm -f conftestmake
1242 fi
1243 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1244 echo "$ac_t""yes" 1>&6
1245 SET_MAKE=
1246 else
1247 echo "$ac_t""no" 1>&6
1248 SET_MAKE="MAKE=${MAKE-make}"
1249 fi
1250
1251 # Extract the first word of "ranlib", so it can be a program name with args.
1252 set dummy ranlib; ac_word=$2
1253 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1254 echo "configure:1255: checking for $ac_word" >&5
1255 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1256 echo $ac_n "(cached) $ac_c" 1>&6
1257 else
1258 if test -n "$RANLIB"; then
1259 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1260 else
1261 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1262 ac_dummy="$PATH"
1263 for ac_dir in $ac_dummy; do
1264 test -z "$ac_dir" && ac_dir=.
1265 if test -f $ac_dir/$ac_word; then
1266 ac_cv_prog_RANLIB="ranlib"
1267 break
1268 fi
1269 done
1270 IFS="$ac_save_ifs"
1271 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1272 fi
1273 fi
1274 RANLIB="$ac_cv_prog_RANLIB"
1275 if test -n "$RANLIB"; then
1276 echo "$ac_t""$RANLIB" 1>&6
1277 else
1278 echo "$ac_t""no" 1>&6
1279 fi
1280
1281 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1282 echo "configure:1283: checking for ANSI C header files" >&5
1283 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1284 echo $ac_n "(cached) $ac_c" 1>&6
1285 else
1286 cat > conftest.$ac_ext <<EOF
1287 #line 1288 "configure"
1288 #include "confdefs.h"
1289 #include <stdlib.h>
1290 #include <stdarg.h>
1291 #include <string.h>
1292 #include <float.h>
1293 EOF
1294 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1295 { (eval echo configure:1296: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1296 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1297 if test -z "$ac_err"; then
1298 rm -rf conftest*
1299 ac_cv_header_stdc=yes
1300 else
1301 echo "$ac_err" >&5
1302 echo "configure: failed program was:" >&5
1303 cat conftest.$ac_ext >&5
1304 rm -rf conftest*
1305 ac_cv_header_stdc=no
1306 fi
1307 rm -f conftest*
1308
1309 if test $ac_cv_header_stdc = yes; then
1310 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1311 cat > conftest.$ac_ext <<EOF
1312 #line 1313 "configure"
1313 #include "confdefs.h"
1314 #include <string.h>
1315 EOF
1316 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1317 egrep "memchr" >/dev/null 2>&1; then
1318 :
1319 else
1320 rm -rf conftest*
1321 ac_cv_header_stdc=no
1322 fi
1323 rm -f conftest*
1324
1325 fi
1326
1327 if test $ac_cv_header_stdc = yes; then
1328 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1329 cat > conftest.$ac_ext <<EOF
1330 #line 1331 "configure"
1331 #include "confdefs.h"
1332 #include <stdlib.h>
1333 EOF
1334 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1335 egrep "free" >/dev/null 2>&1; then
1336 :
1337 else
1338 rm -rf conftest*
1339 ac_cv_header_stdc=no
1340 fi
1341 rm -f conftest*
1342
1343 fi
1344
1345 if test $ac_cv_header_stdc = yes; then
1346 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1347 if test "$cross_compiling" = yes; then
1348 :
1349 else
1350 cat > conftest.$ac_ext <<EOF
1351 #line 1352 "configure"
1352 #include "confdefs.h"
1353 #include <ctype.h>
1354 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1355 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1356 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1357 int main () { int i; for (i = 0; i < 256; i++)
1358 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1359 exit (0); }
1360
1361 EOF
1362 if { (eval echo configure:1363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1363 then
1364 :
1365 else
1366 echo "configure: failed program was:" >&5
1367 cat conftest.$ac_ext >&5
1368 rm -fr conftest*
1369 ac_cv_header_stdc=no
1370 fi
1371 rm -fr conftest*
1372 fi
1373
1374 fi
1375 fi
1376
1377 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1378 if test $ac_cv_header_stdc = yes; then
1379 cat >> confdefs.h <<\EOF
1380 #define STDC_HEADERS 1
1381 EOF
1382
1383 fi
1384
1385 echo $ac_n "checking for working const""... $ac_c" 1>&6
1386 echo "configure:1387: checking for working const" >&5
1387 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1388 echo $ac_n "(cached) $ac_c" 1>&6
1389 else
1390 cat > conftest.$ac_ext <<EOF
1391 #line 1392 "configure"
1392 #include "confdefs.h"
1393
1394 int main() {
1395
1396 /* Ultrix mips cc rejects this. */
1397 typedef int charset[2]; const charset x;
1398 /* SunOS 4.1.1 cc rejects this. */
1399 char const *const *ccp;
1400 char **p;
1401 /* NEC SVR4.0.2 mips cc rejects this. */
1402 struct point {int x, y;};
1403 static struct point const zero = {0,0};
1404 /* AIX XL C 1.02.0.0 rejects this.
1405 It does not let you subtract one const X* pointer from another in an arm
1406 of an if-expression whose if-part is not a constant expression */
1407 const char *g = "string";
1408 ccp = &g + (g ? g-g : 0);
1409 /* HPUX 7.0 cc rejects these. */
1410 ++ccp;
1411 p = (char**) ccp;
1412 ccp = (char const *const *) p;
1413 { /* SCO 3.2v4 cc rejects this. */
1414 char *t;
1415 char const *s = 0 ? (char *) 0 : (char const *) 0;
1416
1417 *t++ = 0;
1418 }
1419 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
1420 int x[] = {25, 17};
1421 const int *foo = &x[0];
1422 ++foo;
1423 }
1424 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1425 typedef const int *iptr;
1426 iptr p = 0;
1427 ++p;
1428 }
1429 { /* AIX XL C 1.02.0.0 rejects this saying
1430 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1431 struct s { int j; const int *ap[3]; };
1432 struct s *b; b->j = 5;
1433 }
1434 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1435 const int foo = 10;
1436 }
1437
1438 ; return 0; }
1439 EOF
1440 if { (eval echo configure:1441: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1441 rm -rf conftest*
1442 ac_cv_c_const=yes
1443 else
1444 echo "configure: failed program was:" >&5
1445 cat conftest.$ac_ext >&5
1446 rm -rf conftest*
1447 ac_cv_c_const=no
1448 fi
1449 rm -f conftest*
1450 fi
1451
1452 echo "$ac_t""$ac_cv_c_const" 1>&6
1453 if test $ac_cv_c_const = no; then
1454 cat >> confdefs.h <<\EOF
1455 #define const
1456 EOF
1457
1458 fi
1459
1460 echo $ac_n "checking for inline""... $ac_c" 1>&6
1461 echo "configure:1462: checking for inline" >&5
1462 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1463 echo $ac_n "(cached) $ac_c" 1>&6
1464 else
1465 ac_cv_c_inline=no
1466 for ac_kw in inline __inline__ __inline; do
1467 cat > conftest.$ac_ext <<EOF
1468 #line 1469 "configure"
1469 #include "confdefs.h"
1470
1471 int main() {
1472 } $ac_kw foo() {
1473 ; return 0; }
1474 EOF
1475 if { (eval echo configure:1476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1476 rm -rf conftest*
1477 ac_cv_c_inline=$ac_kw; break
1478 else
1479 echo "configure: failed program was:" >&5
1480 cat conftest.$ac_ext >&5
1481 fi
1482 rm -f conftest*
1483 done
1484
1485 fi
1486
1487 echo "$ac_t""$ac_cv_c_inline" 1>&6
1488 case "$ac_cv_c_inline" in
1489 inline | yes) ;;
1490 no) cat >> confdefs.h <<\EOF
1491 #define inline
1492 EOF
1493 ;;
1494 *) cat >> confdefs.h <<EOF
1495 #define inline $ac_cv_c_inline
1496 EOF
1497 ;;
1498 esac
1499
1500 echo $ac_n "checking for off_t""... $ac_c" 1>&6
1501 echo "configure:1502: checking for off_t" >&5
1502 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1503 echo $ac_n "(cached) $ac_c" 1>&6
1504 else
1505 cat > conftest.$ac_ext <<EOF
1506 #line 1507 "configure"
1507 #include "confdefs.h"
1508 #include <sys/types.h>
1509 #if STDC_HEADERS
1510 #include <stdlib.h>
1511 #include <stddef.h>
1512 #endif
1513 EOF
1514 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1515 egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1516 rm -rf conftest*
1517 ac_cv_type_off_t=yes
1518 else
1519 rm -rf conftest*
1520 ac_cv_type_off_t=no
1521 fi
1522 rm -f conftest*
1523
1524 fi
1525 echo "$ac_t""$ac_cv_type_off_t" 1>&6
1526 if test $ac_cv_type_off_t = no; then
1527 cat >> confdefs.h <<\EOF
1528 #define off_t long
1529 EOF
1530
1531 fi
1532
1533 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1534 echo "configure:1535: checking for size_t" >&5
1535 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1536 echo $ac_n "(cached) $ac_c" 1>&6
1537 else
1538 cat > conftest.$ac_ext <<EOF
1539 #line 1540 "configure"
1540 #include "confdefs.h"
1541 #include <sys/types.h>
1542 #if STDC_HEADERS
1543 #include <stdlib.h>
1544 #include <stddef.h>
1545 #endif
1546 EOF
1547 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1548 egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1549 rm -rf conftest*
1550 ac_cv_type_size_t=yes
1551 else
1552 rm -rf conftest*
1553 ac_cv_type_size_t=no
1554 fi
1555 rm -f conftest*
1556
1557 fi
1558 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1559 if test $ac_cv_type_size_t = no; then
1560 cat >> confdefs.h <<\EOF
1561 #define size_t unsigned
1562 EOF
1563
1564 fi
1565
1566 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
1567 # for constant arguments. Useless!
1568 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1569 echo "configure:1570: checking for working alloca.h" >&5
1570 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
1571 echo $ac_n "(cached) $ac_c" 1>&6
1572 else
1573 cat > conftest.$ac_ext <<EOF
1574 #line 1575 "configure"
1575 #include "confdefs.h"
1576 #include <alloca.h>
1577 int main() {
1578 char *p = alloca(2 * sizeof(int));
1579 ; return 0; }
1580 EOF
1581 if { (eval echo configure:1582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1582 rm -rf conftest*
1583 ac_cv_header_alloca_h=yes
1584 else
1585 echo "configure: failed program was:" >&5
1586 cat conftest.$ac_ext >&5
1587 rm -rf conftest*
1588 ac_cv_header_alloca_h=no
1589 fi
1590 rm -f conftest*
1591 fi
1592
1593 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
1594 if test $ac_cv_header_alloca_h = yes; then
1595 cat >> confdefs.h <<\EOF
1596 #define HAVE_ALLOCA_H 1
1597 EOF
1598
1599 fi
1600
1601 echo $ac_n "checking for alloca""... $ac_c" 1>&6
1602 echo "configure:1603: checking for alloca" >&5
1603 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
1604 echo $ac_n "(cached) $ac_c" 1>&6
1605 else
1606 cat > conftest.$ac_ext <<EOF
1607 #line 1608 "configure"
1608 #include "confdefs.h"
1609
1610 #ifdef __GNUC__
1611 # define alloca __builtin_alloca
1612 #else
1613 # ifdef _MSC_VER
1614 # include <malloc.h>
1615 # define alloca _alloca
1616 # else
1617 # if HAVE_ALLOCA_H
1618 # include <alloca.h>
1619 # else
1620 # ifdef _AIX
1621 #pragma alloca
1622 # else
1623 # ifndef alloca /* predefined by HP cc +Olibcalls */
1624 char *alloca ();
1625 # endif
1626 # endif
1627 # endif
1628 # endif
1629 #endif
1630
1631 int main() {
1632 char *p = (char *) alloca(1);
1633 ; return 0; }
1634 EOF
1635 if { (eval echo configure:1636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1636 rm -rf conftest*
1637 ac_cv_func_alloca_works=yes
1638 else
1639 echo "configure: failed program was:" >&5
1640 cat conftest.$ac_ext >&5
1641 rm -rf conftest*
1642 ac_cv_func_alloca_works=no
1643 fi
1644 rm -f conftest*
1645 fi
1646
1647 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
1648 if test $ac_cv_func_alloca_works = yes; then
1649 cat >> confdefs.h <<\EOF
1650 #define HAVE_ALLOCA 1
1651 EOF
1652
1653 fi
1654
1655 if test $ac_cv_func_alloca_works = no; then
1656 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
1657 # that cause trouble. Some versions do not even contain alloca or
1658 # contain a buggy version. If you still want to use their alloca,
1659 # use ar to extract alloca.o from them instead of compiling alloca.c.
1660 ALLOCA=alloca.${ac_objext}
1661 cat >> confdefs.h <<\EOF
1662 #define C_ALLOCA 1
1663 EOF
1664
1665
1666 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1667 echo "configure:1668: checking whether alloca needs Cray hooks" >&5
1668 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
1669 echo $ac_n "(cached) $ac_c" 1>&6
1670 else
1671 cat > conftest.$ac_ext <<EOF
1672 #line 1673 "configure"
1673 #include "confdefs.h"
1674 #if defined(CRAY) && ! defined(CRAY2)
1675 webecray
1676 #else
1677 wenotbecray
1678 #endif
1679
1680 EOF
1681 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1682 egrep "webecray" >/dev/null 2>&1; then
1683 rm -rf conftest*
1684 ac_cv_os_cray=yes
1685 else
1686 rm -rf conftest*
1687 ac_cv_os_cray=no
1688 fi
1689 rm -f conftest*
1690
1691 fi
1692
1693 echo "$ac_t""$ac_cv_os_cray" 1>&6
1694 if test $ac_cv_os_cray = yes; then
1695 for ac_func in _getb67 GETB67 getb67; do
1696 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1697 echo "configure:1698: checking for $ac_func" >&5
1698 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1699 echo $ac_n "(cached) $ac_c" 1>&6
1700 else
1701 cat > conftest.$ac_ext <<EOF
1702 #line 1703 "configure"
1703 #include "confdefs.h"
1704 /* System header to define __stub macros and hopefully few prototypes,
1705 which can conflict with char $ac_func(); below. */
1706 #include <assert.h>
1707 /* Override any gcc2 internal prototype to avoid an error. */
1708 /* We use char because int might match the return type of a gcc2
1709 builtin and then its argument prototype would still apply. */
1710 char $ac_func();
1711
1712 int main() {
1713
1714 /* The GNU C library defines this for functions which it implements
1715 to always fail with ENOSYS. Some functions are actually named
1716 something starting with __ and the normal name is an alias. */
1717 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1718 choke me
1719 #else
1720 $ac_func();
1721 #endif
1722
1723 ; return 0; }
1724 EOF
1725 if { (eval echo configure:1726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1726 rm -rf conftest*
1727 eval "ac_cv_func_$ac_func=yes"
1728 else
1729 echo "configure: failed program was:" >&5
1730 cat conftest.$ac_ext >&5
1731 rm -rf conftest*
1732 eval "ac_cv_func_$ac_func=no"
1733 fi
1734 rm -f conftest*
1735 fi
1736
1737 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1738 echo "$ac_t""yes" 1>&6
1739 cat >> confdefs.h <<EOF
1740 #define CRAY_STACKSEG_END $ac_func
1741 EOF
1742
1743 break
1744 else
1745 echo "$ac_t""no" 1>&6
1746 fi
1747
1748 done
1749 fi
1750
1751 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1752 echo "configure:1753: checking stack direction for C alloca" >&5
1753 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
1754 echo $ac_n "(cached) $ac_c" 1>&6
1755 else
1756 if test "$cross_compiling" = yes; then
1757 ac_cv_c_stack_direction=0
1758 else
1759 cat > conftest.$ac_ext <<EOF
1760 #line 1761 "configure"
1761 #include "confdefs.h"
1762 find_stack_direction ()
1763 {
1764 static char *addr = 0;
1765 auto char dummy;
1766 if (addr == 0)
1767 {
1768 addr = &dummy;
1769 return find_stack_direction ();
1770 }
1771 else
1772 return (&dummy > addr) ? 1 : -1;
1773 }
1774 main ()
1775 {
1776 exit (find_stack_direction() < 0);
1777 }
1778 EOF
1779 if { (eval echo configure:1780: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1780 then
1781 ac_cv_c_stack_direction=1
1782 else
1783 echo "configure: failed program was:" >&5
1784 cat conftest.$ac_ext >&5
1785 rm -fr conftest*
1786 ac_cv_c_stack_direction=-1
1787 fi
1788 rm -fr conftest*
1789 fi
1790
1791 fi
1792
1793 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
1794 cat >> confdefs.h <<EOF
1795 #define STACK_DIRECTION $ac_cv_c_stack_direction
1796 EOF
1797
1798 fi
1799
1800 for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
1801 do
1802 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1803 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1804 echo "configure:1805: checking for $ac_hdr" >&5
1805 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1806 echo $ac_n "(cached) $ac_c" 1>&6
1807 else
1808 cat > conftest.$ac_ext <<EOF
1809 #line 1810 "configure"
1810 #include "confdefs.h"
1811 #include <$ac_hdr>
1812 EOF
1813 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1814 { (eval echo configure:1815: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1815 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1816 if test -z "$ac_err"; then
1817 rm -rf conftest*
1818 eval "ac_cv_header_$ac_safe=yes"
1819 else
1820 echo "$ac_err" >&5
1821 echo "configure: failed program was:" >&5
1822 cat conftest.$ac_ext >&5
1823 rm -rf conftest*
1824 eval "ac_cv_header_$ac_safe=no"
1825 fi
1826 rm -f conftest*
1827 fi
1828 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1829 echo "$ac_t""yes" 1>&6
1830 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1831 cat >> confdefs.h <<EOF
1832 #define $ac_tr_hdr 1
1833 EOF
1834
1835 else
1836 echo "$ac_t""no" 1>&6
1837 fi
1838 done
1839
1840 for ac_func in getpagesize
1841 do
1842 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1843 echo "configure:1844: checking for $ac_func" >&5
1844 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1845 echo $ac_n "(cached) $ac_c" 1>&6
1846 else
1847 cat > conftest.$ac_ext <<EOF
1848 #line 1849 "configure"
1849 #include "confdefs.h"
1850 /* System header to define __stub macros and hopefully few prototypes,
1851 which can conflict with char $ac_func(); below. */
1852 #include <assert.h>
1853 /* Override any gcc2 internal prototype to avoid an error. */
1854 /* We use char because int might match the return type of a gcc2
1855 builtin and then its argument prototype would still apply. */
1856 char $ac_func();
1857
1858 int main() {
1859
1860 /* The GNU C library defines this for functions which it implements
1861 to always fail with ENOSYS. Some functions are actually named
1862 something starting with __ and the normal name is an alias. */
1863 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1864 choke me
1865 #else
1866 $ac_func();
1867 #endif
1868
1869 ; return 0; }
1870 EOF
1871 if { (eval echo configure:1872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1872 rm -rf conftest*
1873 eval "ac_cv_func_$ac_func=yes"
1874 else
1875 echo "configure: failed program was:" >&5
1876 cat conftest.$ac_ext >&5
1877 rm -rf conftest*
1878 eval "ac_cv_func_$ac_func=no"
1879 fi
1880 rm -f conftest*
1881 fi
1882
1883 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1884 echo "$ac_t""yes" 1>&6
1885 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1886 cat >> confdefs.h <<EOF
1887 #define $ac_tr_func 1
1888 EOF
1889
1890 else
1891 echo "$ac_t""no" 1>&6
1892 fi
1893 done
1894
1895 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
1896 echo "configure:1897: checking for working mmap" >&5
1897 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
1898 echo $ac_n "(cached) $ac_c" 1>&6
1899 else
1900 if test "$cross_compiling" = yes; then
1901 ac_cv_func_mmap_fixed_mapped=no
1902 else
1903 cat > conftest.$ac_ext <<EOF
1904 #line 1905 "configure"
1905 #include "confdefs.h"
1906
1907 /* Thanks to Mike Haertel and Jim Avera for this test.
1908 Here is a matrix of mmap possibilities:
1909 mmap private not fixed
1910 mmap private fixed at somewhere currently unmapped
1911 mmap private fixed at somewhere already mapped
1912 mmap shared not fixed
1913 mmap shared fixed at somewhere currently unmapped
1914 mmap shared fixed at somewhere already mapped
1915 For private mappings, we should verify that changes cannot be read()
1916 back from the file, nor mmap's back from the file at a different
1917 address. (There have been systems where private was not correctly
1918 implemented like the infamous i386 svr4.0, and systems where the
1919 VM page cache was not coherent with the filesystem buffer cache
1920 like early versions of FreeBSD and possibly contemporary NetBSD.)
1921 For shared mappings, we should conversely verify that changes get
1922 propogated back to all the places they're supposed to be.
1923
1924 Grep wants private fixed already mapped.
1925 The main things grep needs to know about mmap are:
1926 * does it exist and is it safe to write into the mmap'd area
1927 * how to use it (BSD variants) */
1928 #include <sys/types.h>
1929 #include <fcntl.h>
1930 #include <sys/mman.h>
1931
1932 #if HAVE_SYS_TYPES_H
1933 # include <sys/types.h>
1934 #endif
1935
1936 #if HAVE_STDLIB_H
1937 # include <stdlib.h>
1938 #endif
1939
1940 #if HAVE_SYS_STAT_H
1941 # include <sys/stat.h>
1942 #endif
1943
1944 #if HAVE_UNISTD_H
1945 # include <unistd.h>
1946 #endif
1947
1948 /* This mess was copied from the GNU getpagesize.h. */
1949 #ifndef HAVE_GETPAGESIZE
1950
1951 /* Assume that all systems that can run configure have sys/param.h. */
1952 # ifndef HAVE_SYS_PARAM_H
1953 # define HAVE_SYS_PARAM_H 1
1954 # endif
1955
1956 # ifdef _SC_PAGESIZE
1957 # define getpagesize() sysconf(_SC_PAGESIZE)
1958 # else /* no _SC_PAGESIZE */
1959 # ifdef HAVE_SYS_PARAM_H
1960 # include <sys/param.h>
1961 # ifdef EXEC_PAGESIZE
1962 # define getpagesize() EXEC_PAGESIZE
1963 # else /* no EXEC_PAGESIZE */
1964 # ifdef NBPG
1965 # define getpagesize() NBPG * CLSIZE
1966 # ifndef CLSIZE
1967 # define CLSIZE 1
1968 # endif /* no CLSIZE */
1969 # else /* no NBPG */
1970 # ifdef NBPC
1971 # define getpagesize() NBPC
1972 # else /* no NBPC */
1973 # ifdef PAGESIZE
1974 # define getpagesize() PAGESIZE
1975 # endif /* PAGESIZE */
1976 # endif /* no NBPC */
1977 # endif /* no NBPG */
1978 # endif /* no EXEC_PAGESIZE */
1979 # else /* no HAVE_SYS_PARAM_H */
1980 # define getpagesize() 8192 /* punt totally */
1981 # endif /* no HAVE_SYS_PARAM_H */
1982 # endif /* no _SC_PAGESIZE */
1983
1984 #endif /* no HAVE_GETPAGESIZE */
1985
1986 #ifdef __cplusplus
1987 extern "C" { void *malloc(unsigned); }
1988 #else
1989 char *malloc();
1990 #endif
1991
1992 int
1993 main()
1994 {
1995 char *data, *data2, *data3;
1996 int i, pagesize;
1997 int fd;
1998
1999 pagesize = getpagesize();
2000
2001 /*
2002 * First, make a file with some known garbage in it.
2003 */
2004 data = malloc(pagesize);
2005 if (!data)
2006 exit(1);
2007 for (i = 0; i < pagesize; ++i)
2008 *(data + i) = rand();
2009 umask(0);
2010 fd = creat("conftestmmap", 0600);
2011 if (fd < 0)
2012 exit(1);
2013 if (write(fd, data, pagesize) != pagesize)
2014 exit(1);
2015 close(fd);
2016
2017 /*
2018 * Next, try to mmap the file at a fixed address which
2019 * already has something else allocated at it. If we can,
2020 * also make sure that we see the same garbage.
2021 */
2022 fd = open("conftestmmap", O_RDWR);
2023 if (fd < 0)
2024 exit(1);
2025 data2 = malloc(2 * pagesize);
2026 if (!data2)
2027 exit(1);
2028 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
2029 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
2030 MAP_PRIVATE | MAP_FIXED, fd, 0L))
2031 exit(1);
2032 for (i = 0; i < pagesize; ++i)
2033 if (*(data + i) != *(data2 + i))
2034 exit(1);
2035
2036 /*
2037 * Finally, make sure that changes to the mapped area
2038 * do not percolate back to the file as seen by read().
2039 * (This is a bug on some variants of i386 svr4.0.)
2040 */
2041 for (i = 0; i < pagesize; ++i)
2042 *(data2 + i) = *(data2 + i) + 1;
2043 data3 = malloc(pagesize);
2044 if (!data3)
2045 exit(1);
2046 if (read(fd, data3, pagesize) != pagesize)
2047 exit(1);
2048 for (i = 0; i < pagesize; ++i)
2049 if (*(data + i) != *(data3 + i))
2050 exit(1);
2051 close(fd);
2052 unlink("conftestmmap");
2053 exit(0);
2054 }
2055
2056 EOF
2057 if { (eval echo configure:2058: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2058 then
2059 ac_cv_func_mmap_fixed_mapped=yes
2060 else
2061 echo "configure: failed program was:" >&5
2062 cat conftest.$ac_ext >&5
2063 rm -fr conftest*
2064 ac_cv_func_mmap_fixed_mapped=no
2065 fi
2066 rm -fr conftest*
2067 fi
2068
2069 fi
2070
2071 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
2072 if test $ac_cv_func_mmap_fixed_mapped = yes; then
2073 cat >> confdefs.h <<\EOF
2074 #define HAVE_MMAP 1
2075 EOF
2076
2077 fi
2078
2079
2080 for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
2081 unistd.h values.h sys/param.h
2082 do
2083 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2084 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2085 echo "configure:2086: checking for $ac_hdr" >&5
2086 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2087 echo $ac_n "(cached) $ac_c" 1>&6
2088 else
2089 cat > conftest.$ac_ext <<EOF
2090 #line 2091 "configure"
2091 #include "confdefs.h"
2092 #include <$ac_hdr>
2093 EOF
2094 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2095 { (eval echo configure:2096: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2096 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2097 if test -z "$ac_err"; then
2098 rm -rf conftest*
2099 eval "ac_cv_header_$ac_safe=yes"
2100 else
2101 echo "$ac_err" >&5
2102 echo "configure: failed program was:" >&5
2103 cat conftest.$ac_ext >&5
2104 rm -rf conftest*
2105 eval "ac_cv_header_$ac_safe=no"
2106 fi
2107 rm -f conftest*
2108 fi
2109 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2110 echo "$ac_t""yes" 1>&6
2111 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2112 cat >> confdefs.h <<EOF
2113 #define $ac_tr_hdr 1
2114 EOF
2115
2116 else
2117 echo "$ac_t""no" 1>&6
2118 fi
2119 done
2120
2121 for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
2122 __argz_count __argz_stringify __argz_next
2123 do
2124 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2125 echo "configure:2126: checking for $ac_func" >&5
2126 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2127 echo $ac_n "(cached) $ac_c" 1>&6
2128 else
2129 cat > conftest.$ac_ext <<EOF
2130 #line 2131 "configure"
2131 #include "confdefs.h"
2132 /* System header to define __stub macros and hopefully few prototypes,
2133 which can conflict with char $ac_func(); below. */
2134 #include <assert.h>
2135 /* Override any gcc2 internal prototype to avoid an error. */
2136 /* We use char because int might match the return type of a gcc2
2137 builtin and then its argument prototype would still apply. */
2138 char $ac_func();
2139
2140 int main() {
2141
2142 /* The GNU C library defines this for functions which it implements
2143 to always fail with ENOSYS. Some functions are actually named
2144 something starting with __ and the normal name is an alias. */
2145 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2146 choke me
2147 #else
2148 $ac_func();
2149 #endif
2150
2151 ; return 0; }
2152 EOF
2153 if { (eval echo configure:2154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2154 rm -rf conftest*
2155 eval "ac_cv_func_$ac_func=yes"
2156 else
2157 echo "configure: failed program was:" >&5
2158 cat conftest.$ac_ext >&5
2159 rm -rf conftest*
2160 eval "ac_cv_func_$ac_func=no"
2161 fi
2162 rm -f conftest*
2163 fi
2164
2165 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2166 echo "$ac_t""yes" 1>&6
2167 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2168 cat >> confdefs.h <<EOF
2169 #define $ac_tr_func 1
2170 EOF
2171
2172 else
2173 echo "$ac_t""no" 1>&6
2174 fi
2175 done
2176
2177
2178 if test "${ac_cv_func_stpcpy+set}" != "set"; then
2179 for ac_func in stpcpy
2180 do
2181 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2182 echo "configure:2183: checking for $ac_func" >&5
2183 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2184 echo $ac_n "(cached) $ac_c" 1>&6
2185 else
2186 cat > conftest.$ac_ext <<EOF
2187 #line 2188 "configure"
2188 #include "confdefs.h"
2189 /* System header to define __stub macros and hopefully few prototypes,
2190 which can conflict with char $ac_func(); below. */
2191 #include <assert.h>
2192 /* Override any gcc2 internal prototype to avoid an error. */
2193 /* We use char because int might match the return type of a gcc2
2194 builtin and then its argument prototype would still apply. */
2195 char $ac_func();
2196
2197 int main() {
2198
2199 /* The GNU C library defines this for functions which it implements
2200 to always fail with ENOSYS. Some functions are actually named
2201 something starting with __ and the normal name is an alias. */
2202 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2203 choke me
2204 #else
2205 $ac_func();
2206 #endif
2207
2208 ; return 0; }
2209 EOF
2210 if { (eval echo configure:2211: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2211 rm -rf conftest*
2212 eval "ac_cv_func_$ac_func=yes"
2213 else
2214 echo "configure: failed program was:" >&5
2215 cat conftest.$ac_ext >&5
2216 rm -rf conftest*
2217 eval "ac_cv_func_$ac_func=no"
2218 fi
2219 rm -f conftest*
2220 fi
2221
2222 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2223 echo "$ac_t""yes" 1>&6
2224 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2225 cat >> confdefs.h <<EOF
2226 #define $ac_tr_func 1
2227 EOF
2228
2229 else
2230 echo "$ac_t""no" 1>&6
2231 fi
2232 done
2233
2234 fi
2235 if test "${ac_cv_func_stpcpy}" = "yes"; then
2236 cat >> confdefs.h <<\EOF
2237 #define HAVE_STPCPY 1
2238 EOF
2239
2240 fi
2241
2242 if test $ac_cv_header_locale_h = yes; then
2243 echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
2244 echo "configure:2245: checking for LC_MESSAGES" >&5
2245 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
2246 echo $ac_n "(cached) $ac_c" 1>&6
2247 else
2248 cat > conftest.$ac_ext <<EOF
2249 #line 2250 "configure"
2250 #include "confdefs.h"
2251 #include <locale.h>
2252 int main() {
2253 return LC_MESSAGES
2254 ; return 0; }
2255 EOF
2256 if { (eval echo configure:2257: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2257 rm -rf conftest*
2258 am_cv_val_LC_MESSAGES=yes
2259 else
2260 echo "configure: failed program was:" >&5
2261 cat conftest.$ac_ext >&5
2262 rm -rf conftest*
2263 am_cv_val_LC_MESSAGES=no
2264 fi
2265 rm -f conftest*
2266 fi
2267
2268 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
2269 if test $am_cv_val_LC_MESSAGES = yes; then
2270 cat >> confdefs.h <<\EOF
2271 #define HAVE_LC_MESSAGES 1
2272 EOF
2273
2274 fi
2275 fi
2276 echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
2277 echo "configure:2278: checking whether NLS is requested" >&5
2278 # Check whether --enable-nls or --disable-nls was given.
2279 if test "${enable_nls+set}" = set; then
2280 enableval="$enable_nls"
2281 USE_NLS=$enableval
2282 else
2283 USE_NLS=yes
2284 fi
2285
2286 echo "$ac_t""$USE_NLS" 1>&6
2287
2288
2289 USE_INCLUDED_LIBINTL=no
2290
2291 if test "$USE_NLS" = "yes"; then
2292 cat >> confdefs.h <<\EOF
2293 #define ENABLE_NLS 1
2294 EOF
2295
2296 echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
2297 echo "configure:2298: checking whether included gettext is requested" >&5
2298 # Check whether --with-included-gettext or --without-included-gettext was given.
2299 if test "${with_included_gettext+set}" = set; then
2300 withval="$with_included_gettext"
2301 nls_cv_force_use_gnu_gettext=$withval
2302 else
2303 nls_cv_force_use_gnu_gettext=no
2304 fi
2305
2306 echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
2307
2308 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
2309 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
2310 nls_cv_header_intl=
2311 nls_cv_header_libgt=
2312 CATOBJEXT=NONE
2313
2314 ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
2315 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
2316 echo "configure:2317: checking for libintl.h" >&5
2317 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2318 echo $ac_n "(cached) $ac_c" 1>&6
2319 else
2320 cat > conftest.$ac_ext <<EOF
2321 #line 2322 "configure"
2322 #include "confdefs.h"
2323 #include <libintl.h>
2324 EOF
2325 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2326 { (eval echo configure:2327: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2327 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2328 if test -z "$ac_err"; then
2329 rm -rf conftest*
2330 eval "ac_cv_header_$ac_safe=yes"
2331 else
2332 echo "$ac_err" >&5
2333 echo "configure: failed program was:" >&5
2334 cat conftest.$ac_ext >&5
2335 rm -rf conftest*
2336 eval "ac_cv_header_$ac_safe=no"
2337 fi
2338 rm -f conftest*
2339 fi
2340 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2341 echo "$ac_t""yes" 1>&6
2342 echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
2343 echo "configure:2344: checking for gettext in libc" >&5
2344 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
2345 echo $ac_n "(cached) $ac_c" 1>&6
2346 else
2347 cat > conftest.$ac_ext <<EOF
2348 #line 2349 "configure"
2349 #include "confdefs.h"
2350 #include <libintl.h>
2351 int main() {
2352 return (int) gettext ("")
2353 ; return 0; }
2354 EOF
2355 if { (eval echo configure:2356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2356 rm -rf conftest*
2357 gt_cv_func_gettext_libc=yes
2358 else
2359 echo "configure: failed program was:" >&5
2360 cat conftest.$ac_ext >&5
2361 rm -rf conftest*
2362 gt_cv_func_gettext_libc=no
2363 fi
2364 rm -f conftest*
2365 fi
2366
2367 echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
2368
2369 if test "$gt_cv_func_gettext_libc" != "yes"; then
2370 echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
2371 echo "configure:2372: checking for bindtextdomain in -lintl" >&5
2372 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
2373 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2374 echo $ac_n "(cached) $ac_c" 1>&6
2375 else
2376 ac_save_LIBS="$LIBS"
2377 LIBS="-lintl $LIBS"
2378 cat > conftest.$ac_ext <<EOF
2379 #line 2380 "configure"
2380 #include "confdefs.h"
2381 /* Override any gcc2 internal prototype to avoid an error. */
2382 /* We use char because int might match the return type of a gcc2
2383 builtin and then its argument prototype would still apply. */
2384 char bindtextdomain();
2385
2386 int main() {
2387 bindtextdomain()
2388 ; return 0; }
2389 EOF
2390 if { (eval echo configure:2391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2391 rm -rf conftest*
2392 eval "ac_cv_lib_$ac_lib_var=yes"
2393 else
2394 echo "configure: failed program was:" >&5
2395 cat conftest.$ac_ext >&5
2396 rm -rf conftest*
2397 eval "ac_cv_lib_$ac_lib_var=no"
2398 fi
2399 rm -f conftest*
2400 LIBS="$ac_save_LIBS"
2401
2402 fi
2403 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2404 echo "$ac_t""yes" 1>&6
2405 echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
2406 echo "configure:2407: checking for gettext in libintl" >&5
2407 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
2408 echo $ac_n "(cached) $ac_c" 1>&6
2409 else
2410 cat > conftest.$ac_ext <<EOF
2411 #line 2412 "configure"
2412 #include "confdefs.h"
2413
2414 int main() {
2415 return (int) gettext ("")
2416 ; return 0; }
2417 EOF
2418 if { (eval echo configure:2419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2419 rm -rf conftest*
2420 gt_cv_func_gettext_libintl=yes
2421 else
2422 echo "configure: failed program was:" >&5
2423 cat conftest.$ac_ext >&5
2424 rm -rf conftest*
2425 gt_cv_func_gettext_libintl=no
2426 fi
2427 rm -f conftest*
2428 fi
2429
2430 echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
2431 else
2432 echo "$ac_t""no" 1>&6
2433 fi
2434
2435 fi
2436
2437 if test "$gt_cv_func_gettext_libc" = "yes" \
2438 || test "$gt_cv_func_gettext_libintl" = "yes"; then
2439 cat >> confdefs.h <<\EOF
2440 #define HAVE_GETTEXT 1
2441 EOF
2442
2443 # Extract the first word of "msgfmt", so it can be a program name with args.
2444 set dummy msgfmt; ac_word=$2
2445 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2446 echo "configure:2447: checking for $ac_word" >&5
2447 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2448 echo $ac_n "(cached) $ac_c" 1>&6
2449 else
2450 case "$MSGFMT" in
2451 /*)
2452 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2453 ;;
2454 *)
2455 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2456 for ac_dir in $PATH; do
2457 test -z "$ac_dir" && ac_dir=.
2458 if test -f $ac_dir/$ac_word; then
2459 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2460 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2461 break
2462 fi
2463 fi
2464 done
2465 IFS="$ac_save_ifs"
2466 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
2467 ;;
2468 esac
2469 fi
2470 MSGFMT="$ac_cv_path_MSGFMT"
2471 if test -n "$MSGFMT"; then
2472 echo "$ac_t""$MSGFMT" 1>&6
2473 else
2474 echo "$ac_t""no" 1>&6
2475 fi
2476 if test "$MSGFMT" != "no"; then
2477 for ac_func in dcgettext
2478 do
2479 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2480 echo "configure:2481: checking for $ac_func" >&5
2481 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2482 echo $ac_n "(cached) $ac_c" 1>&6
2483 else
2484 cat > conftest.$ac_ext <<EOF
2485 #line 2486 "configure"
2486 #include "confdefs.h"
2487 /* System header to define __stub macros and hopefully few prototypes,
2488 which can conflict with char $ac_func(); below. */
2489 #include <assert.h>
2490 /* Override any gcc2 internal prototype to avoid an error. */
2491 /* We use char because int might match the return type of a gcc2
2492 builtin and then its argument prototype would still apply. */
2493 char $ac_func();
2494
2495 int main() {
2496
2497 /* The GNU C library defines this for functions which it implements
2498 to always fail with ENOSYS. Some functions are actually named
2499 something starting with __ and the normal name is an alias. */
2500 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2501 choke me
2502 #else
2503 $ac_func();
2504 #endif
2505
2506 ; return 0; }
2507 EOF
2508 if { (eval echo configure:2509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2509 rm -rf conftest*
2510 eval "ac_cv_func_$ac_func=yes"
2511 else
2512 echo "configure: failed program was:" >&5
2513 cat conftest.$ac_ext >&5
2514 rm -rf conftest*
2515 eval "ac_cv_func_$ac_func=no"
2516 fi
2517 rm -f conftest*
2518 fi
2519
2520 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2521 echo "$ac_t""yes" 1>&6
2522 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2523 cat >> confdefs.h <<EOF
2524 #define $ac_tr_func 1
2525 EOF
2526
2527 else
2528 echo "$ac_t""no" 1>&6
2529 fi
2530 done
2531
2532 # Extract the first word of "gmsgfmt", so it can be a program name with args.
2533 set dummy gmsgfmt; ac_word=$2
2534 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2535 echo "configure:2536: checking for $ac_word" >&5
2536 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2537 echo $ac_n "(cached) $ac_c" 1>&6
2538 else
2539 case "$GMSGFMT" in
2540 /*)
2541 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2542 ;;
2543 ?:/*)
2544 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2545 ;;
2546 *)
2547 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2548 ac_dummy="$PATH"
2549 for ac_dir in $ac_dummy; do
2550 test -z "$ac_dir" && ac_dir=.
2551 if test -f $ac_dir/$ac_word; then
2552 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2553 break
2554 fi
2555 done
2556 IFS="$ac_save_ifs"
2557 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2558 ;;
2559 esac
2560 fi
2561 GMSGFMT="$ac_cv_path_GMSGFMT"
2562 if test -n "$GMSGFMT"; then
2563 echo "$ac_t""$GMSGFMT" 1>&6
2564 else
2565 echo "$ac_t""no" 1>&6
2566 fi
2567
2568 # Extract the first word of "xgettext", so it can be a program name with args.
2569 set dummy xgettext; ac_word=$2
2570 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2571 echo "configure:2572: checking for $ac_word" >&5
2572 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2573 echo $ac_n "(cached) $ac_c" 1>&6
2574 else
2575 case "$XGETTEXT" in
2576 /*)
2577 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2578 ;;
2579 *)
2580 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2581 for ac_dir in $PATH; do
2582 test -z "$ac_dir" && ac_dir=.
2583 if test -f $ac_dir/$ac_word; then
2584 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2585 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2586 break
2587 fi
2588 fi
2589 done
2590 IFS="$ac_save_ifs"
2591 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2592 ;;
2593 esac
2594 fi
2595 XGETTEXT="$ac_cv_path_XGETTEXT"
2596 if test -n "$XGETTEXT"; then
2597 echo "$ac_t""$XGETTEXT" 1>&6
2598 else
2599 echo "$ac_t""no" 1>&6
2600 fi
2601
2602 cat > conftest.$ac_ext <<EOF
2603 #line 2604 "configure"
2604 #include "confdefs.h"
2605
2606 int main() {
2607 extern int _nl_msg_cat_cntr;
2608 return _nl_msg_cat_cntr
2609 ; return 0; }
2610 EOF
2611 if { (eval echo configure:2612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2612 rm -rf conftest*
2613 CATOBJEXT=.gmo
2614 DATADIRNAME=share
2615 else
2616 echo "configure: failed program was:" >&5
2617 cat conftest.$ac_ext >&5
2618 rm -rf conftest*
2619 CATOBJEXT=.mo
2620 DATADIRNAME=lib
2621 fi
2622 rm -f conftest*
2623 INSTOBJEXT=.mo
2624 fi
2625 fi
2626
2627 else
2628 echo "$ac_t""no" 1>&6
2629 fi
2630
2631
2632
2633 if test "$CATOBJEXT" = "NONE"; then
2634 nls_cv_use_gnu_gettext=yes
2635 fi
2636 fi
2637
2638 if test "$nls_cv_use_gnu_gettext" = "yes"; then
2639 INTLOBJS="\$(GETTOBJS)"
2640 # Extract the first word of "msgfmt", so it can be a program name with args.
2641 set dummy msgfmt; ac_word=$2
2642 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2643 echo "configure:2644: checking for $ac_word" >&5
2644 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2645 echo $ac_n "(cached) $ac_c" 1>&6
2646 else
2647 case "$MSGFMT" in
2648 /*)
2649 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2650 ;;
2651 *)
2652 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2653 for ac_dir in $PATH; do
2654 test -z "$ac_dir" && ac_dir=.
2655 if test -f $ac_dir/$ac_word; then
2656 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2657 ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2658 break
2659 fi
2660 fi
2661 done
2662 IFS="$ac_save_ifs"
2663 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
2664 ;;
2665 esac
2666 fi
2667 MSGFMT="$ac_cv_path_MSGFMT"
2668 if test -n "$MSGFMT"; then
2669 echo "$ac_t""$MSGFMT" 1>&6
2670 else
2671 echo "$ac_t""no" 1>&6
2672 fi
2673
2674 # Extract the first word of "gmsgfmt", so it can be a program name with args.
2675 set dummy gmsgfmt; ac_word=$2
2676 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2677 echo "configure:2678: checking for $ac_word" >&5
2678 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2679 echo $ac_n "(cached) $ac_c" 1>&6
2680 else
2681 case "$GMSGFMT" in
2682 /*)
2683 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2684 ;;
2685 ?:/*)
2686 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2687 ;;
2688 *)
2689 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2690 ac_dummy="$PATH"
2691 for ac_dir in $ac_dummy; do
2692 test -z "$ac_dir" && ac_dir=.
2693 if test -f $ac_dir/$ac_word; then
2694 ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2695 break
2696 fi
2697 done
2698 IFS="$ac_save_ifs"
2699 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2700 ;;
2701 esac
2702 fi
2703 GMSGFMT="$ac_cv_path_GMSGFMT"
2704 if test -n "$GMSGFMT"; then
2705 echo "$ac_t""$GMSGFMT" 1>&6
2706 else
2707 echo "$ac_t""no" 1>&6
2708 fi
2709
2710 # Extract the first word of "xgettext", so it can be a program name with args.
2711 set dummy xgettext; ac_word=$2
2712 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2713 echo "configure:2714: checking for $ac_word" >&5
2714 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2715 echo $ac_n "(cached) $ac_c" 1>&6
2716 else
2717 case "$XGETTEXT" in
2718 /*)
2719 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2720 ;;
2721 *)
2722 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2723 for ac_dir in $PATH; do
2724 test -z "$ac_dir" && ac_dir=.
2725 if test -f $ac_dir/$ac_word; then
2726 if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2727 ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2728 break
2729 fi
2730 fi
2731 done
2732 IFS="$ac_save_ifs"
2733 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2734 ;;
2735 esac
2736 fi
2737 XGETTEXT="$ac_cv_path_XGETTEXT"
2738 if test -n "$XGETTEXT"; then
2739 echo "$ac_t""$XGETTEXT" 1>&6
2740 else
2741 echo "$ac_t""no" 1>&6
2742 fi
2743
2744
2745 USE_INCLUDED_LIBINTL=yes
2746 CATOBJEXT=.gmo
2747 INSTOBJEXT=.mo
2748 DATADIRNAME=share
2749 INTLDEPS='$(top_builddir)/../intl/libintl.a'
2750 INTLLIBS=$INTLDEPS
2751 LIBS=`echo $LIBS | sed -e 's/-lintl//'`
2752 nls_cv_header_intl=libintl.h
2753 nls_cv_header_libgt=libgettext.h
2754 fi
2755
2756 if test "$XGETTEXT" != ":"; then
2757 if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
2758 : ;
2759 else
2760 echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
2761 XGETTEXT=":"
2762 fi
2763 fi
2764
2765 # We need to process the po/ directory.
2766 POSUB=po
2767 else
2768 DATADIRNAME=share
2769 nls_cv_header_intl=libintl.h
2770 nls_cv_header_libgt=libgettext.h
2771 fi
2772
2773 # If this is used in GNU gettext we have to set USE_NLS to `yes'
2774 # because some of the sources are only built for this goal.
2775 if test "$PACKAGE" = gettext; then
2776 USE_NLS=yes
2777 USE_INCLUDED_LIBINTL=yes
2778 fi
2779
2780 for lang in $ALL_LINGUAS; do
2781 GMOFILES="$GMOFILES $lang.gmo"
2782 POFILES="$POFILES $lang.po"
2783 done
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798 if test "x$CATOBJEXT" != "x"; then
2799 if test "x$ALL_LINGUAS" = "x"; then
2800 LINGUAS=
2801 else
2802 echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
2803 echo "configure:2804: checking for catalogs to be installed" >&5
2804 NEW_LINGUAS=
2805 for lang in ${LINGUAS=$ALL_LINGUAS}; do
2806 case "$ALL_LINGUAS" in
2807 *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
2808 esac
2809 done
2810 LINGUAS=$NEW_LINGUAS
2811 echo "$ac_t""$LINGUAS" 1>&6
2812 fi
2813
2814 if test -n "$LINGUAS"; then
2815 for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
2816 fi
2817 fi
2818
2819 if test $ac_cv_header_locale_h = yes; then
2820 INCLUDE_LOCALE_H="#include <locale.h>"
2821 else
2822 INCLUDE_LOCALE_H="\
2823 /* The system does not provide the header <locale.h>. Take care yourself. */"
2824 fi
2825
2826
2827 if test -f $srcdir/po2tbl.sed.in; then
2828 if test "$CATOBJEXT" = ".cat"; then
2829 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
2830 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
2831 echo "configure:2832: checking for linux/version.h" >&5
2832 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2833 echo $ac_n "(cached) $ac_c" 1>&6
2834 else
2835 cat > conftest.$ac_ext <<EOF
2836 #line 2837 "configure"
2837 #include "confdefs.h"
2838 #include <linux/version.h>
2839 EOF
2840 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2841 { (eval echo configure:2842: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2842 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2843 if test -z "$ac_err"; then
2844 rm -rf conftest*
2845 eval "ac_cv_header_$ac_safe=yes"
2846 else
2847 echo "$ac_err" >&5
2848 echo "configure: failed program was:" >&5
2849 cat conftest.$ac_ext >&5
2850 rm -rf conftest*
2851 eval "ac_cv_header_$ac_safe=no"
2852 fi
2853 rm -f conftest*
2854 fi
2855 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2856 echo "$ac_t""yes" 1>&6
2857 msgformat=linux
2858 else
2859 echo "$ac_t""no" 1>&6
2860 msgformat=xopen
2861 fi
2862
2863
2864 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
2865 fi
2866 sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
2867 $srcdir/po2tbl.sed.in > po2tbl.sed
2868 fi
2869
2870 if test "$PACKAGE" = "gettext"; then
2871 GT_NO="#NO#"
2872 GT_YES=
2873 else
2874 GT_NO=
2875 GT_YES="#YES#"
2876 fi
2877
2878
2879
2880 MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
2881
2882
2883 l=
2884
2885
2886 if test -f $srcdir/po/POTFILES.in; then
2887 test -d po || mkdir po
2888 if test "x$srcdir" != "x."; then
2889 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
2890 posrcprefix="$srcdir/"
2891 else
2892 posrcprefix="../$srcdir/"
2893 fi
2894 else
2895 posrcprefix="../"
2896 fi
2897 rm -f po/POTFILES
2898 sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
2899 < $srcdir/po/POTFILES.in > po/POTFILES
2900 fi
2901
2902 cat >> confdefs.h <<\EOF
2903 #define PACKAGE "gdb"
2904 EOF
2905
2906
2907 debugdir=${libdir}/debug
2908
2909 # Check whether --with-separate-debug-dir or --without-separate-debug-dir was given.
2910 if test "${with_separate_debug_dir+set}" = set; then
2911 withval="$with_separate_debug_dir"
2912 debugdir="${withval}"
2913 fi
2914
2915
2916
2917 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
2918 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2919 ac_define_dir=`eval echo $debugdir`
2920 ac_define_dir=`eval echo $ac_define_dir`
2921 cat >> confdefs.h <<EOF
2922 #define DEBUGDIR "$ac_define_dir"
2923 EOF
2924
2925
2926 #AC_DEFINE_UNQUOTED(DEBUGDIR, "$debugdir"),
2927
2928
2929 CONFIG_OBS=
2930 CONFIG_LIB_OBS=
2931 CONFIG_DEPS=
2932 CONFIG_SRCS=
2933 CONFIG_INITS=
2934 ENABLE_CFLAGS=
2935 CONFIG_ALL=
2936 CONFIG_CLEAN=
2937 CONFIG_INSTALL=
2938 CONFIG_UNINSTALL=
2939
2940 subdirs="doc testsuite"
2941
2942 configdirs=
2943
2944 . $srcdir/configure.host
2945
2946 . $srcdir/configure.tgt
2947
2948 # Fetch the default architecture and default target vector from BFD.
2949 targ=$target; . $srcdir/../bfd/config.bfd
2950
2951 # We only want the first architecture, so strip off the others if
2952 # there is more than one.
2953 targ_archs=`echo $targ_archs | sed 's/ .*//'`
2954
2955 if test "x$targ_archs" != x; then
2956 cat >> confdefs.h <<EOF
2957 #define DEFAULT_BFD_ARCH $targ_archs
2958 EOF
2959
2960 fi
2961 if test "x$targ_defvec" != x; then
2962 cat >> confdefs.h <<EOF
2963 #define DEFAULT_BFD_VEC $targ_defvec
2964 EOF
2965
2966 fi
2967
2968 if test "$program_transform_name" = s,x,x,; then
2969 program_transform_name=
2970 else
2971 # Double any \ or $. echo might interpret backslashes.
2972 cat <<\EOF_SED > conftestsed
2973 s,\\,\\\\,g; s,\$,$$,g
2974 EOF_SED
2975 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
2976 rm -f conftestsed
2977 fi
2978 test "$program_prefix" != NONE &&
2979 program_transform_name="s,^,${program_prefix},; $program_transform_name"
2980 # Use a double $ so make ignores it.
2981 test "$program_suffix" != NONE &&
2982 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
2983
2984 # sed with no file args requires a program.
2985 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
2986
2987
2988 # The CLI cannot be disabled yet, but may be in the future.
2989
2990 # Enable CLI.
2991 # Check whether --enable-gdbcli or --disable-gdbcli was given.
2992 if test "${enable_gdbcli+set}" = set; then
2993 enableval="$enable_gdbcli"
2994 case $enableval in
2995 yes)
2996 ;;
2997 no)
2998 { echo "configure: error: the command-line interface cannot be disabled yet" 1>&2; exit 1; } ;;
2999 *)
3000 { echo "configure: error: bad value $enableval for --enable-gdbcli" 1>&2; exit 1; } ;;
3001 esac
3002 else
3003 enable_gdbcli=yes
3004 fi
3005
3006 if test x"$enable_gdbcli" = xyes; then
3007 if test -d $srcdir/cli; then
3008 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_CLI_OBS)"
3009 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_CLI_DEPS)"
3010 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_CLI_SRCS)"
3011 CONFIG_INITS="$CONFIG_INITS \$(SUBDIR_CLI_INITS)"
3012 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_CLI_CFLAGS)"
3013 CONFIG_ALL="$CONFIG_ALL \$(SUBDIR_CLI_ALL)"
3014 CONFIG_CLEAN="$CONFIG_CLEAN \$(SUBDIR_CLI_CLEAN)"
3015 CONFIG_INSTALL="$CONFIG_INSTALL \$(SUBDIR_CLI_INSTALL)"
3016 CONFIG_UNINSTALL="$CONFIG_UNINSTALL \$(SUBDIR_CLI_UNINSTALL)"
3017 fi
3018 fi
3019
3020 # Enable MI.
3021 # Check whether --enable-gdbmi or --disable-gdbmi was given.
3022 if test "${enable_gdbmi+set}" = set; then
3023 enableval="$enable_gdbmi"
3024 case $enableval in
3025 yes | no)
3026 ;;
3027 *)
3028 { echo "configure: error: bad value $enableval for --enable-gdbmi" 1>&2; exit 1; } ;;
3029 esac
3030 else
3031 enable_gdbmi=yes
3032 fi
3033
3034 if test x"$enable_gdbmi" = xyes; then
3035 if test -d $srcdir/mi; then
3036 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_MI_OBS)"
3037 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_MI_DEPS)"
3038 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_MI_SRCS)"
3039 CONFIG_INITS="$CONFIG_INITS \$(SUBDIR_MI_INITS)"
3040 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_MI_CFLAGS)"
3041 CONFIG_ALL="$CONFIG_ALL \$(SUBDIR_MI_ALL)"
3042 CONFIG_CLEAN="$CONFIG_CLEAN \$(SUBDIR_MI_CLEAN)"
3043 CONFIG_INSTALL="$CONFIG_INSTALL \$(SUBDIR_MI_INSTALL)"
3044 CONFIG_UNINSTALL="$CONFIG_UNINSTALL \$(SUBDIR_MI_UNINSTALL)"
3045 fi
3046 fi
3047
3048 # Enable TUI.
3049 # Check whether --enable-tui or --disable-tui was given.
3050 if test "${enable_tui+set}" = set; then
3051 enableval="$enable_tui"
3052 case $enableval in
3053 yes | no)
3054 ;;
3055 *)
3056 { echo "configure: error: bad value $enableval for --enable-tui" 1>&2; exit 1; } ;;
3057 esac
3058 fi
3059
3060 if test x"$enable_tui" = xyes; then
3061 if test -d $srcdir/tui; then
3062 CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
3063 CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
3064 CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
3065 CONFIG_INITS="$CONFIG_INITS \$(SUBDIR_TUI_INITS)"
3066 ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
3067 CONFIG_ALL="$CONFIG_ALL \$(SUBDIR_TUI_ALL)"
3068 CONFIG_CLEAN="$CONFIG_CLEAN \$(SUBDIR_TUI_CLEAN)"
3069 CONFIG_INSTALL="$CONFIG_INSTALL \$(SUBDIR_TUI_INSTALL)"
3070 CONFIG_UNINSTALL="$CONFIG_UNINSTALL \$(SUBDIR_TUI_UNINSTALL)"
3071 need_curses=yes
3072 fi
3073 fi
3074
3075 # Enable gdbtk.
3076 # Check whether --enable-gdbtk or --disable-gdbtk was given.
3077 if test "${enable_gdbtk+set}" = set; then
3078 enableval="$enable_gdbtk"
3079 case $enableval in
3080 yes | no)
3081 ;;
3082 *)
3083 { echo "configure: error: bad value $enableval for --enable-gdbtk" 1>&2; exit 1; } ;;
3084 esac
3085 else
3086 if test -d $srcdir/gdbtk; then
3087 enable_gdbtk=yes
3088 else
3089 enable_gdbtk=no
3090 fi
3091 fi
3092
3093 # We unconditionally disable gdbtk tests on selected platforms.
3094 case $host_os in
3095 go32* | windows*)
3096 echo "configure: warning: gdbtk isn't supported on $host; disabling" 1>&2
3097 enable_gdbtk=no ;;
3098 esac
3099
3100 # Profiling support.
3101 # Check whether --enable-profiling or --disable-profiling was given.
3102 if test "${enable_profiling+set}" = set; then
3103 enableval="$enable_profiling"
3104 case $enableval in
3105 yes | no)
3106 ;;
3107 *)
3108 { echo "configure: error: bad value $enableval for --enable-profile" 1>&2; exit 1; } ;;
3109 esac
3110 else
3111 enable_profiling=no
3112 fi
3113
3114
3115 for ac_func in monstartup _mcleanup
3116 do
3117 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3118 echo "configure:3119: checking for $ac_func" >&5
3119 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3120 echo $ac_n "(cached) $ac_c" 1>&6
3121 else
3122 cat > conftest.$ac_ext <<EOF
3123 #line 3124 "configure"
3124 #include "confdefs.h"
3125 /* System header to define __stub macros and hopefully few prototypes,
3126 which can conflict with char $ac_func(); below. */
3127 #include <assert.h>
3128 /* Override any gcc2 internal prototype to avoid an error. */
3129 /* We use char because int might match the return type of a gcc2
3130 builtin and then its argument prototype would still apply. */
3131 char $ac_func();
3132
3133 int main() {
3134
3135 /* The GNU C library defines this for functions which it implements
3136 to always fail with ENOSYS. Some functions are actually named
3137 something starting with __ and the normal name is an alias. */
3138 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3139 choke me
3140 #else
3141 $ac_func();
3142 #endif
3143
3144 ; return 0; }
3145 EOF
3146 if { (eval echo configure:3147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3147 rm -rf conftest*
3148 eval "ac_cv_func_$ac_func=yes"
3149 else
3150 echo "configure: failed program was:" >&5
3151 cat conftest.$ac_ext >&5
3152 rm -rf conftest*
3153 eval "ac_cv_func_$ac_func=no"
3154 fi
3155 rm -f conftest*
3156 fi
3157
3158 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3159 echo "$ac_t""yes" 1>&6
3160 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3161 cat >> confdefs.h <<EOF
3162 #define $ac_tr_func 1
3163 EOF
3164
3165 else
3166 echo "$ac_t""no" 1>&6
3167 fi
3168 done
3169
3170 echo $ac_n "checking for _etext""... $ac_c" 1>&6
3171 echo "configure:3172: checking for _etext" >&5
3172 if eval "test \"`echo '$''{'ac_cv_var__etext'+set}'`\" = set"; then
3173 echo $ac_n "(cached) $ac_c" 1>&6
3174 else
3175 cat > conftest.$ac_ext <<EOF
3176 #line 3177 "configure"
3177 #include "confdefs.h"
3178 #include <stdlib.h>
3179 extern char _etext;
3180
3181 int main() {
3182 free (&_etext);
3183 ; return 0; }
3184 EOF
3185 if { (eval echo configure:3186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3186 rm -rf conftest*
3187 ac_cv_var__etext=yes
3188 else
3189 echo "configure: failed program was:" >&5
3190 cat conftest.$ac_ext >&5
3191 rm -rf conftest*
3192 ac_cv_var__etext=no
3193 fi
3194 rm -f conftest*
3195 fi
3196
3197 echo "$ac_t""$ac_cv_var__etext" 1>&6
3198 if test $ac_cv_var__etext = yes; then
3199 cat >> confdefs.h <<\EOF
3200 #define HAVE__ETEXT 1
3201 EOF
3202
3203 fi
3204 if test "$enable_profiling" = yes ; then
3205 if test $ac_cv_func_monstartup = no || test $ac_cv_func__mcleanup = no; then
3206 { echo "configure: error: --enable-profiling requires monstartup and _mcleanup" 1>&2; exit 1; }
3207 fi
3208 PROFILE_CFLAGS=-pg
3209 OLD_CFLAGS="$CFLAGS"
3210 CFLAGS="$CFLAGS $PROFILE_CFLAGS"
3211
3212 echo $ac_n "checking whether $CC supports -pg""... $ac_c" 1>&6
3213 echo "configure:3214: checking whether $CC supports -pg" >&5
3214 if eval "test \"`echo '$''{'ac_cv_cc_supports_pg'+set}'`\" = set"; then
3215 echo $ac_n "(cached) $ac_c" 1>&6
3216 else
3217 cat > conftest.$ac_ext <<EOF
3218 #line 3219 "configure"
3219 #include "confdefs.h"
3220
3221 int main() {
3222 int x;
3223 ; return 0; }
3224 EOF
3225 if { (eval echo configure:3226: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3226 rm -rf conftest*
3227 ac_cv_cc_supports_pg=yes
3228 else
3229 echo "configure: failed program was:" >&5
3230 cat conftest.$ac_ext >&5
3231 rm -rf conftest*
3232 ac_cv_cc_supports_pg=no
3233 fi
3234 rm -f conftest*
3235 fi
3236
3237 echo "$ac_t""$ac_cv_cc_supports_pg" 1>&6
3238
3239 if test $ac_cv_cc_supports_pg = no; then
3240 { echo "configure: error: --enable-profiling requires a compiler which supports -pg" 1>&2; exit 1; }
3241 fi
3242
3243 CFLAGS="$OLD_CFLAGS"
3244 fi
3245
3246 # --------------------- #
3247 # Checks for programs. #
3248 # --------------------- #
3249
3250 for ac_prog in gawk mawk nawk awk
3251 do
3252 # Extract the first word of "$ac_prog", so it can be a program name with args.
3253 set dummy $ac_prog; ac_word=$2
3254 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3255 echo "configure:3256: checking for $ac_word" >&5
3256 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
3257 echo $ac_n "(cached) $ac_c" 1>&6
3258 else
3259 if test -n "$AWK"; then
3260 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3261 else
3262 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3263 ac_dummy="$PATH"
3264 for ac_dir in $ac_dummy; do
3265 test -z "$ac_dir" && ac_dir=.
3266 if test -f $ac_dir/$ac_word; then
3267 ac_cv_prog_AWK="$ac_prog"
3268 break
3269 fi
3270 done
3271 IFS="$ac_save_ifs"
3272 fi
3273 fi
3274 AWK="$ac_cv_prog_AWK"
3275 if test -n "$AWK"; then
3276 echo "$ac_t""$AWK" 1>&6
3277 else
3278 echo "$ac_t""no" 1>&6
3279 fi
3280
3281 test -n "$AWK" && break
3282 done
3283
3284 # Find a good install program. We prefer a C program (faster),
3285 # so one script is as good as another. But avoid the broken or
3286 # incompatible versions:
3287 # SysV /etc/install, /usr/sbin/install
3288 # SunOS /usr/etc/install
3289 # IRIX /sbin/install
3290 # AIX /bin/install
3291 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3292 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3293 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3294 # ./install, which can be erroneously created by make from ./install.sh.
3295 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
3296 echo "configure:3297: checking for a BSD compatible install" >&5
3297 if test -z "$INSTALL"; then
3298 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
3299 echo $ac_n "(cached) $ac_c" 1>&6
3300 else
3301 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
3302 for ac_dir in $PATH; do
3303 # Account for people who put trailing slashes in PATH elements.
3304 case "$ac_dir/" in
3305 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
3306 *)
3307 # OSF1 and SCO ODT 3.0 have their own names for install.
3308 # Don't use installbsd from OSF since it installs stuff as root
3309 # by default.
3310 for ac_prog in ginstall scoinst install; do
3311 if test -f $ac_dir/$ac_prog; then
3312 if test $ac_prog = install &&
3313 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
3314 # AIX install. It has an incompatible calling convention.
3315 :
3316 else
3317 ac_cv_path_install="$ac_dir/$ac_prog -c"
3318 break 2
3319 fi
3320 fi
3321 done
3322 ;;
3323 esac
3324 done
3325 IFS="$ac_save_IFS"
3326
3327 fi
3328 if test "${ac_cv_path_install+set}" = set; then
3329 INSTALL="$ac_cv_path_install"
3330 else
3331 # As a last resort, use the slow shell script. We don't cache a
3332 # path for INSTALL within a source directory, because that will
3333 # break other packages using the cache if that directory is
3334 # removed, or if the path is relative.
3335 INSTALL="$ac_install_sh"
3336 fi
3337 fi
3338 echo "$ac_t""$INSTALL" 1>&6
3339
3340 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3341 # It thinks the first close brace ends the variable substitution.
3342 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3343
3344 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
3345
3346 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3347
3348 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
3349 echo "configure:3350: checking whether ln -s works" >&5
3350 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
3351 echo $ac_n "(cached) $ac_c" 1>&6
3352 else
3353 rm -f conftestdata
3354 if ln -s X conftestdata 2>/dev/null
3355 then
3356 rm -f conftestdata
3357 ac_cv_prog_LN_S="ln -s"
3358 else
3359 ac_cv_prog_LN_S=ln
3360 fi
3361 fi
3362 LN_S="$ac_cv_prog_LN_S"
3363 if test "$ac_cv_prog_LN_S" = "ln -s"; then
3364 echo "$ac_t""yes" 1>&6
3365 else
3366 echo "$ac_t""no" 1>&6
3367 fi
3368
3369 # Extract the first word of "ranlib", so it can be a program name with args.
3370 set dummy ranlib; ac_word=$2
3371 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3372 echo "configure:3373: checking for $ac_word" >&5
3373 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
3374 echo $ac_n "(cached) $ac_c" 1>&6
3375 else
3376 if test -n "$RANLIB"; then
3377 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3378 else
3379 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3380 ac_dummy="$PATH"
3381 for ac_dir in $ac_dummy; do
3382 test -z "$ac_dir" && ac_dir=.
3383 if test -f $ac_dir/$ac_word; then
3384 ac_cv_prog_RANLIB="ranlib"
3385 break
3386 fi
3387 done
3388 IFS="$ac_save_ifs"
3389 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
3390 fi
3391 fi
3392 RANLIB="$ac_cv_prog_RANLIB"
3393 if test -n "$RANLIB"; then
3394 echo "$ac_t""$RANLIB" 1>&6
3395 else
3396 echo "$ac_t""no" 1>&6
3397 fi
3398
3399 for ac_prog in 'bison -y' byacc
3400 do
3401 # Extract the first word of "$ac_prog", so it can be a program name with args.
3402 set dummy $ac_prog; ac_word=$2
3403 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3404 echo "configure:3405: checking for $ac_word" >&5
3405 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
3406 echo $ac_n "(cached) $ac_c" 1>&6
3407 else
3408 if test -n "$YACC"; then
3409 ac_cv_prog_YACC="$YACC" # Let the user override the test.
3410 else
3411 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3412 ac_dummy="$PATH"
3413 for ac_dir in $ac_dummy; do
3414 test -z "$ac_dir" && ac_dir=.
3415 if test -f $ac_dir/$ac_word; then
3416 ac_cv_prog_YACC="$ac_prog"
3417 break
3418 fi
3419 done
3420 IFS="$ac_save_ifs"
3421 fi
3422 fi
3423 YACC="$ac_cv_prog_YACC"
3424 if test -n "$YACC"; then
3425 echo "$ac_t""$YACC" 1>&6
3426 else
3427 echo "$ac_t""no" 1>&6
3428 fi
3429
3430 test -n "$YACC" && break
3431 done
3432 test -n "$YACC" || YACC="yacc"
3433
3434
3435 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3436 set dummy ${ac_tool_prefix}ar; ac_word=$2
3437 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3438 echo "configure:3439: checking for $ac_word" >&5
3439 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
3440 echo $ac_n "(cached) $ac_c" 1>&6
3441 else
3442 if test -n "$AR"; then
3443 ac_cv_prog_AR="$AR" # Let the user override the test.
3444 else
3445 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3446 ac_dummy="$PATH"
3447 for ac_dir in $ac_dummy; do
3448 test -z "$ac_dir" && ac_dir=.
3449 if test -f $ac_dir/$ac_word; then
3450 ac_cv_prog_AR="${ac_tool_prefix}ar"
3451 break
3452 fi
3453 done
3454 IFS="$ac_save_ifs"
3455 test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
3456 fi
3457 fi
3458 AR="$ac_cv_prog_AR"
3459 if test -n "$AR"; then
3460 echo "$ac_t""$AR" 1>&6
3461 else
3462 echo "$ac_t""no" 1>&6
3463 fi
3464
3465
3466
3467 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
3468 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
3469 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3470 echo "configure:3471: checking for $ac_word" >&5
3471 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
3472 echo $ac_n "(cached) $ac_c" 1>&6
3473 else
3474 if test -n "$DLLTOOL"; then
3475 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
3476 else
3477 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3478 ac_dummy="$PATH"
3479 for ac_dir in $ac_dummy; do
3480 test -z "$ac_dir" && ac_dir=.
3481 if test -f $ac_dir/$ac_word; then
3482 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
3483 break
3484 fi
3485 done
3486 IFS="$ac_save_ifs"
3487 test -z "$ac_cv_prog_DLLTOOL" && ac_cv_prog_DLLTOOL="dlltool"
3488 fi
3489 fi
3490 DLLTOOL="$ac_cv_prog_DLLTOOL"
3491 if test -n "$DLLTOOL"; then
3492 echo "$ac_t""$DLLTOOL" 1>&6
3493 else
3494 echo "$ac_t""no" 1>&6
3495 fi
3496
3497
3498
3499 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
3500 set dummy ${ac_tool_prefix}windres; ac_word=$2
3501 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3502 echo "configure:3503: checking for $ac_word" >&5
3503 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
3504 echo $ac_n "(cached) $ac_c" 1>&6
3505 else
3506 if test -n "$WINDRES"; then
3507 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
3508 else
3509 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3510 ac_dummy="$PATH"
3511 for ac_dir in $ac_dummy; do
3512 test -z "$ac_dir" && ac_dir=.
3513 if test -f $ac_dir/$ac_word; then
3514 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
3515 break
3516 fi
3517 done
3518 IFS="$ac_save_ifs"
3519 test -z "$ac_cv_prog_WINDRES" && ac_cv_prog_WINDRES="windres"
3520 fi
3521 fi
3522 WINDRES="$ac_cv_prog_WINDRES"
3523 if test -n "$WINDRES"; then
3524 echo "$ac_t""$WINDRES" 1>&6
3525 else
3526 echo "$ac_t""no" 1>&6
3527 fi
3528
3529
3530
3531
3532 # Needed for GNU/Hurd.
3533 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
3534 set dummy ${ac_tool_prefix}mig; ac_word=$2
3535 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3536 echo "configure:3537: checking for $ac_word" >&5
3537 if eval "test \"`echo '$''{'ac_cv_prog_MIG'+set}'`\" = set"; then
3538 echo $ac_n "(cached) $ac_c" 1>&6
3539 else
3540 if test -n "$MIG"; then
3541 ac_cv_prog_MIG="$MIG" # Let the user override the test.
3542 else
3543 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3544 ac_dummy="$PATH"
3545 for ac_dir in $ac_dummy; do
3546 test -z "$ac_dir" && ac_dir=.
3547 if test -f $ac_dir/$ac_word; then
3548 ac_cv_prog_MIG="${ac_tool_prefix}mig"
3549 break
3550 fi
3551 done
3552 IFS="$ac_save_ifs"
3553 test -z "$ac_cv_prog_MIG" && ac_cv_prog_MIG="mig"
3554 fi
3555 fi
3556 MIG="$ac_cv_prog_MIG"
3557 if test -n "$MIG"; then
3558 echo "$ac_t""$MIG" 1>&6
3559 else
3560 echo "$ac_t""no" 1>&6
3561 fi
3562
3563
3564
3565
3566 # ---------------------- #
3567 # Checks for libraries. #
3568 # ---------------------- #
3569
3570 # We might need to link with -lm; most simulators need it.
3571 echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
3572 echo "configure:3573: checking for main in -lm" >&5
3573 ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
3574 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3575 echo $ac_n "(cached) $ac_c" 1>&6
3576 else
3577 ac_save_LIBS="$LIBS"
3578 LIBS="-lm $LIBS"
3579 cat > conftest.$ac_ext <<EOF
3580 #line 3581 "configure"
3581 #include "confdefs.h"
3582
3583 int main() {
3584 main()
3585 ; return 0; }
3586 EOF
3587 if { (eval echo configure:3588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3588 rm -rf conftest*
3589 eval "ac_cv_lib_$ac_lib_var=yes"
3590 else
3591 echo "configure: failed program was:" >&5
3592 cat conftest.$ac_ext >&5
3593 rm -rf conftest*
3594 eval "ac_cv_lib_$ac_lib_var=no"
3595 fi
3596 rm -f conftest*
3597 LIBS="$ac_save_LIBS"
3598
3599 fi
3600 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3601 echo "$ac_t""yes" 1>&6
3602 ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3603 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3604 cat >> confdefs.h <<EOF
3605 #define $ac_tr_lib 1
3606 EOF
3607
3608 LIBS="-lm $LIBS"
3609
3610 else
3611 echo "$ac_t""no" 1>&6
3612 fi
3613
3614
3615 # We need to link with -lw to get `wctype' on Solaris before Solaris
3616 # 2.6. Solaris 2.6 and beyond have this function in libc, and have a
3617 # libw that some versions of the GNU linker cannot hanle (GNU ld 2.9.1
3618 # is known to have this problem). Therefore we avoid libw if we can.
3619 echo $ac_n "checking for wctype""... $ac_c" 1>&6
3620 echo "configure:3621: checking for wctype" >&5
3621 if eval "test \"`echo '$''{'ac_cv_func_wctype'+set}'`\" = set"; then
3622 echo $ac_n "(cached) $ac_c" 1>&6
3623 else
3624 cat > conftest.$ac_ext <<EOF
3625 #line 3626 "configure"
3626 #include "confdefs.h"
3627 /* System header to define __stub macros and hopefully few prototypes,
3628 which can conflict with char wctype(); below. */
3629 #include <assert.h>
3630 /* Override any gcc2 internal prototype to avoid an error. */
3631 /* We use char because int might match the return type of a gcc2
3632 builtin and then its argument prototype would still apply. */
3633 char wctype();
3634
3635 int main() {
3636
3637 /* The GNU C library defines this for functions which it implements
3638 to always fail with ENOSYS. Some functions are actually named
3639 something starting with __ and the normal name is an alias. */
3640 #if defined (__stub_wctype) || defined (__stub___wctype)
3641 choke me
3642 #else
3643 wctype();
3644 #endif
3645
3646 ; return 0; }
3647 EOF
3648 if { (eval echo configure:3649: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3649 rm -rf conftest*
3650 eval "ac_cv_func_wctype=yes"
3651 else
3652 echo "configure: failed program was:" >&5
3653 cat conftest.$ac_ext >&5
3654 rm -rf conftest*
3655 eval "ac_cv_func_wctype=no"
3656 fi
3657 rm -f conftest*
3658 fi
3659
3660 if eval "test \"`echo '$ac_cv_func_'wctype`\" = yes"; then
3661 echo "$ac_t""yes" 1>&6
3662 :
3663 else
3664 echo "$ac_t""no" 1>&6
3665 echo $ac_n "checking for wctype in -lw""... $ac_c" 1>&6
3666 echo "configure:3667: checking for wctype in -lw" >&5
3667 ac_lib_var=`echo w'_'wctype | sed 'y%./+-%__p_%'`
3668 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3669 echo $ac_n "(cached) $ac_c" 1>&6
3670 else
3671 ac_save_LIBS="$LIBS"
3672 LIBS="-lw $LIBS"
3673 cat > conftest.$ac_ext <<EOF
3674 #line 3675 "configure"
3675 #include "confdefs.h"
3676 /* Override any gcc2 internal prototype to avoid an error. */
3677 /* We use char because int might match the return type of a gcc2
3678 builtin and then its argument prototype would still apply. */
3679 char wctype();
3680
3681 int main() {
3682 wctype()
3683 ; return 0; }
3684 EOF
3685 if { (eval echo configure:3686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3686 rm -rf conftest*
3687 eval "ac_cv_lib_$ac_lib_var=yes"
3688 else
3689 echo "configure: failed program was:" >&5
3690 cat conftest.$ac_ext >&5
3691 rm -rf conftest*
3692 eval "ac_cv_lib_$ac_lib_var=no"
3693 fi
3694 rm -f conftest*
3695 LIBS="$ac_save_LIBS"
3696
3697 fi
3698 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3699 echo "$ac_t""yes" 1>&6
3700 ac_tr_lib=HAVE_LIB`echo w | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3701 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3702 cat >> confdefs.h <<EOF
3703 #define $ac_tr_lib 1
3704 EOF
3705
3706 LIBS="-lw $LIBS"
3707
3708 else
3709 echo "$ac_t""no" 1>&6
3710 fi
3711
3712 fi
3713
3714
3715 # Some systems (e.g. Solaris) have `socketpair' in libsocket.
3716
3717 echo $ac_n "checking for library containing socketpair""... $ac_c" 1>&6
3718 echo "configure:3719: checking for library containing socketpair" >&5
3719 if eval "test \"`echo '$''{'ac_cv_search_socketpair'+set}'`\" = set"; then
3720 echo $ac_n "(cached) $ac_c" 1>&6
3721 else
3722 ac_func_search_save_LIBS="$LIBS"
3723 ac_cv_search_socketpair="no"
3724 cat > conftest.$ac_ext <<EOF
3725 #line 3726 "configure"
3726 #include "confdefs.h"
3727 /* Override any gcc2 internal prototype to avoid an error. */
3728 /* We use char because int might match the return type of a gcc2
3729 builtin and then its argument prototype would still apply. */
3730 char socketpair();
3731
3732 int main() {
3733 socketpair()
3734 ; return 0; }
3735 EOF
3736 if { (eval echo configure:3737: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3737 rm -rf conftest*
3738 ac_cv_search_socketpair="none required"
3739 else
3740 echo "configure: failed program was:" >&5
3741 cat conftest.$ac_ext >&5
3742 fi
3743 rm -f conftest*
3744 test "$ac_cv_search_socketpair" = "no" && for i in socket; do
3745 LIBS="-l$i $ac_func_search_save_LIBS"
3746 cat > conftest.$ac_ext <<EOF
3747 #line 3748 "configure"
3748 #include "confdefs.h"
3749 /* Override any gcc2 internal prototype to avoid an error. */
3750 /* We use char because int might match the return type of a gcc2
3751 builtin and then its argument prototype would still apply. */
3752 char socketpair();
3753
3754 int main() {
3755 socketpair()
3756 ; return 0; }
3757 EOF
3758 if { (eval echo configure:3759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3759 rm -rf conftest*
3760 ac_cv_search_socketpair="-l$i"
3761 break
3762 else
3763 echo "configure: failed program was:" >&5
3764 cat conftest.$ac_ext >&5
3765 fi
3766 rm -f conftest*
3767 done
3768 LIBS="$ac_func_search_save_LIBS"
3769 fi
3770
3771 echo "$ac_t""$ac_cv_search_socketpair" 1>&6
3772 if test "$ac_cv_search_socketpair" != "no"; then
3773 test "$ac_cv_search_socketpair" = "none required" || LIBS="$ac_cv_search_socketpair $LIBS"
3774
3775 else :
3776
3777 fi
3778
3779 # Since GDB uses Readline, we need termcap functionality, so we need
3780 # to find a library that provides that. When GDB is configured with
3781 # --enable-tui, we need full curses functionality.
3782 #
3783 # FIXME: kettenis/20030102: We seem to prefer HP curses (Hcurses) over
3784 # Xcurses on HP-UX; see the `-D__HP_CURSES' in the relevant host
3785 # Makefile fragments. That's why we need to have `Hcurses' before
3786 # `curses'. I don't see why we should use HP curses if a more
3787 # standard curses is available, except that according to HP's
3788 # documentation one needs to compile `-D_XOPEN_SOURCE_EXTENDED' on
3789 # HP-UX 10.10 and 10.20.
3790
3791 if test "$need_curses" = yes; then
3792
3793 echo $ac_n "checking for library containing initscr""... $ac_c" 1>&6
3794 echo "configure:3795: checking for library containing initscr" >&5
3795 if eval "test \"`echo '$''{'ac_cv_search_initscr'+set}'`\" = set"; then
3796 echo $ac_n "(cached) $ac_c" 1>&6
3797 else
3798 ac_func_search_save_LIBS="$LIBS"
3799 ac_cv_search_initscr="no"
3800 cat > conftest.$ac_ext <<EOF
3801 #line 3802 "configure"
3802 #include "confdefs.h"
3803 /* Override any gcc2 internal prototype to avoid an error. */
3804 /* We use char because int might match the return type of a gcc2
3805 builtin and then its argument prototype would still apply. */
3806 char initscr();
3807
3808 int main() {
3809 initscr()
3810 ; return 0; }
3811 EOF
3812 if { (eval echo configure:3813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3813 rm -rf conftest*
3814 ac_cv_search_initscr="none required"
3815 else
3816 echo "configure: failed program was:" >&5
3817 cat conftest.$ac_ext >&5
3818 fi
3819 rm -f conftest*
3820 test "$ac_cv_search_initscr" = "no" && for i in ncurses Hcurses curses; do
3821 LIBS="-l$i $ac_func_search_save_LIBS"
3822 cat > conftest.$ac_ext <<EOF
3823 #line 3824 "configure"
3824 #include "confdefs.h"
3825 /* Override any gcc2 internal prototype to avoid an error. */
3826 /* We use char because int might match the return type of a gcc2
3827 builtin and then its argument prototype would still apply. */
3828 char initscr();
3829
3830 int main() {
3831 initscr()
3832 ; return 0; }
3833 EOF
3834 if { (eval echo configure:3835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3835 rm -rf conftest*
3836 ac_cv_search_initscr="-l$i"
3837 break
3838 else
3839 echo "configure: failed program was:" >&5
3840 cat conftest.$ac_ext >&5
3841 fi
3842 rm -f conftest*
3843 done
3844 LIBS="$ac_func_search_save_LIBS"
3845 fi
3846
3847 echo "$ac_t""$ac_cv_search_initscr" 1>&6
3848 if test "$ac_cv_search_initscr" != "no"; then
3849 test "$ac_cv_search_initscr" = "none required" || LIBS="$ac_cv_search_initscr $LIBS"
3850
3851 else :
3852 { echo "configure: error: no curses library found" 1>&2; exit 1; }
3853 fi
3854 fi
3855
3856 case $host_os in
3857 cygwin*)
3858 if test -d $srcdir/libtermcap; then
3859 LIBS="../libtermcap/libtermcap.a $LIBS"
3860 ac_cv_search_tgetent="../libtermcap/libtermcap.a"
3861 fi ;;
3862 go32*)
3863 # ??? Is this really true?
3864 ac_cv_search_tgetent="none required"
3865 ;;
3866 aix*)
3867 # Readline prefers curses over termcap on AIX.
3868 # ??? Why?
3869
3870 echo $ac_n "checking for library containing tgetent""... $ac_c" 1>&6
3871 echo "configure:3872: checking for library containing tgetent" >&5
3872 if eval "test \"`echo '$''{'ac_cv_search_tgetent'+set}'`\" = set"; then
3873 echo $ac_n "(cached) $ac_c" 1>&6
3874 else
3875 ac_func_search_save_LIBS="$LIBS"
3876 ac_cv_search_tgetent="no"
3877 cat > conftest.$ac_ext <<EOF
3878 #line 3879 "configure"
3879 #include "confdefs.h"
3880 /* Override any gcc2 internal prototype to avoid an error. */
3881 /* We use char because int might match the return type of a gcc2
3882 builtin and then its argument prototype would still apply. */
3883 char tgetent();
3884
3885 int main() {
3886 tgetent()
3887 ; return 0; }
3888 EOF
3889 if { (eval echo configure:3890: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3890 rm -rf conftest*
3891 ac_cv_search_tgetent="none required"
3892 else
3893 echo "configure: failed program was:" >&5
3894 cat conftest.$ac_ext >&5
3895 fi
3896 rm -f conftest*
3897 test "$ac_cv_search_tgetent" = "no" && for i in tinfo ncurses curses termcap; do
3898 LIBS="-l$i $ac_func_search_save_LIBS"
3899 cat > conftest.$ac_ext <<EOF
3900 #line 3901 "configure"
3901 #include "confdefs.h"
3902 /* Override any gcc2 internal prototype to avoid an error. */
3903 /* We use char because int might match the return type of a gcc2
3904 builtin and then its argument prototype would still apply. */
3905 char tgetent();
3906
3907 int main() {
3908 tgetent()
3909 ; return 0; }
3910 EOF
3911 if { (eval echo configure:3912: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3912 rm -rf conftest*
3913 ac_cv_search_tgetent="-l$i"
3914 break
3915 else
3916 echo "configure: failed program was:" >&5
3917 cat conftest.$ac_ext >&5
3918 fi
3919 rm -f conftest*
3920 done
3921 LIBS="$ac_func_search_save_LIBS"
3922 fi
3923
3924 echo "$ac_t""$ac_cv_search_tgetent" 1>&6
3925 if test "$ac_cv_search_tgetent" != "no"; then
3926 test "$ac_cv_search_tgetent" = "none required" || LIBS="$ac_cv_search_tgetent $LIBS"
3927
3928 else :
3929
3930 fi
3931 ;;
3932 esac
3933
3934 # Note: We used to check for libtermlib and libterminfo too, but
3935 # Readline doesn't, so I think we're safe with leaving them out.
3936
3937 echo $ac_n "checking for library containing tgetent""... $ac_c" 1>&6
3938 echo "configure:3939: checking for library containing tgetent" >&5
3939 if eval "test \"`echo '$''{'ac_cv_search_tgetent'+set}'`\" = set"; then
3940 echo $ac_n "(cached) $ac_c" 1>&6
3941 else
3942 ac_func_search_save_LIBS="$LIBS"
3943 ac_cv_search_tgetent="no"
3944 cat > conftest.$ac_ext <<EOF
3945 #line 3946 "configure"
3946 #include "confdefs.h"
3947 /* Override any gcc2 internal prototype to avoid an error. */
3948 /* We use char because int might match the return type of a gcc2
3949 builtin and then its argument prototype would still apply. */
3950 char tgetent();
3951
3952 int main() {
3953 tgetent()
3954 ; return 0; }
3955 EOF
3956 if { (eval echo configure:3957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3957 rm -rf conftest*
3958 ac_cv_search_tgetent="none required"
3959 else
3960 echo "configure: failed program was:" >&5
3961 cat conftest.$ac_ext >&5
3962 fi
3963 rm -f conftest*
3964 test "$ac_cv_search_tgetent" = "no" && for i in termcap tinfo ncurses Hcurses curses; do
3965 LIBS="-l$i $ac_func_search_save_LIBS"
3966 cat > conftest.$ac_ext <<EOF
3967 #line 3968 "configure"
3968 #include "confdefs.h"
3969 /* Override any gcc2 internal prototype to avoid an error. */
3970 /* We use char because int might match the return type of a gcc2
3971 builtin and then its argument prototype would still apply. */
3972 char tgetent();
3973
3974 int main() {
3975 tgetent()
3976 ; return 0; }
3977 EOF
3978 if { (eval echo configure:3979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3979 rm -rf conftest*
3980 ac_cv_search_tgetent="-l$i"
3981 break
3982 else
3983 echo "configure: failed program was:" >&5
3984 cat conftest.$ac_ext >&5
3985 fi
3986 rm -f conftest*
3987 done
3988 LIBS="$ac_func_search_save_LIBS"
3989 fi
3990
3991 echo "$ac_t""$ac_cv_search_tgetent" 1>&6
3992 if test "$ac_cv_search_tgetent" != "no"; then
3993 test "$ac_cv_search_tgetent" = "none required" || LIBS="$ac_cv_search_tgetent $LIBS"
3994
3995 else :
3996
3997 fi
3998
3999 if test "$ac_cv_search_tgetent" = no; then
4000 { echo "configure: error: no termcap library found" 1>&2; exit 1; }
4001 fi
4002
4003 # ------------------------- #
4004 # Checks for header files. #
4005 # ------------------------- #
4006
4007 ac_header_dirent=no
4008 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
4009 do
4010 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4011 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
4012 echo "configure:4013: checking for $ac_hdr that defines DIR" >&5
4013 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
4014 echo $ac_n "(cached) $ac_c" 1>&6
4015 else
4016 cat > conftest.$ac_ext <<EOF
4017 #line 4018 "configure"
4018 #include "confdefs.h"
4019 #include <sys/types.h>
4020 #include <$ac_hdr>
4021 int main() {
4022 DIR *dirp = 0;
4023 ; return 0; }
4024 EOF
4025 if { (eval echo configure:4026: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4026 rm -rf conftest*
4027 eval "ac_cv_header_dirent_$ac_safe=yes"
4028 else
4029 echo "configure: failed program was:" >&5
4030 cat conftest.$ac_ext >&5
4031 rm -rf conftest*
4032 eval "ac_cv_header_dirent_$ac_safe=no"
4033 fi
4034 rm -f conftest*
4035 fi
4036 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
4037 echo "$ac_t""yes" 1>&6
4038 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4039 cat >> confdefs.h <<EOF
4040 #define $ac_tr_hdr 1
4041 EOF
4042 ac_header_dirent=$ac_hdr; break
4043 else
4044 echo "$ac_t""no" 1>&6
4045 fi
4046 done
4047 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4048 if test $ac_header_dirent = dirent.h; then
4049 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
4050 echo "configure:4051: checking for opendir in -ldir" >&5
4051 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
4052 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4053 echo $ac_n "(cached) $ac_c" 1>&6
4054 else
4055 ac_save_LIBS="$LIBS"
4056 LIBS="-ldir $LIBS"
4057 cat > conftest.$ac_ext <<EOF
4058 #line 4059 "configure"
4059 #include "confdefs.h"
4060 /* Override any gcc2 internal prototype to avoid an error. */
4061 /* We use char because int might match the return type of a gcc2
4062 builtin and then its argument prototype would still apply. */
4063 char opendir();
4064
4065 int main() {
4066 opendir()
4067 ; return 0; }
4068 EOF
4069 if { (eval echo configure:4070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4070 rm -rf conftest*
4071 eval "ac_cv_lib_$ac_lib_var=yes"
4072 else
4073 echo "configure: failed program was:" >&5
4074 cat conftest.$ac_ext >&5
4075 rm -rf conftest*
4076 eval "ac_cv_lib_$ac_lib_var=no"
4077 fi
4078 rm -f conftest*
4079 LIBS="$ac_save_LIBS"
4080
4081 fi
4082 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4083 echo "$ac_t""yes" 1>&6
4084 LIBS="$LIBS -ldir"
4085 else
4086 echo "$ac_t""no" 1>&6
4087 fi
4088
4089 else
4090 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
4091 echo "configure:4092: checking for opendir in -lx" >&5
4092 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
4093 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4094 echo $ac_n "(cached) $ac_c" 1>&6
4095 else
4096 ac_save_LIBS="$LIBS"
4097 LIBS="-lx $LIBS"
4098 cat > conftest.$ac_ext <<EOF
4099 #line 4100 "configure"
4100 #include "confdefs.h"
4101 /* Override any gcc2 internal prototype to avoid an error. */
4102 /* We use char because int might match the return type of a gcc2
4103 builtin and then its argument prototype would still apply. */
4104 char opendir();
4105
4106 int main() {
4107 opendir()
4108 ; return 0; }
4109 EOF
4110 if { (eval echo configure:4111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4111 rm -rf conftest*
4112 eval "ac_cv_lib_$ac_lib_var=yes"
4113 else
4114 echo "configure: failed program was:" >&5
4115 cat conftest.$ac_ext >&5
4116 rm -rf conftest*
4117 eval "ac_cv_lib_$ac_lib_var=no"
4118 fi
4119 rm -f conftest*
4120 LIBS="$ac_save_LIBS"
4121
4122 fi
4123 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4124 echo "$ac_t""yes" 1>&6
4125 LIBS="$LIBS -lx"
4126 else
4127 echo "$ac_t""no" 1>&6
4128 fi
4129
4130 fi
4131
4132 echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
4133 echo "configure:4134: checking whether stat file-mode macros are broken" >&5
4134 if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
4135 echo $ac_n "(cached) $ac_c" 1>&6
4136 else
4137 cat > conftest.$ac_ext <<EOF
4138 #line 4139 "configure"
4139 #include "confdefs.h"
4140 #include <sys/types.h>
4141 #include <sys/stat.h>
4142
4143 #if defined(S_ISBLK) && defined(S_IFDIR)
4144 # if S_ISBLK (S_IFDIR)
4145 You lose.
4146 # endif
4147 #endif
4148
4149 #if defined(S_ISBLK) && defined(S_IFCHR)
4150 # if S_ISBLK (S_IFCHR)
4151 You lose.
4152 # endif
4153 #endif
4154
4155 #if defined(S_ISLNK) && defined(S_IFREG)
4156 # if S_ISLNK (S_IFREG)
4157 You lose.
4158 # endif
4159 #endif
4160
4161 #if defined(S_ISSOCK) && defined(S_IFREG)
4162 # if S_ISSOCK (S_IFREG)
4163 You lose.
4164 # endif
4165 #endif
4166
4167 EOF
4168 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4169 egrep "You lose" >/dev/null 2>&1; then
4170 rm -rf conftest*
4171 ac_cv_header_stat_broken=yes
4172 else
4173 rm -rf conftest*
4174 ac_cv_header_stat_broken=no
4175 fi
4176 rm -f conftest*
4177
4178 fi
4179
4180 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
4181 if test $ac_cv_header_stat_broken = yes; then
4182 cat >> confdefs.h <<\EOF
4183 #define STAT_MACROS_BROKEN 1
4184 EOF
4185
4186 fi
4187
4188 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
4189 echo "configure:4190: checking for ANSI C header files" >&5
4190 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
4191 echo $ac_n "(cached) $ac_c" 1>&6
4192 else
4193 cat > conftest.$ac_ext <<EOF
4194 #line 4195 "configure"
4195 #include "confdefs.h"
4196 #include <stdlib.h>
4197 #include <stdarg.h>
4198 #include <string.h>
4199 #include <float.h>
4200 EOF
4201 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4202 { (eval echo configure:4203: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4203 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4204 if test -z "$ac_err"; then
4205 rm -rf conftest*
4206 ac_cv_header_stdc=yes
4207 else
4208 echo "$ac_err" >&5
4209 echo "configure: failed program was:" >&5
4210 cat conftest.$ac_ext >&5
4211 rm -rf conftest*
4212 ac_cv_header_stdc=no
4213 fi
4214 rm -f conftest*
4215
4216 if test $ac_cv_header_stdc = yes; then
4217 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4218 cat > conftest.$ac_ext <<EOF
4219 #line 4220 "configure"
4220 #include "confdefs.h"
4221 #include <string.h>
4222 EOF
4223 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4224 egrep "memchr" >/dev/null 2>&1; then
4225 :
4226 else
4227 rm -rf conftest*
4228 ac_cv_header_stdc=no
4229 fi
4230 rm -f conftest*
4231
4232 fi
4233
4234 if test $ac_cv_header_stdc = yes; then
4235 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4236 cat > conftest.$ac_ext <<EOF
4237 #line 4238 "configure"
4238 #include "confdefs.h"
4239 #include <stdlib.h>
4240 EOF
4241 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4242 egrep "free" >/dev/null 2>&1; then
4243 :
4244 else
4245 rm -rf conftest*
4246 ac_cv_header_stdc=no
4247 fi
4248 rm -f conftest*
4249
4250 fi
4251
4252 if test $ac_cv_header_stdc = yes; then
4253 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4254 if test "$cross_compiling" = yes; then
4255 :
4256 else
4257 cat > conftest.$ac_ext <<EOF
4258 #line 4259 "configure"
4259 #include "confdefs.h"
4260 #include <ctype.h>
4261 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4262 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4263 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4264 int main () { int i; for (i = 0; i < 256; i++)
4265 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
4266 exit (0); }
4267
4268 EOF
4269 if { (eval echo configure:4270: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4270 then
4271 :
4272 else
4273 echo "configure: failed program was:" >&5
4274 cat conftest.$ac_ext >&5
4275 rm -fr conftest*
4276 ac_cv_header_stdc=no
4277 fi
4278 rm -fr conftest*
4279 fi
4280
4281 fi
4282 fi
4283
4284 echo "$ac_t""$ac_cv_header_stdc" 1>&6
4285 if test $ac_cv_header_stdc = yes; then
4286 cat >> confdefs.h <<\EOF
4287 #define STDC_HEADERS 1
4288 EOF
4289
4290 fi
4291
4292 for ac_hdr in link.h
4293 do
4294 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4295 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4296 echo "configure:4297: checking for $ac_hdr" >&5
4297 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4298 echo $ac_n "(cached) $ac_c" 1>&6
4299 else
4300 cat > conftest.$ac_ext <<EOF
4301 #line 4302 "configure"
4302 #include "confdefs.h"
4303 #include <$ac_hdr>
4304 EOF
4305 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4306 { (eval echo configure:4307: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4307 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4308 if test -z "$ac_err"; then
4309 rm -rf conftest*
4310 eval "ac_cv_header_$ac_safe=yes"
4311 else
4312 echo "$ac_err" >&5
4313 echo "configure: failed program was:" >&5
4314 cat conftest.$ac_ext >&5
4315 rm -rf conftest*
4316 eval "ac_cv_header_$ac_safe=no"
4317 fi
4318 rm -f conftest*
4319 fi
4320 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4321 echo "$ac_t""yes" 1>&6
4322 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4323 cat >> confdefs.h <<EOF
4324 #define $ac_tr_hdr 1
4325 EOF
4326
4327 else
4328 echo "$ac_t""no" 1>&6
4329 fi
4330 done
4331
4332 for ac_hdr in nlist.h
4333 do
4334 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4335 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4336 echo "configure:4337: checking for $ac_hdr" >&5
4337 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4338 echo $ac_n "(cached) $ac_c" 1>&6
4339 else
4340 cat > conftest.$ac_ext <<EOF
4341 #line 4342 "configure"
4342 #include "confdefs.h"
4343 #include <$ac_hdr>
4344 EOF
4345 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4346 { (eval echo configure:4347: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4347 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4348 if test -z "$ac_err"; then
4349 rm -rf conftest*
4350 eval "ac_cv_header_$ac_safe=yes"
4351 else
4352 echo "$ac_err" >&5
4353 echo "configure: failed program was:" >&5
4354 cat conftest.$ac_ext >&5
4355 rm -rf conftest*
4356 eval "ac_cv_header_$ac_safe=no"
4357 fi
4358 rm -f conftest*
4359 fi
4360 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4361 echo "$ac_t""yes" 1>&6
4362 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4363 cat >> confdefs.h <<EOF
4364 #define $ac_tr_hdr 1
4365 EOF
4366
4367 else
4368 echo "$ac_t""no" 1>&6
4369 fi
4370 done
4371
4372 for ac_hdr in poll.h sys/poll.h
4373 do
4374 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4375 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4376 echo "configure:4377: checking for $ac_hdr" >&5
4377 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4378 echo $ac_n "(cached) $ac_c" 1>&6
4379 else
4380 cat > conftest.$ac_ext <<EOF
4381 #line 4382 "configure"
4382 #include "confdefs.h"
4383 #include <$ac_hdr>
4384 EOF
4385 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4386 { (eval echo configure:4387: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4387 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4388 if test -z "$ac_err"; then
4389 rm -rf conftest*
4390 eval "ac_cv_header_$ac_safe=yes"
4391 else
4392 echo "$ac_err" >&5
4393 echo "configure: failed program was:" >&5
4394 cat conftest.$ac_ext >&5
4395 rm -rf conftest*
4396 eval "ac_cv_header_$ac_safe=no"
4397 fi
4398 rm -f conftest*
4399 fi
4400 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4401 echo "$ac_t""yes" 1>&6
4402 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4403 cat >> confdefs.h <<EOF
4404 #define $ac_tr_hdr 1
4405 EOF
4406
4407 else
4408 echo "$ac_t""no" 1>&6
4409 fi
4410 done
4411
4412 for ac_hdr in proc_service.h thread_db.h
4413 do
4414 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4415 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4416 echo "configure:4417: checking for $ac_hdr" >&5
4417 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4418 echo $ac_n "(cached) $ac_c" 1>&6
4419 else
4420 cat > conftest.$ac_ext <<EOF
4421 #line 4422 "configure"
4422 #include "confdefs.h"
4423 #include <$ac_hdr>
4424 EOF
4425 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4426 { (eval echo configure:4427: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4427 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4428 if test -z "$ac_err"; then
4429 rm -rf conftest*
4430 eval "ac_cv_header_$ac_safe=yes"
4431 else
4432 echo "$ac_err" >&5
4433 echo "configure: failed program was:" >&5
4434 cat conftest.$ac_ext >&5
4435 rm -rf conftest*
4436 eval "ac_cv_header_$ac_safe=no"
4437 fi
4438 rm -f conftest*
4439 fi
4440 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4441 echo "$ac_t""yes" 1>&6
4442 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4443 cat >> confdefs.h <<EOF
4444 #define $ac_tr_hdr 1
4445 EOF
4446
4447 else
4448 echo "$ac_t""no" 1>&6
4449 fi
4450 done
4451
4452 for ac_hdr in stddef.h
4453 do
4454 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4455 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4456 echo "configure:4457: checking for $ac_hdr" >&5
4457 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4458 echo $ac_n "(cached) $ac_c" 1>&6
4459 else
4460 cat > conftest.$ac_ext <<EOF
4461 #line 4462 "configure"
4462 #include "confdefs.h"
4463 #include <$ac_hdr>
4464 EOF
4465 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4466 { (eval echo configure:4467: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4467 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4468 if test -z "$ac_err"; then
4469 rm -rf conftest*
4470 eval "ac_cv_header_$ac_safe=yes"
4471 else
4472 echo "$ac_err" >&5
4473 echo "configure: failed program was:" >&5
4474 cat conftest.$ac_ext >&5
4475 rm -rf conftest*
4476 eval "ac_cv_header_$ac_safe=no"
4477 fi
4478 rm -f conftest*
4479 fi
4480 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4481 echo "$ac_t""yes" 1>&6
4482 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4483 cat >> confdefs.h <<EOF
4484 #define $ac_tr_hdr 1
4485 EOF
4486
4487 else
4488 echo "$ac_t""no" 1>&6
4489 fi
4490 done
4491
4492 for ac_hdr in stdlib.h
4493 do
4494 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4495 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4496 echo "configure:4497: checking for $ac_hdr" >&5
4497 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4498 echo $ac_n "(cached) $ac_c" 1>&6
4499 else
4500 cat > conftest.$ac_ext <<EOF
4501 #line 4502 "configure"
4502 #include "confdefs.h"
4503 #include <$ac_hdr>
4504 EOF
4505 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4506 { (eval echo configure:4507: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4507 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4508 if test -z "$ac_err"; then
4509 rm -rf conftest*
4510 eval "ac_cv_header_$ac_safe=yes"
4511 else
4512 echo "$ac_err" >&5
4513 echo "configure: failed program was:" >&5
4514 cat conftest.$ac_ext >&5
4515 rm -rf conftest*
4516 eval "ac_cv_header_$ac_safe=no"
4517 fi
4518 rm -f conftest*
4519 fi
4520 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4521 echo "$ac_t""yes" 1>&6
4522 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4523 cat >> confdefs.h <<EOF
4524 #define $ac_tr_hdr 1
4525 EOF
4526
4527 else
4528 echo "$ac_t""no" 1>&6
4529 fi
4530 done
4531
4532 for ac_hdr in stdint.h
4533 do
4534 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4535 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4536 echo "configure:4537: checking for $ac_hdr" >&5
4537 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4538 echo $ac_n "(cached) $ac_c" 1>&6
4539 else
4540 cat > conftest.$ac_ext <<EOF
4541 #line 4542 "configure"
4542 #include "confdefs.h"
4543 #include <$ac_hdr>
4544 EOF
4545 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4546 { (eval echo configure:4547: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4547 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4548 if test -z "$ac_err"; then
4549 rm -rf conftest*
4550 eval "ac_cv_header_$ac_safe=yes"
4551 else
4552 echo "$ac_err" >&5
4553 echo "configure: failed program was:" >&5
4554 cat conftest.$ac_ext >&5
4555 rm -rf conftest*
4556 eval "ac_cv_header_$ac_safe=no"
4557 fi
4558 rm -f conftest*
4559 fi
4560 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4561 echo "$ac_t""yes" 1>&6
4562 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4563 cat >> confdefs.h <<EOF
4564 #define $ac_tr_hdr 1
4565 EOF
4566
4567 else
4568 echo "$ac_t""no" 1>&6
4569 fi
4570 done
4571
4572 for ac_hdr in string.h memory.h strings.h
4573 do
4574 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4575 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4576 echo "configure:4577: checking for $ac_hdr" >&5
4577 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4578 echo $ac_n "(cached) $ac_c" 1>&6
4579 else
4580 cat > conftest.$ac_ext <<EOF
4581 #line 4582 "configure"
4582 #include "confdefs.h"
4583 #include <$ac_hdr>
4584 EOF
4585 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4586 { (eval echo configure:4587: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4587 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4588 if test -z "$ac_err"; then
4589 rm -rf conftest*
4590 eval "ac_cv_header_$ac_safe=yes"
4591 else
4592 echo "$ac_err" >&5
4593 echo "configure: failed program was:" >&5
4594 cat conftest.$ac_ext >&5
4595 rm -rf conftest*
4596 eval "ac_cv_header_$ac_safe=no"
4597 fi
4598 rm -f conftest*
4599 fi
4600 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4601 echo "$ac_t""yes" 1>&6
4602 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4603 cat >> confdefs.h <<EOF
4604 #define $ac_tr_hdr 1
4605 EOF
4606
4607 else
4608 echo "$ac_t""no" 1>&6
4609 fi
4610 done
4611
4612 for ac_hdr in sys/fault.h
4613 do
4614 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4615 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4616 echo "configure:4617: checking for $ac_hdr" >&5
4617 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4618 echo $ac_n "(cached) $ac_c" 1>&6
4619 else
4620 cat > conftest.$ac_ext <<EOF
4621 #line 4622 "configure"
4622 #include "confdefs.h"
4623 #include <$ac_hdr>
4624 EOF
4625 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4626 { (eval echo configure:4627: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4627 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4628 if test -z "$ac_err"; then
4629 rm -rf conftest*
4630 eval "ac_cv_header_$ac_safe=yes"
4631 else
4632 echo "$ac_err" >&5
4633 echo "configure: failed program was:" >&5
4634 cat conftest.$ac_ext >&5
4635 rm -rf conftest*
4636 eval "ac_cv_header_$ac_safe=no"
4637 fi
4638 rm -f conftest*
4639 fi
4640 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4641 echo "$ac_t""yes" 1>&6
4642 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4643 cat >> confdefs.h <<EOF
4644 #define $ac_tr_hdr 1
4645 EOF
4646
4647 else
4648 echo "$ac_t""no" 1>&6
4649 fi
4650 done
4651
4652 for ac_hdr in sys/file.h
4653 do
4654 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4655 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4656 echo "configure:4657: checking for $ac_hdr" >&5
4657 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4658 echo $ac_n "(cached) $ac_c" 1>&6
4659 else
4660 cat > conftest.$ac_ext <<EOF
4661 #line 4662 "configure"
4662 #include "confdefs.h"
4663 #include <$ac_hdr>
4664 EOF
4665 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4666 { (eval echo configure:4667: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4667 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4668 if test -z "$ac_err"; then
4669 rm -rf conftest*
4670 eval "ac_cv_header_$ac_safe=yes"
4671 else
4672 echo "$ac_err" >&5
4673 echo "configure: failed program was:" >&5
4674 cat conftest.$ac_ext >&5
4675 rm -rf conftest*
4676 eval "ac_cv_header_$ac_safe=no"
4677 fi
4678 rm -f conftest*
4679 fi
4680 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4681 echo "$ac_t""yes" 1>&6
4682 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4683 cat >> confdefs.h <<EOF
4684 #define $ac_tr_hdr 1
4685 EOF
4686
4687 else
4688 echo "$ac_t""no" 1>&6
4689 fi
4690 done
4691
4692 for ac_hdr in sys/filio.h
4693 do
4694 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4695 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4696 echo "configure:4697: checking for $ac_hdr" >&5
4697 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4698 echo $ac_n "(cached) $ac_c" 1>&6
4699 else
4700 cat > conftest.$ac_ext <<EOF
4701 #line 4702 "configure"
4702 #include "confdefs.h"
4703 #include <$ac_hdr>
4704 EOF
4705 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4706 { (eval echo configure:4707: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4707 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4708 if test -z "$ac_err"; then
4709 rm -rf conftest*
4710 eval "ac_cv_header_$ac_safe=yes"
4711 else
4712 echo "$ac_err" >&5
4713 echo "configure: failed program was:" >&5
4714 cat conftest.$ac_ext >&5
4715 rm -rf conftest*
4716 eval "ac_cv_header_$ac_safe=no"
4717 fi
4718 rm -f conftest*
4719 fi
4720 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4721 echo "$ac_t""yes" 1>&6
4722 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4723 cat >> confdefs.h <<EOF
4724 #define $ac_tr_hdr 1
4725 EOF
4726
4727 else
4728 echo "$ac_t""no" 1>&6
4729 fi
4730 done
4731
4732 for ac_hdr in sys/ioctl.h
4733 do
4734 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4735 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4736 echo "configure:4737: checking for $ac_hdr" >&5
4737 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4738 echo $ac_n "(cached) $ac_c" 1>&6
4739 else
4740 cat > conftest.$ac_ext <<EOF
4741 #line 4742 "configure"
4742 #include "confdefs.h"
4743 #include <$ac_hdr>
4744 EOF
4745 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4746 { (eval echo configure:4747: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4747 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4748 if test -z "$ac_err"; then
4749 rm -rf conftest*
4750 eval "ac_cv_header_$ac_safe=yes"
4751 else
4752 echo "$ac_err" >&5
4753 echo "configure: failed program was:" >&5
4754 cat conftest.$ac_ext >&5
4755 rm -rf conftest*
4756 eval "ac_cv_header_$ac_safe=no"
4757 fi
4758 rm -f conftest*
4759 fi
4760 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4761 echo "$ac_t""yes" 1>&6
4762 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4763 cat >> confdefs.h <<EOF
4764 #define $ac_tr_hdr 1
4765 EOF
4766
4767 else
4768 echo "$ac_t""no" 1>&6
4769 fi
4770 done
4771
4772 for ac_hdr in sys/param.h
4773 do
4774 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4775 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4776 echo "configure:4777: checking for $ac_hdr" >&5
4777 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4778 echo $ac_n "(cached) $ac_c" 1>&6
4779 else
4780 cat > conftest.$ac_ext <<EOF
4781 #line 4782 "configure"
4782 #include "confdefs.h"
4783 #include <$ac_hdr>
4784 EOF
4785 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4786 { (eval echo configure:4787: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4787 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4788 if test -z "$ac_err"; then
4789 rm -rf conftest*
4790 eval "ac_cv_header_$ac_safe=yes"
4791 else
4792 echo "$ac_err" >&5
4793 echo "configure: failed program was:" >&5
4794 cat conftest.$ac_ext >&5
4795 rm -rf conftest*
4796 eval "ac_cv_header_$ac_safe=no"
4797 fi
4798 rm -f conftest*
4799 fi
4800 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4801 echo "$ac_t""yes" 1>&6
4802 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4803 cat >> confdefs.h <<EOF
4804 #define $ac_tr_hdr 1
4805 EOF
4806
4807 else
4808 echo "$ac_t""no" 1>&6
4809 fi
4810 done
4811
4812 for ac_hdr in sys/proc.h
4813 do
4814 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4815 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4816 echo "configure:4817: checking for $ac_hdr" >&5
4817 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4818 echo $ac_n "(cached) $ac_c" 1>&6
4819 else
4820 cat > conftest.$ac_ext <<EOF
4821 #line 4822 "configure"
4822 #include "confdefs.h"
4823 #include <$ac_hdr>
4824 EOF
4825 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4826 { (eval echo configure:4827: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4827 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4828 if test -z "$ac_err"; then
4829 rm -rf conftest*
4830 eval "ac_cv_header_$ac_safe=yes"
4831 else
4832 echo "$ac_err" >&5
4833 echo "configure: failed program was:" >&5
4834 cat conftest.$ac_ext >&5
4835 rm -rf conftest*
4836 eval "ac_cv_header_$ac_safe=no"
4837 fi
4838 rm -f conftest*
4839 fi
4840 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4841 echo "$ac_t""yes" 1>&6
4842 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4843 cat >> confdefs.h <<EOF
4844 #define $ac_tr_hdr 1
4845 EOF
4846
4847 else
4848 echo "$ac_t""no" 1>&6
4849 fi
4850 done
4851
4852 for ac_hdr in sys/procfs.h
4853 do
4854 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4855 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4856 echo "configure:4857: checking for $ac_hdr" >&5
4857 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4858 echo $ac_n "(cached) $ac_c" 1>&6
4859 else
4860 cat > conftest.$ac_ext <<EOF
4861 #line 4862 "configure"
4862 #include "confdefs.h"
4863 #include <$ac_hdr>
4864 EOF
4865 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4866 { (eval echo configure:4867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4867 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4868 if test -z "$ac_err"; then
4869 rm -rf conftest*
4870 eval "ac_cv_header_$ac_safe=yes"
4871 else
4872 echo "$ac_err" >&5
4873 echo "configure: failed program was:" >&5
4874 cat conftest.$ac_ext >&5
4875 rm -rf conftest*
4876 eval "ac_cv_header_$ac_safe=no"
4877 fi
4878 rm -f conftest*
4879 fi
4880 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4881 echo "$ac_t""yes" 1>&6
4882 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4883 cat >> confdefs.h <<EOF
4884 #define $ac_tr_hdr 1
4885 EOF
4886
4887 else
4888 echo "$ac_t""no" 1>&6
4889 fi
4890 done
4891
4892 for ac_hdr in sys/ptrace.h ptrace.h
4893 do
4894 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4895 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4896 echo "configure:4897: checking for $ac_hdr" >&5
4897 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4898 echo $ac_n "(cached) $ac_c" 1>&6
4899 else
4900 cat > conftest.$ac_ext <<EOF
4901 #line 4902 "configure"
4902 #include "confdefs.h"
4903 #include <$ac_hdr>
4904 EOF
4905 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4906 { (eval echo configure:4907: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4907 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4908 if test -z "$ac_err"; then
4909 rm -rf conftest*
4910 eval "ac_cv_header_$ac_safe=yes"
4911 else
4912 echo "$ac_err" >&5
4913 echo "configure: failed program was:" >&5
4914 cat conftest.$ac_ext >&5
4915 rm -rf conftest*
4916 eval "ac_cv_header_$ac_safe=no"
4917 fi
4918 rm -f conftest*
4919 fi
4920 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4921 echo "$ac_t""yes" 1>&6
4922 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4923 cat >> confdefs.h <<EOF
4924 #define $ac_tr_hdr 1
4925 EOF
4926
4927 else
4928 echo "$ac_t""no" 1>&6
4929 fi
4930 done
4931
4932 for ac_hdr in sys/reg.h sys/debugreg.h
4933 do
4934 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4935 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4936 echo "configure:4937: checking for $ac_hdr" >&5
4937 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4938 echo $ac_n "(cached) $ac_c" 1>&6
4939 else
4940 cat > conftest.$ac_ext <<EOF
4941 #line 4942 "configure"
4942 #include "confdefs.h"
4943 #include <$ac_hdr>
4944 EOF
4945 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4946 { (eval echo configure:4947: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4947 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4948 if test -z "$ac_err"; then
4949 rm -rf conftest*
4950 eval "ac_cv_header_$ac_safe=yes"
4951 else
4952 echo "$ac_err" >&5
4953 echo "configure: failed program was:" >&5
4954 cat conftest.$ac_ext >&5
4955 rm -rf conftest*
4956 eval "ac_cv_header_$ac_safe=no"
4957 fi
4958 rm -f conftest*
4959 fi
4960 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4961 echo "$ac_t""yes" 1>&6
4962 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4963 cat >> confdefs.h <<EOF
4964 #define $ac_tr_hdr 1
4965 EOF
4966
4967 else
4968 echo "$ac_t""no" 1>&6
4969 fi
4970 done
4971
4972 for ac_hdr in sys/select.h
4973 do
4974 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4975 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4976 echo "configure:4977: checking for $ac_hdr" >&5
4977 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4978 echo $ac_n "(cached) $ac_c" 1>&6
4979 else
4980 cat > conftest.$ac_ext <<EOF
4981 #line 4982 "configure"
4982 #include "confdefs.h"
4983 #include <$ac_hdr>
4984 EOF
4985 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4986 { (eval echo configure:4987: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4987 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4988 if test -z "$ac_err"; then
4989 rm -rf conftest*
4990 eval "ac_cv_header_$ac_safe=yes"
4991 else
4992 echo "$ac_err" >&5
4993 echo "configure: failed program was:" >&5
4994 cat conftest.$ac_ext >&5
4995 rm -rf conftest*
4996 eval "ac_cv_header_$ac_safe=no"
4997 fi
4998 rm -f conftest*
4999 fi
5000 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5001 echo "$ac_t""yes" 1>&6
5002 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5003 cat >> confdefs.h <<EOF
5004 #define $ac_tr_hdr 1
5005 EOF
5006
5007 else
5008 echo "$ac_t""no" 1>&6
5009 fi
5010 done
5011
5012 for ac_hdr in sys/syscall.h
5013 do
5014 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5015 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5016 echo "configure:5017: checking for $ac_hdr" >&5
5017 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5018 echo $ac_n "(cached) $ac_c" 1>&6
5019 else
5020 cat > conftest.$ac_ext <<EOF
5021 #line 5022 "configure"
5022 #include "confdefs.h"
5023 #include <$ac_hdr>
5024 EOF
5025 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5026 { (eval echo configure:5027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5027 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5028 if test -z "$ac_err"; then
5029 rm -rf conftest*
5030 eval "ac_cv_header_$ac_safe=yes"
5031 else
5032 echo "$ac_err" >&5
5033 echo "configure: failed program was:" >&5
5034 cat conftest.$ac_ext >&5
5035 rm -rf conftest*
5036 eval "ac_cv_header_$ac_safe=no"
5037 fi
5038 rm -f conftest*
5039 fi
5040 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5041 echo "$ac_t""yes" 1>&6
5042 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5043 cat >> confdefs.h <<EOF
5044 #define $ac_tr_hdr 1
5045 EOF
5046
5047 else
5048 echo "$ac_t""no" 1>&6
5049 fi
5050 done
5051
5052 for ac_hdr in sys/user.h
5053 do
5054 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5055 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5056 echo "configure:5057: checking for $ac_hdr" >&5
5057 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5058 echo $ac_n "(cached) $ac_c" 1>&6
5059 else
5060 cat > conftest.$ac_ext <<EOF
5061 #line 5062 "configure"
5062 #include "confdefs.h"
5063 #include <$ac_hdr>
5064 EOF
5065 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5066 { (eval echo configure:5067: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5067 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5068 if test -z "$ac_err"; then
5069 rm -rf conftest*
5070 eval "ac_cv_header_$ac_safe=yes"
5071 else
5072 echo "$ac_err" >&5
5073 echo "configure: failed program was:" >&5
5074 cat conftest.$ac_ext >&5
5075 rm -rf conftest*
5076 eval "ac_cv_header_$ac_safe=no"
5077 fi
5078 rm -f conftest*
5079 fi
5080 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5081 echo "$ac_t""yes" 1>&6
5082 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5083 cat >> confdefs.h <<EOF
5084 #define $ac_tr_hdr 1
5085 EOF
5086
5087 else
5088 echo "$ac_t""no" 1>&6
5089 fi
5090 done
5091
5092 for ac_hdr in sys/wait.h wait.h
5093 do
5094 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5095 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5096 echo "configure:5097: checking for $ac_hdr" >&5
5097 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5098 echo $ac_n "(cached) $ac_c" 1>&6
5099 else
5100 cat > conftest.$ac_ext <<EOF
5101 #line 5102 "configure"
5102 #include "confdefs.h"
5103 #include <$ac_hdr>
5104 EOF
5105 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5106 { (eval echo configure:5107: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5107 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5108 if test -z "$ac_err"; then
5109 rm -rf conftest*
5110 eval "ac_cv_header_$ac_safe=yes"
5111 else
5112 echo "$ac_err" >&5
5113 echo "configure: failed program was:" >&5
5114 cat conftest.$ac_ext >&5
5115 rm -rf conftest*
5116 eval "ac_cv_header_$ac_safe=no"
5117 fi
5118 rm -f conftest*
5119 fi
5120 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5121 echo "$ac_t""yes" 1>&6
5122 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5123 cat >> confdefs.h <<EOF
5124 #define $ac_tr_hdr 1
5125 EOF
5126
5127 else
5128 echo "$ac_t""no" 1>&6
5129 fi
5130 done
5131
5132 for ac_hdr in termios.h termio.h sgtty.h
5133 do
5134 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5135 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5136 echo "configure:5137: checking for $ac_hdr" >&5
5137 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5138 echo $ac_n "(cached) $ac_c" 1>&6
5139 else
5140 cat > conftest.$ac_ext <<EOF
5141 #line 5142 "configure"
5142 #include "confdefs.h"
5143 #include <$ac_hdr>
5144 EOF
5145 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5146 { (eval echo configure:5147: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5147 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5148 if test -z "$ac_err"; then
5149 rm -rf conftest*
5150 eval "ac_cv_header_$ac_safe=yes"
5151 else
5152 echo "$ac_err" >&5
5153 echo "configure: failed program was:" >&5
5154 cat conftest.$ac_ext >&5
5155 rm -rf conftest*
5156 eval "ac_cv_header_$ac_safe=no"
5157 fi
5158 rm -f conftest*
5159 fi
5160 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5161 echo "$ac_t""yes" 1>&6
5162 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5163 cat >> confdefs.h <<EOF
5164 #define $ac_tr_hdr 1
5165 EOF
5166
5167 else
5168 echo "$ac_t""no" 1>&6
5169 fi
5170 done
5171
5172 for ac_hdr in unistd.h
5173 do
5174 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5175 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5176 echo "configure:5177: checking for $ac_hdr" >&5
5177 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5178 echo $ac_n "(cached) $ac_c" 1>&6
5179 else
5180 cat > conftest.$ac_ext <<EOF
5181 #line 5182 "configure"
5182 #include "confdefs.h"
5183 #include <$ac_hdr>
5184 EOF
5185 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5186 { (eval echo configure:5187: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5187 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5188 if test -z "$ac_err"; then
5189 rm -rf conftest*
5190 eval "ac_cv_header_$ac_safe=yes"
5191 else
5192 echo "$ac_err" >&5
5193 echo "configure: failed program was:" >&5
5194 cat conftest.$ac_ext >&5
5195 rm -rf conftest*
5196 eval "ac_cv_header_$ac_safe=no"
5197 fi
5198 rm -f conftest*
5199 fi
5200 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5201 echo "$ac_t""yes" 1>&6
5202 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5203 cat >> confdefs.h <<EOF
5204 #define $ac_tr_hdr 1
5205 EOF
5206
5207 else
5208 echo "$ac_t""no" 1>&6
5209 fi
5210 done
5211
5212
5213 # On Solaris 2.[78], we need to define _MSE_INT_H to avoid a clash
5214 # between <widec.h> and <wchar.h> that would cause AC_CHECK_HEADERS to
5215 # think that we don't have <curses.h> if we're using GCC.
5216 case $host_os in
5217 solaris2.[78])
5218 if test "$GCC" = yes; then
5219 cat >> confdefs.h <<\EOF
5220 #define _MSE_INT_H 1
5221 EOF
5222
5223 fi ;;
5224 esac
5225 for ac_hdr in curses.h ncurses.h term.h
5226 do
5227 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5228 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5229 echo "configure:5230: checking for $ac_hdr" >&5
5230 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5231 echo $ac_n "(cached) $ac_c" 1>&6
5232 else
5233 cat > conftest.$ac_ext <<EOF
5234 #line 5235 "configure"
5235 #include "confdefs.h"
5236 #include <$ac_hdr>
5237 EOF
5238 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5239 { (eval echo configure:5240: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5240 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5241 if test -z "$ac_err"; then
5242 rm -rf conftest*
5243 eval "ac_cv_header_$ac_safe=yes"
5244 else
5245 echo "$ac_err" >&5
5246 echo "configure: failed program was:" >&5
5247 cat conftest.$ac_ext >&5
5248 rm -rf conftest*
5249 eval "ac_cv_header_$ac_safe=no"
5250 fi
5251 rm -f conftest*
5252 fi
5253 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5254 echo "$ac_t""yes" 1>&6
5255 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5256 cat >> confdefs.h <<EOF
5257 #define $ac_tr_hdr 1
5258 EOF
5259
5260 else
5261 echo "$ac_t""no" 1>&6
5262 fi
5263 done
5264
5265
5266 # FIXME: kettenis/20030102: In most cases we include these
5267 # unconditionally, so what's the point in checking these?
5268 for ac_hdr in ctype.h time.h
5269 do
5270 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5271 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5272 echo "configure:5273: checking for $ac_hdr" >&5
5273 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5274 echo $ac_n "(cached) $ac_c" 1>&6
5275 else
5276 cat > conftest.$ac_ext <<EOF
5277 #line 5278 "configure"
5278 #include "confdefs.h"
5279 #include <$ac_hdr>
5280 EOF
5281 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5282 { (eval echo configure:5283: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5283 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5284 if test -z "$ac_err"; then
5285 rm -rf conftest*
5286 eval "ac_cv_header_$ac_safe=yes"
5287 else
5288 echo "$ac_err" >&5
5289 echo "configure: failed program was:" >&5
5290 cat conftest.$ac_ext >&5
5291 rm -rf conftest*
5292 eval "ac_cv_header_$ac_safe=no"
5293 fi
5294 rm -f conftest*
5295 fi
5296 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5297 echo "$ac_t""yes" 1>&6
5298 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5299 cat >> confdefs.h <<EOF
5300 #define $ac_tr_hdr 1
5301 EOF
5302
5303 else
5304 echo "$ac_t""no" 1>&6
5305 fi
5306 done
5307
5308
5309 # ------------------ #
5310 # Checks for types. #
5311 # ------------------ #
5312
5313 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
5314 echo "configure:5315: checking return type of signal handlers" >&5
5315 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
5316 echo $ac_n "(cached) $ac_c" 1>&6
5317 else
5318 cat > conftest.$ac_ext <<EOF
5319 #line 5320 "configure"
5320 #include "confdefs.h"
5321 #include <sys/types.h>
5322 #include <signal.h>
5323 #ifdef signal
5324 #undef signal
5325 #endif
5326 #ifdef __cplusplus
5327 extern "C" void (*signal (int, void (*)(int)))(int);
5328 #else
5329 void (*signal ()) ();
5330 #endif
5331
5332 int main() {
5333 int i;
5334 ; return 0; }
5335 EOF
5336 if { (eval echo configure:5337: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5337 rm -rf conftest*
5338 ac_cv_type_signal=void
5339 else
5340 echo "configure: failed program was:" >&5
5341 cat conftest.$ac_ext >&5
5342 rm -rf conftest*
5343 ac_cv_type_signal=int
5344 fi
5345 rm -f conftest*
5346 fi
5347
5348 echo "$ac_t""$ac_cv_type_signal" 1>&6
5349 cat >> confdefs.h <<EOF
5350 #define RETSIGTYPE $ac_cv_type_signal
5351 EOF
5352
5353
5354
5355 # ------------------------------------- #
5356 # Checks for compiler characteristics. #
5357 # ------------------------------------- #
5358
5359 echo $ac_n "checking for working const""... $ac_c" 1>&6
5360 echo "configure:5361: checking for working const" >&5
5361 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
5362 echo $ac_n "(cached) $ac_c" 1>&6
5363 else
5364 cat > conftest.$ac_ext <<EOF
5365 #line 5366 "configure"
5366 #include "confdefs.h"
5367
5368 int main() {
5369
5370 /* Ultrix mips cc rejects this. */
5371 typedef int charset[2]; const charset x;
5372 /* SunOS 4.1.1 cc rejects this. */
5373 char const *const *ccp;
5374 char **p;
5375 /* NEC SVR4.0.2 mips cc rejects this. */
5376 struct point {int x, y;};
5377 static struct point const zero = {0,0};
5378 /* AIX XL C 1.02.0.0 rejects this.
5379 It does not let you subtract one const X* pointer from another in an arm
5380 of an if-expression whose if-part is not a constant expression */
5381 const char *g = "string";
5382 ccp = &g + (g ? g-g : 0);
5383 /* HPUX 7.0 cc rejects these. */
5384 ++ccp;
5385 p = (char**) ccp;
5386 ccp = (char const *const *) p;
5387 { /* SCO 3.2v4 cc rejects this. */
5388 char *t;
5389 char const *s = 0 ? (char *) 0 : (char const *) 0;
5390
5391 *t++ = 0;
5392 }
5393 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
5394 int x[] = {25, 17};
5395 const int *foo = &x[0];
5396 ++foo;
5397 }
5398 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
5399 typedef const int *iptr;
5400 iptr p = 0;
5401 ++p;
5402 }
5403 { /* AIX XL C 1.02.0.0 rejects this saying
5404 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
5405 struct s { int j; const int *ap[3]; };
5406 struct s *b; b->j = 5;
5407 }
5408 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
5409 const int foo = 10;
5410 }
5411
5412 ; return 0; }
5413 EOF
5414 if { (eval echo configure:5415: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5415 rm -rf conftest*
5416 ac_cv_c_const=yes
5417 else
5418 echo "configure: failed program was:" >&5
5419 cat conftest.$ac_ext >&5
5420 rm -rf conftest*
5421 ac_cv_c_const=no
5422 fi
5423 rm -f conftest*
5424 fi
5425
5426 echo "$ac_t""$ac_cv_c_const" 1>&6
5427 if test $ac_cv_c_const = no; then
5428 cat >> confdefs.h <<\EOF
5429 #define const
5430 EOF
5431
5432 fi
5433
5434 echo $ac_n "checking for inline""... $ac_c" 1>&6
5435 echo "configure:5436: checking for inline" >&5
5436 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
5437 echo $ac_n "(cached) $ac_c" 1>&6
5438 else
5439 ac_cv_c_inline=no
5440 for ac_kw in inline __inline__ __inline; do
5441 cat > conftest.$ac_ext <<EOF
5442 #line 5443 "configure"
5443 #include "confdefs.h"
5444
5445 int main() {
5446 } $ac_kw foo() {
5447 ; return 0; }
5448 EOF
5449 if { (eval echo configure:5450: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5450 rm -rf conftest*
5451 ac_cv_c_inline=$ac_kw; break
5452 else
5453 echo "configure: failed program was:" >&5
5454 cat conftest.$ac_ext >&5
5455 fi
5456 rm -f conftest*
5457 done
5458
5459 fi
5460
5461 echo "$ac_t""$ac_cv_c_inline" 1>&6
5462 case "$ac_cv_c_inline" in
5463 inline | yes) ;;
5464 no) cat >> confdefs.h <<\EOF
5465 #define inline
5466 EOF
5467 ;;
5468 *) cat >> confdefs.h <<EOF
5469 #define inline $ac_cv_c_inline
5470 EOF
5471 ;;
5472 esac
5473
5474
5475 # ------------------------------ #
5476 # Checks for library functions. #
5477 # ------------------------------ #
5478
5479 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
5480 # for constant arguments. Useless!
5481 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
5482 echo "configure:5483: checking for working alloca.h" >&5
5483 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
5484 echo $ac_n "(cached) $ac_c" 1>&6
5485 else
5486 cat > conftest.$ac_ext <<EOF
5487 #line 5488 "configure"
5488 #include "confdefs.h"
5489 #include <alloca.h>
5490 int main() {
5491 char *p = alloca(2 * sizeof(int));
5492 ; return 0; }
5493 EOF
5494 if { (eval echo configure:5495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5495 rm -rf conftest*
5496 ac_cv_header_alloca_h=yes
5497 else
5498 echo "configure: failed program was:" >&5
5499 cat conftest.$ac_ext >&5
5500 rm -rf conftest*
5501 ac_cv_header_alloca_h=no
5502 fi
5503 rm -f conftest*
5504 fi
5505
5506 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
5507 if test $ac_cv_header_alloca_h = yes; then
5508 cat >> confdefs.h <<\EOF
5509 #define HAVE_ALLOCA_H 1
5510 EOF
5511
5512 fi
5513
5514 echo $ac_n "checking for alloca""... $ac_c" 1>&6
5515 echo "configure:5516: checking for alloca" >&5
5516 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
5517 echo $ac_n "(cached) $ac_c" 1>&6
5518 else
5519 cat > conftest.$ac_ext <<EOF
5520 #line 5521 "configure"
5521 #include "confdefs.h"
5522
5523 #ifdef __GNUC__
5524 # define alloca __builtin_alloca
5525 #else
5526 # ifdef _MSC_VER
5527 # include <malloc.h>
5528 # define alloca _alloca
5529 # else
5530 # if HAVE_ALLOCA_H
5531 # include <alloca.h>
5532 # else
5533 # ifdef _AIX
5534 #pragma alloca
5535 # else
5536 # ifndef alloca /* predefined by HP cc +Olibcalls */
5537 char *alloca ();
5538 # endif
5539 # endif
5540 # endif
5541 # endif
5542 #endif
5543
5544 int main() {
5545 char *p = (char *) alloca(1);
5546 ; return 0; }
5547 EOF
5548 if { (eval echo configure:5549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5549 rm -rf conftest*
5550 ac_cv_func_alloca_works=yes
5551 else
5552 echo "configure: failed program was:" >&5
5553 cat conftest.$ac_ext >&5
5554 rm -rf conftest*
5555 ac_cv_func_alloca_works=no
5556 fi
5557 rm -f conftest*
5558 fi
5559
5560 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
5561 if test $ac_cv_func_alloca_works = yes; then
5562 cat >> confdefs.h <<\EOF
5563 #define HAVE_ALLOCA 1
5564 EOF
5565
5566 fi
5567
5568 if test $ac_cv_func_alloca_works = no; then
5569 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
5570 # that cause trouble. Some versions do not even contain alloca or
5571 # contain a buggy version. If you still want to use their alloca,
5572 # use ar to extract alloca.o from them instead of compiling alloca.c.
5573 ALLOCA=alloca.${ac_objext}
5574 cat >> confdefs.h <<\EOF
5575 #define C_ALLOCA 1
5576 EOF
5577
5578
5579 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
5580 echo "configure:5581: checking whether alloca needs Cray hooks" >&5
5581 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
5582 echo $ac_n "(cached) $ac_c" 1>&6
5583 else
5584 cat > conftest.$ac_ext <<EOF
5585 #line 5586 "configure"
5586 #include "confdefs.h"
5587 #if defined(CRAY) && ! defined(CRAY2)
5588 webecray
5589 #else
5590 wenotbecray
5591 #endif
5592
5593 EOF
5594 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5595 egrep "webecray" >/dev/null 2>&1; then
5596 rm -rf conftest*
5597 ac_cv_os_cray=yes
5598 else
5599 rm -rf conftest*
5600 ac_cv_os_cray=no
5601 fi
5602 rm -f conftest*
5603
5604 fi
5605
5606 echo "$ac_t""$ac_cv_os_cray" 1>&6
5607 if test $ac_cv_os_cray = yes; then
5608 for ac_func in _getb67 GETB67 getb67; do
5609 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5610 echo "configure:5611: checking for $ac_func" >&5
5611 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5612 echo $ac_n "(cached) $ac_c" 1>&6
5613 else
5614 cat > conftest.$ac_ext <<EOF
5615 #line 5616 "configure"
5616 #include "confdefs.h"
5617 /* System header to define __stub macros and hopefully few prototypes,
5618 which can conflict with char $ac_func(); below. */
5619 #include <assert.h>
5620 /* Override any gcc2 internal prototype to avoid an error. */
5621 /* We use char because int might match the return type of a gcc2
5622 builtin and then its argument prototype would still apply. */
5623 char $ac_func();
5624
5625 int main() {
5626
5627 /* The GNU C library defines this for functions which it implements
5628 to always fail with ENOSYS. Some functions are actually named
5629 something starting with __ and the normal name is an alias. */
5630 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5631 choke me
5632 #else
5633 $ac_func();
5634 #endif
5635
5636 ; return 0; }
5637 EOF
5638 if { (eval echo configure:5639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5639 rm -rf conftest*
5640 eval "ac_cv_func_$ac_func=yes"
5641 else
5642 echo "configure: failed program was:" >&5
5643 cat conftest.$ac_ext >&5
5644 rm -rf conftest*
5645 eval "ac_cv_func_$ac_func=no"
5646 fi
5647 rm -f conftest*
5648 fi
5649
5650 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5651 echo "$ac_t""yes" 1>&6
5652 cat >> confdefs.h <<EOF
5653 #define CRAY_STACKSEG_END $ac_func
5654 EOF
5655
5656 break
5657 else
5658 echo "$ac_t""no" 1>&6
5659 fi
5660
5661 done
5662 fi
5663
5664 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
5665 echo "configure:5666: checking stack direction for C alloca" >&5
5666 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
5667 echo $ac_n "(cached) $ac_c" 1>&6
5668 else
5669 if test "$cross_compiling" = yes; then
5670 ac_cv_c_stack_direction=0
5671 else
5672 cat > conftest.$ac_ext <<EOF
5673 #line 5674 "configure"
5674 #include "confdefs.h"
5675 find_stack_direction ()
5676 {
5677 static char *addr = 0;
5678 auto char dummy;
5679 if (addr == 0)
5680 {
5681 addr = &dummy;
5682 return find_stack_direction ();
5683 }
5684 else
5685 return (&dummy > addr) ? 1 : -1;
5686 }
5687 main ()
5688 {
5689 exit (find_stack_direction() < 0);
5690 }
5691 EOF
5692 if { (eval echo configure:5693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5693 then
5694 ac_cv_c_stack_direction=1
5695 else
5696 echo "configure: failed program was:" >&5
5697 cat conftest.$ac_ext >&5
5698 rm -fr conftest*
5699 ac_cv_c_stack_direction=-1
5700 fi
5701 rm -fr conftest*
5702 fi
5703
5704 fi
5705
5706 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
5707 cat >> confdefs.h <<EOF
5708 #define STACK_DIRECTION $ac_cv_c_stack_direction
5709 EOF
5710
5711 fi
5712
5713 for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
5714 do
5715 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5716 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5717 echo "configure:5718: checking for $ac_hdr" >&5
5718 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5719 echo $ac_n "(cached) $ac_c" 1>&6
5720 else
5721 cat > conftest.$ac_ext <<EOF
5722 #line 5723 "configure"
5723 #include "confdefs.h"
5724 #include <$ac_hdr>
5725 EOF
5726 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5727 { (eval echo configure:5728: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5728 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5729 if test -z "$ac_err"; then
5730 rm -rf conftest*
5731 eval "ac_cv_header_$ac_safe=yes"
5732 else
5733 echo "$ac_err" >&5
5734 echo "configure: failed program was:" >&5
5735 cat conftest.$ac_ext >&5
5736 rm -rf conftest*
5737 eval "ac_cv_header_$ac_safe=no"
5738 fi
5739 rm -f conftest*
5740 fi
5741 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5742 echo "$ac_t""yes" 1>&6
5743 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5744 cat >> confdefs.h <<EOF
5745 #define $ac_tr_hdr 1
5746 EOF
5747
5748 else
5749 echo "$ac_t""no" 1>&6
5750 fi
5751 done
5752
5753 for ac_func in getpagesize
5754 do
5755 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5756 echo "configure:5757: checking for $ac_func" >&5
5757 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5758 echo $ac_n "(cached) $ac_c" 1>&6
5759 else
5760 cat > conftest.$ac_ext <<EOF
5761 #line 5762 "configure"
5762 #include "confdefs.h"
5763 /* System header to define __stub macros and hopefully few prototypes,
5764 which can conflict with char $ac_func(); below. */
5765 #include <assert.h>
5766 /* Override any gcc2 internal prototype to avoid an error. */
5767 /* We use char because int might match the return type of a gcc2
5768 builtin and then its argument prototype would still apply. */
5769 char $ac_func();
5770
5771 int main() {
5772
5773 /* The GNU C library defines this for functions which it implements
5774 to always fail with ENOSYS. Some functions are actually named
5775 something starting with __ and the normal name is an alias. */
5776 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5777 choke me
5778 #else
5779 $ac_func();
5780 #endif
5781
5782 ; return 0; }
5783 EOF
5784 if { (eval echo configure:5785: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5785 rm -rf conftest*
5786 eval "ac_cv_func_$ac_func=yes"
5787 else
5788 echo "configure: failed program was:" >&5
5789 cat conftest.$ac_ext >&5
5790 rm -rf conftest*
5791 eval "ac_cv_func_$ac_func=no"
5792 fi
5793 rm -f conftest*
5794 fi
5795
5796 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5797 echo "$ac_t""yes" 1>&6
5798 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5799 cat >> confdefs.h <<EOF
5800 #define $ac_tr_func 1
5801 EOF
5802
5803 else
5804 echo "$ac_t""no" 1>&6
5805 fi
5806 done
5807
5808 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
5809 echo "configure:5810: checking for working mmap" >&5
5810 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
5811 echo $ac_n "(cached) $ac_c" 1>&6
5812 else
5813 if test "$cross_compiling" = yes; then
5814 ac_cv_func_mmap_fixed_mapped=no
5815 else
5816 cat > conftest.$ac_ext <<EOF
5817 #line 5818 "configure"
5818 #include "confdefs.h"
5819
5820 /* Thanks to Mike Haertel and Jim Avera for this test.
5821 Here is a matrix of mmap possibilities:
5822 mmap private not fixed
5823 mmap private fixed at somewhere currently unmapped
5824 mmap private fixed at somewhere already mapped
5825 mmap shared not fixed
5826 mmap shared fixed at somewhere currently unmapped
5827 mmap shared fixed at somewhere already mapped
5828 For private mappings, we should verify that changes cannot be read()
5829 back from the file, nor mmap's back from the file at a different
5830 address. (There have been systems where private was not correctly
5831 implemented like the infamous i386 svr4.0, and systems where the
5832 VM page cache was not coherent with the filesystem buffer cache
5833 like early versions of FreeBSD and possibly contemporary NetBSD.)
5834 For shared mappings, we should conversely verify that changes get
5835 propogated back to all the places they're supposed to be.
5836
5837 Grep wants private fixed already mapped.
5838 The main things grep needs to know about mmap are:
5839 * does it exist and is it safe to write into the mmap'd area
5840 * how to use it (BSD variants) */
5841 #include <sys/types.h>
5842 #include <fcntl.h>
5843 #include <sys/mman.h>
5844
5845 #if HAVE_SYS_TYPES_H
5846 # include <sys/types.h>
5847 #endif
5848
5849 #if HAVE_STDLIB_H
5850 # include <stdlib.h>
5851 #endif
5852
5853 #if HAVE_SYS_STAT_H
5854 # include <sys/stat.h>
5855 #endif
5856
5857 #if HAVE_UNISTD_H
5858 # include <unistd.h>
5859 #endif
5860
5861 /* This mess was copied from the GNU getpagesize.h. */
5862 #ifndef HAVE_GETPAGESIZE
5863
5864 /* Assume that all systems that can run configure have sys/param.h. */
5865 # ifndef HAVE_SYS_PARAM_H
5866 # define HAVE_SYS_PARAM_H 1
5867 # endif
5868
5869 # ifdef _SC_PAGESIZE
5870 # define getpagesize() sysconf(_SC_PAGESIZE)
5871 # else /* no _SC_PAGESIZE */
5872 # ifdef HAVE_SYS_PARAM_H
5873 # include <sys/param.h>
5874 # ifdef EXEC_PAGESIZE
5875 # define getpagesize() EXEC_PAGESIZE
5876 # else /* no EXEC_PAGESIZE */
5877 # ifdef NBPG
5878 # define getpagesize() NBPG * CLSIZE
5879 # ifndef CLSIZE
5880 # define CLSIZE 1
5881 # endif /* no CLSIZE */
5882 # else /* no NBPG */
5883 # ifdef NBPC
5884 # define getpagesize() NBPC
5885 # else /* no NBPC */
5886 # ifdef PAGESIZE
5887 # define getpagesize() PAGESIZE
5888 # endif /* PAGESIZE */
5889 # endif /* no NBPC */
5890 # endif /* no NBPG */
5891 # endif /* no EXEC_PAGESIZE */
5892 # else /* no HAVE_SYS_PARAM_H */
5893 # define getpagesize() 8192 /* punt totally */
5894 # endif /* no HAVE_SYS_PARAM_H */
5895 # endif /* no _SC_PAGESIZE */
5896
5897 #endif /* no HAVE_GETPAGESIZE */
5898
5899 #ifdef __cplusplus
5900 extern "C" { void *malloc(unsigned); }
5901 #else
5902 char *malloc();
5903 #endif
5904
5905 int
5906 main()
5907 {
5908 char *data, *data2, *data3;
5909 int i, pagesize;
5910 int fd;
5911
5912 pagesize = getpagesize();
5913
5914 /*
5915 * First, make a file with some known garbage in it.
5916 */
5917 data = malloc(pagesize);
5918 if (!data)
5919 exit(1);
5920 for (i = 0; i < pagesize; ++i)
5921 *(data + i) = rand();
5922 umask(0);
5923 fd = creat("conftestmmap", 0600);
5924 if (fd < 0)
5925 exit(1);
5926 if (write(fd, data, pagesize) != pagesize)
5927 exit(1);
5928 close(fd);
5929
5930 /*
5931 * Next, try to mmap the file at a fixed address which
5932 * already has something else allocated at it. If we can,
5933 * also make sure that we see the same garbage.
5934 */
5935 fd = open("conftestmmap", O_RDWR);
5936 if (fd < 0)
5937 exit(1);
5938 data2 = malloc(2 * pagesize);
5939 if (!data2)
5940 exit(1);
5941 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
5942 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
5943 MAP_PRIVATE | MAP_FIXED, fd, 0L))
5944 exit(1);
5945 for (i = 0; i < pagesize; ++i)
5946 if (*(data + i) != *(data2 + i))
5947 exit(1);
5948
5949 /*
5950 * Finally, make sure that changes to the mapped area
5951 * do not percolate back to the file as seen by read().
5952 * (This is a bug on some variants of i386 svr4.0.)
5953 */
5954 for (i = 0; i < pagesize; ++i)
5955 *(data2 + i) = *(data2 + i) + 1;
5956 data3 = malloc(pagesize);
5957 if (!data3)
5958 exit(1);
5959 if (read(fd, data3, pagesize) != pagesize)
5960 exit(1);
5961 for (i = 0; i < pagesize; ++i)
5962 if (*(data + i) != *(data3 + i))
5963 exit(1);
5964 close(fd);
5965 unlink("conftestmmap");
5966 exit(0);
5967 }
5968
5969 EOF
5970 if { (eval echo configure:5971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5971 then
5972 ac_cv_func_mmap_fixed_mapped=yes
5973 else
5974 echo "configure: failed program was:" >&5
5975 cat conftest.$ac_ext >&5
5976 rm -fr conftest*
5977 ac_cv_func_mmap_fixed_mapped=no
5978 fi
5979 rm -fr conftest*
5980 fi
5981
5982 fi
5983
5984 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
5985 if test $ac_cv_func_mmap_fixed_mapped = yes; then
5986 cat >> confdefs.h <<\EOF
5987 #define HAVE_MMAP 1
5988 EOF
5989
5990 fi
5991
5992 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
5993 echo "configure:5994: checking for pid_t" >&5
5994 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
5995 echo $ac_n "(cached) $ac_c" 1>&6
5996 else
5997 cat > conftest.$ac_ext <<EOF
5998 #line 5999 "configure"
5999 #include "confdefs.h"
6000 #include <sys/types.h>
6001 #if STDC_HEADERS
6002 #include <stdlib.h>
6003 #include <stddef.h>
6004 #endif
6005 EOF
6006 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6007 egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
6008 rm -rf conftest*
6009 ac_cv_type_pid_t=yes
6010 else
6011 rm -rf conftest*
6012 ac_cv_type_pid_t=no
6013 fi
6014 rm -f conftest*
6015
6016 fi
6017 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
6018 if test $ac_cv_type_pid_t = no; then
6019 cat >> confdefs.h <<\EOF
6020 #define pid_t int
6021 EOF
6022
6023 fi
6024
6025 ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
6026 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
6027 echo "configure:6028: checking for vfork.h" >&5
6028 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6029 echo $ac_n "(cached) $ac_c" 1>&6
6030 else
6031 cat > conftest.$ac_ext <<EOF
6032 #line 6033 "configure"
6033 #include "confdefs.h"
6034 #include <vfork.h>
6035 EOF
6036 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6037 { (eval echo configure:6038: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6038 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6039 if test -z "$ac_err"; then
6040 rm -rf conftest*
6041 eval "ac_cv_header_$ac_safe=yes"
6042 else
6043 echo "$ac_err" >&5
6044 echo "configure: failed program was:" >&5
6045 cat conftest.$ac_ext >&5
6046 rm -rf conftest*
6047 eval "ac_cv_header_$ac_safe=no"
6048 fi
6049 rm -f conftest*
6050 fi
6051 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6052 echo "$ac_t""yes" 1>&6
6053 cat >> confdefs.h <<\EOF
6054 #define HAVE_VFORK_H 1
6055 EOF
6056
6057 else
6058 echo "$ac_t""no" 1>&6
6059 fi
6060
6061 echo $ac_n "checking for working vfork""... $ac_c" 1>&6
6062 echo "configure:6063: checking for working vfork" >&5
6063 if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
6064 echo $ac_n "(cached) $ac_c" 1>&6
6065 else
6066 if test "$cross_compiling" = yes; then
6067 echo $ac_n "checking for vfork""... $ac_c" 1>&6
6068 echo "configure:6069: checking for vfork" >&5
6069 if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
6070 echo $ac_n "(cached) $ac_c" 1>&6
6071 else
6072 cat > conftest.$ac_ext <<EOF
6073 #line 6074 "configure"
6074 #include "confdefs.h"
6075 /* System header to define __stub macros and hopefully few prototypes,
6076 which can conflict with char vfork(); below. */
6077 #include <assert.h>
6078 /* Override any gcc2 internal prototype to avoid an error. */
6079 /* We use char because int might match the return type of a gcc2
6080 builtin and then its argument prototype would still apply. */
6081 char vfork();
6082
6083 int main() {
6084
6085 /* The GNU C library defines this for functions which it implements
6086 to always fail with ENOSYS. Some functions are actually named
6087 something starting with __ and the normal name is an alias. */
6088 #if defined (__stub_vfork) || defined (__stub___vfork)
6089 choke me
6090 #else
6091 vfork();
6092 #endif
6093
6094 ; return 0; }
6095 EOF
6096 if { (eval echo configure:6097: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6097 rm -rf conftest*
6098 eval "ac_cv_func_vfork=yes"
6099 else
6100 echo "configure: failed program was:" >&5
6101 cat conftest.$ac_ext >&5
6102 rm -rf conftest*
6103 eval "ac_cv_func_vfork=no"
6104 fi
6105 rm -f conftest*
6106 fi
6107
6108 if eval "test \"`echo '$ac_cv_func_'vfork`\" = yes"; then
6109 echo "$ac_t""yes" 1>&6
6110 :
6111 else
6112 echo "$ac_t""no" 1>&6
6113 fi
6114
6115 ac_cv_func_vfork_works=$ac_cv_func_vfork
6116 else
6117 cat > conftest.$ac_ext <<EOF
6118 #line 6119 "configure"
6119 #include "confdefs.h"
6120 /* Thanks to Paul Eggert for this test. */
6121 #include <stdio.h>
6122 #include <sys/types.h>
6123 #include <sys/stat.h>
6124 #ifdef HAVE_UNISTD_H
6125 #include <unistd.h>
6126 #endif
6127 #ifdef HAVE_VFORK_H
6128 #include <vfork.h>
6129 #endif
6130 /* On some sparc systems, changes by the child to local and incoming
6131 argument registers are propagated back to the parent.
6132 The compiler is told about this with #include <vfork.h>,
6133 but some compilers (e.g. gcc -O) don't grok <vfork.h>.
6134 Test for this by using a static variable whose address
6135 is put into a register that is clobbered by the vfork. */
6136 static
6137 #ifdef __cplusplus
6138 sparc_address_test (int arg)
6139 #else
6140 sparc_address_test (arg) int arg;
6141 #endif
6142 {
6143 static pid_t child;
6144 if (!child) {
6145 child = vfork ();
6146 if (child < 0) {
6147 perror ("vfork");
6148 _exit(2);
6149 }
6150 if (!child) {
6151 arg = getpid();
6152 write(-1, "", 0);
6153 _exit (arg);
6154 }
6155 }
6156 }
6157 main() {
6158 pid_t parent = getpid ();
6159 pid_t child;
6160
6161 sparc_address_test ();
6162
6163 child = vfork ();
6164
6165 if (child == 0) {
6166 /* Here is another test for sparc vfork register problems.
6167 This test uses lots of local variables, at least
6168 as many local variables as main has allocated so far
6169 including compiler temporaries. 4 locals are enough for
6170 gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe.
6171 A buggy compiler should reuse the register of parent
6172 for one of the local variables, since it will think that
6173 parent can't possibly be used any more in this routine.
6174 Assigning to the local variable will thus munge parent
6175 in the parent process. */
6176 pid_t
6177 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
6178 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
6179 /* Convince the compiler that p..p7 are live; otherwise, it might
6180 use the same hardware register for all 8 local variables. */
6181 if (p != p1 || p != p2 || p != p3 || p != p4
6182 || p != p5 || p != p6 || p != p7)
6183 _exit(1);
6184
6185 /* On some systems (e.g. IRIX 3.3),
6186 vfork doesn't separate parent from child file descriptors.
6187 If the child closes a descriptor before it execs or exits,
6188 this munges the parent's descriptor as well.
6189 Test for this by closing stdout in the child. */
6190 _exit(close(fileno(stdout)) != 0);
6191 } else {
6192 int status;
6193 struct stat st;
6194
6195 while (wait(&status) != child)
6196 ;
6197 exit(
6198 /* Was there some problem with vforking? */
6199 child < 0
6200
6201 /* Did the child fail? (This shouldn't happen.) */
6202 || status
6203
6204 /* Did the vfork/compiler bug occur? */
6205 || parent != getpid()
6206
6207 /* Did the file descriptor bug occur? */
6208 || fstat(fileno(stdout), &st) != 0
6209 );
6210 }
6211 }
6212 EOF
6213 if { (eval echo configure:6214: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6214 then
6215 ac_cv_func_vfork_works=yes
6216 else
6217 echo "configure: failed program was:" >&5
6218 cat conftest.$ac_ext >&5
6219 rm -fr conftest*
6220 ac_cv_func_vfork_works=no
6221 fi
6222 rm -fr conftest*
6223 fi
6224
6225 fi
6226
6227 echo "$ac_t""$ac_cv_func_vfork_works" 1>&6
6228 if test $ac_cv_func_vfork_works = no; then
6229 cat >> confdefs.h <<\EOF
6230 #define vfork fork
6231 EOF
6232
6233 fi
6234
6235 for ac_func in canonicalize_file_name realpath
6236 do
6237 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6238 echo "configure:6239: checking for $ac_func" >&5
6239 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6240 echo $ac_n "(cached) $ac_c" 1>&6
6241 else
6242 cat > conftest.$ac_ext <<EOF
6243 #line 6244 "configure"
6244 #include "confdefs.h"
6245 /* System header to define __stub macros and hopefully few prototypes,
6246 which can conflict with char $ac_func(); below. */
6247 #include <assert.h>
6248 /* Override any gcc2 internal prototype to avoid an error. */
6249 /* We use char because int might match the return type of a gcc2
6250 builtin and then its argument prototype would still apply. */
6251 char $ac_func();
6252
6253 int main() {
6254
6255 /* The GNU C library defines this for functions which it implements
6256 to always fail with ENOSYS. Some functions are actually named
6257 something starting with __ and the normal name is an alias. */
6258 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6259 choke me
6260 #else
6261 $ac_func();
6262 #endif
6263
6264 ; return 0; }
6265 EOF
6266 if { (eval echo configure:6267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6267 rm -rf conftest*
6268 eval "ac_cv_func_$ac_func=yes"
6269 else
6270 echo "configure: failed program was:" >&5
6271 cat conftest.$ac_ext >&5
6272 rm -rf conftest*
6273 eval "ac_cv_func_$ac_func=no"
6274 fi
6275 rm -f conftest*
6276 fi
6277
6278 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6279 echo "$ac_t""yes" 1>&6
6280 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6281 cat >> confdefs.h <<EOF
6282 #define $ac_tr_func 1
6283 EOF
6284
6285 else
6286 echo "$ac_t""no" 1>&6
6287 fi
6288 done
6289
6290 for ac_func in poll
6291 do
6292 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6293 echo "configure:6294: checking for $ac_func" >&5
6294 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6295 echo $ac_n "(cached) $ac_c" 1>&6
6296 else
6297 cat > conftest.$ac_ext <<EOF
6298 #line 6299 "configure"
6299 #include "confdefs.h"
6300 /* System header to define __stub macros and hopefully few prototypes,
6301 which can conflict with char $ac_func(); below. */
6302 #include <assert.h>
6303 /* Override any gcc2 internal prototype to avoid an error. */
6304 /* We use char because int might match the return type of a gcc2
6305 builtin and then its argument prototype would still apply. */
6306 char $ac_func();
6307
6308 int main() {
6309
6310 /* The GNU C library defines this for functions which it implements
6311 to always fail with ENOSYS. Some functions are actually named
6312 something starting with __ and the normal name is an alias. */
6313 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6314 choke me
6315 #else
6316 $ac_func();
6317 #endif
6318
6319 ; return 0; }
6320 EOF
6321 if { (eval echo configure:6322: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6322 rm -rf conftest*
6323 eval "ac_cv_func_$ac_func=yes"
6324 else
6325 echo "configure: failed program was:" >&5
6326 cat conftest.$ac_ext >&5
6327 rm -rf conftest*
6328 eval "ac_cv_func_$ac_func=no"
6329 fi
6330 rm -f conftest*
6331 fi
6332
6333 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6334 echo "$ac_t""yes" 1>&6
6335 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6336 cat >> confdefs.h <<EOF
6337 #define $ac_tr_func 1
6338 EOF
6339
6340 else
6341 echo "$ac_t""no" 1>&6
6342 fi
6343 done
6344
6345 for ac_func in pread64
6346 do
6347 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6348 echo "configure:6349: checking for $ac_func" >&5
6349 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6350 echo $ac_n "(cached) $ac_c" 1>&6
6351 else
6352 cat > conftest.$ac_ext <<EOF
6353 #line 6354 "configure"
6354 #include "confdefs.h"
6355 /* System header to define __stub macros and hopefully few prototypes,
6356 which can conflict with char $ac_func(); below. */
6357 #include <assert.h>
6358 /* Override any gcc2 internal prototype to avoid an error. */
6359 /* We use char because int might match the return type of a gcc2
6360 builtin and then its argument prototype would still apply. */
6361 char $ac_func();
6362
6363 int main() {
6364
6365 /* The GNU C library defines this for functions which it implements
6366 to always fail with ENOSYS. Some functions are actually named
6367 something starting with __ and the normal name is an alias. */
6368 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6369 choke me
6370 #else
6371 $ac_func();
6372 #endif
6373
6374 ; return 0; }
6375 EOF
6376 if { (eval echo configure:6377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6377 rm -rf conftest*
6378 eval "ac_cv_func_$ac_func=yes"
6379 else
6380 echo "configure: failed program was:" >&5
6381 cat conftest.$ac_ext >&5
6382 rm -rf conftest*
6383 eval "ac_cv_func_$ac_func=no"
6384 fi
6385 rm -f conftest*
6386 fi
6387
6388 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6389 echo "$ac_t""yes" 1>&6
6390 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6391 cat >> confdefs.h <<EOF
6392 #define $ac_tr_func 1
6393 EOF
6394
6395 else
6396 echo "$ac_t""no" 1>&6
6397 fi
6398 done
6399
6400 for ac_func in sbrk
6401 do
6402 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6403 echo "configure:6404: checking for $ac_func" >&5
6404 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6405 echo $ac_n "(cached) $ac_c" 1>&6
6406 else
6407 cat > conftest.$ac_ext <<EOF
6408 #line 6409 "configure"
6409 #include "confdefs.h"
6410 /* System header to define __stub macros and hopefully few prototypes,
6411 which can conflict with char $ac_func(); below. */
6412 #include <assert.h>
6413 /* Override any gcc2 internal prototype to avoid an error. */
6414 /* We use char because int might match the return type of a gcc2
6415 builtin and then its argument prototype would still apply. */
6416 char $ac_func();
6417
6418 int main() {
6419
6420 /* The GNU C library defines this for functions which it implements
6421 to always fail with ENOSYS. Some functions are actually named
6422 something starting with __ and the normal name is an alias. */
6423 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6424 choke me
6425 #else
6426 $ac_func();
6427 #endif
6428
6429 ; return 0; }
6430 EOF
6431 if { (eval echo configure:6432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6432 rm -rf conftest*
6433 eval "ac_cv_func_$ac_func=yes"
6434 else
6435 echo "configure: failed program was:" >&5
6436 cat conftest.$ac_ext >&5
6437 rm -rf conftest*
6438 eval "ac_cv_func_$ac_func=no"
6439 fi
6440 rm -f conftest*
6441 fi
6442
6443 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6444 echo "$ac_t""yes" 1>&6
6445 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6446 cat >> confdefs.h <<EOF
6447 #define $ac_tr_func 1
6448 EOF
6449
6450 else
6451 echo "$ac_t""no" 1>&6
6452 fi
6453 done
6454
6455 for ac_func in setpgid setpgrp
6456 do
6457 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6458 echo "configure:6459: checking for $ac_func" >&5
6459 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6460 echo $ac_n "(cached) $ac_c" 1>&6
6461 else
6462 cat > conftest.$ac_ext <<EOF
6463 #line 6464 "configure"
6464 #include "confdefs.h"
6465 /* System header to define __stub macros and hopefully few prototypes,
6466 which can conflict with char $ac_func(); below. */
6467 #include <assert.h>
6468 /* Override any gcc2 internal prototype to avoid an error. */
6469 /* We use char because int might match the return type of a gcc2
6470 builtin and then its argument prototype would still apply. */
6471 char $ac_func();
6472
6473 int main() {
6474
6475 /* The GNU C library defines this for functions which it implements
6476 to always fail with ENOSYS. Some functions are actually named
6477 something starting with __ and the normal name is an alias. */
6478 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6479 choke me
6480 #else
6481 $ac_func();
6482 #endif
6483
6484 ; return 0; }
6485 EOF
6486 if { (eval echo configure:6487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6487 rm -rf conftest*
6488 eval "ac_cv_func_$ac_func=yes"
6489 else
6490 echo "configure: failed program was:" >&5
6491 cat conftest.$ac_ext >&5
6492 rm -rf conftest*
6493 eval "ac_cv_func_$ac_func=no"
6494 fi
6495 rm -f conftest*
6496 fi
6497
6498 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6499 echo "$ac_t""yes" 1>&6
6500 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6501 cat >> confdefs.h <<EOF
6502 #define $ac_tr_func 1
6503 EOF
6504
6505 else
6506 echo "$ac_t""no" 1>&6
6507 fi
6508 done
6509
6510 for ac_func in sigaction sigprocmask sigsetmask
6511 do
6512 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6513 echo "configure:6514: checking for $ac_func" >&5
6514 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6515 echo $ac_n "(cached) $ac_c" 1>&6
6516 else
6517 cat > conftest.$ac_ext <<EOF
6518 #line 6519 "configure"
6519 #include "confdefs.h"
6520 /* System header to define __stub macros and hopefully few prototypes,
6521 which can conflict with char $ac_func(); below. */
6522 #include <assert.h>
6523 /* Override any gcc2 internal prototype to avoid an error. */
6524 /* We use char because int might match the return type of a gcc2
6525 builtin and then its argument prototype would still apply. */
6526 char $ac_func();
6527
6528 int main() {
6529
6530 /* The GNU C library defines this for functions which it implements
6531 to always fail with ENOSYS. Some functions are actually named
6532 something starting with __ and the normal name is an alias. */
6533 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6534 choke me
6535 #else
6536 $ac_func();
6537 #endif
6538
6539 ; return 0; }
6540 EOF
6541 if { (eval echo configure:6542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6542 rm -rf conftest*
6543 eval "ac_cv_func_$ac_func=yes"
6544 else
6545 echo "configure: failed program was:" >&5
6546 cat conftest.$ac_ext >&5
6547 rm -rf conftest*
6548 eval "ac_cv_func_$ac_func=no"
6549 fi
6550 rm -f conftest*
6551 fi
6552
6553 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6554 echo "$ac_t""yes" 1>&6
6555 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6556 cat >> confdefs.h <<EOF
6557 #define $ac_tr_func 1
6558 EOF
6559
6560 else
6561 echo "$ac_t""no" 1>&6
6562 fi
6563 done
6564
6565 for ac_func in socketpair
6566 do
6567 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6568 echo "configure:6569: checking for $ac_func" >&5
6569 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6570 echo $ac_n "(cached) $ac_c" 1>&6
6571 else
6572 cat > conftest.$ac_ext <<EOF
6573 #line 6574 "configure"
6574 #include "confdefs.h"
6575 /* System header to define __stub macros and hopefully few prototypes,
6576 which can conflict with char $ac_func(); below. */
6577 #include <assert.h>
6578 /* Override any gcc2 internal prototype to avoid an error. */
6579 /* We use char because int might match the return type of a gcc2
6580 builtin and then its argument prototype would still apply. */
6581 char $ac_func();
6582
6583 int main() {
6584
6585 /* The GNU C library defines this for functions which it implements
6586 to always fail with ENOSYS. Some functions are actually named
6587 something starting with __ and the normal name is an alias. */
6588 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6589 choke me
6590 #else
6591 $ac_func();
6592 #endif
6593
6594 ; return 0; }
6595 EOF
6596 if { (eval echo configure:6597: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6597 rm -rf conftest*
6598 eval "ac_cv_func_$ac_func=yes"
6599 else
6600 echo "configure: failed program was:" >&5
6601 cat conftest.$ac_ext >&5
6602 rm -rf conftest*
6603 eval "ac_cv_func_$ac_func=no"
6604 fi
6605 rm -f conftest*
6606 fi
6607
6608 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6609 echo "$ac_t""yes" 1>&6
6610 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6611 cat >> confdefs.h <<EOF
6612 #define $ac_tr_func 1
6613 EOF
6614
6615 else
6616 echo "$ac_t""no" 1>&6
6617 fi
6618 done
6619
6620
6621 if test "$cross_compiling" = no; then
6622 echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
6623 echo "configure:6624: checking whether setpgrp takes no argument" >&5
6624 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then
6625 echo $ac_n "(cached) $ac_c" 1>&6
6626 else
6627 if test "$cross_compiling" = yes; then
6628 { echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; }
6629 else
6630 cat > conftest.$ac_ext <<EOF
6631 #line 6632 "configure"
6632 #include "confdefs.h"
6633
6634 #ifdef HAVE_UNISTD_H
6635 #include <unistd.h>
6636 #endif
6637
6638 /*
6639 * If this system has a BSD-style setpgrp, which takes arguments, exit
6640 * successfully.
6641 */
6642 main()
6643 {
6644 if (setpgrp(1,1) == -1)
6645 exit(0);
6646 else
6647 exit(1);
6648 }
6649
6650 EOF
6651 if { (eval echo configure:6652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
6652 then
6653 ac_cv_func_setpgrp_void=no
6654 else
6655 echo "configure: failed program was:" >&5
6656 cat conftest.$ac_ext >&5
6657 rm -fr conftest*
6658 ac_cv_func_setpgrp_void=yes
6659 fi
6660 rm -fr conftest*
6661 fi
6662
6663
6664 fi
6665
6666 echo "$ac_t""$ac_cv_func_setpgrp_void" 1>&6
6667 if test $ac_cv_func_setpgrp_void = yes; then
6668 cat >> confdefs.h <<\EOF
6669 #define SETPGRP_VOID 1
6670 EOF
6671
6672 fi
6673
6674 else
6675 echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
6676 echo "configure:6677: checking whether setpgrp takes no argument" >&5
6677 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then
6678 echo $ac_n "(cached) $ac_c" 1>&6
6679 else
6680 cat > conftest.$ac_ext <<EOF
6681 #line 6682 "configure"
6682 #include "confdefs.h"
6683
6684 #include <unistd.h>
6685
6686 int main() {
6687
6688 if (setpgrp(1,1) == -1)
6689 exit (0);
6690 else
6691 exit (1);
6692
6693 ; return 0; }
6694 EOF
6695 if { (eval echo configure:6696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6696 rm -rf conftest*
6697 ac_cv_func_setpgrp_void=no
6698 else
6699 echo "configure: failed program was:" >&5
6700 cat conftest.$ac_ext >&5
6701 rm -rf conftest*
6702 ac_cv_func_setpgrp_void=yes
6703 fi
6704 rm -f conftest*
6705 fi
6706
6707 echo "$ac_t""$ac_cv_func_setpgrp_void" 1>&6
6708 if test $ac_cv_func_setpgrp_void = yes; then
6709 cat >> confdefs.h <<\EOF
6710 #define SETPGRP_VOID 1
6711 EOF
6712
6713 fi
6714 fi
6715
6716 # Check if sigsetjmp is available. Using AC_CHECK_FUNCS won't do
6717 # since sigsetjmp might only be defined as a macro.
6718 echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6
6719 echo "configure:6720: checking for sigsetjmp" >&5
6720 if eval "test \"`echo '$''{'gdb_cv_func_sigsetjmp'+set}'`\" = set"; then
6721 echo $ac_n "(cached) $ac_c" 1>&6
6722 else
6723 cat > conftest.$ac_ext <<EOF
6724 #line 6725 "configure"
6725 #include "confdefs.h"
6726
6727 #include <setjmp.h>
6728
6729 int main() {
6730 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
6731 ; return 0; }
6732 EOF
6733 if { (eval echo configure:6734: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6734 rm -rf conftest*
6735 gdb_cv_func_sigsetjmp=yes
6736 else
6737 echo "configure: failed program was:" >&5
6738 cat conftest.$ac_ext >&5
6739 rm -rf conftest*
6740 gdb_cv_func_sigsetjmp=no
6741 fi
6742 rm -f conftest*
6743 fi
6744
6745 echo "$ac_t""$gdb_cv_func_sigsetjmp" 1>&6
6746 if test $gdb_cv_func_sigsetjmp = yes; then
6747 cat >> confdefs.h <<\EOF
6748 #define HAVE_SIGSETJMP 1
6749 EOF
6750
6751 fi
6752
6753 # Assume we'll default to using the included libiberty regex.
6754 gdb_use_included_regex=yes
6755
6756 # However, if the system regex is GNU regex, then default to *not*
6757 # using the included regex.
6758 echo $ac_n "checking for GNU regex""... $ac_c" 1>&6
6759 echo "configure:6760: checking for GNU regex" >&5
6760 if eval "test \"`echo '$''{'gdb_cv_have_gnu_regex'+set}'`\" = set"; then
6761 echo $ac_n "(cached) $ac_c" 1>&6
6762 else
6763 cat > conftest.$ac_ext <<EOF
6764 #line 6765 "configure"
6765 #include "confdefs.h"
6766 #include <gnu-versions.h>
6767 int main() {
6768 #define REGEX_INTERFACE_VERSION 1
6769 #if _GNU_REGEX_INTERFACE_VERSION != REGEX_INTERFACE_VERSION
6770 # error "Version mismatch"
6771 #endif
6772 ; return 0; }
6773 EOF
6774 if { (eval echo configure:6775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6775 rm -rf conftest*
6776 gdb_cv_have_gnu_regex=yes
6777 else
6778 echo "configure: failed program was:" >&5
6779 cat conftest.$ac_ext >&5
6780 rm -rf conftest*
6781 gdb_cv_have_gnu_regex=no
6782 fi
6783 rm -f conftest*
6784 fi
6785
6786 echo "$ac_t""$gdb_cv_have_gnu_regex" 1>&6
6787 if test $gdb_cv_have_gnu_regex = yes; then
6788 gdb_use_included_regex=no
6789 fi
6790
6791 # Check whether --with-included-regex or --without-included-regex was given.
6792 if test "${with_included_regex+set}" = set; then
6793 withval="$with_included_regex"
6794 gdb_with_regex=$withval
6795 else
6796 gdb_with_regex=$gdb_use_included_regex
6797 fi
6798
6799 if test "$gdb_with_regex" = yes; then
6800 cat >> confdefs.h <<\EOF
6801 #define USE_INCLUDED_REGEX 1
6802 EOF
6803
6804 fi
6805
6806 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
6807 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
6808 echo $ac_n "checking for r_fs in struct reg""... $ac_c" 1>&6
6809 echo "configure:6810: checking for r_fs in struct reg" >&5
6810 if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_fs'+set}'`\" = set"; then
6811 echo $ac_n "(cached) $ac_c" 1>&6
6812 else
6813 cat > conftest.$ac_ext <<EOF
6814 #line 6815 "configure"
6815 #include "confdefs.h"
6816 #include <machine/reg.h>
6817 int main() {
6818 struct reg r; r.r_fs;
6819 ; return 0; }
6820 EOF
6821 if { (eval echo configure:6822: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6822 rm -rf conftest*
6823 gdb_cv_struct_reg_r_fs=yes
6824 else
6825 echo "configure: failed program was:" >&5
6826 cat conftest.$ac_ext >&5
6827 rm -rf conftest*
6828 gdb_cv_struct_reg_r_fs=no
6829 fi
6830 rm -f conftest*
6831 fi
6832
6833 echo "$ac_t""$gdb_cv_struct_reg_r_fs" 1>&6
6834 if test $gdb_cv_struct_reg_r_fs = yes; then
6835 cat >> confdefs.h <<\EOF
6836 #define HAVE_STRUCT_REG_R_FS 1
6837 EOF
6838
6839 fi
6840 echo $ac_n "checking for r_gs in struct reg""... $ac_c" 1>&6
6841 echo "configure:6842: checking for r_gs in struct reg" >&5
6842 if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_gs'+set}'`\" = set"; then
6843 echo $ac_n "(cached) $ac_c" 1>&6
6844 else
6845 cat > conftest.$ac_ext <<EOF
6846 #line 6847 "configure"
6847 #include "confdefs.h"
6848 #include <machine/reg.h>
6849 int main() {
6850 struct reg r; r.r_gs;
6851 ; return 0; }
6852 EOF
6853 if { (eval echo configure:6854: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6854 rm -rf conftest*
6855 gdb_cv_struct_reg_r_gs=yes
6856 else
6857 echo "configure: failed program was:" >&5
6858 cat conftest.$ac_ext >&5
6859 rm -rf conftest*
6860 gdb_cv_struct_reg_r_gs=no
6861 fi
6862 rm -f conftest*
6863 fi
6864
6865 echo "$ac_t""$gdb_cv_struct_reg_r_gs" 1>&6
6866 if test $gdb_cv_struct_reg_r_gs = yes; then
6867 cat >> confdefs.h <<\EOF
6868 #define HAVE_STRUCT_REG_R_GS 1
6869 EOF
6870
6871 fi
6872
6873 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
6874 echo $ac_n "checking for PTRACE_GETREGS""... $ac_c" 1>&6
6875 echo "configure:6876: checking for PTRACE_GETREGS" >&5
6876 if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getregs'+set}'`\" = set"; then
6877 echo $ac_n "(cached) $ac_c" 1>&6
6878 else
6879 cat > conftest.$ac_ext <<EOF
6880 #line 6881 "configure"
6881 #include "confdefs.h"
6882 #include <sys/ptrace.h>
6883 int main() {
6884 PTRACE_GETREGS;
6885 ; return 0; }
6886 EOF
6887 if { (eval echo configure:6888: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6888 rm -rf conftest*
6889 gdb_cv_have_ptrace_getregs=yes
6890 else
6891 echo "configure: failed program was:" >&5
6892 cat conftest.$ac_ext >&5
6893 rm -rf conftest*
6894 gdb_cv_have_ptrace_getregs=no
6895 fi
6896 rm -f conftest*
6897 fi
6898
6899 echo "$ac_t""$gdb_cv_have_ptrace_getregs" 1>&6
6900 if test $gdb_cv_have_ptrace_getregs = yes; then
6901 cat >> confdefs.h <<\EOF
6902 #define HAVE_PTRACE_GETREGS 1
6903 EOF
6904
6905 fi
6906
6907 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
6908 echo $ac_n "checking for PTRACE_GETFPXREGS""... $ac_c" 1>&6
6909 echo "configure:6910: checking for PTRACE_GETFPXREGS" >&5
6910 if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getfpxregs'+set}'`\" = set"; then
6911 echo $ac_n "(cached) $ac_c" 1>&6
6912 else
6913 cat > conftest.$ac_ext <<EOF
6914 #line 6915 "configure"
6915 #include "confdefs.h"
6916 #include <sys/ptrace.h>
6917 int main() {
6918 PTRACE_GETFPXREGS;
6919 ; return 0; }
6920 EOF
6921 if { (eval echo configure:6922: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6922 rm -rf conftest*
6923 gdb_cv_have_ptrace_getfpxregs=yes
6924 else
6925 echo "configure: failed program was:" >&5
6926 cat conftest.$ac_ext >&5
6927 rm -rf conftest*
6928 gdb_cv_have_ptrace_getfpxregs=no
6929 fi
6930 rm -f conftest*
6931 fi
6932
6933 echo "$ac_t""$gdb_cv_have_ptrace_getfpxregs" 1>&6
6934 if test $gdb_cv_have_ptrace_getfpxregs = yes; then
6935 cat >> confdefs.h <<\EOF
6936 #define HAVE_PTRACE_GETFPXREGS 1
6937 EOF
6938
6939 fi
6940
6941 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
6942 echo $ac_n "checking for PT_GETDBREGS""... $ac_c" 1>&6
6943 echo "configure:6944: checking for PT_GETDBREGS" >&5
6944 if eval "test \"`echo '$''{'gdb_cv_have_pt_getdbregs'+set}'`\" = set"; then
6945 echo $ac_n "(cached) $ac_c" 1>&6
6946 else
6947 cat > conftest.$ac_ext <<EOF
6948 #line 6949 "configure"
6949 #include "confdefs.h"
6950 #include <sys/types.h>
6951 #include <sys/ptrace.h>
6952 int main() {
6953 PT_GETDBREGS;
6954 ; return 0; }
6955 EOF
6956 if { (eval echo configure:6957: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6957 rm -rf conftest*
6958 gdb_cv_have_pt_getdbregs=yes
6959 else
6960 echo "configure: failed program was:" >&5
6961 cat conftest.$ac_ext >&5
6962 rm -rf conftest*
6963 gdb_cv_have_pt_getdbregs=no
6964 fi
6965 rm -f conftest*
6966 fi
6967
6968 echo "$ac_t""$gdb_cv_have_pt_getdbregs" 1>&6
6969 if test $gdb_cv_have_pt_getdbregs = yes; then
6970 cat >> confdefs.h <<\EOF
6971 #define HAVE_PT_GETDBREGS 1
6972 EOF
6973
6974 fi
6975
6976 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
6977 echo $ac_n "checking for PT_GETXMMREGS""... $ac_c" 1>&6
6978 echo "configure:6979: checking for PT_GETXMMREGS" >&5
6979 if eval "test \"`echo '$''{'gdb_cv_have_pt_getxmmregs'+set}'`\" = set"; then
6980 echo $ac_n "(cached) $ac_c" 1>&6
6981 else
6982 cat > conftest.$ac_ext <<EOF
6983 #line 6984 "configure"
6984 #include "confdefs.h"
6985 #include <sys/types.h>
6986 #include <sys/ptrace.h>
6987 int main() {
6988 PT_GETXMMREGS;
6989 ; return 0; }
6990 EOF
6991 if { (eval echo configure:6992: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6992 rm -rf conftest*
6993 gdb_cv_have_pt_getxmmregs=yes
6994 else
6995 echo "configure: failed program was:" >&5
6996 cat conftest.$ac_ext >&5
6997 rm -rf conftest*
6998 gdb_cv_have_pt_getxmmregs=no
6999 fi
7000 rm -f conftest*
7001 fi
7002
7003 echo "$ac_t""$gdb_cv_have_pt_getxmmregs" 1>&6
7004 if test $gdb_cv_have_pt_getxmmregs = yes; then
7005 cat >> confdefs.h <<\EOF
7006 #define HAVE_PT_GETXMMREGS 1
7007 EOF
7008
7009 fi
7010
7011
7012 echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6
7013 echo "configure:7014: checking whether malloc must be declared" >&5
7014 if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then
7015 echo $ac_n "(cached) $ac_c" 1>&6
7016 else
7017 cat > conftest.$ac_ext <<EOF
7018 #line 7019 "configure"
7019 #include "confdefs.h"
7020
7021 #include <stdio.h>
7022 #ifdef HAVE_STRING_H
7023 #include <string.h>
7024 #else
7025 #ifdef HAVE_STRINGS_H
7026 #include <strings.h>
7027 #endif
7028 #endif
7029 #ifdef HAVE_STDLIB_H
7030 #include <stdlib.h>
7031 #endif
7032 #ifdef HAVE_UNISTD_H
7033 #include <unistd.h>
7034 #endif
7035 int main() {
7036 char *(*pfn) = (char *(*)) malloc
7037 ; return 0; }
7038 EOF
7039 if { (eval echo configure:7040: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7040 rm -rf conftest*
7041 bfd_cv_decl_needed_malloc=no
7042 else
7043 echo "configure: failed program was:" >&5
7044 cat conftest.$ac_ext >&5
7045 rm -rf conftest*
7046 bfd_cv_decl_needed_malloc=yes
7047 fi
7048 rm -f conftest*
7049 fi
7050
7051 echo "$ac_t""$bfd_cv_decl_needed_malloc" 1>&6
7052 if test $bfd_cv_decl_needed_malloc = yes; then
7053 cat >> confdefs.h <<\EOF
7054 #define NEED_DECLARATION_MALLOC 1
7055 EOF
7056
7057 fi
7058
7059 echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6
7060 echo "configure:7061: checking whether realloc must be declared" >&5
7061 if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then
7062 echo $ac_n "(cached) $ac_c" 1>&6
7063 else
7064 cat > conftest.$ac_ext <<EOF
7065 #line 7066 "configure"
7066 #include "confdefs.h"
7067
7068 #include <stdio.h>
7069 #ifdef HAVE_STRING_H
7070 #include <string.h>
7071 #else
7072 #ifdef HAVE_STRINGS_H
7073 #include <strings.h>
7074 #endif
7075 #endif
7076 #ifdef HAVE_STDLIB_H
7077 #include <stdlib.h>
7078 #endif
7079 #ifdef HAVE_UNISTD_H
7080 #include <unistd.h>
7081 #endif
7082 int main() {
7083 char *(*pfn) = (char *(*)) realloc
7084 ; return 0; }
7085 EOF
7086 if { (eval echo configure:7087: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7087 rm -rf conftest*
7088 bfd_cv_decl_needed_realloc=no
7089 else
7090 echo "configure: failed program was:" >&5
7091 cat conftest.$ac_ext >&5
7092 rm -rf conftest*
7093 bfd_cv_decl_needed_realloc=yes
7094 fi
7095 rm -f conftest*
7096 fi
7097
7098 echo "$ac_t""$bfd_cv_decl_needed_realloc" 1>&6
7099 if test $bfd_cv_decl_needed_realloc = yes; then
7100 cat >> confdefs.h <<\EOF
7101 #define NEED_DECLARATION_REALLOC 1
7102 EOF
7103
7104 fi
7105
7106 echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
7107 echo "configure:7108: checking whether free must be declared" >&5
7108 if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
7109 echo $ac_n "(cached) $ac_c" 1>&6
7110 else
7111 cat > conftest.$ac_ext <<EOF
7112 #line 7113 "configure"
7113 #include "confdefs.h"
7114
7115 #include <stdio.h>
7116 #ifdef HAVE_STRING_H
7117 #include <string.h>
7118 #else
7119 #ifdef HAVE_STRINGS_H
7120 #include <strings.h>
7121 #endif
7122 #endif
7123 #ifdef HAVE_STDLIB_H
7124 #include <stdlib.h>
7125 #endif
7126 #ifdef HAVE_UNISTD_H
7127 #include <unistd.h>
7128 #endif
7129 int main() {
7130 char *(*pfn) = (char *(*)) free
7131 ; return 0; }
7132 EOF
7133 if { (eval echo configure:7134: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7134 rm -rf conftest*
7135 bfd_cv_decl_needed_free=no
7136 else
7137 echo "configure: failed program was:" >&5
7138 cat conftest.$ac_ext >&5
7139 rm -rf conftest*
7140 bfd_cv_decl_needed_free=yes
7141 fi
7142 rm -f conftest*
7143 fi
7144
7145 echo "$ac_t""$bfd_cv_decl_needed_free" 1>&6
7146 if test $bfd_cv_decl_needed_free = yes; then
7147 cat >> confdefs.h <<\EOF
7148 #define NEED_DECLARATION_FREE 1
7149 EOF
7150
7151 fi
7152
7153 echo $ac_n "checking whether strerror must be declared""... $ac_c" 1>&6
7154 echo "configure:7155: checking whether strerror must be declared" >&5
7155 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strerror'+set}'`\" = set"; then
7156 echo $ac_n "(cached) $ac_c" 1>&6
7157 else
7158 cat > conftest.$ac_ext <<EOF
7159 #line 7160 "configure"
7160 #include "confdefs.h"
7161
7162 #include <stdio.h>
7163 #ifdef HAVE_STRING_H
7164 #include <string.h>
7165 #else
7166 #ifdef HAVE_STRINGS_H
7167 #include <strings.h>
7168 #endif
7169 #endif
7170 #ifdef HAVE_STDLIB_H
7171 #include <stdlib.h>
7172 #endif
7173 #ifdef HAVE_UNISTD_H
7174 #include <unistd.h>
7175 #endif
7176 int main() {
7177 char *(*pfn) = (char *(*)) strerror
7178 ; return 0; }
7179 EOF
7180 if { (eval echo configure:7181: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7181 rm -rf conftest*
7182 bfd_cv_decl_needed_strerror=no
7183 else
7184 echo "configure: failed program was:" >&5
7185 cat conftest.$ac_ext >&5
7186 rm -rf conftest*
7187 bfd_cv_decl_needed_strerror=yes
7188 fi
7189 rm -f conftest*
7190 fi
7191
7192 echo "$ac_t""$bfd_cv_decl_needed_strerror" 1>&6
7193 if test $bfd_cv_decl_needed_strerror = yes; then
7194 cat >> confdefs.h <<\EOF
7195 #define NEED_DECLARATION_STRERROR 1
7196 EOF
7197
7198 fi
7199
7200 echo $ac_n "checking whether strdup must be declared""... $ac_c" 1>&6
7201 echo "configure:7202: checking whether strdup must be declared" >&5
7202 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strdup'+set}'`\" = set"; then
7203 echo $ac_n "(cached) $ac_c" 1>&6
7204 else
7205 cat > conftest.$ac_ext <<EOF
7206 #line 7207 "configure"
7207 #include "confdefs.h"
7208
7209 #include <stdio.h>
7210 #ifdef HAVE_STRING_H
7211 #include <string.h>
7212 #else
7213 #ifdef HAVE_STRINGS_H
7214 #include <strings.h>
7215 #endif
7216 #endif
7217 #ifdef HAVE_STDLIB_H
7218 #include <stdlib.h>
7219 #endif
7220 #ifdef HAVE_UNISTD_H
7221 #include <unistd.h>
7222 #endif
7223 int main() {
7224 char *(*pfn) = (char *(*)) strdup
7225 ; return 0; }
7226 EOF
7227 if { (eval echo configure:7228: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7228 rm -rf conftest*
7229 bfd_cv_decl_needed_strdup=no
7230 else
7231 echo "configure: failed program was:" >&5
7232 cat conftest.$ac_ext >&5
7233 rm -rf conftest*
7234 bfd_cv_decl_needed_strdup=yes
7235 fi
7236 rm -f conftest*
7237 fi
7238
7239 echo "$ac_t""$bfd_cv_decl_needed_strdup" 1>&6
7240 if test $bfd_cv_decl_needed_strdup = yes; then
7241 cat >> confdefs.h <<\EOF
7242 #define NEED_DECLARATION_STRDUP 1
7243 EOF
7244
7245 fi
7246
7247 echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
7248 echo "configure:7249: checking whether strstr must be declared" >&5
7249 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
7250 echo $ac_n "(cached) $ac_c" 1>&6
7251 else
7252 cat > conftest.$ac_ext <<EOF
7253 #line 7254 "configure"
7254 #include "confdefs.h"
7255
7256 #include <stdio.h>
7257 #ifdef HAVE_STRING_H
7258 #include <string.h>
7259 #else
7260 #ifdef HAVE_STRINGS_H
7261 #include <strings.h>
7262 #endif
7263 #endif
7264 #ifdef HAVE_STDLIB_H
7265 #include <stdlib.h>
7266 #endif
7267 #ifdef HAVE_UNISTD_H
7268 #include <unistd.h>
7269 #endif
7270 int main() {
7271 char *(*pfn) = (char *(*)) strstr
7272 ; return 0; }
7273 EOF
7274 if { (eval echo configure:7275: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7275 rm -rf conftest*
7276 bfd_cv_decl_needed_strstr=no
7277 else
7278 echo "configure: failed program was:" >&5
7279 cat conftest.$ac_ext >&5
7280 rm -rf conftest*
7281 bfd_cv_decl_needed_strstr=yes
7282 fi
7283 rm -f conftest*
7284 fi
7285
7286 echo "$ac_t""$bfd_cv_decl_needed_strstr" 1>&6
7287 if test $bfd_cv_decl_needed_strstr = yes; then
7288 cat >> confdefs.h <<\EOF
7289 #define NEED_DECLARATION_STRSTR 1
7290 EOF
7291
7292 fi
7293
7294 echo $ac_n "checking whether canonicalize_file_name must be declared""... $ac_c" 1>&6
7295 echo "configure:7296: checking whether canonicalize_file_name must be declared" >&5
7296 if eval "test \"`echo '$''{'bfd_cv_decl_needed_canonicalize_file_name'+set}'`\" = set"; then
7297 echo $ac_n "(cached) $ac_c" 1>&6
7298 else
7299 cat > conftest.$ac_ext <<EOF
7300 #line 7301 "configure"
7301 #include "confdefs.h"
7302
7303 #include <stdio.h>
7304 #ifdef HAVE_STRING_H
7305 #include <string.h>
7306 #else
7307 #ifdef HAVE_STRINGS_H
7308 #include <strings.h>
7309 #endif
7310 #endif
7311 #ifdef HAVE_STDLIB_H
7312 #include <stdlib.h>
7313 #endif
7314 #ifdef HAVE_UNISTD_H
7315 #include <unistd.h>
7316 #endif
7317 int main() {
7318 char *(*pfn) = (char *(*)) canonicalize_file_name
7319 ; return 0; }
7320 EOF
7321 if { (eval echo configure:7322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7322 rm -rf conftest*
7323 bfd_cv_decl_needed_canonicalize_file_name=no
7324 else
7325 echo "configure: failed program was:" >&5
7326 cat conftest.$ac_ext >&5
7327 rm -rf conftest*
7328 bfd_cv_decl_needed_canonicalize_file_name=yes
7329 fi
7330 rm -f conftest*
7331 fi
7332
7333 echo "$ac_t""$bfd_cv_decl_needed_canonicalize_file_name" 1>&6
7334 if test $bfd_cv_decl_needed_canonicalize_file_name = yes; then
7335 cat >> confdefs.h <<\EOF
7336 #define NEED_DECLARATION_CANONICALIZE_FILE_NAME 1
7337 EOF
7338
7339 fi
7340
7341
7342 # The following save_state_t checkery is only necessary for HPUX
7343 # versions earlier than 10.20. When those fade from memory, this
7344 # could be expunged. --jsm 1999-03-22
7345
7346 echo $ac_n "checking for HPUX save_state structure""... $ac_c" 1>&6
7347 echo "configure:7348: checking for HPUX save_state structure" >&5
7348 cat > conftest.$ac_ext <<EOF
7349 #line 7350 "configure"
7350 #include "confdefs.h"
7351 #include <machine/save_state.h>
7352 EOF
7353 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7354 egrep "save_state_t" >/dev/null 2>&1; then
7355 rm -rf conftest*
7356 gdb_cv_hpux_savestate=yes
7357 else
7358 rm -rf conftest*
7359 gdb_cv_hpux_savestate=no
7360 fi
7361 rm -f conftest*
7362
7363 cat > conftest.$ac_ext <<EOF
7364 #line 7365 "configure"
7365 #include "confdefs.h"
7366 #include <machine/save_state.h>
7367 EOF
7368 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7369 egrep "ss_wide" >/dev/null 2>&1; then
7370 rm -rf conftest*
7371 gdb_cv_hpux_sswide=yes
7372 else
7373 rm -rf conftest*
7374 gdb_cv_hpux_sswide=no
7375 fi
7376 rm -f conftest*
7377
7378 if test $gdb_cv_hpux_savestate = yes
7379 then
7380 cat >> confdefs.h <<\EOF
7381 #define HAVE_STRUCT_SAVE_STATE_T 1
7382 EOF
7383
7384 fi
7385 if test $gdb_cv_hpux_sswide = yes
7386 then
7387 cat >> confdefs.h <<\EOF
7388 #define HAVE_STRUCT_MEMBER_SS_WIDE 1
7389 EOF
7390
7391 fi
7392 echo "$ac_t""$gdb_cv_hpux_sswide" 1>&6
7393
7394
7395 # If we are configured native on GNU/Linux, work around problems with
7396 # sys/procfs.h
7397 # Also detect which type of /proc is in use, such as for Unixware or Solaris.
7398
7399 if test "${target}" = "${host}"; then
7400 case "${host}" in
7401 i[3456]86-*-linux*)
7402 cat >> confdefs.h <<\EOF
7403 #define START_INFERIOR_TRAPS_EXPECTED 2
7404 EOF
7405
7406 cat >> confdefs.h <<\EOF
7407 #define sys_quotactl 1
7408 EOF
7409
7410 ;;
7411 ia64-*-aix*)
7412 cat >> confdefs.h <<\EOF
7413 #define NEW_PROC_API 1
7414 EOF
7415
7416 ;;
7417 *-*-unixware* | *-*-sysv4.2* | *-*-sysv5* | *-*-interix* )
7418 cat >> confdefs.h <<\EOF
7419 #define NEW_PROC_API 1
7420 EOF
7421
7422 ;;
7423 *-*-solaris2.[678])
7424 cat >> confdefs.h <<\EOF
7425 #define NEW_PROC_API 1
7426 EOF
7427
7428 ;;
7429 esac
7430 fi
7431
7432 if test "$ac_cv_header_sys_procfs_h" = yes; then
7433 echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6
7434 echo "configure:7435: checking for pstatus_t in sys/procfs.h" >&5
7435 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then
7436 echo $ac_n "(cached) $ac_c" 1>&6
7437 else
7438 cat > conftest.$ac_ext <<EOF
7439 #line 7440 "configure"
7440 #include "confdefs.h"
7441
7442 #define _SYSCALL32
7443 #include <sys/procfs.h>
7444 int main() {
7445 pstatus_t avar
7446 ; return 0; }
7447 EOF
7448 if { (eval echo configure:7449: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7449 rm -rf conftest*
7450 bfd_cv_have_sys_procfs_type_pstatus_t=yes
7451 else
7452 echo "configure: failed program was:" >&5
7453 cat conftest.$ac_ext >&5
7454 rm -rf conftest*
7455 bfd_cv_have_sys_procfs_type_pstatus_t=no
7456
7457 fi
7458 rm -f conftest*
7459 fi
7460
7461 if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
7462 cat >> confdefs.h <<\EOF
7463 #define HAVE_PSTATUS_T 1
7464 EOF
7465
7466 fi
7467 echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6
7468
7469 echo $ac_n "checking for prrun_t in sys/procfs.h""... $ac_c" 1>&6
7470 echo "configure:7471: checking for prrun_t in sys/procfs.h" >&5
7471 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prrun_t'+set}'`\" = set"; then
7472 echo $ac_n "(cached) $ac_c" 1>&6
7473 else
7474 cat > conftest.$ac_ext <<EOF
7475 #line 7476 "configure"
7476 #include "confdefs.h"
7477
7478 #define _SYSCALL32
7479 #include <sys/procfs.h>
7480 int main() {
7481 prrun_t avar
7482 ; return 0; }
7483 EOF
7484 if { (eval echo configure:7485: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7485 rm -rf conftest*
7486 bfd_cv_have_sys_procfs_type_prrun_t=yes
7487 else
7488 echo "configure: failed program was:" >&5
7489 cat conftest.$ac_ext >&5
7490 rm -rf conftest*
7491 bfd_cv_have_sys_procfs_type_prrun_t=no
7492
7493 fi
7494 rm -f conftest*
7495 fi
7496
7497 if test $bfd_cv_have_sys_procfs_type_prrun_t = yes; then
7498 cat >> confdefs.h <<\EOF
7499 #define HAVE_PRRUN_T 1
7500 EOF
7501
7502 fi
7503 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prrun_t" 1>&6
7504
7505 echo $ac_n "checking for gregset_t in sys/procfs.h""... $ac_c" 1>&6
7506 echo "configure:7507: checking for gregset_t in sys/procfs.h" >&5
7507 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_gregset_t'+set}'`\" = set"; then
7508 echo $ac_n "(cached) $ac_c" 1>&6
7509 else
7510 cat > conftest.$ac_ext <<EOF
7511 #line 7512 "configure"
7512 #include "confdefs.h"
7513
7514 #define _SYSCALL32
7515 #include <sys/procfs.h>
7516 int main() {
7517 gregset_t avar
7518 ; return 0; }
7519 EOF
7520 if { (eval echo configure:7521: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7521 rm -rf conftest*
7522 bfd_cv_have_sys_procfs_type_gregset_t=yes
7523 else
7524 echo "configure: failed program was:" >&5
7525 cat conftest.$ac_ext >&5
7526 rm -rf conftest*
7527 bfd_cv_have_sys_procfs_type_gregset_t=no
7528
7529 fi
7530 rm -f conftest*
7531 fi
7532
7533 if test $bfd_cv_have_sys_procfs_type_gregset_t = yes; then
7534 cat >> confdefs.h <<\EOF
7535 #define HAVE_GREGSET_T 1
7536 EOF
7537
7538 fi
7539 echo "$ac_t""$bfd_cv_have_sys_procfs_type_gregset_t" 1>&6
7540
7541 echo $ac_n "checking for fpregset_t in sys/procfs.h""... $ac_c" 1>&6
7542 echo "configure:7543: checking for fpregset_t in sys/procfs.h" >&5
7543 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_fpregset_t'+set}'`\" = set"; then
7544 echo $ac_n "(cached) $ac_c" 1>&6
7545 else
7546 cat > conftest.$ac_ext <<EOF
7547 #line 7548 "configure"
7548 #include "confdefs.h"
7549
7550 #define _SYSCALL32
7551 #include <sys/procfs.h>
7552 int main() {
7553 fpregset_t avar
7554 ; return 0; }
7555 EOF
7556 if { (eval echo configure:7557: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7557 rm -rf conftest*
7558 bfd_cv_have_sys_procfs_type_fpregset_t=yes
7559 else
7560 echo "configure: failed program was:" >&5
7561 cat conftest.$ac_ext >&5
7562 rm -rf conftest*
7563 bfd_cv_have_sys_procfs_type_fpregset_t=no
7564
7565 fi
7566 rm -f conftest*
7567 fi
7568
7569 if test $bfd_cv_have_sys_procfs_type_fpregset_t = yes; then
7570 cat >> confdefs.h <<\EOF
7571 #define HAVE_FPREGSET_T 1
7572 EOF
7573
7574 fi
7575 echo "$ac_t""$bfd_cv_have_sys_procfs_type_fpregset_t" 1>&6
7576
7577 echo $ac_n "checking for prgregset_t in sys/procfs.h""... $ac_c" 1>&6
7578 echo "configure:7579: checking for prgregset_t in sys/procfs.h" >&5
7579 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset_t'+set}'`\" = set"; then
7580 echo $ac_n "(cached) $ac_c" 1>&6
7581 else
7582 cat > conftest.$ac_ext <<EOF
7583 #line 7584 "configure"
7584 #include "confdefs.h"
7585
7586 #define _SYSCALL32
7587 #include <sys/procfs.h>
7588 int main() {
7589 prgregset_t avar
7590 ; return 0; }
7591 EOF
7592 if { (eval echo configure:7593: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7593 rm -rf conftest*
7594 bfd_cv_have_sys_procfs_type_prgregset_t=yes
7595 else
7596 echo "configure: failed program was:" >&5
7597 cat conftest.$ac_ext >&5
7598 rm -rf conftest*
7599 bfd_cv_have_sys_procfs_type_prgregset_t=no
7600
7601 fi
7602 rm -f conftest*
7603 fi
7604
7605 if test $bfd_cv_have_sys_procfs_type_prgregset_t = yes; then
7606 cat >> confdefs.h <<\EOF
7607 #define HAVE_PRGREGSET_T 1
7608 EOF
7609
7610 fi
7611 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset_t" 1>&6
7612
7613 echo $ac_n "checking for prfpregset_t in sys/procfs.h""... $ac_c" 1>&6
7614 echo "configure:7615: checking for prfpregset_t in sys/procfs.h" >&5
7615 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset_t'+set}'`\" = set"; then
7616 echo $ac_n "(cached) $ac_c" 1>&6
7617 else
7618 cat > conftest.$ac_ext <<EOF
7619 #line 7620 "configure"
7620 #include "confdefs.h"
7621
7622 #define _SYSCALL32
7623 #include <sys/procfs.h>
7624 int main() {
7625 prfpregset_t avar
7626 ; return 0; }
7627 EOF
7628 if { (eval echo configure:7629: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7629 rm -rf conftest*
7630 bfd_cv_have_sys_procfs_type_prfpregset_t=yes
7631 else
7632 echo "configure: failed program was:" >&5
7633 cat conftest.$ac_ext >&5
7634 rm -rf conftest*
7635 bfd_cv_have_sys_procfs_type_prfpregset_t=no
7636
7637 fi
7638 rm -f conftest*
7639 fi
7640
7641 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
7642 cat >> confdefs.h <<\EOF
7643 #define HAVE_PRFPREGSET_T 1
7644 EOF
7645
7646 fi
7647 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset_t" 1>&6
7648
7649 echo $ac_n "checking for prgregset32_t in sys/procfs.h""... $ac_c" 1>&6
7650 echo "configure:7651: checking for prgregset32_t in sys/procfs.h" >&5
7651 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset32_t'+set}'`\" = set"; then
7652 echo $ac_n "(cached) $ac_c" 1>&6
7653 else
7654 cat > conftest.$ac_ext <<EOF
7655 #line 7656 "configure"
7656 #include "confdefs.h"
7657
7658 #define _SYSCALL32
7659 #include <sys/procfs.h>
7660 int main() {
7661 prgregset32_t avar
7662 ; return 0; }
7663 EOF
7664 if { (eval echo configure:7665: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7665 rm -rf conftest*
7666 bfd_cv_have_sys_procfs_type_prgregset32_t=yes
7667 else
7668 echo "configure: failed program was:" >&5
7669 cat conftest.$ac_ext >&5
7670 rm -rf conftest*
7671 bfd_cv_have_sys_procfs_type_prgregset32_t=no
7672
7673 fi
7674 rm -f conftest*
7675 fi
7676
7677 if test $bfd_cv_have_sys_procfs_type_prgregset32_t = yes; then
7678 cat >> confdefs.h <<\EOF
7679 #define HAVE_PRGREGSET32_T 1
7680 EOF
7681
7682 fi
7683 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset32_t" 1>&6
7684
7685 echo $ac_n "checking for prfpregset32_t in sys/procfs.h""... $ac_c" 1>&6
7686 echo "configure:7687: checking for prfpregset32_t in sys/procfs.h" >&5
7687 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset32_t'+set}'`\" = set"; then
7688 echo $ac_n "(cached) $ac_c" 1>&6
7689 else
7690 cat > conftest.$ac_ext <<EOF
7691 #line 7692 "configure"
7692 #include "confdefs.h"
7693
7694 #define _SYSCALL32
7695 #include <sys/procfs.h>
7696 int main() {
7697 prfpregset32_t avar
7698 ; return 0; }
7699 EOF
7700 if { (eval echo configure:7701: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7701 rm -rf conftest*
7702 bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
7703 else
7704 echo "configure: failed program was:" >&5
7705 cat conftest.$ac_ext >&5
7706 rm -rf conftest*
7707 bfd_cv_have_sys_procfs_type_prfpregset32_t=no
7708
7709 fi
7710 rm -f conftest*
7711 fi
7712
7713 if test $bfd_cv_have_sys_procfs_type_prfpregset32_t = yes; then
7714 cat >> confdefs.h <<\EOF
7715 #define HAVE_PRFPREGSET32_T 1
7716 EOF
7717
7718 fi
7719 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset32_t" 1>&6
7720
7721 echo $ac_n "checking for lwpid_t in sys/procfs.h""... $ac_c" 1>&6
7722 echo "configure:7723: checking for lwpid_t in sys/procfs.h" >&5
7723 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpid_t'+set}'`\" = set"; then
7724 echo $ac_n "(cached) $ac_c" 1>&6
7725 else
7726 cat > conftest.$ac_ext <<EOF
7727 #line 7728 "configure"
7728 #include "confdefs.h"
7729
7730 #define _SYSCALL32
7731 #include <sys/procfs.h>
7732 int main() {
7733 lwpid_t avar
7734 ; return 0; }
7735 EOF
7736 if { (eval echo configure:7737: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7737 rm -rf conftest*
7738 bfd_cv_have_sys_procfs_type_lwpid_t=yes
7739 else
7740 echo "configure: failed program was:" >&5
7741 cat conftest.$ac_ext >&5
7742 rm -rf conftest*
7743 bfd_cv_have_sys_procfs_type_lwpid_t=no
7744
7745 fi
7746 rm -f conftest*
7747 fi
7748
7749 if test $bfd_cv_have_sys_procfs_type_lwpid_t = yes; then
7750 cat >> confdefs.h <<\EOF
7751 #define HAVE_LWPID_T 1
7752 EOF
7753
7754 fi
7755 echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpid_t" 1>&6
7756
7757 echo $ac_n "checking for psaddr_t in sys/procfs.h""... $ac_c" 1>&6
7758 echo "configure:7759: checking for psaddr_t in sys/procfs.h" >&5
7759 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psaddr_t'+set}'`\" = set"; then
7760 echo $ac_n "(cached) $ac_c" 1>&6
7761 else
7762 cat > conftest.$ac_ext <<EOF
7763 #line 7764 "configure"
7764 #include "confdefs.h"
7765
7766 #define _SYSCALL32
7767 #include <sys/procfs.h>
7768 int main() {
7769 psaddr_t avar
7770 ; return 0; }
7771 EOF
7772 if { (eval echo configure:7773: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7773 rm -rf conftest*
7774 bfd_cv_have_sys_procfs_type_psaddr_t=yes
7775 else
7776 echo "configure: failed program was:" >&5
7777 cat conftest.$ac_ext >&5
7778 rm -rf conftest*
7779 bfd_cv_have_sys_procfs_type_psaddr_t=no
7780
7781 fi
7782 rm -f conftest*
7783 fi
7784
7785 if test $bfd_cv_have_sys_procfs_type_psaddr_t = yes; then
7786 cat >> confdefs.h <<\EOF
7787 #define HAVE_PSADDR_T 1
7788 EOF
7789
7790 fi
7791 echo "$ac_t""$bfd_cv_have_sys_procfs_type_psaddr_t" 1>&6
7792
7793 echo $ac_n "checking for prsysent_t in sys/procfs.h""... $ac_c" 1>&6
7794 echo "configure:7795: checking for prsysent_t in sys/procfs.h" >&5
7795 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prsysent_t'+set}'`\" = set"; then
7796 echo $ac_n "(cached) $ac_c" 1>&6
7797 else
7798 cat > conftest.$ac_ext <<EOF
7799 #line 7800 "configure"
7800 #include "confdefs.h"
7801
7802 #define _SYSCALL32
7803 #include <sys/procfs.h>
7804 int main() {
7805 prsysent_t avar
7806 ; return 0; }
7807 EOF
7808 if { (eval echo configure:7809: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7809 rm -rf conftest*
7810 bfd_cv_have_sys_procfs_type_prsysent_t=yes
7811 else
7812 echo "configure: failed program was:" >&5
7813 cat conftest.$ac_ext >&5
7814 rm -rf conftest*
7815 bfd_cv_have_sys_procfs_type_prsysent_t=no
7816
7817 fi
7818 rm -f conftest*
7819 fi
7820
7821 if test $bfd_cv_have_sys_procfs_type_prsysent_t = yes; then
7822 cat >> confdefs.h <<\EOF
7823 #define HAVE_PRSYSENT_T 1
7824 EOF
7825
7826 fi
7827 echo "$ac_t""$bfd_cv_have_sys_procfs_type_prsysent_t" 1>&6
7828
7829 echo $ac_n "checking for pr_sigset_t in sys/procfs.h""... $ac_c" 1>&6
7830 echo "configure:7831: checking for pr_sigset_t in sys/procfs.h" >&5
7831 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_sigset_t'+set}'`\" = set"; then
7832 echo $ac_n "(cached) $ac_c" 1>&6
7833 else
7834 cat > conftest.$ac_ext <<EOF
7835 #line 7836 "configure"
7836 #include "confdefs.h"
7837
7838 #define _SYSCALL32
7839 #include <sys/procfs.h>
7840 int main() {
7841 pr_sigset_t avar
7842 ; return 0; }
7843 EOF
7844 if { (eval echo configure:7845: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7845 rm -rf conftest*
7846 bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
7847 else
7848 echo "configure: failed program was:" >&5
7849 cat conftest.$ac_ext >&5
7850 rm -rf conftest*
7851 bfd_cv_have_sys_procfs_type_pr_sigset_t=no
7852
7853 fi
7854 rm -f conftest*
7855 fi
7856
7857 if test $bfd_cv_have_sys_procfs_type_pr_sigset_t = yes; then
7858 cat >> confdefs.h <<\EOF
7859 #define HAVE_PR_SIGSET_T 1
7860 EOF
7861
7862 fi
7863 echo "$ac_t""$bfd_cv_have_sys_procfs_type_pr_sigset_t" 1>&6
7864
7865 echo $ac_n "checking for pr_sigaction64_t in sys/procfs.h""... $ac_c" 1>&6
7866 echo "configure:7867: checking for pr_sigaction64_t in sys/procfs.h" >&5
7867 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_sigaction64_t'+set}'`\" = set"; then
7868 echo $ac_n "(cached) $ac_c" 1>&6
7869 else
7870 cat > conftest.$ac_ext <<EOF
7871 #line 7872 "configure"
7872 #include "confdefs.h"
7873
7874 #define _SYSCALL32
7875 #include <sys/procfs.h>
7876 int main() {
7877 pr_sigaction64_t avar
7878 ; return 0; }
7879 EOF
7880 if { (eval echo configure:7881: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7881 rm -rf conftest*
7882 bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
7883 else
7884 echo "configure: failed program was:" >&5
7885 cat conftest.$ac_ext >&5
7886 rm -rf conftest*
7887 bfd_cv_have_sys_procfs_type_pr_sigaction64_t=no
7888
7889 fi
7890 rm -f conftest*
7891 fi
7892
7893 if test $bfd_cv_have_sys_procfs_type_pr_sigaction64_t = yes; then
7894 cat >> confdefs.h <<\EOF
7895 #define HAVE_PR_SIGACTION64_T 1
7896 EOF
7897
7898 fi
7899 echo "$ac_t""$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" 1>&6
7900
7901 echo $ac_n "checking for pr_siginfo64_t in sys/procfs.h""... $ac_c" 1>&6
7902 echo "configure:7903: checking for pr_siginfo64_t in sys/procfs.h" >&5
7903 if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_siginfo64_t'+set}'`\" = set"; then
7904 echo $ac_n "(cached) $ac_c" 1>&6
7905 else
7906 cat > conftest.$ac_ext <<EOF
7907 #line 7908 "configure"
7908 #include "confdefs.h"
7909
7910 #define _SYSCALL32
7911 #include <sys/procfs.h>
7912 int main() {
7913 pr_siginfo64_t avar
7914 ; return 0; }
7915 EOF
7916 if { (eval echo configure:7917: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
7917 rm -rf conftest*
7918 bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
7919 else
7920 echo "configure: failed program was:" >&5
7921 cat conftest.$ac_ext >&5
7922 rm -rf conftest*
7923 bfd_cv_have_sys_procfs_type_pr_siginfo64_t=no
7924
7925 fi
7926 rm -f conftest*
7927 fi
7928
7929 if test $bfd_cv_have_sys_procfs_type_pr_siginfo64_t = yes; then
7930 cat >> confdefs.h <<\EOF
7931 #define HAVE_PR_SIGINFO64_T 1
7932 EOF
7933
7934 fi
7935 echo "$ac_t""$bfd_cv_have_sys_procfs_type_pr_siginfo64_t" 1>&6
7936
7937
7938
7939
7940
7941 if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
7942 echo $ac_n "checking whether prfpregset_t type is broken""... $ac_c" 1>&6
7943 echo "configure:7944: checking whether prfpregset_t type is broken" >&5
7944 if eval "test \"`echo '$''{'gdb_cv_prfpregset_t_broken'+set}'`\" = set"; then
7945 echo $ac_n "(cached) $ac_c" 1>&6
7946 else
7947 if test "$cross_compiling" = yes; then
7948 gdb_cv_prfpregset_t_broken=yes
7949 else
7950 cat > conftest.$ac_ext <<EOF
7951 #line 7952 "configure"
7952 #include "confdefs.h"
7953 #include <sys/procfs.h>
7954 int main ()
7955 {
7956 if (sizeof (prfpregset_t) == sizeof (void *))
7957 return 1;
7958 return 0;
7959 }
7960 EOF
7961 if { (eval echo configure:7962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
7962 then
7963 gdb_cv_prfpregset_t_broken=no
7964 else
7965 echo "configure: failed program was:" >&5
7966 cat conftest.$ac_ext >&5
7967 rm -fr conftest*
7968 gdb_cv_prfpregset_t_broken=yes
7969 fi
7970 rm -fr conftest*
7971 fi
7972
7973 fi
7974
7975 echo "$ac_t""$gdb_cv_prfpregset_t_broken" 1>&6
7976 if test $gdb_cv_prfpregset_t_broken = yes; then
7977 cat >> confdefs.h <<\EOF
7978 #define PRFPREGSET_T_BROKEN 1
7979 EOF
7980
7981 fi
7982 fi
7983
7984
7985 echo $ac_n "checking for PIOCSET ioctl entry in sys/procfs.h""... $ac_c" 1>&6
7986 echo "configure:7987: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
7987 if eval "test \"`echo '$''{'gdb_cv_have_procfs_piocset'+set}'`\" = set"; then
7988 echo $ac_n "(cached) $ac_c" 1>&6
7989 else
7990 cat > conftest.$ac_ext <<EOF
7991 #line 7992 "configure"
7992 #include "confdefs.h"
7993 #include <unistd.h>
7994 #include <sys/types.h>
7995 #include <sys/procfs.h>
7996
7997 int main() {
7998
7999 int dummy;;
8000 dummy = ioctl(0, PIOCSET, &dummy);
8001
8002 ; return 0; }
8003 EOF
8004 if { (eval echo configure:8005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8005 rm -rf conftest*
8006 gdb_cv_have_procfs_piocset=yes
8007 else
8008 echo "configure: failed program was:" >&5
8009 cat conftest.$ac_ext >&5
8010 rm -rf conftest*
8011 gdb_cv_have_procfs_piocset=no
8012 fi
8013 rm -f conftest*
8014 fi
8015
8016 echo "$ac_t""$gdb_cv_have_procfs_piocset" 1>&6
8017 if test $gdb_cv_have_procfs_piocset = yes; then
8018 cat >> confdefs.h <<\EOF
8019 #define HAVE_PROCFS_PIOCSET 1
8020 EOF
8021
8022 fi
8023 fi
8024
8025 if test ${host} = ${target} ; then
8026
8027 echo $ac_n "checking for member l_addr in struct link_map""... $ac_c" 1>&6
8028 echo "configure:8029: checking for member l_addr in struct link_map" >&5
8029 if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map_with_l_members'+set}'`\" = set"; then
8030 echo $ac_n "(cached) $ac_c" 1>&6
8031 else
8032 cat > conftest.$ac_ext <<EOF
8033 #line 8034 "configure"
8034 #include "confdefs.h"
8035 #include <link.h>
8036 int main() {
8037 struct link_map lm; (void) lm.l_addr;
8038 ; return 0; }
8039 EOF
8040 if { (eval echo configure:8041: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8041 rm -rf conftest*
8042 gdb_cv_have_struct_link_map_with_l_members=yes
8043 else
8044 echo "configure: failed program was:" >&5
8045 cat conftest.$ac_ext >&5
8046 rm -rf conftest*
8047 gdb_cv_have_struct_link_map_with_l_members=no
8048 fi
8049 rm -f conftest*
8050 fi
8051
8052 echo "$ac_t""$gdb_cv_have_struct_link_map_with_l_members" 1>&6
8053 if test $gdb_cv_have_struct_link_map_with_l_members = yes; then
8054 cat >> confdefs.h <<\EOF
8055 #define HAVE_STRUCT_LINK_MAP_WITH_L_MEMBERS 1
8056 EOF
8057
8058 fi
8059
8060
8061 echo $ac_n "checking for member lm_addr in struct link_map""... $ac_c" 1>&6
8062 echo "configure:8063: checking for member lm_addr in struct link_map" >&5
8063 if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map_with_lm_members'+set}'`\" = set"; then
8064 echo $ac_n "(cached) $ac_c" 1>&6
8065 else
8066 cat > conftest.$ac_ext <<EOF
8067 #line 8068 "configure"
8068 #include "confdefs.h"
8069 #include <sys/types.h>
8070 #include <link.h>
8071 int main() {
8072 struct link_map lm; (void) lm.lm_addr;
8073 ; return 0; }
8074 EOF
8075 if { (eval echo configure:8076: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8076 rm -rf conftest*
8077 gdb_cv_have_struct_link_map_with_lm_members=yes
8078 else
8079 echo "configure: failed program was:" >&5
8080 cat conftest.$ac_ext >&5
8081 rm -rf conftest*
8082 gdb_cv_have_struct_link_map_with_lm_members=no
8083 fi
8084 rm -f conftest*
8085 fi
8086
8087 echo "$ac_t""$gdb_cv_have_struct_link_map_with_lm_members" 1>&6
8088 if test $gdb_cv_have_struct_link_map_with_lm_members = yes; then
8089 cat >> confdefs.h <<\EOF
8090 #define HAVE_STRUCT_LINK_MAP_WITH_LM_MEMBERS 1
8091 EOF
8092
8093 fi
8094
8095
8096 echo $ac_n "checking for member som_addr in struct so_map""... $ac_c" 1>&6
8097 echo "configure:8098: checking for member som_addr in struct so_map" >&5
8098 if eval "test \"`echo '$''{'gdb_cv_have_struct_so_map_with_som_members'+set}'`\" = set"; then
8099 echo $ac_n "(cached) $ac_c" 1>&6
8100 else
8101 cat > conftest.$ac_ext <<EOF
8102 #line 8103 "configure"
8103 #include "confdefs.h"
8104 #include <sys/types.h>
8105 #ifdef HAVE_NLIST_H
8106 #include <nlist.h>
8107 #endif
8108 #include <link.h>
8109 int main() {
8110 struct so_map lm; (void) lm.som_addr;
8111 ; return 0; }
8112 EOF
8113 if { (eval echo configure:8114: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8114 rm -rf conftest*
8115 gdb_cv_have_struct_so_map_with_som_members=yes
8116 else
8117 echo "configure: failed program was:" >&5
8118 cat conftest.$ac_ext >&5
8119 rm -rf conftest*
8120 gdb_cv_have_struct_so_map_with_som_members=no
8121 fi
8122 rm -f conftest*
8123 fi
8124
8125 echo "$ac_t""$gdb_cv_have_struct_so_map_with_som_members" 1>&6
8126 if test $gdb_cv_have_struct_so_map_with_som_members = yes; then
8127 cat >> confdefs.h <<\EOF
8128 #define HAVE_STRUCT_SO_MAP_WITH_SOM_MEMBERS 1
8129 EOF
8130
8131 fi
8132
8133
8134 echo $ac_n "checking for struct link_map32 in sys/link.h""... $ac_c" 1>&6
8135 echo "configure:8136: checking for struct link_map32 in sys/link.h" >&5
8136 if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map32'+set}'`\" = set"; then
8137 echo $ac_n "(cached) $ac_c" 1>&6
8138 else
8139 cat > conftest.$ac_ext <<EOF
8140 #line 8141 "configure"
8141 #include "confdefs.h"
8142 #define _SYSCALL32
8143 #include <sys/link.h>
8144 int main() {
8145 struct link_map32 l;
8146 ; return 0; }
8147 EOF
8148 if { (eval echo configure:8149: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8149 rm -rf conftest*
8150 gdb_cv_have_struct_link_map32=yes
8151 else
8152 echo "configure: failed program was:" >&5
8153 cat conftest.$ac_ext >&5
8154 rm -rf conftest*
8155 gdb_cv_have_struct_link_map32=no
8156 fi
8157 rm -f conftest*
8158 fi
8159
8160 echo "$ac_t""$gdb_cv_have_struct_link_map32" 1>&6
8161 if test $gdb_cv_have_struct_link_map32 = yes; then
8162 cat >> confdefs.h <<\EOF
8163 #define HAVE_STRUCT_LINK_MAP32 1
8164 EOF
8165
8166 cat >> confdefs.h <<\EOF
8167 #define _SYSCALL32 1
8168 EOF
8169
8170 fi
8171 fi
8172
8173
8174 echo $ac_n "checking for long long support in compiler""... $ac_c" 1>&6
8175 echo "configure:8176: checking for long long support in compiler" >&5
8176 if eval "test \"`echo '$''{'gdb_cv_c_long_long'+set}'`\" = set"; then
8177 echo $ac_n "(cached) $ac_c" 1>&6
8178 else
8179 cat > conftest.$ac_ext <<EOF
8180 #line 8181 "configure"
8181 #include "confdefs.h"
8182
8183 int main() {
8184
8185 extern long long foo;
8186 switch (foo & 2) { case 0: return 1; }
8187
8188 ; return 0; }
8189 EOF
8190 if { (eval echo configure:8191: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8191 rm -rf conftest*
8192 gdb_cv_c_long_long=yes
8193 else
8194 echo "configure: failed program was:" >&5
8195 cat conftest.$ac_ext >&5
8196 rm -rf conftest*
8197 gdb_cv_c_long_long=no
8198 fi
8199 rm -f conftest*
8200 fi
8201
8202 echo "$ac_t""$gdb_cv_c_long_long" 1>&6
8203 if test $gdb_cv_c_long_long = yes; then
8204 cat >> confdefs.h <<\EOF
8205 #define CC_HAS_LONG_LONG 1
8206 EOF
8207
8208 fi
8209
8210
8211 echo $ac_n "checking for long long support in printf""... $ac_c" 1>&6
8212 echo "configure:8213: checking for long long support in printf" >&5
8213 if eval "test \"`echo '$''{'gdb_cv_printf_has_long_long'+set}'`\" = set"; then
8214 echo $ac_n "(cached) $ac_c" 1>&6
8215 else
8216 if test "$cross_compiling" = yes; then
8217 gdb_cv_printf_has_long_long=no
8218 else
8219 cat > conftest.$ac_ext <<EOF
8220 #line 8221 "configure"
8221 #include "confdefs.h"
8222
8223 int main () {
8224 char buf[32];
8225 long long l = 0;
8226 l = (l << 16) + 0x0123;
8227 l = (l << 16) + 0x4567;
8228 l = (l << 16) + 0x89ab;
8229 l = (l << 16) + 0xcdef;
8230 sprintf (buf, "0x%016llx", l);
8231 return (strcmp ("0x0123456789abcdef", buf));
8232 }
8233 EOF
8234 if { (eval echo configure:8235: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8235 then
8236 gdb_cv_printf_has_long_long=yes
8237 else
8238 echo "configure: failed program was:" >&5
8239 cat conftest.$ac_ext >&5
8240 rm -fr conftest*
8241 gdb_cv_printf_has_long_long=no
8242 fi
8243 rm -fr conftest*
8244 fi
8245
8246 fi
8247
8248 if test $gdb_cv_printf_has_long_long = yes; then
8249 cat >> confdefs.h <<\EOF
8250 #define PRINTF_HAS_LONG_LONG 1
8251 EOF
8252
8253 fi
8254 echo "$ac_t""$gdb_cv_printf_has_long_long" 1>&6
8255
8256
8257 echo $ac_n "checking for long double support in compiler""... $ac_c" 1>&6
8258 echo "configure:8259: checking for long double support in compiler" >&5
8259 if eval "test \"`echo '$''{'ac_cv_c_long_double'+set}'`\" = set"; then
8260 echo $ac_n "(cached) $ac_c" 1>&6
8261 else
8262 cat > conftest.$ac_ext <<EOF
8263 #line 8264 "configure"
8264 #include "confdefs.h"
8265
8266 int main() {
8267 long double foo;
8268 ; return 0; }
8269 EOF
8270 if { (eval echo configure:8271: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8271 rm -rf conftest*
8272 ac_cv_c_long_double=yes
8273 else
8274 echo "configure: failed program was:" >&5
8275 cat conftest.$ac_ext >&5
8276 rm -rf conftest*
8277 ac_cv_c_long_double=no
8278 fi
8279 rm -f conftest*
8280 fi
8281
8282 echo "$ac_t""$ac_cv_c_long_double" 1>&6
8283 if test $ac_cv_c_long_double = yes; then
8284 cat >> confdefs.h <<\EOF
8285 #define HAVE_LONG_DOUBLE 1
8286 EOF
8287
8288 fi
8289
8290
8291 echo $ac_n "checking for long double support in printf""... $ac_c" 1>&6
8292 echo "configure:8293: checking for long double support in printf" >&5
8293 if eval "test \"`echo '$''{'gdb_cv_printf_has_long_double'+set}'`\" = set"; then
8294 echo $ac_n "(cached) $ac_c" 1>&6
8295 else
8296 if test "$cross_compiling" = yes; then
8297 gdb_cv_printf_has_long_double=no
8298 else
8299 cat > conftest.$ac_ext <<EOF
8300 #line 8301 "configure"
8301 #include "confdefs.h"
8302
8303 int main () {
8304 char buf[16];
8305 long double f = 3.141592653;
8306 sprintf (buf, "%Lg", f);
8307 return (strncmp ("3.14159", buf, 7));
8308 }
8309 EOF
8310 if { (eval echo configure:8311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8311 then
8312 gdb_cv_printf_has_long_double=yes
8313 else
8314 echo "configure: failed program was:" >&5
8315 cat conftest.$ac_ext >&5
8316 rm -fr conftest*
8317 gdb_cv_printf_has_long_double=no
8318 fi
8319 rm -fr conftest*
8320 fi
8321
8322 fi
8323
8324 if test $gdb_cv_printf_has_long_double = yes; then
8325 cat >> confdefs.h <<\EOF
8326 #define PRINTF_HAS_LONG_DOUBLE 1
8327 EOF
8328
8329 fi
8330 echo "$ac_t""$gdb_cv_printf_has_long_double" 1>&6
8331
8332
8333 echo $ac_n "checking for long double support in scanf""... $ac_c" 1>&6
8334 echo "configure:8335: checking for long double support in scanf" >&5
8335 if eval "test \"`echo '$''{'gdb_cv_scanf_has_long_double'+set}'`\" = set"; then
8336 echo $ac_n "(cached) $ac_c" 1>&6
8337 else
8338 if test "$cross_compiling" = yes; then
8339 gdb_cv_scanf_has_long_double=no
8340 else
8341 cat > conftest.$ac_ext <<EOF
8342 #line 8343 "configure"
8343 #include "confdefs.h"
8344
8345 int main () {
8346 char *buf = "3.141592653";
8347 long double f = 0;
8348 sscanf (buf, "%Lg", &f);
8349 return !(f > 3.14159 && f < 3.14160);
8350 }
8351 EOF
8352 if { (eval echo configure:8353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
8353 then
8354 gdb_cv_scanf_has_long_double=yes
8355 else
8356 echo "configure: failed program was:" >&5
8357 cat conftest.$ac_ext >&5
8358 rm -fr conftest*
8359 gdb_cv_scanf_has_long_double=no
8360 fi
8361 rm -fr conftest*
8362 fi
8363
8364 fi
8365
8366 if test $gdb_cv_scanf_has_long_double = yes; then
8367 cat >> confdefs.h <<\EOF
8368 #define SCANF_HAS_LONG_DOUBLE 1
8369 EOF
8370
8371 fi
8372 echo "$ac_t""$gdb_cv_scanf_has_long_double" 1>&6
8373
8374 case ${host_os} in
8375 aix*)
8376 echo $ac_n "checking for -bbigtoc option""... $ac_c" 1>&6
8377 echo "configure:8378: checking for -bbigtoc option" >&5
8378 if eval "test \"`echo '$''{'gdb_cv_bigtoc'+set}'`\" = set"; then
8379 echo $ac_n "(cached) $ac_c" 1>&6
8380 else
8381
8382 SAVE_LDFLAGS=$LDFLAGS
8383
8384 case $GCC in
8385 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
8386 *) gdb_cv_bigtoc=-bbigtoc ;;
8387 esac
8388
8389 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
8390 cat > conftest.$ac_ext <<EOF
8391 #line 8392 "configure"
8392 #include "confdefs.h"
8393
8394 int main() {
8395 int i;
8396 ; return 0; }
8397 EOF
8398 if { (eval echo configure:8399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8399 :
8400 else
8401 echo "configure: failed program was:" >&5
8402 cat conftest.$ac_ext >&5
8403 rm -rf conftest*
8404 gdb_cv_bigtoc=
8405 fi
8406 rm -f conftest*
8407
8408 fi
8409
8410 echo "$ac_t""$gdb_cv_bigtoc" 1>&6
8411 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} ${gdb_cv_bigtoc}"
8412 ;;
8413 esac
8414
8415
8416
8417 if test ${build} = ${host} -a ${host} = ${target} ; then
8418 case ${host_os} in
8419 hpux*)
8420 echo $ac_n "checking for HPUX/OSF thread support""... $ac_c" 1>&6
8421 echo "configure:8422: checking for HPUX/OSF thread support" >&5
8422 if test -f /usr/include/dce/cma_config.h ; then
8423 if test "$GCC" = "yes" ; then
8424 echo "$ac_t""yes" 1>&6
8425 cat >> confdefs.h <<\EOF
8426 #define HAVE_HPUX_THREAD_SUPPORT 1
8427 EOF
8428
8429 CONFIG_LIB_OBS="${CONFIG_LIB_OBS} hpux-thread.o"
8430 CONFIG_SRCS="${CONFIG_SRCS} hpux-thread.c"
8431 else
8432 echo "$ac_t""no (suppressed because you are not using GCC)" 1>&6
8433 fi
8434 else
8435 echo "$ac_t""no" 1>&6
8436 fi
8437 ;;
8438 solaris*)
8439 # See if thread_db library is around for Solaris thread debugging.
8440 # Note that we must explicitly test for version 1 of the library
8441 # because version 0 (present on Solaris 2.4 or earlier) doesn't have
8442 # the same API.
8443 echo $ac_n "checking for Solaris thread debugging library""... $ac_c" 1>&6
8444 echo "configure:8445: checking for Solaris thread debugging library" >&5
8445 if test -f /usr/lib/libthread_db.so.1 ; then
8446 echo "$ac_t""yes" 1>&6
8447 cat >> confdefs.h <<\EOF
8448 #define HAVE_THREAD_DB_LIB 1
8449 EOF
8450
8451 CONFIG_LIB_OBS="${CONFIG_LIB_OBS} sol-thread.o"
8452 CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
8453 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
8454 echo "configure:8455: checking for dlopen in -ldl" >&5
8455 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
8456 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
8457 echo $ac_n "(cached) $ac_c" 1>&6
8458 else
8459 ac_save_LIBS="$LIBS"
8460 LIBS="-ldl $LIBS"
8461 cat > conftest.$ac_ext <<EOF
8462 #line 8463 "configure"
8463 #include "confdefs.h"
8464 /* Override any gcc2 internal prototype to avoid an error. */
8465 /* We use char because int might match the return type of a gcc2
8466 builtin and then its argument prototype would still apply. */
8467 char dlopen();
8468
8469 int main() {
8470 dlopen()
8471 ; return 0; }
8472 EOF
8473 if { (eval echo configure:8474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8474 rm -rf conftest*
8475 eval "ac_cv_lib_$ac_lib_var=yes"
8476 else
8477 echo "configure: failed program was:" >&5
8478 cat conftest.$ac_ext >&5
8479 rm -rf conftest*
8480 eval "ac_cv_lib_$ac_lib_var=no"
8481 fi
8482 rm -f conftest*
8483 LIBS="$ac_save_LIBS"
8484
8485 fi
8486 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
8487 echo "$ac_t""yes" 1>&6
8488 ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
8489 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
8490 cat >> confdefs.h <<EOF
8491 #define $ac_tr_lib 1
8492 EOF
8493
8494 LIBS="-ldl $LIBS"
8495
8496 else
8497 echo "$ac_t""no" 1>&6
8498 fi
8499
8500 if test "$GCC" = "yes" ; then
8501 # The GNU linker requires the -export-dynamic option to make
8502 # all symbols visible in the dynamic symbol table.
8503 hold_ldflags=$LDFLAGS
8504 echo $ac_n "checking for the ld -export-dynamic flag""... $ac_c" 1>&6
8505 echo "configure:8506: checking for the ld -export-dynamic flag" >&5
8506 LDFLAGS="${LDFLAGS} -Wl,-export-dynamic"
8507 cat > conftest.$ac_ext <<EOF
8508 #line 8509 "configure"
8509 #include "confdefs.h"
8510
8511 int main() {
8512 int i;
8513 ; return 0; }
8514 EOF
8515 if { (eval echo configure:8516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8516 rm -rf conftest*
8517 found=yes
8518 else
8519 echo "configure: failed program was:" >&5
8520 cat conftest.$ac_ext >&5
8521 rm -rf conftest*
8522 found=no
8523 fi
8524 rm -f conftest*
8525 LDFLAGS=$hold_ldflags
8526 echo "$ac_t""$found" 1>&6
8527 if test $found = yes; then
8528 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -Wl,-export-dynamic"
8529 fi
8530 fi
8531 # Sun randomly tweaked the prototypes in <proc_service.h>
8532 # at one point.
8533 echo $ac_n "checking if <proc_service.h> is old""... $ac_c" 1>&6
8534 echo "configure:8535: checking if <proc_service.h> is old" >&5
8535 if eval "test \"`echo '$''{'gdb_cv_proc_service_is_old'+set}'`\" = set"; then
8536 echo $ac_n "(cached) $ac_c" 1>&6
8537 else
8538
8539 cat > conftest.$ac_ext <<EOF
8540 #line 8541 "configure"
8541 #include "confdefs.h"
8542
8543 #include <proc_service.h>
8544 ps_err_e ps_pdwrite
8545 (struct ps_prochandle*, psaddr_t, const void*, size_t);
8546
8547 int main() {
8548
8549 ; return 0; }
8550 EOF
8551 if { (eval echo configure:8552: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8552 rm -rf conftest*
8553 gdb_cv_proc_service_is_old=no
8554 else
8555 echo "configure: failed program was:" >&5
8556 cat conftest.$ac_ext >&5
8557 rm -rf conftest*
8558 gdb_cv_proc_service_is_old=yes
8559 fi
8560 rm -f conftest*
8561
8562 fi
8563
8564 echo "$ac_t""$gdb_cv_proc_service_is_old" 1>&6
8565 if test $gdb_cv_proc_service_is_old = yes; then
8566 cat >> confdefs.h <<\EOF
8567 #define PROC_SERVICE_IS_OLD 1
8568 EOF
8569
8570 fi
8571 else
8572 echo "$ac_t""no" 1>&6
8573 fi
8574 ;;
8575 aix*)
8576 echo $ac_n "checking for AiX thread debugging library""... $ac_c" 1>&6
8577 echo "configure:8578: checking for AiX thread debugging library" >&5
8578 if eval "test \"`echo '$''{'gdb_cv_have_aix_thread_debug'+set}'`\" = set"; then
8579 echo $ac_n "(cached) $ac_c" 1>&6
8580 else
8581 cat > conftest.$ac_ext <<EOF
8582 #line 8583 "configure"
8583 #include "confdefs.h"
8584 #include <sys/pthdebug.h>
8585 int main() {
8586 #ifndef PTHDB_VERSION_3
8587 #error
8588 #endif
8589 ; return 0; }
8590 EOF
8591 if { (eval echo configure:8592: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8592 rm -rf conftest*
8593 gdb_cv_have_aix_thread_debug=yes
8594 else
8595 echo "configure: failed program was:" >&5
8596 cat conftest.$ac_ext >&5
8597 rm -rf conftest*
8598 gdb_cv_have_aix_thread_debug=no
8599 fi
8600 rm -f conftest*
8601 fi
8602
8603 echo "$ac_t""$gdb_cv_have_aix_thread_debug" 1>&6
8604 if test $gdb_cv_have_aix_thread_debug = yes; then
8605 CONFIG_SRCS="${CONFIG_SRCS} aix-thread.c"
8606 CONFIG_LIB_OBS="${CONFIG_LIB_OBS} aix-thread.o"
8607 CONFIG_LDFLAGS="${CONFIG_LDFLAGS} -lpthdebug"
8608 fi
8609 ;;
8610 esac
8611
8612 fi
8613
8614 if test "x$ac_cv_header_thread_db_h" = "xyes"; then
8615 echo $ac_n "checking whether <thread_db.h> has TD_NOTALLOC""... $ac_c" 1>&6
8616 echo "configure:8617: checking whether <thread_db.h> has TD_NOTALLOC" >&5
8617 if eval "test \"`echo '$''{'gdb_cv_thread_db_h_has_td_notalloc'+set}'`\" = set"; then
8618 echo $ac_n "(cached) $ac_c" 1>&6
8619 else
8620 cat > conftest.$ac_ext <<EOF
8621 #line 8622 "configure"
8622 #include "confdefs.h"
8623 #include <thread_db.h>
8624 int main() {
8625 int i = TD_NOTALLOC;
8626 ; return 0; }
8627 EOF
8628 if { (eval echo configure:8629: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8629 rm -rf conftest*
8630 gdb_cv_thread_db_h_has_td_notalloc=yes
8631 else
8632 echo "configure: failed program was:" >&5
8633 cat conftest.$ac_ext >&5
8634 rm -rf conftest*
8635 gdb_cv_thread_db_h_has_td_notalloc=no
8636
8637 fi
8638 rm -f conftest*
8639
8640 fi
8641
8642 echo "$ac_t""$gdb_cv_thread_db_h_has_td_notalloc" 1>&6
8643 fi
8644 if test "x$gdb_cv_thread_db_h_has_td_notalloc" = "xyes"; then
8645 cat >> confdefs.h <<\EOF
8646 #define THREAD_DB_HAS_TD_NOTALLOC 1
8647 EOF
8648
8649 fi
8650
8651
8652 # Check whether --with-sysroot or --without-sysroot was given.
8653 if test "${with_sysroot+set}" = set; then
8654 withval="$with_sysroot"
8655
8656 case ${with_sysroot} in
8657 yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
8658 *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
8659 esac
8660
8661 TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
8662
8663 if test "x$exec_prefix" = xNONE; then
8664 if test "x$prefix" = xNONE; then
8665 test_prefix=/usr/local
8666 else
8667 test_prefix=$prefix
8668 fi
8669 else
8670 test_prefix=$exec_prefix
8671 fi
8672 case ${TARGET_SYSTEM_ROOT} in
8673 "${test_prefix}"|"${test_prefix}/"*|\
8674 '${exec_prefix}'|'${exec_prefix}/'*)
8675 t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
8676 TARGET_SYSTEM_ROOT_DEFINE="$t"
8677 ;;
8678 esac
8679
8680 else
8681
8682 TARGET_SYSTEM_ROOT=
8683 TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
8684
8685 fi
8686
8687
8688
8689
8690 # NOTE: Don't add -Wall or -Wunused, they both include
8691 # -Wunused-parameter which reports bogus warnings.
8692 # NOTE: If you add to this list, remember to update
8693 # gdb/doc/gdbint.texinfo.
8694 build_warnings="-Wimplicit -Wreturn-type -Wcomment -Wtrigraphs \
8695 -Wformat -Wparentheses -Wpointer-arith -Wuninitialized"
8696 # Up for debate: -Wswitch -Wcomment -trigraphs -Wtrigraphs
8697 # -Wunused-function -Wunused-label -Wunused-variable -Wunused-value
8698 # -Wchar-subscripts -Wtraditional -Wshadow -Wcast-qual
8699 # -Wcast-align -Wwrite-strings -Wconversion -Wstrict-prototypes
8700 # -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls
8701 # -Woverloaded-virtual -Winline -Werror"
8702 # Check whether --enable-build-warnings or --disable-build-warnings was given.
8703 if test "${enable_build_warnings+set}" = set; then
8704 enableval="$enable_build_warnings"
8705 case "${enableval}" in
8706 yes) ;;
8707 no) build_warnings="-w";;
8708 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
8709 build_warnings="${build_warnings} ${t}";;
8710 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
8711 build_warnings="${t} ${build_warnings}";;
8712 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
8713 esac
8714 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
8715 echo "Setting compiler warning flags = $build_warnings" 6>&1
8716 fi
8717 fi
8718 # Check whether --enable-gdb-build-warnings or --disable-gdb-build-warnings was given.
8719 if test "${enable_gdb_build_warnings+set}" = set; then
8720 enableval="$enable_gdb_build_warnings"
8721 case "${enableval}" in
8722 yes) ;;
8723 no) build_warnings="-w";;
8724 ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
8725 build_warnings="${build_warnings} ${t}";;
8726 *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
8727 build_warnings="${t} ${build_warnings}";;
8728 *) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
8729 esac
8730 if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
8731 echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
8732 fi
8733 fi
8734 WARN_CFLAGS=""
8735 WERROR_CFLAGS=""
8736 if test "x${build_warnings}" != x -a "x$GCC" = xyes
8737 then
8738 echo $ac_n "checking compiler warning flags""... $ac_c" 1>&6
8739 echo "configure:8740: checking compiler warning flags" >&5
8740 # Separate out the -Werror flag as some files just cannot be
8741 # compiled with it enabled.
8742 for w in ${build_warnings}; do
8743 case $w in
8744 -Werr*) WERROR_CFLAGS=-Werror ;;
8745 *) # Check that GCC accepts it
8746 saved_CFLAGS="$CFLAGS"
8747 CFLAGS="$CFLAGS $w"
8748 cat > conftest.$ac_ext <<EOF
8749 #line 8750 "configure"
8750 #include "confdefs.h"
8751
8752 int main() {
8753
8754 ; return 0; }
8755 EOF
8756 if { (eval echo configure:8757: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
8757 rm -rf conftest*
8758 WARN_CFLAGS="${WARN_CFLAGS} $w"
8759 else
8760 echo "configure: failed program was:" >&5
8761 cat conftest.$ac_ext >&5
8762 fi
8763 rm -f conftest*
8764 CFLAGS="$saved_CFLAGS"
8765 esac
8766 done
8767 echo "$ac_t""${WARN_CFLAGS}${WERROR_CFLAGS}" 1>&6
8768 fi
8769
8770
8771
8772 MMALLOC_CFLAGS=
8773 MMALLOC=
8774
8775
8776
8777 # Check whether --with-mmalloc or --without-mmalloc was given.
8778 if test "${with_mmalloc+set}" = set; then
8779 withval="$with_mmalloc"
8780 case "${withval}" in
8781 yes) want_mmalloc=true ;;
8782 no) want_mmalloc=false;;
8783 *) { echo "configure: error: bad value ${withval} for GDB with-mmalloc option" 1>&2; exit 1; } ;;
8784 esac
8785 else
8786 want_mmalloc=false
8787 fi
8788
8789 if test x$want_mmalloc = xtrue; then
8790 cat >> confdefs.h <<\EOF
8791 #define USE_MMALLOC 1
8792 EOF
8793
8794 cat >> confdefs.h <<\EOF
8795 #define MMCHECK_FORCE 1
8796 EOF
8797
8798 MMALLOC_CFLAGS="-I$srcdir/../mmalloc"
8799 MMALLOC='../mmalloc/libmmalloc.a'
8800 fi
8801
8802 # In the Cygwin environment, we need some additional flags.
8803 echo $ac_n "checking for cygwin""... $ac_c" 1>&6
8804 echo "configure:8805: checking for cygwin" >&5
8805 if eval "test \"`echo '$''{'gdb_cv_os_cygwin'+set}'`\" = set"; then
8806 echo $ac_n "(cached) $ac_c" 1>&6
8807 else
8808 cat > conftest.$ac_ext <<EOF
8809 #line 8810 "configure"
8810 #include "confdefs.h"
8811
8812 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
8813 lose
8814 #endif
8815 EOF
8816 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8817 egrep "lose" >/dev/null 2>&1; then
8818 rm -rf conftest*
8819 gdb_cv_os_cygwin=yes
8820 else
8821 rm -rf conftest*
8822 gdb_cv_os_cygwin=no
8823 fi
8824 rm -f conftest*
8825
8826 fi
8827
8828 echo "$ac_t""$gdb_cv_os_cygwin" 1>&6
8829
8830
8831 SER_HARDWIRE="ser-unix.o ser-pipe.o ser-tcp.o"
8832 case ${host} in
8833 *go32* ) SER_HARDWIRE=ser-go32.o ;;
8834 *djgpp* ) SER_HARDWIRE=ser-go32.o ;;
8835 esac
8836
8837
8838 # libreadline needs libuser32.a in a cygwin environment
8839 WIN32LIBS=
8840 if test x$gdb_cv_os_cygwin = xyes; then
8841 WIN32LIBS="-luser32"
8842 case "${target}" in
8843 *cygwin*) WIN32LIBS="$WIN32LIBS -limagehlp"
8844 ;;
8845 esac
8846 fi
8847
8848
8849 LIBGUI="../libgui/src/libgui.a"
8850 GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
8851
8852
8853
8854 WIN32LDAPP=
8855
8856
8857
8858 configdir="unix"
8859
8860 GDBTKLIBS=
8861 if test "${enable_gdbtk}" = "yes"; then
8862
8863 # Gdbtk must have an absolute path to srcdir in order to run
8864 # properly when not installed.
8865 here=`pwd`
8866 cd ${srcdir}
8867 GDBTK_SRC_DIR=`pwd`
8868 cd $here
8869
8870
8871 #
8872 # Ok, lets find the tcl configuration
8873 # First, look for one uninstalled.
8874 # the alternative search directory is invoked by --with-tclconfig
8875 #
8876
8877 if test x"${no_tcl}" = x ; then
8878 # we reset no_tcl in case something fails here
8879 no_tcl=true
8880 # Check whether --with-tclconfig or --without-tclconfig was given.
8881 if test "${with_tclconfig+set}" = set; then
8882 withval="$with_tclconfig"
8883 with_tclconfig=${withval}
8884 fi
8885
8886 echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
8887 echo "configure:8888: checking for Tcl configuration" >&5
8888 if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
8889 echo $ac_n "(cached) $ac_c" 1>&6
8890 else
8891
8892
8893 # First check to see if --with-tclconfig was specified.
8894 if test x"${with_tclconfig}" != x ; then
8895 if test -f "${with_tclconfig}/tclConfig.sh" ; then
8896 ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
8897 else
8898 { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; }
8899 fi
8900 fi
8901
8902 # then check for a private Tcl installation
8903 if test x"${ac_cv_c_tclconfig}" = x ; then
8904 for i in \
8905 ../tcl \
8906 `ls -dr ../tcl[7-9]* 2>/dev/null` \
8907 ../../tcl \
8908 `ls -dr ../../tcl[7-9]* 2>/dev/null` \
8909 ../../../tcl \
8910 `ls -dr ../../../tcl[7-9]* 2>/dev/null` ; do
8911 if test -f "$i/${configdir}/tclConfig.sh" ; then
8912 ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)`
8913 break
8914 fi
8915 done
8916 fi
8917 # check in a few common install locations
8918 if test x"${ac_cv_c_tclconfig}" = x ; then
8919 for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
8920 if test -f "$i/tclConfig.sh" ; then
8921 ac_cv_c_tclconfig=`(cd $i; pwd)`
8922 break
8923 fi
8924 done
8925 fi
8926 # check in a few other private locations
8927 if test x"${ac_cv_c_tclconfig}" = x ; then
8928 for i in \
8929 ${srcdir}/../tcl \
8930 `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` ; do
8931 if test -f "$i/${configdir}/tclConfig.sh" ; then
8932 ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)`
8933 break
8934 fi
8935 done
8936 fi
8937
8938 fi
8939
8940 if test x"${ac_cv_c_tclconfig}" = x ; then
8941 TCLCONFIG="# no Tcl configs found"
8942 echo "configure: warning: Can't find Tcl configuration definitions" 1>&2
8943 else
8944 no_tcl=
8945 TCLCONFIG=${ac_cv_c_tclconfig}/tclConfig.sh
8946 echo "$ac_t""found $TCLCONFIG" 1>&6
8947 fi
8948 fi
8949
8950 if test -z "${no_tcl}"; then
8951
8952 . $TCLCONFIG
8953
8954
8955
8956
8957
8958
8959
8960
8961
8962
8963
8964
8965
8966
8967
8968
8969
8970
8971
8972
8973
8974
8975
8976
8977
8978
8979
8980 #
8981 # Ok, lets find the tk configuration
8982 # First, look for one uninstalled.
8983 # the alternative search directory is invoked by --with-tkconfig
8984 #
8985
8986 if test x"${no_tk}" = x ; then
8987 # we reset no_tk in case something fails here
8988 no_tk=true
8989 # Check whether --with-tkconfig or --without-tkconfig was given.
8990 if test "${with_tkconfig+set}" = set; then
8991 withval="$with_tkconfig"
8992 with_tkconfig=${withval}
8993 fi
8994
8995 echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6
8996 echo "configure:8997: checking for Tk configuration" >&5
8997 if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then
8998 echo $ac_n "(cached) $ac_c" 1>&6
8999 else
9000
9001
9002 # First check to see if --with-tkconfig was specified.
9003 if test x"${with_tkconfig}" != x ; then
9004 if test -f "${with_tkconfig}/tkConfig.sh" ; then
9005 ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
9006 else
9007 { echo "configure: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" 1>&2; exit 1; }
9008 fi
9009 fi
9010
9011 # then check for a private Tk library
9012 if test x"${ac_cv_c_tkconfig}" = x ; then
9013 for i in \
9014 ../tk \
9015 `ls -dr ../tk[4-9]* 2>/dev/null` \
9016 ../../tk \
9017 `ls -dr ../../tk[4-9]* 2>/dev/null` \
9018 ../../../tk \
9019 `ls -dr ../../../tk[4-9]* 2>/dev/null` ; do
9020 if test -f "$i/${configdir}/tkConfig.sh" ; then
9021 ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)`
9022 break
9023 fi
9024 done
9025 fi
9026 # check in a few common install locations
9027 if test x"${ac_cv_c_tkconfig}" = x ; then
9028 for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
9029 if test -f "$i/tkConfig.sh" ; then
9030 ac_cv_c_tkconfig=`(cd $i; pwd)`
9031 break
9032 fi
9033 done
9034 fi
9035 # check in a few other private locations
9036 if test x"${ac_cv_c_tkconfig}" = x ; then
9037 for i in \
9038 ${srcdir}/../tk \
9039 `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` ; do
9040 if test -f "$i/${configdir}/tkConfig.sh" ; then
9041 ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)`
9042 break
9043 fi
9044 done
9045 fi
9046
9047 fi
9048
9049 if test x"${ac_cv_c_tkconfig}" = x ; then
9050 TKCONFIG="# no Tk configs found"
9051 echo "configure: warning: Can't find Tk configuration definitions" 1>&2
9052 else
9053 no_tk=
9054 TKCONFIG=${ac_cv_c_tkconfig}/tkConfig.sh
9055 echo "$ac_t""found $TKCONFIG" 1>&6
9056 fi
9057 fi
9058
9059
9060
9061 # now look for Tcl library stuff
9062
9063 case "${host}" in
9064 *-*-cygwin*)
9065 tcldir=../tcl/win/
9066 ;;
9067 *)
9068 tcldir=../tcl/unix/
9069 ;;
9070 esac
9071
9072 TCL_DEPS="${tcldir}${TCL_LIB_FILE}"
9073
9074 # If $no_tk is nonempty, then we can't do Tk, and there is no
9075 # point to doing Tcl.
9076 if test -z "${no_tk}"; then
9077
9078 if test -f "$TKCONFIG" ; then
9079 . $TKCONFIG
9080 fi
9081
9082
9083
9084
9085
9086
9087
9088
9089
9090
9091
9092
9093
9094
9095 #
9096 # Ok, lets find the tcl source trees so we can use the headers
9097 # Warning: transition of version 9 to 10 will break this algorithm
9098 # because 10 sorts before 9. We also look for just tcl. We have to
9099 # be careful that we don't match stuff like tclX by accident.
9100 # the alternative search directory is involked by --with-tclinclude
9101 #
9102
9103 no_tcl=true
9104 echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6
9105 echo "configure:9106: checking for Tcl private headers. dir=${configdir}" >&5
9106 # Check whether --with-tclinclude or --without-tclinclude was given.
9107 if test "${with_tclinclude+set}" = set; then
9108 withval="$with_tclinclude"
9109 with_tclinclude=${withval}
9110 fi
9111
9112 if eval "test \"`echo '$''{'ac_cv_c_tclh'+set}'`\" = set"; then
9113 echo $ac_n "(cached) $ac_c" 1>&6
9114 else
9115
9116 # first check to see if --with-tclinclude was specified
9117 if test x"${with_tclinclude}" != x ; then
9118 if test -f ${with_tclinclude}/tclInt.h ; then
9119 ac_cv_c_tclh=`(cd ${with_tclinclude}; pwd)`
9120 elif test -f ${with_tclinclude}/generic/tclInt.h ; then
9121 ac_cv_c_tclh=`(cd ${with_tclinclude}/generic; pwd)`
9122 else
9123 { echo "configure: error: ${with_tclinclude} directory doesn't contain private headers" 1>&2; exit 1; }
9124 fi
9125 fi
9126
9127 # next check if it came with Tcl configuration file
9128 if test x"${ac_cv_c_tclconfig}" = x ; then
9129 if test -f $ac_cv_c_tclconfig/../generic/tclInt.h ; then
9130 ac_cv_c_tclh=`(cd $ac_cv_c_tclconfig/..; pwd)`
9131 fi
9132 fi
9133
9134 # next check in private source directory
9135 #
9136 # since ls returns lowest version numbers first, reverse its output
9137 if test x"${ac_cv_c_tclh}" = x ; then
9138 for i in \
9139 ${srcdir}/../tcl \
9140 `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` \
9141 ${srcdir}/../../tcl \
9142 `ls -dr ${srcdir}/../../tcl[7-9]* 2>/dev/null` \
9143 ${srcdir}/../../../tcl \
9144 `ls -dr ${srcdir}/../../../tcl[7-9]* 2>/dev/null ` ; do
9145 if test -f $i/generic/tclInt.h ; then
9146 ac_cv_c_tclh=`(cd $i/generic; pwd)`
9147 break
9148 fi
9149 done
9150 fi
9151 # finally check in a few common install locations
9152 #
9153 # since ls returns lowest version numbers first, reverse its output
9154 if test x"${ac_cv_c_tclh}" = x ; then
9155 for i in \
9156 `ls -dr /usr/local/src/tcl[7-9]* 2>/dev/null` \
9157 `ls -dr /usr/local/lib/tcl[7-9]* 2>/dev/null` \
9158 /usr/local/src/tcl \
9159 /usr/local/lib/tcl \
9160 ${prefix}/include ; do
9161 if test -f $i/generic/tclInt.h ; then
9162 ac_cv_c_tclh=`(cd $i/generic; pwd)`
9163 break
9164 fi
9165 done
9166 fi
9167 # see if one is installed
9168 if test x"${ac_cv_c_tclh}" = x ; then
9169 ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'`
9170 echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6
9171 echo "configure:9172: checking for tclInt.h" >&5
9172 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
9173 echo $ac_n "(cached) $ac_c" 1>&6
9174 else
9175 cat > conftest.$ac_ext <<EOF
9176 #line 9177 "configure"
9177 #include "confdefs.h"
9178 #include <tclInt.h>
9179 EOF
9180 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
9181 { (eval echo configure:9182: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
9182 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
9183 if test -z "$ac_err"; then
9184 rm -rf conftest*
9185 eval "ac_cv_header_$ac_safe=yes"
9186 else
9187 echo "$ac_err" >&5
9188 echo "configure: failed program was:" >&5
9189 cat conftest.$ac_ext >&5
9190 rm -rf conftest*
9191 eval "ac_cv_header_$ac_safe=no"
9192 fi
9193 rm -f conftest*
9194 fi
9195 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
9196 echo "$ac_t""yes" 1>&6
9197 ac_cv_c_tclh=installed
9198 else
9199 echo "$ac_t""no" 1>&6
9200 ac_cv_c_tclh=""
9201 fi
9202
9203 fi
9204
9205 fi
9206
9207 if test x"${ac_cv_c_tclh}" = x ; then
9208 TCLHDIR="# no Tcl private headers found"
9209 { echo "configure: error: Can't find Tcl private headers" 1>&2; exit 1; }
9210 fi
9211 if test x"${ac_cv_c_tclh}" != x ; then
9212 no_tcl=""
9213 if test x"${ac_cv_c_tclh}" = x"installed" ; then
9214 echo "$ac_t""is installed" 1>&6
9215 TCLHDIR=""
9216 else
9217 echo "$ac_t""found in ${ac_cv_c_tclh}" 1>&6
9218 # this hack is cause the TCLHDIR won't print if there is a "-I" in it.
9219 TCLHDIR="-I${ac_cv_c_tclh}"
9220 fi
9221 fi
9222
9223
9224
9225
9226 #
9227 # Ok, lets find the tk source trees so we can use the headers
9228 # If the directory (presumably symlink) named "tk" exists, use that one
9229 # in preference to any others. Same logic is used when choosing library
9230 # and again with Tcl. The search order is the best place to look first, then in
9231 # decreasing significance. The loop breaks if the trigger file is found.
9232 # Note the gross little conversion here of srcdir by cd'ing to the found
9233 # directory. This converts the path from a relative to an absolute, so
9234 # recursive cache variables for the path will work right. We check all
9235 # the possible paths in one loop rather than many seperate loops to speed
9236 # things up.
9237 # the alternative search directory is involked by --with-tkinclude
9238 #
9239 no_tk=true
9240 echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6
9241 echo "configure:9242: checking for Tk private headers" >&5
9242 # Check whether --with-tkinclude or --without-tkinclude was given.
9243 if test "${with_tkinclude+set}" = set; then
9244 withval="$with_tkinclude"
9245 with_tkinclude=${withval}
9246 fi
9247
9248 if eval "test \"`echo '$''{'ac_cv_c_tkh'+set}'`\" = set"; then
9249 echo $ac_n "(cached) $ac_c" 1>&6
9250 else
9251
9252 # first check to see if --with-tkinclude was specified
9253 if test x"${with_tkinclude}" != x ; then
9254 if test -f ${with_tkinclude}/tk.h ; then
9255 ac_cv_c_tkh=`(cd ${with_tkinclude}; pwd)`
9256 elif test -f ${with_tkinclude}/generic/tk.h ; then
9257 ac_cv_c_tkh=`(cd ${with_tkinclude}/generic; pwd)`
9258 else
9259 { echo "configure: error: ${with_tkinclude} directory doesn't contain private headers" 1>&2; exit 1; }
9260 fi
9261 fi
9262
9263 # next check if it came with Tk configuration file
9264 if test x"${ac_cv_c_tkconfig}" = x ; then
9265 if test -f $ac_cv_c_tkconfig/../generic/tk.h ; then
9266 ac_cv_c_tkh=`(cd $ac_cv_c_tkconfig/..; pwd)`
9267 fi
9268 fi
9269
9270 # next check in private source directory
9271 #
9272 # since ls returns lowest version numbers first, reverse its output
9273 if test x"${ac_cv_c_tkh}" = x ; then
9274 for i in \
9275 ${srcdir}/../tk \
9276 `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` \
9277 ${srcdir}/../../tk \
9278 `ls -dr ${srcdir}/../../tk[4-9]* 2>/dev/null` \
9279 ${srcdir}/../../../tk \
9280 `ls -dr ${srcdir}/../../../tk[4-9]* 2>/dev/null ` ; do
9281 if test -f $i/generic/tk.h ; then
9282 ac_cv_c_tkh=`(cd $i/generic; pwd)`
9283 break
9284 fi
9285 done
9286 fi
9287 # finally check in a few common install locations
9288 #
9289 # since ls returns lowest version numbers first, reverse its output
9290 if test x"${ac_cv_c_tkh}" = x ; then
9291 for i in \
9292 `ls -dr /usr/local/src/tk[4-9]* 2>/dev/null` \
9293 `ls -dr /usr/local/lib/tk[4-9]* 2>/dev/null` \
9294 /usr/local/src/tk \
9295 /usr/local/lib/tk \
9296 ${prefix}/include ; do
9297 if test -f $i/generic/tk.h ; then
9298 ac_cv_c_tkh=`(cd $i/generic; pwd)`
9299 break
9300 fi
9301 done
9302 fi
9303 # see if one is installed
9304 if test x"${ac_cv_c_tkh}" = x ; then
9305 ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'`
9306 echo $ac_n "checking for tk.h""... $ac_c" 1>&6
9307 echo "configure:9308: checking for tk.h" >&5
9308 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
9309 echo $ac_n "(cached) $ac_c" 1>&6
9310 else
9311 cat > conftest.$ac_ext <<EOF
9312 #line 9313 "configure"
9313 #include "confdefs.h"
9314 #include <tk.h>
9315 EOF
9316 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
9317 { (eval echo configure:9318: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
9318 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
9319 if test -z "$ac_err"; then
9320 rm -rf conftest*
9321 eval "ac_cv_header_$ac_safe=yes"
9322 else
9323 echo "$ac_err" >&5
9324 echo "configure: failed program was:" >&5
9325 cat conftest.$ac_ext >&5
9326 rm -rf conftest*
9327 eval "ac_cv_header_$ac_safe=no"
9328 fi
9329 rm -f conftest*
9330 fi
9331 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
9332 echo "$ac_t""yes" 1>&6
9333 ac_cv_c_tkh=installed
9334 else
9335 echo "$ac_t""no" 1>&6
9336 ac_cv_c_tkh=""
9337 fi
9338
9339 fi
9340
9341 fi
9342
9343 if test x"${ac_cv_c_tkh}" != x ; then
9344 no_tk=""
9345 if test x"${ac_cv_c_tkh}" = x"installed" ; then
9346 echo "$ac_t""is installed" 1>&6
9347 TKHDIR=""
9348 else
9349 echo "$ac_t""found in ${ac_cv_c_tkh}" 1>&6
9350 # this hack is cause the TKHDIR won't print if there is a "-I" in it.
9351 TKHDIR="-I${ac_cv_c_tkh}"
9352 fi
9353 else
9354 TKHDIR="# no Tk directory found"
9355 echo "configure: warning: Can't find Tk private headers" 1>&2
9356 no_tk=true
9357 fi
9358
9359
9360
9361
9362 echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6
9363 echo "configure:9364: checking for Itcl private headers. srcdir=${srcdir}" >&5
9364 if test x"${ac_cv_c_itclh}" = x ; then
9365 for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itcl; do
9366 if test -f $i/generic/itcl.h ; then
9367 ac_cv_c_itclh=`(cd $i/generic; pwd)`
9368 break
9369 fi
9370 done
9371 fi
9372 if test x"${ac_cv_c_itclh}" = x ; then
9373 ITCLHDIR="# no Itcl private headers found"
9374 { echo "configure: error: Can't find Itcl private headers" 1>&2; exit 1; }
9375 fi
9376 if test x"${ac_cv_c_itclh}" != x ; then
9377 ITCLHDIR="-I${ac_cv_c_itclh}"
9378 fi
9379 # should always be here
9380 # ITCLLIB="../itcl/itcl/unix/libitcl.a"
9381
9382 #AC_SUBST(ITCLLIB)
9383
9384
9385 echo $ac_n "checking for Itk private headers. srcdir=${srcdir}""... $ac_c" 1>&6
9386 echo "configure:9387: checking for Itk private headers. srcdir=${srcdir}" >&5
9387 if test x"${ac_cv_c_itkh}" = x ; then
9388 for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itk; do
9389 if test -f $i/generic/itk.h ; then
9390 ac_cv_c_itkh=`(cd $i/generic; pwd)`
9391 break
9392 fi
9393 done
9394 fi
9395 if test x"${ac_cv_c_itkh}" = x ; then
9396 ITKHDIR="# no Itk private headers found"
9397 { echo "configure: error: Can't find Itk private headers" 1>&2; exit 1; }
9398 fi
9399 if test x"${ac_cv_c_itkh}" != x ; then
9400 ITKHDIR="-I${ac_cv_c_itkh}"
9401 fi
9402 # should always be here
9403 # ITKLIB="../itcl/itk/unix/libitk.a"
9404
9405 #AC_SUBST(ITKLIB)
9406
9407
9408
9409 # now look for Tk library stuff
9410
9411 case "${host}" in
9412 *-*-cygwin*)
9413 tkdir=../tk/win/
9414 ;;
9415 *)
9416 tkdir=../tk/unix/
9417 ;;
9418 esac
9419
9420 TK_DEPS="${tkdir}${TK_LIB_FILE}"
9421
9422 # now look for Itcl library stuff
9423
9424
9425 #
9426 # Ok, lets find the itcl configuration
9427 # First, look for one uninstalled.
9428 # the alternative search directory is invoked by --with-itclconfig
9429 #
9430
9431 if test x"${no_itcl}" = x ; then
9432 # we reset no_itcl in case something fails here
9433 no_itcl=true
9434 # Check whether --with-itclconfig or --without-itclconfig was given.
9435 if test "${with_itclconfig+set}" = set; then
9436 withval="$with_itclconfig"
9437 with_itclconfig=${withval}
9438 fi
9439
9440 echo $ac_n "checking for Itcl configuration""... $ac_c" 1>&6
9441 echo "configure:9442: checking for Itcl configuration" >&5
9442 if eval "test \"`echo '$''{'ac_cv_c_itclconfig'+set}'`\" = set"; then
9443 echo $ac_n "(cached) $ac_c" 1>&6
9444 else
9445
9446
9447 # First check to see if --with-itclconfig was specified.
9448 if test x"${with_itclconfig}" != x ; then
9449 if test -f "${with_itclconfig}/itclConfig.sh" ; then
9450 ac_cv_c_itclconfig=`(cd ${with_itclconfig}; pwd)`
9451 else
9452 { echo "configure: error: ${with_itclconfig} directory doesn't contain itclConfig.sh" 1>&2; exit 1; }
9453 fi
9454 fi
9455
9456 # then check for a private Itcl library
9457 if test x"${ac_cv_c_itclconfig}" = x ; then
9458 for i in \
9459 ../itcl/itcl \
9460 `ls -dr ../itcl[4-9]*/itcl 2>/dev/null` \
9461 ../../itcl \
9462 `ls -dr ../../itcl[4-9]*/itcl 2>/dev/null` \
9463 ../../../itcl \
9464 `ls -dr ../../../itcl[4-9]*/itcl 2>/dev/null` ; do
9465 if test -f "$i/itclConfig.sh" ; then
9466 ac_cv_c_itclconfig=`(cd $i; pwd)`
9467 break
9468 fi
9469 done
9470 fi
9471 # check in a few common install locations
9472 if test x"${ac_cv_c_itclconfig}" = x ; then
9473 for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
9474 if test -f "$i/itclConfig.sh" ; then
9475 ac_cv_c_itclconfig=`(cd $i; pwd)`
9476 break
9477 fi
9478 done
9479 fi
9480 # check in a few other private locations
9481 if test x"${ac_cv_c_itclconfig}" = x ; then
9482 for i in \
9483 ${srcdir}/../itcl/itcl \
9484 `ls -dr ${srcdir}/../itcl[4-9]*/itcl 2>/dev/null` ; do
9485 if test -f "$i/itclConfig.sh" ; then
9486 ac_cv_c_itclconfig=`(cd $i; pwd)`
9487 break
9488 fi
9489 done
9490 fi
9491
9492 fi
9493
9494 if test x"${ac_cv_c_itclconfig}" = x ; then
9495 ITCLCONFIG="# no Itcl configs found"
9496 echo "configure: warning: Can't find Itcl configuration definitions" 1>&2
9497 else
9498 no_itcl=
9499 ITCLCONFIG=${ac_cv_c_itclconfig}/itclConfig.sh
9500 echo "$ac_t""found $ITCLCONFIG" 1>&6
9501 fi
9502 fi
9503
9504 if test -z "${no_itcl}"; then
9505
9506 if test -f "$ITCLCONFIG" ; then
9507 . $ITCLCONFIG
9508 fi
9509
9510
9511
9512
9513
9514
9515
9516
9517
9518
9519
9520
9521 ITCLLIB="${ITCL_BUILD_LIB_SPEC}"
9522 ITCL_DEPS="${ITCL_LIB_FULL_PATH}"
9523 fi
9524
9525
9526 # now look for Itk library stuff
9527
9528 #
9529 # Ok, lets find the itk configuration
9530 # First, look for one uninstalled.
9531 # the alternative search directory is invoked by --with-itkconfig
9532 #
9533
9534 if test x"${no_itk}" = x ; then
9535 # we reset no_itk in case something fails here
9536 no_itk=true
9537 # Check whether --with-itkconfig or --without-itkconfig was given.
9538 if test "${with_itkconfig+set}" = set; then
9539 withval="$with_itkconfig"
9540 with_itkconfig=${withval}
9541 fi
9542
9543 echo $ac_n "checking for Itk configuration""... $ac_c" 1>&6
9544 echo "configure:9545: checking for Itk configuration" >&5
9545 if eval "test \"`echo '$''{'ac_cv_c_itkconfig'+set}'`\" = set"; then
9546 echo $ac_n "(cached) $ac_c" 1>&6
9547 else
9548
9549
9550 # First check to see if --with-itkconfig was specified.
9551 if test x"${with_itkconfig}" != x ; then
9552 if test -f "${with_itkconfig}/itkConfig.sh" ; then
9553 ac_cv_c_itkconfig=`(cd ${with_itkconfig}; pwd)`
9554 else
9555 { echo "configure: error: ${with_itkconfig} directory doesn't contain itkConfig.sh" 1>&2; exit 1; }
9556 fi
9557 fi
9558
9559 # then check for a private Itk library
9560 if test x"${ac_cv_c_itkconfig}" = x ; then
9561 for i in \
9562 ../itcl/itk \
9563 `ls -dr ../itcl[4-9]*/itk 2>/dev/null` \
9564 ../../itk \
9565 `ls -dr ../../itcl[4-9]*/itk 2>/dev/null` \
9566 ../../../itk \
9567 `ls -dr ../../../itcl[4-9]*/itk 2>/dev/null` ; do
9568 if test -f "$i/itkConfig.sh" ; then
9569 ac_cv_c_itkconfig=`(cd $i; pwd)`
9570 break
9571 fi
9572 done
9573 fi
9574 # check in a few common install locations
9575 if test x"${ac_cv_c_itkconfig}" = x ; then
9576 for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
9577 if test -f "$i/itkConfig.sh" ; then
9578 ac_cv_c_itkconfig=`(cd $i; pwd)`
9579 break
9580 fi
9581 done
9582 fi
9583 # check in a few other private locations
9584 if test x"${ac_cv_c_itkconfig}" = x ; then
9585 for i in \
9586 ${srcdir}/../itcl/itk \
9587 `ls -dr ${srcdir}/../itcl[4-9]*/itk 2>/dev/null` ; do
9588 if test -f "$i/itkConfig.sh" ; then
9589 ac_cv_c_itkconfig=`(cd $i; pwd)`
9590 break
9591 fi
9592 done
9593 fi
9594
9595 fi
9596
9597 if test x"${ac_cv_c_itkconfig}" = x ; then
9598 ITKCONFIG="# no Itk configs found"
9599 echo "configure: warning: Can't find Itk configuration definitions" 1>&2
9600 else
9601 no_itk=
9602 ITKCONFIG=${ac_cv_c_itkconfig}/itkConfig.sh
9603 echo "$ac_t""found $ITKCONFIG" 1>&6
9604 fi
9605 fi
9606
9607
9608 if test -z "${no_itcl}"; then
9609
9610 if test -f "$ITKCONFIG" ; then
9611 . $ITKCONFIG
9612 fi
9613
9614
9615
9616
9617
9618
9619
9620
9621
9622
9623
9624
9625 ITKLIB="${ITK_BUILD_LIB_SPEC}"
9626 ITK_DEPS="${ITK_LIB_FULL_PATH}"
9627 fi
9628
9629 ENABLE_CFLAGS="${ENABLE_CFLAGS} \$(SUBDIR_GDBTK_CFLAGS)"
9630 # Tcl/Tk 8.1 require -fwritable strings. I don't
9631 # know whether 8.2 will or not, but I bet it will.
9632 # I don't have to worry about 7.x since we don't support it.
9633 GDBTK_CFLAGS=""
9634 if test "$GCC" = "yes"; then
9635 if test "$TCL_VERSION" != "8.0" ; then
9636 GDBTK_CFLAGS="-fwritable-strings"
9637 fi
9638 fi
9639
9640 # Include some libraries that Tcl and Tk want.
9641 TCL_LIBS='$(LIBGUI) $(ITCL) $(ITK) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
9642 # Yes, the ordering seems wrong here. But it isn't.
9643 # TK_LIBS is the list of libraries that need to be linked
9644 # after Tcl/Tk. Note that this isn't put into LIBS. If it
9645 # were in LIBS then any link tests after this point would
9646 # try to include things like `$(LIBGUI)', which wouldn't work.
9647 GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
9648
9649 CONFIG_OBS="${CONFIG_OBS} \$(SUBDIR_GDBTK_OBS)"
9650 CONFIG_DEPS="${CONFIG_DEPS} \$(SUBDIR_GDBTK_DEPS)"
9651 CONFIG_SRCS="${CONFIG_SRCS} \$(SUBDIR_GDBTK_SRCS)"
9652 CONFIG_INITS="${CONFIG_INITS} \$(SUBDIR_GDBTK_INITS)"
9653 CONFIG_ALL="${CONFIG_ALL} \$(SUBDIR_GDBTK_ALL)"
9654 CONFIG_CLEAN="${CONFIG_CLEAN} \$(SUBDIR_GDBTK_CLEAN)"
9655 CONFIG_INSTALL="${CONFIG_INSTALL} \$(SUBDIR_GDBTK_INSTALL)"
9656 CONFIG_UNINSTALL="${CONFIG_UNINSTALL} \$(SUBDIR_GDBTK_UNINSTALL)"
9657
9658 if test x$gdb_cv_os_cygwin = xyes; then
9659 WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
9660 WIN32LDAPP="-Wl,--subsystem,console"
9661 CONFIG_OBS="${CONFIG_OBS} gdbres.o"
9662 fi
9663 fi
9664 fi
9665
9666 configdirs="${configdirs} gdbtk"
9667 fi
9668
9669
9670
9671
9672
9673
9674
9675
9676
9677
9678
9679
9680
9681
9682 # If we find X, set shell vars x_includes and x_libraries to the
9683 # paths, otherwise set no_x=yes.
9684 # Uses ac_ vars as temps to allow command line to override cache and checks.
9685 # --without-x overrides everything else, but does not touch the cache.
9686 echo $ac_n "checking for X""... $ac_c" 1>&6
9687 echo "configure:9688: checking for X" >&5
9688
9689 # Check whether --with-x or --without-x was given.
9690 if test "${with_x+set}" = set; then
9691 withval="$with_x"
9692 :
9693 fi
9694
9695 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9696 if test "x$with_x" = xno; then
9697 # The user explicitly disabled X.
9698 have_x=disabled
9699 else
9700 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9701 # Both variables are already set.
9702 have_x=yes
9703 else
9704 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
9705 echo $ac_n "(cached) $ac_c" 1>&6
9706 else
9707 # One or both of the vars are not set, and there is no cached value.
9708 ac_x_includes=NO ac_x_libraries=NO
9709 rm -fr conftestdir
9710 if mkdir conftestdir; then
9711 cd conftestdir
9712 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9713 cat > Imakefile <<'EOF'
9714 acfindx:
9715 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9716 EOF
9717 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9718 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9719 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
9720 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9721 for ac_extension in a so sl; do
9722 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
9723 test -f $ac_im_libdir/libX11.$ac_extension; then
9724 ac_im_usrlibdir=$ac_im_libdir; break
9725 fi
9726 done
9727 # Screen out bogus values from the imake configuration. They are
9728 # bogus both because they are the default anyway, and because
9729 # using them would break gcc on systems where it needs fixed includes.
9730 case "$ac_im_incroot" in
9731 /usr/include) ;;
9732 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
9733 esac
9734 case "$ac_im_usrlibdir" in
9735 /usr/lib | /lib) ;;
9736 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
9737 esac
9738 fi
9739 cd ..
9740 rm -fr conftestdir
9741 fi
9742
9743 if test "$ac_x_includes" = NO; then
9744 # Guess where to find include files, by looking for this one X11 .h file.
9745 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
9746
9747 # First, try using that file with no special directory specified.
9748 cat > conftest.$ac_ext <<EOF
9749 #line 9750 "configure"
9750 #include "confdefs.h"
9751 #include <$x_direct_test_include>
9752 EOF
9753 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
9754 { (eval echo configure:9755: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
9755 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
9756 if test -z "$ac_err"; then
9757 rm -rf conftest*
9758 # We can compile using X headers with no special include directory.
9759 ac_x_includes=
9760 else
9761 echo "$ac_err" >&5
9762 echo "configure: failed program was:" >&5
9763 cat conftest.$ac_ext >&5
9764 rm -rf conftest*
9765 # Look for the header file in a standard set of common directories.
9766 # Check X11 before X11Rn because it is often a symlink to the current release.
9767 for ac_dir in \
9768 /usr/X11/include \
9769 /usr/X11R6/include \
9770 /usr/X11R5/include \
9771 /usr/X11R4/include \
9772 \
9773 /usr/include/X11 \
9774 /usr/include/X11R6 \
9775 /usr/include/X11R5 \
9776 /usr/include/X11R4 \
9777 \
9778 /usr/local/X11/include \
9779 /usr/local/X11R6/include \
9780 /usr/local/X11R5/include \
9781 /usr/local/X11R4/include \
9782 \
9783 /usr/local/include/X11 \
9784 /usr/local/include/X11R6 \
9785 /usr/local/include/X11R5 \
9786 /usr/local/include/X11R4 \
9787 \
9788 /usr/X386/include \
9789 /usr/x386/include \
9790 /usr/XFree86/include/X11 \
9791 \
9792 /usr/include \
9793 /usr/local/include \
9794 /usr/unsupported/include \
9795 /usr/athena/include \
9796 /usr/local/x11r5/include \
9797 /usr/lpp/Xamples/include \
9798 \
9799 /usr/openwin/include \
9800 /usr/openwin/share/include \
9801 ; \
9802 do
9803 if test -r "$ac_dir/$x_direct_test_include"; then
9804 ac_x_includes=$ac_dir
9805 break
9806 fi
9807 done
9808 fi
9809 rm -f conftest*
9810 fi # $ac_x_includes = NO
9811
9812 if test "$ac_x_libraries" = NO; then
9813 # Check for the libraries.
9814
9815 test -z "$x_direct_test_library" && x_direct_test_library=Xt
9816 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
9817
9818 # See if we find them without any special options.
9819 # Don't add to $LIBS permanently.
9820 ac_save_LIBS="$LIBS"
9821 LIBS="-l$x_direct_test_library $LIBS"
9822 cat > conftest.$ac_ext <<EOF
9823 #line 9824 "configure"
9824 #include "confdefs.h"
9825
9826 int main() {
9827 ${x_direct_test_function}()
9828 ; return 0; }
9829 EOF
9830 if { (eval echo configure:9831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
9831 rm -rf conftest*
9832 LIBS="$ac_save_LIBS"
9833 # We can link X programs with no special library path.
9834 ac_x_libraries=
9835 else
9836 echo "configure: failed program was:" >&5
9837 cat conftest.$ac_ext >&5
9838 rm -rf conftest*
9839 LIBS="$ac_save_LIBS"
9840 # First see if replacing the include by lib works.
9841 # Check X11 before X11Rn because it is often a symlink to the current release.
9842 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
9843 /usr/X11/lib \
9844 /usr/X11R6/lib \
9845 /usr/X11R5/lib \
9846 /usr/X11R4/lib \
9847 \
9848 /usr/lib/X11 \
9849 /usr/lib/X11R6 \
9850 /usr/lib/X11R5 \
9851 /usr/lib/X11R4 \
9852 \
9853 /usr/local/X11/lib \
9854 /usr/local/X11R6/lib \
9855 /usr/local/X11R5/lib \
9856 /usr/local/X11R4/lib \
9857 \
9858 /usr/local/lib/X11 \
9859 /usr/local/lib/X11R6 \
9860 /usr/local/lib/X11R5 \
9861 /usr/local/lib/X11R4 \
9862 \
9863 /usr/X386/lib \
9864 /usr/x386/lib \
9865 /usr/XFree86/lib/X11 \
9866 \
9867 /usr/lib \
9868 /usr/local/lib \
9869 /usr/unsupported/lib \
9870 /usr/athena/lib \
9871 /usr/local/x11r5/lib \
9872 /usr/lpp/Xamples/lib \
9873 /lib/usr/lib/X11 \
9874 \
9875 /usr/openwin/lib \
9876 /usr/openwin/share/lib \
9877 ; \
9878 do
9879 for ac_extension in a so sl; do
9880 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
9881 ac_x_libraries=$ac_dir
9882 break 2
9883 fi
9884 done
9885 done
9886 fi
9887 rm -f conftest*
9888 fi # $ac_x_libraries = NO
9889
9890 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
9891 # Didn't find X anywhere. Cache the known absence of X.
9892 ac_cv_have_x="have_x=no"
9893 else
9894 # Record where we found X for the cache.
9895 ac_cv_have_x="have_x=yes \
9896 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9897 fi
9898 fi
9899 fi
9900 eval "$ac_cv_have_x"
9901 fi # $with_x != no
9902
9903 if test "$have_x" != yes; then
9904 echo "$ac_t""$have_x" 1>&6
9905 no_x=yes
9906 else
9907 # If each of the values was on the command line, it overrides each guess.
9908 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9909 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9910 # Update the cache value to reflect the command line values.
9911 ac_cv_have_x="have_x=yes \
9912 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9913 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
9914 fi
9915
9916
9917
9918 # Unlike the sim directory, whether a simulator is linked is controlled by
9919 # presence of a SIM= and a SIM_OBS= definition in the target '.mt' file.
9920 # This code just checks for a few cases where we'd like to ignore those
9921 # definitions, even when they're present in the '.mt' file. These cases
9922 # are when --disable-sim is specified, or if the simulator directory is
9923 # not part of the source tree.
9924 #
9925 # Check whether --enable-sim or --disable-sim was given.
9926 if test "${enable_sim+set}" = set; then
9927 enableval="$enable_sim"
9928 echo "enable_sim = $enable_sim";
9929 echo "enableval = ${enableval}";
9930 case "${enableval}" in
9931 yes) ignore_sim=false ;;
9932 no) ignore_sim=true ;;
9933 *) ignore_sim=false ;;
9934 esac
9935 else
9936 ignore_sim=false
9937 fi
9938
9939
9940 if test ! -d "${srcdir}/../sim"; then
9941 ignore_sim=true
9942 fi
9943
9944 if test "${ignore_sim}" = "true"; then
9945 IGNORE_SIM="SIM="
9946 IGNORE_SIM_OBS="SIM_OBS="
9947 else
9948 IGNORE_SIM=""
9949 IGNORE_SIM_OBS=""
9950 cat >> confdefs.h <<\EOF
9951 #define WITH_SIM 1
9952 EOF
9953
9954 fi
9955
9956
9957
9958
9959
9960
9961
9962
9963
9964
9965
9966
9967
9968
9969
9970
9971 # target_subdir is used by the testsuite to find the target libraries.
9972 target_subdir=
9973 if test "${host}" != "${target}"; then
9974 target_subdir="${target_alias}/"
9975 fi
9976
9977
9978 frags=
9979 host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
9980 if test ! -f ${host_makefile_frag}; then
9981 # When building a native debuger the .mh file containing things
9982 # like NATDEPFILES is needed. Cross debuggers don't need .mh
9983 # since it no longer contains anything useful.
9984 if test "${target}" = "${host}"; then
9985 { echo "configure: error: "*** Gdb does not support native target ${host}"" 1>&2; exit 1; }
9986 else
9987 host_makefile_frag=/dev/null
9988 fi
9989 fi
9990 frags="$frags $host_makefile_frag"
9991
9992 target_makefile_frag=${srcdir}/config/${gdb_target_cpu}/${gdb_target}.mt
9993 if test ! -f ${target_makefile_frag}; then
9994 { echo "configure: error: "*** Gdb does not support target ${target}"" 1>&2; exit 1; }
9995 fi
9996 frags="$frags $target_makefile_frag"
9997
9998
9999
10000
10001
10002 hostfile=`sed -n '
10003 s/XM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
10004 ' ${host_makefile_frag}`
10005
10006 targetfile=`sed -n '
10007 s/TM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
10008 ' ${target_makefile_frag}`
10009
10010 GDB_MULTI_ARCH=`sed -n '
10011 s/GDB_MULTI_ARCH[ ]*=[ ]*\([^ ]*\)[ ]*/\1/p
10012 ' ${target_makefile_frag}`
10013
10014 if test "${target}" = "${host}"; then
10015 # We pick this up from the host configuration file (.mh) because we
10016 # do not have a native configuration Makefile fragment.
10017 nativefile=`sed -n '
10018 s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
10019 ' ${host_makefile_frag}`
10020 fi
10021
10022
10023 # New targets should just set gdb_multi_arch=yes in configure.tgt.
10024 # Old targets being converted can either do that or set GDB_MULTI_ARCH
10025 # in the target specific makefile frag. Eventually gdb_multi_arch=yes
10026 # will be the default.
10027 if test x"${GDB_MULTI_ARCH}" = x ; then
10028 case "${gdb_multi_arch}" in
10029 yes ) GDB_MULTI_ARCH=GDB_MULTI_ARCH_PURE ;;
10030 no ) GDB_MULTI_ARCH=0 ;;
10031 0|1|2 ) GDB_MULTI_ARCH=${gdb_multi_arch} ;;
10032 esac
10033 fi
10034 if test x"${GDB_MULTI_ARCH}" != x ; then
10035 cat >> confdefs.h <<EOF
10036 #define GDB_MULTI_ARCH ${GDB_MULTI_ARCH}
10037 EOF
10038
10039 fi
10040 # Warn the user when they use an old practice
10041 case "${GDB_MULTI_ARCH}" in
10042 "" ) ;;
10043 0 | GDB_MULTI_ARCH_PARTIAL | 1 | GDB_MULTI_ARCH_TM | 2 )
10044 echo "configure: warning: "GDB: Target is not pure multi-arch"" 1>&2 ;;
10045 GDB_MULTI_ARCH_PURE )
10046 if test x"${targetfile}" != x ; then
10047 echo "configure: warning: "GDB: Ignoring TM_FILE in ${target_makefile_frag}"" 1>&2
10048 targetfile=""
10049 fi ;;
10050 *) { echo "configure: error: "GDB: Unknown GDB_MULTI_ARCH value ${GDB_MULTI_ARCH}"" 1>&2; exit 1; };;
10051 esac
10052
10053 if test x"${gdb_osabi}" != x ; then
10054 cat >> confdefs.h <<EOF
10055 #define GDB_OSABI_DEFAULT $gdb_osabi
10056 EOF
10057
10058 fi
10059
10060 # Enable multi-ice-gdb-server.
10061 # Check whether --enable-multi-ice or --disable-multi-ice was given.
10062 if test "${enable_multi_ice+set}" = set; then
10063 enableval="$enable_multi_ice"
10064 case $enableval in
10065 yes | no)
10066 ;;
10067 *) { echo "configure: error: bad value $enableval for --enable-multi-ice" 1>&2; exit 1; } ;;
10068 esac
10069 fi
10070
10071 if test "x$enable_multi_ice" = xyes; then
10072 configdirs="$configdirs multi-ice"
10073 fi
10074
10075 # We only build gdbserver automatically if host and target are the same.
10076 if test "x$target" = "x$host"; then
10077 echo $ac_n "checking whether gdbserver is supported on this host""... $ac_c" 1>&6
10078 echo "configure:10079: checking whether gdbserver is supported on this host" >&5
10079 if test "x$build_gdbserver" = xyes; then
10080 configdirs="$configdirs gdbserver"
10081 echo "$ac_t""yes" 1>&6
10082 else
10083 echo "$ac_t""no" 1>&6
10084 fi
10085 fi
10086
10087 subdirs="doc testsuite $configdirs"
10088
10089
10090 # If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile
10091 # (NAT_FILE) is not set in config/*/*.m[ht] files, we link to an empty
10092 # version.
10093
10094 files=
10095 links=
10096
10097 rm -f xm.h
10098 xm_h=""
10099 if test "${hostfile}" != ""; then
10100 xm_h=xm.h
10101 GDB_XM_FILE="config/${gdb_host_cpu}/${hostfile}"
10102 files="${files} ${GDB_XM_FILE}"
10103 links="${links} xm.h"
10104 cat >> confdefs.h <<EOF
10105 #define GDB_XM_FILE ${GDB_XM_FILE}
10106 EOF
10107
10108 fi
10109
10110
10111 rm -f tm.h
10112 tm_h=""
10113 if test "${targetfile}" != ""; then
10114 tm_h=tm.h
10115 GDB_TM_FILE="config/${gdb_target_cpu}/${targetfile}"
10116 files="${files} ${GDB_TM_FILE}"
10117 links="${links} tm.h"
10118 cat >> confdefs.h <<EOF
10119 #define GDB_TM_FILE ${GDB_TM_FILE}
10120 EOF
10121
10122 fi
10123
10124
10125 rm -f nm.h
10126 nm_h=""
10127 if test "${nativefile}" != ""; then
10128 nm_h=nm.h
10129 GDB_NM_FILE="config/${gdb_host_cpu}/${nativefile}"
10130 files="${files} ${GDB_NM_FILE}"
10131 links="${links} nm.h"
10132 cat >> confdefs.h <<EOF
10133 #define GDB_NM_FILE ${GDB_NM_FILE}
10134 EOF
10135
10136 fi
10137
10138
10139
10140
10141 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
10142 echo "configure:10143: checking for Cygwin environment" >&5
10143 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
10144 echo $ac_n "(cached) $ac_c" 1>&6
10145 else
10146 cat > conftest.$ac_ext <<EOF
10147 #line 10148 "configure"
10148 #include "confdefs.h"
10149
10150 int main() {
10151
10152 #ifndef __CYGWIN__
10153 #define __CYGWIN__ __CYGWIN32__
10154 #endif
10155 return __CYGWIN__;
10156 ; return 0; }
10157 EOF
10158 if { (eval echo configure:10159: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
10159 rm -rf conftest*
10160 ac_cv_cygwin=yes
10161 else
10162 echo "configure: failed program was:" >&5
10163 cat conftest.$ac_ext >&5
10164 rm -rf conftest*
10165 ac_cv_cygwin=no
10166 fi
10167 rm -f conftest*
10168 rm -f conftest*
10169 fi
10170
10171 echo "$ac_t""$ac_cv_cygwin" 1>&6
10172 CYGWIN=
10173 test "$ac_cv_cygwin" = yes && CYGWIN=yes
10174 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
10175 echo "configure:10176: checking for mingw32 environment" >&5
10176 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
10177 echo $ac_n "(cached) $ac_c" 1>&6
10178 else
10179 cat > conftest.$ac_ext <<EOF
10180 #line 10181 "configure"
10181 #include "confdefs.h"
10182
10183 int main() {
10184 return __MINGW32__;
10185 ; return 0; }
10186 EOF
10187 if { (eval echo configure:10188: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
10188 rm -rf conftest*
10189 ac_cv_mingw32=yes
10190 else
10191 echo "configure: failed program was:" >&5
10192 cat conftest.$ac_ext >&5
10193 rm -rf conftest*
10194 ac_cv_mingw32=no
10195 fi
10196 rm -f conftest*
10197 rm -f conftest*
10198 fi
10199
10200 echo "$ac_t""$ac_cv_mingw32" 1>&6
10201 MINGW32=
10202 test "$ac_cv_mingw32" = yes && MINGW32=yes
10203
10204
10205 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
10206 echo "configure:10207: checking for executable suffix" >&5
10207 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
10208 echo $ac_n "(cached) $ac_c" 1>&6
10209 else
10210 if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
10211 ac_cv_exeext=.exe
10212 else
10213 rm -f conftest*
10214 echo 'int main () { return 0; }' > conftest.$ac_ext
10215 ac_cv_exeext=
10216 if { (eval echo configure:10217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
10217 for file in conftest.*; do
10218 case $file in
10219 *.c | *.o | *.obj) ;;
10220 *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
10221 esac
10222 done
10223 else
10224 { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
10225 fi
10226 rm -f conftest*
10227 test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
10228 fi
10229 fi
10230
10231 EXEEXT=""
10232 test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
10233 echo "$ac_t""${ac_cv_exeext}" 1>&6
10234 ac_exeext=$EXEEXT
10235
10236
10237
10238 cat >> confdefs.h <<\EOF
10239 #define GDB_DEFAULT_HOST_CHARSET "ISO-8859-1"
10240 EOF
10241
10242
10243
10244
10245 # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
10246 if test "${with_libiconv_prefix+set}" = set; then
10247 withval="$with_libiconv_prefix"
10248
10249 for dir in `echo "$withval" | tr : ' '`; do
10250 if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
10251 if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi
10252 done
10253
10254 fi
10255
10256
10257 echo $ac_n "checking for iconv""... $ac_c" 1>&6
10258 echo "configure:10259: checking for iconv" >&5
10259 if eval "test \"`echo '$''{'am_cv_func_iconv'+set}'`\" = set"; then
10260 echo $ac_n "(cached) $ac_c" 1>&6
10261 else
10262
10263 am_cv_func_iconv="no, consider installing GNU libiconv"
10264 am_cv_lib_iconv=no
10265 cat > conftest.$ac_ext <<EOF
10266 #line 10267 "configure"
10267 #include "confdefs.h"
10268 #include <stdlib.h>
10269 #include <iconv.h>
10270 int main() {
10271 iconv_t cd = iconv_open("","");
10272 iconv(cd,NULL,NULL,NULL,NULL);
10273 iconv_close(cd);
10274 ; return 0; }
10275 EOF
10276 if { (eval echo configure:10277: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10277 rm -rf conftest*
10278 am_cv_func_iconv=yes
10279 else
10280 echo "configure: failed program was:" >&5
10281 cat conftest.$ac_ext >&5
10282 fi
10283 rm -f conftest*
10284 if test "$am_cv_func_iconv" != yes; then
10285 am_save_LIBS="$LIBS"
10286 LIBS="$LIBS -liconv"
10287 cat > conftest.$ac_ext <<EOF
10288 #line 10289 "configure"
10289 #include "confdefs.h"
10290 #include <stdlib.h>
10291 #include <iconv.h>
10292 int main() {
10293 iconv_t cd = iconv_open("","");
10294 iconv(cd,NULL,NULL,NULL,NULL);
10295 iconv_close(cd);
10296 ; return 0; }
10297 EOF
10298 if { (eval echo configure:10299: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
10299 rm -rf conftest*
10300 am_cv_lib_iconv=yes
10301 am_cv_func_iconv=yes
10302 else
10303 echo "configure: failed program was:" >&5
10304 cat conftest.$ac_ext >&5
10305 fi
10306 rm -f conftest*
10307 LIBS="$am_save_LIBS"
10308 fi
10309
10310 fi
10311
10312 echo "$ac_t""$am_cv_func_iconv" 1>&6
10313 if test "$am_cv_func_iconv" = yes; then
10314 cat >> confdefs.h <<\EOF
10315 #define HAVE_ICONV 1
10316 EOF
10317
10318 echo $ac_n "checking for iconv declaration""... $ac_c" 1>&6
10319 echo "configure:10320: checking for iconv declaration" >&5
10320 if eval "test \"`echo '$''{'am_cv_proto_iconv'+set}'`\" = set"; then
10321 echo $ac_n "(cached) $ac_c" 1>&6
10322 else
10323
10324 cat > conftest.$ac_ext <<EOF
10325 #line 10326 "configure"
10326 #include "confdefs.h"
10327
10328 #include <stdlib.h>
10329 #include <iconv.h>
10330 extern
10331 #ifdef __cplusplus
10332 "C"
10333 #endif
10334 #if defined(__STDC__) || defined(__cplusplus)
10335 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
10336 #else
10337 size_t iconv();
10338 #endif
10339
10340 int main() {
10341
10342 ; return 0; }
10343 EOF
10344 if { (eval echo configure:10345: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
10345 rm -rf conftest*
10346 am_cv_proto_iconv_arg1=""
10347 else
10348 echo "configure: failed program was:" >&5
10349 cat conftest.$ac_ext >&5
10350 rm -rf conftest*
10351 am_cv_proto_iconv_arg1="const"
10352 fi
10353 rm -f conftest*
10354 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);"
10355 fi
10356
10357 am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
10358 echo "$ac_t""${ac_t:-
10359 }$am_cv_proto_iconv" 1>&6
10360 cat >> confdefs.h <<EOF
10361 #define ICONV_CONST $am_cv_proto_iconv_arg1
10362 EOF
10363
10364 fi
10365 LIBICONV=
10366 if test "$am_cv_lib_iconv" = yes; then
10367 LIBICONV="-liconv"
10368 fi
10369
10370
10371
10372 trap '' 1 2 15
10373 cat > confcache <<\EOF
10374 # This file is a shell script that caches the results of configure
10375 # tests run on this system so they can be shared between configure
10376 # scripts and configure runs. It is not useful on other systems.
10377 # If it contains results you don't want to keep, you may remove or edit it.
10378 #
10379 # By default, configure uses ./config.cache as the cache file,
10380 # creating it if it does not exist already. You can give configure
10381 # the --cache-file=FILE option to use a different cache file; that is
10382 # what configure does when it calls configure scripts in
10383 # subdirectories, so they share the cache.
10384 # Giving --cache-file=/dev/null disables caching, for debugging configure.
10385 # config.status only pays attention to the cache file if you give it the
10386 # --recheck option to rerun configure.
10387 #
10388 EOF
10389 # The following way of writing the cache mishandles newlines in values,
10390 # but we know of no workaround that is simple, portable, and efficient.
10391 # So, don't put newlines in cache variables' values.
10392 # Ultrix sh set writes to stderr and can't be redirected directly,
10393 # and sets the high bit in the cache file unless we assign to the vars.
10394 (set) 2>&1 |
10395 case `(ac_space=' '; set | grep ac_space) 2>&1` in
10396 *ac_space=\ *)
10397 # `set' does not quote correctly, so add quotes (double-quote substitution
10398 # turns \\\\ into \\, and sed turns \\ into \).
10399 sed -n \
10400 -e "s/'/'\\\\''/g" \
10401 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
10402 ;;
10403 *)
10404 # `set' quotes correctly as required by POSIX, so do not add quotes.
10405 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
10406 ;;
10407 esac >> confcache
10408 if cmp -s $cache_file confcache; then
10409 :
10410 else
10411 if test -w $cache_file; then
10412 echo "updating cache $cache_file"
10413 cat confcache > $cache_file
10414 else
10415 echo "not updating unwritable cache $cache_file"
10416 fi
10417 fi
10418 rm -f confcache
10419
10420 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
10421
10422 test "x$prefix" = xNONE && prefix=$ac_default_prefix
10423 # Let make expand exec_prefix.
10424 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
10425
10426 # Any assignment to VPATH causes Sun make to only execute
10427 # the first set of double-colon rules, so remove it if not needed.
10428 # If there is a colon in the path, we need to keep it.
10429 if test "x$srcdir" = x.; then
10430 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
10431 fi
10432
10433 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
10434
10435 DEFS=-DHAVE_CONFIG_H
10436
10437 # Without the "./", some shells look in PATH for config.status.
10438 : ${CONFIG_STATUS=./config.status}
10439
10440 echo creating $CONFIG_STATUS
10441 rm -f $CONFIG_STATUS
10442 cat > $CONFIG_STATUS <<EOF
10443 #! /bin/sh
10444 # Generated automatically by configure.
10445 # Run this file to recreate the current configuration.
10446 # This directory was configured as follows,
10447 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10448 #
10449 # $0 $ac_configure_args
10450 #
10451 # Compiler output produced by configure, useful for debugging
10452 # configure, is in ./config.log if it exists.
10453
10454 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
10455 for ac_option
10456 do
10457 case "\$ac_option" in
10458 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
10459 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
10460 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
10461 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
10462 echo "$CONFIG_STATUS generated by autoconf version 2.13"
10463 exit 0 ;;
10464 -help | --help | --hel | --he | --h)
10465 echo "\$ac_cs_usage"; exit 0 ;;
10466 *) echo "\$ac_cs_usage"; exit 1 ;;
10467 esac
10468 done
10469
10470 ac_given_srcdir=$srcdir
10471 ac_given_INSTALL="$INSTALL"
10472
10473 trap 'rm -fr `echo "Makefile .gdbinit:gdbinit.in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
10474 EOF
10475 cat >> $CONFIG_STATUS <<EOF
10476
10477 # Protect against being on the right side of a sed subst in config.status.
10478 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
10479 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
10480 $ac_vpsub
10481 $extrasub
10482 s%@SHELL@%$SHELL%g
10483 s%@CFLAGS@%$CFLAGS%g
10484 s%@CPPFLAGS@%$CPPFLAGS%g
10485 s%@CXXFLAGS@%$CXXFLAGS%g
10486 s%@FFLAGS@%$FFLAGS%g
10487 s%@DEFS@%$DEFS%g
10488 s%@LDFLAGS@%$LDFLAGS%g
10489 s%@LIBS@%$LIBS%g
10490 s%@exec_prefix@%$exec_prefix%g
10491 s%@prefix@%$prefix%g
10492 s%@program_transform_name@%$program_transform_name%g
10493 s%@bindir@%$bindir%g
10494 s%@sbindir@%$sbindir%g
10495 s%@libexecdir@%$libexecdir%g
10496 s%@datadir@%$datadir%g
10497 s%@sysconfdir@%$sysconfdir%g
10498 s%@sharedstatedir@%$sharedstatedir%g
10499 s%@localstatedir@%$localstatedir%g
10500 s%@libdir@%$libdir%g
10501 s%@includedir@%$includedir%g
10502 s%@oldincludedir@%$oldincludedir%g
10503 s%@infodir@%$infodir%g
10504 s%@mandir@%$mandir%g
10505 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
10506 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
10507 s%@MAINT@%$MAINT%g
10508 s%@CC@%$CC%g
10509 s%@CPP@%$CPP%g
10510 s%@host@%$host%g
10511 s%@host_alias@%$host_alias%g
10512 s%@host_cpu@%$host_cpu%g
10513 s%@host_vendor@%$host_vendor%g
10514 s%@host_os@%$host_os%g
10515 s%@target@%$target%g
10516 s%@target_alias@%$target_alias%g
10517 s%@target_cpu@%$target_cpu%g
10518 s%@target_vendor@%$target_vendor%g
10519 s%@target_os@%$target_os%g
10520 s%@build@%$build%g
10521 s%@build_alias@%$build_alias%g
10522 s%@build_cpu@%$build_cpu%g
10523 s%@build_vendor@%$build_vendor%g
10524 s%@build_os@%$build_os%g
10525 s%@RANLIB@%$RANLIB%g
10526 s%@SET_MAKE@%$SET_MAKE%g
10527 s%@ALLOCA@%$ALLOCA%g
10528 s%@USE_NLS@%$USE_NLS%g
10529 s%@MSGFMT@%$MSGFMT%g
10530 s%@GMSGFMT@%$GMSGFMT%g
10531 s%@XGETTEXT@%$XGETTEXT%g
10532 s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
10533 s%@CATALOGS@%$CATALOGS%g
10534 s%@CATOBJEXT@%$CATOBJEXT%g
10535 s%@DATADIRNAME@%$DATADIRNAME%g
10536 s%@GMOFILES@%$GMOFILES%g
10537 s%@INSTOBJEXT@%$INSTOBJEXT%g
10538 s%@INTLDEPS@%$INTLDEPS%g
10539 s%@INTLLIBS@%$INTLLIBS%g
10540 s%@INTLOBJS@%$INTLOBJS%g
10541 s%@POFILES@%$POFILES%g
10542 s%@POSUB@%$POSUB%g
10543 s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
10544 s%@GT_NO@%$GT_NO%g
10545 s%@GT_YES@%$GT_YES%g
10546 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
10547 s%@l@%$l%g
10548 s%@subdirs@%$subdirs%g
10549 s%@AWK@%$AWK%g
10550 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
10551 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
10552 s%@INSTALL_DATA@%$INSTALL_DATA%g
10553 s%@LN_S@%$LN_S%g
10554 s%@YACC@%$YACC%g
10555 s%@AR@%$AR%g
10556 s%@DLLTOOL@%$DLLTOOL%g
10557 s%@WINDRES@%$WINDRES%g
10558 s%@MIG@%$MIG%g
10559 s%@CONFIG_LDFLAGS@%$CONFIG_LDFLAGS%g
10560 s%@TARGET_SYSTEM_ROOT@%$TARGET_SYSTEM_ROOT%g
10561 s%@TARGET_SYSTEM_ROOT_DEFINE@%$TARGET_SYSTEM_ROOT_DEFINE%g
10562 s%@WARN_CFLAGS@%$WARN_CFLAGS%g
10563 s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g
10564 s%@MMALLOC_CFLAGS@%$MMALLOC_CFLAGS%g
10565 s%@MMALLOC@%$MMALLOC%g
10566 s%@SER_HARDWIRE@%$SER_HARDWIRE%g
10567 s%@WIN32LIBS@%$WIN32LIBS%g
10568 s%@LIBGUI@%$LIBGUI%g
10569 s%@GUI_CFLAGS_X@%$GUI_CFLAGS_X%g
10570 s%@WIN32LDAPP@%$WIN32LDAPP%g
10571 s%@TCL_VERSION@%$TCL_VERSION%g
10572 s%@TCL_MAJOR_VERSION@%$TCL_MAJOR_VERSION%g
10573 s%@TCL_MINOR_VERSION@%$TCL_MINOR_VERSION%g
10574 s%@TCL_CC@%$TCL_CC%g
10575 s%@TCL_DEFS@%$TCL_DEFS%g
10576 s%@TCL_SHLIB_CFLAGS@%$TCL_SHLIB_CFLAGS%g
10577 s%@TCL_SHLIB_LD@%$TCL_SHLIB_LD%g
10578 s%@TCL_SHLIB_LD_LIBS@%$TCL_SHLIB_LD_LIBS%g
10579 s%@TCL_SHLIB_SUFFIX@%$TCL_SHLIB_SUFFIX%g
10580 s%@TCL_DL_LIBS@%$TCL_DL_LIBS%g
10581 s%@TCL_LD_FLAGS@%$TCL_LD_FLAGS%g
10582 s%@TCL_LD_SEARCH_FLAGS@%$TCL_LD_SEARCH_FLAGS%g
10583 s%@TCL_CC_SEARCH_FLAGS@%$TCL_CC_SEARCH_FLAGS%g
10584 s%@TCL_COMPAT_OBJS@%$TCL_COMPAT_OBJS%g
10585 s%@TCL_RANLIB@%$TCL_RANLIB%g
10586 s%@TCL_BUILD_LIB_SPEC@%$TCL_BUILD_LIB_SPEC%g
10587 s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
10588 s%@TCL_LIB_VERSIONS_OK@%$TCL_LIB_VERSIONS_OK%g
10589 s%@TK_VERSION@%$TK_VERSION%g
10590 s%@TK_DEFS@%$TK_DEFS%g
10591 s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g
10592 s%@TK_XINCLUDES@%$TK_XINCLUDES%g
10593 s%@TK_XLIBSW@%$TK_XLIBSW%g
10594 s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g
10595 s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
10596 s%@TCLHDIR@%$TCLHDIR%g
10597 s%@TKHDIR@%$TKHDIR%g
10598 s%@ITCLHDIR@%$ITCLHDIR%g
10599 s%@ITKHDIR@%$ITKHDIR%g
10600 s%@ITCL_VERSION@%$ITCL_VERSION%g
10601 s%@ITCL_DEFS@%$ITCL_DEFS%g
10602 s%@ITCL_BUILD_INCLUDES@%$ITCL_BUILD_INCLUDES%g
10603 s%@ITCL_BUILD_LIB_SPEC@%$ITCL_BUILD_LIB_SPEC%g
10604 s%@ITCL_LIB_SPEC@%$ITCL_LIB_SPEC%g
10605 s%@ITK_VERSION@%$ITK_VERSION%g
10606 s%@ITK_DEFS@%$ITK_DEFS%g
10607 s%@ITK_BUILD_INCLUDES@%$ITK_BUILD_INCLUDES%g
10608 s%@ITK_BUILD_LIB_SPEC@%$ITK_BUILD_LIB_SPEC%g
10609 s%@ITK_LIB_SPEC@%$ITK_LIB_SPEC%g
10610 s%@X_CFLAGS@%$X_CFLAGS%g
10611 s%@X_LDFLAGS@%$X_LDFLAGS%g
10612 s%@X_LIBS@%$X_LIBS%g
10613 s%@TCL_DEPS@%$TCL_DEPS%g
10614 s%@TK_DEPS@%$TK_DEPS%g
10615 s%@ITCLLIB@%$ITCLLIB%g
10616 s%@ITCL_DEPS@%$ITCL_DEPS%g
10617 s%@ITKLIB@%$ITKLIB%g
10618 s%@ITK_DEPS@%$ITK_DEPS%g
10619 s%@GDBTKLIBS@%$GDBTKLIBS%g
10620 s%@GDBTK_CFLAGS@%$GDBTK_CFLAGS%g
10621 s%@GDBTK_SRC_DIR@%$GDBTK_SRC_DIR%g
10622 s%@IGNORE_SIM@%$IGNORE_SIM%g
10623 s%@IGNORE_SIM_OBS@%$IGNORE_SIM_OBS%g
10624 s%@ENABLE_CFLAGS@%$ENABLE_CFLAGS%g
10625 s%@PROFILE_CFLAGS@%$PROFILE_CFLAGS%g
10626 s%@CONFIG_OBS@%$CONFIG_OBS%g
10627 s%@CONFIG_LIB_OBS@%$CONFIG_LIB_OBS%g
10628 s%@CONFIG_DEPS@%$CONFIG_DEPS%g
10629 s%@CONFIG_SRCS@%$CONFIG_SRCS%g
10630 s%@CONFIG_INITS@%$CONFIG_INITS%g
10631 s%@CONFIG_ALL@%$CONFIG_ALL%g
10632 s%@CONFIG_CLEAN@%$CONFIG_CLEAN%g
10633 s%@CONFIG_INSTALL@%$CONFIG_INSTALL%g
10634 s%@CONFIG_UNINSTALL@%$CONFIG_UNINSTALL%g
10635 s%@target_subdir@%$target_subdir%g
10636 /@host_makefile_frag@/r $host_makefile_frag
10637 s%@host_makefile_frag@%%g
10638 /@target_makefile_frag@/r $target_makefile_frag
10639 s%@target_makefile_frag@%%g
10640 s%@frags@%$frags%g
10641 s%@xm_h@%$xm_h%g
10642 s%@tm_h@%$tm_h%g
10643 s%@nm_h@%$nm_h%g
10644 s%@EXEEXT@%$EXEEXT%g
10645 s%@LIBICONV@%$LIBICONV%g
10646
10647 CEOF
10648 EOF
10649
10650 cat >> $CONFIG_STATUS <<\EOF
10651
10652 # Split the substitutions into bite-sized pieces for seds with
10653 # small command number limits, like on Digital OSF/1 and HP-UX.
10654 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
10655 ac_file=1 # Number of current file.
10656 ac_beg=1 # First line for current file.
10657 ac_end=$ac_max_sed_cmds # Line after last line for current file.
10658 ac_more_lines=:
10659 ac_sed_cmds=""
10660 while $ac_more_lines; do
10661 if test $ac_beg -gt 1; then
10662 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
10663 else
10664 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
10665 fi
10666 if test ! -s conftest.s$ac_file; then
10667 ac_more_lines=false
10668 rm -f conftest.s$ac_file
10669 else
10670 if test -z "$ac_sed_cmds"; then
10671 ac_sed_cmds="sed -f conftest.s$ac_file"
10672 else
10673 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
10674 fi
10675 ac_file=`expr $ac_file + 1`
10676 ac_beg=$ac_end
10677 ac_end=`expr $ac_end + $ac_max_sed_cmds`
10678 fi
10679 done
10680 if test -z "$ac_sed_cmds"; then
10681 ac_sed_cmds=cat
10682 fi
10683 EOF
10684
10685 cat >> $CONFIG_STATUS <<EOF
10686
10687 CONFIG_FILES=\${CONFIG_FILES-"Makefile .gdbinit:gdbinit.in"}
10688 EOF
10689 cat >> $CONFIG_STATUS <<\EOF
10690 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
10691 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10692 case "$ac_file" in
10693 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
10694 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
10695 *) ac_file_in="${ac_file}.in" ;;
10696 esac
10697
10698 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
10699
10700 # Remove last slash and all that follows it. Not all systems have dirname.
10701 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
10702 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10703 # The file is in a subdirectory.
10704 test ! -d "$ac_dir" && mkdir "$ac_dir"
10705 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
10706 # A "../" for each directory in $ac_dir_suffix.
10707 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
10708 else
10709 ac_dir_suffix= ac_dots=
10710 fi
10711
10712 case "$ac_given_srcdir" in
10713 .) srcdir=.
10714 if test -z "$ac_dots"; then top_srcdir=.
10715 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
10716 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
10717 *) # Relative path.
10718 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
10719 top_srcdir="$ac_dots$ac_given_srcdir" ;;
10720 esac
10721
10722 case "$ac_given_INSTALL" in
10723 [/$]*) INSTALL="$ac_given_INSTALL" ;;
10724 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
10725 esac
10726
10727 echo creating "$ac_file"
10728 rm -f "$ac_file"
10729 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
10730 case "$ac_file" in
10731 *Makefile*) ac_comsub="1i\\
10732 # $configure_input" ;;
10733 *) ac_comsub= ;;
10734 esac
10735
10736 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
10737 sed -e "$ac_comsub
10738 s%@configure_input@%$configure_input%g
10739 s%@srcdir@%$srcdir%g
10740 s%@top_srcdir@%$top_srcdir%g
10741 s%@INSTALL@%$INSTALL%g
10742 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
10743 fi; done
10744 rm -f conftest.s*
10745
10746 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
10747 # NAME is the cpp macro being defined and VALUE is the value it is being given.
10748 #
10749 # ac_d sets the value in "#define NAME VALUE" lines.
10750 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
10751 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
10752 ac_dC='\3'
10753 ac_dD='%g'
10754 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
10755 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
10756 ac_uB='\([ ]\)%\1#\2define\3'
10757 ac_uC=' '
10758 ac_uD='\4%g'
10759 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
10760 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
10761 ac_eB='$%\1#\2define\3'
10762 ac_eC=' '
10763 ac_eD='%g'
10764
10765 if test "${CONFIG_HEADERS+set}" != set; then
10766 EOF
10767 cat >> $CONFIG_STATUS <<EOF
10768 CONFIG_HEADERS="config.h:config.in"
10769 EOF
10770 cat >> $CONFIG_STATUS <<\EOF
10771 fi
10772 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
10773 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10774 case "$ac_file" in
10775 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
10776 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
10777 *) ac_file_in="${ac_file}.in" ;;
10778 esac
10779
10780 echo creating $ac_file
10781
10782 rm -f conftest.frag conftest.in conftest.out
10783 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
10784 cat $ac_file_inputs > conftest.in
10785
10786 EOF
10787
10788 # Transform confdefs.h into a sed script conftest.vals that substitutes
10789 # the proper values into config.h.in to produce config.h. And first:
10790 # Protect against being on the right side of a sed subst in config.status.
10791 # Protect against being in an unquoted here document in config.status.
10792 rm -f conftest.vals
10793 cat > conftest.hdr <<\EOF
10794 s/[\\&%]/\\&/g
10795 s%[\\$`]%\\&%g
10796 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
10797 s%ac_d%ac_u%gp
10798 s%ac_u%ac_e%gp
10799 EOF
10800 sed -n -f conftest.hdr confdefs.h > conftest.vals
10801 rm -f conftest.hdr
10802
10803 # This sed command replaces #undef with comments. This is necessary, for
10804 # example, in the case of _POSIX_SOURCE, which is predefined and required
10805 # on some systems where configure will not decide to define it.
10806 cat >> conftest.vals <<\EOF
10807 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
10808 EOF
10809
10810 # Break up conftest.vals because some shells have a limit on
10811 # the size of here documents, and old seds have small limits too.
10812
10813 rm -f conftest.tail
10814 while :
10815 do
10816 ac_lines=`grep -c . conftest.vals`
10817 # grep -c gives empty output for an empty file on some AIX systems.
10818 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
10819 # Write a limited-size here document to conftest.frag.
10820 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
10821 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
10822 echo 'CEOF
10823 sed -f conftest.frag conftest.in > conftest.out
10824 rm -f conftest.in
10825 mv conftest.out conftest.in
10826 ' >> $CONFIG_STATUS
10827 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
10828 rm -f conftest.vals
10829 mv conftest.tail conftest.vals
10830 done
10831 rm -f conftest.vals
10832
10833 cat >> $CONFIG_STATUS <<\EOF
10834 rm -f conftest.frag conftest.h
10835 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
10836 cat conftest.in >> conftest.h
10837 rm -f conftest.in
10838 if cmp -s $ac_file conftest.h 2>/dev/null; then
10839 echo "$ac_file is unchanged"
10840 rm -f conftest.h
10841 else
10842 # Remove last slash and all that follows it. Not all systems have dirname.
10843 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
10844 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10845 # The file is in a subdirectory.
10846 test ! -d "$ac_dir" && mkdir "$ac_dir"
10847 fi
10848 rm -f $ac_file
10849 mv conftest.h $ac_file
10850 fi
10851 fi; done
10852
10853 EOF
10854
10855 cat >> $CONFIG_STATUS <<EOF
10856 ac_sources="$files"
10857 ac_dests="$links"
10858 EOF
10859
10860 cat >> $CONFIG_STATUS <<\EOF
10861 srcdir=$ac_given_srcdir
10862 while test -n "$ac_sources"; do
10863 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
10864 set $ac_sources; ac_source=$1; shift; ac_sources=$*
10865
10866 echo "linking $srcdir/$ac_source to $ac_dest"
10867
10868 if test ! -r $srcdir/$ac_source; then
10869 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
10870 fi
10871 rm -f $ac_dest
10872
10873 # Make relative symlinks.
10874 # Remove last slash and all that follows it. Not all systems have dirname.
10875 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
10876 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
10877 # The dest file is in a subdirectory.
10878 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
10879 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
10880 # A "../" for each directory in $ac_dest_dir_suffix.
10881 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
10882 else
10883 ac_dest_dir_suffix= ac_dots=
10884 fi
10885
10886 case "$srcdir" in
10887 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
10888 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
10889 esac
10890
10891 # Make a symlink if possible; otherwise try a hard link.
10892 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
10893 ln $srcdir/$ac_source $ac_dest; then :
10894 else
10895 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
10896 fi
10897 done
10898 EOF
10899 cat >> $CONFIG_STATUS <<EOF
10900
10901 gdb_host_cpu=$gdb_host_cpu
10902 gdb_target_cpu=$gdb_target_cpu
10903 nativefile=$nativefile
10904
10905 EOF
10906 cat >> $CONFIG_STATUS <<\EOF
10907
10908 if test "${nativefile}" = ""; then
10909 < Makefile \
10910 sed -e '/^NATDEPFILES[ ]*=.*\\$/,/[^\\]$/s/^/# /' \
10911 -e '/^NATDEPFILES[ ]*=/s/^/# /' \
10912 | sed -e '/^\(NATDEPFILES[ ]*[+]=[ ]*\)/s//# \1/' \
10913 > Makefile.tem
10914 mv -f Makefile.tem Makefile
10915 fi
10916
10917 sed -e '/^TM_FILE[ ]*=/s,^TM_FILE[ ]*=[ ]*,&config/'"${gdb_target_cpu}"'/,
10918 /^XM_FILE[ ]*=/s,^XM_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,
10919 /^NAT_FILE[ ]*=/s,^NAT_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,' <Makefile >Makefile.tmp
10920 mv -f Makefile.tmp Makefile
10921
10922
10923 case x$CONFIG_HEADERS in
10924 xconfig.h:config.in)
10925 echo > stamp-h ;;
10926 esac
10927
10928 exit 0
10929 EOF
10930 chmod +x $CONFIG_STATUS
10931 rm -fr confdefs* $ac_clean_files
10932 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
10933
10934 if test "$no_recursion" != yes; then
10935
10936 # Remove --cache-file and --srcdir arguments so they do not pile up.
10937 ac_sub_configure_args=
10938 ac_prev=
10939 for ac_arg in $ac_configure_args; do
10940 if test -n "$ac_prev"; then
10941 ac_prev=
10942 continue
10943 fi
10944 case "$ac_arg" in
10945 -cache-file | --cache-file | --cache-fil | --cache-fi \
10946 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
10947 ac_prev=cache_file ;;
10948 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
10949 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
10950 ;;
10951 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
10952 ac_prev=srcdir ;;
10953 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
10954 ;;
10955 *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
10956 esac
10957 done
10958
10959 for ac_config_dir in doc testsuite $configdirs; do
10960
10961 # Do not complain, so a configure script can configure whichever
10962 # parts of a large source tree are present.
10963 if test ! -d $srcdir/$ac_config_dir; then
10964 continue
10965 fi
10966
10967 echo configuring in $ac_config_dir
10968
10969 case "$srcdir" in
10970 .) ;;
10971 *)
10972 if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
10973 else
10974 { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
10975 fi
10976 ;;
10977 esac
10978
10979 ac_popdir=`pwd`
10980 cd $ac_config_dir
10981
10982 # A "../" for each directory in /$ac_config_dir.
10983 ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
10984
10985 case "$srcdir" in
10986 .) # No --srcdir option. We are building in place.
10987 ac_sub_srcdir=$srcdir ;;
10988 /*) # Absolute path.
10989 ac_sub_srcdir=$srcdir/$ac_config_dir ;;
10990 *) # Relative path.
10991 ac_sub_srcdir=$ac_dots$srcdir/$ac_config_dir ;;
10992 esac
10993
10994 # Check for guested configure; otherwise get Cygnus style configure.
10995 if test -f $ac_sub_srcdir/configure; then
10996 ac_sub_configure=$ac_sub_srcdir/configure
10997 elif test -f $ac_sub_srcdir/configure.in; then
10998 ac_sub_configure=$ac_configure
10999 else
11000 echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
11001 ac_sub_configure=
11002 fi
11003
11004 # The recursion is here.
11005 if test -n "$ac_sub_configure"; then
11006
11007 # Make the cache file name correct relative to the subdirectory.
11008 case "$cache_file" in
11009 /*) ac_sub_cache_file=$cache_file ;;
11010 *) # Relative path.
11011 ac_sub_cache_file="$ac_dots$cache_file" ;;
11012 esac
11013 case "$ac_given_INSTALL" in
11014 [/$]*) INSTALL="$ac_given_INSTALL" ;;
11015 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
11016 esac
11017
11018 echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
11019 # The eval makes quoting arguments work.
11020 if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
11021 then :
11022 else
11023 { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
11024 fi
11025 fi
11026
11027 cd $ac_popdir
11028 done
11029 fi
11030
11031
11032 exit 0