Ideally the "remote-mips.c" prompt spotting code should be updated to
[deliverable/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.3
5 # Copyright (C) 1992, 1993, 1994 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-netrom "
16 ac_help="$ac_help
17 --enable-gdbtk "
18 ac_help="$ac_help
19 --with-x use the X Window System"
20
21 # Initialize some variables set by options.
22 # The variables have the same names as the options, with
23 # dashes changed to underlines.
24 build=NONE
25 cache_file=./config.cache
26 exec_prefix=NONE
27 host=NONE
28 no_create=
29 nonopt=NONE
30 no_recursion=
31 prefix=NONE
32 program_prefix=NONE
33 program_suffix=NONE
34 program_transform_name=s,x,x,
35 silent=
36 site=
37 srcdir=
38 target=NONE
39 verbose=
40 x_includes=NONE
41 x_libraries=NONE
42
43 # Initialize some other variables.
44 subdirs=
45
46 ac_prev=
47 for ac_option
48 do
49
50 # If the previous option needs an argument, assign it.
51 if test -n "$ac_prev"; then
52 eval "$ac_prev=\$ac_option"
53 ac_prev=
54 continue
55 fi
56
57 case "$ac_option" in
58 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
59 *) ac_optarg= ;;
60 esac
61
62 # Accept the important Cygnus configure options, so we can diagnose typos.
63
64 case "$ac_option" in
65
66 -build | --build | --buil | --bui | --bu | --b)
67 ac_prev=build ;;
68 -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
69 build="$ac_optarg" ;;
70
71 -cache-file | --cache-file | --cache-fil | --cache-fi \
72 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
73 ac_prev=cache_file ;;
74 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
75 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
76 cache_file="$ac_optarg" ;;
77
78 -disable-* | --disable-*)
79 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
80 # Reject names that are not valid shell variable names.
81 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
82 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
83 fi
84 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
85 eval "enable_${ac_feature}=no" ;;
86
87 -enable-* | --enable-*)
88 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
89 # Reject names that are not valid shell variable names.
90 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
91 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
92 fi
93 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
94 case "$ac_option" in
95 *=*) ;;
96 *) ac_optarg=yes ;;
97 esac
98 eval "enable_${ac_feature}='$ac_optarg'" ;;
99
100 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
101 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
102 | --exec | --exe | --ex)
103 ac_prev=exec_prefix ;;
104 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
105 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
106 | --exec=* | --exe=* | --ex=*)
107 exec_prefix="$ac_optarg" ;;
108
109 -gas | --gas | --ga | --g)
110 # Obsolete; use --with-gas.
111 with_gas=yes ;;
112
113 -help | --help | --hel | --he)
114 # Omit some internal or obsolete options to make the list less imposing.
115 # This message is too long to be a string in the A/UX 3.1 sh.
116 cat << EOF
117 Usage: configure [options] [host]
118 Options: [defaults in brackets after descriptions]
119 Configuration:
120 --cache-file=FILE cache test results in FILE
121 --help print this message
122 --no-create do not create output files
123 --quiet, --silent do not print \`checking...' messages
124 --version print the version of autoconf that created configure
125 Directory and file names:
126 --prefix=PREFIX install architecture-independent files in PREFIX
127 [$ac_default_prefix]
128 --exec-prefix=PREFIX install architecture-dependent files in PREFIX
129 [same as prefix]
130 --srcdir=DIR find the sources in DIR [configure dir or ..]
131 --program-prefix=PREFIX prepend PREFIX to installed program names
132 --program-suffix=SUFFIX append SUFFIX to installed program names
133 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
134 Host type:
135 --build=BUILD configure for building on BUILD [BUILD=HOST]
136 --host=HOST configure for HOST [guessed]
137 --target=TARGET configure for TARGET [TARGET=HOST]
138 Features and packages:
139 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
140 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
141 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
142 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
143 --x-includes=DIR X include files are in DIR
144 --x-libraries=DIR X library files are in DIR
145 --enable and --with options recognized:$ac_help
146 EOF
147 exit 0 ;;
148
149 -host | --host | --hos | --ho)
150 ac_prev=host ;;
151 -host=* | --host=* | --hos=* | --ho=*)
152 host="$ac_optarg" ;;
153
154 -nfp | --nfp | --nf)
155 # Obsolete; use --without-fp.
156 with_fp=no ;;
157
158 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
159 | --no-cr | --no-c)
160 no_create=yes ;;
161
162 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
163 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
164 no_recursion=yes ;;
165
166 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
167 ac_prev=prefix ;;
168 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
169 prefix="$ac_optarg" ;;
170
171 -program-prefix | --program-prefix | --program-prefi | --program-pref \
172 | --program-pre | --program-pr | --program-p)
173 ac_prev=program_prefix ;;
174 -program-prefix=* | --program-prefix=* | --program-prefi=* \
175 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
176 program_prefix="$ac_optarg" ;;
177
178 -program-suffix | --program-suffix | --program-suffi | --program-suff \
179 | --program-suf | --program-su | --program-s)
180 ac_prev=program_suffix ;;
181 -program-suffix=* | --program-suffix=* | --program-suffi=* \
182 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
183 program_suffix="$ac_optarg" ;;
184
185 -program-transform-name | --program-transform-name \
186 | --program-transform-nam | --program-transform-na \
187 | --program-transform-n | --program-transform- \
188 | --program-transform | --program-transfor \
189 | --program-transfo | --program-transf \
190 | --program-trans | --program-tran \
191 | --progr-tra | --program-tr | --program-t)
192 ac_prev=program_transform_name ;;
193 -program-transform-name=* | --program-transform-name=* \
194 | --program-transform-nam=* | --program-transform-na=* \
195 | --program-transform-n=* | --program-transform-=* \
196 | --program-transform=* | --program-transfor=* \
197 | --program-transfo=* | --program-transf=* \
198 | --program-trans=* | --program-tran=* \
199 | --progr-tra=* | --program-tr=* | --program-t=*)
200 program_transform_name="$ac_optarg" ;;
201
202 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
203 | -silent | --silent | --silen | --sile | --sil)
204 silent=yes ;;
205
206 -site | --site | --sit)
207 ac_prev=site ;;
208 -site=* | --site=* | --sit=*)
209 site="$ac_optarg" ;;
210
211 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
212 ac_prev=srcdir ;;
213 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
214 srcdir="$ac_optarg" ;;
215
216 -target | --target | --targe | --targ | --tar | --ta | --t)
217 ac_prev=target ;;
218 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
219 target="$ac_optarg" ;;
220
221 -v | -verbose | --verbose | --verbos | --verbo | --verb)
222 verbose=yes ;;
223
224 -version | --version | --versio | --versi | --vers)
225 echo "configure generated by autoconf version 2.3"
226 exit 0 ;;
227
228 -with-* | --with-*)
229 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
230 # Reject names that are not valid shell variable names.
231 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
232 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
233 fi
234 ac_package=`echo $ac_package| sed 's/-/_/g'`
235 case "$ac_option" in
236 *=*) ;;
237 *) ac_optarg=yes ;;
238 esac
239 eval "with_${ac_package}='$ac_optarg'" ;;
240
241 -without-* | --without-*)
242 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
243 # Reject names that are not valid shell variable names.
244 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
245 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
246 fi
247 ac_package=`echo $ac_package| sed 's/-/_/g'`
248 eval "with_${ac_package}=no" ;;
249
250 --x)
251 # Obsolete; use --with-x.
252 with_x=yes ;;
253
254 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
255 | --x-incl | --x-inc | --x-in | --x-i)
256 ac_prev=x_includes ;;
257 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
258 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
259 x_includes="$ac_optarg" ;;
260
261 -x-libraries | --x-libraries | --x-librarie | --x-librari \
262 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
263 ac_prev=x_libraries ;;
264 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
265 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
266 x_libraries="$ac_optarg" ;;
267
268 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
269 ;;
270
271 *)
272 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
273 echo "configure: warning: $ac_option: invalid host type" 1>&2
274 fi
275 if test "x$nonopt" != xNONE; then
276 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
277 fi
278 nonopt="$ac_option"
279 ;;
280
281 esac
282 done
283
284 if test -n "$ac_prev"; then
285 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
286 fi
287
288 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
289
290 # File descriptor usage:
291 # 0 standard input
292 # 1 file creation
293 # 2 errors and warnings
294 # 3 some systems may open it to /dev/tty
295 # 4 used on the Kubota Titan
296 # 6 checking for... messages and results
297 # 5 compiler messages saved in config.log
298 if test "$silent" = yes; then
299 exec 6>/dev/null
300 else
301 exec 6>&1
302 fi
303 exec 5>./config.log
304
305 echo "\
306 This file contains any messages produced by compilers while
307 running configure, to aid debugging if configure makes a mistake.
308 " 1>&5
309
310 # Strip out --no-create and --no-recursion so they do not pile up.
311 # Also quote any args containing shell metacharacters.
312 ac_configure_args=
313 for ac_arg
314 do
315 case "$ac_arg" in
316 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
317 | --no-cr | --no-c) ;;
318 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
319 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
320 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
321 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
322 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
323 esac
324 done
325
326 # NLS nuisances.
327 # Only set LANG and LC_ALL to C if already set.
328 # These must not be set unconditionally because not all systems understand
329 # e.g. LANG=C (notably SCO).
330 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
331 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
332
333 # confdefs.h avoids OS command line length limits that DEFS can exceed.
334 rm -rf conftest* confdefs.h
335 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
336 echo > confdefs.h
337
338 # A filename unique to this package, relative to the directory that
339 # configure is in, which we can look for to find out if srcdir is correct.
340 ac_unique_file=main.c
341
342 # Find the source files, if location was not specified.
343 if test -z "$srcdir"; then
344 ac_srcdir_defaulted=yes
345 # Try the directory containing this script, then its parent.
346 ac_prog=$0
347 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
348 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
349 srcdir=$ac_confdir
350 if test ! -r $srcdir/$ac_unique_file; then
351 srcdir=..
352 fi
353 else
354 ac_srcdir_defaulted=no
355 fi
356 if test ! -r $srcdir/$ac_unique_file; then
357 if test "$ac_srcdir_defaulted" = yes; then
358 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
359 else
360 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
361 fi
362 fi
363 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
364
365 # Prefer explicitly selected file to automatically selected ones.
366 if test -z "$CONFIG_SITE"; then
367 if test "x$prefix" != xNONE; then
368 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
369 else
370 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
371 fi
372 fi
373 for ac_site_file in $CONFIG_SITE; do
374 if test -r "$ac_site_file"; then
375 echo "loading site script $ac_site_file"
376 . "$ac_site_file"
377 fi
378 done
379
380 if test -r "$cache_file"; then
381 echo "loading cache $cache_file"
382 . $cache_file
383 else
384 echo "creating cache $cache_file"
385 > $cache_file
386 fi
387
388 ac_ext=c
389 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
390 ac_cpp='$CPP $CPPFLAGS'
391 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5'
392 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5'
393
394 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
395 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
396 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
397 ac_n= ac_c='
398 ' ac_t=' '
399 else
400 ac_n=-n ac_c= ac_t=
401 fi
402 else
403 ac_n= ac_c='\c' ac_t=
404 fi
405
406
407
408 CC=${CC-cc}
409 # Extract the first word of "gcc", so it can be a program name with args.
410 set dummy gcc; ac_word=$2
411 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
412 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
413 echo $ac_n "(cached) $ac_c" 1>&6
414 else
415 if test -n "$CC"; then
416 ac_cv_prog_CC="$CC" # Let the user override the test.
417 else
418 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
419 for ac_dir in $PATH; do
420 test -z "$ac_dir" && ac_dir=.
421 if test -f $ac_dir/$ac_word; then
422 ac_cv_prog_CC="gcc"
423 break
424 fi
425 done
426 IFS="$ac_save_ifs"
427 test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
428 fi
429 fi
430 CC="$ac_cv_prog_CC"
431 if test -n "$CC"; then
432 echo "$ac_t""$CC" 1>&6
433 else
434 echo "$ac_t""no" 1>&6
435 fi
436
437
438 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
439 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
440 echo $ac_n "(cached) $ac_c" 1>&6
441 else
442 cat > conftest.c <<EOF
443 #ifdef __GNUC__
444 yes;
445 #endif
446 EOF
447 if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
448 ac_cv_prog_gcc=yes
449 else
450 ac_cv_prog_gcc=no
451 fi
452 fi
453 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
454 if test $ac_cv_prog_gcc = yes; then
455 GCC=yes
456 if test "${CFLAGS+set}" != set; then
457 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
458 if eval "test \"`echo '$''{'ac_cv_prog_gcc_g'+set}'`\" = set"; then
459 echo $ac_n "(cached) $ac_c" 1>&6
460 else
461 echo 'void f(){}' > conftest.c
462 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
463 ac_cv_prog_gcc_g=yes
464 else
465 ac_cv_prog_gcc_g=no
466 fi
467 rm -f conftest*
468
469 fi
470 echo "$ac_t""$ac_cv_prog_gcc_g" 1>&6
471 if test $ac_cv_prog_gcc_g = yes; then
472 CFLAGS="-g -O"
473 else
474 CFLAGS="-O"
475 fi
476 fi
477 else
478 GCC=
479 test "${CFLAGS+set}" = set || CFLAGS="-g"
480 fi
481
482 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
483 # On Suns, sometimes $CPP names a directory.
484 if test -n "$CPP" && test -d "$CPP"; then
485 CPP=
486 fi
487 if test -z "$CPP"; then
488 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
489 echo $ac_n "(cached) $ac_c" 1>&6
490 else
491 # This must be in double quotes, not single quotes, because CPP may get
492 # substituted into the Makefile and "${CC-cc}" will confuse make.
493 CPP="${CC-cc} -E"
494 # On the NeXT, cc -E runs the code through the compiler's parser,
495 # not just through cpp.
496 cat > conftest.$ac_ext <<EOF
497 #line 498 "configure"
498 #include "confdefs.h"
499 #include <assert.h>
500 Syntax Error
501 EOF
502 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
503 ac_err=`grep -v '^ *+' conftest.out`
504 if test -z "$ac_err"; then
505 :
506 else
507 echo "$ac_err" >&5
508 rm -rf conftest*
509 CPP="${CC-cc} -E -traditional-cpp"
510 cat > conftest.$ac_ext <<EOF
511 #line 512 "configure"
512 #include "confdefs.h"
513 #include <assert.h>
514 Syntax Error
515 EOF
516 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
517 ac_err=`grep -v '^ *+' conftest.out`
518 if test -z "$ac_err"; then
519 :
520 else
521 echo "$ac_err" >&5
522 rm -rf conftest*
523 CPP=/lib/cpp
524 fi
525 rm -f conftest*
526 fi
527 rm -f conftest*
528 ac_cv_prog_CPP="$CPP"
529 fi
530 fi
531 CPP="$ac_cv_prog_CPP"
532 echo "$ac_t""$CPP" 1>&6
533
534 echo $ac_n "checking for AIX""... $ac_c" 1>&6
535 cat > conftest.$ac_ext <<EOF
536 #line 537 "configure"
537 #include "confdefs.h"
538 #ifdef _AIX
539 yes
540 #endif
541
542 EOF
543 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
544 egrep "yes" >/dev/null 2>&1; then
545 rm -rf conftest*
546 echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
547 #define _ALL_SOURCE 1
548 EOF
549
550 else
551 rm -rf conftest*
552 echo "$ac_t""no" 1>&6
553 fi
554 rm -f conftest*
555
556
557 ac_safe=`echo "minix/config.h" | tr './\055' '___'`
558 echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
559 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
560 echo $ac_n "(cached) $ac_c" 1>&6
561 else
562 cat > conftest.$ac_ext <<EOF
563 #line 564 "configure"
564 #include "confdefs.h"
565 #include <minix/config.h>
566 EOF
567 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
568 ac_err=`grep -v '^ *+' conftest.out`
569 if test -z "$ac_err"; then
570 rm -rf conftest*
571 eval "ac_cv_header_$ac_safe=yes"
572 else
573 echo "$ac_err" >&5
574 rm -rf conftest*
575 eval "ac_cv_header_$ac_safe=no"
576 fi
577 rm -f conftest*
578 fi
579 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
580 echo "$ac_t""yes" 1>&6
581 MINIX=yes
582 else
583 echo "$ac_t""no" 1>&6
584 MINIX=
585 fi
586
587 if test "$MINIX" = yes; then
588 cat >> confdefs.h <<\EOF
589 #define _POSIX_SOURCE 1
590 EOF
591
592 cat >> confdefs.h <<\EOF
593 #define _POSIX_1_SOURCE 2
594 EOF
595
596 cat >> confdefs.h <<\EOF
597 #define _MINIX 1
598 EOF
599
600 fi
601
602 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
603 if test -d /etc/conf/kconfig.d &&
604 grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
605 then
606 echo "$ac_t""yes" 1>&6
607 ISC=yes # If later tests want to check for ISC.
608 cat >> confdefs.h <<\EOF
609 #define _POSIX_SOURCE 1
610 EOF
611
612 if test "$GCC" = yes; then
613 CC="$CC -posix"
614 else
615 CC="$CC -Xp"
616 fi
617 else
618 echo "$ac_t""no" 1>&6
619 ISC=
620 fi
621
622
623 ac_aux_dir=
624 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
625 if test -f $ac_dir/install-sh; then
626 ac_aux_dir=$ac_dir
627 ac_install_sh="$ac_aux_dir/install-sh -c"
628 break
629 elif test -f $ac_dir/install.sh; then
630 ac_aux_dir=$ac_dir
631 ac_install_sh="$ac_aux_dir/install.sh -c"
632 break
633 fi
634 done
635 if test -z "$ac_aux_dir"; then
636 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
637 fi
638 ac_config_guess=$ac_aux_dir/config.guess
639 ac_config_sub=$ac_aux_dir/config.sub
640 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
641
642 # Find a good install program. We prefer a C program (faster),
643 # so one script is as good as another. But avoid the broken or
644 # incompatible versions:
645 # SysV /etc/install, /usr/sbin/install
646 # SunOS /usr/etc/install
647 # IRIX /sbin/install
648 # AIX /bin/install
649 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
650 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
651 # ./install, which can be erroneously created by make from ./install.sh.
652 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
653 if test -z "$INSTALL"; then
654 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
655 echo $ac_n "(cached) $ac_c" 1>&6
656 else
657 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
658 for ac_dir in $PATH; do
659 # Account for people who put trailing slashes in PATH elements.
660 case "$ac_dir/" in
661 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
662 *)
663 # OSF1 and SCO ODT 3.0 have their own names for install.
664 for ac_prog in ginstall installbsd scoinst install; do
665 if test -f $ac_dir/$ac_prog; then
666 if test $ac_prog = install &&
667 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
668 # AIX install. It has an incompatible calling convention.
669 # OSF/1 installbsd also uses dspmsg, but is usable.
670 :
671 else
672 ac_cv_path_install="$ac_dir/$ac_prog -c"
673 break 2
674 fi
675 fi
676 done
677 ;;
678 esac
679 done
680 IFS="$ac_save_ifs"
681 # As a last resort, use the slow shell script.
682 test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
683 fi
684 INSTALL="$ac_cv_path_install"
685 fi
686 echo "$ac_t""$INSTALL" 1>&6
687
688 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
689 # It thinks the first close brace ends the variable substitution.
690 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
691
692 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
693
694 # Extract the first word of "ranlib", so it can be a program name with args.
695 set dummy ranlib; ac_word=$2
696 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
697 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
698 echo $ac_n "(cached) $ac_c" 1>&6
699 else
700 if test -n "$RANLIB"; then
701 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
702 else
703 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
704 for ac_dir in $PATH; do
705 test -z "$ac_dir" && ac_dir=.
706 if test -f $ac_dir/$ac_word; then
707 ac_cv_prog_RANLIB="ranlib"
708 break
709 fi
710 done
711 IFS="$ac_save_ifs"
712 test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
713 fi
714 fi
715 RANLIB="$ac_cv_prog_RANLIB"
716 if test -n "$RANLIB"; then
717 echo "$ac_t""$RANLIB" 1>&6
718 else
719 echo "$ac_t""no" 1>&6
720 fi
721
722
723 ac_aux_dir=
724 for ac_dir in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/..; do
725 if test -f $ac_dir/install-sh; then
726 ac_aux_dir=$ac_dir
727 ac_install_sh="$ac_aux_dir/install-sh -c"
728 break
729 elif test -f $ac_dir/install.sh; then
730 ac_aux_dir=$ac_dir
731 ac_install_sh="$ac_aux_dir/install.sh -c"
732 break
733 fi
734 done
735 if test -z "$ac_aux_dir"; then
736 { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/.. $srcdir/`cd $srcdir;pwd`/.." 1>&2; exit 1; }
737 fi
738 ac_config_guess=$ac_aux_dir/config.guess
739 ac_config_sub=$ac_aux_dir/config.sub
740 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
741
742
743 # Do some error checking and defaulting for the host and target type.
744 # The inputs are:
745 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
746 #
747 # The rules are:
748 # 1. You are not allowed to specify --host, --target, and nonopt at the
749 # same time.
750 # 2. Host defaults to nonopt.
751 # 3. If nonopt is not specified, then host defaults to the current host,
752 # as determined by config.guess.
753 # 4. Target and build default to nonopt.
754 # 5. If nonopt is not specified, then target and build default to host.
755
756 # The aliases save the names the user supplied, while $host etc.
757 # will get canonicalized.
758 case $host---$target---$nonopt in
759 NONE---*---* | *---NONE---* | *---*---NONE) ;;
760 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
761 esac
762
763
764 # Make sure we can run config.sub.
765 if $ac_config_sub sun4 >/dev/null 2>&1; then :
766 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
767 fi
768
769 echo $ac_n "checking host system type""... $ac_c" 1>&6
770
771 host_alias=$host
772 case "$host_alias" in
773 NONE)
774 case $nonopt in
775 NONE)
776 if host_alias=`$ac_config_guess`; then :
777 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
778 fi ;;
779 *) host_alias=$nonopt ;;
780 esac ;;
781 esac
782
783 host=`$ac_config_sub $host_alias`
784 host_cpu=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
785 host_vendor=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
786 host_os=`echo $host | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
787 echo "$ac_t""$host" 1>&6
788
789 echo $ac_n "checking target system type""... $ac_c" 1>&6
790
791 target_alias=$target
792 case "$target_alias" in
793 NONE)
794 case $nonopt in
795 NONE) target_alias=$host_alias ;;
796 *) target_alias=$nonopt ;;
797 esac ;;
798 esac
799
800 target=`$ac_config_sub $target_alias`
801 target_cpu=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
802 target_vendor=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
803 target_os=`echo $target | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
804 echo "$ac_t""$target" 1>&6
805
806 echo $ac_n "checking build system type""... $ac_c" 1>&6
807
808 build_alias=$build
809 case "$build_alias" in
810 NONE)
811 case $nonopt in
812 NONE) build_alias=$host_alias ;;
813 *) build_alias=$nonopt ;;
814 esac ;;
815 esac
816
817 build=`$ac_config_sub $build_alias`
818 build_cpu=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\1/'`
819 build_vendor=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\2/'`
820 build_os=`echo $build | sed 's/^\(.*\)-\(.*\)-\(.*\)$/\3/'`
821 echo "$ac_t""$build" 1>&6
822
823 test "$host_alias" != "$target_alias" &&
824 test "$program_prefix$program_suffix$program_transform_name" = \
825 NONENONEs,x,x, &&
826 program_prefix=${target_alias}-
827
828 if test "$program_transform_name" = s,x,x,; then
829 program_transform_name=
830 else
831 # Double any \ or $.
832 echo 's,\\,\\\\,g; s,\$,$$,g' > conftestsed
833 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
834 rm -f conftestsed
835 fi
836 test "$program_prefix" != NONE &&
837 program_transform_name="s,^,${program_prefix},; $program_transform_name"
838 # Use a double $ so make ignores it.
839 test "$program_suffix" != NONE &&
840 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
841
842 # sed with no file args requires a program.
843 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
844
845
846 # If we cannot run a trivial program, we must be cross compiling.
847 echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
848 if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
849 echo $ac_n "(cached) $ac_c" 1>&6
850 else
851 if test "$cross_compiling" = yes; then
852 ac_cv_c_cross=yes
853 else
854 cat > conftest.$ac_ext <<EOF
855 #line 856 "configure"
856 #include "confdefs.h"
857 main(){return(0);}
858 EOF
859 eval $ac_link
860 if test -s conftest && (./conftest; exit) 2>/dev/null; then
861 ac_cv_c_cross=no
862 else
863 ac_cv_c_cross=yes
864 fi
865 fi
866 rm -fr conftest*
867 fi
868 cross_compiling=$ac_cv_c_cross
869 echo "$ac_t""$ac_cv_c_cross" 1>&6
870
871 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
872 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
873 echo $ac_n "(cached) $ac_c" 1>&6
874 else
875 cat > conftest.$ac_ext <<EOF
876 #line 877 "configure"
877 #include "confdefs.h"
878 #include <stdlib.h>
879 #include <stdarg.h>
880 #include <string.h>
881 #include <float.h>
882 EOF
883 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
884 ac_err=`grep -v '^ *+' conftest.out`
885 if test -z "$ac_err"; then
886 rm -rf conftest*
887 ac_cv_header_stdc=yes
888 else
889 echo "$ac_err" >&5
890 rm -rf conftest*
891 ac_cv_header_stdc=no
892 fi
893 rm -f conftest*
894
895 if test $ac_cv_header_stdc = yes; then
896 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
897 cat > conftest.$ac_ext <<EOF
898 #line 899 "configure"
899 #include "confdefs.h"
900 #include <string.h>
901 EOF
902 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
903 egrep "memchr" >/dev/null 2>&1; then
904 :
905 else
906 rm -rf conftest*
907 ac_cv_header_stdc=no
908 fi
909 rm -f conftest*
910
911 fi
912
913 if test $ac_cv_header_stdc = yes; then
914 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
915 cat > conftest.$ac_ext <<EOF
916 #line 917 "configure"
917 #include "confdefs.h"
918 #include <stdlib.h>
919 EOF
920 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
921 egrep "free" >/dev/null 2>&1; then
922 :
923 else
924 rm -rf conftest*
925 ac_cv_header_stdc=no
926 fi
927 rm -f conftest*
928
929 fi
930
931 if test $ac_cv_header_stdc = yes; then
932 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
933 if test "$cross_compiling" = yes; then
934 ac_cv_header_stdc=no
935 else
936 cat > conftest.$ac_ext <<EOF
937 #line 938 "configure"
938 #include "confdefs.h"
939 #include <ctype.h>
940 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
941 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
942 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
943 int main () { int i; for (i = 0; i < 256; i++)
944 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
945 exit (0); }
946
947 EOF
948 eval $ac_link
949 if test -s conftest && (./conftest; exit) 2>/dev/null; then
950 :
951 else
952 ac_cv_header_stdc=no
953 fi
954 fi
955 rm -fr conftest*
956 fi
957 fi
958 echo "$ac_t""$ac_cv_header_stdc" 1>&6
959 if test $ac_cv_header_stdc = yes; then
960 cat >> confdefs.h <<\EOF
961 #define STDC_HEADERS 1
962 EOF
963
964 fi
965
966 for ac_hdr in memory.h string.h strings.h unistd.h
967 do
968 ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
969 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
970 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
971 echo $ac_n "(cached) $ac_c" 1>&6
972 else
973 cat > conftest.$ac_ext <<EOF
974 #line 975 "configure"
975 #include "confdefs.h"
976 #include <$ac_hdr>
977 EOF
978 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
979 ac_err=`grep -v '^ *+' conftest.out`
980 if test -z "$ac_err"; then
981 rm -rf conftest*
982 eval "ac_cv_header_$ac_safe=yes"
983 else
984 echo "$ac_err" >&5
985 rm -rf conftest*
986 eval "ac_cv_header_$ac_safe=no"
987 fi
988 rm -f conftest*
989 fi
990 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
991 echo "$ac_t""yes" 1>&6
992 ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
993 cat >> confdefs.h <<EOF
994 #define $ac_tr_hdr 1
995 EOF
996
997 else
998 echo "$ac_t""no" 1>&6
999 fi
1000 done
1001
1002 echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
1003 if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
1004 echo $ac_n "(cached) $ac_c" 1>&6
1005 else
1006 cat > conftest.$ac_ext <<EOF
1007 #line 1008 "configure"
1008 #include "confdefs.h"
1009 #include <sys/types.h>
1010 #include <sys/stat.h>
1011
1012 #if defined(S_ISBLK) && defined(S_IFDIR)
1013 # if S_ISBLK (S_IFDIR)
1014 You lose.
1015 # endif
1016 #endif
1017
1018 #if defined(S_ISBLK) && defined(S_IFCHR)
1019 # if S_ISBLK (S_IFCHR)
1020 You lose.
1021 # endif
1022 #endif
1023
1024 #if defined(S_ISLNK) && defined(S_IFREG)
1025 # if S_ISLNK (S_IFREG)
1026 You lose.
1027 # endif
1028 #endif
1029
1030 #if defined(S_ISSOCK) && defined(S_IFREG)
1031 # if S_ISSOCK (S_IFREG)
1032 You lose.
1033 # endif
1034 #endif
1035
1036 EOF
1037 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1038 egrep "You lose" >/dev/null 2>&1; then
1039 rm -rf conftest*
1040 ac_cv_header_stat_broken=yes
1041 else
1042 rm -rf conftest*
1043 ac_cv_header_stat_broken=no
1044 fi
1045 rm -f conftest*
1046
1047 fi
1048 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
1049 if test $ac_cv_header_stat_broken = yes; then
1050 cat >> confdefs.h <<\EOF
1051 #define STAT_MACROS_BROKEN 1
1052 EOF
1053
1054 fi
1055
1056
1057 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
1058 if eval "test \"`echo '$''{'ac_cv_func_mmap'+set}'`\" = set"; then
1059 echo $ac_n "(cached) $ac_c" 1>&6
1060 else
1061 if test "$cross_compiling" = yes; then
1062 ac_cv_func_mmap=no
1063 else
1064 cat > conftest.$ac_ext <<EOF
1065 #line 1066 "configure"
1066 #include "confdefs.h"
1067
1068 /* Thanks to Mike Haertel and Jim Avera for this test. */
1069 #include <sys/types.h>
1070 #include <fcntl.h>
1071 #include <sys/mman.h>
1072
1073 #ifdef BSD
1074 # ifndef BSD4_1
1075 # define HAVE_GETPAGESIZE
1076 # endif
1077 #endif
1078
1079 #ifndef HAVE_GETPAGESIZE
1080 # include <sys/param.h>
1081 # ifdef EXEC_PAGESIZE
1082 # define getpagesize() EXEC_PAGESIZE
1083 # else
1084 # ifdef NBPG
1085 # define getpagesize() NBPG * CLSIZE
1086 # ifndef CLSIZE
1087 # define CLSIZE 1
1088 # endif
1089 # else
1090 # ifdef NBPC
1091 # define getpagesize() NBPC
1092 # else
1093 # define getpagesize() PAGESIZE /* SVR4 */
1094 # endif
1095 # endif
1096 # endif
1097 #endif
1098
1099 #ifdef __osf__
1100 # define valloc malloc
1101 #endif
1102
1103 #ifdef __cplusplus
1104 extern "C" { void *valloc(unsigned), *malloc(unsigned); }
1105 #else
1106 char *valloc(), *malloc();
1107 #endif
1108
1109 int
1110 main()
1111 {
1112 char *buf1, *buf2, *buf3;
1113 int i = getpagesize(), j;
1114 int i2 = getpagesize()*2;
1115 int fd;
1116
1117 buf1 = (char *)valloc(i2);
1118 buf2 = (char *)valloc(i);
1119 buf3 = (char *)malloc(i2);
1120 for (j = 0; j < i2; ++j)
1121 *(buf1 + j) = rand();
1122 fd = open("conftestmmap", O_CREAT | O_RDWR, 0666);
1123 write(fd, buf1, i2);
1124 mmap(buf2, i, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE, fd, 0);
1125 for (j = 0; j < i; ++j)
1126 if (*(buf1 + j) != *(buf2 + j))
1127 exit(1);
1128 lseek(fd, (long)i, 0);
1129 read(fd, buf2, i); /* read into mapped memory -- file should not change */
1130 /* (it does in i386 SVR4.0 - Jim Avera, jima@netcom.com) */
1131 lseek(fd, (long)0, 0);
1132 read(fd, buf3, i2);
1133 for (j = 0; j < i2; ++j)
1134 if (*(buf1 + j) != *(buf3 + j))
1135 exit(1);
1136 exit(0);
1137 }
1138
1139 EOF
1140 eval $ac_link
1141 if test -s conftest && (./conftest; exit) 2>/dev/null; then
1142 ac_cv_func_mmap=yes
1143 else
1144 ac_cv_func_mmap=no
1145 fi
1146 fi
1147 rm -fr conftest*
1148 fi
1149 echo "$ac_t""$ac_cv_func_mmap" 1>&6
1150 if test $ac_cv_func_mmap = yes; then
1151 cat >> confdefs.h <<\EOF
1152 #define HAVE_MMAP 1
1153 EOF
1154
1155 fi
1156
1157
1158 ENABLE_CFLAGS=
1159 ENABLE_CLIBS=
1160 ENABLE_OBS=
1161
1162 # Check whether --enable-netrom or --disable-netrom was given.
1163 enableval="$enable_netrom"
1164 if test -n "$enableval"; then
1165 case "${enableval}" in
1166 yes) enable_netrom=yes ;;
1167 no) enable_netrom=no ;;
1168 *) { echo "configure: error: bad value ${enableval} given for netrom option" 1>&2; exit 1; } ;;
1169 esac
1170 fi
1171
1172
1173 if test "${enable_netrom}" = "yes"; then
1174 ENABLE_OBS="${ENABLE_OBS} remote-nrom.o"
1175 fi
1176
1177 # start-sanitize-gdbtk
1178 ENABLE_GDBTK=
1179
1180 # Check whether --enable-gdbtk or --disable-gdbtk was given.
1181 enableval="$enable_gdbtk"
1182 if test -n "$enableval"; then
1183 case "${enableval}" in
1184 yes) enable_gdbtk=yes ;;
1185 no) enable_gdbtk=no ;;
1186 *) { echo "configure: error: bad value ${enableval} given for gdbtk option" 1>&2; exit 1; } ;;
1187 esac
1188 fi
1189
1190
1191 if test "${enable_gdbtk}" = "yes"; then
1192 # If we find X, set shell vars x_includes and x_libraries to the
1193 # paths, otherwise set no_x=yes.
1194 # Uses ac_ vars as temps to allow command line to override cache and checks.
1195 # --without-x overrides everything else, but does not touch the cache.
1196 echo $ac_n "checking for X""... $ac_c" 1>&6
1197
1198 # Check whether --with-x or --without-x was given.
1199 withval="$with_x"
1200 if test -n "$withval"; then
1201 :
1202 fi
1203
1204 if test "x$with_x" = xno; then
1205 no_x=yes
1206 else
1207 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1208 no_x=
1209 else
1210 if eval "test \"`echo '$''{'ac_cv_path_x'+set}'`\" = set"; then
1211 echo $ac_n "(cached) $ac_c" 1>&6
1212 else
1213 # One or both of the vars are not set, and there is no cached value.
1214 no_x=yes
1215 rm -fr conftestdir
1216 if mkdir conftestdir; then
1217 cd conftestdir
1218 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1219 cat > Imakefile <<'EOF'
1220 acfindx:
1221 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1222 EOF
1223 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1224 no_x=
1225 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1226 eval `make acfindx 2>/dev/null | grep -v make`
1227 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1228 if test ! -f $ac_im_usrlibdir/libX11.a && test -f $ac_im_libdir/libX11.a
1229 then
1230 ac_im_usrlibdir=$ac_im_libdir
1231 fi
1232 # Screen out bogus values from the imake configuration.
1233 case "$ac_im_incroot" in
1234 /usr/include) ;;
1235 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1236 esac
1237 case "$ac_im_usrlibdir" in
1238 /usr/lib | /lib) ;;
1239 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1240 esac
1241 fi
1242 cd ..
1243 rm -fr conftestdir
1244 fi
1245
1246 if test "$no_x" = yes; then
1247 test -z "$x_direct_test_library" && x_direct_test_library=Xt
1248 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1249 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1250 cat > conftest.$ac_ext <<EOF
1251 #line 1252 "configure"
1252 #include "confdefs.h"
1253 #include <$x_direct_test_include>
1254 EOF
1255 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1256 ac_err=`grep -v '^ *+' conftest.out`
1257 if test -z "$ac_err"; then
1258 rm -rf conftest*
1259 no_x= ac_x_includes=
1260 else
1261 echo "$ac_err" >&5
1262 rm -rf conftest*
1263 for ac_dir in \
1264 /usr/X11R6/include \
1265 /usr/X11R5/include \
1266 /usr/X11R4/include \
1267 \
1268 /usr/include/X11R6 \
1269 /usr/include/X11R5 \
1270 /usr/include/X11R4 \
1271 \
1272 /usr/local/X11R6/include \
1273 /usr/local/X11R5/include \
1274 /usr/local/X11R4/include \
1275 \
1276 /usr/local/include/X11R6 \
1277 /usr/local/include/X11R5 \
1278 /usr/local/include/X11R4 \
1279 \
1280 /usr/X11/include \
1281 /usr/include/X11 \
1282 /usr/local/X11/include \
1283 /usr/local/include/X11 \
1284 \
1285 /usr/X386/include \
1286 /usr/x386/include \
1287 /usr/XFree86/include/X11 \
1288 \
1289 /usr/include \
1290 /usr/local/include \
1291 /usr/unsupported/include \
1292 /usr/athena/include \
1293 /usr/local/x11r5/include \
1294 /usr/lpp/Xamples/include \
1295 \
1296 /usr/openwin/include \
1297 /usr/openwin/share/include \
1298 ; \
1299 do
1300 if test -r "$ac_dir/$x_direct_test_include"; then
1301 no_x= ac_x_includes=$ac_dir
1302 break
1303 fi
1304 done
1305 fi
1306 rm -f conftest*
1307
1308 # Check for the libraries.
1309 # See if we find them without any special options.
1310 # Don't add to $LIBS permanently.
1311 ac_save_LIBS="$LIBS"
1312 LIBS="-l$x_direct_test_library $LIBS"
1313 cat > conftest.$ac_ext <<EOF
1314 #line 1315 "configure"
1315 #include "confdefs.h"
1316
1317 int main() { return 0; }
1318 int t() {
1319 ${x_direct_test_function}()
1320 ; return 0; }
1321 EOF
1322 if eval $ac_link; then
1323 rm -rf conftest*
1324 LIBS="$ac_save_LIBS" no_x= ac_x_libraries=
1325 else
1326 rm -rf conftest*
1327 LIBS="$ac_save_LIBS"
1328 # First see if replacing the include by lib works.
1329 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
1330 /usr/X11R6/lib \
1331 /usr/X11R5/lib \
1332 /usr/X11R4/lib \
1333 \
1334 /usr/lib/X11R6 \
1335 /usr/lib/X11R5 \
1336 /usr/lib/X11R4 \
1337 \
1338 /usr/local/X11R6/lib \
1339 /usr/local/X11R5/lib \
1340 /usr/local/X11R4/lib \
1341 \
1342 /usr/local/lib/X11R6 \
1343 /usr/local/lib/X11R5 \
1344 /usr/local/lib/X11R4 \
1345 \
1346 /usr/X11/lib \
1347 /usr/lib/X11 \
1348 /usr/local/X11/lib \
1349 /usr/local/lib/X11 \
1350 \
1351 /usr/X386/lib \
1352 /usr/x386/lib \
1353 /usr/XFree86/lib/X11 \
1354 \
1355 /usr/lib \
1356 /usr/local/lib \
1357 /usr/unsupported/lib \
1358 /usr/athena/lib \
1359 /usr/local/x11r5/lib \
1360 /usr/lpp/Xamples/lib \
1361 \
1362 /usr/openwin/lib \
1363 /usr/openwin/share/lib \
1364 ; \
1365 do
1366 for ac_extension in a so sl; do
1367 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1368 no_x= ac_x_libraries=$ac_dir
1369 break 2
1370 fi
1371 done
1372 done
1373 fi
1374 rm -f conftest*
1375
1376 fi
1377 if test "$no_x" = yes; then
1378 ac_cv_path_x="no_x=yes"
1379 else
1380 ac_cv_path_x="no_x= ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1381 fi
1382 fi
1383 fi
1384 eval "$ac_cv_path_x"
1385 fi # $with_x != no
1386
1387 if test "$no_x" = yes; then
1388 echo "$ac_t""no" 1>&6
1389 else
1390 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1391 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1392 ac_cv_path_x="no_x= ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1393 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1394 fi
1395
1396 if test "$no_x" = yes; then
1397 # Not all programs may use this symbol, but it does not hurt to define it.
1398 X_CFLAGS="$X_CFLAGS -DX_DISPLAY_MISSING"
1399 else
1400 if test -n "$x_includes"; then
1401 X_CFLAGS="$X_CFLAGS -I$x_includes"
1402 fi
1403
1404 # It would be nice to have a more robust check for the -R ld option than
1405 # just checking for Solaris.
1406 # It would also be nice to do this for all -L options, not just this one.
1407 if test -n "$x_libraries"; then
1408 X_LIBS="$X_LIBS -L$x_libraries"
1409 if test "`(uname) 2>/dev/null`" = SunOS &&
1410 uname -r | grep '^5' >/dev/null; then
1411 X_LIBS="$X_LIBS -R$x_libraries"
1412 fi
1413 fi
1414
1415 # Check for libraries that X11R6 Xt/Xaw programs need.
1416
1417 ac_save_LDFLAGS="$LDFLAGS"
1418 LDFLAGS="$LDFLAGS -L$x_libraries"
1419 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
1420 # check for ICE first), but we must link in the order -lSM -lICE or
1421 # we get undefined symbols. So assume we have SM if we have ICE.
1422 # These have to be linked with before -lX11, unlike the other
1423 # libraries we check for below, so use a different variable.
1424 # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
1425 echo $ac_n "checking for -lICE""... $ac_c" 1>&6
1426 if eval "test \"`echo '$''{'ac_cv_lib_ICE'+set}'`\" = set"; then
1427 echo $ac_n "(cached) $ac_c" 1>&6
1428 else
1429 ac_save_LIBS="$LIBS"
1430 LIBS="-lICE $LIBS"
1431 cat > conftest.$ac_ext <<EOF
1432 #line 1433 "configure"
1433 #include "confdefs.h"
1434
1435 int main() { return 0; }
1436 int t() {
1437 IceConnectionNumber()
1438 ; return 0; }
1439 EOF
1440 if eval $ac_link; then
1441 rm -rf conftest*
1442 eval "ac_cv_lib_ICE=yes"
1443 else
1444 rm -rf conftest*
1445 eval "ac_cv_lib_ICE=no"
1446 fi
1447 rm -f conftest*
1448 LIBS="$ac_save_LIBS"
1449
1450 fi
1451 if eval "test \"`echo '$ac_cv_lib_'ICE`\" = yes"; then
1452 echo "$ac_t""yes" 1>&6
1453 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
1454 else
1455 echo "$ac_t""no" 1>&6
1456 fi
1457
1458 LDFLAGS="$ac_save_LDFLAGS"
1459
1460 # Check for system-dependent libraries X programs must link with.
1461
1462 if test "$ISC" = yes; then
1463 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
1464 else
1465 # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
1466 # libraries were built with DECnet support. And karl@cs.umb.edu says
1467 # the Alpha needs dnet_stub (dnet does not exist).
1468 echo $ac_n "checking for -ldnet""... $ac_c" 1>&6
1469 if eval "test \"`echo '$''{'ac_cv_lib_dnet'+set}'`\" = set"; then
1470 echo $ac_n "(cached) $ac_c" 1>&6
1471 else
1472 ac_save_LIBS="$LIBS"
1473 LIBS="-ldnet $LIBS"
1474 cat > conftest.$ac_ext <<EOF
1475 #line 1476 "configure"
1476 #include "confdefs.h"
1477
1478 int main() { return 0; }
1479 int t() {
1480 dnet_ntoa()
1481 ; return 0; }
1482 EOF
1483 if eval $ac_link; then
1484 rm -rf conftest*
1485 eval "ac_cv_lib_dnet=yes"
1486 else
1487 rm -rf conftest*
1488 eval "ac_cv_lib_dnet=no"
1489 fi
1490 rm -f conftest*
1491 LIBS="$ac_save_LIBS"
1492
1493 fi
1494 if eval "test \"`echo '$ac_cv_lib_'dnet`\" = yes"; then
1495 echo "$ac_t""yes" 1>&6
1496 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
1497 else
1498 echo "$ac_t""no" 1>&6
1499 fi
1500
1501 if test $ac_cv_lib_dnet = no; then
1502 echo $ac_n "checking for -ldnet_stub""... $ac_c" 1>&6
1503 if eval "test \"`echo '$''{'ac_cv_lib_dnet_stub'+set}'`\" = set"; then
1504 echo $ac_n "(cached) $ac_c" 1>&6
1505 else
1506 ac_save_LIBS="$LIBS"
1507 LIBS="-ldnet_stub $LIBS"
1508 cat > conftest.$ac_ext <<EOF
1509 #line 1510 "configure"
1510 #include "confdefs.h"
1511
1512 int main() { return 0; }
1513 int t() {
1514 dnet_ntoa()
1515 ; return 0; }
1516 EOF
1517 if eval $ac_link; then
1518 rm -rf conftest*
1519 eval "ac_cv_lib_dnet_stub=yes"
1520 else
1521 rm -rf conftest*
1522 eval "ac_cv_lib_dnet_stub=no"
1523 fi
1524 rm -f conftest*
1525 LIBS="$ac_save_LIBS"
1526
1527 fi
1528 if eval "test \"`echo '$ac_cv_lib_'dnet_stub`\" = yes"; then
1529 echo "$ac_t""yes" 1>&6
1530 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
1531 else
1532 echo "$ac_t""no" 1>&6
1533 fi
1534
1535 fi
1536
1537 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
1538 # to get the SysV transport functions.
1539 # Not sure which flavor of 386 UNIX this is, but it seems harmless to
1540 # check for it.
1541 echo $ac_n "checking for -lnsl""... $ac_c" 1>&6
1542 if eval "test \"`echo '$''{'ac_cv_lib_nsl'+set}'`\" = set"; then
1543 echo $ac_n "(cached) $ac_c" 1>&6
1544 else
1545 ac_save_LIBS="$LIBS"
1546 LIBS="-lnsl $LIBS"
1547 cat > conftest.$ac_ext <<EOF
1548 #line 1549 "configure"
1549 #include "confdefs.h"
1550
1551 int main() { return 0; }
1552 int t() {
1553 t_accept()
1554 ; return 0; }
1555 EOF
1556 if eval $ac_link; then
1557 rm -rf conftest*
1558 eval "ac_cv_lib_nsl=yes"
1559 else
1560 rm -rf conftest*
1561 eval "ac_cv_lib_nsl=no"
1562 fi
1563 rm -f conftest*
1564 LIBS="$ac_save_LIBS"
1565
1566 fi
1567 if eval "test \"`echo '$ac_cv_lib_'nsl`\" = yes"; then
1568 echo "$ac_t""yes" 1>&6
1569 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
1570 else
1571 echo "$ac_t""no" 1>&6
1572 fi
1573
1574
1575 # lieder@skyler.mavd.honeywell.com says without -lsocket,
1576 # socket/setsockopt and other routines are undefined under SCO ODT 2.0.
1577 # But -lsocket is broken on IRIX, according to simon@lia.di.epfl.ch.
1578 if test "`(uname) 2>/dev/null`" != IRIX; then
1579 echo $ac_n "checking for -lsocket""... $ac_c" 1>&6
1580 if eval "test \"`echo '$''{'ac_cv_lib_socket'+set}'`\" = set"; then
1581 echo $ac_n "(cached) $ac_c" 1>&6
1582 else
1583 ac_save_LIBS="$LIBS"
1584 LIBS="-lsocket $LIBS"
1585 cat > conftest.$ac_ext <<EOF
1586 #line 1587 "configure"
1587 #include "confdefs.h"
1588
1589 int main() { return 0; }
1590 int t() {
1591 socket()
1592 ; return 0; }
1593 EOF
1594 if eval $ac_link; then
1595 rm -rf conftest*
1596 eval "ac_cv_lib_socket=yes"
1597 else
1598 rm -rf conftest*
1599 eval "ac_cv_lib_socket=no"
1600 fi
1601 rm -f conftest*
1602 LIBS="$ac_save_LIBS"
1603
1604 fi
1605 if eval "test \"`echo '$ac_cv_lib_'socket`\" = yes"; then
1606 echo "$ac_t""yes" 1>&6
1607 X_EXTRA_LIBS="$X_EXTRA_LIBS -lsocket"
1608 else
1609 echo "$ac_t""no" 1>&6
1610 fi
1611
1612 fi
1613 fi
1614 fi
1615
1616
1617
1618 #
1619 # Ok, lets find the tk source trees so we can use the headers
1620 # If the directory (presumably symlink) named "tk" exists, use that one
1621 # in preference to any others. Same logic is used when choosing library
1622 # and again with Tcl.
1623 #
1624 echo "checking for Tk source directory" 1>&6
1625 TKHDIR=""
1626 for i in `ls -d ${srcdir}/../tk* 2>/dev/null` ${srcdir}/../tk ; do
1627 if test -f $i/tk.h ; then
1628 TKHDIR="-I$i"
1629 fi
1630 done
1631 # if we can't find it, see if one is installed
1632 if test x"$TKHDIR" = x ; then
1633 installed=0
1634 if test -f $prefix/include/tk.h; then
1635 installed=1 TKHDIR="-I$prefix/include"
1636 else
1637 ac_safe=`echo "tk.h" | tr './\055' '___'`
1638 echo $ac_n "checking for tk.h""... $ac_c" 1>&6
1639 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1640 echo $ac_n "(cached) $ac_c" 1>&6
1641 else
1642 cat > conftest.$ac_ext <<EOF
1643 #line 1644 "configure"
1644 #include "confdefs.h"
1645 #include <tk.h>
1646 EOF
1647 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1648 ac_err=`grep -v '^ *+' conftest.out`
1649 if test -z "$ac_err"; then
1650 rm -rf conftest*
1651 eval "ac_cv_header_$ac_safe=yes"
1652 else
1653 echo "$ac_err" >&5
1654 rm -rf conftest*
1655 eval "ac_cv_header_$ac_safe=no"
1656 fi
1657 rm -f conftest*
1658 fi
1659 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1660 echo "$ac_t""yes" 1>&6
1661 installed=1
1662 else
1663 echo "$ac_t""no" 1>&6
1664 fi
1665
1666 fi
1667 if test $installed -eq 0 ; then
1668 TKHDIR="# no Tk directory found"
1669 echo "configure: warning: Can't find Tk directory" 1>&2
1670 fi
1671 fi
1672 if test x"$TKHDIR" != x ; then
1673 echo "$ac_t""Setting TKHDIR to be $i" 1>&6
1674 fi
1675
1676 #
1677 # Ok, lets find the tk library
1678 # First, look for one uninstalled.
1679 #
1680 TKLIB=""
1681 echo "checking for Tk library" 1>&6
1682 for i in `ls -d ../tk* 2>/dev/null` ../tk ; do
1683 if test -f "$i/Makefile" ; then
1684 TKLIB=$i/libtk.a
1685 fi
1686 done
1687 # If not found, look for installed version
1688 if test x"$TKLIB" = x ; then
1689 if test -f $prefix/lib/libtk.a; then
1690 installed=1
1691 else
1692 installed=0
1693 fi
1694 if test $installed -eq 1 ; then
1695 TKLIB="-ltk"
1696 fi
1697 fi
1698
1699 # If still not found, assume Tk simply hasn't been built yet
1700 if test x"$TKLIB" = x ; then
1701 for i in `ls -d ../tk* 2>/dev/null` ../tk ; do
1702 if test -f "$i/tk.h" ; then
1703 TKLIB=$i/libtk.a
1704 fi
1705 done
1706 fi
1707
1708 if test x"$TKLIB" = x ; then
1709 TKLIB="# no Tk library found"
1710 echo "configure: warning: Can't find Tk library" 1>&2
1711 else
1712 echo "$ac_t""setting TKLIB to be $TKLIB" 1>&6
1713 no_tk=
1714 fi
1715
1716
1717
1718
1719
1720 #
1721 # Ok, lets find the tcl source trees so we can use the headers
1722 #
1723 # Warning: transition of version 9 to 10 will break this algorithm
1724 # because 10 sorts before 9.
1725 #
1726 echo "checking for Tcl source directory" 1>&6
1727 TCLHDIR=""
1728 for i in `ls -d ${srcdir}/../tcl* 2>/dev/null` ${srcdir}/../tcl ; do
1729 if test -f $i/tclInt.h ; then
1730 TCLHDIR="-I$i"
1731 fi
1732 done
1733 # if we can't find it, see if one is installed
1734 if test x"$TCLHDIR" = x ; then
1735 installed=0
1736 if test -f $prefix/include/tclInt.h; then
1737 installed=1 TCLHDIR="-I$prefix/include"
1738 else
1739 ac_safe=`echo "tclInt.h" | tr './\055' '___'`
1740 echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6
1741 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1742 echo $ac_n "(cached) $ac_c" 1>&6
1743 else
1744 cat > conftest.$ac_ext <<EOF
1745 #line 1746 "configure"
1746 #include "confdefs.h"
1747 #include <tclInt.h>
1748 EOF
1749 eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1750 ac_err=`grep -v '^ *+' conftest.out`
1751 if test -z "$ac_err"; then
1752 rm -rf conftest*
1753 eval "ac_cv_header_$ac_safe=yes"
1754 else
1755 echo "$ac_err" >&5
1756 rm -rf conftest*
1757 eval "ac_cv_header_$ac_safe=no"
1758 fi
1759 rm -f conftest*
1760 fi
1761 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1762 echo "$ac_t""yes" 1>&6
1763 installed=1
1764 else
1765 echo "$ac_t""no" 1>&6
1766 fi
1767
1768 fi
1769 if test $installed -eq 0 ; then
1770 TCLHDIR="# no Tcl directory found"
1771 echo "configure: warning: Can't find Tcl directory" 1>&2
1772 fi
1773 else
1774 echo "$ac_t""setting TCLHDIR to be $i" 1>&6
1775 fi
1776
1777 #
1778 # Ok, lets find the tcl library
1779 # First, look for the latest uninstalled
1780 #
1781 TCLLIB=""
1782 echo "checking for Tcl library" 1>&6
1783 for i in `ls -d ../tcl* 2>/dev/null` ../tcl ; do
1784 if test -f "$i/Makefile" ; then
1785 TCLLIB=$i/libtcl.a
1786 fi
1787 done
1788 # If not found, look for installed version
1789 if test x"$TCLLIB" = x ; then
1790 if test -f $prefix/lib/libtcl.a; then installed=1; else installed=0; fi
1791 if test $installed -eq 1 ; then
1792 TCLLIB="-ltcl"
1793 fi
1794 fi
1795 # If still not found, assume Tcl simply hasn't been built yet
1796 if test x"$TCLLIB" = x ; then
1797 for i in `ls -d ../tcl* 2>/dev/null` ../tcl ; do
1798 if test -f "$i/tcl.h" ; then
1799 TCLLIB=$i/libtcl.a
1800 fi
1801 done
1802 fi
1803
1804 if test x"$TCLLIB" = x ; then
1805 TCLLIB="# no Tcl library found"
1806 echo "configure: warning: Can't find Tcl library" 1>&2
1807 else
1808 echo "$ac_t""setting TCLLIB to be $TCLLIB" 1>&6
1809 fi
1810
1811
1812
1813
1814
1815 ENABLE_GDBTK=1
1816 TCL_LIBS='$(TCL) $(TK) $(X11)'
1817 ENABLE_CLIBS="${ENABLE_CLIBS} ${TCL_LIBS} -lm"
1818 ENABLE_OBS="${ENABLE_OBS} gdbtk.o"
1819 fi
1820
1821 # end-sanitize-gdbtk
1822
1823
1824
1825
1826
1827
1828 configdirs="doc testsuite"
1829
1830
1831 # Map host cpu into the config cpu subdirectory name.
1832 # The default is $host_cpu.
1833
1834 case "${host_cpu}" in
1835
1836 c[12]) gdb_host_cpu=convex ;;
1837 hppa*) gdb_host_cpu=pa ;;
1838 i[345]86) gdb_host_cpu=i386 ;;
1839 m68*) gdb_host_cpu=m68k ;;
1840 m88*) gdb_host_cpu=m88k ;;
1841 np1) gdb_host_cpu=gould ;;
1842 pyramid) gdb_host_cpu=pyr ;;
1843 powerpc*) gdb_host_cpu=powerpc ;;
1844 *) gdb_host_cpu=$host_cpu ;;
1845
1846 esac
1847
1848 # map host info into gdb names.
1849
1850 case "${host}" in
1851
1852 a29k-*-*) gdb_host=ultra3 ;;
1853
1854 alpha-*-osf1*) gdb_host=alpha-osf1 ;;
1855 alpha-*-osf2*) gdb_host=alpha-osf2 ;;
1856 alpha-*-osf[3456789]*) gdb_host=alpha-osf3 ;;
1857
1858 arm-*-*) gdb_host=arm ;;
1859
1860 c[12]-*-*) gdb_host=convex ;;
1861
1862 hppa*-*-bsd*) gdb_host=hppabsd ;;
1863 hppa*-*-hiux*) gdb_host=hppahpux ;;
1864 hppa*-*-hpux*) gdb_host=hppahpux ;;
1865 hppa*-*-osf*) gdb_host=hppaosf ;;
1866
1867 i[345]86-ncr-*) gdb_host=ncr3000 ;;
1868 i[345]86-sequent-bsd*) gdb_host=symmetry ;; # dynix
1869 i[345]86-sequent-sysv4*) gdb_host=ptx4 ;;
1870 i[345]86-sequent-sysv*) gdb_host=ptx ;;
1871 i[345]86-*-aix*) gdb_host=i386aix ;;
1872 i[345]86-*-bsd*) gdb_host=i386bsd ;;
1873 i[345]86-*-freebsd*) gdb_host=fbsd ;;
1874 i[345]86-*-netbsd*) gdb_host=nbsd ;;
1875 i[345]86-*-go32*) gdb_host=go32 ;;
1876 i[345]86-*-linux*) gdb_host=linux ;;
1877 i[345]86-*-lynxos*) gdb_host=i386lynx ;;
1878 i[345]86-*-mach3*) gdb_host=i386m3 ;;
1879 i[345]86-*-mach*) gdb_host=i386mach ;;
1880 i[345]86-*-osf1mk*) gdb_host=osf1mk ;;
1881 i[345]86-*-sco3.2v4*) gdb_host=i386sco4 ;;
1882 i[345]86-*-sco*) gdb_host=i386sco ;;
1883 i[345]86-*-solaris*) gdb_host=i386sol2 ;;
1884 i[345]86-*-sunos*) gdb_host=sun386 ;;
1885 i[345]86-*-sysv3.2*) gdb_host=i386v32 ;;
1886 i[345]86-*-sysv32*) gdb_host=i386v32 ;;
1887 i[345]86-*-sysv4*) gdb_host=i386v4 ;;
1888 i[345]86-*-unixware) gdb_host=i386v4 ;;
1889 i[345]86-*-sysv*) gdb_host=i386v ;;
1890 i[345]86-*-isc*) gdb_host=i386v32 ;;
1891 i[345]86-*-os9k) gdb_host=i386os9k ;;
1892
1893 m680[01]0-sun-sunos3*) gdb_host=sun2os3 ;;
1894 m680[01]0-sun-sunos4*) gdb_host=sun2os4 ;;
1895 m68030-sony-*) gdb_host=news1000 ;;
1896
1897 m68*-altos-*) gdb_host=altos ;;
1898 m68*-apollo*-sysv*) gdb_host=apollo68v ;;
1899 m68*-apollo*-bsd*) gdb_host=apollo68b ;;
1900 m68*-att-*) gdb_host=3b1 ;;
1901 m68*-bull*-sysv*) gdb_host=dpx2 ;;
1902 m68*-hp-bsd*) gdb_host=hp300bsd ;;
1903 m68*-hp-hpux*) gdb_host=hp300hpux ;;
1904 m68*-isi-*) gdb_host=isi ;;
1905 m68*-*-lynxos*) gdb_host=m68klynx ;;
1906 m68*-*-sysv4*) gdb_host=m68kv4 ;;
1907 m68*-motorola-*) gdb_host=delta68 ;;
1908 m68*-sony-*) gdb_host=news ;;
1909 m68*-sun-sunos3*) gdb_host=sun3os3 ;;
1910 m68*-sun-sunos4*) gdb_host=sun3os4 ;;
1911 m68*-sun-*) gdb_host=sun3os4 ;;
1912
1913 m88*-harris-cxux*) gdb_host=cxux ;;
1914 m88*-motorola-sysv4*) gdb_host=delta88v4 ;;
1915 m88*-motorola-sysv*) gdb_host=delta88 ;;
1916 m88*-*-mach3*) gdb_host=mach3 ;;
1917 m88*-*-*) gdb_host=m88k ;;
1918
1919 mips-dec-mach3*) gdb_host=mach3 ;;
1920 mips-dec-*) gdb_host=decstation ;;
1921 mips-little-*) gdb_host=littlemips ;;
1922 mips-sgi-irix3*) gdb_host=irix3 ;;
1923 mips-sgi-irix4*) gdb_host=irix4 ;;
1924 mips-sgi-irix5*) gdb_host=irix5 ;;
1925 mips-sony-*) gdb_host=news-mips ;;
1926 mips-*-mach3*) gdb_host=mach3 ;;
1927 mips-*-sysv4*) gdb_host=mipsv4 ;;
1928 mips-*-sysv*) gdb_host=riscos ;;
1929 mips-*-riscos*) gdb_host=riscos ;;
1930
1931 none-*-*) gdb_host=none ;;
1932
1933 np1-*-*) gdb_host=np1 ;;
1934
1935 ns32k-*-mach3*) gdb_host=mach3 ;;
1936 ns32k-*-netbsd*) gdb_host=nbsd ;;
1937 ns32k-umax-*) gdb_host=umax ;;
1938 ns32k-utek-sysv*) gdb_host=merlin ;;
1939
1940 powerpc-*-aix*) gdb_host=aix ;;
1941
1942 pn-*-*) gdb_host=pn ;;
1943
1944 pyramid-*-*) gdb_host=pyramid ;;
1945
1946 romp-*-*) gdb_host=rtbsd ;;
1947
1948 rs6000-*-lynxos*) gdb_host=rs6000lynx ;;
1949 rs6000-*-*) gdb_host=rs6000 ;;
1950
1951 sparc-*-lynxos*) gdb_host=sparclynx ;;
1952 sparc-*-netbsd*) gdb_host=nbsd ;;
1953 sparc-*-solaris2*) gdb_host=sun4sol2 ;;
1954 sparc-*-sunos4*) gdb_host=sun4os4 ;;
1955 sparc-*-sunos5*) gdb_host=sun4sol2 ;;
1956 sparc-*-*) gdb_host=sun4os4 ;;
1957
1958 tahoe-*-*) gdb_host=tahoe ;;
1959
1960 vax-*-bsd*) gdb_host=vaxbsd ;;
1961 vax-*-ultrix2*) gdb_host=vaxult2 ;;
1962 vax-*-ultrix*) gdb_host=vaxult ;;
1963
1964 w65-*-*) gdb_host=w65 ;;
1965
1966 esac
1967
1968
1969 # Map target cpu into the config cpu subdirectory name.
1970 # The default is $target_cpu.
1971
1972 case "${target_cpu}" in
1973
1974 alpha) gdb_target_cpu=alpha ;;
1975 c[12]) gdb_target_cpu=convex ;;
1976 hppa*) gdb_target_cpu=pa ;;
1977 i[345]86) gdb_target_cpu=i386 ;;
1978 m68*) gdb_target_cpu=m68k ;;
1979 m88*) gdb_target_cpu=m88k ;;
1980 mips*) gdb_target_cpu=mips ;;
1981 np1) gdb_target_cpu=gould ;;
1982 powerpc*) gdb_target_cpu=powerpc ;;
1983 pn) gdb_target_cpu=gould ;;
1984 pyramid) gdb_target_cpu=pyr ;;
1985 sparc*) gdb_target_cpu=sparc ;;
1986 *) gdb_target_cpu=$target_cpu ;;
1987
1988 esac
1989
1990 # map target info into gdb names.
1991
1992 case "${target}" in
1993
1994 a29k-*-aout*) gdb_target=a29k ;;
1995 a29k-*-coff*) gdb_target=a29k ;;
1996 a29k-*-elf*) gdb_target=a29k ;;
1997 a29k-*-ebmon*) gdb_target=a29k ;;
1998 a29k-*-kern*) gdb_target=a29k-kern ;;
1999 a29k-*-none*) gdb_target=a29k ;;
2000 a29k-*-sym1*) gdb_target=ultra3 ;;
2001 a29k-*-udi*) gdb_target=a29k-udi ;;
2002 a29k-*-vxworks*) gdb_target=vx29k ;;
2003
2004 alpha-*-osf*) gdb_target=alpha-osf1 ;;
2005
2006 # start-sanitize-arc
2007 arc-*-*) gdb_target=arc ;;
2008 # end-sanitize-arc
2009
2010 arm-*-*) gdb_target=arm ;;
2011
2012 c1-*-*) gdb_target=convex ;;
2013 c2-*-*) gdb_target=convex ;;
2014
2015 h8300-*-*) gdb_target=h8300 ;;
2016 h8500-*-*) gdb_target=h8500 ;;
2017
2018 sh-*-*) gdb_target=sh ;;
2019
2020 # start-sanitize-r16
2021 r16-*-*) gdb_target=r16 ;;
2022 # end-sanitize-r16
2023
2024 hppa*-*-bsd*) gdb_target=hppabsd ;;
2025 hppa*-*-pro*) gdb_target=hppapro ;;
2026 hppa*-*-hpux*) gdb_target=hppahpux ;;
2027 hppa*-*-hiux*) gdb_target=hppahpux ;;
2028 hppa*-*-osf*) gdb_target=hppaosf ;;
2029
2030 i[345]86-sequent-bsd*) gdb_target=symmetry ;;
2031 i[345]86-sequent-sysv4*) gdb_target=ptx4 ;;
2032 i[345]86-sequent-sysv*) gdb_target=ptx ;;
2033 i[345]86-ncr-*) gdb_target=ncr3000 ;;
2034 i[345]86-*-aout*) gdb_target=i386aout ;;
2035 i[345]86-*-coff*) gdb_target=i386v ;;
2036 i[345]86-*-elf*) gdb_target=i386v ;;
2037 i[345]86-*-aix*) gdb_target=i386aix ;;
2038 i[345]86-*-bsd*) gdb_target=i386bsd ;;
2039 i[345]86-*-freebsd*) gdb_target=fbsd ;;
2040 i[345]86-*-netbsd*) gdb_target=nbsd ;;
2041 i[345]86-*-os9k) gdb_target=i386os9k ;;
2042 i[345]86-*-go32*) gdb_target=i386aout ;;
2043 i[345]86-*-lynxos*) gdb_target=i386lynx
2044 configdirs="${configdirs} gdbserver" ;;
2045 i[345]86-*-solaris*) gdb_target=i386sol2 ;;
2046 i[345]86-*-sunos*) gdb_target=sun386 ;;
2047 i[345]86-*-sysv4*) gdb_target=i386v4 ;;
2048 i[345]86-*-sco*) gdb_target=i386v ;;
2049 i[345]86-*-sysv*) gdb_target=i386v ;;
2050 i[345]86-*-linux*) gdb_target=linux ;;
2051 i[345]86-*-isc*) gdb_target=i386v ;;
2052 i[345]86-*-mach3*) gdb_target=i386m3 ;;
2053 i[345]86-*-mach*) gdb_target=i386mach ;;
2054 i[345]86-*-netware*) gdb_target=i386nw
2055 configdirs="${configdirs} nlm" ;;
2056 i[345]86-*-osf1mk*) gdb_target=i386mk ;;
2057
2058 i960-*-bout*) gdb_target=vxworks960 ;;
2059 i960-*-coff*) gdb_target=nindy960 ;;
2060 i960-*-elf*) gdb_target=nindy960 ;;
2061
2062 i960-*-nindy*) gdb_target=nindy960 ;;
2063 i960-*-vxworks*) gdb_target=vxworks960 ;;
2064
2065 m68000-*-sunos3*) gdb_target=sun2os3 ;;
2066 m68000-*-sunos4*) gdb_target=sun2os4 ;;
2067
2068 m68*-apollo*-bsd*) gdb_target=apollo68b ;;
2069 m68*-bull-sysv*) gdb_target=dpx2 ;;
2070 m68*-hp-bsd*) gdb_target=hp300bsd ;;
2071 m68*-hp-hpux*) gdb_target=hp300hpux ;;
2072 m68*-altos-*) gdb_target=altos ;;
2073 m68*-att-*) gdb_target=3b1 ;;
2074 m68*-cisco*-*) gdb_target=cisco ;;
2075 m68*-ericsson-*) gdb_target=es1800 ;;
2076 m68*-isi-*) gdb_target=isi ;;
2077 m68*-motorola-*) gdb_target=delta68 ;;
2078 m68*-netx-*) gdb_target=vxworks68 ;;
2079 m68*-sony-*) gdb_target=news ;;
2080 m68*-tandem-*) gdb_target=st2000 ;;
2081 m68*-rom68k-*) gdb_target=monitor ;;
2082 m68*-*bug-*) gdb_target=monitor ;;
2083 m68*-monitor-*) gdb_target=monitor ;;
2084 m68*-est-*) gdb_target=monitor ;;
2085 m68*-*-aout*) gdb_target=monitor ;;
2086 m68*-*-coff*) gdb_target=monitor ;;
2087 m68*-*-elf*) gdb_target=monitor ;;
2088 m68*-*-lynxos*) gdb_target=m68klynx
2089 configdirs="${configdirs} gdbserver" ;;
2090 m68*-*-os68k*) gdb_target=os68k ;;
2091 m68*-*-sunos3*) gdb_target=sun3os3 ;;
2092 m68*-*-sunos4*) gdb_target=sun3os4 ;;
2093 m68*-*-sysv4*) gdb_target=m68kv4 ;;
2094 m68*-*-vxworks*) gdb_target=vxworks68 ;;
2095
2096 m88*-harris-cxux*) gdb_target=cxux ;;
2097 m88*-motorola-sysv4*) gdb_target=delta88v4 ;;
2098 m88*-*-mach3*) gdb_target=mach3 ;;
2099 m88*-motorola-*) gdb_target=delta88 ;;
2100 m88*-*-*) gdb_target=m88k ;;
2101
2102 mips64*-big-*) gdb_target=bigmips64 ;;
2103 mips*-big-*) gdb_target=bigmips ;;
2104 mips*-dec-mach3*) gdb_target=mach3 ;;
2105 mips*-dec-*) gdb_target=decstation ;;
2106 mips64*el-*-ecoff*) gdb_target=idtl64 ;;
2107 mips64*-idt-ecoff*) gdb_target=idt64 ;;
2108 # CYGNUS LOCAL jsmith
2109 mips64*vr4300*el-*-elf*) gdb_target=vr4300el ;;
2110 mips64*vr4300*-*-elf*) gdb_target=vr4300 ;;
2111 # END CYGNUS LOCAL
2112 mips64*el-*-elf*) gdb_target=idtl64 ;;
2113 mips64*-*-elf*) gdb_target=idt64 ;;
2114 mips*el-*-ecoff*) gdb_target=idtl ;;
2115 mips*-*-ecoff*) gdb_target=idt ;;
2116 mips*el-*-elf*) gdb_target=idtl ;;
2117 mips*-*-elf*) gdb_target=idt ;;
2118 mips*-little-*) gdb_target=littlemips ;;
2119 mips*-sgi-irix5*) gdb_target=irix5 ;;
2120 mips*-sgi-*) gdb_target=irix3 ;;
2121 mips*-sony-*) gdb_target=bigmips ;;
2122 mips*-*-mach3*) gdb_target=mach3 ;;
2123 mips*-*-sysv4*) gdb_target=mipsv4 ;;
2124 mips*-*-sysv*) gdb_target=bigmips ;;
2125 mips*-*-riscos*) gdb_target=bigmips ;;
2126
2127 none-*-*) gdb_target=none ;;
2128
2129 np1-*-*) gdb_target=np1 ;;
2130
2131 ns32k-*-mach3*) gdb_target=mach3 ;;
2132 ns32k-*-netbsd*) gdb_target=nbsd ;;
2133 ns32k-utek-sysv*) gdb_target=merlin ;;
2134 ns32k-utek-*) gdb_target=umax ;;
2135
2136 pn-*-*) gdb_target=pn ;;
2137 powerpc-*-netware*) gdb_target=ppc-nw
2138 configdirs="${configdirs} nlm" ;;
2139
2140 powerpc-*-aix4*) gdb_target=aix4 ;;
2141 powerpc-*-aix*) gdb_target=aix ;;
2142 powerpc-*-eabisim*) gdb_target=ppc-sim ;;
2143 powerpc-*-eabi*) gdb_target=ppc-eabi ;;
2144 powerpcle-*-eabisim*) gdb_target=ppcle-sim ;;
2145 powerpcle-*-eabi*) gdb_target=ppcle-eabi ;;
2146
2147 pyramid-*-*) gdb_target=pyramid ;;
2148
2149 rs6000-*-lynxos*) gdb_target=rs6000lynx ;;
2150 rs6000-*-aix4*) gdb_target=aix4 ;;
2151 rs6000-*-*) gdb_target=rs6000 ;;
2152
2153 sparc-*-aout*) gdb_target=sparc-em ;;
2154 sparc-*-coff*) gdb_target=sparc-em ;;
2155 sparc-*-elf*) gdb_target=sparc-em ;;
2156 sparc-*-lynxos*) gdb_target=sparclynx
2157 configdirs="${configdirs} gdbserver" ;;
2158 sparc-*-netbsd*) gdb_target=nbsd ;;
2159 sparc-*-solaris2*) gdb_target=sun4sol2 ;;
2160 sparc-*-sunos4*) gdb_target=sun4os4 ;;
2161 sparc-*-sunos5*) gdb_target=sun4sol2 ;;
2162 sparc-*-vxworks*) gdb_target=vxsparc ;;
2163 sparc-*-*) gdb_target=sun4os4 ;;
2164 sparclite*-*-*) gdb_target=sparclite ;;
2165 sparc64-*-*) gdb_target=sp64 ;;
2166
2167 tahoe-*-*) gdb_target=tahoe ;;
2168
2169 vax-*-*) gdb_target=vax ;;
2170
2171 w65-*-*) gdb_target=w65 ;;
2172
2173 z8k-*-coff*) gdb_target=z8k ;;
2174
2175 esac
2176
2177
2178 frags=
2179 host_makefile_frag=${srcdir}/config/${gdb_host_cpu}/${gdb_host}.mh
2180 if test ! -f ${host_makefile_frag}; then
2181 { echo "configure: error: "*** Gdb does not support host ${host}"" 1>&2; exit 1; }
2182 fi
2183 frags="$frags $host_makefile_frag"
2184
2185 target_makefile_frag=${srcdir}/config/${gdb_target_cpu}/${gdb_target}.mt
2186 if test ! -f ${target_makefile_frag}; then
2187 { echo "configure: error: "*** Gdb does not support target ${target}"" 1>&2; exit 1; }
2188 fi
2189 frags="$frags $target_makefile_frag"
2190
2191
2192
2193
2194
2195 hostfile=`sed -n '
2196 s/XM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
2197 ' ${host_makefile_frag}`
2198
2199 targetfile=`sed -n '
2200 s/TM_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
2201 ' ${target_makefile_frag}`
2202
2203 # these really aren't orthogonal true/false values of the same condition,
2204 # but shells are slow enough that I like to reuse the test conditions
2205 # whenever possible
2206 if test "${target}" = "${host}"; then
2207 nativefile=`sed -n '
2208 s/NAT_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
2209 ' ${host_makefile_frag}`
2210 else
2211 # GDBserver is only useful in a "native" enviroment
2212 configdirs=`echo $configdirs | sed 's/gdbserver//'`
2213 fi
2214
2215
2216 # If hostfile (XM_FILE) and/or targetfile (TM_FILE) and/or nativefile
2217 # (NAT_FILE) is not set in config/*/*.m[ht] files, we don't make the
2218 # corresponding links. But we have to remove the xm.h files and tm.h
2219 # files anyway, e.g. when switching from "configure host" to
2220 # "configure none".
2221
2222 files=
2223 links=
2224 rm -f xm.h
2225 if test "${hostfile}" != ""; then
2226 files="${files} config/${gdb_host_cpu}/${hostfile}"
2227 links="${links} xm.h"
2228 fi
2229 rm -f tm.h
2230 if test "${targetfile}" != ""; then
2231 files="${files} config/${gdb_target_cpu}/${targetfile}"
2232 links="${links} tm.h"
2233 fi
2234 rm -f nm.h
2235 if test "${nativefile}" != ""; then
2236 files="${files} config/${gdb_host_cpu}/${nativefile}"
2237 links="${links} nm.h"
2238 else
2239 # A cross-only configuration.
2240 files="${files} config/nm-empty.h"
2241 links="${links} nm.h"
2242 fi
2243 # start-sanitize-gdbtk
2244
2245 # Make it possible to use the GUI without doing a full install
2246 if test "${enable_gdbtk}" = "yes" -a ! -f gdbtk.tcl ; then
2247 files="${files} gdbtk.tcl"
2248 links="${links} gdbtk.tcl"
2249 fi
2250 # end-sanitize-gdbtk
2251
2252
2253
2254 subdirs="$configdirs"
2255
2256 trap '' 1 2 15
2257 cat > confcache <<\EOF
2258 # This file is a shell script that caches the results of configure
2259 # tests run on this system so they can be shared between configure
2260 # scripts and configure runs. It is not useful on other systems.
2261 # If it contains results you don't want to keep, you may remove or edit it.
2262 #
2263 # By default, configure uses ./config.cache as the cache file,
2264 # creating it if it does not exist already. You can give configure
2265 # the --cache-file=FILE option to use a different cache file; that is
2266 # what configure does when it calls configure scripts in
2267 # subdirectories, so they share the cache.
2268 # Giving --cache-file=/dev/null disables caching, for debugging configure.
2269 # config.status only pays attention to the cache file if you give it the
2270 # --recheck option to rerun configure.
2271 #
2272 EOF
2273 # Ultrix sh set writes to stderr and can't be redirected directly,
2274 # and sets the high bit in the cache file unless we assign to the vars.
2275 (set) 2>&1 |
2276 sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=\${\1='\2'}/p" \
2277 >> confcache
2278 if cmp -s $cache_file confcache; then
2279 :
2280 else
2281 if test -w $cache_file; then
2282 echo "updating cache $cache_file"
2283 cat confcache > $cache_file
2284 else
2285 echo "not updating unwritable cache $cache_file"
2286 fi
2287 fi
2288 rm -f confcache
2289
2290 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2291
2292 test "x$prefix" = xNONE && prefix=$ac_default_prefix
2293 # Let make expand exec_prefix.
2294 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2295
2296 # Any assignment to VPATH causes Sun make to only execute
2297 # the first set of double-colon rules, so remove it if not needed.
2298 # If there is a colon in the path, we need to keep it.
2299 if test "x$srcdir" = x.; then
2300 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
2301 fi
2302
2303 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2304
2305 # Transform confdefs.h into DEFS.
2306 # Protect against shell expansion while executing Makefile rules.
2307 # Protect against Makefile macro expansion.
2308 cat > conftest.defs <<\EOF
2309 s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%-D\1=\2%g
2310 s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
2311 s%\[%\\&%g
2312 s%\]%\\&%g
2313 s%\$%$$%g
2314 EOF
2315 DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
2316 rm -f conftest.defs
2317
2318
2319 # Without the "./", some shells look in PATH for config.status.
2320 : ${CONFIG_STATUS=./config.status}
2321
2322 echo creating $CONFIG_STATUS
2323 rm -f $CONFIG_STATUS
2324 cat > $CONFIG_STATUS <<EOF
2325 #! /bin/sh
2326 # Generated automatically by configure.
2327 # Run this file to recreate the current configuration.
2328 # This directory was configured as follows,
2329 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2330 #
2331 # $0 $ac_configure_args
2332 #
2333 # Compiler output produced by configure, useful for debugging
2334 # configure, is in ./config.log if it exists.
2335
2336 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2337 for ac_option
2338 do
2339 case "\$ac_option" in
2340 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2341 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2342 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2343 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2344 echo "$CONFIG_STATUS generated by autoconf version 2.3"
2345 exit 0 ;;
2346 -help | --help | --hel | --he | --h)
2347 echo "\$ac_cs_usage"; exit 0 ;;
2348 *) echo "\$ac_cs_usage"; exit 1 ;;
2349 esac
2350 done
2351
2352 ac_given_srcdir=$srcdir
2353 ac_given_INSTALL="$INSTALL"
2354
2355 trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2356
2357 # Protect against being on the right side of a sed subst in config.status.
2358 sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g;
2359 s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
2360 $ac_vpsub
2361 $extrasub
2362 s%@CFLAGS@%$CFLAGS%g
2363 s%@CPPFLAGS@%$CPPFLAGS%g
2364 s%@CXXFLAGS@%$CXXFLAGS%g
2365 s%@DEFS@%$DEFS%g
2366 s%@LDFLAGS@%$LDFLAGS%g
2367 s%@LIBS@%$LIBS%g
2368 s%@exec_prefix@%$exec_prefix%g
2369 s%@prefix@%$prefix%g
2370 s%@program_transform_name@%$program_transform_name%g
2371 s%@CC@%$CC%g
2372 s%@CPP@%$CPP%g
2373 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2374 s%@INSTALL_DATA@%$INSTALL_DATA%g
2375 s%@RANLIB@%$RANLIB%g
2376 s%@host@%$host%g
2377 s%@host_alias@%$host_alias%g
2378 s%@host_cpu@%$host_cpu%g
2379 s%@host_vendor@%$host_vendor%g
2380 s%@host_os@%$host_os%g
2381 s%@target@%$target%g
2382 s%@target_alias@%$target_alias%g
2383 s%@target_cpu@%$target_cpu%g
2384 s%@target_vendor@%$target_vendor%g
2385 s%@target_os@%$target_os%g
2386 s%@build@%$build%g
2387 s%@build_alias@%$build_alias%g
2388 s%@build_cpu@%$build_cpu%g
2389 s%@build_vendor@%$build_vendor%g
2390 s%@build_os@%$build_os%g
2391 s%@X_CFLAGS@%$X_CFLAGS%g
2392 s%@X_PRE_LIBS@%$X_PRE_LIBS%g
2393 s%@X_LIBS@%$X_LIBS%g
2394 s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
2395 s%@TKHDIR@%$TKHDIR%g
2396 s%@TKLIB@%$TKLIB%g
2397 s%@TCLHDIR@%$TCLHDIR%g
2398 s%@TCLLIB@%$TCLLIB%g
2399 s%@ENABLE_GDBTK@%$ENABLE_GDBTK%g
2400 s%@ENABLE_CFLAGS@%$ENABLE_CFLAGS%g
2401 s%@ENABLE_CLIBS@%$ENABLE_CLIBS%g
2402 s%@ENABLE_OBS@%$ENABLE_OBS%g
2403 /@host_makefile_frag@/r $host_makefile_frag
2404 s%@host_makefile_frag@%%g
2405 /@target_makefile_frag@/r $target_makefile_frag
2406 s%@target_makefile_frag@%%g
2407 s%@frags@%$frags%g
2408 s%@subdirs@%$subdirs%g
2409
2410 CEOF
2411 EOF
2412 cat >> $CONFIG_STATUS <<EOF
2413
2414 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
2415 EOF
2416 cat >> $CONFIG_STATUS <<\EOF
2417 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2418 # Support "outfile[:infile]", defaulting infile="outfile.in".
2419 case "$ac_file" in
2420 *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
2421 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2422 *) ac_file_in="${ac_file}.in" ;;
2423 esac
2424
2425 # Adjust relative srcdir, etc. for subdirectories.
2426
2427 # Remove last slash and all that follows it. Not all systems have dirname.
2428 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2429 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2430 # The file is in a subdirectory.
2431 test ! -d "$ac_dir" && mkdir "$ac_dir"
2432 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2433 # A "../" for each directory in $ac_dir_suffix.
2434 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2435 else
2436 ac_dir_suffix= ac_dots=
2437 fi
2438
2439 case "$ac_given_srcdir" in
2440 .) srcdir=.
2441 if test -z "$ac_dots"; then top_srcdir=.
2442 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2443 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2444 *) # Relative path.
2445 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2446 top_srcdir="$ac_dots$ac_given_srcdir" ;;
2447 esac
2448
2449 case "$ac_given_INSTALL" in
2450 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2451 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2452 esac
2453 echo creating "$ac_file"
2454 rm -f "$ac_file"
2455 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2456 case "$ac_file" in
2457 *Makefile*) ac_comsub="1i\\
2458 # $configure_input" ;;
2459 *) ac_comsub= ;;
2460 esac
2461 sed -e "$ac_comsub
2462 s%@configure_input@%$configure_input%g
2463 s%@srcdir@%$srcdir%g
2464 s%@top_srcdir@%$top_srcdir%g
2465 s%@INSTALL@%$INSTALL%g
2466 " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
2467 fi; done
2468 rm -f conftest.subs
2469
2470 EOF
2471
2472 cat >> $CONFIG_STATUS <<EOF
2473 ac_sources="$files"
2474 ac_dests="$links"
2475 EOF
2476
2477 cat >> $CONFIG_STATUS <<\EOF
2478 srcdir=$ac_given_srcdir
2479 while test -n "$ac_sources"; do
2480 set $ac_dests; ac_dest=$1; shift; ac_dests=$*
2481 set $ac_sources; ac_source=$1; shift; ac_sources=$*
2482
2483 echo "linking $srcdir/$ac_source to $ac_dest"
2484
2485 if test ! -r $srcdir/$ac_source; then
2486 { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
2487 fi
2488 rm -f $ac_dest
2489
2490 # Make relative symlinks.
2491 # Remove last slash and all that follows it. Not all systems have dirname.
2492 ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
2493 if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
2494 # The dest file is in a subdirectory.
2495 test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
2496 ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
2497 # A "../" for each directory in $ac_dest_dir_suffix.
2498 ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
2499 else
2500 ac_dest_dir_suffix= ac_dots=
2501 fi
2502
2503 case "$srcdir" in
2504 [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
2505 *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
2506 esac
2507
2508 # Make a symlink if possible; otherwise try a hard link.
2509 if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
2510 ln $srcdir/$ac_source $ac_dest; then :
2511 else
2512 { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
2513 fi
2514 done
2515 EOF
2516 cat >> $CONFIG_STATUS <<EOF
2517
2518 gdb_host_cpu=$gdb_host_cpu
2519 gdb_target_cpu=$gdb_target_cpu
2520 nativefile=$nativefile
2521
2522 EOF
2523 cat >> $CONFIG_STATUS <<\EOF
2524
2525 if test "${nativefile}" = ""; then
2526 sed -e '/^NATDEPFILES= /s//# NATDEPFILES= /' \
2527 < Makefile > Makefile.tem
2528 mv -f Makefile.tem Makefile
2529 fi
2530
2531 sed -e '/^TM_FILE[ ]*=/s,^TM_FILE[ ]*=[ ]*,&config/'"${gdb_target_cpu}"'/,
2532 /^XM_FILE[ ]*=/s,^XM_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,
2533 /^NAT_FILE[ ]*=/s,^NAT_FILE[ ]*=[ ]*,&config/'"${gdb_host_cpu}"'/,' <Makefile >Makefile.tmp
2534 mv -f Makefile.tmp Makefile
2535
2536 case ${srcdir} in
2537 .)
2538 ;;
2539 *)
2540 grep "source ${srcdir}/.gdbinit" .gdbinit >/dev/null 2>/dev/null || \
2541 echo "source ${srcdir}/.gdbinit" >> .gdbinit
2542 esac
2543
2544 exit 0
2545 EOF
2546 chmod +x $CONFIG_STATUS
2547 rm -fr confdefs* $ac_clean_files
2548 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2549
2550 if test "$no_recursion" != yes; then
2551
2552 # Remove --cache-file and --srcdir arguments so they do not pile up.
2553 ac_sub_configure_args=
2554 ac_prev=
2555 for ac_arg in $ac_configure_args; do
2556 if test -n "$ac_prev"; then
2557 ac_prev=
2558 continue
2559 fi
2560 case "$ac_arg" in
2561 -cache-file | --cache-file | --cache-fil | --cache-fi \
2562 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
2563 ac_prev=cache_file ;;
2564 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
2565 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
2566 ;;
2567 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2568 ac_prev=srcdir ;;
2569 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2570 ;;
2571 *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;;
2572 esac
2573 done
2574
2575 for ac_config_dir in $configdirs; do
2576
2577 # Do not complain, so a configure script can configure whichever
2578 # parts of a large source tree are present.
2579 if test ! -d $srcdir/$ac_config_dir; then
2580 continue
2581 fi
2582
2583 echo configuring in $ac_config_dir
2584
2585 case "$srcdir" in
2586 .) ;;
2587 *)
2588 if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :;
2589 else
2590 { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; }
2591 fi
2592 ;;
2593 esac
2594
2595 ac_popdir=`pwd`
2596 cd $ac_config_dir
2597
2598 case "$srcdir" in
2599 .) # No --srcdir option. We are building in place.
2600 ac_sub_srcdir=$srcdir ;;
2601 /*) # Absolute path.
2602 ac_sub_srcdir=$srcdir/$ac_config_dir ;;
2603 *) # Relative path.
2604 ac_sub_srcdir=../$srcdir/$ac_config_dir ;;
2605 esac
2606
2607 # Check for guested configure; otherwise get Cygnus style configure.
2608 if test -f $ac_sub_srcdir/configure; then
2609 ac_sub_configure=$ac_sub_srcdir/configure
2610 elif test -f $ac_sub_srcdir/configure.in; then
2611 ac_sub_configure=$ac_configure
2612 else
2613 echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2
2614 ac_sub_configure=
2615 fi
2616
2617 # The recursion is here.
2618 if test -n "$ac_sub_configure"; then
2619
2620 # Make the cache file name correct relative to the subdirectory.
2621 # A "../" for each directory in /$ac_config_dir.
2622 ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'`
2623 case "$cache_file" in
2624 /*) ac_sub_cache_file=$cache_file ;;
2625 *) # Relative path.
2626 ac_sub_cache_file="$ac_dots$cache_file" ;;
2627 esac
2628 case "$ac_given_INSTALL" in
2629 [/$]*) INSTALL="$ac_given_INSTALL" ;;
2630 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2631 esac
2632
2633 echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir"
2634 # The eval makes quoting arguments work.
2635 if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir
2636 then :
2637 else
2638 { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; }
2639 fi
2640 fi
2641
2642 cd $ac_popdir
2643 done
2644 fi
2645
This page took 0.08914 seconds and 5 git commands to generate.