1 # configure.in for GNU CC
2 # Process this file with autoconf to generate a configuration script.
4 # Copyright (C) 1997, 1998, 1999, 2000 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 gcc. 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 gcc. 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 $DEFAULT_LINKER -v < /dev/null 2>&1 | grep GNU > /dev/null; 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 $DEFAULT_ASSEMBLER -v < /dev/null 2>&1 | grep GNU > /dev/null; 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
152 # Don't set gcc_gxx_include_dir to gxx_include_dir since that's only
153 # passed in by the toplevel make and thus we'd get different behavior
154 # depending on where we built the sources.
156 # Specify the g++ header file directory
157 AC_ARG_WITH(gxx-include-dir,
158 [ --with-gxx-include-dir=DIR
159 specifies directory to put g++ header files.],
160 [case "${withval}" in
161 yes) AC_MSG_ERROR(bad value ${withval} given for g++ include directory) ;;
163 *) gcc_gxx_include_dir=$with_gxx_include_dir ;;
166 if test x${gcc_gxx_include_dir} = x; then
167 if test x${enable_version_specific_runtime_libs} = xyes; then
168 gcc_gxx_include_dir='${libsubdir}/include/g++'
170 topsrcdir=${srcdir}/.. . ${srcdir}/../config.if
171 changequote(<<, >>)dnl
172 gcc_gxx_include_dir="\$(libsubdir)/\$(unlibsubdir)/..\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/[^/]*|/..|g'\`/include/g++"-${libstdcxx_interface}
177 # Enable expensive internal checks
178 AC_ARG_ENABLE(checking,
179 [ --enable-checking[=LIST]
180 enable expensive run-time checks. With LIST,
181 enable only specific categories of checks.
182 Categories are: misc,tree,rtl,gc,gcac; default
184 [case "${enableval}" in
185 yes) AC_DEFINE(ENABLE_CHECKING)
186 AC_DEFINE(ENABLE_TREE_CHECKING)
187 AC_DEFINE(ENABLE_RTL_CHECKING) ;;
189 *) ac_save_IFS="$IFS" IFS="$IFS,"
190 set fnord $enableval; shift
195 misc) AC_DEFINE(ENABLE_CHECKING) ;;
196 tree) AC_DEFINE(ENABLE_TREE_CHECKING) ;;
197 rtl) AC_DEFINE(ENABLE_RTL_CHECKING) ;;
198 gc) AC_DEFINE(ENABLE_GC_CHECKING) ;;
199 gcac) AC_DEFINE(ENABLE_GC_ALWAYS_COLLECT) ;;
200 *) AC_MSG_ERROR(unknown check category $check) ;;
207 [ --disable-cpp don't provide a user-visible C preprocessor.],
208 [], [enable_cpp=yes])
210 AC_ARG_WITH(cpp_install_dir,
211 [ --with-cpp-install-dir=DIR
212 install the user visible C preprocessor in DIR
213 (relative to PREFIX) as well as PREFIX/bin.],
214 [if test x$withval = xyes; then
215 AC_MSG_ERROR([option --with-cpp-install-dir requires an argument])
216 elif test x$withval != xno; then
217 cpp_install_dir=$withval
220 # Use cpplib+cppmain for the preprocessor, but don't link it with the compiler.
222 AC_ARG_ENABLE(cpplib,
223 [ --enable-cpplib use cpplib for the C preprocessor.],
224 if test x$enable_cpplib != xno; then
228 # Link cpplib into the compiler proper, for C/C++/ObjC.
229 AC_ARG_ENABLE(c-cpplib,
230 [ --enable-c-cpplib link cpplib directly into C and C++ compilers
231 (EXPERIMENTAL) (implies --enable-cpplib).],
232 if test x$enable_c_cpplib != xno; then
233 extra_c_objs="${extra_c_objs} libcpp.a"
234 extra_cxx_objs="${extra_cxx_objs} ../libcpp.a"
235 extra_c_flags="${extra_c_flags} -DUSE_CPPLIB=1"
239 # Disable fast fixincludes
240 AC_ARG_ENABLE(fast-fixincludes,
241 [ --disable-fast-fixincludes
242 Disable the new fast fixincludes.
243 Run the old fixincludes script unconditionally],
244 if test x$enable_fast_fixincludes = xno ; then
245 cp $srcdir/fixincludes ./fixinc.sh
248 # Enable Multibyte Characters for C/C++
249 AC_ARG_ENABLE(c-mbchar,
250 [ --enable-c-mbchar Enable multibyte characters for C and C++.],
251 if test x$enable_c_mbchar != xno; then
252 extra_c_flags="${extra_c_flags} -DMULTIBYTE_CHARS=1"
256 # Pass with no value to take the default
257 # Pass with a value to specify a thread package
258 AC_ARG_ENABLE(threads,
259 [ --enable-threads enable thread usage for target GCC.
260 --enable-threads=LIB use LIB thread package for target GCC.],
261 if test x$enable_threads = xno; then
266 enable_threads_flag=$enable_threads
267 # Check if a valid thread package
268 case x${enable_threads_flag} in
271 target_thread_file='single'
275 target_thread_file=''
277 xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \
278 xsolaris | xwin32 | xdce | xvxworks)
279 target_thread_file=$enable_threads_flag
282 echo "$enable_threads is an unknown thread package" 1>&2
287 AC_ARG_ENABLE(objc-gc,
288 [ --enable-objc-gc enable the use of Boehm's garbage collector with
289 the GNU Objective-C runtime.],
290 if test x$enable_objc_gc = xno; then
298 [ --enable-dwarf2 enable DWARF2 debugging as default.],
299 dwarf2="$with_dwarf2",
302 # Determine the host, build, and target systems
305 # Find the native compiler
309 # If the native compiler is GCC, we can enable warnings even in stage1.
310 # That's useful for people building cross-compilers, or just running a
312 if test "x$GCC" = "xyes"; then
313 stage1_warn_cflags='$(WARN_CFLAGS)'
315 stage1_warn_cflags=""
317 AC_SUBST(stage1_warn_cflags)
321 AC_MSG_CHECKING([whether a default assembler was specified])
322 if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then
323 if test x"$gas_flag" = x"no"; then
324 AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER)])
326 AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER - GNU as)])
332 AC_MSG_CHECKING([whether a default linker was specified])
333 if test x"${DEFAULT_LINKER+set}" = x"set"; then
334 if test x"$gnu_ld_flag" = x"no"; then
335 AC_MSG_RESULT([yes ($DEFAULT_LINKER)])
337 AC_MSG_RESULT([yes ($DEFAULT_LINKER - GNU ld)])
343 # Find some useful tools
357 AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h \
358 fcntl.h unistd.h stab.h sys/file.h sys/time.h \
359 sys/resource.h sys/param.h sys/times.h sys/stat.h \
362 # Check for thread headers.
363 AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=])
364 AC_CHECK_HEADER(pthread.h, [have_pthread_h=yes], [have_pthread_h=])
366 # See if GNAT has been installed
367 AC_CHECK_PROG(gnat, gnatbind, yes, no)
369 # See if the stage1 system preprocessor understands the ANSI C
370 # preprocessor stringification operator.
373 # Use <inttypes.h> only if it exists,
374 # doesn't clash with <sys/types.h>, and declares intmax_t.
375 AC_MSG_CHECKING(for inttypes.h)
376 AC_CACHE_VAL(gcc_cv_header_inttypes_h,
378 [#include <sys/types.h>
379 #include <inttypes.h>],
381 [gcc_cv_header_inttypes_h=yes],
382 gcc_cv_header_inttypes_h=no)])
383 AC_MSG_RESULT($gcc_cv_header_inttypes_h)
384 if test $gcc_cv_header_inttypes_h = yes; then
385 AC_DEFINE(HAVE_INTTYPES_H)
388 AC_CHECK_FUNCS(strtoul bsearch strerror putenv popen bcopy bzero bcmp \
389 index rindex strchr strrchr kill getrlimit setrlimit atoll atoq \
390 sysconf isascii gettimeofday strsignal putc_unlocked fputc_unlocked \
391 fputs_unlocked getrusage valloc)
393 # Make sure wchar_t is available
394 #AC_CHECK_TYPE(wchar_t, unsigned int)
396 GCC_FUNC_VFPRINTF_DOPRNT
401 # Under some versions of uwin, vfork is notoriously buggy and the test
402 # can hang configure; on other versions, vfork exists just as a stub.
403 # FIXME: This should be removed once vfork in uwin's runtime is fixed.
404 ac_cv_func_vfork_works=no
410 GCC_NEED_DECLARATIONS(bcopy bzero bcmp \
411 index rindex getenv atol sbrk abort atof strerror getcwd getwd \
412 strsignal putc_unlocked fputs_unlocked strstr)
414 GCC_NEED_DECLARATIONS(malloc realloc calloc free, [
420 GCC_NEED_DECLARATIONS(getrlimit setrlimit getrusage, [
421 #include <sys/types.h>
422 #ifdef HAVE_SYS_RESOURCE_H
423 #include <sys/resource.h>
427 # mkdir takes a single argument on some systems.
428 GCC_FUNC_MKDIR_TAKES_ONE_ARG
438 build_install_headers_dir=install-headers-tar
443 host_truncate_target=
446 # Decode the host machine, then the target machine.
447 # For the host machine, we save the xm_file variable as host_xm_file;
448 # then we decode the target machine and forget everything else
449 # that came from the host machine.
450 for machine in $build $host $target; do
464 # Set this to force installation and use of collect2.
466 # Set this to override the default target model.
468 # Set this to control how the header file directory is installed.
469 install_headers_dir=install-headers-tar
470 # Set this to a non-empty list of args to pass to cpp if the target
471 # wants its .md file passed through cpp.
473 # Set this if directory names should be truncated to 14 characters.
475 # Set this if gdb needs a dir command with `dirname $out_file`
476 gdb_needs_out_file_path=
477 # Set this if the build machine requires executables to have a
480 # Set this to control which thread package will be used.
482 # Reinitialize these from the flag values every loop pass, since some
483 # configure entries modify them.
485 gnu_ld="$gnu_ld_flag"
486 enable_threads=$enable_threads_flag
488 # Set default cpu_type, tm_file, tm_p_file and xm_file so it can be
489 # updated in each machine entry.
491 cpu_type=`echo $machine | sed 's/-.*$//'`
530 tm_file=${cpu_type}/${cpu_type}.h
531 xm_file=${cpu_type}/xm-${cpu_type}.h
532 if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-protos.h;
534 tm_p_file=${cpu_type}/${cpu_type}-protos.h;
536 # On a.out targets, we need to use collect2.
543 # Common parts for linux-gnu and openbsd systems
546 xm_defines="HAVE_ATEXIT POSIX BSTRING"
549 tm_file=${cpu_type}/openbsd.h
550 tmake_file="t-libc-ok t-openbsd"
551 # avoid surprises, always provide an xm-openbsd file
552 xm_file=${cpu_type}/xm-openbsd.h
553 # don't depend on processor x-fragments as well
555 if test x$enable_threads = xyes; then
557 tmake_file="${tmake_file} t-openbsd-thread"
563 # Support site-specific machine types.
565 cpu_type=`echo $machine | sed -e 's/-.*//'`
566 rest=`echo $machine | sed -e "s/$cpu_type-//"`
567 xm_file=${cpu_type}/xm-$rest.h
568 tm_file=${cpu_type}/$rest.h
569 if test -f $srcdir/config/${cpu_type}/x-$rest; \
570 then xmake_file=${cpu_type}/x-$rest; \
573 if test -f $srcdir/config/${cpu_type}/t-$rest; \
574 then tmake_file=${cpu_type}/t-$rest; \
580 a29k-*-bsd* | a29k-*-sym1*)
581 tm_file="${tm_file} a29k/unix.h"
583 xmake_file=a29k/x-unix
586 a29k-*-udi | a29k-*-coff)
587 tm_file="${tm_file} dbxcoff.h a29k/udi.h"
588 tmake_file=a29k/t-a29kbare
591 tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h"
592 tmake_file=a29k/t-vx29k
593 extra_parts="crtbegin.o crtend.o"
594 thread_file='vxworks'
596 a29k-*-*) # Default a29k environment.
600 tm_file="${tm_file} alpha/alpha32.h interix.h alpha/alpha-interix.h"
602 # GAS + IEEE_CONFORMANT+IEEE (no inexact);
603 #target_cpu_default="MASK_GAS|MASK_IEEE_CONFORMANT|MASK_IEEE"
605 # GAS + IEEE_CONFORMANT
606 target_cpu_default="MASK_GAS|MASK_IEEE_CONFORMANT"
608 xm_file="alpha/xm-alpha-interix.h xm-interix.h"
609 xmake_file="x-interix alpha/t-pe"
610 tmake_file="alpha/t-interix alpha/t-ieee"
611 if test x$enable_threads = xyes ; then
614 if test x$stabs = xyes ; then
615 tm_file="${tm_file} dbxcoff.h"
617 #prefix='$$INTERIX_ROOT'/usr/contrib
618 #local_prefix='$$INTERIX_ROOT'/usr/contrib
620 alpha*-*-linux-gnuecoff*)
621 tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h"
622 target_cpu_default="MASK_GAS"
623 tmake_file="alpha/t-ieee"
628 alpha*-*-linux-gnulibc1*)
629 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
630 target_cpu_default="MASK_GAS"
631 tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux alpha/t-crtbe alpha/t-ieee"
632 extra_parts="crtbegin.o crtend.o"
635 if test x$enable_threads = xyes; then
640 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
641 target_cpu_default="MASK_GAS"
642 tmake_file="t-linux alpha/t-linux alpha/t-crtbe alpha/t-ieee"
643 extra_parts="crtbegin.o crtend.o"
646 if test x$enable_threads = xyes; then
651 tm_file="${tm_file} alpha/elf.h alpha/netbsd.h alpha/netbsd-elf.h"
652 target_cpu_default="MASK_GAS"
653 tmake_file="alpha/t-crtbe alpha/t-ieee"
654 extra_parts="crtbegin.o crtend.o"
660 # default x-alpha is only appropriate for dec-osf.
661 target_cpu_default="MASK_GAS"
662 tmake_file="alpha/t-ieee"
666 if test x$stabs = xyes
668 tm_file="${tm_file} dbx.h"
670 if test x$gas != xyes
672 extra_passes="mips-tfile mips-tdump"
675 tmake_file="alpha/t-ieee"
678 tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h"
683 tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h"
686 tm_file="${tm_file} alpha/osf.h"
687 # Some versions of OSF4 (specifically X4.0-9 296.7) have
688 # a broken tar, so we use cpio instead.
689 install_headers_dir=install-headers-cpio
692 tm_file="${tm_file} alpha/osf.h"
697 *-*-osf4.0[b-z] | *-*-osf4.[1-9]*)
699 target_cpu_default=MASK_SUPPORT_ARCH
704 tm_file="${tm_file} dbx.h alpha/vxworks.h"
705 tmake_file="alpha/t-ieee"
708 extra_passes="mips-tfile mips-tdump"
711 thread_file='vxworks'
714 tm_file="${tm_file} alpha/alpha32.h alpha/win-nt.h winnt/win-nt.h"
715 xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h"
716 tmake_file="t-libc-ok alpha/t-ieee"
717 xmake_file=winnt/x-winnt
718 extra_host_objs=oldnames.o
719 extra_gcc_objs="spawnv.o oldnames.o"
720 if test x$gnu_ld != xyes
722 extra_programs=ld.exe
724 if test x$enable_threads = xyes; then
730 xm_file="${xm_file} alpha/xm-vms.h"
731 tmake_file="alpha/t-vms alpha/t-ieee"
734 extra_parts="crtinit.o crtfini.o"
736 arm-*-coff* | armel-*-coff*)
738 tmake_file=arm/t-bare
742 tmake_file=arm/t-bare
743 thread_file='vxworks'
746 arm-*-riscix1.[01]*) # Acorn RISC machine (early versions)
748 tm_file=arm/riscix1-1.h
751 arm-*-riscix*) # Acorn RISC machine
754 tm_file=arm/rix-gas.h
758 xmake_file=arm/x-riscix
759 tmake_file=arm/t-riscix
762 arm-semi-aout | armel-semi-aout)
764 tmake_file=arm/t-semi
766 arm-semi-aof | armel-semi-aof)
767 tm_file=arm/semiaof.h
768 tmake_file=arm/t-semiaof
772 tmake_file="t-netbsd arm/t-netbsd"
775 arm*-*-linux-gnuaout*) # ARM GNU/Linux with a.out
778 tm_file=arm/linux-aout.h
779 tmake_file=arm/t-linux
782 arm*-*-linux-gnuoldld*) # ARM GNU/Linux with old ELF linker
783 xm_file=arm/xm-linux.h
785 tm_file="arm/linux-oldld.h arm/linux-elf.h"
788 tm_file="arm/linux-elf26.h $tm_file"
791 tmake_file="t-linux arm/t-linux"
792 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
794 case x${enable_threads} in
795 x | xyes | xpthreads | xposix)
800 arm*-*-linux-gnu*) # ARM GNU/Linux with ELF
801 xm_file=arm/xm-linux.h
803 tm_file="arm/linux-elf.h"
806 tm_file="arm/linux-elf26.h $tm_file"
809 tmake_file="t-linux arm/t-linux"
810 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
812 case x${enable_threads} in
813 x | xyes | xpthreads | xposix)
818 arm*-*-uclinux*) # ARM ucLinux
819 tm_file=arm/uclinux-elf.h
820 tmake_file=arm/t-arm-elf
824 tmake_file=arm/t-bare
827 tm_file=arm/ecos-elf.h
831 tm_file=arm/unknown-elf.h
832 tmake_file=arm/t-arm-elf
835 tm_file=arm/unknown-elf-oabi.h
836 tmake_file=arm/t-arm-elf
843 c1-convex-*) # Convex C1
847 c2-convex-*) # Convex C2
860 target_cpu_default=16
867 clipper-intergraph-clix*)
868 tm_file="${tm_file} svr3.h clipper/clix.h"
869 xm_file=clipper/xm-clix.h
870 xmake_file=clipper/x-clix
871 extra_headers=va-clipper.h
872 extra_parts="crtbegin.o crtend.o"
873 install_headers_dir=install-headers-cpio
881 tm_file="fr30/fr30.h"
882 tmake_file=fr30/t-fr30
883 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
885 # This hasn't been upgraded to GCC 2.
886 # fx80-alliant-*) # Alliant FX/80
892 target_cpu_default="(MASK_PA_11 | MASK_GAS | MASK_JUMP_IN_DELAY)"
893 tm_file="${tm_file} pa/elf.h linux.h pa/pa-linux.h"
894 tmake_file="t-linux pa/t-linux"
895 extra_parts="crtbegin.o crtend.o"
898 if test x$enable_threads = xyes; then
903 target_cpu_default="MASK_PA_11"
904 tmake_file=pa/t-openbsd
907 target_cpu_default="(MASK_JUMP_IN_DELAY | MASK_PORTABLE_RUNTIME | MASK_GAS | MASK_NO_SPACE_REGS | MASK_SOFT_FLOAT)"
908 tm_file="${tm_file} elfos.h pa/elf.h pa/pa-pro-end.h libgloss.h"
909 xm_file=pa/xm-papro.h
913 target_cpu_default="MASK_PA_11"
914 tm_file="${tm_file} pa/som.h pa/pa-osf.h"
918 target_cpu_default="(MASK_JUMP_IN_DELAY | MASK_PORTABLE_RUNTIME | MASK_GAS | MASK_NO_SPACE_REGS | MASK_SOFT_FLOAT)"
919 tm_file="${tm_file} elfos.h pa/elf.h pa/pa-pro-end.h libgloss.h pa/rtems.h"
920 xm_file=pa/xm-papro.h
924 tm_file="${tm_file} pa/som.h pa/pa-osf.h"
928 tm_file="${tm_file} pa/som.h"
929 target_cpu_default="MASK_PA_11"
933 tm_file="${tm_file} pa/som.h"
937 tm_file="pa/pa-oldas.h ${tm_file} pa/som.h pa/pa-hpux7.h"
938 xm_file=pa/xm-pahpux.h
939 xmake_file=pa/x-pa-hpux
942 tm_file="${tm_file} pa/gas.h"
944 install_headers_dir=install-headers-cpio
948 hppa1.0-*-hpux8.0[0-2]*)
950 tm_file="${tm_file} pa/som.h pa/pa-hpux.h"
951 xm_file=pa/xm-pahpux.h
952 xmake_file=pa/x-pa-hpux
955 tm_file="${tm_file} pa/pa-gas.h"
957 tm_file="pa/pa-oldas.h ${tm_file}"
959 install_headers_dir=install-headers-cpio
963 hppa1.1-*-hpux8.0[0-2]*)
965 target_cpu_default="MASK_PA_11"
966 tm_file="${tm_file} pa/som.h pa/pa-hpux.h"
967 xm_file=pa/xm-pahpux.h
968 xmake_file=pa/x-pa-hpux
971 tm_file="${tm_file} pa/pa-gas.h"
973 tm_file="pa/pa-oldas.h ${tm_file}"
975 install_headers_dir=install-headers-cpio
979 target_cpu_default="MASK_PA_11"
980 tm_file="${tm_file} pa/som.h pa/pa-hpux.h"
981 xm_file=pa/xm-pahpux.h
982 xmake_file=pa/x-pa-hpux
985 tm_file="${tm_file} pa/pa-gas.h"
987 install_headers_dir=install-headers-cpio
991 tm_file="${tm_file} pa/som.h pa/pa-hpux.h"
992 xm_file=pa/xm-pahpux.h
993 xmake_file=pa/x-pa-hpux
996 tm_file="${tm_file} pa/pa-gas.h"
998 install_headers_dir=install-headers-cpio
1001 hppa1.1-*-hpux10* | hppa2*-*-hpux10*)
1002 target_cpu_default="MASK_PA_11"
1003 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux10.h"
1004 xm_file=pa/xm-pahpux.h
1005 xmake_file=pa/x-pa-hpux
1007 if test x$gas = xyes
1009 tm_file="${tm_file} pa/pa-gas.h"
1011 if test x$enable_threads = x; then
1012 enable_threads=$have_pthread_h
1014 if test x$enable_threads = xyes; then
1016 tmake_file="${tmake_file} pa/t-dce-thr"
1018 install_headers_dir=install-headers-cpio
1022 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux10.h"
1023 xm_file=pa/xm-pahpux.h
1024 xmake_file=pa/x-pa-hpux
1026 if test x$gas = xyes
1028 tm_file="${tm_file} pa/pa-gas.h"
1030 if test x$enable_threads = x; then
1031 enable_threads=$have_pthread_h
1033 if test x$enable_threads = xyes; then
1035 tmake_file="${tmake_file} pa/t-dce-thr"
1037 install_headers_dir=install-headers-cpio
1040 hppa1.1-*-hpux11* | hppa2*-*-hpux11*)
1041 target_cpu_default="MASK_PA_11"
1042 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux11.h"
1043 xm_file=pa/xm-pahpux.h
1044 xmake_file=pa/x-pa-hpux
1046 if test x$gas = xyes
1048 tm_file="${tm_file} pa/pa-gas.h"
1050 # if test x$enable_threads = x; then
1051 # enable_threads=$have_pthread_h
1053 # if test x$enable_threads = xyes; then
1055 # tmake_file="${tmake_file} pa/t-dce-thr"
1057 install_headers_dir=install-headers-cpio
1061 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux11.h"
1062 xm_file=pa/xm-pahpux.h
1063 xmake_file=pa/x-pa-hpux
1064 if test x$gas = xyes
1066 tm_file="${tm_file} pa/pa-gas.h"
1068 # if test x$enable_threads = x; then
1069 # enable_threads=$have_pthread_h
1071 # if test x$enable_threads = xyes; then
1073 # tmake_file="${tmake_file} pa/t-dce-thr"
1075 install_headers_dir=install-headers-cpio
1078 hppa1.1-*-hpux* | hppa2*-*-hpux*)
1079 target_cpu_default="MASK_PA_11"
1080 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux9.h"
1081 xm_file=pa/xm-pahpux.h
1082 xmake_file=pa/x-pa-hpux
1083 if test x$gas = xyes
1085 tm_file="${tm_file} pa/pa-gas.h"
1087 install_headers_dir=install-headers-cpio
1091 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hpux9.h"
1092 xm_file=pa/xm-pahpux.h
1093 xmake_file=pa/x-pa-hpux
1094 if test x$gas = xyes
1096 tm_file="${tm_file} pa/pa-gas.h"
1098 install_headers_dir=install-headers-cpio
1101 hppa1.1-*-hiux* | hppa2*-*-hiux*)
1102 target_cpu_default="MASK_PA_11"
1103 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hiux.h"
1104 xm_file=pa/xm-pahpux.h
1105 xmake_file=pa/x-pa-hpux
1106 if test x$gas = xyes
1108 tm_file="${tm_file} pa/pa-gas.h"
1110 install_headers_dir=install-headers-cpio
1114 tm_file="${tm_file} pa/som.h pa/pa-hpux.h pa/pa-hiux.h"
1115 xm_file=pa/xm-pahpux.h
1116 xmake_file=pa/x-pa-hpux
1117 if test x$gas = xyes
1119 tm_file="${tm_file} pa/pa-gas.h"
1121 install_headers_dir=install-headers-cpio
1125 tm_file="${tm_file} elfos.h pa/elf.h"
1126 target_cpu_default="MASK_PA_11"
1130 tm_file="${tm_file} pa/pa-mpeix.h"
1131 xm_file=pa/xm-pampeix.h
1132 xmake_file=pa/x-pa-mpeix
1133 echo "You must use gas. Assuming it is already installed."
1134 install_headers_dir=install-headers-tar
1135 fixincludes=Makefile.in
1138 i370-*-opened*) # IBM 360/370/390 Architecture
1139 xm_file=i370/xm-oe.h
1141 xmake_file=i370/x-oe
1142 tmake_file=i370/t-oe
1143 fixincludes=Makefile.in # Headers are wierd, don't mess with
1146 xm_file=i370/xm-mvs.h
1148 tmake_file=i370/t-mvs
1149 fixincludes=Makefile.in # Headers are wierd, don't mess with
1152 xm_file="xm-linux.h i370/xm-linux.h"
1154 tm_file="i370/linux.h ${tm_file}"
1155 tmake_file="t-linux i370/t-linux"
1156 fixincludes=Makefile.in # The headers are ok already.
1157 # broken_install=yes
1158 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1159 # extra_parts="crtbegin.o crtend.o"
1163 if test x$enable_threads = xyes; then
1170 xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h"
1171 tm_file=i386/i386elf.h
1172 tmake_file=i386/t-i386elf
1176 i[34567]86-ibm-aix*) # IBM PS/2 running AIX
1178 if test x$gas = xyes
1180 tm_file=i386/aix386.h
1181 extra_parts="crtbegin.o crtend.o"
1182 tmake_file=i386/t-crtstuff
1184 tm_file=i386/aix386ng.h
1187 xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
1189 xmake_file=i386/x-aix
1192 i[34567]86-ncr-sysv4*) # NCR 3000 - ix86 running system V.4
1194 xm_file="xm-alloca.h ${xm_file}"
1195 xm_defines="USG POSIX SMALL_ARG_MAX"
1196 xmake_file=i386/x-ncr3000
1197 if test x$stabs = xyes -a x$gas = xyes
1199 tm_file=i386/sysv4gdb.h
1201 tm_file=i386/sysv4.h
1203 extra_parts="crtbegin.o crtend.o"
1204 tmake_file=i386/t-crtpic
1210 xm_file=i386/xm-next.h
1211 tmake_file=i386/t-next
1212 xmake_file=i386/x-next
1213 extra_objs=nextstep.o
1214 extra_parts="crtbegin.o crtend.o"
1215 if test x$enable_threads = xyes; then
1220 i[34567]86-sequent-bsd*) # 80386 from Sequent
1223 if test x$gas = xyes
1225 tm_file=i386/seq-gas.h
1227 tm_file=i386/sequent.h
1231 i[34567]86-sequent-ptx1*)
1233 xm_defines="USG SVR3"
1234 xmake_file=i386/x-sysv3
1235 tm_file=i386/seq-sysv3.h
1236 tmake_file=i386/t-crtstuff
1237 extra_parts="crtbegin.o crtend.o"
1238 install_headers_dir=install-headers-cpio
1241 i[34567]86-sequent-ptx2* | i[34567]86-sequent-sysv3*)
1243 xm_defines="USG SVR3"
1244 xmake_file=i386/x-sysv3
1245 tm_file=i386/seq2-sysv3.h
1246 tmake_file=i386/t-crtstuff
1247 extra_parts="crtbegin.o crtend.o"
1248 install_headers_dir=install-headers-cpio
1251 i[34567]86-sequent-ptx4* | i[34567]86-sequent-sysv4*)
1253 xm_file="xm-alloca.h ${xm_file}"
1254 xm_defines="USG POSIX SMALL_ARG_MAX"
1256 tm_file=i386/ptx4-i.h
1258 extra_parts="crtbegin.o crtend.o"
1259 install_headers_dir=install-headers-cpio
1261 i386-sun-sunos*) # Sun i386 roadrunner
1267 i[34567]86-wrs-vxworks*)
1269 tm_file=i386/vxi386.h
1270 tmake_file=i386/t-i386bare
1271 thread_file='vxworks'
1276 tm_file=i386/i386-aout.h
1277 tmake_file=i386/t-i386bare
1280 i[34567]86-*-bsdi* | i[34567]86-*-bsd386*)
1282 tm_file=i386/bsd386.h
1283 # tmake_file=t-libc-ok
1288 tm_file=i386/386bsd.h
1289 # tmake_file=t-libc-ok
1290 # Next line turned off because both 386BSD and BSD/386 use GNU ld.
1294 i[34567]86-*-freebsdelf*)
1296 tm_file="i386/i386.h i386/att.h svr4.h freebsd.h i386/freebsd-elf.h i386/perform.h"
1297 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1298 tmake_file=t-freebsd
1302 case x${enable_threads} in
1303 xyes | xpthreads | xposix)
1305 tmake_file="${tmake_file} t-freebsd-thread"
1310 i[34567]86-*-freebsd*)
1312 tm_file="i386/freebsd.h i386/perform.h"
1313 tmake_file=t-freebsd
1316 i[34567]86-*-netbsd*)
1318 tm_file=i386/netbsd.h
1323 i[34567]86-*-openbsd*)
1325 # we need collect2 until our bug is fixed...
1331 tm_file=i386/i386-coff.h
1332 tmake_file=i386/t-i386bare
1335 i[34567]86-*-isc*) # 80386 running ISC system
1337 xm_file="${xm_file} i386/xm-isc.h"
1338 xm_defines="USG SVR3"
1341 i[34567]86-*-isc[34]*)
1343 xmake_file=i386/x-isc3
1346 xmake_file=i386/x-isc
1349 if test x$gas = xyes -a x$stabs = xyes
1351 tm_file=i386/iscdbx.h
1352 tmake_file=i386/t-svr3dbx
1353 extra_parts="svr3.ifile svr3z.ifile"
1355 tm_file=i386/isccoff.h
1356 tmake_file=i386/t-crtstuff
1357 extra_parts="crtbegin.o crtend.o"
1359 install_headers_dir=install-headers-cpio
1362 i[34567]86-*-linux-gnuoldld*) # Intel 80386's running GNU/Linux
1363 changequote([,])dnl # with a.out format using
1365 xmake_file=x-linux-aout
1366 tmake_file="t-linux-aout i386/t-crtstuff"
1367 tm_file=i386/linux-oldld.h
1372 i[34567]86-*-linux-gnuaout*) # Intel 80386's running GNU/Linux
1373 changequote([,])dnl # with a.out format
1374 xmake_file=x-linux-aout
1375 tmake_file="t-linux-aout i386/t-crtstuff"
1376 tm_file=i386/linux-aout.h
1381 i[34567]86-*-linux-gnulibc1) # Intel 80386's running GNU/Linux
1382 changequote([,])dnl # with ELF format using the
1383 # GNU/Linux C library 5
1385 tm_file=i386/linux.h
1386 tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff"
1387 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1390 if test x$enable_threads = xyes; then
1391 thread_file='single'
1395 i[34567]86-*-linux-gnu*) # Intel 80386's running GNU/Linux
1396 changequote([,])dnl # with ELF format using glibc 2
1397 # aka GNU/Linux C library 6
1399 tm_file=i386/linux.h
1400 tmake_file="t-linux i386/t-crtstuff"
1401 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1404 if test x$enable_threads = xyes; then
1414 i[34567]86-go32-msdos | i[34567]86-*-go32*)
1416 echo "GO32/DJGPP V1.X is no longer supported. Use *-pc-msdosdjgpp for DJGPP V2.X instead."
1420 i[34567]86-pc-msdosdjgpp*)
1422 xm_file=i386/xm-djgpp.h
1423 tm_file=i386/djgpp.h
1424 tmake_file=i386/t-djgpp
1425 xmake_file=i386/x-djgpp
1429 case $host in *pc-msdosdjgpp*)
1435 i[34567]86-moss-msdos* | i[34567]86-*-moss*)
1438 tmake_file=t-libc-ok
1443 i[34567]86-*-lynxos*)
1445 if test x$gas = xyes
1449 tm_file=i386/lynx-ng.h
1451 xm_file=i386/xm-lynx.h
1452 tmake_file=i386/t-i386bare
1459 # tmake_file=t-libc-ok
1463 i[34567]86-*-osfrose*) # 386 using OSF/rose
1465 if test x$elf = xyes
1467 tm_file=i386/osfelf.h
1470 tm_file=i386/osfrose.h
1473 xm_file="i386/xm-osf.h ${xm_file}"
1474 xmake_file=i386/x-osfrose
1475 tmake_file=i386/t-osf
1476 extra_objs=halfpic.o
1479 i[34567]86-go32-rtems*)
1482 xm_file=i386/xm-go32.h
1483 tm_file=i386/go32-rtems.h
1484 tmake_file="i386/t-go32 t-rtems"
1487 i[34567]86-*-rtems*|i[34567]86-*-rtemself*)
1490 tm_file=i386/rtemself.h
1491 extra_parts="crtbegin.o crtend.o crti.o crtn.o"
1492 tmake_file="i386/t-rtems-i386 i386/t-crtstuff t-rtems"
1495 i[34567]86-*-rtemscoff*)
1498 tm_file=i386/rtems.h
1499 tmake_file="i386/t-i386bare t-rtems"
1502 i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
1504 xm_file="xm-alloca.h ${xm_file} i386/xm-sco5.h"
1505 xm_defines="USG SVR3"
1506 xmake_file=i386/x-sco5
1507 install_headers_dir=install-headers-cpio
1509 if test x$gas = xyes
1511 tm_file="i386/sco5gas.h ${tm_file}"
1512 tmake_file=i386/t-sco5gas
1514 tmake_file=i386/t-sco5
1516 extra_parts="crti.o crtbegin.o crtend.o crtbeginS.o crtendS.o"
1519 i[34567]86-*-sco3.2v4*) # 80386 running SCO 3.2v4 system
1521 xm_file="${xm_file} i386/xm-sco.h"
1522 xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX"
1523 xmake_file=i386/x-sco4
1524 install_headers_dir=install-headers-cpio
1525 if test x$stabs = xyes
1527 tm_file=i386/sco4dbx.h
1528 tmake_file=i386/t-svr3dbx
1529 extra_parts="svr3.ifile svr3z.rfile"
1532 tmake_file=i386/t-crtstuff
1533 extra_parts="crtbegin.o crtend.o"
1535 # The default EAFS filesystem supports long file names.
1536 # Truncating the target makes $host != $target which
1537 # makes gcc think it is doing a cross-compile.
1538 # truncate_target=yes
1541 i[34567]86-*-sco*) # 80386 running SCO system
1543 xm_file=i386/xm-sco.h
1544 xmake_file=i386/x-sco
1545 install_headers_dir=install-headers-cpio
1546 if test x$stabs = xyes
1548 tm_file=i386/scodbx.h
1549 tmake_file=i386/t-svr3dbx
1550 extra_parts="svr3.ifile svr3z.rfile"
1553 extra_parts="crtbegin.o crtend.o"
1554 tmake_file=i386/t-crtstuff
1559 i[34567]86-*-solaris2*)
1561 xm_file="xm-alloca.h ${xm_file}"
1562 xm_defines="USG POSIX SMALL_ARG_MAX"
1564 if test x$gas = xyes; then
1565 # Only needed if gas does not support -s
1566 tm_file="i386/sol2gas.h ${tm_file}"
1568 tmake_file=i386/t-sol2
1569 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
1571 if test x${enable_threads} = x; then
1572 enable_threads=$have_pthread_h
1573 if test x${enable_threads} = x; then
1574 enable_threads=$have_thread_h
1577 if test x${enable_threads} = xyes; then
1578 if test x${have_pthread_h} = xyes; then
1581 thread_file='solaris'
1586 i[34567]86-*-sysv5*) # Intel x86 on System V Release 5
1588 xm_file="xm-alloca.h ${xm_file}"
1589 xm_defines="USG POSIX"
1590 tm_file=i386/sysv5.h
1591 if test x$stabs = xyes
1593 tm_file="${tm_file} dbx.h"
1595 tmake_file=i386/t-crtpic
1597 extra_parts="crtbegin.o crtend.o"
1598 if test x$enable_threads = xyes; then
1603 i[34567]86-*-sysv4*) # Intel 80386's running system V.4
1605 xm_file="xm-alloca.h ${xm_file}"
1606 xm_defines="USG POSIX SMALL_ARG_MAX"
1607 tm_file=i386/sysv4.h
1608 if test x$stabs = xyes
1610 tm_file="${tm_file} dbx.h"
1612 tmake_file=i386/t-crtpic
1614 extra_parts="crtbegin.o crtend.o"
1617 i[34567]86-*-udk*) # Intel x86 on SCO UW/OSR5 Dev Kit
1619 xm_file="xm-alloca.h ${xm_file}"
1620 xm_defines="USG POSIX"
1622 tmake_file="i386/t-crtpic i386/t-udk"
1624 extra_parts="crtbegin.o crtend.o"
1625 install_headers_dir=install-headers-cpio
1628 i[34567]86-*-osf1*) # Intel 80386's running OSF/1 1.3+
1631 xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h i386/xm-osf1elf.h"
1632 xm_defines="USE_C_ALLOCA SMALL_ARG_MAX"
1633 if test x$stabs = xyes
1635 tm_file=i386/osf1elfgdb.h
1637 tm_file=i386/osf1elf.h
1639 tmake_file=i386/t-osf1elf
1640 xmake_file=i386/x-osf1elf
1641 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
1644 i[34567]86-*-sysv*) # Intel 80386's running system V
1646 xm_defines="USG SVR3"
1647 xmake_file=i386/x-sysv3
1648 if test x$gas = xyes
1650 if test x$stabs = xyes
1652 tm_file=i386/svr3dbx.h
1653 tmake_file=i386/t-svr3dbx
1654 extra_parts="svr3.ifile svr3z.rfile"
1656 tm_file=i386/svr3gas.h
1657 extra_parts="crtbegin.o crtend.o"
1658 tmake_file=i386/t-crtstuff
1661 tm_file=i386/sysv3.h
1662 extra_parts="crtbegin.o crtend.o"
1663 tmake_file=i386/t-crtstuff
1666 i386-*-vsta) # Intel 80386's running VSTa kernel
1667 xm_file="${xm_file} i386/xm-vsta.h"
1669 tmake_file=i386/t-vsta
1670 xmake_file=i386/x-vsta
1675 xm_file="${xm_file} i386/xm-cygwin.h"
1676 tmake_file=i386/t-cygwin
1677 tm_file=i386/win32.h
1678 xmake_file=i386/x-cygwin
1680 if test x$enable_threads = xyes; then
1686 i[34567]86-*-pe | i[34567]86-*-cygwin*)
1688 xm_file="${xm_file} i386/xm-cygwin.h"
1689 tmake_file=i386/t-cygwin
1690 tm_file=i386/cygwin.h
1691 xmake_file=i386/x-cygwin
1693 if test x$enable_threads = xyes; then
1699 i[34567]86-*-mingw32*)
1701 tm_file=i386/mingw32.h
1702 xm_file="${xm_file} i386/xm-mingw32.h"
1703 tmake_file="i386/t-cygwin i386/t-mingw32"
1705 xmake_file=i386/x-cygwin
1706 if test x$enable_threads = xyes; then
1713 *minwg32crt* | *mingw32*)
1714 tm_file="${tm_file} i386/crtdll.h"
1722 xm_file="${xm_file} i386/xm-uwin.h"
1723 xm_defines="USG NO_STAB_H"
1724 tmake_file="i386/t-cygwin i386/t-uwin"
1726 xmake_file=i386/x-cygwin
1727 if test x$enable_threads = xyes; then
1733 i[34567]86-*-interix*)
1735 tm_file="i386/i386-interix.h interix.h"
1736 xm_file="i386/xm-i386-interix.h xm-interix.h"
1738 tmake_file="i386/t-interix"
1739 extra_objs=interix.o
1740 xmake_file=x-interix
1741 if test x$enable_threads = xyes ; then
1744 if test x$stabs = xyes ; then
1745 tm_file="${tm_file} dbxcoff.h"
1749 i[34567]86-*-winnt3*)
1751 tm_file=i386/win-nt.h
1752 out_file=i386/i386.c
1753 xm_file="xm-winnt.h ${xm_file}"
1754 xmake_file=winnt/x-winnt
1755 tmake_file=i386/t-winnt
1756 extra_host_objs="winnt.o oldnames.o"
1757 extra_gcc_objs="spawnv.o oldnames.o"
1758 if test x$gnu_ld != xyes
1760 extra_programs=ld.exe
1762 if test x$enable_threads = xyes; then
1767 i[34567]86-dg-dgux*)
1769 xm_file="xm-alloca.h ${xm_file}"
1770 xm_defines="USG POSIX"
1771 out_file=i386/dgux.c
1773 tmake_file=i386/t-dgux
1774 xmake_file=i386/x-dgux
1775 install_headers_dir=install-headers-cpio
1777 i860-alliant-*) # Alliant FX/2800
1778 tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h"
1779 xm_file="${xm_file}"
1780 xmake_file=i860/x-fx2800
1781 tmake_file=i860/t-fx2800
1782 extra_parts="crtbegin.o crtend.o"
1785 tm_file="${tm_file} i860/bsd.h"
1786 if test x$gas = xyes
1788 tm_file="${tm_file} i860/bsd-gas.h"
1793 tm_file="${tm_file} i860/mach.h"
1794 tmake_file=t-libc-ok
1796 i860-*-osf*) # Intel Paragon XP/S, OSF/1AD
1797 tm_file="${tm_file} svr3.h i860/paragon.h"
1798 xm_defines="USG SVR3"
1802 tm_file="${tm_file} svr3.h i860/sysv3.h"
1803 xm_defines="USG SVR3"
1804 xmake_file=i860/x-sysv3
1805 extra_parts="crtbegin.o crtend.o"
1808 tm_file="${tm_file} svr4.h i860/sysv4.h"
1809 xm_defines="USG SVR3"
1810 xmake_file=i860/x-sysv4
1812 extra_parts="crtbegin.o crtend.o"
1814 i960-wrs-vxworks5 | i960-wrs-vxworks5.0*)
1815 tm_file="${tm_file} i960/vx960.h"
1816 tmake_file=i960/t-vxworks960
1818 thread_file='vxworks'
1820 i960-wrs-vxworks5* | i960-wrs-vxworks)
1821 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h"
1822 tmake_file=i960/t-vxworks960
1824 thread_file='vxworks'
1827 tm_file="${tm_file} i960/vx960.h"
1828 tmake_file=i960/t-vxworks960
1830 thread_file='vxworks'
1833 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h"
1834 tmake_file=i960/t-960bare
1838 tmake_file="i960/t-960bare t-rtems"
1839 tm_file="${tm_file} dbxcoff.h i960/rtems.h"
1842 i960-*-*) # Default i960 environment.
1846 extra_parts="crtinit.o crtfini.o"
1848 m68000-convergent-sysv*)
1850 xm_file="m68k/xm-3b1.h ${xm_file}"
1853 extra_headers=math-68881.h
1855 m68000-hp-bsd*) # HP 9000/200 running BSD
1856 tm_file=m68k/hp2bsd.h
1857 xmake_file=m68k/x-hp2bsd
1859 extra_headers=math-68881.h
1861 m68000-hp-hpux*) # HP 9000 series 300
1862 xm_file="xm-alloca.h ${xm_file}"
1864 if test x$gas = xyes
1866 xmake_file=m68k/x-hp320g
1867 tm_file=m68k/hp310g.h
1869 xmake_file=m68k/x-hp320
1870 tm_file=m68k/hp310.h
1872 install_headers_dir=install-headers-cpio
1874 extra_headers=math-68881.h
1879 extra_headers=math-68881.h
1882 tm_file=m68k/sun2o4.h
1884 extra_headers=math-68881.h
1887 xm_file="m68k/xm-3b1.h ${xm_file}"
1889 if test x$gas = xyes
1896 extra_headers=math-68881.h
1898 m68k-apple-aux*) # Apple Macintosh running A/UX
1899 xm_defines="USG AUX"
1900 tmake_file=m68k/t-aux
1901 install_headers_dir=install-headers-cpio
1902 extra_headers=math-68881.h
1903 extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o"
1905 if test "$gnu_ld" = yes
1907 tm_file="${tm_file} m68k/auxgld.h"
1909 tm_file="${tm_file} m68k/auxld.h"
1911 if test "$gas" = yes
1913 tm_file="${tm_file} m68k/auxgas.h"
1915 tm_file="${tm_file} m68k/auxas.h"
1917 tm_file="${tm_file} m68k/a-ux.h"
1921 tm_file=m68k/apollo68.h
1922 xmake_file=m68k/x-apollo68
1924 extra_headers=math-68881.h
1927 m68k-altos-sysv*) # Altos 3068
1928 if test x$gas = xyes
1930 tm_file=m68k/altos3068.h
1933 echo "The Altos is supported only with the GNU assembler" 1>&2
1936 extra_headers=math-68881.h
1938 m68k-bull-sysv*) # Bull DPX/2
1939 if test x$gas = xyes
1941 if test x$stabs = xyes
1943 tm_file=m68k/dpx2cdbx.h
1945 tm_file=m68k/dpx2g.h
1950 xm_file="xm-alloca.h ${xm_file}"
1952 xmake_file=m68k/x-dpx2
1954 extra_headers=math-68881.h
1956 m68k-atari-sysv4*) # Atari variant of V.4.
1957 tm_file=m68k/atari.h
1958 xm_file="xm-alloca.h ${xm_file}"
1959 xm_defines="USG FULL_PROTOTYPES"
1961 extra_parts="crtbegin.o crtend.o"
1962 extra_headers=math-68881.h
1965 m68k-motorola-sysv*)
1966 tm_file=m68k/mot3300.h
1967 xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}"
1968 if test x$gas = xyes
1970 xmake_file=m68k/x-mot3300-gas
1971 if test x$gnu_ld = xyes
1973 tmake_file=m68k/t-mot3300-gald
1975 tmake_file=m68k/t-mot3300-gas
1979 xmake_file=m68k/x-mot3300
1980 if test x$gnu_ld = xyes
1982 tmake_file=m68k/t-mot3300-gld
1984 tmake_file=m68k/t-mot3300
1988 gdb_needs_out_file_path=yes
1989 extra_parts="crt0.o mcrt0.o"
1990 extra_headers=math-68881.h
1993 m68k-ncr-sysv*) # NCR Tower 32 SVR3
1994 tm_file=m68k/tower-as.h
1995 xm_defines="USG SVR3"
1996 xmake_file=m68k/x-tower
1997 extra_parts="crtbegin.o crtend.o"
1998 extra_headers=math-68881.h
2001 tm_file=m68k/plexus.h
2002 xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}"
2005 extra_headers=math-68881.h
2009 xm_file="xm-alloca.h ${xm_file}"
2011 extra_headers=math-68881.h
2014 xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}"
2015 xm_defines="USG unos"
2016 xmake_file=m68k/x-crds
2019 extra_headers=math-68881.h
2021 m68k-cbm-sysv4*) # Commodore variant of V.4.
2023 xm_file="xm-alloca.h ${xm_file}"
2024 xm_defines="USG FULL_PROTOTYPES"
2025 xmake_file=m68k/x-amix
2027 extra_parts="crtbegin.o crtend.o"
2028 extra_headers=math-68881.h
2032 tm_file=m68k/ccur-GAS.h
2033 xmake_file=m68k/x-ccur
2034 extra_headers=math-68881.h
2038 m68k-hp-bsd4.4*) # HP 9000/3xx running 4.4bsd
2039 tm_file=m68k/hp3bsd44.h
2040 xmake_file=m68k/x-hp3bsd44
2042 extra_headers=math-68881.h
2045 m68k-hp-bsd*) # HP 9000/3xx running Berkeley Unix
2046 tm_file=m68k/hp3bsd.h
2048 extra_headers=math-68881.h
2052 if test x$with_fp = xno
2054 tm_file=m68k/isi-nfp.h
2060 extra_headers=math-68881.h
2062 m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
2063 xm_file="xm-alloca.h ${xm_file}"
2065 if test x$gas = xyes
2067 xmake_file=m68k/x-hp320g
2068 tm_file=m68k/hp320g.h
2070 xmake_file=m68k/x-hp320
2071 tm_file=m68k/hpux7.h
2073 install_headers_dir=install-headers-cpio
2075 extra_headers=math-68881.h
2078 m68k-hp-hpux*) # HP 9000 series 300
2079 xm_file="xm-alloca.h ${xm_file}"
2081 if test x$gas = xyes
2083 xmake_file=m68k/x-hp320g
2084 tm_file=m68k/hp320g.h
2086 xmake_file=m68k/x-hp320
2087 tm_file=m68k/hp320.h
2089 install_headers_dir=install-headers-cpio
2091 extra_headers=math-68881.h
2095 tm_file=m68k/sun3mach.h
2097 extra_headers=math-68881.h
2101 if test x$gas = xyes
2103 tm_file=m68k/news3gas.h
2105 tm_file=m68k/news3.h
2108 extra_headers=math-68881.h
2111 m68k-sony-bsd* | m68k-sony-newsos*)
2112 if test x$gas = xyes
2114 tm_file=m68k/newsgas.h
2119 extra_headers=math-68881.h
2122 m68k-next-nextstep2*)
2123 tm_file=m68k/next21.h
2124 xm_file="m68k/xm-next.h ${xm_file}"
2125 tmake_file=m68k/t-next
2126 xmake_file=m68k/x-next
2127 extra_objs=nextstep.o
2128 extra_headers=math-68881.h
2133 m68k-next-nextstep[34]*)
2136 xm_file="m68k/xm-next.h ${xm_file}"
2137 tmake_file=m68k/t-next
2138 xmake_file=m68k/x-next
2139 extra_objs=nextstep.o
2140 extra_parts="crtbegin.o crtend.o"
2141 extra_headers=math-68881.h
2143 if test x$enable_threads = xyes; then
2148 if test x$with_fp = xno
2150 tm_file=m68k/sun3n3.h
2152 tm_file=m68k/sun3o3.h
2156 extra_headers=math-68881.h
2158 m68k-sun-sunos*) # For SunOS 4 (the default).
2159 if test x$with_fp = xno
2161 tm_file=m68k/sun3n.h
2167 extra_headers=math-68881.h
2170 tm_file=m68k/vxm68k.h
2171 tmake_file=m68k/t-vxworks68
2172 extra_headers=math-68881.h
2173 thread_file='vxworks'
2177 tmake_file=m68k/t-m68kbare
2178 tm_file="m68k/m68k-aout.h libgloss.h"
2179 extra_headers=math-68881.h
2183 tmake_file=m68k/t-m68kbare
2184 tm_file="m68k/m68k-coff.h dbx.h libgloss.h"
2185 extra_headers=math-68881.h
2188 m68020-*-elf* | m68k-*-elf*)
2189 tm_file="m68k/m68020-elf.h"
2190 xm_file=m68k/xm-m68kv.h
2191 tmake_file=m68k/t-m68kelf
2192 header_files=math-68881.h
2195 if test x$gas = xyes
2199 tm_file=m68k/lynx-ng.h
2201 xm_file=m68k/xm-lynx.h
2203 tmake_file=m68k/t-lynx
2204 extra_headers=math-68881.h
2208 tm_file=m68k/netbsd.h
2215 # we need collect2 until our bug is fixed...
2218 m68k-*-sysv3*) # Motorola m68k's running system V.3
2219 xm_file="xm-alloca.h ${xm_file}"
2221 xmake_file=m68k/x-m68kv
2222 extra_parts="crtbegin.o crtend.o"
2223 extra_headers=math-68881.h
2226 m68k-*-sysv4*) # Motorola m68k's running system V.4
2227 tm_file=m68k/m68kv4.h
2228 xm_file="xm-alloca.h ${xm_file}"
2231 extra_parts="crtbegin.o crtend.o"
2232 extra_headers=math-68881.h
2235 m68k-*-linux-gnuaout*) # Motorola m68k's running GNU/Linux
2238 tm_file=m68k/linux-aout.h
2239 tmake_file="t-linux-aout m68k/t-linux-aout"
2240 extra_headers=math-68881.h
2244 m68k-*-linux-gnulibc1) # Motorola m68k's running GNU/Linux
2245 # with ELF format using the
2246 # GNU/Linux C library 5
2248 tm_file=m68k/linux.h
2249 tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux"
2250 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2251 extra_headers=math-68881.h
2255 m68k-*-linux-gnu*) # Motorola m68k's running GNU/Linux
2256 # with ELF format using glibc 2
2257 # aka the GNU/Linux C library 6.
2259 tm_file=m68k/linux.h
2260 tmake_file="t-linux m68k/t-linux"
2261 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2262 extra_headers=math-68881.h
2265 if test x$enable_threads = xyes; then
2270 tmake_file=m68k/t-m68kbare
2271 tm_file=m68k/m68k-psos.h
2272 extra_headers=math-68881.h
2276 tmake_file="m68k/t-m68kbare t-rtems"
2277 tm_file=m68k/rtems.h
2278 extra_headers=math-68881.h
2281 m68k-*-rtemself*|m68k-*-rtems*)
2282 tmake_file="m68k/t-m68kbare t-rtems m68k/t-crtstuff"
2283 tm_file=m68k/rtemself.h
2284 extra_headers=math-68881.h
2290 tm_file=m88k/dguxbcs.h
2291 tmake_file=m88k/t-dguxbcs
2295 tmake_file=m88k/t-dgux
2298 extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld"
2299 xmake_file=m88k/x-dgux
2300 if test x$gas = xyes
2302 tmake_file=m88k/t-dgux-gas
2305 m88k-dolphin-sysv3*)
2306 tm_file=m88k/dolph.h
2307 extra_parts="crtbegin.o crtend.o"
2308 xm_file="m88k/xm-sysv3.h ${xm_file}"
2309 xmake_file=m88k/x-dolph
2310 if test x$gas = xyes
2312 tmake_file=m88k/t-m88k-gas
2315 m88k-tektronix-sysv3)
2316 tm_file=m88k/tekXD88.h
2317 extra_parts="crtbegin.o crtend.o"
2318 xm_file="m88k/xm-sysv3.h ${xm_file}"
2319 xmake_file=m88k/x-tekXD88
2320 if test x$gas = xyes
2322 tmake_file=m88k/t-m88k-gas
2326 tm_file=m88k/m88k-aout.h
2329 tm_file=m88k/m88k-coff.h
2330 tmake_file=m88k/t-bug
2334 extra_parts="crtbegin.o crtend.o"
2335 if test x$gas = xyes
2337 tmake_file=m88k/t-luna-gas
2339 tmake_file=m88k/t-luna
2343 tmake_file="${tmake_file} m88k/t-luna-gas"
2346 tm_file=m88k/sysv3.h
2347 extra_parts="crtbegin.o crtend.o"
2348 xm_file="m88k/xm-sysv3.h ${xm_file}"
2349 xmake_file=m88k/x-sysv3
2350 if test x$gas = xyes
2352 tmake_file=m88k/t-m88k-gas
2356 tm_file=m88k/sysv4.h
2357 extra_parts="crtbegin.o crtend.o"
2358 xmake_file=m88k/x-sysv4
2359 tmake_file=m88k/t-sysv4
2361 mips-sgi-irix6*) # SGI System V.4., IRIX 6
2362 if test "x$gnu_ld" = xyes
2364 tm_file="mips/iris6.h mips/iris6gld.h"
2366 tm_file=mips/iris6.h
2368 tmake_file=mips/t-iris6
2369 xm_file=mips/xm-iris6.h
2370 xmake_file=mips/x-iris6
2371 # if test x$enable_threads = xyes; then
2372 # thread_file='irix'
2376 tm_file="mips/elf.h mips/vxworks.h"
2377 tmake_file=mips/t-ecoff
2380 extra_parts="crtbegin.o crtend.o"
2381 thread_file='vxworks'
2383 mips-sgi-irix5cross64) # Irix5 host, Irix 6 target, cross64
2384 tm_file="mips/iris6.h mips/cross64.h"
2386 xm_file="mips/xm-iris5.h"
2387 xmake_file=mips/x-iris
2388 tmake_file=mips/t-cross64
2389 # See comment in mips/iris[56].h files.
2391 # if test x$enable_threads = xyes; then
2392 # thread_file='irix'
2396 if test x$gas = xyes
2398 if test x$stabs = xyes
2400 tm_file=mips/iris5gdb.h
2402 tm_file="mips/sni-svr4.h mips/sni-gas.h"
2405 tm_file=mips/sni-svr4.h
2408 xmake_file=mips/x-sni-svr4
2409 tmake_file=mips/t-mips-gas
2410 if test x$gnu_ld != xyes
2415 mips-sgi-irix5*) # SGI System V.4., IRIX 5
2416 if test x$gas = xyes
2418 tm_file="mips/iris5.h mips/iris5gas.h"
2419 if test x$stabs = xyes
2421 tm_file="${tm_file} dbx.h"
2424 tm_file=mips/iris5.h
2427 xm_file="mips/xm-iris5.h"
2428 xmake_file=mips/x-iris
2429 # mips-tfile doesn't work yet
2430 tmake_file=mips/t-mips-gas
2431 # See comment in mips/iris5.h file.
2433 # if test x$enable_threads = xyes; then
2434 # thread_file='irix'
2437 mips-sgi-irix4loser*) # Mostly like a MIPS.
2438 tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h"
2439 if test x$stabs = xyes; then
2440 tm_file="${tm_file} dbx.h"
2443 xmake_file=mips/x-iris
2444 if test x$gas = xyes
2446 tmake_file=mips/t-mips-gas
2448 extra_passes="mips-tfile mips-tdump"
2450 if test x$gnu_ld != xyes
2454 # if test x$enable_threads = xyes; then
2455 # thread_file='irix'
2458 mips-sgi-irix4*) # Mostly like a MIPS.
2459 tm_file="mips/iris3.h ${tm_file} mips/iris4.h"
2460 if test x$stabs = xyes; then
2461 tm_file="${tm_file} dbx.h"
2464 xmake_file=mips/x-iris
2465 if test x$gas = xyes
2467 tmake_file=mips/t-mips-gas
2469 extra_passes="mips-tfile mips-tdump"
2471 if test x$gnu_ld != xyes
2475 # if test x$enable_threads = xyes; then
2476 # thread_file='irix'
2479 mips-sgi-*) # Mostly like a MIPS.
2480 tm_file="mips/iris3.h ${tm_file}"
2481 if test x$stabs = xyes; then
2482 tm_file="${tm_file} dbx.h"
2485 xmake_file=mips/x-iris3
2486 if test x$gas = xyes
2488 tmake_file=mips/t-mips-gas
2490 extra_passes="mips-tfile mips-tdump"
2492 if test x$gnu_ld != xyes
2497 mips-dec-osfrose*) # Decstation running OSF/1 reference port with OSF/rose.
2498 tm_file="mips/osfrose.h ${tm_file}"
2499 xmake_file=mips/x-osfrose
2500 tmake_file=mips/t-osfrose
2501 extra_objs=halfpic.o
2504 mips-dec-osf*) # Decstation running OSF/1 as shipped by DIGITAL
2505 tm_file=mips/dec-osf1.h
2506 if test x$stabs = xyes; then
2507 tm_file="${tm_file} dbx.h"
2509 xmake_file=mips/x-dec-osf1
2510 if test x$gas = xyes
2512 tmake_file=mips/t-mips-gas
2514 tmake_file=mips/t-ultrix
2515 extra_passes="mips-tfile mips-tdump"
2517 if test x$gnu_ld != xyes
2522 mips-dec-bsd*) # Decstation running 4.4 BSD
2523 tm_file=mips/dec-bsd.h
2524 if test x$gas = xyes
2526 tmake_file=mips/t-mips-gas
2528 tmake_file=mips/t-ultrix
2529 extra_passes="mips-tfile mips-tdump"
2531 if test x$gnu_ld != xyes
2536 mipsel-*-netbsd* | mips-dec-netbsd*) # Decstation running NetBSD
2537 tm_file=mips/netbsd.h
2538 # On NetBSD, the headers are already okay, except for math.h.
2541 mips*-*-linux*) # Linux MIPS, either endian.
2544 mipsel-*) tm_file="mips/elfl.h mips/linux.h" ;;
2545 *) tm_file="mips/elf.h mips/linux.h" ;;
2547 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2550 if test x$enable_threads = xyes; then
2554 mips*el-*-openbsd*) # mips little endian
2555 target_cpu_default="MASK_GAS|MASK_ABICALLS"
2557 mips*-*-openbsd*) # mips big endian
2558 target_cpu_default="MASK_GAS|MASK_ABICALLS"
2559 tm_file="mips/openbsd-be.h ${tm_file}"
2561 mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news.
2562 tm_file="mips/news4.h ${tm_file}"
2563 if test x$stabs = xyes; then
2564 tm_file="${tm_file} dbx.h"
2566 if test x$gas = xyes
2568 tmake_file=mips/t-mips-gas
2570 extra_passes="mips-tfile mips-tdump"
2572 if test x$gnu_ld != xyes
2576 xmake_file=mips/x-sony
2578 mips-sony-sysv*) # Sony NEWS 3800 with NEWSOS5.0.
2579 # That is based on svr4.
2580 # t-svr4 is not right because this system doesn't use ELF.
2581 tm_file="mips/news5.h ${tm_file}"
2582 if test x$stabs = xyes; then
2583 tm_file="${tm_file} dbx.h"
2586 if test x$gas = xyes
2588 tmake_file=mips/t-mips-gas
2590 extra_passes="mips-tfile mips-tdump"
2592 if test x$gnu_ld != xyes
2597 mips-tandem-sysv4*) # Tandem S2 running NonStop UX
2598 tm_file="mips/svr4-5.h mips/svr4-t.h"
2599 if test x$stabs = xyes; then
2600 tm_file="${tm_file} dbx.h"
2603 xmake_file=mips/x-sysv
2604 if test x$gas = xyes
2606 tmake_file=mips/t-mips-gas
2607 extra_parts="crtbegin.o crtend.o"
2609 tmake_file=mips/t-mips
2610 extra_passes="mips-tfile mips-tdump"
2612 if test x$gnu_ld != xyes
2617 mips-*-ultrix* | mips-dec-mach3) # Decstation.
2618 tm_file="mips/ultrix.h ${tm_file}"
2619 if test x$stabs = xyes; then
2620 tm_file="${tm_file} dbx.h"
2622 xmake_file=mips/x-ultrix
2623 if test x$gas = xyes
2625 tmake_file=mips/t-mips-gas
2627 tmake_file=mips/t-ultrix
2628 extra_passes="mips-tfile mips-tdump"
2630 if test x$gnu_ld != xyes
2636 mips-*-riscos[56789]bsd*)
2638 tm_file=mips/bsd-5.h # MIPS BSD 4.3, RISC-OS 5.0
2639 if test x$stabs = xyes; then
2640 tm_file="${tm_file} dbx.h"
2642 if test x$gas = xyes
2644 tmake_file=mips/t-bsd-gas
2646 tmake_file=mips/t-bsd
2647 extra_passes="mips-tfile mips-tdump"
2649 if test x$gnu_ld != xyes
2655 mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[1234]bsd*)
2657 tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0
2658 if test x$stabs = xyes; then
2659 tm_file="${tm_file} dbx.h"
2661 if test x$gas = xyes
2663 tmake_file=mips/t-bsd-gas
2665 tmake_file=mips/t-bsd
2666 extra_passes="mips-tfile mips-tdump"
2668 if test x$gnu_ld != xyes
2674 mips-*-riscos[56789]sysv4*)
2676 tm_file=mips/svr4-5.h # MIPS System V.4., RISC-OS 5.0
2677 if test x$stabs = xyes; then
2678 tm_file="${tm_file} dbx.h"
2680 xmake_file=mips/x-sysv
2681 if test x$gas = xyes
2683 tmake_file=mips/t-svr4-gas
2685 tmake_file=mips/t-svr4
2686 extra_passes="mips-tfile mips-tdump"
2688 if test x$gnu_ld != xyes
2694 mips-*-sysv4* | mips-*-riscos[1234]sysv4* | mips-*-riscossysv4*)
2696 tm_file="mips/svr4-4.h ${tm_file}"
2697 if test x$stabs = xyes; then
2698 tm_file="${tm_file} dbx.h"
2701 xmake_file=mips/x-sysv
2702 if test x$gas = xyes
2704 tmake_file=mips/t-svr4-gas
2706 tmake_file=mips/t-svr4
2707 extra_passes="mips-tfile mips-tdump"
2709 if test x$gnu_ld != xyes
2715 mips-*-riscos[56789]sysv*)
2717 tm_file=mips/svr3-5.h # MIPS System V.3, RISC-OS 5.0
2718 if test x$stabs = xyes; then
2719 tm_file="${tm_file} dbx.h"
2722 xmake_file=mips/x-sysv
2723 if test x$gas = xyes
2725 tmake_file=mips/t-svr3-gas
2727 tmake_file=mips/t-svr3
2728 extra_passes="mips-tfile mips-tdump"
2730 if test x$gnu_ld != xyes
2735 mips-*-sysv* | mips-*-riscos*sysv*)
2736 tm_file="mips/svr3-4.h ${tm_file}"
2737 if test x$stabs = xyes; then
2738 tm_file="${tm_file} dbx.h"
2741 xmake_file=mips/x-sysv
2742 if test x$gas = xyes
2744 tmake_file=mips/t-svr3-gas
2746 tmake_file=mips/t-svr3
2747 extra_passes="mips-tfile mips-tdump"
2749 if test x$gnu_ld != xyes
2755 mips-*-riscos[56789]*) # Default MIPS RISC-OS 5.0.
2757 tm_file=mips/mips-5.h
2758 if test x$stabs = xyes; then
2759 tm_file="${tm_file} dbx.h"
2761 if test x$gas = xyes
2763 tmake_file=mips/t-mips-gas
2765 extra_passes="mips-tfile mips-tdump"
2767 if test x$gnu_ld != xyes
2775 tm_file=mips/ecoffl.h
2776 if test x$stabs = xyes; then
2777 tm_file="${tm_file} dbx.h"
2779 tmake_file=mips/t-ecoff
2782 tm_file="gofast.h mips/ecoff.h"
2783 if test x$stabs = xyes; then
2784 tm_file="${tm_file} dbx.h"
2786 tmake_file=mips/t-ecoff
2789 tm_file="mips/elfl.h"
2790 tmake_file=mips/t-elf
2793 tm_file="mips/elf.h"
2794 tmake_file=mips/t-elf
2797 tm_file="mips/elfl64.h"
2798 tmake_file=mips/t-elf
2800 mips64orionel-*-elf*)
2801 tm_file="mips/elforion.h mips/elfl64.h"
2802 tmake_file=mips/t-elf
2805 tm_file="mips/elf64.h"
2806 tmake_file=mips/t-elf
2809 tm_file="mips/elforion.h mips/elf64.h"
2810 tmake_file=mips/t-elf
2812 mips64orion-*-rtems*)
2813 tm_file="mips/elforion.h mips/elf64.h mips/rtems64.h"
2814 tmake_file="mips/t-elf t-rtems"
2817 tm_file="mips/r3900.h mips/elfl.h mips/abi64.h"
2818 tmake_file=mips/t-r3900
2821 tm_file="mips/r3900.h mips/elf.h mips/abi64.h"
2822 tmake_file=mips/t-r3900
2824 mips-*-*) # Default MIPS RISC-OS 4.0.
2825 if test x$stabs = xyes; then
2826 tm_file="${tm_file} dbx.h"
2828 if test x$gas = xyes
2830 tmake_file=mips/t-mips-gas
2832 extra_passes="mips-tfile mips-tdump"
2834 if test x$gnu_ld != xyes
2842 tm_file="mn10200/mn10200.h"
2843 if test x$stabs = xyes
2845 tm_file="${tm_file} dbx.h"
2851 tm_file="mn10300/mn10300.h"
2852 if test x$stabs = xyes
2854 tm_file="${tm_file} dbx.h"
2859 tm_file=ns32k/encore.h
2863 tm_file=ns32k/sequent.h
2867 tm_file=ns32k/tek6100.h
2871 tm_file=ns32k/tek6200.h
2874 # This has not been updated to GCC 2.
2877 # xmake_file=ns32k/x-genix
2878 # tm_file=ns32k/genix.h
2882 tm_file=ns32k/merlin.h
2886 tm_file=ns32k/pc532-mach.h
2890 tm_file=ns32k/pc532-min.h
2891 xm_file="ns32k/xm-pc532-min.h ${xm-file}"
2896 tm_file=ns32k/netbsd.h
2897 xm_file="ns32k/xm-netbsd.h ${xm_file}"
2898 # On NetBSD, the headers are already okay, except for math.h.
2903 tm_file="${tm_file} pdp11/2bsd.h"
2910 # This has not been updated to GCC 2.
2913 # xmake_file=pyr/x-pyr
2918 tm_file="svr4.h pj/linux.h ${tm_file}"
2923 tm_file="svr4.h pj/pjl.h ${tm_file}"
2930 xmake_file=romp/x-mach
2937 tmake_file="${tmake_file} rs6000/t-rs6000 rs6000/t-openbsd"
2941 tm_file=rs6000/beos.h
2942 xm_file=rs6000/xm-beos.h
2943 tmake_file=rs6000/t-beos
2944 xmake_file=rs6000/x-beos
2946 powerpc-*-sysv* | powerpc-*-elf*)
2947 tm_file=rs6000/sysv4.h
2948 xm_file="rs6000/xm-sysv4.h"
2949 xm_defines="USG POSIX"
2950 extra_headers=ppc-asm.h
2951 if test x$gas = xyes
2953 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2955 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2957 xmake_file=rs6000/x-sysv4
2960 tm_file=rs6000/eabiaix.h
2961 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2962 extra_headers=ppc-asm.h
2965 tm_file=rs6000/eabisim.h
2966 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2967 extra_headers=ppc-asm.h
2970 tm_file=rs6000/eabi.h
2971 if test x$gas = xyes
2973 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2975 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2977 extra_headers=ppc-asm.h
2980 tm_file=rs6000/rtems.h
2981 if test x$gas = xyes
2983 tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm"
2985 tmake_file="rs6000/t-ppc t-rtems rs6000/t-ppccomm"
2987 extra_headers=ppc-asm.h
2989 powerpc-*-linux-gnulibc1)
2990 tm_file=rs6000/linux.h
2991 xm_file=rs6000/xm-sysv4.h
2992 out_file=rs6000/rs6000.c
2993 if test x$gas = xyes
2995 tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2997 tmake_file="rs6000/t-ppc t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
3000 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3001 extra_headers=ppc-asm.h
3002 if test x$enable_threads = xyes; then
3006 powerpc-*-linux-gnu*)
3007 tm_file=rs6000/linux.h
3008 xm_file="rs6000/xm-sysv4.h"
3009 xm_defines="USG ${xm_defines}"
3010 out_file=rs6000/rs6000.c
3011 if test x$gas = xyes
3013 tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm"
3015 tmake_file="rs6000/t-ppc t-linux rs6000/t-ppccomm"
3018 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3019 extra_headers=ppc-asm.h
3020 if test x$enable_threads = xyes; then
3024 powerpc-wrs-vxworks*)
3026 xm_file="rs6000/xm-sysv4.h"
3027 xm_defines="USG POSIX"
3028 tm_file=rs6000/vxppc.h
3029 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
3030 extra_headers=ppc-asm.h
3031 thread_file='vxworks'
3033 powerpcle-*-sysv* | powerpcle-*-elf*)
3034 tm_file=rs6000/sysv4le.h
3035 xm_file="rs6000/xm-sysv4.h"
3036 xm_defines="USG POSIX"
3037 if test x$gas = xyes
3039 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
3041 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
3043 xmake_file=rs6000/x-sysv4
3044 extra_headers=ppc-asm.h
3046 powerpcle-*-eabisim*)
3047 tm_file=rs6000/eabilesim.h
3048 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
3049 extra_headers=ppc-asm.h
3052 tm_file=rs6000/eabile.h
3053 if test x$gas = xyes
3055 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
3057 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
3059 extra_headers=ppc-asm.h
3061 powerpcle-*-winnt* )
3062 tm_file=rs6000/win-nt.h
3063 tmake_file=rs6000/t-winnt
3065 if test x$enable_threads = xyes; then
3068 extra_headers=ppc-asm.h
3070 powerpcle-*-pe | powerpcle-*-cygwin*)
3071 tm_file=rs6000/cygwin.h
3072 xm_file="rs6000/xm-cygwin.h ${xm_file}"
3073 tmake_file=rs6000/t-winnt
3074 xmake_file=rs6000/x-cygwin
3076 if test x$enable_threads = xyes; then
3080 extra_headers=ppc-asm.h
3082 powerpcle-*-solaris2*)
3083 tm_file=rs6000/sol2.h
3084 xm_file="rs6000/xm-sysv4.h"
3085 xm_defines="USG POSIX"
3086 if test x$gas = xyes
3088 tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
3090 tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
3092 xmake_file=rs6000/x-sysv4
3093 extra_headers=ppc-asm.h
3096 rs6000-ibm-aix3.[01]*)
3098 tm_file=rs6000/aix31.h
3099 xmake_file=rs6000/x-aix31
3104 rs6000-ibm-aix3.2.[456789]* | powerpc-ibm-aix3.2.[456789]*)
3106 tm_file=rs6000/aix3newas.h
3107 if test x$host != x$target
3109 tmake_file=rs6000/t-xnewas
3111 tmake_file=rs6000/t-newas
3117 rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*)
3119 tm_file=rs6000/aix41.h
3120 if test x$host != x$target
3122 tmake_file=rs6000/t-xnewas
3124 tmake_file=rs6000/t-newas
3126 if test "$gnu_ld" = yes
3128 xmake_file=rs6000/x-aix41-gld
3130 xmake_file=rs6000/x-aix41
3136 rs6000-ibm-aix4.[3456789]* | powerpc-ibm-aix4.[3456789]*)
3138 tm_file=rs6000/aix43.h
3139 if test x$host != x$target
3141 tmake_file=rs6000/t-xaix43
3143 tmake_file=rs6000/t-aix43
3145 xmake_file=rs6000/x-aix43
3150 rs6000-ibm-aix[56789].* | powerpc-ibm-aix[56789].*)
3152 tm_file=rs6000/aix43.h
3153 if test x$host != x$target
3155 tmake_file=rs6000/t-xaix43
3157 tmake_file=rs6000/t-aix43
3159 xmake_file=rs6000/x-aix43
3172 tm_file=rs6000/mach.h
3173 xm_file="${xm_file} rs6000/xm-mach.h"
3174 xmake_file=rs6000/x-mach
3178 tm_file=rs6000/lynx.h
3179 xm_file=rs6000/xm-lynx.h
3180 tmake_file=rs6000/t-rs6000
3181 xmake_file=rs6000/x-lynx
3189 tmake_file="sh/t-sh t-rtems"
3190 tm_file=sh/rtemself.h
3194 tmake_file="sh/t-sh t-rtems"
3203 xm_file="xm-alloca.h ${xm_file}"
3206 sparc-wrs-vxworks* | sparclite-wrs-vxworks*)
3207 tm_file=sparc/vxsparc.h
3208 tmake_file=sparc/t-vxsparc
3210 thread_file='vxworks'
3213 tmake_file=sparc/t-sparcbare
3214 tm_file="sparc/aout.h libgloss.h"
3217 tm_file=sparc/netbsd.h
3222 # we need collect2 until our bug is fixed...
3230 tmake_file=sparc/t-elf
3231 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
3235 sparc-*-linux-gnuaout*) # Sparc's running GNU/Linux, a.out
3236 xm_file="${xm_file} sparc/xm-linux.h"
3237 tm_file=sparc/linux-aout.h
3241 sparc-*-linux-gnulibc1*) # Sparc's running GNU/Linux, libc5
3242 xm_file="${xm_file} sparc/xm-linux.h"
3244 tm_file=sparc/linux.h
3245 tmake_file="t-linux t-linux-gnulibc1"
3246 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3250 sparc-*-linux-gnu*) # Sparc's running GNU/Linux, libc6
3251 xm_file="${xm_file} sparc/xm-linux.h"
3253 tm_file=sparc/linux.h
3254 tmake_file="t-linux"
3255 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3257 if test x$enable_threads = xyes; then
3263 if test x$gas = xyes
3265 tm_file=sparc/lynx.h
3267 tm_file=sparc/lynx-ng.h
3269 xm_file=sparc/xm-lynx.h
3270 tmake_file=sparc/t-sunos41
3274 tmake_file="sparc/t-sparcbare t-rtems"
3275 tm_file=sparc/rtems.h
3277 sparc-*-rtems*|sparc-*-rtemself*)
3278 tm_file="sparc/rtemself.h"
3279 tmake_file="sparc/t-elf t-rtems"
3280 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
3284 sparcv9-*-solaris2*)
3285 if test x$gnu_ld = xyes
3287 tm_file=sparc/sol2-64.h
3289 tm_file=sparc/sol2-sld-64.h
3291 xm_file="sparc/xm-sysv4-64.h sparc/xm-sol2.h"
3292 xm_defines="USG POSIX"
3293 tmake_file="sparc/t-sol2 sparc/t-sol2-64"
3294 xmake_file=sparc/x-sysv4
3295 extra_parts="crt1.o crti.o crtn.o gcrt1.o crtbegin.o crtend.o"
3297 if test x${enable_threads} = x ; then
3298 enable_threads=$have_pthread_h
3299 if test x${enable_threads} = x ; then
3300 enable_threads=$have_thread_h
3303 if test x${enable_threads} = xyes ; then
3304 if test x${have_pthread_h} = xyes ; then
3307 thread_file='solaris'
3311 sparc-hal-solaris2*)
3312 xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h"
3313 xm_defines="USG POSIX"
3314 tm_file="sparc/sol2.h sparc/hal.h"
3315 tmake_file="sparc/t-halos sparc/t-sol2"
3316 xmake_file=sparc/x-sysv4
3317 extra_parts="crt1.o crti.o crtn.o gmon.o crtbegin.o crtend.o"
3326 thread_file='solaris'
3329 if test x$gnu_ld = xyes
3331 tm_file=sparc/sol2.h
3333 tm_file=sparc/sol2-sld.h
3335 xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h"
3336 xm_defines="USG POSIX"
3337 tmake_file=sparc/t-sol2
3338 xmake_file=sparc/x-sysv4
3339 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
3342 *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*) ;;
3345 if test x$gnu_ld = xyes
3347 tm_file=sparc/sol2-64.h
3349 tm_file=sparc/sol2-sld-64.h
3351 tmake_file="$tmake_file sparc/t-sol2-64"
3364 if test x${enable_threads} = x; then
3365 enable_threads=$have_pthread_h
3366 if test x${enable_threads} = x; then
3367 enable_threads=$have_thread_h
3370 if test x${enable_threads} = xyes; then
3371 if test x${have_pthread_h} = xyes; then
3374 thread_file='solaris'
3379 tm_file=sparc/sunos4.h
3380 tmake_file=sparc/t-sunos40
3384 tm_file=sparc/sunos4.h
3385 tmake_file=sparc/t-sunos41
3387 if test x$gas = xyes; then
3388 tm_file="${tm_file} sparc/sun4gas.h"
3392 tm_file=sparc/sun4o3.h
3396 tm_file=sparc/sysv4.h
3397 xm_file="sparc/xm-sysv4.h"
3398 xm_defines="USG POSIX"
3400 xmake_file=sparc/x-sysv4
3401 extra_parts="crtbegin.o crtend.o"
3404 xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h"
3405 xm_defines="USG POSIX"
3406 tm_file=sparc/vxsim.h
3407 tmake_file=sparc/t-vxsparc
3408 xmake_file=sparc/x-sysv4
3411 tm_file="sparc/splet.h libgloss.h"
3412 tmake_file=sparc/t-splet
3415 tm_file="sparc/litecoff.h libgloss.h"
3416 tmake_file=sparc/t-sparclite
3419 tm_file="sparc/lite.h aoutos.h libgloss.h"
3420 tmake_file=sparc/t-sparclite
3423 tm_file="sparc/liteelf.h"
3424 tmake_file=sparc/t-sparclite
3425 extra_parts="crtbegin.o crtend.o"
3428 tm_file="sparc/sp86x-aout.h aoutos.h libgloss.h"
3429 tmake_file=sparc/t-sp86x
3432 tm_file="sparc/sp86x-elf.h"
3433 tmake_file=sparc/t-sp86x
3434 extra_parts="crtbegin.o crtend.o"
3437 tmake_file=sparc/t-sp64
3438 tm_file=sparc/sp64-aout.h
3441 tmake_file=sparc/t-sp64
3442 tm_file=sparc/sp64-elf.h
3443 extra_parts="crtbegin.o crtend.o"
3445 sparc64-*-linux*) # 64-bit Sparc's running GNU/Linux
3446 tmake_file="t-linux sparc/t-linux64"
3447 xm_file="sparc/xm-sp64.h sparc/xm-linux.h"
3448 tm_file=sparc/linux64.h
3450 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3452 if test x$enable_threads = xyes; then
3457 # This hasn't been upgraded to GCC 2.
3458 # tahoe-harris-*) # Harris tahoe, using COFF.
3459 # tm_file=tahoe/harris.h
3461 # tahoe-*-bsd*) # tahoe running BSD
3463 thumb-*-coff* | thumbel-*-coff*)
3465 out_file=arm/thumb.c
3466 xm_file=arm/xm-thumb.h
3467 md_file=arm/thumb.md
3468 tmake_file=arm/t-thumb
3470 thumb-*-elf* | thumbel-*-elf*)
3472 out_file=arm/thumb.c
3473 xm_file=arm/xm-thumb.h
3474 md_file=arm/thumb.md
3475 tmake_file=arm/t-thumb-elf
3478 tm_file=arm/linux-telf.h
3479 out_file=arm/thumb.c
3480 xm_file=arm/xm-thumb.h
3481 md_file=arm/thumb.md
3482 tmake_file=arm/t-thumb-linux
3485 tm_file=arm/uclinux-telf.h
3486 out_file=arm/thumb.c
3487 md_file=arm/thumb.md
3488 tmake_file=arm/t-thumb-linux
3489 xm_file=arm/xm-thumb.h
3493 out_file=arm/thumb.c
3494 xm_file=arm/xm-thumb.h
3495 md_file=arm/thumb.md
3496 tmake_file=arm/t-thumb
3497 thread_file='vxworks'
3501 out_file=arm/thumb.c
3502 xm_file=arm/xm-thumb.h
3503 md_file=arm/thumb.md
3504 tmake_file=arm/t-pe-thumb
3507 # This hasn't been upgraded to GCC 2.
3514 tm_file="v850/rtems.h"
3515 xm_file="v850/xm-v850.h"
3516 tmake_file="v850/t-v850 t-rtems"
3517 if test x$stabs = xyes
3519 tm_file="${tm_file} dbx.h"
3524 target_cpu_default="TARGET_CPU_generic"
3526 tm_file="v850/v850.h"
3527 xm_file="v850/xm-v850.h"
3528 tmake_file=v850/t-v850
3529 if test x$stabs = xyes
3531 tm_file="${tm_file} dbx.h"
3535 vax-*-bsd*) # vaxen running BSD
3539 vax-*-sysv*) # vaxen running system V
3540 tm_file="${tm_file} vax/vaxv.h"
3545 tm_file="${tm_file} netbsd.h vax/netbsd.h"
3551 tmake_file="${tmake_file} vax/t-openbsd"
3553 vax-*-ultrix*) # vaxen running ultrix
3554 tm_file="${tm_file} vax/ultrix.h"
3558 vax-*-vms*) # vaxen running VMS
3559 xm_file=vax/xm-vms.h
3563 vax-*-*) # vax default entry
3567 xm_file="${xm_file} xm-svr3"
3571 echo "Configuration $machine not supported" 1>&2
3578 ;; # Existing GNU/Linux systems do not use the GNU setup.
3580 # On the GNU system, the setup is just about the same on
3581 # each different CPU. The specific machines that GNU
3582 # supports are matched above and just set $cpu_type.
3583 xm_file="xm-gnu.h ${xm_file}"
3584 tm_file=${cpu_type}/gnu.h
3585 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
3586 # GNU always uses ELF.
3588 # GNU tools are the only tools.
3591 xmake_file=x-linux # These details are the same as Linux.
3592 tmake_file=t-gnu # These are not.
3595 xmake_try_sysv=x-sysv
3596 install_headers_dir=install-headers-cpio
3599 install_headers_dir=install-headers-cpio
3603 # Distinguish i[34567]86
3604 # Also, do not run mips-tfile on MIPS if using gas.
3605 # Process --with-cpu= for PowerPC/rs6000
3606 target_cpu_default2=
3609 target_cpu_default2=1
3612 case $target_alias in
3614 target_cpu_default2=4
3617 target_cpu_default2=2
3621 i686-*-* | i786-*-*)
3622 target_cpu_default2=3
3629 target_cpu_default2="MASK_CPU_EV6|MASK_BWX|MASK_MAX|MASK_FIX|MASK_CIX"
3632 target_cpu_default2="MASK_CPU_EV6|MASK_BWX|MASK_MAX|MASK_FIX"
3635 target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX"
3638 target_cpu_default2="MASK_CPU_EV5|MASK_BWX"
3641 target_cpu_default2="MASK_CPU_EV5"
3645 if test x$gas = xyes
3647 if test "$target_cpu_default2" = ""
3649 target_cpu_default2="MASK_GAS"
3651 target_cpu_default2="${target_cpu_default2}|MASK_GAS"
3656 case "x$with_cpu" in
3659 target_cpu_default2="TARGET_CPU_generic"
3662 # Distinguish cores, and major variants
3663 # arm7m doesn't exist, but D & I don't affect code
3665 xarm[23678] | xarm250 | xarm[67][01]0 \
3666 | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \
3667 | xarm7100 | xarm7500 | xarm7500fe | xarm810 \
3668 | xstrongarm | xstrongarm110 | xstrongarm1100)
3670 target_cpu_default2="TARGET_CPU_$with_cpu"
3674 echo "--with-cpu must be passed a value" 1>&2
3679 if test x$pass2done = xyes
3681 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3688 mips*-*-ecoff* | mips*-*-elf*)
3689 if test x$gas = xyes
3691 if test x$gnu_ld = xyes
3693 target_cpu_default2=20
3695 target_cpu_default2=16
3700 if test x$gas = xyes
3702 target_cpu_default2=16
3705 powerpc*-*-* | rs6000-*-*)
3706 case "x$with_cpu" in
3710 xcommon | xpower | xpower2 | xpowerpc | xrios \
3711 | xrios1 | xrios2 | xrsc | xrsc1 \
3712 | x601 | x602 | x603 | x603e | x604 | x604e | x620 \
3713 | xec603e | x740 | x750 | x401 \
3714 | x403 | x505 | x801 | x821 | x823 | x860)
3715 target_cpu_default2="\"$with_cpu\""
3719 echo "--with-cpu must be passed a value" 1>&2
3724 if test x$pass2done = xyes
3726 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3733 case ".$with_cpu" in
3735 target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`"
3737 .supersparc | .hypersparc | .ultrasparc | .v7 | .v8 | .v9)
3738 target_cpu_default2="TARGET_CPU_$with_cpu"
3741 if test x$pass2done = xyes
3743 echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
3751 if test "$target_cpu_default2" != ""
3753 if test "$target_cpu_default" != ""
3755 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
3757 target_cpu_default=$target_cpu_default2
3761 # No need for collect2 if we have the GNU linker.
3762 # Actually, there is now; GNU ld doesn't handle the EH info or
3763 # collecting for shared libraries.
3770 # Save data on machine being used to compile GCC in build_xm_file.
3771 # Save data on host machine in vars host_xm_file and host_xmake_file.
3772 if test x$pass1done = x
3774 if test x"$xm_file" = x
3775 then build_xm_file=$cpu_type/xm-$cpu_type.h
3776 else build_xm_file=$xm_file
3778 build_xm_defines=$xm_defines
3779 build_install_headers_dir=$install_headers_dir
3780 build_exeext=$exeext
3783 if test x$pass2done = x
3785 if test x"$xm_file" = x
3786 then host_xm_file=$cpu_type/xm-$cpu_type.h
3787 else host_xm_file=$xm_file
3789 host_xm_defines=$xm_defines
3790 if test x"$xmake_file" = x
3791 then xmake_file=$cpu_type/x-$cpu_type
3793 host_xmake_file="$xmake_file"
3794 host_truncate_target=$truncate_target
3795 host_extra_gcc_objs=$extra_gcc_objs
3796 host_extra_objs=$extra_host_objs
3803 extra_objs="${host_extra_objs} ${extra_objs}"
3805 # Default the target-machine variables that were not explicitly set.
3806 if test x"$tm_file" = x
3807 then tm_file=$cpu_type/$cpu_type.h; fi
3809 if test x$extra_headers = x
3810 then extra_headers=; fi
3812 if test x"$xm_file" = x
3813 then xm_file=$cpu_type/xm-$cpu_type.h; fi
3815 if test x$md_file = x
3816 then md_file=$cpu_type/$cpu_type.md; fi
3818 if test x$out_file = x
3819 then out_file=$cpu_type/$cpu_type.c; fi
3821 if test x"$tmake_file" = x
3822 then tmake_file=$cpu_type/t-$cpu_type
3825 if test x"$dwarf2" = xyes
3826 then tm_file="tm-dwarf2.h $tm_file"
3829 if test x$float_format = x
3830 then float_format=i64
3833 if test $float_format = none
3834 then float_h_file=Makefile.in
3835 else float_h_file=float-$float_format.h
3838 # Handle cpp installation.
3839 if test x$enable_cpp != xno
3841 tmake_file="$tmake_file t-install-cpp"
3844 # Say what files are being used for the output code and MD file.
3845 echo "Using \`$srcdir/config/$out_file' to output insns."
3846 echo "Using \`$srcdir/config/$md_file' as machine description file."
3849 for f in $tm_file; do
3852 if test $count = ax; then
3853 echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
3855 echo "Using the following target machine macro files:"
3856 for f in $tm_file; do
3857 echo " $srcdir/config/$f"
3862 for f in $host_xm_file; do
3865 if test $count = ax; then
3866 echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
3868 echo "Using the following host machine macro files:"
3869 for f in $host_xm_file; do
3870 echo " $srcdir/config/$f"
3874 if test "$host_xm_file" != "$build_xm_file"; then
3876 for f in $build_xm_file; do
3879 if test $count = ax; then
3880 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
3882 echo "Using the following build machine macro files:"
3883 for f in $build_xm_file; do
3884 echo " $srcdir/config/$f"
3889 if test x$thread_file = x; then
3890 if test x$target_thread_file != x; then
3891 thread_file=$target_thread_file
3893 thread_file='single'
3897 # Set up the header files.
3898 # $links is the list of header files to create.
3899 # $vars is the list of shell variables with file names to include.
3900 # auto-host.h is the file containing items generated by autoconf and is
3901 # the first file included by config.h.
3903 host_xm_file="auto-host.h gansidecl.h ${host_xm_file} hwint.h"
3905 # If host=build, it is correct to have hconfig include auto-host.h
3906 # as well. If host!=build, we are in error and need to do more
3907 # work to find out the build config parameters.
3908 if test x$host = x$build
3910 build_xm_file="auto-host.h gansidecl.h ${build_xm_file} hwint.h"
3912 # We create a subdir, then run autoconf in the subdir.
3913 # To prevent recursion we set host and build for the new
3914 # invocation of configure to the build for this invocation
3921 /*) realsrcdir=${srcdir};;
3922 *) realsrcdir=../${srcdir};;
3924 CC=${CC_FOR_BUILD} ${realsrcdir}/configure \
3925 --target=$target --host=$build --build=$build
3927 # We just finished tests for the build machine, so rename
3928 # the file auto-build.h in the gcc directory.
3929 mv auto-host.h ../auto-build.h
3932 build_xm_file="auto-build.h gansidecl.h ${build_xm_file} hwint.h"
3935 xm_file="gansidecl.h ${xm_file}"
3936 tm_file="gansidecl.h ${tm_file}"
3938 vars="host_xm_file tm_file tm_p_file xm_file build_xm_file"
3939 links="config.h tm.h tm_p.h tconfig.h hconfig.h"
3940 defines="host_xm_defines null_defines null_defines xm_defines build_xm_defines"
3943 if test -f config.status; then mv -f config.status config.bak; fi
3946 while test -n "$vars"
3948 set $vars; var=$1; shift; vars=$*
3949 set $links; link=$1; shift; links=$*
3950 set $defines; define=$1; shift; defines=$*
3953 # Make sure the file is created, even if it is empty.
3956 # Define TARGET_CPU_DEFAULT if the system wants one.
3957 # This substitutes for lots of *.h files.
3958 if test "$target_cpu_default" != "" -a $link = tm.h
3960 echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link
3963 for file in `eval echo '$'$var`; do
3968 echo '#ifdef IN_GCC' >>$link
3971 echo "#include \"$file\"" >>$link
3976 echo '#endif' >>$link
3981 for def in `eval echo '$'$define`; do
3982 echo "#ifndef $def" >>$link
3983 echo "#define $def" >>$link
3984 echo "#endif" >>$link
3988 # Truncate the target if necessary
3989 if test x$host_truncate_target != x; then
3990 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
3993 # Get the version trigger filename from the toplevel
3994 if test "${with_gcc_version_trigger+set}" = set; then
3995 gcc_version_trigger=$with_gcc_version_trigger
3997 gcc_version_trigger=${srcdir}/version.c
4000 gcc_version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < ${gcc_version_trigger}`
4003 # Internationalization
4005 VERSION="$gcc_version"
4006 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
4007 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
4013 # NLS support is still experimental, so disable it by default for now.
4015 [ --enable-nls use Native Language Support (disabled by default)],
4019 XGETTEXT="AWK='$AWK' \$(SHELL) \$(top_srcdir)/exgettext $XGETTEXT"
4021 # Windows32 Registry support for specifying GCC installation paths.
4022 AC_ARG_ENABLE(win32-registry,
4023 [ --disable-win32-registry
4024 Disable lookup of installation paths in the
4025 Registry on Windows hosts.
4026 --enable-win32-registry Enable registry lookup (default).
4027 --enable-win32-registry=KEY
4028 Use KEY instead of GCC version as the last portion
4029 of the registry key.],,)
4031 AC_MSG_CHECKING(whether windows registry support is requested)
4032 if test x$enable_win32_registry != xno; then
4033 AC_DEFINE(ENABLE_WIN32_REGISTRY)
4039 # Check if user specified a different registry key.
4040 case x${enable_win32_registry} in
4043 gcc_cv_win32_registry_key="$VERSION"
4046 # no registry lookup.
4047 gcc_cv_win32_registry_key=''
4050 # user-specified key.
4051 gcc_cv_win32_registry_key="$enable_win32_registry"
4055 if test x$enable_win32_registry != xno; then
4056 AC_MSG_CHECKING(registry key on windows hosts)
4057 AC_DEFINE_UNQUOTED(WIN32_REGISTRY_KEY, "$gcc_cv_win32_registry_key")
4058 AC_MSG_RESULT($gcc_cv_win32_registry_key)
4061 # Get an absolute path to the GCC top-level source directory
4067 # Conditionalize the makefile for this host machine.
4068 # Make-host contains the concatenation of all host makefile fragments
4069 # [there can be more than one]. This file is built by configure.frag.
4070 host_overrides=Make-host
4071 dep_host_xmake_file=
4072 for f in .. ${host_xmake_file}
4074 if test -f ${srcdir}/config/$f
4076 dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f"
4080 # Conditionalize the makefile for this target machine.
4081 # Make-target contains the concatenation of all host makefile fragments
4082 # [there can be more than one]. This file is built by configure.frag.
4083 target_overrides=Make-target
4085 for f in .. ${tmake_file}
4087 if test -f ${srcdir}/config/$f
4089 dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f"
4093 # If the host doesn't support symlinks, modify CC in
4094 # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works.
4095 # Otherwise, we can use "CC=$(CC)".
4097 if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null
4099 cc_set_by_configure="\$(CC)"
4100 quoted_cc_set_by_configure="\$(CC)"
4101 stage_prefix_set_by_configure="\$(STAGE_PREFIX)"
4104 if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null
4106 symbolic_link="cp -p"
4110 cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`"
4111 quoted_cc_set_by_configure="\\\`case '\\\$(CC)' in stage*) echo '\\\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\\\$(CC)';; esac\\\`"
4112 stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`"
4116 out_object_file=`basename $out_file .c`.o
4119 for f in $tm_file; do
4122 tm_file_list="${tm_file_list} $f" ;;
4123 *) tm_file_list="${tm_file_list} \$(srcdir)/config/$f" ;;
4128 for f in $host_xm_file; do
4130 auto-host.h | gansidecl.h | hwint.h )
4131 host_xm_file_list="${host_xm_file_list} $f" ;;
4132 *) host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f" ;;
4137 for f in $build_xm_file; do
4139 auto-build.h | auto-host.h | gansidecl.h | hwint.h )
4140 build_xm_file_list="${build_xm_file_list} $f" ;;
4141 *) build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f" ;;
4145 # Define macro CROSS_COMPILE in compilation
4146 # if this is a cross-compiler.
4147 # Also use all.cross instead of all.internal
4148 # and add cross-make to Makefile.
4149 cross_overrides="/dev/null"
4150 if test x$host != x$target
4152 cross_defines="CROSS=-DCROSS_COMPILE"
4153 cross_overrides="${topdir}/cross-make"
4156 # When building gcc with a cross-compiler, we need to fix a few things.
4157 # This must come after cross-make as we want all.build to override
4159 build_overrides="/dev/null"
4160 if test x$build != x$host
4162 build_overrides="${topdir}/build-make"
4165 # Expand extra_headers to include complete path.
4166 # This substitutes for lots of t-* files.
4168 if test "x$extra_headers" = x
4171 # Prepend ${srcdir}/ginclude/ to every entry in extra_headers.
4172 for file in $extra_headers;
4174 extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}"
4178 if test x$use_collect2 = xno; then
4182 # Add a definition of USE_COLLECT2 if system wants one.
4183 # Also tell toplev.c what to do.
4184 # This substitutes for lots of t-* files.
4185 if test x$use_collect2 = x
4190 will_use_collect2="collect2"
4191 maybe_use_collect2="-DUSE_COLLECT2"
4195 # Set MD_DEPS if the real md file is in md.pre-cpp.
4196 # Set MD_CPP to the cpp to pass the md file through. Md files use ';'
4197 # for line oriented comments, so we must always use a GNU cpp. If
4198 # building gcc with a cross compiler, use the cross compiler just
4199 # built. Otherwise, we can use the cpp just built.
4201 if test "x$md_cppflags" = x
4203 md_file_sub=$srcdir/config/$md_file
4208 # If we have gas in the build tree, make a link to it.
4209 if test -f ../gas/Makefile; then
4210 rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null
4213 # If we have nm in the build tree, make a link to it.
4214 if test -f ../binutils/Makefile; then
4215 rm -f nm; $symbolic_link ../binutils/nm-new$host_exeext nm$host_exeext 2>/dev/null
4218 # If we have ld in the build tree, make a link to it.
4219 if test -f ../ld/Makefile; then
4220 # if test x$use_collect2 = x; then
4221 # rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null
4223 rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null
4227 # Figure out what assembler alignment features are present.
4228 AC_MSG_CHECKING(assembler alignment features)
4230 gcc_cv_as_alignment_features=
4231 gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas
4232 if test -x "$DEFAULT_ASSEMBLER"; then
4233 gcc_cv_as="$DEFAULT_ASSEMBLER"
4234 elif test -x "$AS"; then
4236 elif test -x as$host_exeext; then
4237 # Build using assembler in the current directory.
4238 gcc_cv_as=./as$host_exeext
4239 elif test -f $gcc_cv_as_gas_srcdir/configure.in -a -f ../gas/Makefile; then
4240 # Single tree build which includes gas.
4241 for f in $gcc_cv_as_gas_srcdir/configure $gcc_cv_as_gas_srcdir/configure.in $gcc_cv_as_gas_srcdir/Makefile.in
4244 gcc_cv_gas_version=`grep '^VERSION=[0-9]*\.[0-9]*' $f`
4246 if test x$gcc_cv_gas_version != x; then
4251 gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
4252 gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
4254 if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
4255 # Gas version 2.6 and later support for .balign and .p2align.
4256 # bytes to skip when using .p2align.
4257 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
4258 gcc_cv_as_alignment_features=".balign and .p2align"
4259 AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
4261 # Gas version 2.8 and later support specifying the maximum
4262 # bytes to skip when using .p2align.
4263 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
4264 gcc_cv_as_alignment_features=".p2align including maximum skip"
4265 AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
4268 elif test x$host = x$target; then
4270 # Search the same directories that the installed compiler will
4271 # search. Else we may find the wrong assembler and lose. If we
4272 # do not find a suitable assembler binary, then try the user's
4275 # Also note we have to check MD_EXEC_PREFIX before checking the
4276 # user's path. Unfortunately, there is no good way to get at the
4277 # value of MD_EXEC_PREFIX here. So we do a brute force search
4278 # through all the known MD_EXEC_PREFIX values. Ugh. This needs
4279 # to be fixed as part of the make/configure rewrite too.
4281 if test "x$exec_prefix" = xNONE; then
4282 if test "x$prefix" = xNONE; then
4283 test_prefix=/usr/local
4288 test_prefix=$exec_prefix
4291 # If the loop below does not find an assembler, then use whatever
4292 # one we can find in the users's path.
4296 test_dirs="$test_prefix/lib/gcc-lib/$target/$gcc_version \
4297 $test_prefix/lib/gcc-lib/$target \
4298 /usr/lib/gcc/$target/$gcc_version \
4299 /usr/lib/gcc/$target \
4300 $test_prefix/$target/bin/$target/$gcc_version \
4301 $test_prefix/$target/bin \
4306 /bsd43/usr/lib/cmplrs/cc \
4307 /usr/cross64/usr/bin \
4308 /usr/lib/cmplrs/cc \
4309 /sysv/usr/lib/cmplrs/cc \
4310 /svr4/usr/lib/cmplrs/cc \
4313 for dir in $test_dirs; do
4314 if test -f $dir/as$host_exeext; then
4315 gcc_cv_as=$dir/as$host_exeext
4320 if test x$gcc_cv_as != x; then
4321 # Check if we have .balign and .p2align
4322 echo ".balign 4" > conftest.s
4323 echo ".p2align 2" >> conftest.s
4324 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4325 gcc_cv_as_alignment_features=".balign and .p2align"
4326 AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
4328 rm -f conftest.s conftest.o
4329 # Check if specifying the maximum bytes to skip when
4330 # using .p2align is supported.
4331 echo ".p2align 4,,7" > conftest.s
4332 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4333 gcc_cv_as_alignment_features=".p2align including maximum skip"
4334 AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
4336 rm -f conftest.s conftest.o
4338 AC_MSG_RESULT($gcc_cv_as_alignment_features)
4340 AC_MSG_CHECKING(assembler subsection support)
4341 gcc_cv_as_subsections=
4342 if test x$gcc_cv_as != x; then
4343 # Check if we have .subsection
4344 echo ".subsection 1" > conftest.s
4345 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4346 gcc_cv_as_subsections=".subsection"
4347 if test -x nm$host_exeext; then
4348 gcc_cv_nm=./nm$host_exeext
4349 elif test x$host = x$target; then
4351 gcc_cv_nm=nm$host_exeext
4353 if test x$gcc_cv_nm != x; then
4354 cat > conftest.s <<EOF
4355 conftest_label1: .word 0
4357 conftest_label2: .word 0
4360 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4361 $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1
4362 $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2
4363 if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1; then
4366 gcc_cv_as_subsections="working .subsection -1"
4367 AC_DEFINE(HAVE_GAS_SUBSECTION_ORDERING)
4372 rm -f conftest.s conftest.o conftest.nm1 conftest.nm2
4374 AC_MSG_RESULT($gcc_cv_as_subsections)
4378 AC_CACHE_CHECK([assembler .register pseudo-op support],
4379 gcc_cv_as_register_pseudo_op, [
4380 gcc_cv_as_register_pseudo_op=unknown
4381 if test x$gcc_cv_as != x; then
4382 # Check if we have .register
4383 echo ".register %g2, #scratch" > conftest.s
4384 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4385 gcc_cv_as_register_pseudo_op=yes
4387 gcc_cv_as_register_pseudo_op=no
4389 rm -f conftest.s conftest.o
4392 if test "x$gcc_cv_as_register_pseudo_op" = xyes; then
4393 AC_DEFINE(HAVE_AS_REGISTER_PSEUDO_OP)
4398 AC_CACHE_CHECK([for 64 bit support in assembler ($gcc_cv_as)],
4399 gcc_cv_as_flags64, [
4400 if test -n "$gcc_cv_as"; then
4401 echo ".xword foo" > conftest.s
4402 gcc_cv_as_flags64=no
4403 for flag in "-xarch=v9" "-64 -Av9"; do
4404 if $gcc_cv_as $flag -o conftest.o conftest.s \
4405 > /dev/null 2>&1; then
4406 gcc_cv_as_flags64=$flag
4410 rm -f conftest.s conftest.o
4412 if test "$gas" = yes; then
4413 gcc_cv_as_flags64="-64 -Av9"
4415 gcc_cv_as_flags64="-xarch=v9"
4419 if test "x$gcc_cv_as_flags64" = xno; then
4421 tmake_file=`echo " $tmake_file " | sed -e 's, sparc/t-sol2-64 , ,' -e 's,^ ,,' -e 's, $,,'`
4422 dep_tmake_file=`echo " $dep_tmake_file " | sed -e 's, [^ ]*/config/sparc/t-sol2-64 , ,' -e 's,^ ,,' -e 's, $,,'`
4425 AC_DEFINE_UNQUOTED(AS_SPARC64_FLAG, "$gcc_cv_as_flags64")
4428 *) gcc_cv_as_flags64=${gcc_cv_as_flags64-no}
4432 if test "x$gcc_cv_as_flags64" != xno; then
4433 AC_CACHE_CHECK([for assembler offsetable %lo() support],
4434 gcc_cv_as_offsetable_lo10, [
4435 gcc_cv_as_offsetable_lo10=unknown
4436 if test "x$gcc_cv_as" != x; then
4437 # Check if assembler has offsetable %lo()
4438 echo "or %g1, %lo(ab) + 12, %g1" > conftest.s
4439 echo "or %g1, %lo(ab + 12), %g1" > conftest1.s
4440 if $gcc_cv_as $gcc_cv_as_flags64 -o conftest.o conftest.s \
4442 $gcc_cv_as $gcc_cv_as_flags64 -o conftest1.o conftest1.s \
4443 > /dev/null 2>&1; then
4444 if cmp conftest.o conftest1.o > /dev/null 2>&1; then
4445 gcc_cv_as_offsetable_lo10=no
4447 gcc_cv_as_offsetable_lo10=yes
4450 gcc_cv_as_offsetable_lo10=no
4452 rm -f conftest.s conftest.o conftest1.s conftest1.o
4455 if test "x$gcc_cv_as_offsetable_lo10" = xyes; then
4456 AC_DEFINE(HAVE_AS_OFFSETABLE_LO10)
4464 AC_MSG_CHECKING(assembler instructions)
4465 gcc_cv_as_instructions=
4466 if test x$gcc_cv_as != x; then
4467 set "filds fists" "filds mem; fists mem"
4470 echo "$2" > conftest.s
4471 if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
4472 gcc_cv_as_instructions=${gcc_cv_as_instructions}$1" "
4473 AC_DEFINE_UNQUOTED(HAVE_GAS_`echo "$1" | tr '[a-z ]' '[A-Z_]'`)
4477 rm -f conftest.s conftest.o
4479 AC_MSG_RESULT($gcc_cv_as_instructions)
4483 # Figure out what language subdirectories are present.
4484 # Look if the user specified --enable-languages="..."; if not, use
4485 # the environment variable $LANGUAGES if defined. $LANGUAGES might
4487 if test x"${enable_languages+set}" != xset; then
4488 if test x"${LANGUAGES+set}" = xset; then
4489 enable_languages="`echo ${LANGUAGES} | tr ' ' ','`"
4491 enable_languages=all
4495 for lang in ${srcdir}/*/config-lang.in ..
4499 # The odd quoting in the next line works around
4500 # an apparent bug in bash 1.12 on linux.
4502 ${srcdir}/[*]/config-lang.in) ;;
4504 lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
4505 if test "x$lang_alias" = x
4507 echo "$lang doesn't set \$language." 1>&2
4510 if test x"${enable_languages}" = xall; then
4513 case "${enable_languages}" in
4514 ${lang_alias} | "${lang_alias},"* | *",${lang_alias},"* | *",${lang_alias}" )
4522 if test x"${add_this_lang}" = xyes; then
4524 ${srcdir}/ada/config-lang.in)
4525 if test x$gnat = xyes ; then
4526 subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
4530 subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
4539 # Make gthr-default.h if we have a thread file.
4541 if test $thread_file != single; then
4542 rm -f gthr-default.h
4543 echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h
4544 gthread_flags=-DHAVE_GTHR_DEFAULT
4546 AC_SUBST(gthread_flags)
4548 # Find out what GC implementation we want, or may, use.
4550 [ --with-gc={simple,page} Choose the garbage collection mechanism to use
4551 with the compiler.],
4557 AC_MSG_ERROR([$withval is an invalid option to --with-gc])
4560 [if test $ac_cv_func_mmap_fixed_mapped = yes; then
4562 elif test $ac_cv_func_valloc = yes; then
4568 echo "Using $GGC for garbage collection."
4570 # Make empty files to contain the specs and options for each language.
4571 # Then add #include lines to for a compiler that has specs and/or options.
4576 rm -f specs.h options.h gencheck.h
4577 touch specs.h options.h gencheck.h
4578 for subdir in . $subdirs
4580 if test -f $srcdir/$subdir/lang-specs.h; then
4581 echo "#include \"$subdir/lang-specs.h\"" >>specs.h
4582 lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h"
4584 if test -f $srcdir/$subdir/lang-options.h; then
4585 echo "#include \"$subdir/lang-options.h\"" >>options.h
4586 lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h"
4588 if test -f $srcdir/$subdir/$subdir-tree.def; then
4589 echo "#include \"$subdir/$subdir-tree.def\"" >>gencheck.h
4590 lang_tree_files="$lang_tree_files $srcdir/$subdir/$subdir-tree.def"
4594 # These (without "all_") are set in each config-lang.in.
4595 # `language' must be a single word so is spelled singularly.
4601 all_outputs='Makefile intl/Makefile po/Makefile.in fixinc/Makefile'
4602 # List of language makefile fragments.
4607 # Add the language fragments.
4608 # Languages are added via two mechanisms. Some information must be
4609 # recorded in makefile variables, these are defined in config-lang.in.
4610 # We accumulate them and plug them into the main Makefile.
4611 # The other mechanism is a set of hooks for each of the main targets
4612 # like `clean', `install', etc.
4614 language_fragments="Make-lang"
4615 language_hooks="Make-hooks"
4618 for s in .. $subdirs
4630 . ${srcdir}/$s/config-lang.in
4631 if test "x$language" = x
4633 echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2
4636 all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in ${srcdir}/$s/Makefile.in"
4637 all_languages="$all_languages $language"
4638 if test "x$boot_language" = xyes
4640 all_boot_languages="$all_boot_languages $language"
4642 all_compilers="$all_compilers $compilers"
4643 all_stagestuff="$all_stagestuff $stagestuff"
4644 all_diff_excludes="$all_diff_excludes $diff_excludes"
4645 all_headers="$all_headers $headers"
4646 all_outputs="$all_outputs $outputs"
4647 if test x$outputs = x
4649 oldstyle_subdirs="$oldstyle_subdirs $s"
4651 all_lib2funcs="$all_lib2funcs $lib2funcs"
4655 # Since we can't use `::' targets, we link each language in
4656 # with a set of hooks, reached indirectly via lang.${target}.
4660 target_list="all.build all.cross start.encap rest.encap \
4662 install-normal install-common install-info install-man \
4664 mostlyclean clean distclean extraclean maintainer-clean \
4665 stage1 stage2 stage3 stage4"
4666 for t in $target_list
4669 for lang in .. $all_languages
4671 if test $lang != ".."; then
4675 echo "lang.$t: $x" >> Make-hooks
4678 # If we're not building in srcdir, create .gdbinit.
4680 if test ! -f Makefile.in; then
4681 echo "dir ." > .gdbinit
4682 echo "dir ${srcdir}" >> .gdbinit
4683 if test x$gdb_needs_out_file_path = xyes
4685 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
4687 if test "x$subdirs" != x; then
4690 echo "dir ${srcdir}/$s" >> .gdbinit
4693 echo "source ${srcdir}/.gdbinit" >> .gdbinit
4696 # Define variables host_canonical and build_canonical
4697 # because some Cygnus local changes in the Makefile depend on them.
4698 build_canonical=${build}
4699 host_canonical=${host}
4701 if test "${host}" != "${target}" ; then
4702 target_subdir=${target}/
4704 AC_SUBST(build_canonical)
4705 AC_SUBST(host_canonical)
4706 AC_SUBST(target_subdir)
4708 # If this is using newlib, then define inhibit_libc in
4709 # LIBGCC2_CFLAGS. This will cause __eprintf to be left out of
4710 # libgcc.a, but that's OK because newib should have its own version of
4713 if test x$with_newlib = xyes; then
4714 inhibit_libc=-Dinhibit_libc
4716 AC_SUBST(inhibit_libc)
4718 # If $(exec_prefix) exists and is not the same as $(prefix), then compute an
4719 # absolute path for gcc_tooldir based on inserting the number of up-directory
4720 # movements required to get from $(exec_prefix) to $(prefix) into the basic
4721 # $(libsubdir)/@(unlibsubdir) based path.
4722 # Don't set gcc_tooldir to tooldir since that's only passed in by the toplevel
4723 # make and thus we'd get different behavior depending on where we built the
4725 if test x$exec_prefix = xNONE -o x$exec_prefix = x$prefix; then
4726 gcc_tooldir='$(libsubdir)/$(unlibsubdir)/../$(target_alias)'
4728 changequote(<<, >>)dnl
4729 # An explanation of the sed strings:
4730 # -e 's|^\$(prefix)||' matches and eliminates 'prefix' from 'exec_prefix'
4731 # -e 's|/$||' match a trailing forward slash and eliminates it
4732 # -e 's|^[^/]|/|' forces the string to start with a forward slash (*)
4733 # -e 's|/[^/]*|../|g' replaces each occurance of /<directory> with ../
4735 # (*) Note this pattern overwrites the first character of the string
4736 # with a forward slash if one is not already present. This is not a
4737 # problem because the exact names of the sub-directories concerned is
4738 # unimportant, just the number of them matters.
4740 # The practical upshot of these patterns is like this:
4742 # prefix exec_prefix result
4743 # ------ ----------- ------
4745 # /foo/ /foo/bar ../
4746 # /foo /foo/bar/ ../
4747 # /foo/ /foo/bar/ ../
4748 # /foo /foo/bar/ugg ../../
4751 gcc_tooldir="\$(libsubdir)/\$(unlibsubdir)/\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/\$(dollar)||' -e 's|^[^/]|/|' -e 's|/[^/]*|../|g'\`\$(target_alias)"
4752 changequote([, ])dnl
4754 AC_SUBST(gcc_tooldir)
4757 # Nothing to do for FLOAT_H, float_format already handled.
4761 # Process the language and host/target makefile fragments.
4762 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
4764 # Substitute configuration variables
4766 AC_SUBST(all_boot_languages)
4767 AC_SUBST(all_compilers)
4768 AC_SUBST(all_diff_excludes)
4769 AC_SUBST(all_headers)
4770 AC_SUBST(all_lang_makefiles)
4771 AC_SUBST(all_languages)
4772 AC_SUBST(all_lib2funcs)
4773 AC_SUBST(all_stagestuff)
4774 AC_SUBST(build_exeext)
4775 AC_SUBST(build_install_headers_dir)
4776 AC_SUBST(build_xm_file_list)
4777 AC_SUBST(cc_set_by_configure)
4778 AC_SUBST(quoted_cc_set_by_configure)
4779 AC_SUBST(cpp_install_dir)
4781 AC_SUBST(dep_host_xmake_file)
4782 AC_SUBST(dep_tmake_file)
4783 AC_SUBST(extra_c_flags)
4784 AC_SUBST(extra_c_objs)
4785 AC_SUBST(extra_cpp_objs)
4786 AC_SUBST(extra_cxx_objs)
4787 AC_SUBST(extra_headers_list)
4788 AC_SUBST(extra_objs)
4789 AC_SUBST(extra_parts)
4790 AC_SUBST(extra_passes)
4791 AC_SUBST(extra_programs)
4792 AC_SUBST(fixinc_defs)
4793 AC_SUBST(float_h_file)
4794 AC_SUBST(gcc_gxx_include_dir)
4795 AC_SUBST(gcc_version)
4796 AC_SUBST(gcc_version_trigger)
4797 AC_SUBST(host_exeext)
4798 AC_SUBST(host_extra_gcc_objs)
4799 AC_SUBST(host_xm_file_list)
4801 AC_SUBST(lang_options_files)
4802 AC_SUBST(lang_specs_files)
4803 AC_SUBST(lang_tree_files)
4804 AC_SUBST(local_prefix)
4805 AC_SUBST(maybe_use_collect2)
4807 AC_SUBST(objc_boehm_gc)
4809 AC_SUBST(out_object_file)
4810 AC_SUBST(stage_prefix_set_by_configure)
4811 AC_SUBST(symbolic_link)
4812 AC_SUBST(thread_file)
4813 AC_SUBST(tm_file_list)
4814 AC_SUBST(will_use_collect2)
4817 AC_SUBST_FILE(target_overrides)
4818 AC_SUBST_FILE(host_overrides)
4819 AC_SUBST(cross_defines)
4820 AC_SUBST_FILE(cross_overrides)
4821 AC_SUBST_FILE(build_overrides)
4822 AC_SUBST_FILE(language_fragments)
4823 AC_SUBST_FILE(language_hooks)
4825 # Echo that links are built
4826 if test x$host = x$target
4834 if test x$host != x$build
4836 str3=" on a $build system"
4839 if test "x$str2" != x || test "x$str3" != x
4844 echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2
4846 if test "x$str2" != x || test "x$str3" != x
4848 echo " ${str2}${str3}." 1>&2
4851 # Truncate the target if necessary
4852 if test x$host_truncate_target != x; then
4853 target=`echo $target | sed -e 's/\(..............\).*/\1/'`
4856 # Configure the subdirectories
4857 # AC_CONFIG_SUBDIRS($subdirs)
4859 # Create the Makefile
4860 # and configure language subdirectories
4861 AC_OUTPUT($all_outputs,
4863 . $srcdir/configure.lang
4864 case x$CONFIG_HEADERS in
4865 xauto-host.h:config.in)
4868 # If the host supports symlinks, point stage[1234] at ../stage[1234] so
4869 # bootstrapping and the installation procedure can still use
4870 # CC="stage1/xgcc -Bstage1/". If the host doesn't support symlinks,
4871 # FLAGS_TO_PASS has been modified to solve the problem there.
4872 # This is virtually a duplicate of what happens in configure.lang; we do
4873 # an extra check to make sure this only happens if ln -s can be used.
4874 if test "$symbolic_link" = "ln -s"; then
4875 for d in .. ${subdirs} ; do
4876 if test $d != ..; then
4879 for t in stage1 stage2 stage3 stage4 include
4882 $symbolic_link ../$t $t 2>/dev/null
4888 # Avoid having to add intl to our include paths.
4889 if test -f intl/libintl.h; then
4890 echo creating libintl.h
4891 echo '#include "intl/libintl.h"' >libintl.h
4898 target_alias='${target_alias}'
4900 subdirs='${subdirs}'
4901 oldstyle_subdirs='${oldstyle_subdirs}'
4902 symbolic_link='${symbolic_link}'
4903 program_transform_set='${program_transform_set}'
4904 program_transform_name='${program_transform_name}'
4905 dep_host_xmake_file='${dep_host_xmake_file}'
4906 host_xmake_file='${host_xmake_file}'
4907 dep_tmake_file='${dep_tmake_file}'
4908 tmake_file='${tmake_file}'
4909 thread_file='${thread_file}'
4910 gcc_version='${gcc_version}'
4911 gcc_version_trigger='${gcc_version_trigger}'
4912 local_prefix='${local_prefix}'
4913 build_install_headers_dir='${build_install_headers_dir}'
4914 build_exeext='${build_exeext}'
4915 host_exeext='${host_exeext}'
4916 out_file='${out_file}'
4917 gdb_needs_out_file_path='${gdb_needs_out_file_path}'
4918 SET_MAKE='${SET_MAKE}'
4919 target_list='${target_list}'
4920 target_overrides='${target_overrides}'
4921 host_overrides='${host_overrides}'
4922 cross_defines='${cross_defines}'
4923 cross_overrides='${cross_overrides}'
4924 build_overrides='${build_overrides}'
4925 cpp_install_dir='${cpp_install_dir}'