]> gcc.gnu.org Git - gcc.git/blob - gcc/configure.in
crtbegin.asm, [...]: New files.
[gcc.git] / gcc / configure.in
1 # configure.in for GNU CC
2 # Process this file with autoconf to generate a configuration script.
3
4 # Copyright (C) 1997, 1998 Free Software Foundation, Inc.
5
6 #This file is part of GNU CC.
7
8 #GNU CC is free software; you can redistribute it and/or modify
9 #it under the terms of the GNU General Public License as published by
10 #the Free Software Foundation; either version 2, or (at your option)
11 #any later version.
12
13 #GNU CC is distributed in the hope that it will be useful,
14 #but WITHOUT ANY WARRANTY; without even the implied warranty of
15 #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 #GNU General Public License for more details.
17
18 #You should have received a copy of the GNU General Public License
19 #along with GNU CC; see the file COPYING. If not, write to
20 #the Free Software Foundation, 59 Temple Place - Suite 330,
21 #Boston, MA 02111-1307, USA.
22
23 # Initialization and defaults
24 AC_INIT(tree.c)
25 AC_CONFIG_HEADER(auto-config.h:config.in)
26
27 remove=rm
28 hard_link=ln
29 symbolic_link='ln -s'
30 copy=cp
31
32 # Check for additional parameters
33
34 # With GNU ld
35 AC_ARG_WITH(gnu-ld,
36 [ --with-gnu-ld arrange to work with GNU ld.],
37 gnu_ld="$with_gnu_ld",
38 gnu_ld=no)
39
40 # With GNU as
41 AC_ARG_WITH(gnu-as,
42 [ --with-gnu-as arrange to work with GNU as.],
43 gas="$with_gnu_as",
44 gas=no)
45
46 # With stabs
47 AC_ARG_WITH(stabs,
48 [ --with-stabs arrange to use stabs instead of host debug format.],
49 stabs="$with_stabs",
50 stabs=no)
51
52 # With ELF
53 AC_ARG_WITH(elf,
54 [ --with-elf arrange to use ELF instead of host debug format.],
55 elf="$with_elf",
56 elf=no)
57
58 # Specify the local prefix
59 AC_ARG_WITH(local-prefix,
60 [ --with-local-prefix=DIR specifies directory to put local include.],
61 local_prefix=$with_local_prefix,
62 local_prefix=/usr/local)
63
64 # Default local prefix if it is empty
65 if [[ x$local_prefix = x ]]; then
66 local_prefix=/usr/local
67 fi
68
69 # Specify the g++ header file directory
70 AC_ARG_WITH(gxx-include-dir,
71 [ --with-gxx-include-dir=DIR
72 specifies directory to put g++ header files.],
73 gxx_include_dir=$with_gxx_include_dir,
74 gxx_include_dir='${prefix}/include/g++')
75
76 # Default g++ header file directory if it is empty
77 if [[ x$gxx_include_dir = x ]]; then
78 gxx_include_dir='${prefix}/include/g++'
79 fi
80
81 # Enable use of cpplib for C.
82 AC_ARG_ENABLE(c-cpplib,
83 [ --enable-c-cpplib Use cpplib for C.],
84 if [[[ x$enable_c_cpplib != xno ]]]; then
85 extra_c_objs="${extra_c_objs} cpplib.o cppexp.o cpphash.o cpperror.o"
86 extra_c_flags=-DUSE_CPPLIB=1
87 fi)
88
89 # Enable Haifa scheduler.
90 AC_ARG_ENABLE(haifa,
91 [ --enable-haifa Use the experimental scheduler.
92 --disable-haifa Don't use the experimental scheduler for the
93 targets which normally enable it.])
94
95 # Enable threads
96 # Pass with no value to take the default
97 # Pass with a value to specify a thread package
98 AC_ARG_ENABLE(threads,
99 [ --enable-threads enable thread usage for target GCC.
100 --enable-threads=LIB use LIB thread package for target GCC.],
101 if [[[ x$enable_threads = xno ]]]; then
102 enable_threads=''
103 fi,
104 enable_threads='')
105
106 # Check if a valid thread package
107 case x${enable_threads} in
108 x | xno)
109 # No threads
110 target_thread_file='single'
111 ;;
112 xyes)
113 # default
114 target_thread_file=''
115 ;;
116 xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \
117 xsolaris | xwin32 | xdce | xvxworks)
118 target_thread_file=$enable_threads
119 ;;
120 *)
121 echo "$enable_threads is an unknown thread package" 1>&2
122 exit 1
123 ;;
124 esac
125
126 # Determine the host, build, and target systems
127 AC_CANONICAL_SYSTEM
128
129 # Find the native compiler
130 AC_PROG_CC
131 AC_PROG_MAKE_SET
132
133 # Find some useful tools
134 AC_PROG_AWK
135 AC_PROG_LEX
136 GCC_PROG_LN
137 GCC_PROG_LN_S
138 AC_PROG_RANLIB
139 AC_PROG_YACC
140 EGCS_PROG_INSTALL
141
142 AC_HEADER_STDC
143 AC_HEADER_TIME
144 AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h fcntl.h unistd.h sys/file.h sys/time.h sys/resource.h sys/param.h sys/times.h varargs.h sys/varargs.h)
145
146 # Check for thread headers.
147 AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=])
148 AC_CHECK_HEADER(pthread.h, [have_pthread_h=yes], [have_pthread_h=])
149
150 # See if the system preprocessor understands the ANSI C preprocessor
151 # stringification operator.
152 AC_MSG_CHECKING(whether cpp understands the stringify operator)
153 AC_CACHE_VAL(gcc_cv_c_have_stringify,
154 [AC_TRY_COMPILE(,
155 [#define S(x) #x
156 char *test = S(foo);],
157 gcc_cv_c_have_stringify=yes, gcc_cv_c_have_stringify=no)])
158 AC_MSG_RESULT($gcc_cv_c_have_stringify)
159 if test $gcc_cv_c_have_stringify = yes; then
160 AC_DEFINE(HAVE_CPP_STRINGIFY)
161 fi
162
163 # Use <inttypes.h> only if it exists,
164 # doesn't clash with <sys/types.h>, and declares intmax_t.
165 AC_MSG_CHECKING(for inttypes.h)
166 AC_CACHE_VAL(gcc_cv_header_inttypes_h,
167 [AC_TRY_COMPILE(
168 [#include <sys/types.h>
169 #include <inttypes.h>],
170 [intmax_t i = -1;],
171 [AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H)
172 gcc_cv_header_inttypes_h=yes],
173 gcc_cv_header_inttypes_h=no)])
174 AC_MSG_RESULT($gcc_cv_header_inttypes_h)
175
176 AC_CHECK_FUNCS(strtoul bsearch strerror putenv popen vprintf bcopy bzero bcmp \
177 index rindex kill getrlimit setrlimit atoll atoq sysconf)
178
179 GCC_FUNC_PRINTF_PTR
180
181 GCC_NEED_DECLARATIONS(malloc realloc calloc free bcopy bzero bcmp \
182 index rindex getenv atol sbrk abort)
183
184 AC_DECL_SYS_SIGLIST
185
186 # File extensions
187 manext='.1'
188 objext='.o'
189 AC_SUBST(manext)
190 AC_SUBST(objext)
191
192 build_xm_file=
193 build_xm_defines=
194 build_install_headers_dir=install-headers-tar
195 build_exeext=
196 host_xm_file=
197 host_xm_defines=
198 host_xmake_file=
199 host_truncate_target=
200 host_exeext=
201
202 # Decode the host machine, then the target machine.
203 # For the host machine, we save the xm_file variable as host_xm_file;
204 # then we decode the target machine and forget everything else
205 # that came from the host machine.
206 for machine in $build $host $target; do
207
208 out_file=
209 xmake_file=
210 tmake_file=
211 extra_headers=
212 extra_passes=
213 extra_parts=
214 extra_programs=
215 extra_objs=
216 extra_host_objs=
217 extra_gcc_objs=
218 xm_defines=
219 float_format=
220 # Set this to force installation and use of collect2.
221 use_collect2=
222 # Set this to override the default target model.
223 target_cpu_default=
224 # Set this to control which fixincludes program to use.
225 fixincludes=fixincludes
226 # Set this to control how the header file directory is installed.
227 install_headers_dir=install-headers-tar
228 # Set this to a non-empty list of args to pass to cpp if the target
229 # wants its .md file passed through cpp.
230 md_cppflags=
231 # Set this if directory names should be truncated to 14 characters.
232 truncate_target=
233 # Set this if gdb needs a dir command with `dirname $out_file`
234 gdb_needs_out_file_path=
235 # Set this if the build machine requires executables to have a
236 # file name suffix.
237 exeext=
238 # Set this to control which thread package will be used.
239 thread_file=
240
241 # Set default cpu_type, tm_file and xm_file so it can be updated in
242 # each machine entry.
243 cpu_type=`echo $machine | sed 's/-.*$//'`
244 case $machine in
245 alpha*-*-*)
246 cpu_type=alpha
247 ;;
248 arm*-*-*)
249 cpu_type=arm
250 ;;
251 c*-convex-*)
252 cpu_type=convex
253 ;;
254 i[[34567]]86-*-*)
255 cpu_type=i386
256 ;;
257 hppa*-*-*)
258 cpu_type=pa
259 ;;
260 m68000-*-*)
261 cpu_type=m68k
262 ;;
263 mips*-*-*)
264 cpu_type=mips
265 ;;
266 powerpc*-*-*)
267 cpu_type=rs6000
268 ;;
269 pyramid-*-*)
270 cpu_type=pyr
271 ;;
272 sparc*-*-*)
273 cpu_type=sparc
274 ;;
275 esac
276
277 tm_file=${cpu_type}/${cpu_type}.h
278 xm_file=${cpu_type}/xm-${cpu_type}.h
279
280 # Set the default macros to define for GNU/Linux systems.
281 case $machine in
282 *-*-linux-gnu*)
283 xm_defines="HAVE_ATEXIT POSIX NO_STAB_H BSTRING"
284 ;;
285 esac
286
287 case $machine in
288 # Support site-specific machine types.
289 *local*)
290 cpu_type=`echo $machine | sed -e 's/-.*//'`
291 rest=`echo $machine | sed -e "s/$cpu_type-//"`
292 xm_file=${cpu_type}/xm-$rest.h
293 tm_file=${cpu_type}/$rest.h
294 if [[ -f $srcdir/config/${cpu_type}/x-$rest ]] ; \
295 then xmake_file=${cpu_type}/x-$rest; \
296 else true; \
297 fi
298 if [[ -f $srcdir/config/${cpu_type}/t-$rest ]] ; \
299 then tmake_file=${cpu_type}/t-$rest; \
300 else true; \
301 fi
302 ;;
303 1750a-*-*)
304 ;;
305 a29k-*-bsd* | a29k-*-sym1*)
306 tm_file="${tm_file} a29k/unix.h"
307 xm_defines=USG
308 xmake_file=a29k/x-unix
309 use_collect2=yes
310 ;;
311 a29k-*-udi | a29k-*-coff)
312 tm_file="${tm_file} dbxcoff.h a29k/udi.h"
313 tmake_file=a29k/t-a29kbare
314 ;;
315 a29k-wrs-vxworks*)
316 tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h"
317 tmake_file=a29k/t-vx29k
318 extra_parts="crtbegin.o crtend.o"
319 thread_file='vxworks'
320 ;;
321 a29k-*-*) # Default a29k environment.
322 use_collect2=yes
323 ;;
324 alpha*-*-linux-gnuecoff*)
325 tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h"
326 xm_defines=USE_BFD
327 target_cpu_default="MASK_GAS"
328 gas=no
329 xmake_file=none
330 gas=yes gnu_ld=yes
331 ;;
332 alpha*-*-linux-gnulibc1*)
333 tm_file="${tm_file} alpha/elf.h alpha/linux-elf.h alpha/linux.h"
334 xm_defines=USE_BFD
335 target_cpu_default="MASK_GAS"
336 tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux alpha/t-crtbe"
337 extra_parts="crtbegin.o crtend.o"
338 xmake_file=none
339 gas=yes gnu_ld=yes
340 if [[ x$enable_threads = xyes ]]; then
341 thread_file='posix'
342 fi
343 ;;
344 alpha*-*-linux-gnu*)
345 tm_file="${tm_file} alpha/elf.h alpha/linux-elf.h alpha/linux.h"
346 xm_defines=USE_BFD
347 target_cpu_default="MASK_GAS"
348 tmake_file="t-linux alpha/t-linux alpha/t-crtbe"
349 extra_parts="crtbegin.o crtend.o"
350 xmake_file=none
351 fixincludes=Makefile.in
352 gas=yes gnu_ld=yes
353 if [[ x$enable_threads = xyes ]]; then
354 thread_file='posix'
355 fi
356 ;;
357 alpha*-dec-osf*)
358 if [[ x$stabs = xyes ]]
359 then
360 tm_file="${tm_file} dbx.h"
361 fi
362 if [[ x$gas != xyes ]]
363 then
364 extra_passes="mips-tfile mips-tdump"
365 fi
366 use_collect2=yes
367 case $machine in
368 *-*-osf1*)
369 tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h"
370 ;;
371 *-*-osf[[23]]*)
372 tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h"
373 ;;
374 *-*-osf4*)
375 tm_file="${tm_file} alpha/osf.h"
376 # Some versions of OSF4 (specifically X4.0-9 296.7) have
377 # a broken tar, so we use cpio instead.
378 install_headers_dir=install-headers-cpio
379 ;;
380 esac
381 case $machine in
382 *-*-osf4.0[[b-z]] | *-*-osf4.[[1-9]]*)
383 target_cpu_default=MASK_SUPPORT_ARCH
384 ;;
385 esac
386 ;;
387 alpha*-*-winnt*)
388 tm_file="${tm_file} alpha/win-nt.h"
389 xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h"
390 tmake_file=t-libc-ok
391 xmake_file=winnt/x-winnt
392 extra_host_objs=oldnames.o
393 extra_gcc_objs="spawnv.o oldnames.o"
394 fixincludes=fixinc.winnt
395 if [[ x$gnu_ld != xyes ]]
396 then
397 extra_programs=ld.exe
398 fi
399 if [[ x$enable_threads = xyes ]]; then
400 thread_file='win32'
401 fi
402 ;;
403 alpha*-dec-vms*)
404 tm_file=alpha/vms.h
405 xm_file="${xm_file} alpha/xm-vms.h"
406 tmake_file=alpha/t-vms
407 fixincludes=Makefile.in
408 ;;
409 arc-*-elf*)
410 extra_parts="crtinit.o crtfini.o"
411 ;;
412 arm-*-coff* | armel-*-coff*)
413 tm_file=arm/coff.h
414 tmake_file=arm/t-bare
415 ;;
416 arm-*-riscix1.[[01]]*) # Acorn RISC machine (early versions)
417 tm_file=arm/riscix1-1.h
418 use_collect2=yes
419 ;;
420 arm-*-riscix*) # Acorn RISC machine
421 if [[ x$gas = xyes ]]
422 then
423 tm_file=arm/rix-gas.h
424 else
425 tm_file=arm/riscix.h
426 fi
427 xmake_file=arm/x-riscix
428 tmake_file=arm/t-riscix
429 use_collect2=yes
430 ;;
431 arm-semi-aout | armel-semi-aout)
432 tm_file=arm/semi.h
433 tmake_file=arm/t-semi
434 fixincludes=Makefile.in # There is nothing to fix
435 ;;
436 arm-semi-aof | armel-semi-aof)
437 tm_file=arm/semiaof.h
438 tmake_file=arm/t-semiaof
439 fixincludes=Makefile.in # There is nothing to fix
440 ;;
441 arm-*-netbsd*)
442 tm_file=arm/netbsd.h
443 xm_file="xm-siglist.h ${xm_file}"
444 tmake_file="t-netbsd arm/t-netbsd"
445 # On NetBSD, the headers are already okay, except for math.h.
446 fixincludes=fixinc.math
447 ;;
448 arm-*-linux-gnuaout*) # ARM GNU/Linux
449 cpu_type=arm
450 xmake_file=x-linux
451 tm_file=arm/linux-gas.h
452 tmake_file=arm/t-linux
453 fixincludes=Makefile.in
454 gnu_ld=yes
455 ;;
456 arm-*-aout)
457 tm_file=arm/aout.h
458 tmake_file=arm/t-bare
459 ;;
460 c1-convex-*) # Convex C1
461 target_cpu_default=1
462 use_collect2=yes
463 fixincludes=Makefile.in
464 ;;
465 c2-convex-*) # Convex C2
466 target_cpu_default=2
467 use_collect2=yes
468 fixincludes=Makefile.in
469 ;;
470 c32-convex-*)
471 target_cpu_default=4
472 use_collect2=yes
473 fixincludes=Makefile.in
474 ;;
475 c34-convex-*)
476 target_cpu_default=8
477 use_collect2=yes
478 fixincludes=Makefile.in
479 ;;
480 c38-convex-*)
481 target_cpu_default=16
482 use_collect2=yes
483 fixincludes=Makefile.in
484 ;;
485 clipper-intergraph-clix*)
486 tm_file="${tm_file} svr3.h clipper/clix.h"
487 xm_file=clipper/xm-clix.h
488 xmake_file=clipper/x-clix
489 extra_headers=va-clipper.h
490 extra_parts="crtbegin.o crtend.o"
491 install_headers_dir=install-headers-cpio
492 ;;
493 dsp16xx-*)
494 ;;
495 elxsi-elxsi-*)
496 use_collect2=yes
497 ;;
498 # This hasn't been upgraded to GCC 2.
499 # fx80-alliant-*) # Alliant FX/80
500 # ;;
501 h8300-*-*)
502 float_format=i32
503 ;;
504 hppa1.1-*-pro*)
505 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
506 xm_file=pa/xm-papro.h
507 tmake_file=pa/t-pro
508 ;;
509 hppa1.1-*-osf*)
510 target_cpu_default=1
511 tm_file="${tm_file} pa/pa-osf.h"
512 use_collect2=yes
513 fixincludes=Makefile.in
514 ;;
515 hppa1.1-*-rtems*)
516 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h pa/rtems.h"
517 xm_file=pa/xm-papro.h
518 tmake_file=pa/t-pro
519 ;;
520 hppa1.0-*-osf*)
521 tm_file="${tm_file} pa/pa-osf.h"
522 use_collect2=yes
523 fixincludes=Makefile.in
524 ;;
525 hppa1.1-*-bsd*)
526 target_cpu_default=1
527 use_collect2=yes
528 fixincludes=Makefile.in
529 ;;
530 hppa1.0-*-bsd*)
531 use_collect2=yes
532 fixincludes=Makefile.in
533 ;;
534 hppa1.0-*-hpux7*)
535 tm_file="pa/pa-oldas.h ${tm_file} pa/pa-hpux7.h"
536 xm_file=pa/xm-pahpux.h
537 xmake_file=pa/x-pa-hpux
538 if [[ x$gas = xyes ]]
539 then
540 tm_file="${tm_file} pa/gas.h"
541 fi
542 install_headers_dir=install-headers-cpio
543 use_collect2=yes
544 ;;
545 hppa1.0-*-hpux8.0[[0-2]]*)
546 tm_file="${tm_file} pa/pa-hpux.h"
547 xm_file=pa/xm-pahpux.h
548 xmake_file=pa/x-pa-hpux
549 if [[ x$gas = xyes ]]
550 then
551 tm_file="${tm_file} pa/pa-gas.h"
552 else
553 tm_file="pa/pa-oldas.h ${tm_file}"
554 fi
555 install_headers_dir=install-headers-cpio
556 use_collect2=yes
557 ;;
558 hppa1.1-*-hpux8.0[[0-2]]*)
559 target_cpu_default=1
560 tm_file="${tm_file} pa/pa-hpux.h"
561 xm_file=pa/xm-pahpux.h
562 xmake_file=pa/x-pa-hpux
563 if [[ x$gas = xyes ]]
564 then
565 tm_file="${tm_file} pa/pa-gas.h"
566 else
567 tm_file="pa/pa-oldas.h ${tm_file}"
568 fi
569 install_headers_dir=install-headers-cpio
570 use_collect2=yes
571 ;;
572 hppa1.1-*-hpux8*)
573 target_cpu_default=1
574 tm_file="${tm_file} pa/pa-hpux.h"
575 xm_file=pa/xm-pahpux.h
576 xmake_file=pa/x-pa-hpux
577 if [[ x$gas = xyes ]]
578 then
579 tm_file="${tm_file} pa/pa-gas.h"
580 fi
581 install_headers_dir=install-headers-cpio
582 use_collect2=yes
583 ;;
584 hppa1.0-*-hpux8*)
585 tm_file="${tm_file} pa/pa-hpux.h"
586 xm_file=pa/xm-pahpux.h
587 xmake_file=pa/x-pa-hpux
588 if [[ x$gas = xyes ]]
589 then
590 tm_file="${tm_file} pa/pa-gas.h"
591 fi
592 install_headers_dir=install-headers-cpio
593 use_collect2=yes
594 ;;
595 hppa1.1-*-hpux10*)
596 target_cpu_default=1
597 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
598 xm_file=pa/xm-pahpux.h
599 xmake_file=pa/x-pa-hpux
600 tmake_file=pa/t-pa
601 if [[ x$gas = xyes ]]
602 then
603 tm_file="${tm_file} pa/pa-gas.h"
604 fi
605 if [[ x$enable_threads = x ]]; then
606 enable_threads=$have_pthread_h
607 fi
608 if [[ x$enable_threads = xyes ]]; then
609 thread_file='dce'
610 tmake_file="${tmake_file} pa/t-dce-thr"
611 fi
612 install_headers_dir=install-headers-cpio
613 use_collect2=yes
614 ;;
615 hppa1.0-*-hpux10*)
616 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
617 xm_file=pa/xm-pahpux.h
618 xmake_file=pa/x-pa-hpux
619 if [[ x$gas = xyes ]]
620 then
621 tm_file="${tm_file} pa/pa-gas.h"
622 fi
623 if [[ x$enable_threads = x ]]; then
624 enable_threads=$have_pthread_h
625 fi
626 if [[ x$enable_threads = xyes ]]; then
627 thread_file='dce'
628 tmake_file="${tmake_file} pa/t-dce-thr"
629 fi
630 install_headers_dir=install-headers-cpio
631 use_collect2=yes
632 ;;
633 hppa1.1-*-hpux*)
634 target_cpu_default=1
635 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
636 xm_file=pa/xm-pahpux.h
637 xmake_file=pa/x-pa-hpux
638 if [[ x$gas = xyes ]]
639 then
640 tm_file="${tm_file} pa/pa-gas.h"
641 fi
642 install_headers_dir=install-headers-cpio
643 use_collect2=yes
644 ;;
645 hppa1.0-*-hpux*)
646 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
647 xm_file=pa/xm-pahpux.h
648 xmake_file=pa/x-pa-hpux
649 if [[ x$gas = xyes ]]
650 then
651 tm_file="${tm_file} pa/pa-gas.h"
652 fi
653 install_headers_dir=install-headers-cpio
654 use_collect2=yes
655 ;;
656 hppa1.1-*-hiux*)
657 target_cpu_default=1
658 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
659 xm_file=pa/xm-pahpux.h
660 xmake_file=pa/x-pa-hpux
661 if [[ x$gas = xyes ]]
662 then
663 tm_file="${tm_file} pa/pa-gas.h"
664 fi
665 install_headers_dir=install-headers-cpio
666 use_collect2=yes
667 ;;
668 hppa1.0-*-hiux*)
669 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
670 xm_file=pa/xm-pahpux.h
671 xmake_file=pa/x-pa-hpux
672 if [[ x$gas = xyes ]]
673 then
674 tm_file="${tm_file} pa/pa-gas.h"
675 fi
676 install_headers_dir=install-headers-cpio
677 use_collect2=yes
678 ;;
679 hppa*-*-lites*)
680 target_cpu_default=1
681 use_collect2=yes
682 fixincludes=Makefile.in
683 ;;
684 i370-*-mvs*)
685 ;;
686 i[[34567]]86-ibm-aix*) # IBM PS/2 running AIX
687 if [[ x$gas = xyes ]]
688 then
689 tm_file=i386/aix386.h
690 extra_parts="crtbegin.o crtend.o"
691 tmake_file=i386/t-crtstuff
692 else
693 tm_file=i386/aix386ng.h
694 use_collect2=yes
695 fi
696 xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
697 xm_defines=USG
698 xmake_file=i386/x-aix
699 ;;
700 i[[34567]]86-ncr-sysv4*) # NCR 3000 - ix86 running system V.4
701 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
702 xm_defines="USG POSIX SMALL_ARG_MAX"
703 xmake_file=i386/x-ncr3000
704 if [[ x$stabs = xyes -a x$gas = xyes ]]
705 then
706 tm_file=i386/sysv4gdb.h
707 else
708 tm_file=i386/sysv4.h
709 fi
710 extra_parts="crtbegin.o crtend.o"
711 tmake_file=i386/t-crtpic
712 ;;
713 i[[34567]]86-next-*)
714 tm_file=i386/next.h
715 xm_file=i386/xm-next.h
716 tmake_file=i386/t-next
717 xmake_file=i386/x-next
718 extra_objs=nextstep.o
719 if [[ x$enable_threads = xyes ]]; then
720 thread_file='mach'
721 fi
722 ;;
723 i[[34567]]86-sequent-bsd*) # 80386 from Sequent
724 use_collect2=yes
725 if [[ x$gas = xyes ]]
726 then
727 tm_file=i386/seq-gas.h
728 else
729 tm_file=i386/sequent.h
730 fi
731 ;;
732 i[[34567]]86-sequent-ptx1*)
733 xm_defines="USG SVR3"
734 xmake_file=i386/x-sysv3
735 tm_file=i386/seq-sysv3.h
736 tmake_file=i386/t-crtstuff
737 fixincludes=fixinc.ptx
738 extra_parts="crtbegin.o crtend.o"
739 install_headers_dir=install-headers-cpio
740 ;;
741 i[[34567]]86-sequent-ptx2* | i[[34567]]86-sequent-sysv3*)
742 xm_defines="USG SVR3"
743 xmake_file=i386/x-sysv3
744 tm_file=i386/seq2-sysv3.h
745 tmake_file=i386/t-crtstuff
746 extra_parts="crtbegin.o crtend.o"
747 fixincludes=fixinc.ptx
748 install_headers_dir=install-headers-cpio
749 ;;
750 i[[34567]]86-sequent-ptx4* | i[[34567]]86-sequent-sysv4*)
751 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
752 xm_defines="USG POSIX SMALL_ARG_MAX"
753 xmake_file=x-svr4
754 tm_file=i386/ptx4-i.h
755 tmake_file=t-svr4
756 extra_parts="crtbegin.o crtend.o"
757 fixincludes=fixinc.ptx
758 install_headers_dir=install-headers-cpio
759 ;;
760 i386-sun-sunos*) # Sun i386 roadrunner
761 xm_defines=USG
762 tm_file=i386/sun.h
763 use_collect2=yes
764 ;;
765 i[[3456]]86-wrs-vxworks*)
766 tm_file=i386/vxi386.h
767 tmake_file=i386/t-i386bare
768 ;;
769 i[[34567]]86-*-aout*)
770 tm_file=i386/i386-aout.h
771 tmake_file=i386/t-i386bare
772 ;;
773 i[[34567]]86-*-bsdi* | i[[34567]]86-*-bsd386*)
774 tm_file=i386/bsd386.h
775 # tmake_file=t-libc-ok
776 ;;
777 i[[34567]]86-*-bsd*)
778 tm_file=i386/386bsd.h
779 # tmake_file=t-libc-ok
780 # Next line turned off because both 386BSD and BSD/386 use GNU ld.
781 # use_collect2=yes
782 ;;
783 i[[34567]]86-*-freebsdelf*)
784 tm_file="i386/i386.h i386/att.h linux.h i386/freebsd-elf.h i386/perform.h"
785 # On FreeBSD, the headers are already ok, except for math.h.
786 fixincludes=fixinc.math
787 tmake_file=i386/t-freebsd
788 gas=yes
789 gnu_ld=yes
790 stabs=yes
791 ;;
792 i[[34567]]86-*-freebsd*)
793 tm_file=i386/freebsd.h
794 # On FreeBSD, the headers are already ok, except for math.h.
795 fixincludes=fixinc.math
796 tmake_file=i386/t-freebsd
797 ;;
798 i[[34567]]86-*-netbsd*)
799 tm_file=i386/netbsd.h
800 # On NetBSD, the headers are already okay, except for math.h.
801 fixincludes=fixinc.math
802 tmake_file=t-netbsd
803 ;;
804 i[[34567]]86-*-coff*)
805 tm_file=i386/i386-coff.h
806 tmake_file=i386/t-i386bare
807 ;;
808 i[[34567]]86-*-isc*) # 80386 running ISC system
809 xm_file="${xm_file} i386/xm-isc.h"
810 xm_defines="USG SVR3"
811 case $machine in
812 i[[34567]]86-*-isc[[34]]*)
813 xmake_file=i386/x-isc3
814 ;;
815 *)
816 xmake_file=i386/x-isc
817 ;;
818 esac
819 if [[ x$gas = xyes -a x$stabs = xyes ]]
820 then
821 tm_file=i386/iscdbx.h
822 tmake_file=i386/t-svr3dbx
823 extra_parts="svr3.ifile svr3z.ifile"
824 else
825 tm_file=i386/isccoff.h
826 tmake_file=i386/t-crtstuff
827 extra_parts="crtbegin.o crtend.o"
828 fi
829 install_headers_dir=install-headers-cpio
830 ;;
831 i[[34567]]86-*-linux-gnuoldld*) # Intel 80386's running GNU/Linux
832 # with a.out format using
833 # pre BFD linkers
834 xmake_file=x-linux-aout
835 tmake_file="t-linux-aout i386/t-crtstuff"
836 tm_file=i386/linux-oldld.h
837 fixincludes=Makefile.in #On Linux, the headers are ok already.
838 gnu_ld=yes
839 ;;
840 i[[34567]]86-*-linux-gnuaout*) # Intel 80386's running GNU/Linux
841 # with a.out format
842 xmake_file=x-linux-aout
843 tmake_file="t-linux-aout i386/t-crtstuff"
844 tm_file=i386/linux-aout.h
845 fixincludes=Makefile.in #On Linux, the headers are ok already.
846 gnu_ld=yes
847 ;;
848 i[[34567]]86-*-linux-gnulibc1) # Intel 80386's running GNU/Linux
849 # with ELF format using the
850 # GNU/Linux C library 5
851 xmake_file=x-linux
852 tm_file=i386/linux.h
853 tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff"
854 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
855 fixincludes=Makefile.in #On Linux, the headers are ok already.
856 gnu_ld=yes
857 if [[ x$enable_threads = xyes ]]; then
858 thread_file='single'
859 fi
860 ;;
861 i[[34567]]86-*-linux-gnu*) # Intel 80386's running GNU/Linux
862 # with ELF format using glibc 2
863 # aka GNU/Linux C library 6
864 xmake_file=x-linux
865 tm_file=i386/linux.h
866 tmake_file="t-linux i386/t-crtstuff"
867 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
868 fixincludes=Makefile.in #On Linux, the headers are ok already.
869 gnu_ld=yes
870 if [[ x$enable_threads = xyes ]]; then
871 thread_file='posix'
872 fi
873 ;;
874 i[[34567]]86-*-gnu*)
875 ;;
876 i[[34567]]86-go32-msdos | i[[34567]]86-*-go32*)
877 xm_file=i386/xm-go32.h
878 tm_file=i386/go32.h
879 tmake_file=i386/t-go32
880 ;;
881 i[[34567]]86-pc-msdosdjgpp*)
882 xm_file=i386/xm-go32.h
883 tm_file=i386/go32.h
884 tmake_file=i386/t-go32
885 gnu_ld=yes
886 gas=yes
887 ;;
888 i[[34567]]86-moss-msdos* | i[[34567]]86-*-moss*)
889 tm_file=i386/moss.h
890 tmake_file=t-libc-ok
891 fixincludes=Makefile.in
892 gnu_ld=yes
893 gas=yes
894 ;;
895 i[[34567]]86-*-lynxos*)
896 if [[ x$gas = xyes ]]
897 then
898 tm_file=i386/lynx.h
899 else
900 tm_file=i386/lynx-ng.h
901 fi
902 xm_file=i386/xm-lynx.h
903 tmake_file=i386/t-i386bare
904 xmake_file=x-lynx
905 ;;
906 i[[34567]]86-*-mach*)
907 tm_file=i386/mach.h
908 # tmake_file=t-libc-ok
909 use_collect2=yes
910 ;;
911 i[[34567]]86-*-osfrose*) # 386 using OSF/rose
912 if [[ x$elf = xyes ]]
913 then
914 tm_file=i386/osfelf.h
915 use_collect2=
916 else
917 tm_file=i386/osfrose.h
918 use_collect2=yes
919 fi
920 xm_file="i386/xm-osf.h ${xm_file}"
921 xmake_file=i386/x-osfrose
922 tmake_file=i386/t-osf
923 extra_objs=halfpic.o
924 ;;
925 i[[34567]]86-go32-rtems*)
926 cpu_type=i386
927 xm_file=i386/xm-go32.h
928 tm_file=i386/go32-rtems.h
929 tmake_file="i386/t-go32 t-rtems"
930 ;;
931 i[[34567]]86-*-rtems*)
932 cpu_type=i386
933 tm_file=i386/rtems.h
934 tmake_file="i386/t-i386bare t-rtems"
935 ;;
936 i[[34567]]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
937 xm_file="xm-siglist.h xm-alloca.h ${xm_file} i386/xm-sco5.h"
938 xm_defines="USG SVR3"
939 xmake_file=i386/x-sco5
940 fixincludes=fixinc.sco
941 install_headers_dir=install-headers-cpio
942 tm_file=i386/sco5.h
943 tmake_file=i386/t-sco5
944 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
945 ;;
946 i[[34567]]86-*-sco3.2v4*) # 80386 running SCO 3.2v4 system
947 xm_file="${xm_file} i386/xm-sco.h"
948 xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX NO_SYS_SIGLIST"
949 xmake_file=i386/x-sco4
950 fixincludes=fixinc.sco
951 install_headers_dir=install-headers-cpio
952 if [[ x$stabs = xyes ]]
953 then
954 tm_file=i386/sco4dbx.h
955 tmake_file=i386/t-svr3dbx
956 extra_parts="svr3.ifile svr3z.rfile"
957 else
958 tm_file=i386/sco4.h
959 tmake_file=i386/t-crtstuff
960 extra_parts="crtbegin.o crtend.o"
961 fi
962 truncate_target=yes
963 ;;
964 i[[34567]]86-*-sco*) # 80386 running SCO system
965 xm_file=i386/xm-sco.h
966 xmake_file=i386/x-sco
967 install_headers_dir=install-headers-cpio
968 if [[ x$stabs = xyes ]]
969 then
970 tm_file=i386/scodbx.h
971 tmake_file=i386/t-svr3dbx
972 extra_parts="svr3.ifile svr3z.rfile"
973 else
974 tm_file=i386/sco.h
975 extra_parts="crtbegin.o crtend.o"
976 tmake_file=i386/t-crtstuff
977 fi
978 truncate_target=yes
979 ;;
980 i[[34567]]86-*-solaris2*)
981 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
982 xm_defines="USG POSIX SMALL_ARG_MAX"
983 if [[ x$stabs = xyes ]]
984 then
985 tm_file=i386/sol2dbg.h
986 else
987 tm_file=i386/sol2.h
988 fi
989 tmake_file=i386/t-sol2
990 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
991 xmake_file=x-svr4
992 case $machine in
993 *-*-solaris2.[[0-4]])
994 fixincludes=fixinc.svr4;;
995 *)
996 fixincludes=fixinc.math;;
997 esac
998 if [[ x$enable_threads = xyes ]]; then
999 thread_file='solaris'
1000 fi
1001 ;;
1002 i[[34567]]86-*-sysv5*) # Intel x86 on System V Release 5
1003 xm_file=i386/xm-sysv4.h
1004 tm_file=i386/sysv4.h
1005 if [[ x$stabs = xyes ]]
1006 then
1007 tm_file="${tm_file} dbx.h"
1008 fi
1009 tmake_file=i386/t-crtpic
1010 xmake_file=x-svr4
1011 extra_parts="crtbegin.o crtend.o"
1012 fixincludes=Makefile.in # The headers are just fine, thank you.
1013 ;;
1014 i[[34567]]86-*-sysv4*) # Intel 80386's running system V.4
1015 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1016 xm_defines="USG POSIX SMALL_ARG_MAX"
1017 tm_file=i386/sysv4.h
1018 if [[ x$stabs = xyes ]]
1019 then
1020 tm_file="${tm_file} dbx.h"
1021 fi
1022 tmake_file=i386/t-crtpic
1023 xmake_file=x-svr4
1024 extra_parts="crtbegin.o crtend.o"
1025 ;;
1026 i[[34567]]86-*-sysv*) # Intel 80386's running system V
1027 xm_defines="USG SVR3"
1028 xmake_file=i386/x-sysv3
1029 if [[ x$gas = xyes ]]
1030 then
1031 if [[ x$stabs = xyes ]]
1032 then
1033 tm_file=i386/svr3dbx.h
1034 tmake_file=i386/t-svr3dbx
1035 extra_parts="svr3.ifile svr3z.rfile"
1036 else
1037 tm_file=i386/svr3gas.h
1038 extra_parts="crtbegin.o crtend.o"
1039 tmake_file=i386/t-crtstuff
1040 fi
1041 else
1042 tm_file=i386/sysv3.h
1043 extra_parts="crtbegin.o crtend.o"
1044 tmake_file=i386/t-crtstuff
1045 fi
1046 ;;
1047 i386-*-vsta) # Intel 80386's running VSTa kernel
1048 xm_file=i386/xm-vsta.h
1049 tm_file=i386/vsta.h
1050 tmake_file=i386/t-vsta
1051 xmake_file=i386/x-vsta
1052 ;;
1053 i[[34567]]86-*-pe | i[[34567]]86-*-cygwin32)
1054 xm_file="${xm_file} i386/xm-cygwin32.h"
1055 tmake_file=i386/t-cygwin32
1056 tm_file=i386/cygwin32.h
1057 xmake_file=i386/x-cygwin32
1058 extra_objs=winnt.o
1059 fixincludes=Makefile.in
1060 if [[ x$enable_threads = xyes ]]; then
1061 thread_file='win32'
1062 fi
1063 exeext=.exe
1064 ;;
1065 i[[34567]]86-*-mingw32*)
1066 tm_file=i386/mingw32.h
1067 xm_file="${xm_file} i386/xm-mingw32.h"
1068 tmake_file=i386/t-cygwin32
1069 extra_objs=winnt.o
1070 xmake_file=i386/x-cygwin32
1071 fixincludes=Makefile.in
1072 if [[ x$enable_threads = xyes ]]; then
1073 thread_file='win32'
1074 fi
1075 exeext=.exe
1076 case $machine in
1077 *mingw32msv*)
1078 ;;
1079 *minwg32crt* | *mingw32*)
1080 tm_file="${tm_file} i386/crtdll.h"
1081 ;;
1082 esac
1083 ;;
1084 i[[34567]]86-*-winnt3*)
1085 tm_file=i386/win-nt.h
1086 out_file=i386/i386.c
1087 xm_file="xm-winnt.h ${xm_file}"
1088 xmake_file=winnt/x-winnt
1089 tmake_file=i386/t-winnt
1090 extra_host_objs="winnt.o oldnames.o"
1091 extra_gcc_objs="spawnv.o oldnames.o"
1092 fixincludes=fixinc.winnt
1093 if [[ x$gnu_ld != xyes ]]
1094 then
1095 extra_programs=ld.exe
1096 fi
1097 if [[ x$enable_threads = xyes ]]; then
1098 thread_file='win32'
1099 fi
1100 ;;
1101 i[[34567]]86-dg-dgux*)
1102 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1103 xm_defines="USG POSIX"
1104 out_file=i386/dgux.c
1105 tm_file=i386/dgux.h
1106 tmake_file=i386/t-dgux
1107 xmake_file=i386/x-dgux
1108 fixincludes=fixinc.dgux
1109 install_headers_dir=install-headers-cpio
1110 ;;
1111 i860-alliant-*) # Alliant FX/2800
1112 tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h"
1113 xm_file="${xm_file}"
1114 xmake_file=i860/x-fx2800
1115 tmake_file=i860/t-fx2800
1116 extra_parts="crtbegin.o crtend.o"
1117 ;;
1118 i860-*-bsd*)
1119 tm_file="${tm_file} i860/bsd.h"
1120 if [[ x$gas = xyes ]]
1121 then
1122 tm_file="${tm_file} i860/bsd-gas.h"
1123 fi
1124 use_collect2=yes
1125 ;;
1126 i860-*-mach*)
1127 tm_file="${tm_file} i860/mach.h"
1128 tmake_file=t-libc-ok
1129 ;;
1130 i860-*-osf*) # Intel Paragon XP/S, OSF/1AD
1131 tm_file="${tm_file} svr3.h i860/paragon.h"
1132 xm_defines="USG SVR3"
1133 tmake_file=t-osf
1134 ;;
1135 i860-*-sysv3*)
1136 tm_file="${tm_file} svr3.h i860/sysv3.h"
1137 xm_defines="USG SVR3"
1138 xmake_file=i860/x-sysv3
1139 extra_parts="crtbegin.o crtend.o"
1140 ;;
1141 i860-*-sysv4*)
1142 tm_file="${tm_file} svr4.h i860/sysv4.h"
1143 xm_defines="USG SVR3"
1144 xmake_file=i860/x-sysv4
1145 tmake_file=t-svr4
1146 extra_parts="crtbegin.o crtend.o"
1147 ;;
1148 i960-wrs-vxworks5 | i960-wrs-vxworks5.0*)
1149 tm_file="${tm_file} i960/vx960.h"
1150 tmake_file=i960/t-vxworks960
1151 use_collect2=yes
1152 thread_file='vxworks'
1153 ;;
1154 i960-wrs-vxworks5* | i960-wrs-vxworks)
1155 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h"
1156 tmake_file=i960/t-vxworks960
1157 use_collect2=yes
1158 thread_file='vxworks'
1159 ;;
1160 i960-wrs-vxworks*)
1161 tm_file="${tm_file} i960/vx960.h"
1162 tmake_file=i960/t-vxworks960
1163 use_collect2=yes
1164 thread_file='vxworks'
1165 ;;
1166 i960-*-coff*)
1167 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h"
1168 tmake_file=i960/t-960bare
1169 use_collect2=yes
1170 ;;
1171 i960-*-rtems)
1172 tmake_file="i960/t-960bare t-rtems"
1173 tm_file="${tm_file} dbxcoff.h i960/rtems.h"
1174 use_collect2=yes
1175 ;;
1176 i960-*-*) # Default i960 environment.
1177 use_collect2=yes
1178 ;;
1179 m32r-*-elf*)
1180 extra_parts="crtinit.o crtfini.o"
1181 ;;
1182 m68000-convergent-sysv*)
1183 tm_file=m68k/ctix.h
1184 xm_file="m68k/xm-3b1.h ${xm_file}"
1185 xm_defines=USG
1186 use_collect2=yes
1187 extra_headers=math-68881.h
1188 ;;
1189 m68000-hp-bsd*) # HP 9000/200 running BSD
1190 tm_file=m68k/hp2bsd.h
1191 xmake_file=m68k/x-hp2bsd
1192 use_collect2=yes
1193 extra_headers=math-68881.h
1194 ;;
1195 m68000-hp-hpux*) # HP 9000 series 300
1196 xm_file="xm_alloca.h ${xm_file}"
1197 xm_defines="USG NO_SYS_SIGLIST"
1198 if [[ x$gas = xyes ]]
1199 then
1200 xmake_file=m68k/x-hp320g
1201 tm_file=m68k/hp310g.h
1202 else
1203 xmake_file=m68k/x-hp320
1204 tm_file=m68k/hp310.h
1205 fi
1206 install_headers_dir=install-headers-cpio
1207 use_collect2=yes
1208 extra_headers=math-68881.h
1209 ;;
1210 m68000-sun-sunos3*)
1211 tm_file=m68k/sun2.h
1212 use_collect2=yes
1213 extra_headers=math-68881.h
1214 ;;
1215 m68000-sun-sunos4*)
1216 tm_file=m68k/sun2o4.h
1217 use_collect2=yes
1218 extra_headers=math-68881.h
1219 ;;
1220 m68000-att-sysv*)
1221 xm_file="m68k/xm-3b1.h ${xm_file}"
1222 xm_defines=USG
1223 if [[ x$gas = xyes ]]
1224 then
1225 tm_file=m68k/3b1g.h
1226 else
1227 tm_file=m68k/3b1.h
1228 fi
1229 use_collect2=yes
1230 extra_headers=math-68881.h
1231 ;;
1232 m68k-apple-aux*) # Apple Macintosh running A/UX
1233 xm_defines="USG AUX"
1234 tmake_file=m68k/t-aux
1235 install_headers_dir=install-headers-cpio
1236 extra_headers=math-68881.h
1237 extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o"
1238 tm_file=
1239 if [[ "$gnu_ld" = yes ]]
1240 then
1241 tm_file="${tm_file} m68k/auxgld.h"
1242 else
1243 tm_file="${tm_file} m68k/auxld.h"
1244 fi
1245 if [[ "$gas" = yes ]]
1246 then
1247 tm_file="${tm_file} m68k/auxgas.h"
1248 else
1249 tm_file="${tm_file} m68k/auxas.h"
1250 fi
1251 tm_file="${tm_file} m68k/a-ux.h"
1252 ;;
1253 m68k-apollo-*)
1254 tm_file=m68k/apollo68.h
1255 xmake_file=m68k/x-apollo68
1256 use_collect2=yes
1257 extra_headers=math-68881.h
1258 ;;
1259 m68k-altos-sysv*) # Altos 3068
1260 if [[ x$gas = xyes ]]
1261 then
1262 tm_file=m68k/altos3068.h
1263 xm_defines=USG
1264 else
1265 echo "The Altos is supported only with the GNU assembler" 1>&2
1266 exit 1
1267 fi
1268 extra_headers=math-68881.h
1269 ;;
1270 m68k-bull-sysv*) # Bull DPX/2
1271 if [[ x$gas = xyes ]]
1272 then
1273 if [[ x$stabs = xyes ]]
1274 then
1275 tm_file=m68k/dpx2cdbx.h
1276 else
1277 tm_file=m68k/dpx2g.h
1278 fi
1279 else
1280 tm_file=m68k/dpx2.h
1281 fi
1282 xm_file="xm-alloca.h ${xm_file}"
1283 xm_defines=USG
1284 xmake_file=m68k/x-dpx2
1285 use_collect2=yes
1286 extra_headers=math-68881.h
1287 ;;
1288 m68k-atari-sysv4*) # Atari variant of V.4.
1289 tm_file=m68k/atari.h
1290 xm_file="xm-alloca.h ${xm_file}"
1291 xm_defines="USG FULL_PROTOTYPES"
1292 tmake_file=t-svr4
1293 extra_parts="crtbegin.o crtend.o"
1294 extra_headers=math-68881.h
1295 ;;
1296 m68k-motorola-sysv*)
1297 tm_file=m68k/mot3300.h
1298 xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}"
1299 xm_defines=NO_SYS_SIGLIST
1300 if [[ x$gas = xyes ]]
1301 then
1302 xmake_file=m68k/x-mot3300-gas
1303 if [[ x$gnu_ld = xyes ]]
1304 then
1305 tmake_file=m68k/t-mot3300-gald
1306 else
1307 tmake_file=m68k/t-mot3300-gas
1308 use_collect2=yes
1309 fi
1310 else
1311 xmake_file=m68k/x-mot3300
1312 if [[ x$gnu_ld = xyes ]]
1313 then
1314 tmake_file=m68k/t-mot3300-gld
1315 else
1316 tmake_file=m68k/t-mot3300
1317 use_collect2=yes
1318 fi
1319 fi
1320 gdb_needs_out_file_path=yes
1321 extra_parts="crt0.o mcrt0.o"
1322 extra_headers=math-68881.h
1323 ;;
1324 m68k-ncr-sysv*) # NCR Tower 32 SVR3
1325 tm_file=m68k/tower-as.h
1326 xm_defines="USG SVR3"
1327 xmake_file=m68k/x-tower
1328 extra_parts="crtbegin.o crtend.o"
1329 extra_headers=math-68881.h
1330 ;;
1331 m68k-plexus-sysv*)
1332 tm_file=m68k/plexus.h
1333 xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}"
1334 xm_defines=USG
1335 use_collect2=yes
1336 extra_headers=math-68881.h
1337 ;;
1338 m68k-tti-*)
1339 tm_file=m68k/pbb.h
1340 xm_file="xm-alloca.h ${xm_file}"
1341 xm_defines=USG
1342 extra_headers=math-68881.h
1343 ;;
1344 m68k-crds-unos*)
1345 xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}"
1346 xm_defines="USG unos"
1347 xmake_file=m68k/x-crds
1348 tm_file=m68k/crds.h
1349 use_collect2=yes
1350 extra_headers=math-68881.h
1351 ;;
1352 m68k-cbm-sysv4*) # Commodore variant of V.4.
1353 tm_file=m68k/amix.h
1354 xm_file="xm-alloca.h ${xm_file}"
1355 xm_defines="USG FULL_PROTOTYPES"
1356 xmake_file=m68k/x-amix
1357 tmake_file=t-svr4
1358 extra_parts="crtbegin.o crtend.o"
1359 extra_headers=math-68881.h
1360 ;;
1361 m68k-ccur-rtu)
1362 tm_file=m68k/ccur-GAS.h
1363 xmake_file=m68k/x-ccur
1364 extra_headers=math-68881.h
1365 use_collect2=yes
1366 ;;
1367 m68k-hp-bsd4.4*) # HP 9000/3xx running 4.4bsd
1368 tm_file=m68k/hp3bsd44.h
1369 xmake_file=m68k/x-hp3bsd44
1370 use_collect2=yes
1371 extra_headers=math-68881.h
1372 ;;
1373 m68k-hp-bsd*) # HP 9000/3xx running Berkeley Unix
1374 tm_file=m68k/hp3bsd.h
1375 use_collect2=yes
1376 extra_headers=math-68881.h
1377 ;;
1378 m68k-isi-bsd*)
1379 if [[ x$with_fp = xno ]]
1380 then
1381 tm_file=m68k/isi-nfp.h
1382 else
1383 tm_file=m68k/isi.h
1384 fi
1385 use_collect2=yes
1386 extra_headers=math-68881.h
1387 ;;
1388 m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
1389 xm_file="xm_alloca.h ${xm_file}"
1390 xm_defines="USG NO_SYS_SIGLIST"
1391 if [[ x$gas = xyes ]]
1392 then
1393 xmake_file=m68k/x-hp320g
1394 tm_file=m68k/hp320g.h
1395 else
1396 xmake_file=m68k/x-hp320
1397 tm_file=m68k/hpux7.h
1398 fi
1399 install_headers_dir=install-headers-cpio
1400 use_collect2=yes
1401 extra_headers=math-68881.h
1402 ;;
1403 m68k-hp-hpux*) # HP 9000 series 300
1404 xm_file="xm_alloca.h ${xm_file}"
1405 xm_defines="USG NO_SYS_SIGLIST"
1406 if [[ x$gas = xyes ]]
1407 then
1408 xmake_file=m68k/x-hp320g
1409 tm_file=m68k/hp320g.h
1410 else
1411 xmake_file=m68k/x-hp320
1412 tm_file=m68k/hp320.h
1413 fi
1414 install_headers_dir=install-headers-cpio
1415 use_collect2=yes
1416 extra_headers=math-68881.h
1417 ;;
1418 m68k-sun-mach*)
1419 tm_file=m68k/sun3mach.h
1420 use_collect2=yes
1421 extra_headers=math-68881.h
1422 ;;
1423 m68k-sony-newsos3*)
1424 if [[ x$gas = xyes ]]
1425 then
1426 tm_file=m68k/news3gas.h
1427 else
1428 tm_file=m68k/news3.h
1429 fi
1430 use_collect2=yes
1431 extra_headers=math-68881.h
1432 ;;
1433 m68k-sony-bsd* | m68k-sony-newsos*)
1434 if [[ x$gas = xyes ]]
1435 then
1436 tm_file=m68k/newsgas.h
1437 else
1438 tm_file=m68k/news.h
1439 fi
1440 use_collect2=yes
1441 extra_headers=math-68881.h
1442 ;;
1443 m68k-next-nextstep2*)
1444 tm_file=m68k/next21.h
1445 xm_file="m68k/xm-next.h ${xm_file}"
1446 tmake_file=m68k/t-next
1447 xmake_file=m68k/x-next
1448 extra_objs=nextstep.o
1449 extra_headers=math-68881.h
1450 use_collect2=yes
1451 ;;
1452 m68k-next-nextstep3*)
1453 tm_file=m68k/next.h
1454 xm_file="m68k/xm-next.h ${xm_file}"
1455 tmake_file=m68k/t-next
1456 xmake_file=m68k/x-next
1457 extra_objs=nextstep.o
1458 extra_headers=math-68881.h
1459 if [[ x$enable_threads = xyes ]]; then
1460 thread_file='mach'
1461 fi
1462 ;;
1463 m68k-sun-sunos3*)
1464 if [[ x$with_fp = xno ]]
1465 then
1466 tm_file=m68k/sun3n3.h
1467 else
1468 tm_file=m68k/sun3o3.h
1469 fi
1470 use_collect2=yes
1471 extra_headers=math-68881.h
1472 ;;
1473 m68k-sun-sunos*) # For SunOS 4 (the default).
1474 if [[ x$with_fp = xno ]]
1475 then
1476 tm_file=m68k/sun3n.h
1477 else
1478 tm_file=m68k/sun3.h
1479 fi
1480 use_collect2=yes
1481 extra_headers=math-68881.h
1482 ;;
1483 m68k-wrs-vxworks*)
1484 tm_file=m68k/vxm68k.h
1485 tmake_file=m68k/t-vxworks68
1486 extra_headers=math-68881.h
1487 thread_file='vxworks'
1488 ;;
1489 m68k-*-aout*)
1490 tmake_file=m68k/t-m68kbare
1491 tm_file="m68k/m68k-aout.h libgloss.h"
1492 extra_headers=math-68881.h
1493 ;;
1494 m68k-*-coff*)
1495 tmake_file=m68k/t-m68kbare
1496 tm_file="m68k/m68k-coff.h dbx.h libgloss.h"
1497 extra_headers=math-68881.h
1498 ;;
1499 m68k-*-lynxos*)
1500 if [[ x$gas = xyes ]]
1501 then
1502 tm_file=m68k/lynx.h
1503 else
1504 tm_file=m68k/lynx-ng.h
1505 fi
1506 xm_file=m68k/xm-lynx.h
1507 xmake_file=x-lynx
1508 tmake_file=m68k/t-lynx
1509 extra_headers=math-68881.h
1510 ;;
1511 m68k-*-netbsd*)
1512 tm_file=m68k/netbsd.h
1513 # On NetBSD, the headers are already okay, except for math.h.
1514 fixincludes=fixinc.math
1515 tmake_file=t-netbsd
1516 ;;
1517 m68k-*-sysv3*) # Motorola m68k's running system V.3
1518 xm_file="xm-alloca.h ${xm_file}"
1519 xm_defines=USG
1520 xmake_file=m68k/x-m68kv
1521 extra_parts="crtbegin.o crtend.o"
1522 extra_headers=math-68881.h
1523 ;;
1524 m68k-*-sysv4*) # Motorola m68k's running system V.4
1525 tm_file=m68k/m68kv4.h
1526 xm_file="xm-alloca.h ${xm_file}"
1527 xm_defines=USG
1528 tmake_file=t-svr4
1529 extra_parts="crtbegin.o crtend.o"
1530 extra_headers=math-68881.h
1531 ;;
1532 m68k-*-linux-gnuaout*) # Motorola m68k's running GNU/Linux
1533 # with a.out format
1534 xmake_file=x-linux
1535 tm_file=m68k/linux-aout.h
1536 tmake_file="t-linux-aout m68k/t-linux-aout"
1537 fixincludes=Makefile.in # The headers are ok already.
1538 extra_headers=math-68881.h
1539 gnu_ld=yes
1540 ;;
1541 m68k-*-linux-gnulibc1) # Motorola m68k's running GNU/Linux
1542 # with ELF format using the
1543 # GNU/Linux C library 5
1544 xmake_file=x-linux
1545 tm_file=m68k/linux.h
1546 tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux"
1547 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1548 fixincludes=Makefile.in # The headers are ok already.
1549 extra_headers=math-68881.h
1550 gnu_ld=yes
1551 ;;
1552 m68k-*-linux-gnu*) # Motorola m68k's running GNU/Linux
1553 # with ELF format using glibc 2
1554 # aka the GNU/Linux C library 6.
1555 xmake_file=x-linux
1556 tm_file=m68k/linux.h
1557 tmake_file="t-linux m68k/t-linux"
1558 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1559 fixincludes=Makefile.in # The headers are ok already.
1560 extra_headers=math-68881.h
1561 gnu_ld=yes
1562 if [[ x$enable_threads = xyes ]]; then
1563 thread_file='posix'
1564 fi
1565 ;;
1566 m68k-*-psos*)
1567 tmake_file=m68k/t-m68kbare
1568 tm_file=m68k/m68k-psos.h
1569 extra_headers=math-68881.h
1570 ;;
1571 m68k-*-rtems*)
1572 tmake_file="m68k/t-m68kbare t-rtems"
1573 tm_file=m68k/rtems.h
1574 extra_headers=math-68881.h
1575 ;;
1576
1577 m88k-dg-dgux*)
1578 case $machine in
1579 m88k-dg-dguxbcs*)
1580 tm_file=m88k/dguxbcs.h
1581 tmake_file=m88k/t-dguxbcs
1582 ;;
1583 *)
1584 tm_file=m88k/dgux.h
1585 tmake_file=m88k/t-dgux
1586 ;;
1587 esac
1588 extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld"
1589 xmake_file=m88k/x-dgux
1590 if [[ x$gas = xyes ]]
1591 then
1592 tmake_file=m88k/t-dgux-gas
1593 fi
1594 fixincludes=fixinc.dgux
1595 ;;
1596 m88k-dolphin-sysv3*)
1597 tm_file=m88k/dolph.h
1598 extra_parts="crtbegin.o crtend.o"
1599 xm_file="m88k/xm-sysv3.h ${xm_file}"
1600 xmake_file=m88k/x-dolph
1601 if [[ x$gas = xyes ]]
1602 then
1603 tmake_file=m88k/t-m88k-gas
1604 fi
1605 ;;
1606 m88k-tektronix-sysv3)
1607 tm_file=m88k/tekXD88.h
1608 extra_parts="crtbegin.o crtend.o"
1609 xm_file="m88k/xm-sysv3.h ${xm_file}"
1610 xmake_file=m88k/x-tekXD88
1611 if [[ x$gas = xyes ]]
1612 then
1613 tmake_file=m88k/t-m88k-gas
1614 fi
1615 ;;
1616 m88k-*-aout*)
1617 tm_file=m88k/m88k-aout.h
1618 ;;
1619 m88k-*-coff*)
1620 tm_file=m88k/m88k-coff.h
1621 tmake_file=m88k/t-bug
1622 ;;
1623 m88k-*-luna*)
1624 tm_file=m88k/luna.h
1625 extra_parts="crtbegin.o crtend.o"
1626 if [[ x$gas = xyes ]]
1627 then
1628 tmake_file=m88k/t-luna-gas
1629 else
1630 tmake_file=m88k/t-luna
1631 fi
1632 ;;
1633 m88k-*-sysv3*)
1634 tm_file=m88k/sysv3.h
1635 extra_parts="crtbegin.o crtend.o"
1636 xm_file="m88k/xm-sysv3.h ${xm_file}"
1637 xmake_file=m88k/x-sysv3
1638 if [[ x$gas = xyes ]]
1639 then
1640 tmake_file=m88k/t-m88k-gas
1641 fi
1642 ;;
1643 m88k-*-sysv4*)
1644 tm_file=m88k/sysv4.h
1645 extra_parts="crtbegin.o crtend.o"
1646 xmake_file=m88k/x-sysv4
1647 tmake_file=m88k/t-sysv4
1648 ;;
1649 mips-sgi-irix6*) # SGI System V.4., IRIX 6
1650 tm_file=mips/iris6.h
1651 xm_file=mips/xm-iris6.h
1652 fixincludes=fixinc.irix
1653 xmake_file=mips/x-iris6
1654 tmake_file=mips/t-iris6
1655 if [[ x$enable_threads = xyes ]]; then
1656 thread_file='irix'
1657 fi
1658 ;;
1659 mips-wrs-vxworks)
1660 tm_file="mips/elf.h libgloss.h"
1661 tmake_file=mips/t-ecoff
1662 gas=yes
1663 gnu_ld=yes
1664 extra_parts="crtbegin.o crtend.o"
1665 # thread_file='vxworks'
1666 ;;
1667 mips-sgi-irix5cross64) # Irix5 host, Irix 6 target, cross64
1668 tm_file="mips/iris6.h mips/cross64.h"
1669 xm_defines="USG HAVE_INTTYPES_H"
1670 fixincludes=Makefile.in
1671 xmake_file=mips/x-iris
1672 tmake_file=mips/t-cross64
1673 # See comment in mips/iris[56].h files.
1674 use_collect2=yes
1675 if [[ x$enable_threads = xyes ]]; then
1676 thread_file='irix'
1677 fi
1678 ;;
1679 mips-sni-sysv4)
1680 if [[ x$gas = xyes ]]
1681 then
1682 if [[ x$stabs = xyes ]]
1683 then
1684 tm_file=mips/iris5gdb.h
1685 else
1686 tm_file="mips/sni-svr4.h mips/sni-gas.h"
1687 fi
1688 else
1689 tm_file=mips/sni-svr4.h
1690 fi
1691 xm_defines=USG
1692 xmake_file=mips/x-sni-svr4
1693 tmake_file=mips/t-mips-gas
1694 if [[ x$gnu_ld != xyes ]]
1695 then
1696 use_collect2=yes
1697 fi
1698 ;;
1699 mips-sgi-irix5*) # SGI System V.4., IRIX 5
1700 if [[ x$gas = xyes ]]
1701 then
1702 tm_file="mips/iris5.h mips/iris5gas.h"
1703 if [[ x$stabs = xyes ]]
1704 then
1705 tm_file="${tm_file} dbx.h"
1706 fi
1707 else
1708 tm_file=mips/iris5.h
1709 fi
1710 xm_defines="USG HAVE_INTTYPES_H"
1711 fixincludes=fixinc.irix
1712 xmake_file=mips/x-iris
1713 # mips-tfile doesn't work yet
1714 tmake_file=mips/t-mips-gas
1715 # See comment in mips/iris5.h file.
1716 use_collect2=yes
1717 if [[ x$enable_threads = xyes ]]; then
1718 thread_file='irix'
1719 fi
1720 ;;
1721 mips-sgi-irix4loser*) # Mostly like a MIPS.
1722 tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h"
1723 if [[ x$stabs = xyes ]]; then
1724 tm_file="${tm_file} dbx.h"
1725 fi
1726 xm_defines=USG
1727 xmake_file=mips/x-iris
1728 if [[ x$gas = xyes ]]
1729 then
1730 tmake_file=mips/t-mips-gas
1731 else
1732 extra_passes="mips-tfile mips-tdump"
1733 fi
1734 if [[ x$gnu_ld != xyes ]]
1735 then
1736 use_collect2=yes
1737 fi
1738 if [[ x$enable_threads = xyes ]]; then
1739 thread_file='irix'
1740 fi
1741 ;;
1742 mips-sgi-irix4*) # Mostly like a MIPS.
1743 tm_file="mips/iris3.h ${tm_file} mips/iris4.h"
1744 if [[ x$stabs = xyes ]]; then
1745 tm_file="${tm_file} dbx.h"
1746 fi
1747 xm_defines=USG
1748 xmake_file=mips/x-iris
1749 if [[ x$gas = xyes ]]
1750 then
1751 tmake_file=mips/t-mips-gas
1752 else
1753 extra_passes="mips-tfile mips-tdump"
1754 fi
1755 if [[ x$gnu_ld != xyes ]]
1756 then
1757 use_collect2=yes
1758 fi
1759 if [[ x$enable_threads = xyes ]]; then
1760 thread_file='irix'
1761 fi
1762 ;;
1763 mips-sgi-*) # Mostly like a MIPS.
1764 tm_file="mips/iris3.h ${tm_file}"
1765 if [[ x$stabs = xyes ]]; then
1766 tm_file="${tm_file} dbx.h"
1767 fi
1768 xm_defines=USG
1769 xmake_file=mips/x-iris3
1770 if [[ x$gas = xyes ]]
1771 then
1772 tmake_file=mips/t-mips-gas
1773 else
1774 extra_passes="mips-tfile mips-tdump"
1775 fi
1776 if [[ x$gnu_ld != xyes ]]
1777 then
1778 use_collect2=yes
1779 fi
1780 ;;
1781 mips-dec-osfrose*) # Decstation running OSF/1 reference port with OSF/rose.
1782 tm_file="mips/osfrose.h ${tm_file}"
1783 xmake_file=mips/x-osfrose
1784 tmake_file=mips/t-osfrose
1785 extra_objs=halfpic.o
1786 use_collect2=yes
1787 ;;
1788 mips-dec-osf*) # Decstation running OSF/1 as shipped by DIGITAL
1789 tm_file=mips/dec-osf1.h
1790 if [[ x$stabs = xyes ]]; then
1791 tm_file="${tm_file} dbx.h"
1792 fi
1793 xmake_file=mips/x-dec-osf1
1794 if [[ x$gas = xyes ]]
1795 then
1796 tmake_file=mips/t-mips-gas
1797 else
1798 tmake_file=mips/t-ultrix
1799 extra_passes="mips-tfile mips-tdump"
1800 fi
1801 if [[ x$gnu_ld != xyes ]]
1802 then
1803 use_collect2=yes
1804 fi
1805 ;;
1806 mips-dec-bsd*) # Decstation running 4.4 BSD
1807 tm_file=mips/dec-bsd.h
1808 fixincludes=
1809 if [[ x$gas = xyes ]]
1810 then
1811 tmake_file=mips/t-mips-gas
1812 else
1813 tmake_file=mips/t-ultrix
1814 extra_passes="mips-tfile mips-tdump"
1815 fi
1816 if [[ x$gnu_ld != xyes ]]
1817 then
1818 use_collect2=yes
1819 fi
1820 ;;
1821 mips-dec-netbsd*) # Decstation running NetBSD
1822 tm_file=mips/netbsd.h
1823 # On NetBSD, the headers are already okay, except for math.h.
1824 fixincludes=fixinc.math
1825 tmake_file=t-netbsd
1826 ;;
1827 mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news.
1828 tm_file="mips/news4.h ${tm_file}"
1829 if [[ x$stabs = xyes ]]; then
1830 tm_file="${tm_file} dbx.h"
1831 fi
1832 if [[ x$gas = xyes ]]
1833 then
1834 tmake_file=mips/t-mips-gas
1835 else
1836 extra_passes="mips-tfile mips-tdump"
1837 fi
1838 if [[ x$gnu_ld != xyes ]]
1839 then
1840 use_collect2=yes
1841 fi
1842 xmake_file=mips/x-sony
1843 ;;
1844 mips-sony-sysv*) # Sony NEWS 3800 with NEWSOS5.0.
1845 # That is based on svr4.
1846 # t-svr4 is not right because this system doesn't use ELF.
1847 tm_file="mips/news5.h ${tm_file}"
1848 if [[ x$stabs = xyes ]]; then
1849 tm_file="${tm_file} dbx.h"
1850 fi
1851 xm_file="xm-siglist.h ${xm_file}"
1852 xm_defines=USG
1853 if [[ x$gas = xyes ]]
1854 then
1855 tmake_file=mips/t-mips-gas
1856 else
1857 extra_passes="mips-tfile mips-tdump"
1858 fi
1859 if [[ x$gnu_ld != xyes ]]
1860 then
1861 use_collect2=yes
1862 fi
1863 ;;
1864 mips-tandem-sysv4*) # Tandem S2 running NonStop UX
1865 tm_file="mips/svr4-5.h mips/svr4-t.h"
1866 if [[ x$stabs = xyes ]]; then
1867 tm_file="${tm_file} dbx.h"
1868 fi
1869 xm_file="xm-siglist.h ${xm_file}"
1870 xm_defines=USG
1871 xmake_file=mips/x-sysv
1872 if [[ x$gas = xyes ]]
1873 then
1874 tmake_file=mips/t-mips-gas
1875 extra_parts="crtbegin.o crtend.o"
1876 else
1877 tmake_file=mips/t-mips
1878 extra_passes="mips-tfile mips-tdump"
1879 fi
1880 if [[ x$gnu_ld != xyes ]]
1881 then
1882 use_collect2=yes
1883 fi
1884 ;;
1885 mips-*-ultrix* | mips-dec-mach3) # Decstation.
1886 tm_file="mips/ultrix.h ${tm_file}"
1887 if [[ x$stabs = xyes ]]; then
1888 tm_file="${tm_file} dbx.h"
1889 fi
1890 xmake_file=mips/x-ultrix
1891 if [[ x$gas = xyes ]]
1892 then
1893 tmake_file=mips/t-mips-gas
1894 else
1895 tmake_file=mips/t-ultrix
1896 extra_passes="mips-tfile mips-tdump"
1897 fi
1898 if [[ x$gnu_ld != xyes ]]
1899 then
1900 use_collect2=yes
1901 fi
1902 ;;
1903 mips-*-riscos[[56789]]bsd*)
1904 tm_file=mips/bsd-5.h # MIPS BSD 4.3, RISC-OS 5.0
1905 if [[ x$stabs = xyes ]]; then
1906 tm_file="${tm_file} dbx.h"
1907 fi
1908 if [[ x$gas = xyes ]]
1909 then
1910 tmake_file=mips/t-bsd-gas
1911 else
1912 tmake_file=mips/t-bsd
1913 extra_passes="mips-tfile mips-tdump"
1914 fi
1915 if [[ x$gnu_ld != xyes ]]
1916 then
1917 use_collect2=yes
1918 fi
1919 ;;
1920 mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[[1234]]bsd*)
1921 tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0
1922 if [[ x$stabs = xyes ]]; then
1923 tm_file="${tm_file} dbx.h"
1924 fi
1925 if [[ x$gas = xyes ]]
1926 then
1927 tmake_file=mips/t-bsd-gas
1928 else
1929 tmake_file=mips/t-bsd
1930 extra_passes="mips-tfile mips-tdump"
1931 fi
1932 if [[ x$gnu_ld != xyes ]]
1933 then
1934 use_collect2=yes
1935 fi
1936 ;;
1937 mips-*-riscos[[56789]]sysv4*)
1938 tm_file=mips/svr4-5.h # MIPS System V.4., RISC-OS 5.0
1939 if [[ x$stabs = xyes ]]; then
1940 tm_file="${tm_file} dbx.h"
1941 fi
1942 xm_file="xm-siglist.h ${xm_file}"
1943 xmake_file=mips/x-sysv
1944 if [[ x$gas = xyes ]]
1945 then
1946 tmake_file=mips/t-svr4-gas
1947 else
1948 tmake_file=mips/t-svr4
1949 extra_passes="mips-tfile mips-tdump"
1950 fi
1951 if [[ x$gnu_ld != xyes ]]
1952 then
1953 use_collect2=yes
1954 fi
1955 ;;
1956 mips-*-sysv4* | mips-*-riscos[[1234]]sysv4* | mips-*-riscossysv4*)
1957 tm_file="mips/svr4-4.h ${tm_file}"
1958 if [[ x$stabs = xyes ]]; then
1959 tm_file="${tm_file} dbx.h"
1960 fi
1961 xm_defines=USG
1962 xmake_file=mips/x-sysv
1963 if [[ x$gas = xyes ]]
1964 then
1965 tmake_file=mips/t-svr4-gas
1966 else
1967 tmake_file=mips/t-svr4
1968 extra_passes="mips-tfile mips-tdump"
1969 fi
1970 if [[ x$gnu_ld != xyes ]]
1971 then
1972 use_collect2=yes
1973 fi
1974 ;;
1975 mips-*-riscos[[56789]]sysv*)
1976 tm_file=mips/svr3-5.h # MIPS System V.3, RISC-OS 5.0
1977 if [[ x$stabs = xyes ]]; then
1978 tm_file="${tm_file} dbx.h"
1979 fi
1980 xm_defines=USG
1981 xmake_file=mips/x-sysv
1982 if [[ x$gas = xyes ]]
1983 then
1984 tmake_file=mips/t-svr3-gas
1985 else
1986 tmake_file=mips/t-svr3
1987 extra_passes="mips-tfile mips-tdump"
1988 fi
1989 if [[ x$gnu_ld != xyes ]]
1990 then
1991 use_collect2=yes
1992 fi
1993 ;;
1994 mips-*-sysv* | mips-*-riscos*sysv*)
1995 tm_file="mips/svr3-4.h ${tm_file}"
1996 if [[ x$stabs = xyes ]]; then
1997 tm_file="${tm_file} dbx.h"
1998 fi
1999 xm_defines=USG
2000 xmake_file=mips/x-sysv
2001 if [[ x$gas = xyes ]]
2002 then
2003 tmake_file=mips/t-svr3-gas
2004 else
2005 tmake_file=mips/t-svr3
2006 extra_passes="mips-tfile mips-tdump"
2007 fi
2008 if [[ x$gnu_ld != xyes ]]
2009 then
2010 use_collect2=yes
2011 fi
2012 ;;
2013 mips-*-riscos[[56789]]*) # Default MIPS RISC-OS 5.0.
2014 tm_file=mips/mips-5.h
2015 if [[ x$stabs = xyes ]]; then
2016 tm_file="${tm_file} dbx.h"
2017 fi
2018 if [[ x$gas = xyes ]]
2019 then
2020 tmake_file=mips/t-mips-gas
2021 else
2022 extra_passes="mips-tfile mips-tdump"
2023 fi
2024 if [[ x$gnu_ld != xyes ]]
2025 then
2026 use_collect2=yes
2027 fi
2028 ;;
2029 mips-*-gnu*)
2030 ;;
2031 mipsel-*-ecoff*)
2032 tm_file=mips/ecoffl.h
2033 if [[ x$stabs = xyes ]]; then
2034 tm_file="${tm_file} dbx.h"
2035 fi
2036 tmake_file=mips/t-ecoff
2037 ;;
2038 mips-*-ecoff*)
2039 tm_file="${tm_file} gofast.h mips/ecoff.h"
2040 if [[ x$stabs = xyes ]]; then
2041 tm_file="${tm_file} dbx.h"
2042 fi
2043 tmake_file=mips/t-ecoff
2044 ;;
2045 mipsel-*-elf*)
2046 tm_file="mips/elfl.h libgloss.h"
2047 tmake_file=mips/t-ecoff
2048 ;;
2049 mips-*-elf*)
2050 tm_file="mips/elf.h libgloss.h"
2051 tmake_file=mips/t-ecoff
2052 ;;
2053 mips64el-*-elf*)
2054 tm_file="mips/elfl64.h libgloss.h"
2055 tmake_file=mips/t-ecoff
2056 ;;
2057 mips64orionel-*-elf*)
2058 tm_file="mips/elforion.h mips/elfl64.h libgloss.h"
2059 tmake_file=mips/t-ecoff
2060 ;;
2061 mips64-*-elf*)
2062 tm_file="mips/elf64.h libgloss.h"
2063 tmake_file=mips/t-ecoff
2064 ;;
2065 mips64orion-*-elf*)
2066 tm_file="mips/elforion.h mips/elf64.h libgloss.h"
2067 tmake_file=mips/t-ecoff
2068 ;;
2069 mips64orion-*-rtems*)
2070 tm_file="mips/elforion.h mips/elfl64.h mips/rtems64.h"
2071 tmake_file="mips/t-ecoff t-rtems"
2072 ;;
2073 mipstx39el-*-elf*)
2074 tm_file="mips/r3900.h mips/elfl.h mips/abi64.h libgloss.h"
2075 tmake_file=mips/t-r3900
2076 ;;
2077 mipstx39-*-elf*)
2078 tm_file="mips/r3900.h mips/elf.h mips/abi64.h libgloss.h"
2079 tmake_file=mips/t-r3900
2080 ;;
2081 mips-*-*) # Default MIPS RISC-OS 4.0.
2082 if [[ x$stabs = xyes ]]; then
2083 tm_file="${tm_file} dbx.h"
2084 fi
2085 if [[ x$gas = xyes ]]
2086 then
2087 tmake_file=mips/t-mips-gas
2088 else
2089 extra_passes="mips-tfile mips-tdump"
2090 fi
2091 if [[ x$gnu_ld != xyes ]]
2092 then
2093 use_collect2=yes
2094 fi
2095 ;;
2096 mn10200-*-*)
2097 cpu_type=mn10200
2098 tm_file="mn10200/mn10200.h"
2099 if [[ x$stabs = xyes ]]
2100 then
2101 tm_file="${tm_file} dbx.h"
2102 fi
2103 use_collect2=no
2104 ;;
2105 mn10300-*-*)
2106 cpu_type=mn10300
2107 tm_file="mn10300/mn10300.h"
2108 if [[ x$stabs = xyes ]]
2109 then
2110 tm_file="${tm_file} dbx.h"
2111 fi
2112 use_collect2=no
2113 ;;
2114 ns32k-encore-bsd*)
2115 tm_file=ns32k/encore.h
2116 use_collect2=yes
2117 ;;
2118 ns32k-sequent-bsd*)
2119 tm_file=ns32k/sequent.h
2120 use_collect2=yes
2121 ;;
2122 ns32k-tek6100-bsd*)
2123 tm_file=ns32k/tek6100.h
2124 use_collect2=yes
2125 ;;
2126 ns32k-tek6200-bsd*)
2127 tm_file=ns32k/tek6200.h
2128 use_collect2=yes
2129 ;;
2130 # This has not been updated to GCC 2.
2131 # ns32k-ns-genix*)
2132 # xm_defines=USG
2133 # xmake_file=ns32k/x-genix
2134 # tm_file=ns32k/genix.h
2135 # use_collect2=yes
2136 # ;;
2137 ns32k-merlin-*)
2138 tm_file=ns32k/merlin.h
2139 use_collect2=yes
2140 ;;
2141 ns32k-pc532-mach*)
2142 tm_file=ns32k/pc532-mach.h
2143 use_collect2=yes
2144 ;;
2145 ns32k-pc532-minix*)
2146 tm_file=ns32k/pc532-min.h
2147 xm_file="ns32k/xm-pc532-min.h ${xm-file}"
2148 xm_defines=USG
2149 use_collect2=yes
2150 ;;
2151 ns32k-pc532-netbsd*)
2152 tm_file=ns32k/netbsd.h
2153 # On NetBSD, the headers are already okay, except for math.h.
2154 fixincludes=fixinc.math
2155 tmake_file=t-netbsd
2156 ;;
2157 pdp11-*-bsd)
2158 tm_file="${tm_file} pdp11/2bsd.h"
2159 ;;
2160 pdp11-*-*)
2161 ;;
2162 pyramid-*-*)
2163 cpu_type=pyr
2164 xmake_file=pyr/x-pyr
2165 use_collect2=yes
2166 ;;
2167 romp-*-aos*)
2168 use_collect2=yes
2169 ;;
2170 romp-*-mach*)
2171 xmake_file=romp/x-mach
2172 use_collect2=yes
2173 ;;
2174 powerpc-*-beos*)
2175 cpu_type=rs6000
2176 tm_file=rs6000/beos.h
2177 xm_file=rs6000/xm-beos.h
2178 tmake_file=rs6000/t-beos
2179 xmake_file=rs6000/x-beos
2180 ;;
2181 powerpc-*-sysv* | powerpc-*-elf*)
2182 tm_file=rs6000/sysv4.h
2183 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2184 xm_defines="USG POSIX"
2185 extra_headers=ppc-asm.h
2186 if [[ x$gas = xyes ]]
2187 then
2188 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2189 else
2190 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2191 fi
2192 xmake_file=rs6000/x-sysv4
2193 ;;
2194 powerpc-*-eabiaix*)
2195 tm_file=rs6000/eabiaix.h
2196 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2197 fixincludes=Makefile.in
2198 extra_headers=ppc-asm.h
2199 ;;
2200 powerpc-*-eabisim*)
2201 tm_file=rs6000/eabisim.h
2202 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2203 fixincludes=Makefile.in
2204 extra_headers=ppc-asm.h
2205 ;;
2206 powerpc-*-eabi*)
2207 tm_file=rs6000/eabi.h
2208 if [[ x$gas = xyes ]]
2209 then
2210 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2211 else
2212 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2213 fi
2214 fixincludes=Makefile.in
2215 extra_headers=ppc-asm.h
2216 ;;
2217 powerpc-*-rtems*)
2218 tm_file=rs6000/rtems.h
2219 if [[ x$gas = xyes ]]
2220 then
2221 tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm"
2222 else
2223 tmake_file="rs6000/t-ppc t-rtems rs6000/t-ppccomm"
2224 fi
2225 fixincludes=Makefile.in
2226 extra_headers=ppc-asm.h
2227 ;;
2228 powerpc-*-linux-gnulibc1)
2229 tm_file=rs6000/linux.h
2230 xm_file=rs6000/xm-sysv4.h
2231 out_file=rs6000/rs6000.c
2232 if [[ x$gas = xyes ]]
2233 then
2234 tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2235 else
2236 tmake_file="rs6000/t-ppc t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2237 fi
2238 xmake_file=x-linux
2239 fixincludes=Makefile.in
2240 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2241 extra_headers=ppc-asm.h
2242 if [[ x$enable_threads = xyes ]]; then
2243 thread_file='posix'
2244 fi
2245 ;;
2246 powerpc-*-linux-gnu*)
2247 tm_file=rs6000/linux.h
2248 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2249 xm_defines="USG ${xm_defines}"
2250 out_file=rs6000/rs6000.c
2251 if [[ x$gas = xyes ]]
2252 then
2253 tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm"
2254 else
2255 tmake_file="rs6000/t-ppc t-linux rs6000/t-ppccomm"
2256 fi
2257 xmake_file=x-linux
2258 fixincludes=Makefile.in
2259 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2260 extra_headers=ppc-asm.h
2261 if [[ x$enable_threads = xyes ]]; then
2262 thread_file='posix'
2263 fi
2264 ;;
2265 powerpc-wrs-vxworks*)
2266 cpu_type=rs6000
2267 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2268 xm_defines="USG POSIX"
2269 tm_file=rs6000/vxppc.h
2270 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2271 extra_headers=ppc-asm.h
2272 thread_file='vxworks'
2273 ;;
2274 powerpcle-*-sysv* | powerpcle-*-elf*)
2275 tm_file=rs6000/sysv4le.h
2276 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2277 xm_defines="USG POSIX"
2278 if [[ x$gas = xyes ]]
2279 then
2280 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2281 else
2282 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2283 fi
2284 xmake_file=rs6000/x-sysv4
2285 extra_headers=ppc-asm.h
2286 ;;
2287 powerpcle-*-eabisim*)
2288 tm_file=rs6000/eabilesim.h
2289 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2290 fixincludes=Makefile.in
2291 extra_headers=ppc-asm.h
2292 ;;
2293 powerpcle-*-eabi*)
2294 tm_file=rs6000/eabile.h
2295 if [[ x$gas = xyes ]]
2296 then
2297 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2298 else
2299 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2300 fi
2301 fixincludes=Makefile.in
2302 extra_headers=ppc-asm.h
2303 ;;
2304 powerpcle-*-winnt* )
2305 tm_file=rs6000/win-nt.h
2306 tmake_file=rs6000/t-winnt
2307 # extra_objs=pe.o
2308 fixincludes=Makefile.in
2309 if [[ x$enable_threads = xyes ]]; then
2310 thread_file='win32'
2311 fi
2312 extra_headers=ppc-asm.h
2313 ;;
2314 powerpcle-*-pe | powerpcle-*-cygwin32)
2315 tm_file=rs6000/cygwin32.h
2316 xm_file="rs6000/xm-cygwin32.h ${xm_file}"
2317 xm_defines=NO_STAB_H
2318 tmake_file=rs6000/t-winnt
2319 xmake_file=rs6000/x-cygwin32
2320 # extra_objs=pe.o
2321 fixincludes=Makefile.in
2322 if [[ x$enable_threads = xyes ]]; then
2323 thread_file='win32'
2324 fi
2325 exeext=.exe
2326 extra_headers=ppc-asm.h
2327 ;;
2328 powerpcle-*-solaris2*)
2329 tm_file=rs6000/sol2.h
2330 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2331 xm_defines="USG POSIX"
2332 if [[ x$gas = xyes ]]
2333 then
2334 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2335 else
2336 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2337 fi
2338 xmake_file=rs6000/x-sysv4
2339 case $machine in
2340 *-*-solaris2.[[0-4]])
2341 fixincludes=fixinc.svr4;;
2342 *)
2343 fixincludes=fixinc.math;;
2344 esac
2345 extra_headers=ppc-asm.h
2346 ;;
2347 rs6000-ibm-aix3.[[01]]*)
2348 tm_file=rs6000/aix31.h
2349 xmake_file=rs6000/x-aix31
2350 use_collect2=yes
2351 ;;
2352 rs6000-ibm-aix3.2.[[456789]]* | powerpc-ibm-aix3.2.[[456789]]*)
2353 tm_file=rs6000/aix3newas.h
2354 if [[ x$host != x$target ]]
2355 then
2356 tmake_file=rs6000/t-xnewas
2357 else
2358 tmake_file=rs6000/t-newas
2359 fi
2360 use_collect2=yes
2361 ;;
2362 rs6000-ibm-aix[[456789]].* | powerpc-ibm-aix[[456789]].*)
2363 tm_file=rs6000/aix41.h
2364 if [[ x$host != x$target ]]
2365 then
2366 tmake_file=rs6000/t-xnewas
2367 else
2368 tmake_file=rs6000/t-newas
2369 fi
2370 xmake_file=rs6000/x-aix31
2371 use_collect2=yes
2372 ;;
2373 rs6000-ibm-aix*)
2374 use_collect2=yes
2375 ;;
2376 rs6000-bull-bosx)
2377 use_collect2=yes
2378 ;;
2379 rs6000-*-mach*)
2380 tm_file=rs6000/mach.h
2381 xm_file="${xm_file} rs6000/xm-mach.h"
2382 xmake_file=rs6000/x-mach
2383 use_collect2=yes
2384 ;;
2385 rs6000-*-lynxos*)
2386 tm_file=rs6000/lynx.h
2387 xm_file=rs6000/xm-lynx.h
2388 tmake_file=rs6000/t-rs6000
2389 xmake_file=rs6000/x-lynx
2390 use_collect2=yes
2391 ;;
2392 sh-*-elf*)
2393 tm_file=sh/elf.h
2394 float_format=sh
2395 ;;
2396 sh-*-rtems*)
2397 tmake_file="sh/t-sh t-rtems"
2398 tm_file=sh/rtems.h
2399 float_format=sh
2400 ;;
2401 sh-*-*)
2402 float_format=sh
2403 ;;
2404 sparc-tti-*)
2405 tm_file=sparc/pbd.h
2406 xm_file="xm-alloca.h ${xm_file}"
2407 xm_defines=USG
2408 ;;
2409 sparc-wrs-vxworks* | sparclite-wrs-vxworks*)
2410 tm_file=sparc/vxsparc.h
2411 tmake_file=sparc/t-vxsparc
2412 use_collect2=yes
2413 thread_file='vxworks'
2414 ;;
2415 sparc-*-aout*)
2416 tmake_file=sparc/t-sparcbare
2417 tm_file="sparc/aout.h libgloss.h"
2418 ;;
2419 sparc-*-netbsd*)
2420 tm_file=sparc/netbsd.h
2421 # On NetBSD, the headers are already okay, except for math.h.
2422 fixincludes=fixinc.math
2423 tmake_file=t-netbsd
2424 ;;
2425 sparc-*-bsd*)
2426 tm_file=sparc/bsd.h
2427 ;;
2428 sparc-*-elf*)
2429 tm_file=sparc/elf.h
2430 tmake_file=sparc/t-elf
2431 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
2432 #float_format=i128
2433 float_format=i64
2434 ;;
2435 sparc-*-linux-gnuaout*) # Sparc's running GNU/Linux, a.out
2436 xm_file="${xm_file} sparc/xm-linux.h"
2437 tm_file=sparc/linux-aout.h
2438 xmake_file=x-linux
2439 fixincludes=Makefile.in #On Linux, the headers are ok already.
2440 gnu_ld=yes
2441 ;;
2442 sparc-*-linux-gnulibc1*) # Sparc's running GNU/Linux, libc5
2443 xm_file="${xm_file} sparc/xm-linux.h"
2444 xmake_file=x-linux
2445 tm_file=sparc/linux.h
2446 tmake_file="t-linux t-linux-gnulibc1"
2447 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2448 fixincludes=Makefile.in #On Linux, the headers are ok already.
2449 gnu_ld=yes
2450 ;;
2451 sparc-*-linux-gnu*) # Sparc's running GNU/Linux, libc6
2452 xm_file="${xm_file} sparc/xm-linux.h"
2453 xmake_file=x-linux
2454 tm_file=sparc/linux.h
2455 tmake_file="t-linux"
2456 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2457 fixincludes=Makefile.in #On Linux, the headers are ok already.
2458 gnu_ld=yes
2459 if [[ x$enable_threads = xyes ]]; then
2460 thread_file='posix'
2461 fi
2462 ;;
2463 sparc-*-lynxos*)
2464 if [[ x$gas = xyes ]]
2465 then
2466 tm_file=sparc/lynx.h
2467 else
2468 tm_file=sparc/lynx-ng.h
2469 fi
2470 xm_file=sparc/xm-lynx.h
2471 tmake_file=sparc/t-sunos41
2472 xmake_file=x-lynx
2473 ;;
2474 sparc-*-rtems*)
2475 tmake_file="sparc/t-sparcbare t-rtems"
2476 tm_file=sparc/rtems.h
2477 ;;
2478 sparc-*-solaris2*)
2479 if [[ x$gnu_ld = xyes ]]
2480 then
2481 tm_file=sparc/sol2.h
2482 else
2483 tm_file=sparc/sol2-sld.h
2484 fi
2485 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
2486 xm_defines="USG POSIX"
2487 tmake_file=sparc/t-sol2
2488 xmake_file=sparc/x-sysv4
2489 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
2490 case $machine in
2491 *-*-solaris2.[[0-4]])
2492 fixincludes=fixinc.svr4;;
2493 *)
2494 fixincludes=fixinc.math;;
2495 esac
2496 float_format=i128
2497 if [[ x${enable_threads} = x ]]; then
2498 enable_threads=$have_pthread_h
2499 if [[ x${enable_threads} = x ]]; then
2500 enable_threads=$have_thread_h
2501 fi
2502 fi
2503 if [[ x${enable_threads} = xyes ]]; then
2504 if [[ x${have_pthread_h} = xyes ]]; then
2505 thread_file='posix'
2506 else
2507 thread_file='solaris'
2508 fi
2509 fi
2510 ;;
2511 sparc-*-sunos4.0*)
2512 tm_file=sparc/sunos4.h
2513 tmake_file=sparc/t-sunos40
2514 use_collect2=yes
2515 ;;
2516 sparc-*-sunos4*)
2517 tm_file=sparc/sunos4.h
2518 tmake_file=sparc/t-sunos41
2519 use_collect2=yes
2520 if [[ x$gas = xyes ]]; then
2521 tm_file="${tm_file} sparc/sun4gas.h"
2522 fi
2523 ;;
2524 sparc-*-sunos3*)
2525 tm_file=sparc/sun4o3.h
2526 use_collect2=yes
2527 ;;
2528 sparc-*-sysv4*)
2529 tm_file=sparc/sysv4.h
2530 xm_file="xm-siglist.h sparc/xm-sysv4.h"
2531 xm_defines="USG POSIX"
2532 tmake_file=t-svr4
2533 xmake_file=sparc/x-sysv4
2534 extra_parts="crtbegin.o crtend.o"
2535 ;;
2536 sparc-*-vxsim*)
2537 xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h"
2538 tm_file=sparc/vxsim.h
2539 tmake_file=sparc/t-vxsparc
2540 xmake_file=sparc/x-sysv4
2541 ;;
2542 sparclet-*-aout*)
2543 tm_file="sparc/splet.h libgloss.h"
2544 tmake_file=sparc/t-splet
2545 ;;
2546 sparclite-*-coff*)
2547 tm_file="sparc/litecoff.h libgloss.h"
2548 tmake_file=sparc/t-sparclite
2549 ;;
2550 sparclite-*-aout*)
2551 tm_file="sparc/lite.h aoutos.h libgloss.h"
2552 tmake_file=sparc/t-sparclite
2553 ;;
2554 sparc64-*-aout*)
2555 tmake_file=sparc/t-sp64
2556 tm_file=sparc/sp64-aout.h
2557 ;;
2558 sparc64-*-elf*)
2559 tmake_file=sparc/t-sp64
2560 tm_file=sparc/sp64-elf.h
2561 extra_parts="crtbegin.o crtend.o"
2562 ;;
2563 sparc64-*-linux*) # 64-bit Sparc's running GNU/Linux
2564 tmake_file=sparc/t-sp64
2565 xm_file="sparc/xm-sp64.h sparc/xm-linux.h"
2566 tm_file=sparc/linux64.h
2567 xmake_file=x-linux
2568 fixincludes=Makefile.in # The headers are ok already.
2569 gnu_ld=yes
2570 ;;
2571 # This hasn't been upgraded to GCC 2.
2572 # tahoe-harris-*) # Harris tahoe, using COFF.
2573 # tm_file=tahoe/harris.h
2574 # ;;
2575 # tahoe-*-bsd*) # tahoe running BSD
2576 # ;;
2577 thumb-*-coff* | thumbel-*-coff*)
2578 tm_file=arm/tcoff.h
2579 out_file=arm/thumb.c
2580 xm_file=arm/xm-thumb.h
2581 md_file=arm/thumb.md
2582 tmake_file=arm/t-thumb
2583 ;;
2584 # This hasn't been upgraded to GCC 2.
2585 # tron-*-*)
2586 # cpu_type=gmicro
2587 # use_collect2=yes
2588 # ;;
2589 v850-*-*)
2590 cpu_type=v850
2591 tm_file="v850/v850.h"
2592 xm_file="v850/xm-v850.h"
2593 if [[ x$stabs = xyes ]]
2594 then
2595 tm_file="${tm_file} dbx.h"
2596 fi
2597 use_collect2=no
2598 ;;
2599 vax-*-bsd*) # vaxen running BSD
2600 use_collect2=yes
2601 float_format=vax
2602 ;;
2603 vax-*-sysv*) # vaxen running system V
2604 tm_file="${tm_file} vax/vaxv.h"
2605 xm_defines=USG
2606 float_format=vax
2607 ;;
2608 vax-*-netbsd*)
2609 tm_file="${tm_file} netbsd.h vax/netbsd.h"
2610 # On NetBSD, the headers are already okay, except for math.h.
2611 fixincludes=fixinc.math
2612 tmake_file=t-netbsd
2613 float_format=vax
2614 ;;
2615 vax-*-ultrix*) # vaxen running ultrix
2616 tm_file="${tm_file} vax/ultrix.h"
2617 use_collect2=yes
2618 float_format=vax
2619 ;;
2620 vax-*-vms*) # vaxen running VMS
2621 xm_file=vax/xm-vms.h
2622 tm_file=vax/vms.h
2623 float_format=vax
2624 ;;
2625 vax-*-*) # vax default entry
2626 float_format=vax
2627 ;;
2628 we32k-att-sysv*)
2629 xm_file="${xm_file} xm-svr3"
2630 use_collect2=yes
2631 ;;
2632 *)
2633 echo "Configuration $machine not supported" 1>&2
2634 exit 1
2635 ;;
2636 esac
2637
2638 case $machine in
2639 *-*-linux-gnu*)
2640 ;; # Existing GNU/Linux systems do not use the GNU setup.
2641 *-*-gnu*)
2642 # On the GNU system, the setup is just about the same on
2643 # each different CPU. The specific machines that GNU
2644 # supports are matched above and just set $cpu_type.
2645 xm_file="xm-gnu.h ${xm_file}"
2646 tm_file=${cpu_type}/gnu.h
2647 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
2648 # GNU always uses ELF.
2649 elf=yes
2650 # GNU tools are the only tools.
2651 gnu_ld=yes
2652 gas=yes
2653 # On GNU, the headers are already okay.
2654 fixincludes=Makefile.in
2655 xmake_file=x-linux # These details are the same as Linux.
2656 tmake_file=t-gnu # These are not.
2657 ;;
2658 *-*-sysv4*)
2659 fixincludes=fixinc.svr4
2660 xmake_try_sysv=x-sysv
2661 install_headers_dir=install-headers-cpio
2662 ;;
2663 *-*-sysv*)
2664 install_headers_dir=install-headers-cpio
2665 ;;
2666 esac
2667
2668 # Distinguish i[34567]86
2669 # Also, do not run mips-tfile on MIPS if using gas.
2670 # Process --with-cpu= for PowerPC/rs6000
2671 target_cpu_default2=
2672 case $machine in
2673 i486-*-*)
2674 target_cpu_default2=1
2675 ;;
2676 i586-*-*)
2677 target_cpu_default2=2
2678 ;;
2679 i686-*-* | i786-*-*)
2680 target_cpu_default2=3
2681 ;;
2682 alpha*-*-*)
2683 case $machine in
2684 alphaev6*)
2685 target_cpu_default2="MASK_CPU_EV6|MASK_BXW|MASK_CIX|MASK_MAX"
2686 ;;
2687 alphapca56*)
2688 target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX"
2689 ;;
2690 alphaev56*)
2691 target_cpu_default2="MASK_CPU_EV5|MASK_BWX"
2692 ;;
2693 alphaev5*)
2694 target_cpu_default2="MASK_CPU_EV5"
2695 ;;
2696 esac
2697
2698 if [[ x$gas = xyes ]]
2699 then
2700 if [[ "$target_cpu_default2" = "" ]]
2701 then
2702 target_cpu_default2="MASK_GAS"
2703 else
2704 target_cpu_default2="${target_cpu_default2}|MASK_GAS"
2705 fi
2706 fi
2707 ;;
2708 arm*-*-*)
2709 case "x$with_cpu" in
2710 x)
2711 # The most generic
2712 target_cpu_default2="TARGET_CPU_generic"
2713 ;;
2714
2715 # Distinguish cores, and major variants
2716 # arm7m doesn't exist, but D & I don't affect code
2717 xarm[23678] | xarm250 | xarm[67][01]0 \
2718 | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \
2719 | xarm7100 | xarm7500 | xarm7500fe | xarm810 \
2720 | xstrongarm | xstrongarm110)
2721 target_cpu_default2="TARGET_CPU_$with_cpu"
2722 ;;
2723
2724 xyes | xno)
2725 echo "--with-cpu must be passed a value" 1>&2
2726 exit 1
2727 ;;
2728
2729 *)
2730 if [[ x$pass2done = xyes ]]
2731 then
2732 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2733 exit 1
2734 fi
2735 ;;
2736 esac
2737 ;;
2738
2739 mips*-*-ecoff* | mips*-*-elf*)
2740 if [[ x$gas = xyes ]]
2741 then
2742 if [[ x$gnu_ld = xyes ]]
2743 then
2744 target_cpu_default2=20
2745 else
2746 target_cpu_default2=16
2747 fi
2748 fi
2749 ;;
2750 mips*-*-*)
2751 if [[ x$gas = xyes ]]
2752 then
2753 target_cpu_default2=16
2754 fi
2755 ;;
2756 powerpc*-*-* | rs6000-*-*)
2757 case "x$with_cpu" in
2758 x)
2759 ;;
2760
2761 xcommon | xpower | xpower2 | xpowerpc | xrios \
2762 | xrios1 | xrios2 | xrsc | xrsc1 \
2763 | x601 | x602 | x603 | x603e | x604 | x604e | x620 \
2764 | x403 | x505 | x801 | x821 | x823 | x860)
2765 target_cpu_default2="\"$with_cpu\""
2766 ;;
2767
2768 xyes | xno)
2769 echo "--with-cpu must be passed a value" 1>&2
2770 exit 1
2771 ;;
2772
2773 *)
2774 if [[ x$pass2done = xyes ]]
2775 then
2776 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2777 exit 1
2778 fi
2779 ;;
2780 esac
2781 ;;
2782 sparc*-*-*)
2783 case ".$with_cpu" in
2784 .)
2785 target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`"
2786 ;;
2787 .supersparc | .ultrasparc | .v7 | .v8 | .v9)
2788 target_cpu_default2="TARGET_CPU_$with_cpu"
2789 ;;
2790 *)
2791 if [[ x$pass2done = xyes ]]
2792 then
2793 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2794 exit 1
2795 fi
2796 ;;
2797 esac
2798 ;;
2799 esac
2800
2801 if [[ "$target_cpu_default2" != "" ]]
2802 then
2803 if [[ "$target_cpu_default" != "" ]]
2804 then
2805 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
2806 else
2807 target_cpu_default=$target_cpu_default2
2808 fi
2809 fi
2810
2811 # No need for collect2 if we have the GNU linker.
2812 case x$gnu_ld in
2813 xyes)
2814 use_collect2=
2815 ;;
2816 esac
2817
2818 # Save data on machine being used to compile GCC in build_xm_file.
2819 # Save data on host machine in vars host_xm_file and host_xmake_file.
2820 if [[ x$pass1done = x ]]
2821 then
2822 if [[ x"$xm_file" = x ]]
2823 then build_xm_file=$cpu_type/xm-$cpu_type.h
2824 else build_xm_file=$xm_file
2825 fi
2826 build_xm_defines=$xm_defines
2827 build_install_headers_dir=$install_headers_dir
2828 build_exeext=$exeext
2829 pass1done=yes
2830 else
2831 if [[ x$pass2done = x ]]
2832 then
2833 if [[ x"$xm_file" = x ]]
2834 then host_xm_file=$cpu_type/xm-$cpu_type.h
2835 else host_xm_file=$xm_file
2836 fi
2837 host_xm_defines=$xm_defines
2838 if [[ x"$xmake_file" = x ]]
2839 then xmake_file=$cpu_type/x-$cpu_type
2840 fi
2841 host_xmake_file="$xmake_file"
2842 host_truncate_target=$truncate_target
2843 host_extra_gcc_objs=$extra_gcc_objs
2844 host_extra_objs=$extra_host_objs
2845 host_exeext=$exeext
2846 pass2done=yes
2847 fi
2848 fi
2849 done
2850
2851 extra_objs="${host_extra_objs} ${extra_objs}"
2852
2853 # Default the target-machine variables that were not explicitly set.
2854 if [[ x"$tm_file" = x ]]
2855 then tm_file=$cpu_type/$cpu_type.h; fi
2856
2857 if [[ x$extra_headers = x ]]
2858 then extra_headers=; fi
2859
2860 if [[ x"$xm_file" = x ]]
2861 then xm_file=$cpu_type/xm-$cpu_type.h; fi
2862
2863 if [[ x$md_file = x ]]
2864 then md_file=$cpu_type/$cpu_type.md; fi
2865
2866 if [[ x$out_file = x ]]
2867 then out_file=$cpu_type/$cpu_type.c; fi
2868
2869 if [[ x"$tmake_file" = x ]]
2870 then tmake_file=$cpu_type/t-$cpu_type
2871 fi
2872
2873 if [[ x$float_format = x ]]
2874 then float_format=i64
2875 fi
2876
2877 if [[ x$enable_haifa = x ]]
2878 then
2879 case $target in
2880 alpha*-* | hppa1.?-* | powerpc*-* | rs6000-*)
2881 enable_haifa=yes;;
2882 esac
2883 fi
2884
2885 # Say what files are being used for the output code and MD file.
2886 echo "Using \`$srcdir/config/$out_file' to output insns."
2887 echo "Using \`$srcdir/config/$md_file' as machine description file."
2888
2889 count=a
2890 for f in $tm_file; do
2891 count=${count}x
2892 done
2893 if [[ $count = ax ]]; then
2894 echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
2895 else
2896 echo "Using the following target machine macro files:"
2897 for f in $tm_file; do
2898 echo " $srcdir/config/$f"
2899 done
2900 fi
2901
2902 count=a
2903 for f in $host_xm_file; do
2904 count=${count}x
2905 done
2906 if [[ $count = ax ]]; then
2907 echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
2908 else
2909 echo "Using the following host machine macro files:"
2910 for f in $host_xm_file; do
2911 echo " $srcdir/config/$f"
2912 done
2913 fi
2914
2915 if [[ "$host_xm_file" != "$build_xm_file" ]]; then
2916 count=a
2917 for f in $build_xm_file; do
2918 count=${count}x
2919 done
2920 if [[ $count = ax ]]; then
2921 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
2922 else
2923 echo "Using the following build machine macro files:"
2924 for f in $build_xm_file; do
2925 echo " $srcdir/config/$f"
2926 done
2927 fi
2928 fi
2929
2930 if [[ x$thread_file = x ]]; then
2931 if [[ x$target_thread_file != x ]]; then
2932 thread_file=$target_thread_file
2933 else
2934 thread_file='single'
2935 fi
2936 fi
2937
2938 # Set up the header files.
2939 # $links is the list of header files to create.
2940 # $vars is the list of shell variables with file names to include.
2941 # auto-conf.h is the file containing items generated by autoconf and is
2942 # the first file included by config.h.
2943 null_defines=
2944 host_xm_file="auto-config.h ${host_xm_file}"
2945
2946 # If host=build, it is correct to have hconfig include auto-conf.h
2947 # as well. If host!=build, we are in error and need to do more
2948 # work to find out the build config parameters.
2949 if [[ x$host = x$build ]]
2950 then
2951 build_xm_file="auto-config.h ${build_xm_file}"
2952 fi
2953
2954 vars="host_xm_file tm_file xm_file build_xm_file"
2955 links="config.h tm.h tconfig.h hconfig.h"
2956 defines="host_xm_defines null_defines xm_defines build_xm_defines"
2957
2958 rm -f config.bak
2959 if [[ -f config.status ]]; then mv -f config.status config.bak; fi
2960
2961 # Make the links.
2962 while [[ -n "$vars" ]]
2963 do
2964 set $vars; var=$1; shift; vars=$*
2965 set $links; link=$1; shift; links=$*
2966 set $defines; define=$1; shift; defines=$*
2967
2968 rm -f $link
2969
2970 # Define TARGET_CPU_DEFAULT if the system wants one.
2971 # This substitutes for lots of *.h files.
2972 if [[ "$target_cpu_default" != "" -a $link = tm.h ]]
2973 then
2974 echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link
2975 fi
2976
2977 for file in `eval echo '$'$var`; do
2978 echo "#include \"$file\"" >>$link
2979 done
2980
2981 for def in `eval echo '$'$define`; do
2982 echo "#ifndef $def" >>$link
2983 echo "#define $def" >>$link
2984 echo "#endif" >>$link
2985 done
2986 done
2987
2988 # Truncate the target if necessary
2989 if [[ x$host_truncate_target != x ]]; then
2990 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
2991 fi
2992
2993 # Get the version number from the toplevel
2994 version=`sed -e 's/.*\"\([[^ \"]]*\)[[ \"]].*/\1/' < ${srcdir}/version.c`
2995
2996 # Get an absolute path to the GCC top-level source directory
2997 holddir=`pwd`
2998 cd $srcdir
2999 topdir=`pwd`
3000 cd $holddir
3001
3002 # Conditionalize the makefile for this host machine.
3003 # Make-host contains the concatenation of all host makefile fragments
3004 # [there can be more than one]. This file is built by configure.frag.
3005 host_overrides=Make-host
3006 dep_host_xmake_file=
3007 for f in .. ${host_xmake_file}
3008 do
3009 if [[ -f ${srcdir}/config/$f ]]
3010 then
3011 dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f"
3012 fi
3013 done
3014
3015 # Conditionalize the makefile for this target machine.
3016 # Make-target contains the concatenation of all host makefile fragments
3017 # [there can be more than one]. This file is built by configure.frag.
3018 target_overrides=Make-target
3019 dep_tmake_file=
3020 for f in .. ${tmake_file}
3021 do
3022 if [[ -f ${srcdir}/config/$f ]]
3023 then
3024 dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f"
3025 fi
3026 done
3027
3028 # If the host doesn't support symlinks, modify CC in
3029 # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works.
3030 # Otherwise, we can use "CC=$(CC)".
3031 rm -f symtest.tem
3032 if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null
3033 then
3034 cc_set_by_configure="\$(CC)"
3035 stage_prefix_set_by_configure="\$(STAGE_PREFIX)"
3036 else
3037 rm -f symtest.tem
3038 if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null
3039 then
3040 symbolic_link="cp -p"
3041 else
3042 symbolic_link="cp"
3043 fi
3044 cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`"
3045 stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`"
3046 fi
3047 rm -f symtest.tem
3048
3049 out_object_file=`basename $out_file .c`.o
3050
3051 tm_file_list=
3052 for f in $tm_file; do
3053 tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
3054 done
3055
3056 host_xm_file_list=
3057 for f in $host_xm_file; do
3058 if test $f != "auto-config.h"; then
3059 host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f"
3060 else
3061 host_xm_file_list="${host_xm_file_list} auto-config.h"
3062 fi
3063 done
3064
3065 build_xm_file_list=
3066 for f in $build_xm_file; do
3067 if test $f != "auto-config.h"; then
3068 build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f"
3069 else
3070 build_xm_file_list="${build_xm_file_list} auto-config.h"
3071 fi
3072 done
3073
3074 # Define macro CROSS_COMPILE in compilation
3075 # if this is a cross-compiler.
3076 # Also use all.cross instead of all.internal
3077 # and add cross-make to Makefile.
3078 cross_overrides="/dev/null"
3079 if [[ x$host != x$target ]]
3080 then
3081 cross_defines="CROSS=-DCROSS_COMPILE"
3082 cross_overrides="${topdir}/cross-make"
3083 fi
3084
3085 # When building gcc with a cross-compiler, we need to fix a few things.
3086 # This must come after cross-make as we want all.build to override
3087 # all.cross.
3088 build_overrides="/dev/null"
3089 if [[ x$build != x$host ]]
3090 then
3091 build_overrides="${topdir}/build-make"
3092 fi
3093
3094 # Expand extra_headers to include complete path.
3095 # This substitutes for lots of t-* files.
3096 extra_headers_list=
3097 if [[ "x$extra_headers" = x ]]
3098 then true
3099 else
3100 # Prepend ${srcdir}/ginclude/ to every entry in extra_headers.
3101 for file in $extra_headers;
3102 do
3103 extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}"
3104 done
3105 fi
3106
3107 # Add a definition of USE_COLLECT2 if system wants one.
3108 # Also tell toplev.c what to do.
3109 # This substitutes for lots of t-* files.
3110 if [[ x$use_collect2 = x ]]
3111 then
3112 will_use_collect2=
3113 maybe_use_collect2=
3114 else
3115 will_use_collect2="collect2"
3116 maybe_use_collect2="-DUSE_COLLECT2"
3117 fi
3118
3119 # NEED TO CONVERT
3120 # Set MD_DEPS if the real md file is in md.pre-cpp.
3121 # Set MD_CPP to the cpp to pass the md file through. Md files use ';'
3122 # for line oriented comments, so we must always use a GNU cpp. If
3123 # building gcc with a cross compiler, use the cross compiler just
3124 # built. Otherwise, we can use the cpp just built.
3125 md_file_sub=
3126 if [[ "x$md_cppflags" = x ]]
3127 then
3128 md_file_sub=$srcdir/config/$md_file
3129 else
3130 md_file=md
3131 fi
3132
3133 # If we have gas in the build tree, make a link to it.
3134 if [[ -f ../gas/Makefile ]]; then
3135 rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null
3136 fi
3137
3138 # If we have ld in the build tree, make a link to it.
3139 if [[ -f ../ld/Makefile ]]; then
3140 # if [[ x$use_collect2 = x ]]; then
3141 # rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null
3142 # else
3143 rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null
3144 # fi
3145 fi
3146
3147 # Figure out what language subdirectories are present.
3148 subdirs=
3149 for lang in ${srcdir}/*/config-lang.in ..
3150 do
3151 case $lang in
3152 ..) ;;
3153 # The odd quoting in the next line works around
3154 # an apparent bug in bash 1.12 on linux.
3155 ${srcdir}/[[*]]/config-lang.in) ;;
3156 *) subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([[^/]]*\)/config-lang.in$,\1,'`" ;;
3157 esac
3158 done
3159
3160 # Make gthr-default.h if we have a thread file.
3161 gthread_flags=
3162 if [[ $thread_file != single ]]; then
3163 rm -f gthr-default.h
3164 echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h
3165 gthread_flags=-DHAVE_GTHR_DEFAULT
3166 fi
3167 AC_SUBST(gthread_flags)
3168
3169 # Make empty files to contain the specs and options for each language.
3170 # Then add #include lines to for a compiler that has specs and/or options.
3171
3172 lang_specs_files=
3173 lang_options_files=
3174 rm -f specs.h options.h
3175 touch specs.h options.h
3176 for subdir in . $subdirs
3177 do
3178 if [[ -f $srcdir/$subdir/lang-specs.h ]]; then
3179 echo "#include \"$subdir/lang-specs.h\"" >>specs.h
3180 lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h"
3181 fi
3182 if [[ -f $srcdir/$subdir/lang-options.h ]]; then
3183 echo "#include \"$subdir/lang-options.h\"" >>options.h
3184 lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h"
3185 fi
3186 done
3187
3188 # These (without "all_") are set in each config-lang.in.
3189 # `language' must be a single word so is spelled singularly.
3190 all_languages=
3191 all_boot_languages=
3192 all_compilers=
3193 all_stagestuff=
3194 all_diff_excludes=
3195 all_outputs=Makefile
3196 # List of language makefile fragments.
3197 all_lang_makefiles=
3198 all_headers=
3199 all_lib2funcs=
3200
3201 # Add the language fragments.
3202 # Languages are added via two mechanisms. Some information must be
3203 # recorded in makefile variables, these are defined in config-lang.in.
3204 # We accumulate them and plug them into the main Makefile.
3205 # The other mechanism is a set of hooks for each of the main targets
3206 # like `clean', `install', etc.
3207
3208 language_fragments="Make-lang"
3209 language_hooks="Make-hooks"
3210 oldstyle_subdirs=
3211
3212 for s in .. $subdirs
3213 do
3214 if [[ $s != ".." ]]
3215 then
3216 language=
3217 boot_language=
3218 compilers=
3219 stagestuff=
3220 diff_excludes=
3221 headers=
3222 outputs=
3223 lib2funcs=
3224 . ${srcdir}/$s/config-lang.in
3225 if [[ "x$language" = x ]]
3226 then
3227 echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2
3228 exit 1
3229 fi
3230 all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in ${srcdir}/$s/Makefile.in"
3231 all_languages="$all_languages $language"
3232 if [[ "x$boot_language" = xyes ]]
3233 then
3234 all_boot_languages="$all_boot_languages $language"
3235 fi
3236 all_compilers="$all_compilers $compilers"
3237 all_stagestuff="$all_stagestuff $stagestuff"
3238 all_diff_excludes="$all_diff_excludes $diff_excludes"
3239 all_headers="$all_headers $headers"
3240 all_outputs="$all_outputs $outputs"
3241 if [[ x$outputs = x ]]
3242 then
3243 oldstyle_subdirs="$oldstyle_subdirs $s"
3244 fi
3245 all_lib2funcs="$all_lib2funcs $lib2funcs"
3246 fi
3247 done
3248
3249 # Since we can't use `::' targets, we link each language in
3250 # with a set of hooks, reached indirectly via lang.${target}.
3251
3252 rm -f Make-hooks
3253 touch Make-hooks
3254 target_list="all.build all.cross start.encap rest.encap \
3255 info dvi \
3256 install-normal install-common install-info install-man \
3257 uninstall distdir \
3258 mostlyclean clean distclean extraclean maintainer-clean \
3259 stage1 stage2 stage3 stage4"
3260 for t in $target_list
3261 do
3262 x=
3263 for l in .. $all_languages
3264 do
3265 if [[ $l != ".." ]]; then
3266 x="$x $l.$t"
3267 fi
3268 done
3269 echo "lang.$t: $x" >> Make-hooks
3270 done
3271
3272 # If we're not building in srcdir, create .gdbinit.
3273
3274 if [[ ! -f Makefile.in ]]; then
3275 echo "dir ." > .gdbinit
3276 echo "dir ${srcdir}" >> .gdbinit
3277 if [[ x$gdb_needs_out_file_path = xyes ]]
3278 then
3279 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
3280 fi
3281 if [[ "x$subdirs" != x ]]; then
3282 for s in $subdirs
3283 do
3284 echo "dir ${srcdir}/$s" >> .gdbinit
3285 done
3286 fi
3287 echo "source ${srcdir}/.gdbinit" >> .gdbinit
3288 fi
3289
3290 # If this is using newlib, then define inhibit_libc in
3291 # LIBGCC2_CFLAGS. This will cause __eprintf to be left out of
3292 # libgcc.a, but that's OK because newib should have its own version of
3293 # assert.h.
3294 inhibit_libc=
3295 if [[ x$with_newlib = xyes ]]; then
3296 inhibit_libc=-Dinhibit_libc
3297 fi
3298 AC_SUBST(inhibit_libc)
3299
3300 # Override SCHED_OBJ and SCHED_CFLAGS to enable the Haifa scheduler.
3301 sched_prefix=
3302 sched_cflags=
3303 if [[ x$enable_haifa = xyes ]]; then
3304 echo "Using the Haifa scheduler."
3305 sched_prefix=haifa-
3306 sched_cflags=-DHAIFA
3307 fi
3308 AC_SUBST(sched_prefix)
3309 AC_SUBST(sched_cflags)
3310 if [[ x$enable_haifa != x ]]; then
3311 # Explicitly remove files that need to be recompiled for the Haifa scheduler.
3312 for x in genattrtab.o toplev.o loop.o unroll.o *sched.o; do
3313 if [[ -f $x ]]; then
3314 echo "Removing $x"
3315 rm -f $x
3316 fi
3317 done
3318 fi
3319
3320 # Process the language and host/target makefile fragments.
3321 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
3322
3323 # Substitute configuration variables
3324 AC_SUBST(subdirs)
3325 AC_SUBST(all_languages)
3326 AC_SUBST(all_boot_languages)
3327 AC_SUBST(all_compilers)
3328 AC_SUBST(all_lang_makefiles)
3329 AC_SUBST(all_stagestuff)
3330 AC_SUBST(all_diff_excludes)
3331 AC_SUBST(all_lib2funcs)
3332 AC_SUBST(all_headers)
3333 AC_SUBST(extra_passes)
3334 AC_SUBST(extra_programs)
3335 AC_SUBST(extra_parts)
3336 AC_SUBST(extra_c_objs)
3337 AC_SUBST(extra_c_flags)
3338 AC_SUBST(extra_objs)
3339 AC_SUBST(host_extra_gcc_objs)
3340 AC_SUBST(extra_headers_list)
3341 AC_SUBST(dep_host_xmake_file)
3342 AC_SUBST(dep_tmake_file)
3343 AC_SUBST(out_file)
3344 AC_SUBST(out_object_file)
3345 AC_SUBST(md_file)
3346 AC_SUBST(tm_file_list)
3347 AC_SUBST(build_xm_file_list)
3348 AC_SUBST(host_xm_file_list)
3349 AC_SUBST(lang_specs_files)
3350 AC_SUBST(lang_options_files)
3351 AC_SUBST(thread_file)
3352 AC_SUBST(version)
3353 AC_SUBST(local_prefix)
3354 AC_SUBST(gxx_include_dir)
3355 AC_SUBST(fixincludes)
3356 AC_SUBST(build_install_headers_dir)
3357 AC_SUBST(build_exeext)
3358 AC_SUBST(host_exeext)
3359 AC_SUBST(float_format)
3360 AC_SUBST(will_use_collect2)
3361 AC_SUBST(maybe_use_collect2)
3362 AC_SUBST(cc_set_by_configure)
3363 AC_SUBST(stage_prefix_set_by_configure)
3364 AC_SUBST(install)
3365 AC_SUBST(symbolic_link)
3366
3367 AC_SUBST_FILE(target_overrides)
3368 AC_SUBST_FILE(host_overrides)
3369 AC_SUBST(cross_defines)
3370 AC_SUBST_FILE(cross_overrides)
3371 AC_SUBST_FILE(build_overrides)
3372 AC_SUBST_FILE(language_fragments)
3373 AC_SUBST_FILE(language_hooks)
3374
3375 # Echo that links are built
3376 if [[ x$host = x$target ]]
3377 then
3378 str1="native "
3379 else
3380 str1="cross-"
3381 str2=" from $host"
3382 fi
3383
3384 if [[ x$host != x$build ]]
3385 then
3386 str3=" on a $build system"
3387 fi
3388
3389 if [[ "x$str2" != x ]] || [[ "x$str3" != x ]]
3390 then
3391 str4=
3392 fi
3393
3394 echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2
3395
3396 if [[ "x$str2" != x ]] || [[ "x$str3" != x ]]
3397 then
3398 echo " ${str2}${str3}." 1>&2
3399 fi
3400
3401 # Truncate the target if necessary
3402 if [[ x$host_truncate_target != x ]]; then
3403 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
3404 fi
3405
3406 # Configure the subdirectories
3407 # AC_CONFIG_SUBDIRS($subdirs)
3408
3409 # Create the Makefile
3410 # and configure language subdirectories
3411 AC_OUTPUT($all_outputs,
3412 [
3413 . $srcdir/configure.lang
3414 case x$CONFIG_HEADERS in
3415 xauto-config.h:config.in)
3416 echo > cstamp-h ;;
3417 esac
3418 # If the host supports symlinks, point stage[1234] at ../stage[1234] so
3419 # bootstrapping and the installation procedure can still use
3420 # CC="stage1/xgcc -Bstage1/". If the host doesn't support symlinks,
3421 # FLAGS_TO_PASS has been modified to solve the problem there.
3422 # This is virtually a duplicate of what happens in configure.lang; we do
3423 # an extra check to make sure this only happens if ln -s can be used.
3424 if [[ "$symbolic_link" = "ln -s" ]]; then
3425 for d in .. ${subdirs} ; do
3426 if [[ $d != .. ]]; then
3427 STARTDIR=`pwd`
3428 cd $d
3429 for t in stage1 stage2 stage3 stage4 include
3430 do
3431 rm -f $t
3432 $symbolic_link ../$t $t 2>/dev/null
3433 done
3434 cd $STARTDIR
3435 fi
3436 done
3437 else true ; fi
3438 ],
3439 [
3440 host='${host}'
3441 build='${build}'
3442 target='${target}'
3443 target_alias='${target_alias}'
3444 srcdir='${srcdir}'
3445 subdirs='${subdirs}'
3446 oldstyle_subdirs='${oldstyle_subdirs}'
3447 symbolic_link='${symbolic_link}'
3448 program_transform_set='${program_transform_set}'
3449 program_transform_name='${program_transform_name}'
3450 dep_host_xmake_file='${dep_host_xmake_file}'
3451 host_xmake_file='${host_xmake_file}'
3452 dep_tmake_file='${dep_tmake_file}'
3453 tmake_file='${tmake_file}'
3454 thread_file='${thread_file}'
3455 version='${version}'
3456 local_prefix='${local_prefix}'
3457 build_install_headers_dir='${build_install_headers_dir}'
3458 build_exeext='${build_exeext}'
3459 host_exeext='${host_exeext}'
3460 out_file='${out_file}'
3461 gdb_needs_out_file_path='${gdb_needs_out_file_path}'
3462 SET_MAKE='${SET_MAKE}'
3463 target_list='${target_list}'
3464 target_overrides='${target_overrides}'
3465 host_overrides='${host_overrides}'
3466 cross_defines='${cross_defines}'
3467 cross_overrides='${cross_overrides}'
3468 build_overrides='${build_overrides}'
3469 ])
This page took 0.188681 seconds and 6 git commands to generate.