1 # configure.in for GNU CC
2 # Process this file with autoconf to generate a configuration script.
4 # Copyright (C) 1997, 1998 Free Software Foundation, Inc.
6 #This file is part of GNU CC.
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)
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.
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.
23 # Initialization and defaults
26 AC_CONFIG_HEADER(auto-host.h:config.in)
33 # Check for bogus environment variables.
34 # Test if LIBRARY_PATH contains the notation for the current directory
35 # since this would lead to problems installing/building glibc.
36 # LIBRARY_PATH contains the current directory if one of the following
38 # - one of the terminals (":" and ";") is the first or last sign
39 # - two terminals occur directly after each other
40 # - the path contains an element with a dot in it
41 AC_MSG_CHECKING(LIBRARY_PATH variable)
43 case ${LIBRARY_PATH} in
44 [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
45 library_path_setting="contains current directory"
48 library_path_setting="ok"
52 AC_MSG_RESULT($library_path_setting)
53 if test "$library_path_setting" != "ok"; then
55 *** LIBRARY_PATH shouldn't contain the current directory when
56 *** building egcs. Please change the environment variable
57 *** and run configure again.])
60 # Test if GCC_EXEC_PREFIX contains the notation for the current directory
61 # since this would lead to problems installing/building glibc.
62 # GCC_EXEC_PREFIX contains the current directory if one of the following
64 # - one of the terminals (":" and ";") is the first or last sign
65 # - two terminals occur directly after each other
66 # - the path contains an element with a dot in it
67 AC_MSG_CHECKING(GCC_EXEC_PREFIX variable)
69 case ${GCC_EXEC_PREFIX} in
70 [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
71 gcc_exec_prefix_setting="contains current directory"
74 gcc_exec_prefix_setting="ok"
78 AC_MSG_RESULT($gcc_exec_prefix_setting)
79 if test "$gcc_exec_prefix_setting" != "ok"; then
81 *** GCC_EXEC_PREFIX shouldn't contain the current directory when
82 *** building egcs. Please change the environment variable
83 *** and run configure again.])
86 # Check for additional parameters
90 [ --with-gnu-ld arrange to work with GNU ld.],
91 gnu_ld_flag="$with_gnu_ld",
96 [ --with-ld arrange to use the specified ld (full pathname).],
97 DEFAULT_LINKER="$with_ld")
98 if test x"${DEFAULT_LINKER+set}" = x"set"; then
99 if test ! -x "$DEFAULT_LINKER"; then
100 AC_MSG_WARN([cannot execute: $DEFAULT_LINKER: check --with-ld or env. var. DEFAULT_LINKER])
101 elif test "GNU" = `$DEFAULT_LINKER -v </dev/null 2>&1 | sed '1s/^GNU.*/GNU/;q'`; then
104 AC_DEFINE_UNQUOTED(DEFAULT_LINKER,"$DEFAULT_LINKER")
109 [ --with-gnu-as arrange to work with GNU as.],
110 gas_flag="$with_gnu_as",
114 [ --with-as arrange to use the specified as (full pathname).],
115 DEFAULT_ASSEMBLER="$with_as")
116 if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then
117 if test ! -x "$DEFAULT_ASSEMBLER"; then
118 AC_MSG_WARN([cannot execute: $DEFAULT_ASSEMBLER: check --with-as or env. var. DEFAULT_ASSEMBLER])
119 elif test "GNU" = `$DEFAULT_ASSEMBLER -v </dev/null 2>&1 | sed '1s/^GNU.*/GNU/;q'`; then
122 AC_DEFINE_UNQUOTED(DEFAULT_ASSEMBLER,"$DEFAULT_ASSEMBLER")
127 [ --with-stabs arrange to use stabs instead of host debug format.],
133 [ --with-elf arrange to use ELF instead of host debug format.],
137 # Specify the local prefix
139 AC_ARG_WITH(local-prefix,
140 [ --with-local-prefix=DIR specifies directory to put local include.],
141 [case "${withval}" in
142 yes) AC_MSG_ERROR(bad value ${withval} given for local include directory prefix) ;;
144 *) local_prefix=$with_local_prefix ;;
147 # Default local prefix if it is empty
148 if test x$local_prefix = x; then
149 local_prefix=/usr/local
153 # Specify the g++ header file directory
154 AC_ARG_WITH(gxx-include-dir,
155 [ --with-gxx-include-dir=DIR
156 specifies directory to put g++ header files.],
157 [case "${withval}" in
158 yes) AC_MSG_ERROR(bad value ${withval} given for g++ include directory) ;;
160 *) gxx_include_dir=$with_gxx_include_dir ;;
163 if test x${gxx_include_dir} = x; then
164 if test x${enable_version_specific_runtime_libs} = xyes; then
165 gxx_include_dir='${libsubdir}/include/g++'
167 topsrcdir=${srcdir}/.. . ${srcdir}/../config.if
168 changequote(<<, >>)dnl
169 gxx_include_dir="\$(libsubdir)/\$(unlibsubdir)/..\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/[^/]*|/..|g'\`/include/g++"-${libstdcxx_interface}
174 # Enable expensive internal checks
175 AC_ARG_ENABLE(checking,
176 [ --enable-checking enable expensive run-time checks.],
177 [case "${enableval}" in
178 yes) AC_DEFINE(ENABLE_CHECKING) ;;
180 *) AC_MSG_ERROR(bad value ${enableval} given for checking option) ;;
183 # Use cpplib+cppmain for the preprocessor, but don't link it with the compiler.
185 AC_ARG_ENABLE(cpplib,
186 [ --enable-cpplib use cpplib for the C preprocessor.],
187 if test x$enable_cpplib != xno; then
191 # Link cpplib into the compiler proper, for C/C++/ObjC.
192 AC_ARG_ENABLE(c-cpplib,
193 [ --enable-c-cpplib link cpplib directly into C and C++ compilers
194 (implies --enable-cpplib).],
195 if test x$enable_c_cpplib != xno; then
196 extra_c_objs="${extra_c_objs} libcpp.a"
197 extra_cxx_objs="${extra_cxx_objs} ../libcpp.a"
198 extra_c_flags=-DUSE_CPPLIB=1
202 # Enable Multibyte Characters for C/C++
203 AC_ARG_ENABLE(c-mbchar,
204 [ --enable-c-mbchar enable multibyte characters for C and C++.],
205 if test x$enable_c_mbchar != xno; then
206 extra_c_flags=-DMULTIBYTE_CHARS=1
209 # Enable Haifa scheduler.
211 [ --enable-haifa use the experimental scheduler.
212 --disable-haifa don't use the experimental scheduler for the
213 targets which normally enable it.])
216 # This is a work in progress...
217 AC_ARG_WITH(fast-fixincludes,
218 [ --with-fast-fixincludes use a faster fixinclude program (experimental)],
219 fast_fixinc="$with_fast_fixincludes",
222 # Enable init_priority.
223 AC_ARG_ENABLE(init-priority,
224 [ --enable-init-priority use attributes to assign initialization order
226 --disable-init-priority conform to ISO C++ rules for ordering static objects
227 (i.e. initialized in order of declaration). ],
228 if test x$enable_init_priority != xno; then
229 extra_c_flags=-DUSE_INIT_PRIORITY
233 # Pass with no value to take the default
234 # Pass with a value to specify a thread package
235 AC_ARG_ENABLE(threads,
236 [ --enable-threads enable thread usage for target GCC.
237 --enable-threads=LIB use LIB thread package for target GCC.],
238 if test x$enable_threads = xno; then
243 enable_threads_flag=$enable_threads
244 # Check if a valid thread package
245 case x${enable_threads_flag} in
248 target_thread_file='single'
252 target_thread_file=''
254 xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \
255 xsolaris | xwin32 | xdce | xvxworks)
256 target_thread_file=$enable_threads_flag
259 echo "$enable_threads is an unknown thread package" 1>&2
264 AC_ARG_ENABLE(objc-gc,
265 [ --enable-objc-gc enable the use of Boehm's garbage collector with
266 the GNU Objective-C runtime.],
267 if [[[ x$enable_objc_gc = xno ]]]; then
274 AC_ARG_ENABLE(java-gc,
275 changequote(<<,>>)dnl
276 << --enable-java-gc=TYPE choose garbage collector [boehm]>>,
281 # Determine the host, build, and target systems
284 # Find the native compiler
287 # If the native compiler is GCC, we can enable warnings even in stage1.
288 # That's useful for people building cross-compilers, or just running a
290 if test "x$GCC" = "xyes"; then
291 stage1_warn_cflags='$(WARN_CFLAGS)'
293 stage1_warn_cflags=""
295 AC_SUBST(stage1_warn_cflags)
299 AC_MSG_CHECKING([whether a default assembler was specified])
300 if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then
301 if test x"$with_gas" = x"no"; then
302 AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER)])
304 AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER - GNU as)])
310 AC_MSG_CHECKING([whether a default linker was specified])
311 if test x"${DEFAULT_LINKER+set}" = x"set"; then
312 if test x"$with_gnu_ld" = x"no"; then
313 AC_MSG_RESULT([yes ($DEFAULT_LINKER)])
315 AC_MSG_RESULT([yes ($DEFAULT_LINKER - GNU ld)])
321 # Find some useful tools
335 AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h fcntl.h unistd.h stab.h sys/file.h sys/time.h sys/resource.h sys/param.h sys/times.h sys/stat.h)
337 # Check for thread headers.
338 AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=])
339 AC_CHECK_HEADER(pthread.h, [have_pthread_h=yes], [have_pthread_h=])
341 # See if GNAT has been installed
342 AC_CHECK_PROG(gnat, gnatbind, yes, no)
344 # See if the system preprocessor understands the ANSI C preprocessor
345 # stringification operator.
346 AC_MSG_CHECKING(whether cpp understands the stringify operator)
347 AC_CACHE_VAL(gcc_cv_c_have_stringify,
350 char *test = S(foo);],
351 gcc_cv_c_have_stringify=yes, gcc_cv_c_have_stringify=no)])
352 AC_MSG_RESULT($gcc_cv_c_have_stringify)
353 if test $gcc_cv_c_have_stringify = yes; then
354 AC_DEFINE(HAVE_CPP_STRINGIFY)
357 # Use <inttypes.h> only if it exists,
358 # doesn't clash with <sys/types.h>, and declares intmax_t.
359 AC_MSG_CHECKING(for inttypes.h)
360 AC_CACHE_VAL(gcc_cv_header_inttypes_h,
362 [#include <sys/types.h>
363 #include <inttypes.h>],
365 [gcc_cv_header_inttypes_h=yes],
366 gcc_cv_header_inttypes_h=no)])
367 AC_MSG_RESULT($gcc_cv_header_inttypes_h)
368 if test $gcc_cv_header_inttypes_h = yes; then
369 AC_DEFINE(HAVE_INTTYPES_H)
372 AC_CHECK_FUNCS(strtoul bsearch strerror putenv popen bcopy bzero bcmp \
373 index rindex strchr strrchr kill getrlimit setrlimit atoll atoq \
374 sysconf isascii gettimeofday strsignal)
376 # Make sure wchar_t is available
377 #AC_CHECK_TYPE(wchar_t, unsigned int)
379 GCC_FUNC_VFPRINTF_DOPRNT
383 GCC_NEED_DECLARATIONS(malloc realloc calloc free bcopy bzero bcmp \
384 index rindex getenv atol sbrk abort atof strerror getcwd getwd \
387 GCC_NEED_DECLARATIONS(getrlimit setrlimit, [
388 #include <sys/types.h>
389 #ifdef HAVE_SYS_RESOURCE_H
390 #include <sys/resource.h>
404 build_install_headers_dir=install-headers-tar
409 host_truncate_target=
412 # Decode the host machine, then the target machine.
413 # For the host machine, we save the xm_file variable as host_xm_file;
414 # then we decode the target machine and forget everything else
415 # that came from the host machine.
416 for machine in $build $host $target; do
430 # Set this to force installation and use of collect2.
432 # Set this to override the default target model.
434 # Set this to control which fixincludes program to use.
435 if test x$fast_fixinc != xyes; then
436 fixincludes=fixincludes
437 else fixincludes=fixinc.sh ; fi
438 # Set this to control how the header file directory is installed.
439 install_headers_dir=install-headers-tar
440 # Set this to a non-empty list of args to pass to cpp if the target
441 # wants its .md file passed through cpp.
443 # Set this if directory names should be truncated to 14 characters.
445 # Set this if gdb needs a dir command with `dirname $out_file`
446 gdb_needs_out_file_path=
447 # Set this if the build machine requires executables to have a
450 # Set this to control which thread package will be used.
452 # Reinitialize these from the flag values every loop pass, since some
453 # configure entries modify them.
455 gnu_ld="$gnu_ld_flag"
456 enable_threads=$enable_threads_flag
458 # Set default cpu_type, tm_file and xm_file so it can be updated in
459 # each machine entry.
460 cpu_type=`echo $machine | sed 's/-.*$//'`
496 tm_file=${cpu_type}/${cpu_type}.h
497 xm_file=${cpu_type}/xm-${cpu_type}.h
499 # Set the default macros to define for GNU/Linux systems.
502 xm_defines="HAVE_ATEXIT POSIX BSTRING"
507 # Support site-specific machine types.
509 cpu_type=`echo $machine | sed -e 's/-.*//'`
510 rest=`echo $machine | sed -e "s/$cpu_type-//"`
511 xm_file=${cpu_type}/xm-$rest.h
512 tm_file=${cpu_type}/$rest.h
513 if test -f $srcdir/config/${cpu_type}/x-$rest; \
514 then xmake_file=${cpu_type}/x-$rest; \
517 if test -f $srcdir/config/${cpu_type}/t-$rest; \
518 then tmake_file=${cpu_type}/t-$rest; \
524 a29k-*-bsd* | a29k-*-sym1*)
525 tm_file="${tm_file} a29k/unix.h"
527 xmake_file=a29k/x-unix
530 a29k-*-udi | a29k-*-coff)
531 tm_file="${tm_file} dbxcoff.h a29k/udi.h"
532 tmake_file=a29k/t-a29kbare
535 tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h"
536 tmake_file=a29k/t-vx29k
537 extra_parts="crtbegin.o crtend.o"
538 thread_file='vxworks'
540 a29k-*-*) # Default a29k environment.
543 alpha*-*-linux-gnuecoff*)
544 tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h"
545 target_cpu_default="MASK_GAS"
550 alpha*-*-linux-gnulibc1*)
551 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
552 target_cpu_default="MASK_GAS"
553 tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux alpha/t-crtbe"
554 extra_parts="crtbegin.o crtend.o"
555 fixincludes=fixinc.wrap
558 if test x$enable_threads = xyes; then
563 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
564 target_cpu_default="MASK_GAS"
565 tmake_file="t-linux alpha/t-linux alpha/t-crtbe"
566 extra_parts="crtbegin.o crtend.o"
568 fixincludes=Makefile.in
570 if test x$enable_threads = xyes; then
575 tm_file="${tm_file} alpha/elf.h alpha/netbsd.h alpha/netbsd-elf.h"
576 target_cpu_default="MASK_GAS"
577 tmake_file="alpha/t-crtbe"
578 extra_parts="crtbegin.o crtend.o"
580 fixincludes=fixinc.wrap
585 if test x$stabs = xyes
587 tm_file="${tm_file} dbx.h"
589 if test x$gas != xyes
591 extra_passes="mips-tfile mips-tdump"
596 tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h"
601 tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h"
604 tm_file="${tm_file} alpha/osf.h"
605 # Some versions of OSF4 (specifically X4.0-9 296.7) have
606 # a broken tar, so we use cpio instead.
607 install_headers_dir=install-headers-cpio
612 *-*-osf4.0[b-z] | *-*-osf4.[1-9]*)
614 target_cpu_default=MASK_SUPPORT_ARCH
619 tm_file="${tm_file} dbx.h alpha/vxworks.h"
622 extra_passes="mips-tfile mips-tdump"
627 tm_file="${tm_file} alpha/win-nt.h"
628 xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h"
630 xmake_file=winnt/x-winnt
631 extra_host_objs=oldnames.o
632 extra_gcc_objs="spawnv.o oldnames.o"
633 fixincludes=fixinc.winnt
634 if test x$gnu_ld != xyes
636 extra_programs=ld.exe
638 if test x$enable_threads = xyes; then
644 xm_file="${xm_file} alpha/xm-vms.h"
645 tmake_file=alpha/t-vms
646 fixincludes=Makefile.in
649 extra_parts="crtinit.o crtfini.o"
651 arm-*-coff* | armel-*-coff*)
653 tmake_file=arm/t-bare
656 arm-*-riscix1.[01]*) # Acorn RISC machine (early versions)
658 tm_file=arm/riscix1-1.h
661 arm-*-riscix*) # Acorn RISC machine
664 tm_file=arm/rix-gas.h
668 xmake_file=arm/x-riscix
669 tmake_file=arm/t-riscix
672 arm-semi-aout | armel-semi-aout)
674 tmake_file=arm/t-semi
675 fixincludes=Makefile.in # There is nothing to fix
677 arm-semi-aof | armel-semi-aof)
678 tm_file=arm/semiaof.h
679 tmake_file=arm/t-semiaof
680 fixincludes=Makefile.in # There is nothing to fix
684 xm_file="arm/xm-netbsd.h ${xm_file}"
685 tmake_file="t-netbsd arm/t-netbsd"
686 # On NetBSD, the headers are already okay, except for math.h.
687 fixincludes=fixinc.wrap
689 arm*-*-linux-gnuaout*) # ARM GNU/Linux with a.out
692 tm_file=arm/linux-aout.h
693 tmake_file=arm/t-linux
694 fixincludes=Makefile.in
697 arm*-*-linux-gnu*) # ARM GNU/Linux with ELF
698 xm_file=arm/xm-linux.h
702 tm_file=arm/linux-elf26.h
705 tm_file=arm/linux-elf.h
708 tmake_file="t-linux arm/t-linux"
709 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
710 fixincludes=Makefile.in # Nothing to fix
715 tmake_file=arm/t-bare
718 tm_file=arm/unknown-elf.h
719 tmake_file=arm/t-arm-elf
721 c1-convex-*) # Convex C1
724 fixincludes=Makefile.in
726 c2-convex-*) # Convex C2
729 fixincludes=Makefile.in
734 fixincludes=Makefile.in
739 fixincludes=Makefile.in
742 target_cpu_default=16
744 fixincludes=Makefile.in
750 clipper-intergraph-clix*)
751 tm_file="${tm_file} svr3.h clipper/clix.h"
752 xm_file=clipper/xm-clix.h
753 xmake_file=clipper/x-clix
754 extra_headers=va-clipper.h
755 extra_parts="crtbegin.o crtend.o"
756 install_headers_dir=install-headers-cpio
763 # This hasn't been upgraded to GCC 2.
764 # fx80-alliant-*) # Alliant FX/80
770 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
771 xm_file=pa/xm-papro.h
776 tm_file="${tm_file} pa/pa-osf.h"
778 fixincludes=Makefile.in
781 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h pa/rtems.h"
782 xm_file=pa/xm-papro.h
786 tm_file="${tm_file} pa/pa-osf.h"
788 fixincludes=Makefile.in
793 fixincludes=Makefile.in
797 fixincludes=Makefile.in
800 tm_file="pa/pa-oldas.h ${tm_file} pa/pa-hpux7.h"
801 xm_file=pa/xm-pahpux.h
802 xmake_file=pa/x-pa-hpux
805 tm_file="${tm_file} pa/gas.h"
807 install_headers_dir=install-headers-cpio
811 hppa1.0-*-hpux8.0[0-2]*)
813 tm_file="${tm_file} pa/pa-hpux.h"
814 xm_file=pa/xm-pahpux.h
815 xmake_file=pa/x-pa-hpux
818 tm_file="${tm_file} pa/pa-gas.h"
820 tm_file="pa/pa-oldas.h ${tm_file}"
822 install_headers_dir=install-headers-cpio
826 hppa1.1-*-hpux8.0[0-2]*)
829 tm_file="${tm_file} pa/pa-hpux.h"
830 xm_file=pa/xm-pahpux.h
831 xmake_file=pa/x-pa-hpux
834 tm_file="${tm_file} pa/pa-gas.h"
836 tm_file="pa/pa-oldas.h ${tm_file}"
838 install_headers_dir=install-headers-cpio
843 tm_file="${tm_file} pa/pa-hpux.h"
844 xm_file=pa/xm-pahpux.h
845 xmake_file=pa/x-pa-hpux
848 tm_file="${tm_file} pa/pa-gas.h"
850 install_headers_dir=install-headers-cpio
854 tm_file="${tm_file} pa/pa-hpux.h"
855 xm_file=pa/xm-pahpux.h
856 xmake_file=pa/x-pa-hpux
859 tm_file="${tm_file} pa/pa-gas.h"
861 install_headers_dir=install-headers-cpio
864 hppa1.1-*-hpux10* | hppa2*-*-hpux10*)
866 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
867 xm_file=pa/xm-pahpux.h
868 xmake_file=pa/x-pa-hpux
872 tm_file="${tm_file} pa/pa-gas.h"
874 if test x$enable_threads = x; then
875 enable_threads=$have_pthread_h
877 if test x$enable_threads = xyes; then
879 tmake_file="${tmake_file} pa/t-dce-thr"
881 install_headers_dir=install-headers-cpio
885 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
886 xm_file=pa/xm-pahpux.h
887 xmake_file=pa/x-pa-hpux
890 tm_file="${tm_file} pa/pa-gas.h"
892 if test x$enable_threads = x; then
893 enable_threads=$have_pthread_h
895 if test x$enable_threads = xyes; then
897 tmake_file="${tmake_file} pa/t-dce-thr"
899 install_headers_dir=install-headers-cpio
902 hppa1.1-*-hpux* | hppa2*-*-hpux*)
904 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
905 xm_file=pa/xm-pahpux.h
906 xmake_file=pa/x-pa-hpux
909 tm_file="${tm_file} pa/pa-gas.h"
911 install_headers_dir=install-headers-cpio
915 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
916 xm_file=pa/xm-pahpux.h
917 xmake_file=pa/x-pa-hpux
920 tm_file="${tm_file} pa/pa-gas.h"
922 install_headers_dir=install-headers-cpio
925 hppa1.1-*-hiux* | hppa2*-*-hiux*)
927 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
928 xm_file=pa/xm-pahpux.h
929 xmake_file=pa/x-pa-hpux
932 tm_file="${tm_file} pa/pa-gas.h"
934 install_headers_dir=install-headers-cpio
938 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
939 xm_file=pa/xm-pahpux.h
940 xmake_file=pa/x-pa-hpux
943 tm_file="${tm_file} pa/pa-gas.h"
945 install_headers_dir=install-headers-cpio
951 fixincludes=Makefile.in
956 i[34567]86-ibm-aix*) # IBM PS/2 running AIX
960 tm_file=i386/aix386.h
961 extra_parts="crtbegin.o crtend.o"
962 tmake_file=i386/t-crtstuff
964 tm_file=i386/aix386ng.h
967 xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
969 xmake_file=i386/x-aix
972 i[34567]86-ncr-sysv4*) # NCR 3000 - ix86 running system V.4
974 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
975 xm_defines="USG POSIX SMALL_ARG_MAX"
976 xmake_file=i386/x-ncr3000
977 if test x$stabs = xyes -a x$gas = xyes
979 tm_file=i386/sysv4gdb.h
983 extra_parts="crtbegin.o crtend.o"
984 tmake_file=i386/t-crtpic
990 xm_file=i386/xm-next.h
991 tmake_file=i386/t-next
992 xmake_file=i386/x-next
993 extra_objs=nextstep.o
994 extra_parts="crtbegin.o crtend.o"
995 if test x$enable_threads = xyes; then
1000 i[34567]86-sequent-bsd*) # 80386 from Sequent
1003 if test x$gas = xyes
1005 tm_file=i386/seq-gas.h
1007 tm_file=i386/sequent.h
1011 i[34567]86-sequent-ptx1*)
1013 xm_defines="USG SVR3"
1014 xmake_file=i386/x-sysv3
1015 tm_file=i386/seq-sysv3.h
1016 tmake_file=i386/t-crtstuff
1017 fixincludes=fixinc.ptx
1018 extra_parts="crtbegin.o crtend.o"
1019 install_headers_dir=install-headers-cpio
1022 i[34567]86-sequent-ptx2* | i[34567]86-sequent-sysv3*)
1024 xm_defines="USG SVR3"
1025 xmake_file=i386/x-sysv3
1026 tm_file=i386/seq2-sysv3.h
1027 tmake_file=i386/t-crtstuff
1028 extra_parts="crtbegin.o crtend.o"
1029 fixincludes=fixinc.ptx
1030 install_headers_dir=install-headers-cpio
1033 i[34567]86-sequent-ptx4* | i[34567]86-sequent-sysv4*)
1035 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1036 xm_defines="USG POSIX SMALL_ARG_MAX"
1038 tm_file=i386/ptx4-i.h
1040 extra_parts="crtbegin.o crtend.o"
1041 fixincludes=fixinc.ptx
1042 install_headers_dir=install-headers-cpio
1044 i386-sun-sunos*) # Sun i386 roadrunner
1050 i[34567]86-wrs-vxworks*)
1052 tm_file=i386/vxi386.h
1053 tmake_file=i386/t-i386bare
1058 tm_file=i386/i386-aout.h
1059 tmake_file=i386/t-i386bare
1062 i[34567]86-*-bsdi* | i[34567]86-*-bsd386*)
1064 tm_file=i386/bsd386.h
1065 # tmake_file=t-libc-ok
1070 tm_file=i386/386bsd.h
1071 # tmake_file=t-libc-ok
1072 # Next line turned off because both 386BSD and BSD/386 use GNU ld.
1076 i[34567]86-*-freebsdelf*)
1078 tm_file="i386/i386.h i386/att.h linux.h i386/freebsd-elf.h i386/perform.h"
1079 # On FreeBSD, the headers are already ok, except for math.h.
1080 fixincludes=fixinc.wrap
1081 tmake_file=i386/t-freebsd
1087 i[34567]86-*-freebsd*)
1089 tm_file=i386/freebsd.h
1090 # On FreeBSD, the headers are already ok, except for math.h.
1091 fixincludes=fixinc.wrap
1092 tmake_file=i386/t-freebsd
1094 # We are hoping OpenBSD is still close enough to NetBSD that we can
1095 # share the configurations.
1097 i[34567]86-*-netbsd* | i[34567]86-*-openbsd*)
1099 tm_file=i386/netbsd.h
1100 # On NetBSD, the headers are already okay, except for math.h.
1101 fixincludes=fixinc.wrap
1107 tm_file=i386/i386-coff.h
1108 tmake_file=i386/t-i386bare
1111 i[34567]86-*-isc*) # 80386 running ISC system
1113 xm_file="${xm_file} i386/xm-isc.h"
1114 xm_defines="USG SVR3"
1117 i[34567]86-*-isc[34]*)
1119 xmake_file=i386/x-isc3
1122 xmake_file=i386/x-isc
1125 if test x$gas = xyes -a x$stabs = xyes
1127 tm_file=i386/iscdbx.h
1128 tmake_file=i386/t-svr3dbx
1129 extra_parts="svr3.ifile svr3z.ifile"
1131 tm_file=i386/isccoff.h
1132 tmake_file=i386/t-crtstuff
1133 extra_parts="crtbegin.o crtend.o"
1135 install_headers_dir=install-headers-cpio
1138 i[34567]86-*-linux-gnuoldld*) # Intel 80386's running GNU/Linux
1139 changequote([,])dnl # with a.out format using
1141 xmake_file=x-linux-aout
1142 tmake_file="t-linux-aout i386/t-crtstuff"
1143 tm_file=i386/linux-oldld.h
1144 fixincludes=Makefile.in #On Linux, the headers are ok already.
1149 i[34567]86-*-linux-gnuaout*) # Intel 80386's running GNU/Linux
1150 changequote([,])dnl # with a.out format
1151 xmake_file=x-linux-aout
1152 tmake_file="t-linux-aout i386/t-crtstuff"
1153 tm_file=i386/linux-aout.h
1154 fixincludes=Makefile.in #On Linux, the headers are ok already.
1159 i[34567]86-*-linux-gnulibc1) # Intel 80386's running GNU/Linux
1160 changequote([,])dnl # with ELF format using the
1161 # GNU/Linux C library 5
1163 tm_file=i386/linux.h
1164 tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff"
1165 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1166 fixincludes=Makefile.in #On Linux, the headers are ok already.
1169 if test x$enable_threads = xyes; then
1170 thread_file='single'
1174 i[34567]86-*-linux-gnu*) # Intel 80386's running GNU/Linux
1175 changequote([,])dnl # with ELF format using glibc 2
1176 # aka GNU/Linux C library 6
1178 tm_file=i386/linux.h
1179 tmake_file="t-linux i386/t-crtstuff"
1180 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1181 fixincludes=Makefile.in #On Linux, the headers are ok already.
1184 if test x$enable_threads = xyes; then
1193 i[34567]86-go32-msdos | i[34567]86-*-go32*)
1195 xm_file=i386/xm-go32.h
1197 tmake_file=i386/t-go32
1200 i[34567]86-pc-msdosdjgpp*)
1202 xm_file=i386/xm-go32.h
1204 tmake_file=i386/t-go32
1215 i[34567]86-moss-msdos* | i[34567]86-*-moss*)
1218 tmake_file=t-libc-ok
1219 fixincludes=Makefile.in
1224 i[34567]86-*-lynxos*)
1226 if test x$gas = xyes
1230 tm_file=i386/lynx-ng.h
1232 xm_file=i386/xm-lynx.h
1233 tmake_file=i386/t-i386bare
1240 # tmake_file=t-libc-ok
1244 i[34567]86-*-osfrose*) # 386 using OSF/rose
1246 if test x$elf = xyes
1248 tm_file=i386/osfelf.h
1251 tm_file=i386/osfrose.h
1254 xm_file="i386/xm-osf.h ${xm_file}"
1255 xmake_file=i386/x-osfrose
1256 tmake_file=i386/t-osf
1257 extra_objs=halfpic.o
1260 i[34567]86-go32-rtems*)
1263 xm_file=i386/xm-go32.h
1264 tm_file=i386/go32-rtems.h
1265 tmake_file="i386/t-go32 t-rtems"
1268 i[34567]86-*-rtemself*)
1271 tm_file=i386/rtemself.h
1272 tmake_file="i386/t-i386bare t-rtems"
1275 i[34567]86-*-rtems*)
1278 tm_file=i386/rtems.h
1279 tmake_file="i386/t-i386bare t-rtems"
1282 i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
1284 xm_file="xm-siglist.h xm-alloca.h ${xm_file} i386/xm-sco5.h"
1285 xm_defines="USG SVR3"
1286 xmake_file=i386/x-sco5
1287 fixincludes=fixinc.sco
1288 install_headers_dir=install-headers-cpio
1290 if test x$gas = xyes
1292 tm_file="i386/sco5gas.h ${tm_file}"
1293 tmake_file=i386/t-sco5gas
1295 tmake_file=i386/t-sco5
1297 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
1300 i[34567]86-*-sco3.2v4*) # 80386 running SCO 3.2v4 system
1302 xm_file="${xm_file} i386/xm-sco.h"
1303 xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX NO_SYS_SIGLIST"
1304 xmake_file=i386/x-sco4
1305 fixincludes=fixinc.sco
1306 install_headers_dir=install-headers-cpio
1307 if test x$stabs = xyes
1309 tm_file=i386/sco4dbx.h
1310 tmake_file=i386/t-svr3dbx
1311 extra_parts="svr3.ifile svr3z.rfile"
1314 tmake_file=i386/t-crtstuff
1315 extra_parts="crtbegin.o crtend.o"
1320 i[34567]86-*-sco*) # 80386 running SCO system
1322 xm_file=i386/xm-sco.h
1323 xmake_file=i386/x-sco
1324 install_headers_dir=install-headers-cpio
1325 if test x$stabs = xyes
1327 tm_file=i386/scodbx.h
1328 tmake_file=i386/t-svr3dbx
1329 extra_parts="svr3.ifile svr3z.rfile"
1332 extra_parts="crtbegin.o crtend.o"
1333 tmake_file=i386/t-crtstuff
1338 i[34567]86-*-solaris2*)
1340 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1341 xm_defines="USG POSIX SMALL_ARG_MAX"
1342 if test x$stabs = xyes
1344 tm_file=i386/sol2dbg.h
1348 tmake_file=i386/t-sol2
1349 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
1355 fixincludes=fixinc.svr4;;
1357 fixincludes=fixinc.wrap;;
1359 if test x$enable_threads = xyes; then
1360 thread_file='solaris'
1364 i[34567]86-*-sysv5*) # Intel x86 on System V Release 5
1366 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1367 xm_defines="USG POSIX"
1368 tm_file=i386/sysv4.h
1369 if test x$stabs = xyes
1371 tm_file="${tm_file} dbx.h"
1373 tmake_file=i386/t-crtpic
1375 extra_parts="crtbegin.o crtend.o"
1376 fixincludes=fixinc.svr4
1379 i[34567]86-*-sysv4*) # Intel 80386's running system V.4
1381 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1382 xm_defines="USG POSIX SMALL_ARG_MAX"
1383 tm_file=i386/sysv4.h
1384 if test x$stabs = xyes
1386 tm_file="${tm_file} dbx.h"
1388 tmake_file=i386/t-crtpic
1390 extra_parts="crtbegin.o crtend.o"
1393 i[34567]86-*-udk*) # Intel x86 on SCO UW/OSR5 Dev Kit
1395 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1396 xm_defines="USG POSIX"
1398 tmake_file="i386/t-crtpic i386/t-udk"
1400 extra_parts="crtbegin.o crtend.o"
1401 fixincludes="fixinc.svr4"
1404 i[34567]86-*-osf1*) # Intel 80386's running OSF/1 1.3+
1407 xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h i386/xm-osf1elf.h"
1408 xm_defines="USE_C_ALLOCA SMALL_ARG_MAX"
1409 fixincludes=Makefile.in #Don't do it on OSF/1
1410 if test x$stabs = xyes
1412 tm_file=i386/osf1elfgdb.h
1414 tm_file=i386/osf1elf.h
1416 tmake_file=i386/t-osf1elf
1417 xmake_file=i386/x-osf1elf
1418 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
1421 i[34567]86-*-sysv*) # Intel 80386's running system V
1423 xm_defines="USG SVR3"
1424 xmake_file=i386/x-sysv3
1425 if test x$gas = xyes
1427 if test x$stabs = xyes
1429 tm_file=i386/svr3dbx.h
1430 tmake_file=i386/t-svr3dbx
1431 extra_parts="svr3.ifile svr3z.rfile"
1433 tm_file=i386/svr3gas.h
1434 extra_parts="crtbegin.o crtend.o"
1435 tmake_file=i386/t-crtstuff
1438 tm_file=i386/sysv3.h
1439 extra_parts="crtbegin.o crtend.o"
1440 tmake_file=i386/t-crtstuff
1443 i386-*-vsta) # Intel 80386's running VSTa kernel
1444 xm_file="${xm_file} i386/xm-vsta.h"
1446 tmake_file=i386/t-vsta
1447 xmake_file=i386/x-vsta
1452 xm_file="${xm_file} i386/xm-cygwin.h"
1453 tmake_file=i386/t-cygwin
1454 tm_file=i386/win32.h
1455 xmake_file=i386/x-cygwin
1457 fixincludes=Makefile.in
1458 if test x$enable_threads = xyes; then
1464 i[34567]86-*-pe | i[34567]86-*-cygwin*)
1466 xm_file="${xm_file} i386/xm-cygwin.h"
1467 tmake_file=i386/t-cygwin
1468 tm_file=i386/cygwin.h
1469 xmake_file=i386/x-cygwin
1471 fixincludes=Makefile.in
1472 if test x$enable_threads = xyes; then
1478 i[34567]86-*-mingw32*)
1480 tm_file=i386/mingw32.h
1481 xm_file="${xm_file} i386/xm-mingw32.h"
1482 tmake_file="i386/t-cygwin i386/t-mingw32"
1484 xmake_file=i386/x-cygwin
1485 fixincludes=Makefile.in
1486 if test x$enable_threads = xyes; then
1493 *minwg32crt* | *mingw32*)
1494 tm_file="${tm_file} i386/crtdll.h"
1499 i[34567]86-*-winnt3*)
1501 tm_file=i386/win-nt.h
1502 out_file=i386/i386.c
1503 xm_file="xm-winnt.h ${xm_file}"
1504 xmake_file=winnt/x-winnt
1505 tmake_file=i386/t-winnt
1506 extra_host_objs="winnt.o oldnames.o"
1507 extra_gcc_objs="spawnv.o oldnames.o"
1508 fixincludes=fixinc.winnt
1509 if test x$gnu_ld != xyes
1511 extra_programs=ld.exe
1513 if test x$enable_threads = xyes; then
1518 i[34567]86-dg-dgux*)
1520 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1521 xm_defines="USG POSIX"
1522 out_file=i386/dgux.c
1524 tmake_file=i386/t-dgux
1525 xmake_file=i386/x-dgux
1526 fixincludes=fixinc.dgux
1527 install_headers_dir=install-headers-cpio
1529 i860-alliant-*) # Alliant FX/2800
1530 tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h"
1531 xm_file="${xm_file}"
1532 xmake_file=i860/x-fx2800
1533 tmake_file=i860/t-fx2800
1534 extra_parts="crtbegin.o crtend.o"
1537 tm_file="${tm_file} i860/bsd.h"
1538 if test x$gas = xyes
1540 tm_file="${tm_file} i860/bsd-gas.h"
1545 tm_file="${tm_file} i860/mach.h"
1546 tmake_file=t-libc-ok
1548 i860-*-osf*) # Intel Paragon XP/S, OSF/1AD
1549 tm_file="${tm_file} svr3.h i860/paragon.h"
1550 xm_defines="USG SVR3"
1554 tm_file="${tm_file} svr3.h i860/sysv3.h"
1555 xm_defines="USG SVR3"
1556 xmake_file=i860/x-sysv3
1557 extra_parts="crtbegin.o crtend.o"
1560 tm_file="${tm_file} svr4.h i860/sysv4.h"
1561 xm_defines="USG SVR3"
1562 xmake_file=i860/x-sysv4
1564 extra_parts="crtbegin.o crtend.o"
1566 i960-wrs-vxworks5 | i960-wrs-vxworks5.0*)
1567 tm_file="${tm_file} i960/vx960.h"
1568 tmake_file=i960/t-vxworks960
1570 thread_file='vxworks'
1572 i960-wrs-vxworks5* | i960-wrs-vxworks)
1573 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h"
1574 tmake_file=i960/t-vxworks960
1576 thread_file='vxworks'
1579 tm_file="${tm_file} i960/vx960.h"
1580 tmake_file=i960/t-vxworks960
1582 thread_file='vxworks'
1585 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h"
1586 tmake_file=i960/t-960bare
1590 tmake_file="i960/t-960bare t-rtems"
1591 tm_file="${tm_file} dbxcoff.h i960/rtems.h"
1594 i960-*-*) # Default i960 environment.
1598 extra_parts="crtinit.o crtfini.o"
1600 m68000-convergent-sysv*)
1602 xm_file="m68k/xm-3b1.h ${xm_file}"
1605 extra_headers=math-68881.h
1607 m68000-hp-bsd*) # HP 9000/200 running BSD
1608 tm_file=m68k/hp2bsd.h
1609 xmake_file=m68k/x-hp2bsd
1611 extra_headers=math-68881.h
1613 m68000-hp-hpux*) # HP 9000 series 300
1614 xm_file="xm_alloca.h ${xm_file}"
1615 xm_defines="USG NO_SYS_SIGLIST"
1616 if test x$gas = xyes
1618 xmake_file=m68k/x-hp320g
1619 tm_file=m68k/hp310g.h
1621 xmake_file=m68k/x-hp320
1622 tm_file=m68k/hp310.h
1624 install_headers_dir=install-headers-cpio
1626 extra_headers=math-68881.h
1631 extra_headers=math-68881.h
1634 tm_file=m68k/sun2o4.h
1636 extra_headers=math-68881.h
1639 xm_file="m68k/xm-3b1.h ${xm_file}"
1641 if test x$gas = xyes
1648 extra_headers=math-68881.h
1650 m68k-apple-aux*) # Apple Macintosh running A/UX
1651 xm_defines="USG AUX"
1652 tmake_file=m68k/t-aux
1653 install_headers_dir=install-headers-cpio
1654 extra_headers=math-68881.h
1655 extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o"
1657 if test "$gnu_ld" = yes
1659 tm_file="${tm_file} m68k/auxgld.h"
1661 tm_file="${tm_file} m68k/auxld.h"
1663 if test "$gas" = yes
1665 tm_file="${tm_file} m68k/auxgas.h"
1667 tm_file="${tm_file} m68k/auxas.h"
1669 tm_file="${tm_file} m68k/a-ux.h"
1673 tm_file=m68k/apollo68.h
1674 xmake_file=m68k/x-apollo68
1676 extra_headers=math-68881.h
1679 m68k-altos-sysv*) # Altos 3068
1680 if test x$gas = xyes
1682 tm_file=m68k/altos3068.h
1685 echo "The Altos is supported only with the GNU assembler" 1>&2
1688 extra_headers=math-68881.h
1690 m68k-bull-sysv*) # Bull DPX/2
1691 if test x$gas = xyes
1693 if test x$stabs = xyes
1695 tm_file=m68k/dpx2cdbx.h
1697 tm_file=m68k/dpx2g.h
1702 xm_file="xm-alloca.h ${xm_file}"
1704 xmake_file=m68k/x-dpx2
1706 extra_headers=math-68881.h
1708 m68k-atari-sysv4*) # Atari variant of V.4.
1709 tm_file=m68k/atari.h
1710 xm_file="xm-alloca.h ${xm_file}"
1711 xm_defines="USG FULL_PROTOTYPES"
1713 extra_parts="crtbegin.o crtend.o"
1714 extra_headers=math-68881.h
1717 m68k-motorola-sysv*)
1718 tm_file=m68k/mot3300.h
1719 xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}"
1720 xm_defines=NO_SYS_SIGLIST
1721 if test x$gas = xyes
1723 xmake_file=m68k/x-mot3300-gas
1724 if test x$gnu_ld = xyes
1726 tmake_file=m68k/t-mot3300-gald
1728 tmake_file=m68k/t-mot3300-gas
1732 xmake_file=m68k/x-mot3300
1733 if test x$gnu_ld = xyes
1735 tmake_file=m68k/t-mot3300-gld
1737 tmake_file=m68k/t-mot3300
1741 gdb_needs_out_file_path=yes
1742 extra_parts="crt0.o mcrt0.o"
1743 extra_headers=math-68881.h
1746 m68k-ncr-sysv*) # NCR Tower 32 SVR3
1747 tm_file=m68k/tower-as.h
1748 xm_defines="USG SVR3"
1749 xmake_file=m68k/x-tower
1750 extra_parts="crtbegin.o crtend.o"
1751 extra_headers=math-68881.h
1754 tm_file=m68k/plexus.h
1755 xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}"
1758 extra_headers=math-68881.h
1762 xm_file="xm-alloca.h ${xm_file}"
1764 extra_headers=math-68881.h
1767 xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}"
1768 xm_defines="USG unos"
1769 xmake_file=m68k/x-crds
1772 extra_headers=math-68881.h
1774 m68k-cbm-sysv4*) # Commodore variant of V.4.
1776 xm_file="xm-alloca.h ${xm_file}"
1777 xm_defines="USG FULL_PROTOTYPES"
1778 xmake_file=m68k/x-amix
1780 extra_parts="crtbegin.o crtend.o"
1781 extra_headers=math-68881.h
1785 tm_file=m68k/ccur-GAS.h
1786 xmake_file=m68k/x-ccur
1787 extra_headers=math-68881.h
1791 m68k-hp-bsd4.4*) # HP 9000/3xx running 4.4bsd
1792 tm_file=m68k/hp3bsd44.h
1793 xmake_file=m68k/x-hp3bsd44
1795 extra_headers=math-68881.h
1798 m68k-hp-bsd*) # HP 9000/3xx running Berkeley Unix
1799 tm_file=m68k/hp3bsd.h
1801 extra_headers=math-68881.h
1805 if test x$with_fp = xno
1807 tm_file=m68k/isi-nfp.h
1813 extra_headers=math-68881.h
1815 m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
1816 xm_file="xm_alloca.h ${xm_file}"
1817 xm_defines="USG NO_SYS_SIGLIST"
1818 if test x$gas = xyes
1820 xmake_file=m68k/x-hp320g
1821 tm_file=m68k/hp320g.h
1823 xmake_file=m68k/x-hp320
1824 tm_file=m68k/hpux7.h
1826 install_headers_dir=install-headers-cpio
1828 extra_headers=math-68881.h
1831 m68k-hp-hpux*) # HP 9000 series 300
1832 xm_file="xm_alloca.h ${xm_file}"
1833 xm_defines="USG NO_SYS_SIGLIST"
1834 if test x$gas = xyes
1836 xmake_file=m68k/x-hp320g
1837 tm_file=m68k/hp320g.h
1839 xmake_file=m68k/x-hp320
1840 tm_file=m68k/hp320.h
1842 install_headers_dir=install-headers-cpio
1844 extra_headers=math-68881.h
1848 tm_file=m68k/sun3mach.h
1850 extra_headers=math-68881.h
1854 if test x$gas = xyes
1856 tm_file=m68k/news3gas.h
1858 tm_file=m68k/news3.h
1861 extra_headers=math-68881.h
1864 m68k-sony-bsd* | m68k-sony-newsos*)
1865 if test x$gas = xyes
1867 tm_file=m68k/newsgas.h
1872 extra_headers=math-68881.h
1875 m68k-next-nextstep2*)
1876 tm_file=m68k/next21.h
1877 xm_file="m68k/xm-next.h ${xm_file}"
1878 tmake_file=m68k/t-next
1879 xmake_file=m68k/x-next
1880 extra_objs=nextstep.o
1881 extra_headers=math-68881.h
1885 m68k-next-nextstep3*)
1887 xm_file="m68k/xm-next.h ${xm_file}"
1888 tmake_file=m68k/t-next
1889 xmake_file=m68k/x-next
1890 extra_objs=nextstep.o
1891 extra_parts="crtbegin.o crtend.o"
1892 extra_headers=math-68881.h
1894 if test x$enable_threads = xyes; then
1899 if test x$with_fp = xno
1901 tm_file=m68k/sun3n3.h
1903 tm_file=m68k/sun3o3.h
1907 extra_headers=math-68881.h
1909 m68k-sun-sunos*) # For SunOS 4 (the default).
1910 if test x$with_fp = xno
1912 tm_file=m68k/sun3n.h
1918 extra_headers=math-68881.h
1921 tm_file=m68k/vxm68k.h
1922 tmake_file=m68k/t-vxworks68
1923 extra_headers=math-68881.h
1924 thread_file='vxworks'
1928 tmake_file=m68k/t-m68kbare
1929 tm_file="m68k/m68k-aout.h libgloss.h"
1930 extra_headers=math-68881.h
1934 tmake_file=m68k/t-m68kbare
1935 tm_file="m68k/m68k-coff.h dbx.h libgloss.h"
1936 extra_headers=math-68881.h
1939 m68020-*-elf* | m68k-*-elf*)
1940 tm_file="m68k/m68020-elf.h libgloss.h"
1941 xm_file=m68k/xm-m68kv.h
1942 tmake_file=m68k/t-m68kelf
1943 header_files=math-68881.h
1946 if test x$gas = xyes
1950 tm_file=m68k/lynx-ng.h
1952 xm_file=m68k/xm-lynx.h
1954 tmake_file=m68k/t-lynx
1955 extra_headers=math-68881.h
1959 tm_file=m68k/netbsd.h
1960 # On NetBSD, the headers are already okay, except for math.h.
1961 fixincludes=fixinc.wrap
1965 m68k-*-sysv3*) # Motorola m68k's running system V.3
1966 xm_file="xm-alloca.h ${xm_file}"
1968 xmake_file=m68k/x-m68kv
1969 extra_parts="crtbegin.o crtend.o"
1970 extra_headers=math-68881.h
1973 m68k-*-sysv4*) # Motorola m68k's running system V.4
1974 tm_file=m68k/m68kv4.h
1975 xm_file="xm-alloca.h ${xm_file}"
1978 extra_parts="crtbegin.o crtend.o"
1979 extra_headers=math-68881.h
1982 m68k-*-linux-gnuaout*) # Motorola m68k's running GNU/Linux
1985 tm_file=m68k/linux-aout.h
1986 tmake_file="t-linux-aout m68k/t-linux-aout"
1987 fixincludes=Makefile.in # The headers are ok already.
1988 extra_headers=math-68881.h
1992 m68k-*-linux-gnulibc1) # Motorola m68k's running GNU/Linux
1993 # with ELF format using the
1994 # GNU/Linux C library 5
1996 tm_file=m68k/linux.h
1997 tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux"
1998 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1999 fixincludes=Makefile.in # The headers are ok already.
2000 extra_headers=math-68881.h
2004 m68k-*-linux-gnu*) # Motorola m68k's running GNU/Linux
2005 # with ELF format using glibc 2
2006 # aka the GNU/Linux C library 6.
2008 tm_file=m68k/linux.h
2009 tmake_file="t-linux m68k/t-linux"
2010 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2011 fixincludes=Makefile.in # The headers are ok already.
2012 extra_headers=math-68881.h
2015 if test x$enable_threads = xyes; then
2020 tmake_file=m68k/t-m68kbare
2021 tm_file=m68k/m68k-psos.h
2022 extra_headers=math-68881.h
2026 tmake_file="m68k/t-m68kbare t-rtems"
2027 tm_file=m68k/rtems.h
2028 extra_headers=math-68881.h
2035 tm_file=m88k/dguxbcs.h
2036 tmake_file=m88k/t-dguxbcs
2040 tmake_file=m88k/t-dgux
2043 extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld"
2044 xmake_file=m88k/x-dgux
2045 if test x$gas = xyes
2047 tmake_file=m88k/t-dgux-gas
2049 fixincludes=fixinc.dgux
2051 m88k-dolphin-sysv3*)
2052 tm_file=m88k/dolph.h
2053 extra_parts="crtbegin.o crtend.o"
2054 xm_file="m88k/xm-sysv3.h ${xm_file}"
2055 xmake_file=m88k/x-dolph
2056 if test x$gas = xyes
2058 tmake_file=m88k/t-m88k-gas
2061 m88k-tektronix-sysv3)
2062 tm_file=m88k/tekXD88.h
2063 extra_parts="crtbegin.o crtend.o"
2064 xm_file="m88k/xm-sysv3.h ${xm_file}"
2065 xmake_file=m88k/x-tekXD88
2066 if test x$gas = xyes
2068 tmake_file=m88k/t-m88k-gas
2072 tm_file=m88k/m88k-aout.h
2075 tm_file=m88k/m88k-coff.h
2076 tmake_file=m88k/t-bug
2080 extra_parts="crtbegin.o crtend.o"
2081 if test x$gas = xyes
2083 tmake_file=m88k/t-luna-gas
2085 tmake_file=m88k/t-luna
2089 tm_file=m88k/sysv3.h
2090 extra_parts="crtbegin.o crtend.o"
2091 xm_file="m88k/xm-sysv3.h ${xm_file}"
2092 xmake_file=m88k/x-sysv3
2093 if test x$gas = xyes
2095 tmake_file=m88k/t-m88k-gas
2099 tm_file=m88k/sysv4.h
2100 extra_parts="crtbegin.o crtend.o"
2101 xmake_file=m88k/x-sysv4
2102 tmake_file=m88k/t-sysv4
2104 mips-sgi-irix6*) # SGI System V.4., IRIX 6
2105 tm_file=mips/iris6.h
2106 xm_file=mips/xm-iris6.h
2107 fixincludes=fixinc.irix
2108 xmake_file=mips/x-iris6
2109 tmake_file=mips/t-iris6
2110 # if test x$enable_threads = xyes; then
2111 # thread_file='irix'
2115 tm_file="mips/elf.h libgloss.h"
2116 tmake_file=mips/t-ecoff
2119 extra_parts="crtbegin.o crtend.o"
2120 # thread_file='vxworks'
2122 mips-sgi-irix5cross64) # Irix5 host, Irix 6 target, cross64
2123 tm_file="mips/iris6.h mips/cross64.h"
2125 xm_file="mips/xm-iris5.h"
2126 fixincludes=Makefile.in
2127 xmake_file=mips/x-iris
2128 tmake_file=mips/t-cross64
2129 # See comment in mips/iris[56].h files.
2131 # if test x$enable_threads = xyes; then
2132 # thread_file='irix'
2136 if test x$gas = xyes
2138 if test x$stabs = xyes
2140 tm_file=mips/iris5gdb.h
2142 tm_file="mips/sni-svr4.h mips/sni-gas.h"
2145 tm_file=mips/sni-svr4.h
2148 xmake_file=mips/x-sni-svr4
2149 tmake_file=mips/t-mips-gas
2150 if test x$gnu_ld != xyes
2155 mips-sgi-irix5*) # SGI System V.4., IRIX 5
2156 if test x$gas = xyes
2158 tm_file="mips/iris5.h mips/iris5gas.h"
2159 if test x$stabs = xyes
2161 tm_file="${tm_file} dbx.h"
2164 tm_file=mips/iris5.h
2167 xm_file="mips/xm-iris5.h"
2168 fixincludes=fixinc.irix
2169 xmake_file=mips/x-iris
2170 # mips-tfile doesn't work yet
2171 tmake_file=mips/t-mips-gas
2172 # See comment in mips/iris5.h file.
2174 # if test x$enable_threads = xyes; then
2175 # thread_file='irix'
2178 mips-sgi-irix4loser*) # Mostly like a MIPS.
2179 tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h"
2180 if test x$stabs = xyes; then
2181 tm_file="${tm_file} dbx.h"
2184 xmake_file=mips/x-iris
2185 if test x$gas = xyes
2187 tmake_file=mips/t-mips-gas
2189 extra_passes="mips-tfile mips-tdump"
2191 if test x$gnu_ld != xyes
2195 # if test x$enable_threads = xyes; then
2196 # thread_file='irix'
2199 mips-sgi-irix4*) # Mostly like a MIPS.
2200 tm_file="mips/iris3.h ${tm_file} mips/iris4.h"
2201 if test x$stabs = xyes; then
2202 tm_file="${tm_file} dbx.h"
2205 xmake_file=mips/x-iris
2206 if test x$gas = xyes
2208 tmake_file=mips/t-mips-gas
2210 extra_passes="mips-tfile mips-tdump"
2212 if test x$gnu_ld != xyes
2216 # if test x$enable_threads = xyes; then
2217 # thread_file='irix'
2220 mips-sgi-*) # Mostly like a MIPS.
2221 tm_file="mips/iris3.h ${tm_file}"
2222 if test x$stabs = xyes; then
2223 tm_file="${tm_file} dbx.h"
2226 xmake_file=mips/x-iris3
2227 if test x$gas = xyes
2229 tmake_file=mips/t-mips-gas
2231 extra_passes="mips-tfile mips-tdump"
2233 if test x$gnu_ld != xyes
2238 mips-dec-osfrose*) # Decstation running OSF/1 reference port with OSF/rose.
2239 tm_file="mips/osfrose.h ${tm_file}"
2240 xmake_file=mips/x-osfrose
2241 tmake_file=mips/t-osfrose
2242 extra_objs=halfpic.o
2245 mips-dec-osf*) # Decstation running OSF/1 as shipped by DIGITAL
2246 tm_file=mips/dec-osf1.h
2247 if test x$stabs = xyes; then
2248 tm_file="${tm_file} dbx.h"
2250 xmake_file=mips/x-dec-osf1
2251 if test x$gas = xyes
2253 tmake_file=mips/t-mips-gas
2255 tmake_file=mips/t-ultrix
2256 extra_passes="mips-tfile mips-tdump"
2258 if test x$gnu_ld != xyes
2263 mips-dec-bsd*) # Decstation running 4.4 BSD
2264 tm_file=mips/dec-bsd.h
2266 if test x$gas = xyes
2268 tmake_file=mips/t-mips-gas
2270 tmake_file=mips/t-ultrix
2271 extra_passes="mips-tfile mips-tdump"
2273 if test x$gnu_ld != xyes
2278 mipsel-*-netbsd* | mips-dec-netbsd*) # Decstation running NetBSD
2279 tm_file=mips/netbsd.h
2280 # On NetBSD, the headers are already okay, except for math.h.
2281 fixincludes=fixinc.wrap
2284 mipsel-*-linux*) # Little endian Linux MIPS
2286 xm_file="xm-siglist.h ${xm_file}"
2287 tm_file="mips/elfl.h mips/linux.h"
2288 extra_parts="crtbegin.o crtend.o"
2291 fixincludes=Makefile.in
2293 mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news.
2294 tm_file="mips/news4.h ${tm_file}"
2295 if test x$stabs = xyes; then
2296 tm_file="${tm_file} dbx.h"
2298 if test x$gas = xyes
2300 tmake_file=mips/t-mips-gas
2302 extra_passes="mips-tfile mips-tdump"
2304 if test x$gnu_ld != xyes
2308 xmake_file=mips/x-sony
2310 mips-sony-sysv*) # Sony NEWS 3800 with NEWSOS5.0.
2311 # That is based on svr4.
2312 # t-svr4 is not right because this system doesn't use ELF.
2313 tm_file="mips/news5.h ${tm_file}"
2314 if test x$stabs = xyes; then
2315 tm_file="${tm_file} dbx.h"
2317 xm_file="xm-siglist.h ${xm_file}"
2319 if test x$gas = xyes
2321 tmake_file=mips/t-mips-gas
2323 extra_passes="mips-tfile mips-tdump"
2325 if test x$gnu_ld != xyes
2330 mips-tandem-sysv4*) # Tandem S2 running NonStop UX
2331 tm_file="mips/svr4-5.h mips/svr4-t.h"
2332 if test x$stabs = xyes; then
2333 tm_file="${tm_file} dbx.h"
2335 xm_file="xm-siglist.h ${xm_file}"
2337 xmake_file=mips/x-sysv
2338 if test x$gas = xyes
2340 tmake_file=mips/t-mips-gas
2341 extra_parts="crtbegin.o crtend.o"
2343 tmake_file=mips/t-mips
2344 extra_passes="mips-tfile mips-tdump"
2346 if test x$gnu_ld != xyes
2351 mips-*-ultrix* | mips-dec-mach3) # Decstation.
2352 tm_file="mips/ultrix.h ${tm_file}"
2353 if test x$stabs = xyes; then
2354 tm_file="${tm_file} dbx.h"
2356 xmake_file=mips/x-ultrix
2357 if test x$gas = xyes
2359 tmake_file=mips/t-mips-gas
2361 tmake_file=mips/t-ultrix
2362 extra_passes="mips-tfile mips-tdump"
2364 if test x$gnu_ld != xyes
2370 mips-*-riscos[56789]bsd*)
2372 tm_file=mips/bsd-5.h # MIPS BSD 4.3, RISC-OS 5.0
2373 if test x$stabs = xyes; then
2374 tm_file="${tm_file} dbx.h"
2376 if test x$gas = xyes
2378 tmake_file=mips/t-bsd-gas
2380 tmake_file=mips/t-bsd
2381 extra_passes="mips-tfile mips-tdump"
2383 if test x$gnu_ld != xyes
2389 mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[1234]bsd*)
2391 tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0
2392 if test x$stabs = xyes; then
2393 tm_file="${tm_file} dbx.h"
2395 if test x$gas = xyes
2397 tmake_file=mips/t-bsd-gas
2399 tmake_file=mips/t-bsd
2400 extra_passes="mips-tfile mips-tdump"
2402 if test x$gnu_ld != xyes
2408 mips-*-riscos[56789]sysv4*)
2410 tm_file=mips/svr4-5.h # MIPS System V.4., RISC-OS 5.0
2411 if test x$stabs = xyes; then
2412 tm_file="${tm_file} dbx.h"
2414 xm_file="xm-siglist.h ${xm_file}"
2415 xmake_file=mips/x-sysv
2416 if test x$gas = xyes
2418 tmake_file=mips/t-svr4-gas
2420 tmake_file=mips/t-svr4
2421 extra_passes="mips-tfile mips-tdump"
2423 if test x$gnu_ld != xyes
2429 mips-*-sysv4* | mips-*-riscos[1234]sysv4* | mips-*-riscossysv4*)
2431 tm_file="mips/svr4-4.h ${tm_file}"
2432 if test x$stabs = xyes; then
2433 tm_file="${tm_file} dbx.h"
2436 xmake_file=mips/x-sysv
2437 if test x$gas = xyes
2439 tmake_file=mips/t-svr4-gas
2441 tmake_file=mips/t-svr4
2442 extra_passes="mips-tfile mips-tdump"
2444 if test x$gnu_ld != xyes
2450 mips-*-riscos[56789]sysv*)
2452 tm_file=mips/svr3-5.h # MIPS System V.3, RISC-OS 5.0
2453 if test x$stabs = xyes; then
2454 tm_file="${tm_file} dbx.h"
2457 xmake_file=mips/x-sysv
2458 if test x$gas = xyes
2460 tmake_file=mips/t-svr3-gas
2462 tmake_file=mips/t-svr3
2463 extra_passes="mips-tfile mips-tdump"
2465 if test x$gnu_ld != xyes
2470 mips-*-sysv* | mips-*-riscos*sysv*)
2471 tm_file="mips/svr3-4.h ${tm_file}"
2472 if test x$stabs = xyes; then
2473 tm_file="${tm_file} dbx.h"
2476 xmake_file=mips/x-sysv
2477 if test x$gas = xyes
2479 tmake_file=mips/t-svr3-gas
2481 tmake_file=mips/t-svr3
2482 extra_passes="mips-tfile mips-tdump"
2484 if test x$gnu_ld != xyes
2490 mips-*-riscos[56789]*) # Default MIPS RISC-OS 5.0.
2492 tm_file=mips/mips-5.h
2493 if test x$stabs = xyes; then
2494 tm_file="${tm_file} dbx.h"
2496 if test x$gas = xyes
2498 tmake_file=mips/t-mips-gas
2500 extra_passes="mips-tfile mips-tdump"
2502 if test x$gnu_ld != xyes
2510 tm_file=mips/ecoffl.h
2511 if test x$stabs = xyes; then
2512 tm_file="${tm_file} dbx.h"
2514 tmake_file=mips/t-ecoff
2517 tm_file="gofast.h mips/ecoff.h"
2518 if test x$stabs = xyes; then
2519 tm_file="${tm_file} dbx.h"
2521 tmake_file=mips/t-ecoff
2524 tm_file="mips/elfl.h libgloss.h"
2525 tmake_file=mips/t-ecoff
2528 tm_file="mips/elf.h libgloss.h"
2529 tmake_file=mips/t-ecoff
2532 tm_file="mips/elfl64.h libgloss.h"
2533 tmake_file=mips/t-ecoff
2535 mips64orionel-*-elf*)
2536 tm_file="mips/elforion.h mips/elfl64.h libgloss.h"
2537 tmake_file=mips/t-ecoff
2540 tm_file="mips/elf64.h libgloss.h"
2541 tmake_file=mips/t-ecoff
2544 tm_file="mips/elforion.h mips/elf64.h libgloss.h"
2545 tmake_file=mips/t-ecoff
2547 mips64orion-*-rtems*)
2548 tm_file="mips/elforion.h mips/elf64.h mips/rtems64.h"
2549 tmake_file="mips/t-ecoff t-rtems"
2552 tm_file="mips/r3900.h mips/elfl.h mips/abi64.h libgloss.h"
2553 tmake_file=mips/t-r3900
2556 tm_file="mips/r3900.h mips/elf.h mips/abi64.h libgloss.h"
2557 tmake_file=mips/t-r3900
2558 # FIXME mips-elf should be fixed to use crtstuff.
2561 mips-*-*) # Default MIPS RISC-OS 4.0.
2562 if test x$stabs = xyes; then
2563 tm_file="${tm_file} dbx.h"
2565 if test x$gas = xyes
2567 tmake_file=mips/t-mips-gas
2569 extra_passes="mips-tfile mips-tdump"
2571 if test x$gnu_ld != xyes
2578 tm_file="mn10200/mn10200.h"
2579 if test x$stabs = xyes
2581 tm_file="${tm_file} dbx.h"
2587 tm_file="mn10300/mn10300.h"
2588 if test x$stabs = xyes
2590 tm_file="${tm_file} dbx.h"
2595 tm_file=ns32k/encore.h
2599 tm_file=ns32k/sequent.h
2603 tm_file=ns32k/tek6100.h
2607 tm_file=ns32k/tek6200.h
2610 # This has not been updated to GCC 2.
2613 # xmake_file=ns32k/x-genix
2614 # tm_file=ns32k/genix.h
2618 tm_file=ns32k/merlin.h
2622 tm_file=ns32k/pc532-mach.h
2626 tm_file=ns32k/pc532-min.h
2627 xm_file="ns32k/xm-pc532-min.h ${xm-file}"
2632 tm_file=ns32k/netbsd.h
2633 xm_file="ns32k/xm-netbsd.h ${xm_file}"
2634 # On NetBSD, the headers are already okay, except for math.h.
2635 fixincludes=fixinc.wrap
2639 tm_file="${tm_file} pdp11/2bsd.h"
2645 xmake_file=pyr/x-pyr
2652 xmake_file=romp/x-mach
2657 tm_file=rs6000/beos.h
2658 xm_file=rs6000/xm-beos.h
2659 tmake_file=rs6000/t-beos
2660 xmake_file=rs6000/x-beos
2662 powerpc-*-sysv* | powerpc-*-elf*)
2663 tm_file=rs6000/sysv4.h
2664 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2665 xm_defines="USG POSIX"
2666 extra_headers=ppc-asm.h
2667 if test x$gas = xyes
2669 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2671 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2673 xmake_file=rs6000/x-sysv4
2676 tm_file=rs6000/eabiaix.h
2677 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2678 fixincludes=Makefile.in
2679 extra_headers=ppc-asm.h
2682 tm_file=rs6000/eabisim.h
2683 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2684 fixincludes=Makefile.in
2685 extra_headers=ppc-asm.h
2688 tm_file=rs6000/eabi.h
2689 if test x$gas = xyes
2691 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2693 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2695 fixincludes=Makefile.in
2696 extra_headers=ppc-asm.h
2699 tm_file=rs6000/rtems.h
2700 if test x$gas = xyes
2702 tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm"
2704 tmake_file="rs6000/t-ppc t-rtems rs6000/t-ppccomm"
2706 fixincludes=Makefile.in
2707 extra_headers=ppc-asm.h
2709 powerpc-*-linux-gnulibc1)
2710 tm_file=rs6000/linux.h
2711 xm_file=rs6000/xm-sysv4.h
2712 out_file=rs6000/rs6000.c
2713 if test x$gas = xyes
2715 tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2717 tmake_file="rs6000/t-ppc t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2720 fixincludes=Makefile.in
2721 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2722 extra_headers=ppc-asm.h
2723 if test x$enable_threads = xyes; then
2727 powerpc-*-linux-gnu*)
2728 tm_file=rs6000/linux.h
2729 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2730 xm_defines="USG ${xm_defines}"
2731 out_file=rs6000/rs6000.c
2732 if test x$gas = xyes
2734 tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm"
2736 tmake_file="rs6000/t-ppc t-linux rs6000/t-ppccomm"
2739 fixincludes=Makefile.in
2740 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2741 extra_headers=ppc-asm.h
2742 if test x$enable_threads = xyes; then
2746 powerpc-wrs-vxworks*)
2748 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2749 xm_defines="USG POSIX"
2750 tm_file=rs6000/vxppc.h
2751 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2752 extra_headers=ppc-asm.h
2753 thread_file='vxworks'
2755 powerpcle-*-sysv* | powerpcle-*-elf*)
2756 tm_file=rs6000/sysv4le.h
2757 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2758 xm_defines="USG POSIX"
2759 if test x$gas = xyes
2761 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2763 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2765 xmake_file=rs6000/x-sysv4
2766 extra_headers=ppc-asm.h
2768 powerpcle-*-eabisim*)
2769 tm_file=rs6000/eabilesim.h
2770 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2771 fixincludes=Makefile.in
2772 extra_headers=ppc-asm.h
2775 tm_file=rs6000/eabile.h
2776 if test x$gas = xyes
2778 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2780 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2782 fixincludes=Makefile.in
2783 extra_headers=ppc-asm.h
2785 powerpcle-*-winnt* )
2786 tm_file=rs6000/win-nt.h
2787 tmake_file=rs6000/t-winnt
2789 fixincludes=Makefile.in
2790 if test x$enable_threads = xyes; then
2793 extra_headers=ppc-asm.h
2795 powerpcle-*-pe | powerpcle-*-cygwin*)
2796 tm_file=rs6000/cygwin.h
2797 xm_file="rs6000/xm-cygwin.h ${xm_file}"
2798 tmake_file=rs6000/t-winnt
2799 xmake_file=rs6000/x-cygwin
2801 fixincludes=Makefile.in
2802 if test x$enable_threads = xyes; then
2806 extra_headers=ppc-asm.h
2808 powerpcle-*-solaris2*)
2809 tm_file=rs6000/sol2.h
2810 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2811 xm_defines="USG POSIX"
2812 if test x$gas = xyes
2814 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2816 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2818 xmake_file=rs6000/x-sysv4
2823 fixincludes=fixinc.svr4;;
2825 fixincludes=fixinc.wrap;;
2827 extra_headers=ppc-asm.h
2830 rs6000-ibm-aix3.[01]*)
2832 tm_file=rs6000/aix31.h
2833 xmake_file=rs6000/x-aix31
2837 rs6000-ibm-aix3.2.[456789]* | powerpc-ibm-aix3.2.[456789]*)
2839 tm_file=rs6000/aix3newas.h
2840 if test x$host != x$target
2842 tmake_file=rs6000/t-xnewas
2844 tmake_file=rs6000/t-newas
2849 rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*)
2851 tm_file=rs6000/aix41.h
2852 if test x$host != x$target
2854 tmake_file=rs6000/t-xnewas
2856 tmake_file=rs6000/t-newas
2858 xmake_file=rs6000/x-aix41
2862 rs6000-ibm-aix4.[3456789].* | powerpc-ibm-aix4.[3456789].*)
2864 tm_file=rs6000/aix43.h
2865 if test x$host != x$target
2867 tmake_file=rs6000/t-xaix43
2869 tmake_file=rs6000/t-aix43
2871 xmake_file=rs6000/x-aix43
2875 rs6000-ibm-aix[56789].* | powerpc-ibm-aix[56789].*)
2877 tm_file=rs6000/aix43.h
2878 if test x$host != x$target
2880 tmake_file=rs6000/t-xaix43
2882 tmake_file=rs6000/t-aix43
2884 xmake_file=rs6000/x-aix43
2894 tm_file=rs6000/mach.h
2895 xm_file="${xm_file} rs6000/xm-mach.h"
2896 xmake_file=rs6000/x-mach
2900 tm_file=rs6000/lynx.h
2901 xm_file=rs6000/xm-lynx.h
2902 tmake_file=rs6000/t-rs6000
2903 xmake_file=rs6000/x-lynx
2911 tmake_file="sh/t-sh t-rtems"
2912 tm_file=sh/rtemself.h
2916 tmake_file="sh/t-sh t-rtems"
2925 xm_file="xm-alloca.h ${xm_file}"
2928 sparc-wrs-vxworks* | sparclite-wrs-vxworks*)
2929 tm_file=sparc/vxsparc.h
2930 tmake_file=sparc/t-vxsparc
2932 thread_file='vxworks'
2935 tmake_file=sparc/t-sparcbare
2936 tm_file="sparc/aout.h libgloss.h"
2939 tm_file=sparc/netbsd.h
2940 # On NetBSD, the headers are already okay, except for math.h.
2941 fixincludes=fixinc.wrap
2949 tmake_file=sparc/t-elf
2950 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
2954 sparc-*-linux-gnuaout*) # Sparc's running GNU/Linux, a.out
2955 xm_file="${xm_file} sparc/xm-linux.h"
2956 tm_file=sparc/linux-aout.h
2958 fixincludes=Makefile.in #On Linux, the headers are ok already.
2961 sparc-*-linux-gnulibc1*) # Sparc's running GNU/Linux, libc5
2962 xm_file="${xm_file} sparc/xm-linux.h"
2964 tm_file=sparc/linux.h
2965 tmake_file="t-linux t-linux-gnulibc1"
2966 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2967 fixincludes=Makefile.in #On Linux, the headers are ok already.
2970 sparc-*-linux-gnu*) # Sparc's running GNU/Linux, libc6
2971 xm_file="${xm_file} sparc/xm-linux.h"
2973 tm_file=sparc/linux.h
2974 tmake_file="t-linux"
2975 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2976 fixincludes=Makefile.in #On Linux, the headers are ok already.
2978 if test x$enable_threads = xyes; then
2983 if test x$gas = xyes
2985 tm_file=sparc/lynx.h
2987 tm_file=sparc/lynx-ng.h
2989 xm_file=sparc/xm-lynx.h
2990 tmake_file=sparc/t-sunos41
2994 tmake_file="sparc/t-sparcbare t-rtems"
2995 tm_file=sparc/rtems.h
2997 sparcv9-*-solaris2*)
2998 tm_file=sparc/sol2-sld-64.h
2999 xm_file="sparc/xm-sysv4-64.h sparc/xm-sol2.h"
3000 xm_defines="USG POSIX"
3001 tmake_file="sparc/t-sol2 sparc/t-sol2-64"
3002 xmake_file=sparc/x-sysv4
3003 extra_parts="crt1.o crti.o crtn.o gcrt1.o crtbegin.o crtend.o"
3004 fixincludes=fixinc.wrap
3006 if test x${enable_threads} = x ; then
3007 enable_threads=$have_pthread_h
3008 if test x${enable_threads} = x ; then
3009 enable_threads=$have_thread_h
3012 if test x${enable_threads} = xyes ; then
3013 if test x${have_pthread_h} = xyes ; then
3016 thread_file='solaris'
3021 if test x$gnu_ld = xyes
3023 tm_file=sparc/sol2.h
3025 tm_file=sparc/sol2-sld.h
3027 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
3028 xm_defines="USG POSIX"
3029 tmake_file=sparc/t-sol2
3030 xmake_file=sparc/x-sysv4
3031 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
3036 fixincludes=fixinc.svr4;;
3038 fixincludes=fixinc.wrap;;
3041 if test x${enable_threads} = x; then
3042 enable_threads=$have_pthread_h
3043 if test x${enable_threads} = x; then
3044 enable_threads=$have_thread_h
3047 if test x${enable_threads} = xyes; then
3048 if test x${have_pthread_h} = xyes; then
3051 thread_file='solaris'
3056 tm_file=sparc/sunos4.h
3057 tmake_file=sparc/t-sunos40
3061 tm_file=sparc/sunos4.h
3062 tmake_file=sparc/t-sunos41
3064 if test x$gas = xyes; then
3065 tm_file="${tm_file} sparc/sun4gas.h"
3069 tm_file=sparc/sun4o3.h
3073 tm_file=sparc/sysv4.h
3074 xm_file="xm-siglist.h sparc/xm-sysv4.h"
3075 xm_defines="USG POSIX"
3077 xmake_file=sparc/x-sysv4
3078 extra_parts="crtbegin.o crtend.o"
3081 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
3082 xm_defines="USG POSIX"
3083 tm_file=sparc/vxsim.h
3084 tmake_file=sparc/t-vxsparc
3085 xmake_file=sparc/x-sysv4
3088 tm_file="sparc/splet.h libgloss.h"
3089 tmake_file=sparc/t-splet
3092 tm_file="sparc/litecoff.h libgloss.h"
3093 tmake_file=sparc/t-sparclite
3096 tm_file="sparc/lite.h aoutos.h libgloss.h"
3097 tmake_file=sparc/t-sparclite
3100 tmake_file=sparc/t-sp64
3101 tm_file=sparc/sp64-aout.h
3104 tmake_file=sparc/t-sp64
3105 tm_file=sparc/sp64-elf.h
3106 extra_parts="crtbegin.o crtend.o"
3108 sparc64-*-linux*) # 64-bit Sparc's running GNU/Linux
3109 tmake_file="t-linux sparc/t-linux64"
3110 xm_file="sparc/xm-sp64.h sparc/xm-linux.h"
3111 tm_file=sparc/linux64.h
3113 fixincludes=Makefile.in # The headers are ok already.
3114 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3117 # This hasn't been upgraded to GCC 2.
3118 # tahoe-harris-*) # Harris tahoe, using COFF.
3119 # tm_file=tahoe/harris.h
3121 # tahoe-*-bsd*) # tahoe running BSD
3123 thumb-*-coff* | thumbel-*-coff*)
3125 out_file=arm/thumb.c
3126 xm_file=arm/xm-thumb.h
3127 md_file=arm/thumb.md
3128 tmake_file=arm/t-thumb
3129 fixincludes=Makefile.in # There is nothing to fix
3131 # This hasn't been upgraded to GCC 2.
3138 tm_file="v850/v850.h"
3139 xm_file="v850/xm-v850.h"
3140 tmake_file=v850/t-v850
3141 if test x$stabs = xyes
3143 tm_file="${tm_file} dbx.h"
3147 vax-*-bsd*) # vaxen running BSD
3151 vax-*-sysv*) # vaxen running system V
3152 tm_file="${tm_file} vax/vaxv.h"
3157 tm_file="${tm_file} netbsd.h vax/netbsd.h"
3158 # On NetBSD, the headers are already okay, except for math.h.
3159 fixincludes=fixinc.wrap
3163 vax-*-ultrix*) # vaxen running ultrix
3164 tm_file="${tm_file} vax/ultrix.h"
3168 vax-*-vms*) # vaxen running VMS
3169 xm_file=vax/xm-vms.h
3173 vax-*-*) # vax default entry
3177 xm_file="${xm_file} xm-svr3"
3181 echo "Configuration $machine not supported" 1>&2
3188 ;; # Existing GNU/Linux systems do not use the GNU setup.
3190 # On the GNU system, the setup is just about the same on
3191 # each different CPU. The specific machines that GNU
3192 # supports are matched above and just set $cpu_type.
3193 xm_file="xm-gnu.h ${xm_file}"
3194 tm_file=${cpu_type}/gnu.h
3195 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
3196 # GNU always uses ELF.
3198 # GNU tools are the only tools.
3201 # On GNU, the headers are already okay.
3202 fixincludes=Makefile.in
3203 xmake_file=x-linux # These details are the same as Linux.
3204 tmake_file=t-gnu # These are not.
3207 fixincludes=fixinc.svr4
3208 xmake_try_sysv=x-sysv
3209 install_headers_dir=install-headers-cpio
3212 install_headers_dir=install-headers-cpio
3216 # Distinguish i[34567]86
3217 # Also, do not run mips-tfile on MIPS if using gas.
3218 # Process --with-cpu= for PowerPC/rs6000
3219 target_cpu_default2=
3222 target_cpu_default2=1
3225 target_cpu_default2=2
3227 i686-*-* | i786-*-*)
3228 target_cpu_default2=3
3233 target_cpu_default2="MASK_CPU_EV6|MASK_BXW|MASK_CIX|MASK_MAX"
3236 target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX"
3239 target_cpu_default2="MASK_CPU_EV5|MASK_BWX"
3242 target_cpu_default2="MASK_CPU_EV5"
3246 if test x$gas = xyes
3248 if test "$target_cpu_default2" = ""
3250 target_cpu_default2="MASK_GAS"
3252 target_cpu_default2="${target_cpu_default2}|MASK_GAS"
3257 case "x$with_cpu" in
3260 target_cpu_default2="TARGET_CPU_generic"
3263 # Distinguish cores, and major variants
3264 # arm7m doesn't exist, but D & I don't affect code
3265 xarm[23678] | xarm250 | xarm[67][01]0 \
3266 | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \
3267 | xarm7100 | xarm7500 | xarm7500fe | xarm810 \
3268 | xstrongarm | xstrongarm110)
3269 target_cpu_default2="TARGET_CPU_$with_cpu"
3273 echo "--with-cpu must be passed a value" 1>&2
3278 if test x$pass2done = xyes
3280 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3287 mips*-*-ecoff* | mips*-*-elf*)
3288 if test x$gas = xyes
3290 if test x$gnu_ld = xyes
3292 target_cpu_default2=20
3294 target_cpu_default2=16
3299 if test x$gas = xyes
3301 target_cpu_default2=16
3304 powerpc*-*-* | rs6000-*-*)
3305 case "x$with_cpu" in
3309 xcommon | xpower | xpower2 | xpowerpc | xrios \
3310 | xrios1 | xrios2 | xrsc | xrsc1 \
3311 | x601 | x602 | x603 | x603e | x604 | x604e | x620 \
3312 | x403 | x505 | x801 | x821 | x823 | x860)
3313 target_cpu_default2="\"$with_cpu\""
3317 echo "--with-cpu must be passed a value" 1>&2
3322 if test x$pass2done = xyes
3324 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3331 case ".$with_cpu" in
3333 target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`"
3335 .supersparc | .ultrasparc | .v7 | .v8 | .v9)
3336 target_cpu_default2="TARGET_CPU_$with_cpu"
3339 if test x$pass2done = xyes
3341 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3349 if test "$target_cpu_default2" != ""
3351 if test "$target_cpu_default" != ""
3353 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
3355 target_cpu_default=$target_cpu_default2
3359 # No need for collect2 if we have the GNU linker.
3360 # Actually, there is now; GNU ld doesn't handle the EH info or
3361 # collecting for shared libraries.
3368 # Save data on machine being used to compile GCC in build_xm_file.
3369 # Save data on host machine in vars host_xm_file and host_xmake_file.
3370 if test x$pass1done = x
3372 if test x"$xm_file" = x
3373 then build_xm_file=$cpu_type/xm-$cpu_type.h
3374 else build_xm_file=$xm_file
3376 build_xm_defines=$xm_defines
3377 build_install_headers_dir=$install_headers_dir
3378 build_exeext=$exeext
3381 if test x$pass2done = x
3383 if test x"$xm_file" = x
3384 then host_xm_file=$cpu_type/xm-$cpu_type.h
3385 else host_xm_file=$xm_file
3387 host_xm_defines=$xm_defines
3388 if test x"$xmake_file" = x
3389 then xmake_file=$cpu_type/x-$cpu_type
3391 host_xmake_file="$xmake_file"
3392 host_truncate_target=$truncate_target
3393 host_extra_gcc_objs=$extra_gcc_objs
3394 host_extra_objs=$extra_host_objs
3401 extra_objs="${host_extra_objs} ${extra_objs}"
3403 # Default the target-machine variables that were not explicitly set.
3404 if test x"$tm_file" = x
3405 then tm_file=$cpu_type/$cpu_type.h; fi
3407 if test x$extra_headers = x
3408 then extra_headers=; fi
3410 if test x"$xm_file" = x
3411 then xm_file=$cpu_type/xm-$cpu_type.h; fi
3413 if test x$md_file = x
3414 then md_file=$cpu_type/$cpu_type.md; fi
3416 if test x$out_file = x
3417 then out_file=$cpu_type/$cpu_type.c; fi
3419 if test x"$tmake_file" = x
3420 then tmake_file=$cpu_type/t-$cpu_type
3423 if test x$float_format = x
3424 then float_format=i64
3427 if test x$enable_haifa = x
3430 alpha*-* | hppa*-* | powerpc*-* | rs6000-* | *sparc*-* | m32r*-*)
3435 # Say what files are being used for the output code and MD file.
3436 echo "Using \`$srcdir/config/$out_file' to output insns."
3437 echo "Using \`$srcdir/config/$md_file' as machine description file."
3440 for f in $tm_file; do
3443 if test $count = ax; then
3444 echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
3446 echo "Using the following target machine macro files:"
3447 for f in $tm_file; do
3448 echo " $srcdir/config/$f"
3453 for f in $host_xm_file; do
3456 if test $count = ax; then
3457 echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
3459 echo "Using the following host machine macro files:"
3460 for f in $host_xm_file; do
3461 echo " $srcdir/config/$f"
3465 if test "$host_xm_file" != "$build_xm_file"; then
3467 for f in $build_xm_file; do
3470 if test $count = ax; then
3471 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
3473 echo "Using the following build machine macro files:"
3474 for f in $build_xm_file; do
3475 echo " $srcdir/config/$f"
3480 if test x$thread_file = x; then
3481 if test x$target_thread_file != x; then
3482 thread_file=$target_thread_file
3484 thread_file='single'
3488 # Set up the header files.
3489 # $links is the list of header files to create.
3490 # $vars is the list of shell variables with file names to include.
3491 # auto-host.h is the file containing items generated by autoconf and is
3492 # the first file included by config.h.
3494 host_xm_file="auto-host.h gansidecl.h ${host_xm_file}"
3496 # If host=build, it is correct to have hconfig include auto-host.h
3497 # as well. If host!=build, we are in error and need to do more
3498 # work to find out the build config parameters.
3499 if test x$host = x$build
3501 build_xm_file="auto-host.h gansidecl.h ${build_xm_file}"
3503 # We create a subdir, then run autoconf in the subdir.
3504 # To prevent recursion we set host and build for the new
3505 # invocation of configure to the build for this invocation
3512 /*) realsrcdir=${srcdir};;
3513 *) realsrcdir=../${srcdir};;
3515 CC=${CC_FOR_BUILD} ${realsrcdir}/configure \
3516 --target=$target --host=$build --build=$build
3518 # We just finished tests for the build machine, so rename
3519 # the file auto-build.h in the gcc directory.
3520 mv auto-host.h ../auto-build.h
3523 build_xm_file="auto-build.h gansidecl.h ${build_xm_file}"
3526 xm_file="gansidecl.h ${xm_file}"
3527 tm_file="gansidecl.h ${tm_file}"
3529 vars="host_xm_file tm_file xm_file build_xm_file"
3530 links="config.h tm.h tconfig.h hconfig.h"
3531 defines="host_xm_defines null_defines xm_defines build_xm_defines"
3534 if test -f config.status; then mv -f config.status config.bak; fi
3537 while test -n "$vars"
3539 set $vars; var=$1; shift; vars=$*
3540 set $links; link=$1; shift; links=$*
3541 set $defines; define=$1; shift; defines=$*
3545 # Define TARGET_CPU_DEFAULT if the system wants one.
3546 # This substitutes for lots of *.h files.
3547 if test "$target_cpu_default" != "" -a $link = tm.h
3549 echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link
3552 for file in `eval echo '$'$var`; do
3553 echo "#include \"$file\"" >>$link
3556 for def in `eval echo '$'$define`; do
3557 echo "#ifndef $def" >>$link
3558 echo "#define $def" >>$link
3559 echo "#endif" >>$link
3563 # Truncate the target if necessary
3564 if test x$host_truncate_target != x; then
3565 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
3568 # Get the version trigger filename from the toplevel
3569 if test "${with_gcc_version_trigger+set}" = set; then
3570 gcc_version_trigger=$with_gcc_version_trigger
3572 gcc_version_trigger=${srcdir}/version.c
3575 gcc_version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < ${gcc_version_trigger}`
3578 # Get an absolute path to the GCC top-level source directory
3584 # Conditionalize the makefile for this host machine.
3585 # Make-host contains the concatenation of all host makefile fragments
3586 # [there can be more than one]. This file is built by configure.frag.
3587 host_overrides=Make-host
3588 dep_host_xmake_file=
3589 for f in .. ${host_xmake_file}
3591 if test -f ${srcdir}/config/$f
3593 dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f"
3597 # Conditionalize the makefile for this target machine.
3598 # Make-target contains the concatenation of all host makefile fragments
3599 # [there can be more than one]. This file is built by configure.frag.
3600 target_overrides=Make-target
3602 for f in .. ${tmake_file}
3604 if test -f ${srcdir}/config/$f
3606 dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f"
3610 # If the host doesn't support symlinks, modify CC in
3611 # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works.
3612 # Otherwise, we can use "CC=$(CC)".
3614 if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null
3616 cc_set_by_configure="\$(CC)"
3617 stage_prefix_set_by_configure="\$(STAGE_PREFIX)"
3620 if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null
3622 symbolic_link="cp -p"
3626 cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`"
3627 stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`"
3631 out_object_file=`basename $out_file .c`.o
3634 for f in $tm_file; do
3635 if test $f != "gansidecl.h" ; then
3636 tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
3638 tm_file_list="${tm_file_list} $f"
3643 for f in $host_xm_file; do
3644 if test $f != "auto-host.h" -a $f != "gansidecl.h" ; then
3645 host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f"
3647 host_xm_file_list="${host_xm_file_list} $f"
3652 for f in $build_xm_file; do
3653 if test $f != "auto-build.h" -a $f != "auto-host.h" -a $f != "gansidecl.h" ; then
3654 build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f"
3656 build_xm_file_list="${build_xm_file_list} $f"
3660 # Define macro CROSS_COMPILE in compilation
3661 # if this is a cross-compiler.
3662 # Also use all.cross instead of all.internal
3663 # and add cross-make to Makefile.
3664 cross_overrides="/dev/null"
3665 if test x$host != x$target
3667 cross_defines="CROSS=-DCROSS_COMPILE"
3668 cross_overrides="${topdir}/cross-make"
3671 # When building gcc with a cross-compiler, we need to fix a few things.
3672 # This must come after cross-make as we want all.build to override
3674 build_overrides="/dev/null"
3675 if test x$build != x$host
3677 build_overrides="${topdir}/build-make"
3680 # Expand extra_headers to include complete path.
3681 # This substitutes for lots of t-* files.
3683 if test "x$extra_headers" = x
3686 # Prepend ${srcdir}/ginclude/ to every entry in extra_headers.
3687 for file in $extra_headers;
3689 extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}"
3693 if test x$use_collect2 = xno; then
3697 # Add a definition of USE_COLLECT2 if system wants one.
3698 # Also tell toplev.c what to do.
3699 # This substitutes for lots of t-* files.
3700 if test x$use_collect2 = x
3705 will_use_collect2="collect2"
3706 maybe_use_collect2="-DUSE_COLLECT2"
3710 # Set MD_DEPS if the real md file is in md.pre-cpp.
3711 # Set MD_CPP to the cpp to pass the md file through. Md files use ';'
3712 # for line oriented comments, so we must always use a GNU cpp. If
3713 # building gcc with a cross compiler, use the cross compiler just
3714 # built. Otherwise, we can use the cpp just built.
3716 if test "x$md_cppflags" = x
3718 md_file_sub=$srcdir/config/$md_file
3723 # If we have gas in the build tree, make a link to it.
3724 if test -f ../gas/Makefile; then
3725 rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null
3728 # If we have nm in the build tree, make a link to it.
3729 if test -f ../binutils/Makefile; then
3730 rm -f nm; $symbolic_link ../binutils/nm-new$host_exeext nm$host_exeext 2>/dev/null
3733 # If we have ld in the build tree, make a link to it.
3734 if test -f ../ld/Makefile; then
3735 # if test x$use_collect2 = x; then
3736 # rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null
3738 rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null
3742 # Figure out what assembler alignment features are present.
3743 AC_MSG_CHECKING(assembler alignment features)
3745 gcc_cv_as_alignment_features=
3746 gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas
3747 if test -x "$DEFAULT_ASSEMBLER"; then
3748 gcc_cv_as="$DEFAULT_ASSEMBLER"
3749 elif test -x "$AS"; then
3751 elif test -x as$host_exeext; then
3752 # Build using assembler in the current directory.
3753 gcc_cv_as=./as$host_exeext
3754 elif test -f $gcc_cv_as_gas_srcdir/configure.in -a -f ../gas/Makefile; then
3755 # Single tree build which includes gas.
3756 for f in $gcc_cv_as_gas_srcdir/configure $gcc_cv_as_gas_srcdir/configure.in $gcc_cv_as_gas_srcdir/Makefile.in
3759 gcc_cv_gas_version=`grep '^VERSION=[0-9]*\.[0-9]*' $f`
3761 if test x$gcc_cv_gas_version != x; then
3766 gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
3767 gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
3769 if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
3770 # Gas version 2.6 and later support for .balign and .p2align.
3771 # bytes to skip when using .p2align.
3772 if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 6 -o "$gcc_cv_gas_major_version" -gt 2; then
3773 gcc_cv_as_alignment_features=".balign and .p2align"
3774 AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
3776 # Gas version 2.8 and later support specifying the maximum
3777 # bytes to skip when using .p2align.
3778 if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 8 -o "$gcc_cv_gas_major_version" -gt 2; then
3779 gcc_cv_as_alignment_features=".p2align including maximum skip"
3780 AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
3783 elif test x$host = x$target; then
3785 gcc_cv_as=as$host_exeext
3787 if test x$gcc_cv_as != x; then
3788 # Check if we have .balign and .p2align
3789 echo ".balign 4" > conftest.s
3790 echo ".p2align 2" >> conftest.s
3791 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3792 gcc_cv_as_alignment_features=".balign and .p2align"
3793 AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
3795 rm -f conftest.s conftest.o
3796 # Check if specifying the maximum bytes to skip when
3797 # using .p2align is supported.
3798 echo ".p2align 4,,7" > conftest.s
3799 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3800 gcc_cv_as_alignment_features=".p2align including maximum skip"
3801 AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
3803 rm -f conftest.s conftest.o
3805 AC_MSG_RESULT($gcc_cv_as_alignment_features)
3807 AC_MSG_CHECKING(assembler subsection support)
3808 gcc_cv_as_subsections=
3809 if test x$gcc_cv_as != x; then
3810 # Check if we have .subsection
3811 echo ".subsection 1" > conftest.s
3812 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3813 gcc_cv_as_subsections=".subsection"
3814 if test -x nm$host_exeext; then
3815 gcc_cv_nm=./nm$host_exeext
3816 elif test x$host = x$target; then
3818 gcc_cv_nm=nm$host_exeext
3820 if test x$gcc_cv_nm != x; then
3821 cat > conftest.s <<EOF
3822 conftest_label1: .word 0
3824 conftest_label2: .word 0
3827 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3828 $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1
3829 $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2
3830 if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1; then
3833 gcc_cv_as_subsections="working .subsection -1"
3834 AC_DEFINE(HAVE_GAS_SUBSECTION_ORDERING)
3839 rm -f conftest.s conftest.o conftest.nm1 conftest.nm2
3841 AC_MSG_RESULT($gcc_cv_as_subsections)
3843 # Figure out what language subdirectories are present.
3844 # Look if the user specified --enable-languages="..."; if not, use
3845 # the environment variable $LANGUAGES if defined. $LANGUAGES might
3847 if test x"${enable_languages+set}" != xset; then
3848 if test x"${LANGUAGES+set}" = xset; then
3849 enable_languages="`echo ${LANGUAGES} | tr ' ' ','`"
3851 enable_languages=all
3855 for lang in ${srcdir}/*/config-lang.in ..
3859 # The odd quoting in the next line works around
3860 # an apparent bug in bash 1.12 on linux.
3862 ${srcdir}/[*]/config-lang.in) ;;
3864 lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
3865 if test "x$lang_alias" = x
3867 echo "$lang doesn't set \$language." 1>&2
3870 if test x"${enable_languages}" = xall; then
3873 case "${enable_languages}" in
3874 ${lang_alias} | "${lang_alias},"* | *",${lang_alias},"* | *",${lang_alias}" )
3882 if test x"${add_this_lang}" = xyes; then
3884 ${srcdir}/ada/config-lang.in)
3885 if test x$gnat = xyes ; then
3886 subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
3890 subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
3899 # Make gthr-default.h if we have a thread file.
3901 if test $thread_file != single; then
3902 rm -f gthr-default.h
3903 echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h
3904 gthread_flags=-DHAVE_GTHR_DEFAULT
3906 AC_SUBST(gthread_flags)
3908 # Make empty files to contain the specs and options for each language.
3909 # Then add #include lines to for a compiler that has specs and/or options.
3914 rm -f specs.h options.h gencheck.h
3915 touch specs.h options.h gencheck.h
3916 for subdir in . $subdirs
3918 if test -f $srcdir/$subdir/lang-specs.h; then
3919 echo "#include \"$subdir/lang-specs.h\"" >>specs.h
3920 lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h"
3922 if test -f $srcdir/$subdir/lang-options.h; then
3923 echo "#include \"$subdir/lang-options.h\"" >>options.h
3924 lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h"
3926 if test -f $srcdir/$subdir/$subdir-tree.def; then
3927 echo "#include \"$subdir/$subdir-tree.def\"" >>gencheck.h
3928 lang_tree_files="$lang_tree_files $srcdir/$subdir/$subdir-tree.def"
3932 # These (without "all_") are set in each config-lang.in.
3933 # `language' must be a single word so is spelled singularly.
3939 all_outputs=Makefile
3940 # List of language makefile fragments.
3945 # Add the language fragments.
3946 # Languages are added via two mechanisms. Some information must be
3947 # recorded in makefile variables, these are defined in config-lang.in.
3948 # We accumulate them and plug them into the main Makefile.
3949 # The other mechanism is a set of hooks for each of the main targets
3950 # like `clean', `install', etc.
3952 language_fragments="Make-lang"
3953 language_hooks="Make-hooks"
3956 for s in .. $subdirs
3968 . ${srcdir}/$s/config-lang.in
3969 if test "x$language" = x
3971 echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2
3974 all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in ${srcdir}/$s/Makefile.in"
3975 all_languages="$all_languages $language"
3976 if test "x$boot_language" = xyes
3978 all_boot_languages="$all_boot_languages $language"
3980 all_compilers="$all_compilers $compilers"
3981 all_stagestuff="$all_stagestuff $stagestuff"
3982 all_diff_excludes="$all_diff_excludes $diff_excludes"
3983 all_headers="$all_headers $headers"
3984 all_outputs="$all_outputs $outputs"
3985 if test x$outputs = x
3987 oldstyle_subdirs="$oldstyle_subdirs $s"
3989 all_lib2funcs="$all_lib2funcs $lib2funcs"
3993 # Since we can't use `::' targets, we link each language in
3994 # with a set of hooks, reached indirectly via lang.${target}.
3998 target_list="all.build all.cross start.encap rest.encap \
4000 install-normal install-common install-info install-man \
4002 mostlyclean clean distclean extraclean maintainer-clean \
4003 stage1 stage2 stage3 stage4"
4004 for t in $target_list
4007 for l in .. $all_languages
4009 if test $l != ".."; then
4013 echo "lang.$t: $x" >> Make-hooks
4016 # If we're not building in srcdir, create .gdbinit.
4018 if test ! -f Makefile.in; then
4019 echo "dir ." > .gdbinit
4020 echo "dir ${srcdir}" >> .gdbinit
4021 if test x$gdb_needs_out_file_path = xyes
4023 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
4025 if test "x$subdirs" != x; then
4028 echo "dir ${srcdir}/$s" >> .gdbinit
4031 echo "source ${srcdir}/.gdbinit" >> .gdbinit
4034 # Define variables host_canonical and build_canonical
4035 # because some Cygnus local changes in the Makefile depend on them.
4036 build_canonical=${build}
4037 host_canonical=${host}
4039 if test "${host}" != "${target}" ; then
4040 target_subdir=${target}/
4042 AC_SUBST(build_canonical)
4043 AC_SUBST(host_canonical)
4044 AC_SUBST(target_subdir)
4046 # If this is using newlib, then define inhibit_libc in
4047 # LIBGCC2_CFLAGS. This will cause __eprintf to be left out of
4048 # libgcc.a, but that's OK because newib should have its own version of
4051 if test x$with_newlib = xyes; then
4052 inhibit_libc=-Dinhibit_libc
4054 AC_SUBST(inhibit_libc)
4056 # Override SCHED_OBJ and SCHED_CFLAGS to enable the Haifa scheduler.
4059 if test x$enable_haifa = xyes; then
4060 echo "Using the Haifa scheduler."
4062 sched_cflags=-DHAIFA
4064 AC_SUBST(sched_prefix)
4065 AC_SUBST(sched_cflags)
4066 if test x$enable_haifa != x; then
4067 # Explicitly remove files that need to be recompiled for the Haifa scheduler.
4068 for x in genattrtab.o toplev.o loop.o unroll.o *sched.o; do
4076 # Warn if using init_priority.
4077 AC_MSG_CHECKING(whether to enable init_priority by default)
4078 if test x$enable_init_priority != xyes; then
4079 enable_init_priority=no
4081 AC_MSG_RESULT($enable_init_priority)
4083 # Nothing to do for FLOAT_H, float_format already handled.
4087 # Process the language and host/target makefile fragments.
4088 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
4090 # Substitute configuration variables
4092 AC_SUBST(all_languages)
4093 AC_SUBST(all_boot_languages)
4094 AC_SUBST(all_compilers)
4095 AC_SUBST(all_lang_makefiles)
4096 AC_SUBST(all_stagestuff)
4097 AC_SUBST(all_diff_excludes)
4098 AC_SUBST(all_lib2funcs)
4099 AC_SUBST(all_headers)
4101 AC_SUBST(extra_passes)
4102 AC_SUBST(extra_programs)
4103 AC_SUBST(extra_parts)
4104 AC_SUBST(extra_c_objs)
4105 AC_SUBST(extra_cxx_objs)
4106 AC_SUBST(extra_cpp_objs)
4107 AC_SUBST(extra_c_flags)
4108 AC_SUBST(extra_objs)
4109 AC_SUBST(host_extra_gcc_objs)
4110 AC_SUBST(extra_headers_list)
4111 AC_SUBST(dep_host_xmake_file)
4112 AC_SUBST(dep_tmake_file)
4114 AC_SUBST(out_object_file)
4116 AC_SUBST(tm_file_list)
4117 AC_SUBST(build_xm_file_list)
4118 AC_SUBST(host_xm_file_list)
4119 AC_SUBST(lang_specs_files)
4120 AC_SUBST(lang_options_files)
4121 AC_SUBST(lang_tree_files)
4122 AC_SUBST(thread_file)
4123 AC_SUBST(objc_boehm_gc)
4125 AC_SUBST(gcc_version)
4126 AC_SUBST(gcc_version_trigger)
4127 AC_SUBST(local_prefix)
4128 AC_SUBST(gxx_include_dir)
4129 AC_SUBST(fixincludes)
4130 AC_SUBST(build_install_headers_dir)
4131 AC_SUBST(build_exeext)
4132 AC_SUBST(host_exeext)
4133 AC_SUBST(float_format)
4134 AC_SUBST(will_use_collect2)
4135 AC_SUBST(maybe_use_collect2)
4136 AC_SUBST(cc_set_by_configure)
4137 AC_SUBST(stage_prefix_set_by_configure)
4139 AC_SUBST(symbolic_link)
4141 AC_SUBST_FILE(target_overrides)
4142 AC_SUBST_FILE(host_overrides)
4143 AC_SUBST(cross_defines)
4144 AC_SUBST_FILE(cross_overrides)
4145 AC_SUBST_FILE(build_overrides)
4146 AC_SUBST_FILE(language_fragments)
4147 AC_SUBST_FILE(language_hooks)
4149 # Echo that links are built
4150 if test x$host = x$target
4158 if test x$host != x$build
4160 str3=" on a $build system"
4163 if test "x$str2" != x || test "x$str3" != x
4168 echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2
4170 if test "x$str2" != x || test "x$str3" != x
4172 echo " ${str2}${str3}." 1>&2
4175 # Truncate the target if necessary
4176 if test x$host_truncate_target != x; then
4177 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
4180 # Configure the subdirectories
4181 # AC_CONFIG_SUBDIRS($subdirs)
4183 # Create the Makefile
4184 # and configure language subdirectories
4185 AC_OUTPUT($all_outputs,
4187 . $srcdir/configure.lang
4188 case x$CONFIG_HEADERS in
4189 xauto-host.h:config.in)
4192 # If the host supports symlinks, point stage[1234] at ../stage[1234] so
4193 # bootstrapping and the installation procedure can still use
4194 # CC="stage1/xgcc -Bstage1/". If the host doesn't support symlinks,
4195 # FLAGS_TO_PASS has been modified to solve the problem there.
4196 # This is virtually a duplicate of what happens in configure.lang; we do
4197 # an extra check to make sure this only happens if ln -s can be used.
4198 if test "$symbolic_link" = "ln -s"; then
4199 for d in .. ${subdirs} ; do
4200 if test $d != ..; then
4203 for t in stage1 stage2 stage3 stage4 include
4206 $symbolic_link ../$t $t 2>/dev/null
4217 target_alias='${target_alias}'
4219 subdirs='${subdirs}'
4220 oldstyle_subdirs='${oldstyle_subdirs}'
4221 symbolic_link='${symbolic_link}'
4222 program_transform_set='${program_transform_set}'
4223 program_transform_name='${program_transform_name}'
4224 dep_host_xmake_file='${dep_host_xmake_file}'
4225 host_xmake_file='${host_xmake_file}'
4226 dep_tmake_file='${dep_tmake_file}'
4227 tmake_file='${tmake_file}'
4228 thread_file='${thread_file}'
4229 gcc_version='${gcc_version}'
4230 gcc_version_trigger='${gcc_version_trigger}'
4231 local_prefix='${local_prefix}'
4232 build_install_headers_dir='${build_install_headers_dir}'
4233 build_exeext='${build_exeext}'
4234 host_exeext='${host_exeext}'
4235 out_file='${out_file}'
4236 gdb_needs_out_file_path='${gdb_needs_out_file_path}'
4237 SET_MAKE='${SET_MAKE}'
4238 target_list='${target_list}'
4239 target_overrides='${target_overrides}'
4240 host_overrides='${host_overrides}'
4241 cross_defines='${cross_defines}'
4242 cross_overrides='${cross_overrides}'
4243 build_overrides='${build_overrides}'