]>
Commit | Line | Data |
---|---|---|
46f18e7b RK |
1 | # configure.in for GNU CC |
2 | # Process this file with autoconf to generate a configuration script. | |
3 | ||
3ed06573 | 4 | # Copyright (C) 1997, 1998, 1999, 2000 Free Software Foundation, Inc. |
46f18e7b RK |
5 | |
6 | #This file is part of GNU CC. | |
7 | ||
8 | #GNU CC is free software; you can redistribute it and/or modify | |
9 | #it under the terms of the GNU General Public License as published by | |
10 | #the Free Software Foundation; either version 2, or (at your option) | |
11 | #any later version. | |
12 | ||
13 | #GNU CC is distributed in the hope that it will be useful, | |
14 | #but WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 | #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
16 | #GNU General Public License for more details. | |
17 | ||
18 | #You should have received a copy of the GNU General Public License | |
19 | #along with GNU CC; see the file COPYING. If not, write to | |
20 | #the Free Software Foundation, 59 Temple Place - Suite 330, | |
21 | #Boston, MA 02111-1307, USA. | |
22 | ||
23 | # Initialization and defaults | |
890ad3ea | 24 | AC_PREREQ(2.13) |
46f18e7b | 25 | AC_INIT(tree.c) |
b7cb92ad | 26 | AC_CONFIG_HEADER(auto-host.h:config.in) |
cdcc6a01 | 27 | |
46f18e7b RK |
28 | remove=rm |
29 | hard_link=ln | |
30 | symbolic_link='ln -s' | |
31 | copy=cp | |
32 | ||
75a39864 JL |
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 | |
37 | # is true: | |
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) | |
42 | changequote(,)dnl | |
43 | case ${LIBRARY_PATH} in | |
44 | [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* ) | |
45 | library_path_setting="contains current directory" | |
46 | ;; | |
47 | *) | |
48 | library_path_setting="ok" | |
49 | ;; | |
50 | esac | |
51 | changequote([,])dnl | |
52 | AC_MSG_RESULT($library_path_setting) | |
53 | if test "$library_path_setting" != "ok"; then | |
54 | AC_MSG_ERROR([ | |
55 | *** LIBRARY_PATH shouldn't contain the current directory when | |
079bd08e | 56 | *** building gcc. Please change the environment variable |
75a39864 JL |
57 | *** and run configure again.]) |
58 | fi | |
59 | ||
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 | |
63 | # is true: | |
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) | |
68 | changequote(,)dnl | |
69 | case ${GCC_EXEC_PREFIX} in | |
70 | [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* ) | |
71 | gcc_exec_prefix_setting="contains current directory" | |
72 | ;; | |
73 | *) | |
74 | gcc_exec_prefix_setting="ok" | |
75 | ;; | |
76 | esac | |
77 | changequote([,])dnl | |
78 | AC_MSG_RESULT($gcc_exec_prefix_setting) | |
79 | if test "$gcc_exec_prefix_setting" != "ok"; then | |
80 | AC_MSG_ERROR([ | |
81 | *** GCC_EXEC_PREFIX shouldn't contain the current directory when | |
079bd08e | 82 | *** building gcc. Please change the environment variable |
75a39864 JL |
83 | *** and run configure again.]) |
84 | fi | |
85 | ||
46f18e7b RK |
86 | # Check for additional parameters |
87 | ||
88 | # With GNU ld | |
89 | AC_ARG_WITH(gnu-ld, | |
90 | [ --with-gnu-ld arrange to work with GNU ld.], | |
df6faf79 JW |
91 | gnu_ld_flag="$with_gnu_ld", |
92 | gnu_ld_flag=no) | |
46f18e7b | 93 | |
ab339d62 AO |
94 | # With pre-defined ld |
95 | AC_ARG_WITH(ld, | |
96 | [ --with-ld arrange to use the specified ld (full pathname).], | |
3ccc3a56 AO |
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]) | |
e154a394 | 101 | elif $DEFAULT_LINKER -v < /dev/null 2>&1 | grep GNU > /dev/null; then |
ab339d62 AO |
102 | gnu_ld_flag=yes |
103 | fi | |
119d24d1 KG |
104 | AC_DEFINE_UNQUOTED(DEFAULT_LINKER,"$DEFAULT_LINKER", |
105 | [Define to enable the use of a default linker.]) | |
ab339d62 AO |
106 | fi |
107 | ||
46f18e7b RK |
108 | # With GNU as |
109 | AC_ARG_WITH(gnu-as, | |
4d8392b7 | 110 | [ --with-gnu-as arrange to work with GNU as.], |
df6faf79 JW |
111 | gas_flag="$with_gnu_as", |
112 | gas_flag=no) | |
46f18e7b | 113 | |
ab339d62 AO |
114 | AC_ARG_WITH(as, |
115 | [ --with-as arrange to use the specified as (full pathname).], | |
3ccc3a56 AO |
116 | DEFAULT_ASSEMBLER="$with_as") |
117 | if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then | |
118 | if test ! -x "$DEFAULT_ASSEMBLER"; then | |
119 | AC_MSG_WARN([cannot execute: $DEFAULT_ASSEMBLER: check --with-as or env. var. DEFAULT_ASSEMBLER]) | |
e154a394 | 120 | elif $DEFAULT_ASSEMBLER -v < /dev/null 2>&1 | grep GNU > /dev/null; then |
ab339d62 AO |
121 | gas_flag=yes |
122 | fi | |
119d24d1 KG |
123 | AC_DEFINE_UNQUOTED(DEFAULT_ASSEMBLER,"$DEFAULT_ASSEMBLER", |
124 | [Define to enable the use of a default assembler.]) | |
3ccc3a56 | 125 | fi |
ab339d62 | 126 | |
46f18e7b RK |
127 | # With stabs |
128 | AC_ARG_WITH(stabs, | |
129 | [ --with-stabs arrange to use stabs instead of host debug format.], | |
535b86ce | 130 | stabs="$with_stabs", |
46f18e7b RK |
131 | stabs=no) |
132 | ||
133 | # With ELF | |
134 | AC_ARG_WITH(elf, | |
135 | [ --with-elf arrange to use ELF instead of host debug format.], | |
535b86ce | 136 | elf="$with_elf", |
46f18e7b RK |
137 | elf=no) |
138 | ||
4d8392b7 | 139 | # Specify the local prefix |
4e88d51b | 140 | local_prefix= |
4d8392b7 RK |
141 | AC_ARG_WITH(local-prefix, |
142 | [ --with-local-prefix=DIR specifies directory to put local include.], | |
4e88d51b JM |
143 | [case "${withval}" in |
144 | yes) AC_MSG_ERROR(bad value ${withval} given for local include directory prefix) ;; | |
145 | no) ;; | |
146 | *) local_prefix=$with_local_prefix ;; | |
147 | esac]) | |
4d8392b7 RK |
148 | |
149 | # Default local prefix if it is empty | |
75bffa71 | 150 | if test x$local_prefix = x; then |
4d8392b7 RK |
151 | local_prefix=/usr/local |
152 | fi | |
153 | ||
8f8d3278 NC |
154 | # Don't set gcc_gxx_include_dir to gxx_include_dir since that's only |
155 | # passed in by the toplevel make and thus we'd get different behavior | |
156 | # depending on where we built the sources. | |
157 | gcc_gxx_include_dir= | |
9514f0d1 RK |
158 | # Specify the g++ header file directory |
159 | AC_ARG_WITH(gxx-include-dir, | |
160 | [ --with-gxx-include-dir=DIR | |
161 | specifies directory to put g++ header files.], | |
4e88d51b JM |
162 | [case "${withval}" in |
163 | yes) AC_MSG_ERROR(bad value ${withval} given for g++ include directory) ;; | |
164 | no) ;; | |
8f8d3278 | 165 | *) gcc_gxx_include_dir=$with_gxx_include_dir ;; |
4e88d51b JM |
166 | esac]) |
167 | ||
8f8d3278 | 168 | if test x${gcc_gxx_include_dir} = x; then |
4e88d51b | 169 | if test x${enable_version_specific_runtime_libs} = xyes; then |
8f8d3278 | 170 | gcc_gxx_include_dir='${libsubdir}/include/g++' |
4e88d51b | 171 | else |
a270b446 | 172 | topsrcdir=${srcdir}/.. . ${srcdir}/../config.if |
de82584d | 173 | changequote(<<, >>)dnl |
8f8d3278 | 174 | gcc_gxx_include_dir="\$(libsubdir)/\$(unlibsubdir)/..\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/[^/]*|/..|g'\`/include/g++"-${libstdcxx_interface} |
de82584d | 175 | changequote([, ])dnl |
4e88d51b JM |
176 | fi |
177 | fi | |
46f18e7b | 178 | |
a494747c MM |
179 | # Enable expensive internal checks |
180 | AC_ARG_ENABLE(checking, | |
f4524c9e ZW |
181 | [ --enable-checking[=LIST] |
182 | enable expensive run-time checks. With LIST, | |
183 | enable only specific categories of checks. | |
184 | Categories are: misc,tree,rtl,gc,gcac; default | |
59f406b7 | 185 | is misc,tree,gc], |
119d24d1 KG |
186 | [ac_checking= |
187 | ac_tree_checking= | |
188 | ac_rtl_checking= | |
189 | ac_gc_checking= | |
190 | ac_gc_always_collect= | |
191 | case "${enableval}" in | |
51d0e20c | 192 | yes) ac_checking=1 ; ac_tree_checking=1 ; ac_gc_checking=1 ;; |
4e88d51b | 193 | no) ;; |
59f406b7 | 194 | *) IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS," |
f4524c9e ZW |
195 | set fnord $enableval; shift |
196 | IFS="$ac_save_IFS" | |
c62e45ad KG |
197 | for check |
198 | do | |
f4524c9e | 199 | case $check in |
119d24d1 KG |
200 | misc) ac_checking=1 ;; |
201 | tree) ac_tree_checking=1 ;; | |
202 | rtl) ac_rtl_checking=1 ;; | |
203 | gc) ac_gc_checking=1 ;; | |
204 | gcac) ac_gc_always_collect=1 ;; | |
f4524c9e ZW |
205 | *) AC_MSG_ERROR(unknown check category $check) ;; |
206 | esac | |
207 | done | |
208 | ;; | |
119d24d1 | 209 | esac |
51d0e20c AJ |
210 | ], |
211 | # Enable some checks by default for development versions of GCC | |
212 | [ac_checking=1; ac_tree_checking=1; ac_gc_checking=1;]) | |
119d24d1 KG |
213 | if test x$ac_checking != x ; then |
214 | AC_DEFINE(ENABLE_CHECKING, 1, | |
215 | [Define if you want more run-time sanity checks. This one gets a grab | |
216 | bag of miscellaneous but relatively cheap checks.]) | |
217 | fi | |
218 | if test x$ac_tree_checking != x ; then | |
219 | AC_DEFINE(ENABLE_TREE_CHECKING, 1, | |
220 | [Define if you want all operations on trees (the basic data | |
221 | structure of the front ends) to be checked for dynamic type safety | |
222 | at runtime. This is moderately expensive.]) | |
223 | fi | |
224 | if test x$ac_rtl_checking != x ; then | |
225 | AC_DEFINE(ENABLE_RTL_CHECKING, 1, | |
226 | [Define if you want all operations on RTL (the basic data structure | |
227 | of the optimizer and back end) to be checked for dynamic type safety | |
228 | at runtime. This is quite expensive.]) | |
229 | fi | |
230 | if test x$ac_gc_checking != x ; then | |
231 | AC_DEFINE(ENABLE_GC_CHECKING, 1, | |
232 | [Define if you want the garbage collector to do object poisoning and | |
233 | other memory allocation checks. This is quite expensive.]) | |
234 | fi | |
235 | if test x$ac_gc_always_collect != x ; then | |
236 | AC_DEFINE(ENABLE_GC_ALWAYS_COLLECT, 1, | |
237 | [Define if you want the garbage collector to operate in maximally | |
238 | paranoid mode, validating the entire heap and collecting garbage at | |
239 | every opportunity. This is extremely expensive.]) | |
240 | fi | |
51d0e20c | 241 | |
a494747c | 242 | |
3ecc3258 ZW |
243 | AC_ARG_ENABLE(cpp, |
244 | [ --disable-cpp don't provide a user-visible C preprocessor.], | |
245 | [], [enable_cpp=yes]) | |
246 | ||
247 | AC_ARG_WITH(cpp_install_dir, | |
248 | [ --with-cpp-install-dir=DIR | |
249 | install the user visible C preprocessor in DIR | |
250 | (relative to PREFIX) as well as PREFIX/bin.], | |
251 | [if test x$withval = xyes; then | |
252 | AC_MSG_ERROR([option --with-cpp-install-dir requires an argument]) | |
253 | elif test x$withval != xno; then | |
254 | cpp_install_dir=$withval | |
255 | fi]) | |
256 | ||
04e3be98 NB |
257 | # Link cpplib into the compiler proper, for C/C++/ObjC. Defaults to on. |
258 | maybe_cpplib=libcpp.a | |
9ec7291f ZW |
259 | AC_ARG_ENABLE(c-cpplib, |
260 | [ --enable-c-cpplib link cpplib directly into C and C++ compilers | |
261 | (HIGHLY EXPERIMENTAL).], | |
04e3be98 NB |
262 | [if test x$enable_c_cpplib != xyes; then |
263 | maybe_cpplib= | |
264 | fi] | |
265 | ) | |
266 | if test x$maybe_cpplib != x ; then | |
9ec7291f | 267 | AC_DEFINE(USE_CPPLIB, 1, |
b8dad04b | 268 | [Define if you want the preprocessor merged into the C and C++ compilers.]) |
04e3be98 | 269 | fi |
b8dad04b | 270 | AC_SUBST(maybe_cpplib) |
f81a440f | 271 | |
c5c76735 JL |
272 | # Enable Multibyte Characters for C/C++ |
273 | AC_ARG_ENABLE(c-mbchar, | |
274 | [ --enable-c-mbchar Enable multibyte characters for C and C++.], | |
2618c083 | 275 | if test x$enable_c_mbchar != xno; then |
9ec7291f ZW |
276 | AC_DEFINE(MULTIBYTE_CHARS, 1, |
277 | [Define if you want the C and C++ compilers to support multibyte | |
278 | character sets for source code.]) | |
c5c76735 JL |
279 | fi) |
280 | ||
0bbb1697 RK |
281 | # Enable threads |
282 | # Pass with no value to take the default | |
283 | # Pass with a value to specify a thread package | |
284 | AC_ARG_ENABLE(threads, | |
285 | [ --enable-threads enable thread usage for target GCC. | |
981d4858 | 286 | --enable-threads=LIB use LIB thread package for target GCC.],, |
0bbb1697 RK |
287 | enable_threads='') |
288 | ||
e445171e | 289 | enable_threads_flag=$enable_threads |
0bbb1697 | 290 | # Check if a valid thread package |
e445171e | 291 | case x${enable_threads_flag} in |
0bbb1697 RK |
292 | x | xno) |
293 | # No threads | |
a851212a | 294 | target_thread_file='single' |
0bbb1697 RK |
295 | ;; |
296 | xyes) | |
297 | # default | |
a851212a | 298 | target_thread_file='' |
0bbb1697 RK |
299 | ;; |
300 | xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \ | |
a473fe45 | 301 | xsolaris | xwin32 | xdce | xvxworks | xaix) |
e445171e | 302 | target_thread_file=$enable_threads_flag |
0bbb1697 RK |
303 | ;; |
304 | *) | |
305 | echo "$enable_threads is an unknown thread package" 1>&2 | |
306 | exit 1 | |
307 | ;; | |
308 | esac | |
309 | ||
d8bb17c8 OP |
310 | AC_ARG_ENABLE(objc-gc, |
311 | [ --enable-objc-gc enable the use of Boehm's garbage collector with | |
312 | the GNU Objective-C runtime.], | |
2618c083 | 313 | if test x$enable_objc_gc = xno; then |
d8bb17c8 OP |
314 | objc_boehm_gc='' |
315 | else | |
316 | objc_boehm_gc=1 | |
317 | fi, | |
318 | objc_boehm_gc='') | |
319 | ||
90e6a802 | 320 | AC_ARG_WITH(dwarf2, |
756ee602 | 321 | [ --with-dwarf2 force the default debug format to be DWARF2.], |
90e6a802 RL |
322 | dwarf2="$with_dwarf2", |
323 | dwarf2=no) | |
324 | ||
50503ac8 RH |
325 | AC_ARG_ENABLE(shared, |
326 | [ --disable-shared don't provide a shared libgcc.], | |
327 | [], [enable_shared=yes]) | |
328 | AC_SUBST(enable_shared) | |
329 | ||
46f18e7b RK |
330 | # Determine the host, build, and target systems |
331 | AC_CANONICAL_SYSTEM | |
332 | ||
e9a25f70 JL |
333 | # Find the native compiler |
334 | AC_PROG_CC | |
3ec83fc2 | 335 | AC_PROG_CC_C_O |
b8dad04b | 336 | # autoconf is lame and doesn't give us any substitution variable for this. |
e38df833 | 337 | if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then |
b4c7e567 | 338 | NO_MINUS_C_MINUS_O=yes |
b8dad04b ZW |
339 | else |
340 | OUTPUT_OPTION='-o $@' | |
b4c7e567 | 341 | fi |
3ec83fc2 | 342 | AC_SUBST(NO_MINUS_C_MINUS_O) |
b8dad04b | 343 | AC_SUBST(OUTPUT_OPTION) |
3ec83fc2 | 344 | |
99e757d5 | 345 | gcc_AC_C_LONG_DOUBLE |
61842080 | 346 | |
97d81d66 JM |
347 | AC_CACHE_CHECK(whether ${CC-cc} accepts -Wno-long-long, |
348 | ac_cv_prog_cc_no_long_long, | |
349 | [save_CFLAGS="$CFLAGS" | |
350 | CFLAGS="-Wno-long-long" | |
351 | AC_TRY_COMPILE(,,ac_cv_prog_cc_no_long_long=yes, | |
352 | ac_cv_prog_cc_no_long_long=no) | |
353 | CFLAGS="$save_CFLAGS"]) | |
b8dad04b ZW |
354 | strict1_warn= |
355 | if test $ac_cv_prog_cc_no_long_long = yes; then | |
356 | strict1_warn="-pedantic -Wno-long-long" | |
357 | fi | |
358 | AC_SUBST(strict1_warn) | |
ff5def20 | 359 | |
61842080 MM |
360 | # If the native compiler is GCC, we can enable warnings even in stage1. |
361 | # That's useful for people building cross-compilers, or just running a | |
362 | # quick `make'. | |
b8dad04b ZW |
363 | warn_cflags= |
364 | if test "x$GCC" = "xyes"; then | |
365 | warn_cflags='$(GCC_WARN_CFLAGS)' | |
61842080 | 366 | fi |
b8dad04b | 367 | AC_SUBST(warn_cflags) |
5b67ad6f DA |
368 | |
369 | # Stage specific cflags for build. | |
b8dad04b | 370 | stage1_cflags= |
5b67ad6f DA |
371 | case $build in |
372 | vax-*-*) | |
373 | if test x$GCC = xyes | |
374 | then | |
b8dad04b | 375 | stage1_cflags="-Wa,-J" |
5b67ad6f | 376 | else |
b8dad04b | 377 | stage1_cflags="-J" |
5b67ad6f DA |
378 | fi |
379 | ;; | |
380 | esac | |
b8dad04b | 381 | AC_SUBST(stage1_cflags) |
61842080 | 382 | |
e9a25f70 JL |
383 | AC_PROG_MAKE_SET |
384 | ||
ab339d62 | 385 | AC_MSG_CHECKING([whether a default assembler was specified]) |
3ccc3a56 | 386 | if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then |
e154a394 | 387 | if test x"$gas_flag" = x"no"; then |
3ccc3a56 | 388 | AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER)]) |
ab339d62 | 389 | else |
3ccc3a56 | 390 | AC_MSG_RESULT([yes ($DEFAULT_ASSEMBLER - GNU as)]) |
ab339d62 AO |
391 | fi |
392 | else | |
393 | AC_MSG_RESULT(no) | |
394 | fi | |
395 | ||
396 | AC_MSG_CHECKING([whether a default linker was specified]) | |
3ccc3a56 | 397 | if test x"${DEFAULT_LINKER+set}" = x"set"; then |
e154a394 | 398 | if test x"$gnu_ld_flag" = x"no"; then |
3ccc3a56 | 399 | AC_MSG_RESULT([yes ($DEFAULT_LINKER)]) |
ab339d62 | 400 | else |
3ccc3a56 | 401 | AC_MSG_RESULT([yes ($DEFAULT_LINKER - GNU ld)]) |
ab339d62 AO |
402 | fi |
403 | else | |
404 | AC_MSG_RESULT(no) | |
405 | fi | |
406 | ||
4070d885 AJ |
407 | AC_MSG_CHECKING(for GNU C library) |
408 | AC_CACHE_VAL(gcc_cv_glibc, | |
409 | [AC_TRY_COMPILE( | |
410 | [#include <features.h>],[ | |
411 | #if ! (defined __GLIBC__ || defined __GNU_LIBRARY__) | |
412 | #error Not a GNU C library system | |
413 | #endif], | |
414 | [gcc_cv_glibc=yes], | |
415 | gcc_cv_glibc=no)]) | |
416 | AC_MSG_RESULT($gcc_cv_glibc) | |
c2f7d403 | 417 | if test $gcc_cv_glibc = yes; then |
4070d885 AJ |
418 | AC_DEFINE(_GNU_SOURCE, 1, [Always define this when using the GNU C Library]) |
419 | fi | |
4797e955 | 420 | |
603832a0 PT |
421 | AC_C_INLINE |
422 | ||
46f18e7b RK |
423 | # Find some useful tools |
424 | AC_PROG_AWK | |
99e757d5 KG |
425 | gcc_AC_PROG_LN |
426 | gcc_AC_PROG_LN_S | |
427 | gcc_AC_C_VOLATILE | |
46f18e7b | 428 | AC_PROG_RANLIB |
99e757d5 | 429 | gcc_AC_PROG_INSTALL |
46f18e7b | 430 | |
956d6950 JL |
431 | AC_HEADER_STDC |
432 | AC_HEADER_TIME | |
99e757d5 | 433 | gcc_AC_HEADER_STRING |
e9831ca0 | 434 | AC_HEADER_SYS_WAIT |
03c41c05 ZW |
435 | AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h \ |
436 | fcntl.h unistd.h stab.h sys/file.h sys/time.h \ | |
437 | sys/resource.h sys/param.h sys/times.h sys/stat.h \ | |
16abe34a | 438 | direct.h malloc.h langinfo.h iconv.h) |
7636d567 | 439 | |
f24af81b TT |
440 | # Check for thread headers. |
441 | AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=]) | |
442 | AC_CHECK_HEADER(pthread.h, [have_pthread_h=yes], [have_pthread_h=]) | |
443 | ||
bcf12124 JL |
444 | # See if GNAT has been installed |
445 | AC_CHECK_PROG(gnat, gnatbind, yes, no) | |
446 | ||
09fa0705 ZW |
447 | # Do we have a single-tree copy of texinfo? |
448 | if test -f $srcdir/../texinfo/Makefile.in; then | |
449 | MAKEINFO='$(objdir)/../texinfo/makeinfo/makeinfo' | |
450 | gcc_cv_prog_makeinfo_modern=yes | |
451 | AC_MSG_RESULT([Using makeinfo from the unified source tree.]) | |
452 | else | |
453 | # See if makeinfo has been installed and is modern enough | |
454 | # that we can use it. | |
455 | gcc_AC_CHECK_PROG_VER(MAKEINFO, makeinfo, --version, | |
456 | [GNU texinfo.* \([0-9][0-9.]*\)], | |
457 | [3.1[2-9] | 3.[2-9][0-9] | 4.* | 1.6[89] | 1.7[0-9]]) | |
458 | fi | |
459 | ||
460 | if test $gcc_cv_prog_makeinfo_modern = no; then | |
461 | AC_MSG_WARN([ | |
462 | *** Makeinfo is missing or too old. | |
463 | *** Info documentation will not be built or installed.]) | |
464 | BUILD_INFO= | |
465 | INSTALL_INFO= | |
466 | else | |
467 | BUILD_INFO=info AC_SUBST(BUILD_INFO) | |
468 | INSTALL_INFO=install-info AC_SUBST(INSTALL_INFO) | |
469 | fi | |
470 | ||
1e608388 ZW |
471 | # How about lex? |
472 | dnl Don't use AC_PROG_LEX; we insist on flex. | |
473 | dnl LEXLIB is not useful in gcc. | |
474 | if test -f $srcdir/../flex/skel.c; then | |
475 | FLEX='$(objdir)/../flex/flex' | |
476 | else | |
477 | AC_CHECK_PROG(FLEX, flex, flex, false) | |
478 | fi | |
479 | ||
480 | # Bison? | |
481 | # The -L switch is so bison can find its skeleton file. | |
482 | if test -f $srcdir/../bison/bison.simple; then | |
483 | BISON='$(objdir)/../bison/bison -L $(srcdir)/../bison/' | |
484 | else | |
485 | AC_CHECK_PROG(BISON, bison, bison, false) | |
486 | fi | |
487 | ||
890ad3ea KG |
488 | # See if the stage1 system preprocessor understands the ANSI C |
489 | # preprocessor stringification operator. | |
490 | AC_C_STRINGIZE | |
76844337 | 491 | |
7636d567 JW |
492 | # Use <inttypes.h> only if it exists, |
493 | # doesn't clash with <sys/types.h>, and declares intmax_t. | |
494 | AC_MSG_CHECKING(for inttypes.h) | |
495 | AC_CACHE_VAL(gcc_cv_header_inttypes_h, | |
496 | [AC_TRY_COMPILE( | |
497 | [#include <sys/types.h> | |
498 | #include <inttypes.h>], | |
499 | [intmax_t i = -1;], | |
9da0e39b | 500 | [gcc_cv_header_inttypes_h=yes], |
7636d567 JW |
501 | gcc_cv_header_inttypes_h=no)]) |
502 | AC_MSG_RESULT($gcc_cv_header_inttypes_h) | |
9da0e39b | 503 | if test $gcc_cv_header_inttypes_h = yes; then |
119d24d1 KG |
504 | AC_DEFINE(HAVE_INTTYPES_H, 1, |
505 | [Define if you have a working <inttypes.h> header file.]) | |
9da0e39b | 506 | fi |
cdcc6a01 | 507 | |
c149cc37 RL |
508 | # |
509 | # Determine if enumerated bitfields are unsigned. ISO C says they can | |
510 | # be either signed or unsigned. | |
511 | # | |
512 | AC_CACHE_CHECK(for unsigned enumerated bitfields, gcc_cv_enum_bf_unsigned, | |
513 | [AC_TRY_RUN(#include <stdlib.h> | |
514 | enum t { BLAH = 128 } ; | |
515 | struct s_t { enum t member : 8; } s ; | |
516 | int main(void) | |
517 | { | |
518 | s.member = BLAH; | |
519 | if (s.member < 0) exit(1); | |
520 | exit(0); | |
521 | ||
522 | }, gcc_cv_enum_bf_unsigned=yes, gcc_cv_enum_bf_unsigned=no, gcc_cv_enum_bf_unsigned=yes)]) | |
c149cc37 RL |
523 | if test $gcc_cv_enum_bf_unsigned = yes; then |
524 | AC_DEFINE(ENUM_BITFIELDS_ARE_UNSIGNED, 1, | |
525 | [Define if enumerated bitfields are treated as unsigned values.]) | |
526 | fi | |
527 | ||
2e09e75a JM |
528 | AC_CHECK_FUNCS(strtoul bsearch putenv popen bcopy \ |
529 | strchr strrchr kill getrlimit setrlimit atoll atoq \ | |
54953b66 | 530 | sysconf isascii gettimeofday strsignal putc_unlocked fputc_unlocked \ |
d21445e7 | 531 | fputs_unlocked getrusage valloc iconv nl_langinfo) |
a81fb89e | 532 | |
f12bc141 | 533 | AC_CHECK_TYPE(ssize_t, int) |
56f48ce9 | 534 | |
e256b8b6 DA |
535 | # Try to determine the array type of the second argument of getgroups |
536 | # for the target system (int or gid_t). | |
537 | AC_TYPE_GETGROUPS | |
538 | if test "${target}" = "${build}"; then | |
539 | TARGET_GETGROUPS_T=$ac_cv_type_getgroups | |
540 | else | |
541 | case "${target}" in | |
542 | # This condition may need some tweaking. It should include all | |
543 | # targets where the array type of the second argument of getgroups | |
544 | # is int and the type of gid_t is not equivalent to int. | |
545 | *-*-sunos* | *-*-ultrix*) | |
546 | TARGET_GETGROUPS_T=int | |
547 | ;; | |
548 | *) | |
549 | TARGET_GETGROUPS_T=gid_t | |
550 | ;; | |
551 | esac | |
552 | fi | |
553 | AC_SUBST(TARGET_GETGROUPS_T) | |
554 | ||
99e757d5 KG |
555 | gcc_AC_FUNC_VFPRINTF_DOPRNT |
556 | gcc_AC_FUNC_PRINTF_PTR | |
b27d2bd5 MK |
557 | |
558 | case "${host}" in | |
559 | *-*-uwin*) | |
560 | # Under some versions of uwin, vfork is notoriously buggy and the test | |
561 | # can hang configure; on other versions, vfork exists just as a stub. | |
562 | # FIXME: This should be removed once vfork in uwin's runtime is fixed. | |
563 | ac_cv_func_vfork_works=no | |
564 | ;; | |
565 | esac | |
c375c43b | 566 | AC_FUNC_VFORK |
4acab94b | 567 | AC_FUNC_MMAP_ANYWHERE |
56f02b88 | 568 | AC_FUNC_MMAP_FILE |
f1b54f9b | 569 | |
86cf1cbd KG |
570 | # We will need to find libiberty.h and ansidecl.h |
571 | saved_CFLAGS="$CFLAGS" | |
572 | CFLAGS="$CFLAGS -I${srcdir} -I${srcdir}/../include" | |
2e09e75a JM |
573 | gcc_AC_CHECK_DECLS(bcopy \ |
574 | getenv atol sbrk abort atof getcwd getwd \ | |
86cf1cbd | 575 | strsignal putc_unlocked fputs_unlocked strstr environ \ |
f31e826b | 576 | malloc realloc calloc free basename getopt, , ,[ |
86cf1cbd KG |
577 | #include "gansidecl.h" |
578 | #include "system.h"]) | |
c5c76735 | 579 | |
f31e826b | 580 | gcc_AC_CHECK_DECLS(getrlimit setrlimit getrusage, , ,[ |
86cf1cbd KG |
581 | #include "gansidecl.h" |
582 | #include "system.h" | |
d2cabf16 KG |
583 | #ifdef HAVE_SYS_RESOURCE_H |
584 | #include <sys/resource.h> | |
585 | #endif | |
586 | ]) | |
587 | ||
86cf1cbd KG |
588 | # Restore CFLAGS from before the gcc_AC_NEED_DECLARATIONS tests. |
589 | CFLAGS="$saved_CFLAGS" | |
590 | ||
75923b2f | 591 | # mkdir takes a single argument on some systems. |
99e757d5 | 592 | gcc_AC_FUNC_MKDIR_TAKES_ONE_ARG |
75923b2f | 593 | |
46f18e7b RK |
594 | # File extensions |
595 | manext='.1' | |
596 | objext='.o' | |
46f18e7b RK |
597 | AC_SUBST(manext) |
598 | AC_SUBST(objext) | |
46f18e7b RK |
599 | |
600 | build_xm_file= | |
61536478 | 601 | build_xm_defines= |
46f18e7b RK |
602 | build_install_headers_dir=install-headers-tar |
603 | build_exeext= | |
604 | host_xm_file= | |
61536478 | 605 | host_xm_defines= |
46f18e7b RK |
606 | host_xmake_file= |
607 | host_truncate_target= | |
6e26218f | 608 | host_exeext= |
46f18e7b RK |
609 | |
610 | # Decode the host machine, then the target machine. | |
611 | # For the host machine, we save the xm_file variable as host_xm_file; | |
612 | # then we decode the target machine and forget everything else | |
613 | # that came from the host machine. | |
614 | for machine in $build $host $target; do | |
615 | ||
616 | out_file= | |
617 | xmake_file= | |
618 | tmake_file= | |
619 | extra_headers= | |
620 | extra_passes= | |
621 | extra_parts= | |
622 | extra_programs= | |
623 | extra_objs= | |
624 | extra_host_objs= | |
625 | extra_gcc_objs= | |
61536478 | 626 | xm_defines= |
46f18e7b RK |
627 | float_format= |
628 | # Set this to force installation and use of collect2. | |
629 | use_collect2= | |
630 | # Set this to override the default target model. | |
631 | target_cpu_default= | |
46f18e7b RK |
632 | # Set this to control how the header file directory is installed. |
633 | install_headers_dir=install-headers-tar | |
634 | # Set this to a non-empty list of args to pass to cpp if the target | |
635 | # wants its .md file passed through cpp. | |
636 | md_cppflags= | |
637 | # Set this if directory names should be truncated to 14 characters. | |
638 | truncate_target= | |
639 | # Set this if gdb needs a dir command with `dirname $out_file` | |
640 | gdb_needs_out_file_path= | |
46f18e7b RK |
641 | # Set this if the build machine requires executables to have a |
642 | # file name suffix. | |
643 | exeext= | |
a851212a JW |
644 | # Set this to control which thread package will be used. |
645 | thread_file= | |
df6faf79 JW |
646 | # Reinitialize these from the flag values every loop pass, since some |
647 | # configure entries modify them. | |
648 | gas="$gas_flag" | |
649 | gnu_ld="$gnu_ld_flag" | |
e445171e | 650 | enable_threads=$enable_threads_flag |
46f18e7b | 651 | |
6baf1cc8 BS |
652 | # Set default cpu_type, tm_file, tm_p_file and xm_file so it can be |
653 | # updated in each machine entry. | |
654 | tm_p_file= | |
46f18e7b RK |
655 | cpu_type=`echo $machine | sed 's/-.*$//'` |
656 | case $machine in | |
08fc0184 RK |
657 | alpha*-*-*) |
658 | cpu_type=alpha | |
659 | ;; | |
cd2b33d0 NC |
660 | strongarm*-*-*) |
661 | cpu_type=arm | |
662 | ;; | |
46f18e7b RK |
663 | arm*-*-*) |
664 | cpu_type=arm | |
665 | ;; | |
666 | c*-convex-*) | |
667 | cpu_type=convex | |
668 | ;; | |
75bffa71 ILT |
669 | changequote(,)dnl |
670 | i[34567]86-*-*) | |
671 | changequote([,])dnl | |
46f18e7b RK |
672 | cpu_type=i386 |
673 | ;; | |
674 | hppa*-*-*) | |
675 | cpu_type=pa | |
676 | ;; | |
677 | m68000-*-*) | |
678 | cpu_type=m68k | |
679 | ;; | |
680 | mips*-*-*) | |
681 | cpu_type=mips | |
682 | ;; | |
1b992148 SC |
683 | pj*-*-*) |
684 | cpu_type=pj | |
685 | ;; | |
46f18e7b RK |
686 | powerpc*-*-*) |
687 | cpu_type=rs6000 | |
688 | ;; | |
689 | pyramid-*-*) | |
690 | cpu_type=pyr | |
691 | ;; | |
692 | sparc*-*-*) | |
693 | cpu_type=sparc | |
694 | ;; | |
695 | esac | |
696 | ||
697 | tm_file=${cpu_type}/${cpu_type}.h | |
698 | xm_file=${cpu_type}/xm-${cpu_type}.h | |
6baf1cc8 BS |
699 | if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-protos.h; |
700 | then | |
701 | tm_p_file=${cpu_type}/${cpu_type}-protos.h; | |
702 | fi | |
7aae67a2 JM |
703 | # On a.out targets, we need to use collect2. |
704 | case $machine in | |
705 | *-*-*aout*) | |
706 | use_collect2=yes | |
707 | ;; | |
708 | esac | |
709 | ||
57119aa9 | 710 | # Common parts for linux and openbsd systems |
61536478 | 711 | case $machine in |
57119aa9 | 712 | *-*-linux*) |
c7391272 | 713 | xm_defines="HAVE_ATEXIT POSIX BSTRING" |
61536478 | 714 | ;; |
1b4a979b ME |
715 | *-*-openbsd*) |
716 | tm_file=${cpu_type}/openbsd.h | |
1b4a979b ME |
717 | tmake_file="t-libc-ok t-openbsd" |
718 | # avoid surprises, always provide an xm-openbsd file | |
719 | xm_file=${cpu_type}/xm-openbsd.h | |
766518a0 ME |
720 | # don't depend on processor x-fragments as well |
721 | xmake_file=none | |
1b4a979b ME |
722 | if test x$enable_threads = xyes; then |
723 | thread_file='posix' | |
724 | tmake_file="${tmake_file} t-openbsd-thread" | |
725 | fi | |
726 | ;; | |
61536478 JL |
727 | esac |
728 | ||
46f18e7b RK |
729 | case $machine in |
730 | # Support site-specific machine types. | |
731 | *local*) | |
732 | cpu_type=`echo $machine | sed -e 's/-.*//'` | |
733 | rest=`echo $machine | sed -e "s/$cpu_type-//"` | |
734 | xm_file=${cpu_type}/xm-$rest.h | |
735 | tm_file=${cpu_type}/$rest.h | |
75bffa71 | 736 | if test -f $srcdir/config/${cpu_type}/x-$rest; \ |
46f18e7b RK |
737 | then xmake_file=${cpu_type}/x-$rest; \ |
738 | else true; \ | |
739 | fi | |
75bffa71 | 740 | if test -f $srcdir/config/${cpu_type}/t-$rest; \ |
46f18e7b RK |
741 | then tmake_file=${cpu_type}/t-$rest; \ |
742 | else true; \ | |
743 | fi | |
744 | ;; | |
745 | 1750a-*-*) | |
746 | ;; | |
747 | a29k-*-bsd* | a29k-*-sym1*) | |
748 | tm_file="${tm_file} a29k/unix.h" | |
61536478 | 749 | xm_defines=USG |
46f18e7b RK |
750 | xmake_file=a29k/x-unix |
751 | use_collect2=yes | |
752 | ;; | |
753 | a29k-*-udi | a29k-*-coff) | |
754 | tm_file="${tm_file} dbxcoff.h a29k/udi.h" | |
755 | tmake_file=a29k/t-a29kbare | |
756 | ;; | |
7cc34889 | 757 | a29k-wrs-vxworks*) |
46f18e7b RK |
758 | tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h" |
759 | tmake_file=a29k/t-vx29k | |
760 | extra_parts="crtbegin.o crtend.o" | |
7cc34889 | 761 | thread_file='vxworks' |
46f18e7b RK |
762 | ;; |
763 | a29k-*-*) # Default a29k environment. | |
764 | use_collect2=yes | |
765 | ;; | |
615c8231 DT |
766 | alpha-*-interix) |
767 | tm_file="${tm_file} alpha/alpha32.h interix.h alpha/alpha-interix.h" | |
768 | ||
769 | # GAS + IEEE_CONFORMANT+IEEE (no inexact); | |
8354da48 | 770 | #target_cpu_default="MASK_GAS|MASK_IEEE_CONFORMANT|MASK_IEEE" |
615c8231 | 771 | |
8354da48 JL |
772 | # GAS + IEEE_CONFORMANT |
773 | target_cpu_default="MASK_GAS|MASK_IEEE_CONFORMANT" | |
615c8231 DT |
774 | |
775 | xm_file="alpha/xm-alpha-interix.h xm-interix.h" | |
776 | xmake_file="x-interix alpha/t-pe" | |
6da9c622 | 777 | tmake_file="alpha/t-alpha alpha/t-interix alpha/t-ieee" |
615c8231 DT |
778 | if test x$enable_threads = xyes ; then |
779 | thread_file='posix' | |
780 | fi | |
781 | if test x$stabs = xyes ; then | |
782 | tm_file="${tm_file} dbxcoff.h" | |
783 | fi | |
784 | #prefix='$$INTERIX_ROOT'/usr/contrib | |
785 | #local_prefix='$$INTERIX_ROOT'/usr/contrib | |
786 | ;; | |
57119aa9 | 787 | alpha*-*-linux*ecoff*) |
8983c716 | 788 | tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h" |
61536478 | 789 | target_cpu_default="MASK_GAS" |
6da9c622 | 790 | tmake_file="alpha/t-alpha alpha/t-ieee" |
e71c3bb0 | 791 | gas=no |
46f18e7b | 792 | xmake_file=none |
46f18e7b RK |
793 | gas=yes gnu_ld=yes |
794 | ;; | |
57119aa9 | 795 | alpha*-*-linux*libc1*) |
9d654bba | 796 | tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h" |
61536478 | 797 | target_cpu_default="MASK_GAS" |
cf889600 | 798 | tmake_file="t-linux t-linux-gnulibc1 alpha/t-alpha alpha/t-crtbe alpha/t-ieee" |
ee8d66f7 | 799 | extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" |
704a6306 | 800 | xmake_file=none |
704a6306 | 801 | gas=yes gnu_ld=yes |
75bffa71 | 802 | if test x$enable_threads = xyes; then |
704a6306 RH |
803 | thread_file='posix' |
804 | fi | |
805 | ;; | |
57119aa9 | 806 | alpha*-*-linux*) |
9d654bba | 807 | tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h" |
61536478 | 808 | target_cpu_default="MASK_GAS" |
cf889600 | 809 | tmake_file="t-linux alpha/t-crtbe alpha/t-alpha alpha/t-ieee" |
ee8d66f7 | 810 | extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" |
46f18e7b | 811 | xmake_file=none |
46f18e7b | 812 | gas=yes gnu_ld=yes |
75bffa71 | 813 | if test x$enable_threads = xyes; then |
c811d261 RK |
814 | thread_file='posix' |
815 | fi | |
46f18e7b | 816 | ;; |
ace54f91 DB |
817 | alpha*-*-freebsd*) |
818 | tm_file="${tm_file} freebsd.h alpha/elf.h alpha/freebsd.h" | |
819 | target_cpu_default="MASK_GAS" | |
820 | tmake_file="t-freebsd alpha/t-crtbe alpha/t-alpha alpha/t-ieee" | |
821 | extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" | |
822 | xmake_file=none | |
823 | gas=yes gnu_ld=yes | |
824 | stabs=yes | |
825 | case x${enable_threads} in | |
826 | xyes | xpthreads | xposix) | |
827 | thread_file='posix' | |
828 | tmake_file="${tmake_file} t-freebsd-thread" | |
829 | ;; | |
830 | esac | |
831 | ;; | |
9d654bba | 832 | alpha*-*-netbsd*) |
66953094 | 833 | tm_file="${tm_file} alpha/elf.h alpha/netbsd.h alpha/netbsd-elf.h" |
9d654bba | 834 | target_cpu_default="MASK_GAS" |
6da9c622 | 835 | tmake_file="alpha/t-crtbe alpha/t-alpha alpha/t-ieee" |
ee8d66f7 | 836 | extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" |
9d654bba | 837 | xmake_file=none |
9d654bba RH |
838 | gas=yes gnu_ld=yes |
839 | ;; | |
1b4a979b ME |
840 | |
841 | alpha*-*-openbsd*) | |
842 | # default x-alpha is only appropriate for dec-osf. | |
843 | target_cpu_default="MASK_GAS" | |
6da9c622 | 844 | tmake_file="alpha/t-alpha alpha/t-ieee" |
1b4a979b | 845 | ;; |
9d654bba | 846 | |
e9a25f70 | 847 | alpha*-dec-osf*) |
75bffa71 | 848 | if test x$stabs = xyes |
dec3e070 JW |
849 | then |
850 | tm_file="${tm_file} dbx.h" | |
851 | fi | |
75bffa71 | 852 | if test x$gas != xyes |
dec3e070 JW |
853 | then |
854 | extra_passes="mips-tfile mips-tdump" | |
855 | fi | |
dec3e070 | 856 | use_collect2=yes |
50503ac8 RH |
857 | tmake_file="alpha/t-alpha alpha/t-ieee alpha/t-osf" |
858 | xmake_file=alpha/x-osf | |
dec3e070 | 859 | case $machine in |
6ecd4e53 | 860 | *-*-osf1*) |
b0435cf4 | 861 | tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h" |
e9a25f70 | 862 | ;; |
75bffa71 ILT |
863 | changequote(,)dnl |
864 | *-*-osf[23]*) | |
865 | changequote([,])dnl | |
b0435cf4 | 866 | tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h" |
e9a25f70 JL |
867 | ;; |
868 | *-*-osf4*) | |
b0435cf4 | 869 | tm_file="${tm_file} alpha/osf.h" |
50503ac8 | 870 | tmake_file="$tmake_file alpha/t-osf4" |
e9a25f70 JL |
871 | # Some versions of OSF4 (specifically X4.0-9 296.7) have |
872 | # a broken tar, so we use cpio instead. | |
dec3e070 JW |
873 | install_headers_dir=install-headers-cpio |
874 | ;; | |
7bc69973 | 875 | *-*-osf5*) |
5495cc55 | 876 | tm_file="${tm_file} alpha/osf.h alpha/osf5.h" |
50503ac8 | 877 | tmake_file="$tmake_file alpha/t-osf4" |
7bc69973 | 878 | ;; |
dec3e070 | 879 | esac |
e9a25f70 | 880 | case $machine in |
75bffa71 | 881 | changequote(,)dnl |
cd038ac2 | 882 | *-*-osf4.0[b-z] | *-*-osf4.[1-9]* | *-*-osf5*) |
75bffa71 | 883 | changequote([,])dnl |
e9a25f70 JL |
884 | target_cpu_default=MASK_SUPPORT_ARCH |
885 | ;; | |
886 | esac | |
46f18e7b | 887 | ;; |
9ec36da5 JL |
888 | alpha*-*-vxworks*) |
889 | tm_file="${tm_file} dbx.h alpha/vxworks.h" | |
6da9c622 | 890 | tmake_file="alpha/t-alpha alpha/t-ieee" |
9ec36da5 JL |
891 | if [ x$gas != xyes ] |
892 | then | |
893 | extra_passes="mips-tfile mips-tdump" | |
894 | fi | |
895 | use_collect2=yes | |
28897609 | 896 | thread_file='vxworks' |
9ec36da5 | 897 | ;; |
b0435cf4 | 898 | alpha*-*-winnt*) |
615c8231 | 899 | tm_file="${tm_file} alpha/alpha32.h alpha/win-nt.h winnt/win-nt.h" |
46f18e7b | 900 | xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h" |
6da9c622 | 901 | tmake_file="t-libc-ok alpha/t-alpha alpha/t-ieee" |
46f18e7b RK |
902 | xmake_file=winnt/x-winnt |
903 | extra_host_objs=oldnames.o | |
904 | extra_gcc_objs="spawnv.o oldnames.o" | |
75bffa71 | 905 | if test x$gnu_ld != xyes |
46f18e7b RK |
906 | then |
907 | extra_programs=ld.exe | |
908 | fi | |
75bffa71 | 909 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
910 | thread_file='win32' |
911 | fi | |
46f18e7b | 912 | ;; |
08fc0184 | 913 | alpha*-dec-vms*) |
46f18e7b RK |
914 | tm_file=alpha/vms.h |
915 | xm_file="${xm_file} alpha/xm-vms.h" | |
6da9c622 | 916 | tmake_file="alpha/t-alpha alpha/t-vms alpha/t-ieee" |
46f18e7b | 917 | ;; |
66ed0683 JL |
918 | arc-*-elf*) |
919 | extra_parts="crtinit.o crtfini.o" | |
920 | ;; | |
46f18e7b RK |
921 | arm-*-coff* | armel-*-coff*) |
922 | tm_file=arm/coff.h | |
d5b7b3ae | 923 | tmake_file=arm/t-arm-coff |
46f18e7b | 924 | ;; |
2aa0c933 | 925 | arm-*-vxworks*) |
e14db015 | 926 | tm_file=arm/vxarm.h |
d5b7b3ae | 927 | tmake_file=arm/t-arm-coff |
28897609 | 928 | thread_file='vxworks' |
2aa0c933 | 929 | ;; |
75bffa71 ILT |
930 | changequote(,)dnl |
931 | arm-*-riscix1.[01]*) # Acorn RISC machine (early versions) | |
932 | changequote([,])dnl | |
46f18e7b RK |
933 | tm_file=arm/riscix1-1.h |
934 | use_collect2=yes | |
935 | ;; | |
936 | arm-*-riscix*) # Acorn RISC machine | |
75bffa71 | 937 | if test x$gas = xyes |
46f18e7b RK |
938 | then |
939 | tm_file=arm/rix-gas.h | |
940 | else | |
941 | tm_file=arm/riscix.h | |
942 | fi | |
943 | xmake_file=arm/x-riscix | |
944 | tmake_file=arm/t-riscix | |
945 | use_collect2=yes | |
946 | ;; | |
947 | arm-semi-aout | armel-semi-aout) | |
948 | tm_file=arm/semi.h | |
949 | tmake_file=arm/t-semi | |
46f18e7b RK |
950 | ;; |
951 | arm-semi-aof | armel-semi-aof) | |
952 | tm_file=arm/semiaof.h | |
953 | tmake_file=arm/t-semiaof | |
46f18e7b | 954 | ;; |
58600d24 | 955 | arm*-*-netbsd*) |
d23f4158 | 956 | tm_file=arm/netbsd.h |
e9a25f70 | 957 | tmake_file="t-netbsd arm/t-netbsd" |
ed4acb3b | 958 | use_collect2=yes |
d23f4158 | 959 | ;; |
57119aa9 | 960 | arm*-*-linux*oldld*) # ARM GNU/Linux with old ELF linker |
b355a481 NC |
961 | xm_file=arm/xm-linux.h |
962 | xmake_file=x-linux | |
078e19a4 | 963 | tm_file="arm/linux-oldld.h arm/linux-elf.h" |
b355a481 NC |
964 | case $machine in |
965 | armv2*-*-*) | |
078e19a4 PB |
966 | tm_file="arm/linux-elf26.h $tm_file" |
967 | ;; | |
968 | esac | |
969 | tmake_file="t-linux arm/t-linux" | |
970 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
971 | gnu_ld=yes | |
972 | case x${enable_threads} in | |
973 | x | xyes | xpthreads | xposix) | |
974 | thread_file='posix' | |
b355a481 | 975 | ;; |
078e19a4 PB |
976 | esac |
977 | ;; | |
57119aa9 | 978 | arm*-*-linux*) # ARM GNU/Linux with ELF |
078e19a4 PB |
979 | xm_file=arm/xm-linux.h |
980 | xmake_file=x-linux | |
981 | tm_file="arm/linux-elf.h" | |
982 | case $machine in | |
983 | armv2*-*-*) | |
984 | tm_file="arm/linux-elf26.h $tm_file" | |
b355a481 NC |
985 | ;; |
986 | esac | |
987 | tmake_file="t-linux arm/t-linux" | |
988 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
b355a481 | 989 | gnu_ld=yes |
65120c40 SB |
990 | case x${enable_threads} in |
991 | x | xyes | xpthreads | xposix) | |
992 | thread_file='posix' | |
993 | ;; | |
994 | esac | |
b355a481 | 995 | ;; |
483f6332 PB |
996 | arm*-*-uclinux*) # ARM ucLinux |
997 | tm_file=arm/uclinux-elf.h | |
998 | tmake_file=arm/t-arm-elf | |
999 | ;; | |
b355a481 | 1000 | arm*-*-aout) |
f5967c59 | 1001 | tm_file=arm/aout.h |
d5b7b3ae | 1002 | tmake_file=arm/t-arm-aout |
46f18e7b | 1003 | ;; |
e6592fff CM |
1004 | arm*-*-ecos-elf) |
1005 | tm_file=arm/ecos-elf.h | |
d5b7b3ae | 1006 | tmake_file=arm/t-arm-elf |
e6592fff | 1007 | ;; |
b355a481 NC |
1008 | arm*-*-elf) |
1009 | tm_file=arm/unknown-elf.h | |
1010 | tmake_file=arm/t-arm-elf | |
47163378 PB |
1011 | ;; |
1012 | arm*-*-conix*) | |
1013 | tm_file=arm/conix-elf.h | |
1014 | tmake_file=arm/t-arm-elf | |
b355a481 | 1015 | ;; |
cbca921c CM |
1016 | arm*-*-oabi) |
1017 | tm_file=arm/unknown-elf-oabi.h | |
1018 | tmake_file=arm/t-arm-elf | |
1019 | ;; | |
cb805c2d NC |
1020 | arm-*-pe*) |
1021 | tm_file=arm/pe.h | |
1022 | tmake_file=arm/t-pe | |
d5b7b3ae | 1023 | extra_objs="pe.o" |
cb805c2d | 1024 | ;; |
ed4acb3b DC |
1025 | avr-*-*) |
1026 | ;; | |
46f18e7b RK |
1027 | c1-convex-*) # Convex C1 |
1028 | target_cpu_default=1 | |
1029 | use_collect2=yes | |
46f18e7b RK |
1030 | ;; |
1031 | c2-convex-*) # Convex C2 | |
1032 | target_cpu_default=2 | |
1033 | use_collect2=yes | |
46f18e7b RK |
1034 | ;; |
1035 | c32-convex-*) | |
1036 | target_cpu_default=4 | |
1037 | use_collect2=yes | |
46f18e7b RK |
1038 | ;; |
1039 | c34-convex-*) | |
1040 | target_cpu_default=8 | |
1041 | use_collect2=yes | |
46f18e7b RK |
1042 | ;; |
1043 | c38-convex-*) | |
1044 | target_cpu_default=16 | |
1045 | use_collect2=yes | |
46f18e7b | 1046 | ;; |
62616695 MH |
1047 | c4x-*) |
1048 | cpu_type=c4x | |
81bce466 | 1049 | float_format=c4x |
62616695 MH |
1050 | tmake_file=c4x/t-c4x |
1051 | ;; | |
46f18e7b RK |
1052 | clipper-intergraph-clix*) |
1053 | tm_file="${tm_file} svr3.h clipper/clix.h" | |
1054 | xm_file=clipper/xm-clix.h | |
1055 | xmake_file=clipper/x-clix | |
1056 | extra_headers=va-clipper.h | |
1057 | extra_parts="crtbegin.o crtend.o" | |
1058 | install_headers_dir=install-headers-cpio | |
46f18e7b | 1059 | ;; |
a5c874cb RH |
1060 | d30v-*) |
1061 | float_format=i64 | |
1062 | ;; | |
46f18e7b RK |
1063 | dsp16xx-*) |
1064 | ;; | |
1065 | elxsi-elxsi-*) | |
1066 | use_collect2=yes | |
1067 | ;; | |
309dd885 NC |
1068 | fr30-*-elf) |
1069 | tm_file="fr30/fr30.h" | |
1070 | tmake_file=fr30/t-fr30 | |
1071 | extra_parts="crti.o crtn.o crtbegin.o crtend.o" | |
1072 | ;; | |
46f18e7b RK |
1073 | h8300-*-*) |
1074 | float_format=i32 | |
1075 | ;; | |
30f08b39 JL |
1076 | hppa*-*-linux*) |
1077 | target_cpu_default="(MASK_PA_11 | MASK_GAS | MASK_JUMP_IN_DELAY)" | |
1078 | tm_file="${tm_file} pa/elf.h linux.h pa/pa-linux.h" | |
1079 | tmake_file="t-linux pa/t-linux" | |
1080 | extra_parts="crtbegin.o crtend.o" | |
1081 | xmake_file=none | |
1082 | gas=yes gnu_ld=yes | |
1083 | if test x$enable_threads = xyes; then | |
1084 | thread_file='posix' | |
1085 | fi | |
1086 | ;; | |
1b4a979b | 1087 | hppa*-*-openbsd*) |
13ee407e | 1088 | target_cpu_default="MASK_PA_11" |
8f8d3278 | 1089 | tmake_file=pa/t-openbsd |
1b4a979b | 1090 | ;; |
46f18e7b | 1091 | hppa1.1-*-pro*) |
0d381b47 | 1092 | target_cpu_default="(MASK_JUMP_IN_DELAY | MASK_PORTABLE_RUNTIME | MASK_GAS | MASK_NO_SPACE_REGS | MASK_SOFT_FLOAT)" |
88624c0e | 1093 | tm_file="${tm_file} pa/pa32-regs.h elfos.h pa/elf.h pa/pa-pro-end.h libgloss.h" |
46f18e7b RK |
1094 | xm_file=pa/xm-papro.h |
1095 | tmake_file=pa/t-pro | |
1096 | ;; | |
1097 | hppa1.1-*-osf*) | |
13ee407e | 1098 | target_cpu_default="MASK_PA_11" |
88624c0e | 1099 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-osf.h" |
46f18e7b | 1100 | use_collect2=yes |
46f18e7b | 1101 | ;; |
dec3e070 | 1102 | hppa1.1-*-rtems*) |
0d381b47 | 1103 | target_cpu_default="(MASK_JUMP_IN_DELAY | MASK_PORTABLE_RUNTIME | MASK_GAS | MASK_NO_SPACE_REGS | MASK_SOFT_FLOAT)" |
88624c0e | 1104 | tm_file="${tm_file} pa/pa32-regs.h elfos.h pa/elf.h pa/pa-pro-end.h libgloss.h pa/rtems.h" |
dec3e070 JW |
1105 | xm_file=pa/xm-papro.h |
1106 | tmake_file=pa/t-pro | |
1107 | ;; | |
46f18e7b | 1108 | hppa1.0-*-osf*) |
88624c0e | 1109 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-osf.h" |
46f18e7b | 1110 | use_collect2=yes |
46f18e7b RK |
1111 | ;; |
1112 | hppa1.1-*-bsd*) | |
88624c0e | 1113 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h" |
13ee407e | 1114 | target_cpu_default="MASK_PA_11" |
46f18e7b | 1115 | use_collect2=yes |
46f18e7b RK |
1116 | ;; |
1117 | hppa1.0-*-bsd*) | |
88624c0e | 1118 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h" |
46f18e7b | 1119 | use_collect2=yes |
46f18e7b RK |
1120 | ;; |
1121 | hppa1.0-*-hpux7*) | |
88624c0e | 1122 | tm_file="pa/pa-oldas.h ${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux7.h" |
46f18e7b RK |
1123 | xm_file=pa/xm-pahpux.h |
1124 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1125 | if test x$gas = xyes |
46f18e7b RK |
1126 | then |
1127 | tm_file="${tm_file} pa/gas.h" | |
1128 | fi | |
46f18e7b RK |
1129 | install_headers_dir=install-headers-cpio |
1130 | use_collect2=yes | |
1131 | ;; | |
75bffa71 ILT |
1132 | changequote(,)dnl |
1133 | hppa1.0-*-hpux8.0[0-2]*) | |
1134 | changequote([,])dnl | |
88624c0e | 1135 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h" |
46f18e7b RK |
1136 | xm_file=pa/xm-pahpux.h |
1137 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1138 | if test x$gas = xyes |
46f18e7b RK |
1139 | then |
1140 | tm_file="${tm_file} pa/pa-gas.h" | |
1141 | else | |
1142 | tm_file="pa/pa-oldas.h ${tm_file}" | |
1143 | fi | |
46f18e7b RK |
1144 | install_headers_dir=install-headers-cpio |
1145 | use_collect2=yes | |
1146 | ;; | |
75bffa71 ILT |
1147 | changequote(,)dnl |
1148 | hppa1.1-*-hpux8.0[0-2]*) | |
1149 | changequote([,])dnl | |
13ee407e | 1150 | target_cpu_default="MASK_PA_11" |
88624c0e | 1151 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h" |
46f18e7b RK |
1152 | xm_file=pa/xm-pahpux.h |
1153 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1154 | if test x$gas = xyes |
46f18e7b RK |
1155 | then |
1156 | tm_file="${tm_file} pa/pa-gas.h" | |
1157 | else | |
1158 | tm_file="pa/pa-oldas.h ${tm_file}" | |
1159 | fi | |
46f18e7b RK |
1160 | install_headers_dir=install-headers-cpio |
1161 | use_collect2=yes | |
1162 | ;; | |
1163 | hppa1.1-*-hpux8*) | |
13ee407e | 1164 | target_cpu_default="MASK_PA_11" |
88624c0e | 1165 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h" |
46f18e7b RK |
1166 | xm_file=pa/xm-pahpux.h |
1167 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1168 | if test x$gas = xyes |
46f18e7b RK |
1169 | then |
1170 | tm_file="${tm_file} pa/pa-gas.h" | |
1171 | fi | |
46f18e7b RK |
1172 | install_headers_dir=install-headers-cpio |
1173 | use_collect2=yes | |
1174 | ;; | |
1175 | hppa1.0-*-hpux8*) | |
88624c0e | 1176 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h" |
46f18e7b RK |
1177 | xm_file=pa/xm-pahpux.h |
1178 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1179 | if test x$gas = xyes |
46f18e7b RK |
1180 | then |
1181 | tm_file="${tm_file} pa/pa-gas.h" | |
1182 | fi | |
46f18e7b RK |
1183 | install_headers_dir=install-headers-cpio |
1184 | use_collect2=yes | |
1185 | ;; | |
18cae839 | 1186 | hppa1.1-*-hpux10* | hppa2*-*-hpux10*) |
13ee407e | 1187 | target_cpu_default="MASK_PA_11" |
88624c0e | 1188 | tm_file="${tm_file} pa/pa32-regs.h pa/long_double.h pa/som.h pa/pa-hpux.h pa/pa-hpux10.h" |
f701f77c | 1189 | float_format=i128 |
46f18e7b RK |
1190 | xm_file=pa/xm-pahpux.h |
1191 | xmake_file=pa/x-pa-hpux | |
f24af81b | 1192 | tmake_file=pa/t-pa |
75bffa71 | 1193 | if test x$gas = xyes |
46f18e7b RK |
1194 | then |
1195 | tm_file="${tm_file} pa/pa-gas.h" | |
1196 | fi | |
75bffa71 | 1197 | if test x$enable_threads = x; then |
f24af81b TT |
1198 | enable_threads=$have_pthread_h |
1199 | fi | |
1ba2dbaa DA |
1200 | case x${enable_threads} in |
1201 | xyes | xdce) | |
f24af81b | 1202 | tmake_file="${tmake_file} pa/t-dce-thr" |
1ba2dbaa DA |
1203 | ;; |
1204 | esac | |
46f18e7b RK |
1205 | install_headers_dir=install-headers-cpio |
1206 | use_collect2=yes | |
1207 | ;; | |
1208 | hppa1.0-*-hpux10*) | |
88624c0e | 1209 | tm_file="${tm_file} pa/pa32-regs.h pa/long_double.h pa/som.h pa/pa-hpux.h pa/pa-hpux10.h" |
f701f77c | 1210 | float_format=i128 |
46f18e7b RK |
1211 | xm_file=pa/xm-pahpux.h |
1212 | xmake_file=pa/x-pa-hpux | |
661c7909 | 1213 | tmake_file=pa/t-pa |
75bffa71 | 1214 | if test x$gas = xyes |
46f18e7b RK |
1215 | then |
1216 | tm_file="${tm_file} pa/pa-gas.h" | |
1217 | fi | |
75bffa71 | 1218 | if test x$enable_threads = x; then |
d005a5a4 JL |
1219 | enable_threads=$have_pthread_h |
1220 | fi | |
1ba2dbaa DA |
1221 | case x${enable_threads} in |
1222 | xyes | xdce) | |
d005a5a4 | 1223 | tmake_file="${tmake_file} pa/t-dce-thr" |
1ba2dbaa DA |
1224 | ;; |
1225 | esac | |
46f18e7b RK |
1226 | install_headers_dir=install-headers-cpio |
1227 | use_collect2=yes | |
1228 | ;; | |
99b09ff3 JL |
1229 | hppa*64*-*-hpux11*) |
1230 | target_cpu_default="MASK_PA_11" | |
1231 | xm_file=pa/xm-pa64hpux.h | |
1232 | xmake_file=pa/x-pa-hpux | |
1233 | tmake_file=pa/t-pa | |
1234 | tm_file="pa/pa64-start.h ${tm_file} pa/pa64-regs.h pa/long_double.h pa/elf.h pa/pa-hpux.h pa/pa-hpux11.h pa/pa-64.h" | |
1235 | float_format=i128 | |
1236 | tmake_file=pa/t-pa64 | |
1237 | target_cpu_default="(MASK_PA_11|MASK_PA_20)" | |
1238 | ||
1239 | if [[ x$gas = xyes ]] | |
1240 | then | |
1241 | tm_file="${tm_file} pa/pa-gas.h" | |
1242 | fi | |
1243 | # if [[ x$enable_threads = x ]]; then | |
1244 | # enable_threads=$have_pthread_h | |
1245 | # fi | |
1246 | # if [[ x$enable_threads = xyes ]]; then | |
1247 | # thread_file='dce' | |
1248 | # tmake_file="${tmake_file} pa/t-dce-thr" | |
1249 | # fi | |
1250 | install_headers_dir=install-headers-cpio | |
1251 | use_collect2=yes | |
1252 | ;; | |
fab7be4f | 1253 | hppa1.1-*-hpux11* | hppa2*-*-hpux11*) |
30f08b39 | 1254 | target_cpu_default="MASK_PA_11" |
88624c0e | 1255 | tm_file="${tm_file} pa/pa32-regs.h pa/long_double.h pa/som.h pa/pa-hpux.h pa/pa-hpux11.h" |
f701f77c | 1256 | float_format=i128 |
fab7be4f JL |
1257 | xm_file=pa/xm-pahpux.h |
1258 | xmake_file=pa/x-pa-hpux | |
1259 | tmake_file=pa/t-pa | |
2618c083 | 1260 | if test x$gas = xyes |
fab7be4f JL |
1261 | then |
1262 | tm_file="${tm_file} pa/pa-gas.h" | |
1263 | fi | |
2618c083 | 1264 | # if test x$enable_threads = x; then |
fab7be4f JL |
1265 | # enable_threads=$have_pthread_h |
1266 | # fi | |
2618c083 | 1267 | # if test x$enable_threads = xyes; then |
fab7be4f JL |
1268 | # thread_file='dce' |
1269 | # tmake_file="${tmake_file} pa/t-dce-thr" | |
1270 | # fi | |
1271 | install_headers_dir=install-headers-cpio | |
1272 | use_collect2=yes | |
1273 | ;; | |
1274 | hppa1.0-*-hpux11*) | |
88624c0e | 1275 | tm_file="${tm_file} pa/pa32-regs.h pa/long_double.h pa/som.h pa/pa-hpux.h pa/pa-hpux11.h" |
f701f77c | 1276 | float_format=i128 |
fab7be4f JL |
1277 | xm_file=pa/xm-pahpux.h |
1278 | xmake_file=pa/x-pa-hpux | |
2618c083 | 1279 | if test x$gas = xyes |
fab7be4f JL |
1280 | then |
1281 | tm_file="${tm_file} pa/pa-gas.h" | |
1282 | fi | |
2618c083 | 1283 | # if test x$enable_threads = x; then |
fab7be4f JL |
1284 | # enable_threads=$have_pthread_h |
1285 | # fi | |
2618c083 | 1286 | # if test x$enable_threads = xyes; then |
fab7be4f JL |
1287 | # thread_file='dce' |
1288 | # tmake_file="${tmake_file} pa/t-dce-thr" | |
1289 | # fi | |
1290 | install_headers_dir=install-headers-cpio | |
1291 | use_collect2=yes | |
1292 | ;; | |
18cae839 | 1293 | hppa1.1-*-hpux* | hppa2*-*-hpux*) |
13ee407e | 1294 | target_cpu_default="MASK_PA_11" |
88624c0e | 1295 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h pa/pa-hpux9.h" |
46f18e7b RK |
1296 | xm_file=pa/xm-pahpux.h |
1297 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1298 | if test x$gas = xyes |
46f18e7b RK |
1299 | then |
1300 | tm_file="${tm_file} pa/pa-gas.h" | |
1301 | fi | |
46f18e7b RK |
1302 | install_headers_dir=install-headers-cpio |
1303 | use_collect2=yes | |
1304 | ;; | |
1305 | hppa1.0-*-hpux*) | |
88624c0e | 1306 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h pa/pa-hpux9.h" |
46f18e7b RK |
1307 | xm_file=pa/xm-pahpux.h |
1308 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1309 | if test x$gas = xyes |
46f18e7b RK |
1310 | then |
1311 | tm_file="${tm_file} pa/pa-gas.h" | |
1312 | fi | |
46f18e7b RK |
1313 | install_headers_dir=install-headers-cpio |
1314 | use_collect2=yes | |
1315 | ;; | |
18cae839 | 1316 | hppa1.1-*-hiux* | hppa2*-*-hiux*) |
13ee407e | 1317 | target_cpu_default="MASK_PA_11" |
88624c0e | 1318 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h pa/pa-hiux.h" |
46f18e7b RK |
1319 | xm_file=pa/xm-pahpux.h |
1320 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1321 | if test x$gas = xyes |
46f18e7b RK |
1322 | then |
1323 | tm_file="${tm_file} pa/pa-gas.h" | |
1324 | fi | |
46f18e7b RK |
1325 | install_headers_dir=install-headers-cpio |
1326 | use_collect2=yes | |
1327 | ;; | |
1328 | hppa1.0-*-hiux*) | |
88624c0e | 1329 | tm_file="${tm_file} pa/pa32-regs.h pa/som.h pa/pa-hpux.h pa/pa-hiux.h" |
46f18e7b RK |
1330 | xm_file=pa/xm-pahpux.h |
1331 | xmake_file=pa/x-pa-hpux | |
75bffa71 | 1332 | if test x$gas = xyes |
46f18e7b RK |
1333 | then |
1334 | tm_file="${tm_file} pa/pa-gas.h" | |
1335 | fi | |
46f18e7b RK |
1336 | install_headers_dir=install-headers-cpio |
1337 | use_collect2=yes | |
1338 | ;; | |
1339 | hppa*-*-lites*) | |
88624c0e | 1340 | tm_file="${tm_file} pa/pa32-regs.h elfos.h pa/elf.h" |
13ee407e | 1341 | target_cpu_default="MASK_PA_11" |
46f18e7b | 1342 | use_collect2=yes |
46f18e7b | 1343 | ;; |
6bc2c8c8 | 1344 | hppa*-*-mpeix*) |
5d712c39 | 1345 | tm_file="${tm_file} pa/pa32-regs.h pa/long_double.h pa/som.h pa/pa-mpeix.h" |
6bc2c8c8 MK |
1346 | xm_file=pa/xm-pampeix.h |
1347 | xmake_file=pa/x-pa-mpeix | |
1348 | echo "You must use gas. Assuming it is already installed." | |
1349 | install_headers_dir=install-headers-tar | |
6bc2c8c8 MK |
1350 | use_collect2=yes |
1351 | ;; | |
a2b368b6 LV |
1352 | i370-*-opened*) # IBM 360/370/390 Architecture |
1353 | xm_file=i370/xm-oe.h | |
1354 | tm_file=i370/oe.h | |
1355 | xmake_file=i370/x-oe | |
1356 | tmake_file=i370/t-oe | |
a2b368b6 | 1357 | ;; |
46f18e7b | 1358 | i370-*-mvs*) |
a2b368b6 LV |
1359 | xm_file=i370/xm-mvs.h |
1360 | tm_file=i370/mvs.h | |
1361 | tmake_file=i370/t-mvs | |
a2b368b6 LV |
1362 | ;; |
1363 | i370-*-linux*) | |
1364 | xm_file="xm-linux.h i370/xm-linux.h" | |
1365 | xmake_file=x-linux | |
1366 | tm_file="i370/linux.h ${tm_file}" | |
1367 | tmake_file="t-linux i370/t-linux" | |
a2b368b6 LV |
1368 | # broken_install=yes |
1369 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
1370 | # extra_parts="crtbegin.o crtend.o" | |
1371 | gnu_ld=yes | |
1372 | gas=yes | |
1373 | elf=yes | |
2618c083 | 1374 | if test x$enable_threads = xyes; then |
a2b368b6 LV |
1375 | thread_file='posix' |
1376 | fi | |
46f18e7b | 1377 | ;; |
9b5c756a JL |
1378 | changequote(,)dnl |
1379 | i[34567]86-*-elf*) | |
1380 | changequote([,])dnl | |
1381 | xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h" | |
1382 | tm_file=i386/i386elf.h | |
1383 | tmake_file=i386/t-i386elf | |
1384 | xmake_file=x-svr4 | |
1385 | ;; | |
75bffa71 ILT |
1386 | changequote(,)dnl |
1387 | i[34567]86-ibm-aix*) # IBM PS/2 running AIX | |
1388 | changequote([,])dnl | |
1389 | if test x$gas = xyes | |
46f18e7b RK |
1390 | then |
1391 | tm_file=i386/aix386.h | |
1392 | extra_parts="crtbegin.o crtend.o" | |
1393 | tmake_file=i386/t-crtstuff | |
1394 | else | |
1395 | tm_file=i386/aix386ng.h | |
1396 | use_collect2=yes | |
1397 | fi | |
61536478 JL |
1398 | xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}" |
1399 | xm_defines=USG | |
46f18e7b | 1400 | xmake_file=i386/x-aix |
46f18e7b | 1401 | ;; |
75bffa71 ILT |
1402 | changequote(,)dnl |
1403 | i[34567]86-ncr-sysv4*) # NCR 3000 - ix86 running system V.4 | |
1404 | changequote([,])dnl | |
2d092ffa | 1405 | xm_file="xm-alloca.h ${xm_file}" |
61536478 | 1406 | xm_defines="USG POSIX SMALL_ARG_MAX" |
46f18e7b | 1407 | xmake_file=i386/x-ncr3000 |
75bffa71 | 1408 | if test x$stabs = xyes -a x$gas = xyes |
46f18e7b RK |
1409 | then |
1410 | tm_file=i386/sysv4gdb.h | |
1411 | else | |
1412 | tm_file=i386/sysv4.h | |
1413 | fi | |
1414 | extra_parts="crtbegin.o crtend.o" | |
1415 | tmake_file=i386/t-crtpic | |
1416 | ;; | |
75bffa71 ILT |
1417 | changequote(,)dnl |
1418 | i[34567]86-next-*) | |
1419 | changequote([,])dnl | |
46f18e7b RK |
1420 | tm_file=i386/next.h |
1421 | xm_file=i386/xm-next.h | |
1422 | tmake_file=i386/t-next | |
1423 | xmake_file=i386/x-next | |
1424 | extra_objs=nextstep.o | |
750930c1 | 1425 | extra_parts="crtbegin.o crtend.o" |
75bffa71 | 1426 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
1427 | thread_file='mach' |
1428 | fi | |
46f18e7b | 1429 | ;; |
4c2c5712 GK |
1430 | changequote(,)dnl |
1431 | i[34567]86-*-netware) # Intel 80386's running netware | |
1432 | changequote([,])dnl | |
1433 | tm_file=i386/netware.h | |
1434 | tmake_file=i386/t-netware | |
1435 | ;; | |
75bffa71 ILT |
1436 | changequote(,)dnl |
1437 | i[34567]86-sequent-bsd*) # 80386 from Sequent | |
1438 | changequote([,])dnl | |
46f18e7b | 1439 | use_collect2=yes |
75bffa71 | 1440 | if test x$gas = xyes |
46f18e7b RK |
1441 | then |
1442 | tm_file=i386/seq-gas.h | |
1443 | else | |
1444 | tm_file=i386/sequent.h | |
1445 | fi | |
1446 | ;; | |
75bffa71 ILT |
1447 | changequote(,)dnl |
1448 | i[34567]86-sequent-ptx1*) | |
1449 | changequote([,])dnl | |
61536478 | 1450 | xm_defines="USG SVR3" |
46f18e7b RK |
1451 | xmake_file=i386/x-sysv3 |
1452 | tm_file=i386/seq-sysv3.h | |
1453 | tmake_file=i386/t-crtstuff | |
46f18e7b RK |
1454 | extra_parts="crtbegin.o crtend.o" |
1455 | install_headers_dir=install-headers-cpio | |
46f18e7b | 1456 | ;; |
75bffa71 ILT |
1457 | changequote(,)dnl |
1458 | i[34567]86-sequent-ptx2* | i[34567]86-sequent-sysv3*) | |
1459 | changequote([,])dnl | |
61536478 | 1460 | xm_defines="USG SVR3" |
46f18e7b RK |
1461 | xmake_file=i386/x-sysv3 |
1462 | tm_file=i386/seq2-sysv3.h | |
1463 | tmake_file=i386/t-crtstuff | |
1464 | extra_parts="crtbegin.o crtend.o" | |
46f18e7b | 1465 | install_headers_dir=install-headers-cpio |
46f18e7b | 1466 | ;; |
75bffa71 ILT |
1467 | changequote(,)dnl |
1468 | i[34567]86-sequent-ptx4* | i[34567]86-sequent-sysv4*) | |
1469 | changequote([,])dnl | |
2d092ffa | 1470 | xm_file="xm-alloca.h ${xm_file}" |
61536478 | 1471 | xm_defines="USG POSIX SMALL_ARG_MAX" |
46f18e7b RK |
1472 | xmake_file=x-svr4 |
1473 | tm_file=i386/ptx4-i.h | |
1474 | tmake_file=t-svr4 | |
1475 | extra_parts="crtbegin.o crtend.o" | |
46f18e7b | 1476 | install_headers_dir=install-headers-cpio |
46f18e7b RK |
1477 | ;; |
1478 | i386-sun-sunos*) # Sun i386 roadrunner | |
61536478 | 1479 | xm_defines=USG |
46f18e7b RK |
1480 | tm_file=i386/sun.h |
1481 | use_collect2=yes | |
1482 | ;; | |
75bffa71 ILT |
1483 | changequote(,)dnl |
1484 | i[34567]86-wrs-vxworks*) | |
1485 | changequote([,])dnl | |
9e89df50 MS |
1486 | tm_file=i386/vxi386.h |
1487 | tmake_file=i386/t-i386bare | |
28897609 | 1488 | thread_file='vxworks' |
9e89df50 | 1489 | ;; |
75bffa71 ILT |
1490 | changequote(,)dnl |
1491 | i[34567]86-*-aout*) | |
1492 | changequote([,])dnl | |
46f18e7b RK |
1493 | tm_file=i386/i386-aout.h |
1494 | tmake_file=i386/t-i386bare | |
1495 | ;; | |
512b62fb JM |
1496 | changequote(,)dnl |
1497 | i[34567]86-*-beoself* | i[34567]86-*-beos*) | |
1498 | changequote([,])dnl | |
1499 | xm_file=i386/xm-beos.h | |
1500 | tmake_file='i386/t-beos i386/t-crtpic' | |
1501 | tm_file=i386/beos-elf.h | |
1502 | xmake_file=i386/x-beos | |
512b62fb | 1503 | extra_parts='crtbegin.o crtend.o' |
512b62fb | 1504 | ;; |
75bffa71 ILT |
1505 | changequote(,)dnl |
1506 | i[34567]86-*-bsdi* | i[34567]86-*-bsd386*) | |
1507 | changequote([,])dnl | |
46f18e7b | 1508 | tm_file=i386/bsd386.h |
46f18e7b RK |
1509 | # tmake_file=t-libc-ok |
1510 | ;; | |
75bffa71 ILT |
1511 | changequote(,)dnl |
1512 | i[34567]86-*-bsd*) | |
1513 | changequote([,])dnl | |
46f18e7b | 1514 | tm_file=i386/386bsd.h |
46f18e7b RK |
1515 | # tmake_file=t-libc-ok |
1516 | # Next line turned off because both 386BSD and BSD/386 use GNU ld. | |
1517 | # use_collect2=yes | |
1518 | ;; | |
75bffa71 | 1519 | changequote(,)dnl |
bad4c106 DB |
1520 | i[34567]86-*-freebsd[12] | i[34567]86-*-freebsd[12].* | i[34567]86-*-freebsd*aout*) |
1521 | changequote([,])dnl | |
41e5a1f5 | 1522 | tm_file="i386/freebsd-aout.h i386/perform.h" |
bad4c106 DB |
1523 | tmake_file=t-freebsd |
1524 | ;; | |
1525 | changequote(,)dnl | |
1526 | i[34567]86-*-freebsd*) | |
75bffa71 | 1527 | changequote([,])dnl |
41e5a1f5 | 1528 | tm_file="i386/i386.h i386/att.h svr4.h freebsd.h i386/freebsd.h i386/perform.h" |
56830143 | 1529 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" |
d0550c9b | 1530 | tmake_file=t-freebsd |
46f18e7b RK |
1531 | gas=yes |
1532 | gnu_ld=yes | |
1533 | stabs=yes | |
46346e0e LR |
1534 | case x${enable_threads} in |
1535 | xyes | xpthreads | xposix) | |
1536 | thread_file='posix' | |
e1459ff8 | 1537 | tmake_file="${tmake_file} t-freebsd-thread" |
46346e0e LR |
1538 | ;; |
1539 | esac | |
46f18e7b | 1540 | ;; |
75bffa71 | 1541 | changequote(,)dnl |
1b4a979b | 1542 | i[34567]86-*-netbsd*) |
75bffa71 | 1543 | changequote([,])dnl |
46f18e7b | 1544 | tm_file=i386/netbsd.h |
e47f44f4 | 1545 | tmake_file=t-netbsd |
ed4acb3b | 1546 | use_collect2=yes |
46f18e7b | 1547 | ;; |
1b4a979b ME |
1548 | changequote(,)dnl |
1549 | i[34567]86-*-openbsd*) | |
1550 | changequote([,])dnl | |
1b4a979b ME |
1551 | # we need collect2 until our bug is fixed... |
1552 | use_collect2=yes | |
1553 | ;; | |
75bffa71 ILT |
1554 | changequote(,)dnl |
1555 | i[34567]86-*-coff*) | |
1556 | changequote([,])dnl | |
46f18e7b RK |
1557 | tm_file=i386/i386-coff.h |
1558 | tmake_file=i386/t-i386bare | |
1559 | ;; | |
75bffa71 ILT |
1560 | changequote(,)dnl |
1561 | i[34567]86-*-isc*) # 80386 running ISC system | |
1562 | changequote([,])dnl | |
61536478 JL |
1563 | xm_file="${xm_file} i386/xm-isc.h" |
1564 | xm_defines="USG SVR3" | |
46f18e7b | 1565 | case $machine in |
75bffa71 ILT |
1566 | changequote(,)dnl |
1567 | i[34567]86-*-isc[34]*) | |
1568 | changequote([,])dnl | |
46f18e7b RK |
1569 | xmake_file=i386/x-isc3 |
1570 | ;; | |
1571 | *) | |
1572 | xmake_file=i386/x-isc | |
1573 | ;; | |
1574 | esac | |
75bffa71 | 1575 | if test x$gas = xyes -a x$stabs = xyes |
46f18e7b RK |
1576 | then |
1577 | tm_file=i386/iscdbx.h | |
1578 | tmake_file=i386/t-svr3dbx | |
1579 | extra_parts="svr3.ifile svr3z.ifile" | |
1580 | else | |
1581 | tm_file=i386/isccoff.h | |
1582 | tmake_file=i386/t-crtstuff | |
1583 | extra_parts="crtbegin.o crtend.o" | |
1584 | fi | |
a5598a06 | 1585 | tmake_file="$tmake_file i386/t-i386bare" |
46f18e7b | 1586 | install_headers_dir=install-headers-cpio |
46f18e7b | 1587 | ;; |
75bffa71 | 1588 | changequote(,)dnl |
57119aa9 | 1589 | i[34567]86-*-linux*oldld*) # Intel 80386's running GNU/Linux |
75bffa71 | 1590 | changequote([,])dnl # with a.out format using |
61536478 | 1591 | # pre BFD linkers |
46f18e7b RK |
1592 | xmake_file=x-linux-aout |
1593 | tmake_file="t-linux-aout i386/t-crtstuff" | |
1594 | tm_file=i386/linux-oldld.h | |
46f18e7b | 1595 | gnu_ld=yes |
f906a0f0 | 1596 | float_format=i386 |
46f18e7b | 1597 | ;; |
75bffa71 | 1598 | changequote(,)dnl |
57119aa9 | 1599 | i[34567]86-*-linux*aout*) # Intel 80386's running GNU/Linux |
75bffa71 | 1600 | changequote([,])dnl # with a.out format |
46f18e7b RK |
1601 | xmake_file=x-linux-aout |
1602 | tmake_file="t-linux-aout i386/t-crtstuff" | |
1603 | tm_file=i386/linux-aout.h | |
46f18e7b | 1604 | gnu_ld=yes |
f906a0f0 | 1605 | float_format=i386 |
46f18e7b | 1606 | ;; |
75bffa71 | 1607 | changequote(,)dnl |
57119aa9 | 1608 | i[34567]86-*-linux*libc1) # Intel 80386's running GNU/Linux |
75bffa71 | 1609 | changequote([,])dnl # with ELF format using the |
61536478 JL |
1610 | # GNU/Linux C library 5 |
1611 | xmake_file=x-linux | |
1612 | tm_file=i386/linux.h | |
78b9f8df RK |
1613 | tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff" |
1614 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
78b9f8df | 1615 | gnu_ld=yes |
f906a0f0 | 1616 | float_format=i386 |
75bffa71 | 1617 | if test x$enable_threads = xyes; then |
78b9f8df RK |
1618 | thread_file='single' |
1619 | fi | |
1620 | ;; | |
75bffa71 | 1621 | changequote(,)dnl |
57119aa9 | 1622 | i[34567]86-*-linux*) # Intel 80386's running GNU/Linux |
75bffa71 | 1623 | changequote([,])dnl # with ELF format using glibc 2 |
61536478 JL |
1624 | # aka GNU/Linux C library 6 |
1625 | xmake_file=x-linux | |
46f18e7b RK |
1626 | tm_file=i386/linux.h |
1627 | tmake_file="t-linux i386/t-crtstuff" | |
1628 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
46f18e7b | 1629 | gnu_ld=yes |
f906a0f0 | 1630 | float_format=i386 |
75bffa71 | 1631 | if test x$enable_threads = xyes; then |
78b9f8df RK |
1632 | thread_file='posix' |
1633 | fi | |
46f18e7b | 1634 | ;; |
75bffa71 ILT |
1635 | changequote(,)dnl |
1636 | i[34567]86-*-gnu*) | |
cd9e5e7c | 1637 | float_format=i386 |
75bffa71 | 1638 | changequote([,])dnl |
61536478 | 1639 | ;; |
75bffa71 ILT |
1640 | changequote(,)dnl |
1641 | i[34567]86-go32-msdos | i[34567]86-*-go32*) | |
1642 | changequote([,])dnl | |
77d787fa | 1643 | echo "GO32/DJGPP V1.X is no longer supported. Use *-pc-msdosdjgpp for DJGPP V2.X instead." |
866fb7cc | 1644 | exit 1 |
46f18e7b | 1645 | ;; |
75bffa71 ILT |
1646 | changequote(,)dnl |
1647 | i[34567]86-pc-msdosdjgpp*) | |
1648 | changequote([,])dnl | |
77d787fa ME |
1649 | xm_file=i386/xm-djgpp.h |
1650 | tm_file=i386/djgpp.h | |
1651 | tmake_file=i386/t-djgpp | |
1652 | xmake_file=i386/x-djgpp | |
61536478 JL |
1653 | gnu_ld=yes |
1654 | gas=yes | |
dedcc399 | 1655 | exeext=.exe |
2838397c | 1656 | float_format=none |
77d787fa | 1657 | case $host in *pc-msdosdjgpp*) |
dedcc399 ME |
1658 | target_alias=djgpp |
1659 | ;; | |
1660 | esac | |
46f18e7b | 1661 | ;; |
75bffa71 ILT |
1662 | changequote(,)dnl |
1663 | i[34567]86-moss-msdos* | i[34567]86-*-moss*) | |
1664 | changequote([,])dnl | |
46f18e7b RK |
1665 | tm_file=i386/moss.h |
1666 | tmake_file=t-libc-ok | |
46f18e7b RK |
1667 | gnu_ld=yes |
1668 | gas=yes | |
1669 | ;; | |
75bffa71 ILT |
1670 | changequote(,)dnl |
1671 | i[34567]86-*-lynxos*) | |
1672 | changequote([,])dnl | |
1673 | if test x$gas = xyes | |
46f18e7b RK |
1674 | then |
1675 | tm_file=i386/lynx.h | |
1676 | else | |
1677 | tm_file=i386/lynx-ng.h | |
1678 | fi | |
1679 | xm_file=i386/xm-lynx.h | |
1680 | tmake_file=i386/t-i386bare | |
1681 | xmake_file=x-lynx | |
1682 | ;; | |
75bffa71 ILT |
1683 | changequote(,)dnl |
1684 | i[34567]86-*-mach*) | |
1685 | changequote([,])dnl | |
46f18e7b RK |
1686 | tm_file=i386/mach.h |
1687 | # tmake_file=t-libc-ok | |
1688 | use_collect2=yes | |
1689 | ;; | |
75bffa71 ILT |
1690 | changequote(,)dnl |
1691 | i[34567]86-*-osfrose*) # 386 using OSF/rose | |
1692 | changequote([,])dnl | |
1693 | if test x$elf = xyes | |
46f18e7b RK |
1694 | then |
1695 | tm_file=i386/osfelf.h | |
1696 | use_collect2= | |
1697 | else | |
1698 | tm_file=i386/osfrose.h | |
1699 | use_collect2=yes | |
1700 | fi | |
61536478 | 1701 | xm_file="i386/xm-osf.h ${xm_file}" |
46f18e7b RK |
1702 | xmake_file=i386/x-osfrose |
1703 | tmake_file=i386/t-osf | |
1704 | extra_objs=halfpic.o | |
1705 | ;; | |
75bffa71 ILT |
1706 | changequote(,)dnl |
1707 | i[34567]86-go32-rtems*) | |
1708 | changequote([,])dnl | |
46f18e7b RK |
1709 | cpu_type=i386 |
1710 | xm_file=i386/xm-go32.h | |
1711 | tm_file=i386/go32-rtems.h | |
1712 | tmake_file="i386/t-go32 t-rtems" | |
1713 | ;; | |
75bffa71 | 1714 | changequote(,)dnl |
0d4ef09c | 1715 | i[34567]86-*-rtemscoff*) |
75bffa71 | 1716 | changequote([,])dnl |
f5963e61 | 1717 | cpu_type=i386 |
0d4ef09c JS |
1718 | tm_file=i386/rtems.h |
1719 | tmake_file="i386/t-i386bare t-rtems" | |
f5963e61 | 1720 | ;; |
75bffa71 | 1721 | changequote(,)dnl |
0d4ef09c | 1722 | i[34567]86-*-rtems*|i[34567]86-*-rtemself*) |
75bffa71 | 1723 | changequote([,])dnl |
46f18e7b | 1724 | cpu_type=i386 |
0d4ef09c JS |
1725 | tm_file=i386/rtemself.h |
1726 | extra_parts="crtbegin.o crtend.o crti.o crtn.o" | |
1727 | tmake_file="i386/t-rtems-i386 i386/t-crtstuff t-rtems" | |
46f18e7b | 1728 | ;; |
75bffa71 ILT |
1729 | changequote(,)dnl |
1730 | i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5 | |
1731 | changequote([,])dnl | |
2d092ffa | 1732 | xm_file="xm-alloca.h ${xm_file} i386/xm-sco5.h" |
61536478 | 1733 | xm_defines="USG SVR3" |
46f18e7b | 1734 | xmake_file=i386/x-sco5 |
f6857708 | 1735 | install_headers_dir=install-headers-cpio |
46f18e7b | 1736 | tm_file=i386/sco5.h |
75bffa71 | 1737 | if test x$gas = xyes |
f7c9c2bb RL |
1738 | then |
1739 | tm_file="i386/sco5gas.h ${tm_file}" | |
1740 | tmake_file=i386/t-sco5gas | |
1741 | else | |
1742 | tmake_file=i386/t-sco5 | |
1743 | fi | |
a5598a06 | 1744 | tmake_file="$tmake_file i386/t-i386bare" |
42902a72 | 1745 | extra_parts="crti.o crtbegin.o crtend.o crtbeginS.o crtendS.o" |
46f18e7b | 1746 | ;; |
75bffa71 ILT |
1747 | changequote(,)dnl |
1748 | i[34567]86-*-sco3.2v4*) # 80386 running SCO 3.2v4 system | |
1749 | changequote([,])dnl | |
61536478 | 1750 | xm_file="${xm_file} i386/xm-sco.h" |
2d092ffa | 1751 | xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX" |
46f18e7b | 1752 | xmake_file=i386/x-sco4 |
46f18e7b | 1753 | install_headers_dir=install-headers-cpio |
75bffa71 | 1754 | if test x$stabs = xyes |
46f18e7b RK |
1755 | then |
1756 | tm_file=i386/sco4dbx.h | |
1757 | tmake_file=i386/t-svr3dbx | |
1758 | extra_parts="svr3.ifile svr3z.rfile" | |
1759 | else | |
1760 | tm_file=i386/sco4.h | |
1761 | tmake_file=i386/t-crtstuff | |
1762 | extra_parts="crtbegin.o crtend.o" | |
1763 | fi | |
a5598a06 | 1764 | tmake_file="$tmake_file i386/t-i386bare" |
090164c0 WB |
1765 | # The default EAFS filesystem supports long file names. |
1766 | # Truncating the target makes $host != $target which | |
1767 | # makes gcc think it is doing a cross-compile. | |
1768 | # truncate_target=yes | |
46f18e7b | 1769 | ;; |
75bffa71 ILT |
1770 | changequote(,)dnl |
1771 | i[34567]86-*-sco*) # 80386 running SCO system | |
1772 | changequote([,])dnl | |
46f18e7b RK |
1773 | xm_file=i386/xm-sco.h |
1774 | xmake_file=i386/x-sco | |
46f18e7b | 1775 | install_headers_dir=install-headers-cpio |
75bffa71 | 1776 | if test x$stabs = xyes |
46f18e7b RK |
1777 | then |
1778 | tm_file=i386/scodbx.h | |
1779 | tmake_file=i386/t-svr3dbx | |
1780 | extra_parts="svr3.ifile svr3z.rfile" | |
1781 | else | |
1782 | tm_file=i386/sco.h | |
1783 | extra_parts="crtbegin.o crtend.o" | |
1784 | tmake_file=i386/t-crtstuff | |
1785 | fi | |
a5598a06 | 1786 | tmake_file="$tmake_file i386/t-i386bare" |
46f18e7b RK |
1787 | truncate_target=yes |
1788 | ;; | |
75bffa71 ILT |
1789 | changequote(,)dnl |
1790 | i[34567]86-*-solaris2*) | |
1791 | changequote([,])dnl | |
2d092ffa | 1792 | xm_file="xm-alloca.h ${xm_file}" |
61536478 | 1793 | xm_defines="USG POSIX SMALL_ARG_MAX" |
0c723ada AO |
1794 | tm_file=i386/sol2.h |
1795 | if test x$gas = xyes; then | |
1796 | # Only needed if gas does not support -s | |
1797 | tm_file="i386/sol2gas.h ${tm_file}" | |
46f18e7b | 1798 | fi |
a5598a06 | 1799 | tmake_file="i386/t-i386bare i386/t-sol2" |
61536478 | 1800 | extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o" |
46f18e7b | 1801 | xmake_file=x-svr4 |
4a8021dc AO |
1802 | if test x${enable_threads} = x; then |
1803 | enable_threads=$have_pthread_h | |
1804 | if test x${enable_threads} = x; then | |
1805 | enable_threads=$have_thread_h | |
1806 | fi | |
1807 | fi | |
1808 | if test x${enable_threads} = xyes; then | |
1809 | if test x${have_pthread_h} = xyes; then | |
1810 | thread_file='posix' | |
1811 | else | |
0bbb1697 | 1812 | thread_file='solaris' |
4a8021dc | 1813 | fi |
0bbb1697 | 1814 | fi |
46f18e7b | 1815 | ;; |
75bffa71 ILT |
1816 | changequote(,)dnl |
1817 | i[34567]86-*-sysv5*) # Intel x86 on System V Release 5 | |
1818 | changequote([,])dnl | |
2d092ffa | 1819 | xm_file="xm-alloca.h ${xm_file}" |
a4cbe801 | 1820 | xm_defines="USG POSIX" |
87e11b70 | 1821 | tm_file=i386/sysv5.h |
75bffa71 | 1822 | if test x$stabs = xyes |
fe07d4c1 RL |
1823 | then |
1824 | tm_file="${tm_file} dbx.h" | |
1825 | fi | |
a5598a06 | 1826 | tmake_file="i386/t-i386bare i386/t-crtpic" |
fe07d4c1 RL |
1827 | xmake_file=x-svr4 |
1828 | extra_parts="crtbegin.o crtend.o" | |
01e39005 RL |
1829 | if test x$enable_threads = xyes; then |
1830 | thread_file='posix' | |
1831 | fi | |
fe07d4c1 | 1832 | ;; |
75bffa71 ILT |
1833 | changequote(,)dnl |
1834 | i[34567]86-*-sysv4*) # Intel 80386's running system V.4 | |
1835 | changequote([,])dnl | |
2d092ffa | 1836 | xm_file="xm-alloca.h ${xm_file}" |
61536478 | 1837 | xm_defines="USG POSIX SMALL_ARG_MAX" |
46f18e7b | 1838 | tm_file=i386/sysv4.h |
75bffa71 | 1839 | if test x$stabs = xyes |
46f18e7b RK |
1840 | then |
1841 | tm_file="${tm_file} dbx.h" | |
1842 | fi | |
a5598a06 | 1843 | tmake_file="i386/t-i386bare i386/t-crtpic" |
46f18e7b RK |
1844 | xmake_file=x-svr4 |
1845 | extra_parts="crtbegin.o crtend.o" | |
1846 | ;; | |
5aaf0123 RL |
1847 | changequote(,)dnl |
1848 | i[34567]86-*-udk*) # Intel x86 on SCO UW/OSR5 Dev Kit | |
1849 | changequote([,])dnl | |
2d092ffa | 1850 | xm_file="xm-alloca.h ${xm_file}" |
5aaf0123 RL |
1851 | xm_defines="USG POSIX" |
1852 | tm_file=i386/udk.h | |
a5598a06 | 1853 | tmake_file="i386/t-i386bare i386/t-crtpic i386/t-udk" |
5aaf0123 RL |
1854 | xmake_file=x-svr4 |
1855 | extra_parts="crtbegin.o crtend.o" | |
fd9c643f | 1856 | install_headers_dir=install-headers-cpio |
5aaf0123 | 1857 | ;; |
75bffa71 ILT |
1858 | changequote(,)dnl |
1859 | i[34567]86-*-osf1*) # Intel 80386's running OSF/1 1.3+ | |
1860 | changequote([,])dnl | |
f5963e61 JL |
1861 | cpu_type=i386 |
1862 | xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h i386/xm-osf1elf.h" | |
1863 | xm_defines="USE_C_ALLOCA SMALL_ARG_MAX" | |
75bffa71 | 1864 | if test x$stabs = xyes |
f5963e61 JL |
1865 | then |
1866 | tm_file=i386/osf1elfgdb.h | |
1867 | else | |
1868 | tm_file=i386/osf1elf.h | |
1869 | fi | |
1870 | tmake_file=i386/t-osf1elf | |
1871 | xmake_file=i386/x-osf1elf | |
1872 | extra_parts="crti.o crtn.o crtbegin.o crtend.o" | |
1873 | ;; | |
75bffa71 ILT |
1874 | changequote(,)dnl |
1875 | i[34567]86-*-sysv*) # Intel 80386's running system V | |
1876 | changequote([,])dnl | |
61536478 | 1877 | xm_defines="USG SVR3" |
46f18e7b | 1878 | xmake_file=i386/x-sysv3 |
75bffa71 | 1879 | if test x$gas = xyes |
46f18e7b | 1880 | then |
75bffa71 | 1881 | if test x$stabs = xyes |
46f18e7b RK |
1882 | then |
1883 | tm_file=i386/svr3dbx.h | |
1884 | tmake_file=i386/t-svr3dbx | |
1885 | extra_parts="svr3.ifile svr3z.rfile" | |
1886 | else | |
1887 | tm_file=i386/svr3gas.h | |
1888 | extra_parts="crtbegin.o crtend.o" | |
1889 | tmake_file=i386/t-crtstuff | |
1890 | fi | |
1891 | else | |
1892 | tm_file=i386/sysv3.h | |
1893 | extra_parts="crtbegin.o crtend.o" | |
1894 | tmake_file=i386/t-crtstuff | |
1895 | fi | |
a5598a06 | 1896 | tmake_file="$tmake_file i386/t-crtpic" |
46f18e7b RK |
1897 | ;; |
1898 | i386-*-vsta) # Intel 80386's running VSTa kernel | |
f5963e61 | 1899 | xm_file="${xm_file} i386/xm-vsta.h" |
46f18e7b RK |
1900 | tm_file=i386/vsta.h |
1901 | tmake_file=i386/t-vsta | |
1902 | xmake_file=i386/x-vsta | |
1903 | ;; | |
75bffa71 ILT |
1904 | changequote(,)dnl |
1905 | i[34567]86-*-win32) | |
1906 | changequote([,])dnl | |
cae21ae8 GN |
1907 | xm_file="${xm_file} i386/xm-cygwin.h" |
1908 | tmake_file=i386/t-cygwin | |
84530511 | 1909 | tm_file=i386/win32.h |
cae21ae8 | 1910 | xmake_file=i386/x-cygwin |
84530511 | 1911 | extra_objs=winnt.o |
75bffa71 | 1912 | if test x$enable_threads = xyes; then |
84530511 SC |
1913 | thread_file='win32' |
1914 | fi | |
1915 | exeext=.exe | |
1916 | ;; | |
75bffa71 | 1917 | changequote(,)dnl |
cae21ae8 | 1918 | i[34567]86-*-pe | i[34567]86-*-cygwin*) |
75bffa71 | 1919 | changequote([,])dnl |
cae21ae8 GN |
1920 | xm_file="${xm_file} i386/xm-cygwin.h" |
1921 | tmake_file=i386/t-cygwin | |
1922 | tm_file=i386/cygwin.h | |
1923 | xmake_file=i386/x-cygwin | |
46f18e7b | 1924 | extra_objs=winnt.o |
75bffa71 | 1925 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
1926 | thread_file='win32' |
1927 | fi | |
46f18e7b RK |
1928 | exeext=.exe |
1929 | ;; | |
75bffa71 ILT |
1930 | changequote(,)dnl |
1931 | i[34567]86-*-mingw32*) | |
1932 | changequote([,])dnl | |
5dfe8508 RK |
1933 | tm_file=i386/mingw32.h |
1934 | xm_file="${xm_file} i386/xm-mingw32.h" | |
cae21ae8 | 1935 | tmake_file="i386/t-cygwin i386/t-mingw32" |
5dfe8508 | 1936 | extra_objs=winnt.o |
cae21ae8 | 1937 | xmake_file=i386/x-cygwin |
75bffa71 | 1938 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
1939 | thread_file='win32' |
1940 | fi | |
5dfe8508 | 1941 | exeext=.exe |
61536478 JL |
1942 | case $machine in |
1943 | *mingw32msv*) | |
1944 | ;; | |
1945 | *minwg32crt* | *mingw32*) | |
1946 | tm_file="${tm_file} i386/crtdll.h" | |
1947 | ;; | |
1948 | esac | |
5dfe8508 | 1949 | ;; |
b27d2bd5 MK |
1950 | changequote(,)dnl |
1951 | i[34567]86-*-uwin*) | |
1952 | changequote([,])dnl | |
1953 | tm_file=i386/uwin.h | |
1954 | xm_file="${xm_file} i386/xm-uwin.h" | |
2d092ffa | 1955 | xm_defines="USG NO_STAB_H" |
b27d2bd5 MK |
1956 | tmake_file="i386/t-cygwin i386/t-uwin" |
1957 | extra_objs=winnt.o | |
1958 | xmake_file=i386/x-cygwin | |
b27d2bd5 MK |
1959 | if test x$enable_threads = xyes; then |
1960 | thread_file='win32' | |
1961 | fi | |
1962 | exeext=.exe | |
1963 | ;; | |
052dbd9e MK |
1964 | changequote(,)dnl |
1965 | i[34567]86-*-interix*) | |
1966 | changequote([,])dnl | |
615c8231 | 1967 | tm_file="i386/i386-interix.h interix.h" |
97ad1d43 | 1968 | xm_file="i386/xm-i386-interix.h xm-interix.h" |
2d092ffa | 1969 | xm_defines="USG" |
052dbd9e MK |
1970 | tmake_file="i386/t-interix" |
1971 | extra_objs=interix.o | |
1972 | xmake_file=x-interix | |
615c8231 | 1973 | if test x$enable_threads = xyes ; then |
052dbd9e MK |
1974 | thread_file='posix' |
1975 | fi | |
615c8231 | 1976 | if test x$stabs = xyes ; then |
052dbd9e MK |
1977 | tm_file="${tm_file} dbxcoff.h" |
1978 | fi | |
1979 | ;; | |
75bffa71 ILT |
1980 | changequote(,)dnl |
1981 | i[34567]86-*-winnt3*) | |
1982 | changequote([,])dnl | |
46f18e7b RK |
1983 | tm_file=i386/win-nt.h |
1984 | out_file=i386/i386.c | |
61536478 | 1985 | xm_file="xm-winnt.h ${xm_file}" |
46f18e7b RK |
1986 | xmake_file=winnt/x-winnt |
1987 | tmake_file=i386/t-winnt | |
1988 | extra_host_objs="winnt.o oldnames.o" | |
1989 | extra_gcc_objs="spawnv.o oldnames.o" | |
75bffa71 | 1990 | if test x$gnu_ld != xyes |
46f18e7b RK |
1991 | then |
1992 | extra_programs=ld.exe | |
1993 | fi | |
75bffa71 | 1994 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
1995 | thread_file='win32' |
1996 | fi | |
46f18e7b | 1997 | ;; |
75bffa71 ILT |
1998 | changequote(,)dnl |
1999 | i[34567]86-dg-dgux*) | |
2000 | changequote([,])dnl | |
2d092ffa | 2001 | xm_file="xm-alloca.h ${xm_file}" |
61536478 | 2002 | xm_defines="USG POSIX" |
46f18e7b RK |
2003 | out_file=i386/dgux.c |
2004 | tm_file=i386/dgux.h | |
2005 | tmake_file=i386/t-dgux | |
2006 | xmake_file=i386/x-dgux | |
46f18e7b RK |
2007 | install_headers_dir=install-headers-cpio |
2008 | ;; | |
2009 | i860-alliant-*) # Alliant FX/2800 | |
2010 | tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h" | |
956d6950 | 2011 | xm_file="${xm_file}" |
46f18e7b RK |
2012 | xmake_file=i860/x-fx2800 |
2013 | tmake_file=i860/t-fx2800 | |
2014 | extra_parts="crtbegin.o crtend.o" | |
2015 | ;; | |
2016 | i860-*-bsd*) | |
2017 | tm_file="${tm_file} i860/bsd.h" | |
75bffa71 | 2018 | if test x$gas = xyes |
46f18e7b RK |
2019 | then |
2020 | tm_file="${tm_file} i860/bsd-gas.h" | |
2021 | fi | |
2022 | use_collect2=yes | |
2023 | ;; | |
2024 | i860-*-mach*) | |
2025 | tm_file="${tm_file} i860/mach.h" | |
2026 | tmake_file=t-libc-ok | |
2027 | ;; | |
2028 | i860-*-osf*) # Intel Paragon XP/S, OSF/1AD | |
2029 | tm_file="${tm_file} svr3.h i860/paragon.h" | |
61536478 | 2030 | xm_defines="USG SVR3" |
46f18e7b | 2031 | tmake_file=t-osf |
46f18e7b RK |
2032 | ;; |
2033 | i860-*-sysv3*) | |
2034 | tm_file="${tm_file} svr3.h i860/sysv3.h" | |
61536478 | 2035 | xm_defines="USG SVR3" |
46f18e7b RK |
2036 | xmake_file=i860/x-sysv3 |
2037 | extra_parts="crtbegin.o crtend.o" | |
2038 | ;; | |
2039 | i860-*-sysv4*) | |
2040 | tm_file="${tm_file} svr4.h i860/sysv4.h" | |
61536478 | 2041 | xm_defines="USG SVR3" |
46f18e7b RK |
2042 | xmake_file=i860/x-sysv4 |
2043 | tmake_file=t-svr4 | |
2044 | extra_parts="crtbegin.o crtend.o" | |
2045 | ;; | |
2046 | i960-wrs-vxworks5 | i960-wrs-vxworks5.0*) | |
2047 | tm_file="${tm_file} i960/vx960.h" | |
2048 | tmake_file=i960/t-vxworks960 | |
2049 | use_collect2=yes | |
7cc34889 | 2050 | thread_file='vxworks' |
46f18e7b | 2051 | ;; |
a0372c94 | 2052 | i960-wrs-vxworks5* | i960-wrs-vxworks) |
46f18e7b RK |
2053 | tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h" |
2054 | tmake_file=i960/t-vxworks960 | |
2055 | use_collect2=yes | |
7cc34889 | 2056 | thread_file='vxworks' |
46f18e7b RK |
2057 | ;; |
2058 | i960-wrs-vxworks*) | |
2059 | tm_file="${tm_file} i960/vx960.h" | |
2060 | tmake_file=i960/t-vxworks960 | |
2061 | use_collect2=yes | |
7cc34889 | 2062 | thread_file='vxworks' |
46f18e7b RK |
2063 | ;; |
2064 | i960-*-coff*) | |
2065 | tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h" | |
2066 | tmake_file=i960/t-960bare | |
2067 | use_collect2=yes | |
2068 | ;; | |
2069 | i960-*-rtems) | |
2070 | tmake_file="i960/t-960bare t-rtems" | |
2071 | tm_file="${tm_file} dbxcoff.h i960/rtems.h" | |
2072 | use_collect2=yes | |
2073 | ;; | |
2074 | i960-*-*) # Default i960 environment. | |
2075 | use_collect2=yes | |
2076 | ;; | |
c65ebc55 JW |
2077 | ia64*-*-elf*) |
2078 | tm_file=ia64/elf.h | |
2079 | tmake_file="ia64/t-ia64" | |
2080 | target_cpu_default="0" | |
2081 | if test x$gas = xyes | |
2082 | then | |
2083 | target_cpu_default="${target_cpu_default}|MASK_GNU_AS" | |
2084 | fi | |
2085 | if test x$gnu_ld = xyes | |
2086 | then | |
2087 | target_cpu_default="${target_cpu_default}|MASK_GNU_LD" | |
2088 | fi | |
3f622353 | 2089 | float_format=i386 |
c65ebc55 JW |
2090 | ;; |
2091 | ia64*-*-linux*) | |
2092 | tm_file=ia64/linux.h | |
fee0225a | 2093 | tmake_file="t-linux ia64/t-ia64 ia64/t-glibc" |
c65ebc55 JW |
2094 | target_cpu_default="MASK_GNU_AS|MASK_GNU_LD" |
2095 | if test x$enable_threads = xyes; then | |
2096 | thread_file='posix' | |
2097 | fi | |
3f622353 | 2098 | float_format=i386 |
c65ebc55 | 2099 | ;; |
dec3e070 JW |
2100 | m32r-*-elf*) |
2101 | extra_parts="crtinit.o crtfini.o" | |
2102 | ;; | |
63883fc3 SC |
2103 | # m68hc11 and m68hc12 share the same machine description. |
2104 | m68hc11-*-*|m6811-*-*) | |
2105 | tm_file="m68hc11/m68hc11.h" | |
2106 | xm_file="m68hc11/xm-m68hc11.h" | |
2107 | tm_p_file="m68hc11/m68hc11-protos.h" | |
2108 | md_file="m68hc11/m68hc11.md" | |
2109 | out_file="m68hc11/m68hc11.c" | |
2110 | tmake_file="m68hc11/t-m68hc11-gas" | |
2111 | ;; | |
2112 | m68hc12-*-*|m6812-*-*) | |
2113 | tm_file="m68hc11/m68hc12.h" | |
2114 | tm_p_file="m68hc11/m68hc11-protos.h" | |
2115 | xm_file="m68hc11/xm-m68hc11.h" | |
2116 | md_file="m68hc11/m68hc11.md" | |
2117 | out_file="m68hc11/m68hc11.c" | |
2118 | tmake_file="m68hc11/t-m68hc11-gas" | |
2119 | ;; | |
46f18e7b RK |
2120 | m68000-convergent-sysv*) |
2121 | tm_file=m68k/ctix.h | |
61536478 JL |
2122 | xm_file="m68k/xm-3b1.h ${xm_file}" |
2123 | xm_defines=USG | |
46f18e7b RK |
2124 | use_collect2=yes |
2125 | extra_headers=math-68881.h | |
2126 | ;; | |
2127 | m68000-hp-bsd*) # HP 9000/200 running BSD | |
2128 | tm_file=m68k/hp2bsd.h | |
2129 | xmake_file=m68k/x-hp2bsd | |
2130 | use_collect2=yes | |
2131 | extra_headers=math-68881.h | |
2132 | ;; | |
2133 | m68000-hp-hpux*) # HP 9000 series 300 | |
1a87de8d | 2134 | xm_file="xm-alloca.h ${xm_file}" |
2d092ffa | 2135 | xm_defines="USG" |
75bffa71 | 2136 | if test x$gas = xyes |
46f18e7b RK |
2137 | then |
2138 | xmake_file=m68k/x-hp320g | |
2139 | tm_file=m68k/hp310g.h | |
2140 | else | |
2141 | xmake_file=m68k/x-hp320 | |
2142 | tm_file=m68k/hp310.h | |
2143 | fi | |
46f18e7b RK |
2144 | install_headers_dir=install-headers-cpio |
2145 | use_collect2=yes | |
2146 | extra_headers=math-68881.h | |
2147 | ;; | |
2148 | m68000-sun-sunos3*) | |
2149 | tm_file=m68k/sun2.h | |
2150 | use_collect2=yes | |
2151 | extra_headers=math-68881.h | |
2152 | ;; | |
2153 | m68000-sun-sunos4*) | |
2154 | tm_file=m68k/sun2o4.h | |
2155 | use_collect2=yes | |
2156 | extra_headers=math-68881.h | |
2157 | ;; | |
2158 | m68000-att-sysv*) | |
61536478 JL |
2159 | xm_file="m68k/xm-3b1.h ${xm_file}" |
2160 | xm_defines=USG | |
75bffa71 | 2161 | if test x$gas = xyes |
46f18e7b RK |
2162 | then |
2163 | tm_file=m68k/3b1g.h | |
2164 | else | |
2165 | tm_file=m68k/3b1.h | |
2166 | fi | |
2167 | use_collect2=yes | |
2168 | extra_headers=math-68881.h | |
2169 | ;; | |
2170 | m68k-apple-aux*) # Apple Macintosh running A/UX | |
61536478 | 2171 | xm_defines="USG AUX" |
46f18e7b | 2172 | tmake_file=m68k/t-aux |
46f18e7b RK |
2173 | install_headers_dir=install-headers-cpio |
2174 | extra_headers=math-68881.h | |
2175 | extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o" | |
2176 | tm_file= | |
75bffa71 | 2177 | if test "$gnu_ld" = yes |
46f18e7b RK |
2178 | then |
2179 | tm_file="${tm_file} m68k/auxgld.h" | |
2180 | else | |
2181 | tm_file="${tm_file} m68k/auxld.h" | |
2182 | fi | |
75bffa71 | 2183 | if test "$gas" = yes |
46f18e7b RK |
2184 | then |
2185 | tm_file="${tm_file} m68k/auxgas.h" | |
2186 | else | |
2187 | tm_file="${tm_file} m68k/auxas.h" | |
2188 | fi | |
2189 | tm_file="${tm_file} m68k/a-ux.h" | |
c8db55b0 | 2190 | float_format=m68k |
46f18e7b RK |
2191 | ;; |
2192 | m68k-apollo-*) | |
2193 | tm_file=m68k/apollo68.h | |
2194 | xmake_file=m68k/x-apollo68 | |
2195 | use_collect2=yes | |
2196 | extra_headers=math-68881.h | |
c8db55b0 | 2197 | float_format=m68k |
46f18e7b RK |
2198 | ;; |
2199 | m68k-altos-sysv*) # Altos 3068 | |
75bffa71 | 2200 | if test x$gas = xyes |
46f18e7b RK |
2201 | then |
2202 | tm_file=m68k/altos3068.h | |
61536478 | 2203 | xm_defines=USG |
46f18e7b RK |
2204 | else |
2205 | echo "The Altos is supported only with the GNU assembler" 1>&2 | |
2206 | exit 1 | |
2207 | fi | |
2208 | extra_headers=math-68881.h | |
2209 | ;; | |
2210 | m68k-bull-sysv*) # Bull DPX/2 | |
75bffa71 | 2211 | if test x$gas = xyes |
46f18e7b | 2212 | then |
75bffa71 | 2213 | if test x$stabs = xyes |
46f18e7b RK |
2214 | then |
2215 | tm_file=m68k/dpx2cdbx.h | |
2216 | else | |
2217 | tm_file=m68k/dpx2g.h | |
2218 | fi | |
2219 | else | |
2220 | tm_file=m68k/dpx2.h | |
2221 | fi | |
61536478 JL |
2222 | xm_file="xm-alloca.h ${xm_file}" |
2223 | xm_defines=USG | |
46f18e7b RK |
2224 | xmake_file=m68k/x-dpx2 |
2225 | use_collect2=yes | |
2226 | extra_headers=math-68881.h | |
2227 | ;; | |
2228 | m68k-atari-sysv4*) # Atari variant of V.4. | |
2229 | tm_file=m68k/atari.h | |
61536478 JL |
2230 | xm_file="xm-alloca.h ${xm_file}" |
2231 | xm_defines="USG FULL_PROTOTYPES" | |
46f18e7b RK |
2232 | tmake_file=t-svr4 |
2233 | extra_parts="crtbegin.o crtend.o" | |
2234 | extra_headers=math-68881.h | |
c8db55b0 | 2235 | float_format=m68k |
46f18e7b RK |
2236 | ;; |
2237 | m68k-motorola-sysv*) | |
2238 | tm_file=m68k/mot3300.h | |
61536478 | 2239 | xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}" |
75bffa71 | 2240 | if test x$gas = xyes |
46f18e7b RK |
2241 | then |
2242 | xmake_file=m68k/x-mot3300-gas | |
75bffa71 | 2243 | if test x$gnu_ld = xyes |
46f18e7b RK |
2244 | then |
2245 | tmake_file=m68k/t-mot3300-gald | |
2246 | else | |
2247 | tmake_file=m68k/t-mot3300-gas | |
2248 | use_collect2=yes | |
2249 | fi | |
2250 | else | |
2251 | xmake_file=m68k/x-mot3300 | |
75bffa71 | 2252 | if test x$gnu_ld = xyes |
46f18e7b RK |
2253 | then |
2254 | tmake_file=m68k/t-mot3300-gld | |
2255 | else | |
2256 | tmake_file=m68k/t-mot3300 | |
2257 | use_collect2=yes | |
2258 | fi | |
2259 | fi | |
2260 | gdb_needs_out_file_path=yes | |
2261 | extra_parts="crt0.o mcrt0.o" | |
2262 | extra_headers=math-68881.h | |
c8db55b0 | 2263 | float_format=m68k |
46f18e7b RK |
2264 | ;; |
2265 | m68k-ncr-sysv*) # NCR Tower 32 SVR3 | |
2266 | tm_file=m68k/tower-as.h | |
61536478 | 2267 | xm_defines="USG SVR3" |
46f18e7b RK |
2268 | xmake_file=m68k/x-tower |
2269 | extra_parts="crtbegin.o crtend.o" | |
2270 | extra_headers=math-68881.h | |
2271 | ;; | |
2272 | m68k-plexus-sysv*) | |
2273 | tm_file=m68k/plexus.h | |
61536478 JL |
2274 | xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}" |
2275 | xm_defines=USG | |
46f18e7b RK |
2276 | use_collect2=yes |
2277 | extra_headers=math-68881.h | |
2278 | ;; | |
2279 | m68k-tti-*) | |
2280 | tm_file=m68k/pbb.h | |
61536478 JL |
2281 | xm_file="xm-alloca.h ${xm_file}" |
2282 | xm_defines=USG | |
46f18e7b RK |
2283 | extra_headers=math-68881.h |
2284 | ;; | |
2285 | m68k-crds-unos*) | |
61536478 JL |
2286 | xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}" |
2287 | xm_defines="USG unos" | |
46f18e7b RK |
2288 | xmake_file=m68k/x-crds |
2289 | tm_file=m68k/crds.h | |
46f18e7b RK |
2290 | use_collect2=yes |
2291 | extra_headers=math-68881.h | |
2292 | ;; | |
2293 | m68k-cbm-sysv4*) # Commodore variant of V.4. | |
2294 | tm_file=m68k/amix.h | |
61536478 JL |
2295 | xm_file="xm-alloca.h ${xm_file}" |
2296 | xm_defines="USG FULL_PROTOTYPES" | |
46f18e7b RK |
2297 | xmake_file=m68k/x-amix |
2298 | tmake_file=t-svr4 | |
2299 | extra_parts="crtbegin.o crtend.o" | |
2300 | extra_headers=math-68881.h | |
c8db55b0 | 2301 | float_format=m68k |
46f18e7b RK |
2302 | ;; |
2303 | m68k-ccur-rtu) | |
2304 | tm_file=m68k/ccur-GAS.h | |
2305 | xmake_file=m68k/x-ccur | |
2306 | extra_headers=math-68881.h | |
2307 | use_collect2=yes | |
c8db55b0 | 2308 | float_format=m68k |
46f18e7b RK |
2309 | ;; |
2310 | m68k-hp-bsd4.4*) # HP 9000/3xx running 4.4bsd | |
2311 | tm_file=m68k/hp3bsd44.h | |
c83fe036 | 2312 | xmake_file=m68k/x-hp3bsd44 |
46f18e7b RK |
2313 | use_collect2=yes |
2314 | extra_headers=math-68881.h | |
c8db55b0 | 2315 | float_format=m68k |
46f18e7b RK |
2316 | ;; |
2317 | m68k-hp-bsd*) # HP 9000/3xx running Berkeley Unix | |
2318 | tm_file=m68k/hp3bsd.h | |
2319 | use_collect2=yes | |
2320 | extra_headers=math-68881.h | |
c8db55b0 | 2321 | float_format=m68k |
46f18e7b RK |
2322 | ;; |
2323 | m68k-isi-bsd*) | |
75bffa71 | 2324 | if test x$with_fp = xno |
46f18e7b RK |
2325 | then |
2326 | tm_file=m68k/isi-nfp.h | |
2327 | else | |
2328 | tm_file=m68k/isi.h | |
c8db55b0 | 2329 | float_format=m68k |
46f18e7b RK |
2330 | fi |
2331 | use_collect2=yes | |
2332 | extra_headers=math-68881.h | |
2333 | ;; | |
2334 | m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7. | |
1a87de8d | 2335 | xm_file="xm-alloca.h ${xm_file}" |
2d092ffa | 2336 | xm_defines="USG" |
75bffa71 | 2337 | if test x$gas = xyes |
46f18e7b RK |
2338 | then |
2339 | xmake_file=m68k/x-hp320g | |
2340 | tm_file=m68k/hp320g.h | |
2341 | else | |
2342 | xmake_file=m68k/x-hp320 | |
2343 | tm_file=m68k/hpux7.h | |
2344 | fi | |
46f18e7b RK |
2345 | install_headers_dir=install-headers-cpio |
2346 | use_collect2=yes | |
2347 | extra_headers=math-68881.h | |
c8db55b0 | 2348 | float_format=m68k |
46f18e7b RK |
2349 | ;; |
2350 | m68k-hp-hpux*) # HP 9000 series 300 | |
1a87de8d | 2351 | xm_file="xm-alloca.h ${xm_file}" |
2d092ffa | 2352 | xm_defines="USG" |
75bffa71 | 2353 | if test x$gas = xyes |
46f18e7b RK |
2354 | then |
2355 | xmake_file=m68k/x-hp320g | |
2356 | tm_file=m68k/hp320g.h | |
2357 | else | |
2358 | xmake_file=m68k/x-hp320 | |
2359 | tm_file=m68k/hp320.h | |
2360 | fi | |
46f18e7b RK |
2361 | install_headers_dir=install-headers-cpio |
2362 | use_collect2=yes | |
2363 | extra_headers=math-68881.h | |
c8db55b0 | 2364 | float_format=m68k |
46f18e7b RK |
2365 | ;; |
2366 | m68k-sun-mach*) | |
2367 | tm_file=m68k/sun3mach.h | |
2368 | use_collect2=yes | |
2369 | extra_headers=math-68881.h | |
c8db55b0 | 2370 | float_format=m68k |
46f18e7b RK |
2371 | ;; |
2372 | m68k-sony-newsos3*) | |
75bffa71 | 2373 | if test x$gas = xyes |
46f18e7b RK |
2374 | then |
2375 | tm_file=m68k/news3gas.h | |
2376 | else | |
2377 | tm_file=m68k/news3.h | |
2378 | fi | |
2379 | use_collect2=yes | |
2380 | extra_headers=math-68881.h | |
c8db55b0 | 2381 | float_format=m68k |
46f18e7b RK |
2382 | ;; |
2383 | m68k-sony-bsd* | m68k-sony-newsos*) | |
75bffa71 | 2384 | if test x$gas = xyes |
46f18e7b RK |
2385 | then |
2386 | tm_file=m68k/newsgas.h | |
2387 | else | |
2388 | tm_file=m68k/news.h | |
2389 | fi | |
2390 | use_collect2=yes | |
2391 | extra_headers=math-68881.h | |
c8db55b0 | 2392 | float_format=m68k |
46f18e7b RK |
2393 | ;; |
2394 | m68k-next-nextstep2*) | |
2395 | tm_file=m68k/next21.h | |
61536478 | 2396 | xm_file="m68k/xm-next.h ${xm_file}" |
46f18e7b RK |
2397 | tmake_file=m68k/t-next |
2398 | xmake_file=m68k/x-next | |
2399 | extra_objs=nextstep.o | |
2400 | extra_headers=math-68881.h | |
2401 | use_collect2=yes | |
c8db55b0 | 2402 | float_format=m68k |
46f18e7b | 2403 | ;; |
016cebc3 JL |
2404 | changequote(,)dnl |
2405 | m68k-next-nextstep[34]*) | |
2406 | changequote([,])dnl | |
46f18e7b | 2407 | tm_file=m68k/next.h |
61536478 | 2408 | xm_file="m68k/xm-next.h ${xm_file}" |
46f18e7b RK |
2409 | tmake_file=m68k/t-next |
2410 | xmake_file=m68k/x-next | |
2411 | extra_objs=nextstep.o | |
750930c1 | 2412 | extra_parts="crtbegin.o crtend.o" |
46f18e7b | 2413 | extra_headers=math-68881.h |
c8db55b0 | 2414 | float_format=m68k |
75bffa71 | 2415 | if test x$enable_threads = xyes; then |
0bbb1697 RK |
2416 | thread_file='mach' |
2417 | fi | |
46f18e7b RK |
2418 | ;; |
2419 | m68k-sun-sunos3*) | |
75bffa71 | 2420 | if test x$with_fp = xno |
46f18e7b RK |
2421 | then |
2422 | tm_file=m68k/sun3n3.h | |
2423 | else | |
2424 | tm_file=m68k/sun3o3.h | |
c8db55b0 | 2425 | float_format=m68k |
46f18e7b RK |
2426 | fi |
2427 | use_collect2=yes | |
2428 | extra_headers=math-68881.h | |
2429 | ;; | |
2430 | m68k-sun-sunos*) # For SunOS 4 (the default). | |
75bffa71 | 2431 | if test x$with_fp = xno |
46f18e7b RK |
2432 | then |
2433 | tm_file=m68k/sun3n.h | |
2434 | else | |
2435 | tm_file=m68k/sun3.h | |
c8db55b0 | 2436 | float_format=m68k |
46f18e7b | 2437 | fi |
46f18e7b RK |
2438 | use_collect2=yes |
2439 | extra_headers=math-68881.h | |
2440 | ;; | |
2441 | m68k-wrs-vxworks*) | |
2442 | tm_file=m68k/vxm68k.h | |
2443 | tmake_file=m68k/t-vxworks68 | |
2444 | extra_headers=math-68881.h | |
7cc34889 | 2445 | thread_file='vxworks' |
c8db55b0 | 2446 | float_format=m68k |
46f18e7b RK |
2447 | ;; |
2448 | m68k-*-aout*) | |
2449 | tmake_file=m68k/t-m68kbare | |
2450 | tm_file="m68k/m68k-aout.h libgloss.h" | |
2451 | extra_headers=math-68881.h | |
c8db55b0 | 2452 | float_format=m68k |
46f18e7b RK |
2453 | ;; |
2454 | m68k-*-coff*) | |
2455 | tmake_file=m68k/t-m68kbare | |
261f21e7 | 2456 | tm_file="m68k/m68k-coff.h dbx.h" |
46f18e7b | 2457 | extra_headers=math-68881.h |
c8db55b0 | 2458 | float_format=m68k |
46f18e7b | 2459 | ;; |
d1be3be3 | 2460 | m68020-*-elf* | m68k-*-elf*) |
7aae67a2 | 2461 | tm_file="m68k/m68020-elf.h" |
d1be3be3 JW |
2462 | xm_file=m68k/xm-m68kv.h |
2463 | tmake_file=m68k/t-m68kelf | |
2464 | header_files=math-68881.h | |
2465 | ;; | |
46f18e7b | 2466 | m68k-*-lynxos*) |
75bffa71 | 2467 | if test x$gas = xyes |
46f18e7b RK |
2468 | then |
2469 | tm_file=m68k/lynx.h | |
2470 | else | |
2471 | tm_file=m68k/lynx-ng.h | |
2472 | fi | |
2473 | xm_file=m68k/xm-lynx.h | |
2474 | xmake_file=x-lynx | |
2475 | tmake_file=m68k/t-lynx | |
2476 | extra_headers=math-68881.h | |
c8db55b0 | 2477 | float_format=m68k |
46f18e7b | 2478 | ;; |
58600d24 | 2479 | m68k*-*-netbsd*) |
46f18e7b | 2480 | tm_file=m68k/netbsd.h |
e47f44f4 | 2481 | tmake_file=t-netbsd |
c8db55b0 | 2482 | float_format=m68k |
ed4acb3b | 2483 | use_collect2=yes |
46f18e7b | 2484 | ;; |
1b4a979b ME |
2485 | m68k*-*-openbsd*) |
2486 | float_format=m68k | |
2487 | # we need collect2 until our bug is fixed... | |
2488 | use_collect2=yes | |
2489 | ;; | |
46f18e7b | 2490 | m68k-*-sysv3*) # Motorola m68k's running system V.3 |
61536478 JL |
2491 | xm_file="xm-alloca.h ${xm_file}" |
2492 | xm_defines=USG | |
46f18e7b RK |
2493 | xmake_file=m68k/x-m68kv |
2494 | extra_parts="crtbegin.o crtend.o" | |
2495 | extra_headers=math-68881.h | |
c8db55b0 | 2496 | float_format=m68k |
46f18e7b RK |
2497 | ;; |
2498 | m68k-*-sysv4*) # Motorola m68k's running system V.4 | |
2499 | tm_file=m68k/m68kv4.h | |
61536478 JL |
2500 | xm_file="xm-alloca.h ${xm_file}" |
2501 | xm_defines=USG | |
46f18e7b RK |
2502 | tmake_file=t-svr4 |
2503 | extra_parts="crtbegin.o crtend.o" | |
2504 | extra_headers=math-68881.h | |
c8db55b0 | 2505 | float_format=m68k |
46f18e7b | 2506 | ;; |
57119aa9 | 2507 | m68k-*-linux*aout*) # Motorola m68k's running GNU/Linux |
61536478 | 2508 | # with a.out format |
46f18e7b RK |
2509 | xmake_file=x-linux |
2510 | tm_file=m68k/linux-aout.h | |
2511 | tmake_file="t-linux-aout m68k/t-linux-aout" | |
46f18e7b | 2512 | extra_headers=math-68881.h |
c8db55b0 | 2513 | float_format=m68k |
46f18e7b | 2514 | gnu_ld=yes |
46f18e7b | 2515 | ;; |
57119aa9 | 2516 | m68k-*-linux*libc1) # Motorola m68k's running GNU/Linux |
61536478 JL |
2517 | # with ELF format using the |
2518 | # GNU/Linux C library 5 | |
2519 | xmake_file=x-linux | |
95fd3981 RK |
2520 | tm_file=m68k/linux.h |
2521 | tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux" | |
2522 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
95fd3981 | 2523 | extra_headers=math-68881.h |
c8db55b0 | 2524 | float_format=m68k |
95fd3981 RK |
2525 | gnu_ld=yes |
2526 | ;; | |
57119aa9 | 2527 | m68k-*-linux*) # Motorola m68k's running GNU/Linux |
61536478 JL |
2528 | # with ELF format using glibc 2 |
2529 | # aka the GNU/Linux C library 6. | |
2530 | xmake_file=x-linux | |
46f18e7b RK |
2531 | tm_file=m68k/linux.h |
2532 | tmake_file="t-linux m68k/t-linux" | |
2533 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" | |
46f18e7b | 2534 | extra_headers=math-68881.h |
c8db55b0 | 2535 | float_format=m68k |
46f18e7b | 2536 | gnu_ld=yes |
75bffa71 | 2537 | if test x$enable_threads = xyes; then |
95fd3981 RK |
2538 | thread_file='posix' |
2539 | fi | |
46f18e7b RK |
2540 | ;; |
2541 | m68k-*-psos*) | |
2542 | tmake_file=m68k/t-m68kbare | |
2543 | tm_file=m68k/m68k-psos.h | |
2544 | extra_headers=math-68881.h | |
c8db55b0 | 2545 | float_format=m68k |
46f18e7b | 2546 | ;; |
6e5138f0 | 2547 | m68k-*-rtemscoff*) |
46f18e7b RK |
2548 | tmake_file="m68k/t-m68kbare t-rtems" |
2549 | tm_file=m68k/rtems.h | |
2550 | extra_headers=math-68881.h | |
c8db55b0 | 2551 | float_format=m68k |
46f18e7b | 2552 | ;; |
6e5138f0 | 2553 | m68k-*-rtemself*|m68k-*-rtems*) |
d1476635 JS |
2554 | tmake_file="m68k/t-m68kbare t-rtems m68k/t-crtstuff" |
2555 | tm_file=m68k/rtemself.h | |
2556 | extra_headers=math-68881.h | |
2557 | float_format=m68k | |
2558 | ;; | |
46f18e7b RK |
2559 | m88k-dg-dgux*) |
2560 | case $machine in | |
2561 | m88k-dg-dguxbcs*) | |
2562 | tm_file=m88k/dguxbcs.h | |
2563 | tmake_file=m88k/t-dguxbcs | |
2564 | ;; | |
2565 | *) | |
2566 | tm_file=m88k/dgux.h | |
2567 | tmake_file=m88k/t-dgux | |
2568 | ;; | |
2569 | esac | |
2570 | extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld" | |
46f18e7b | 2571 | xmake_file=m88k/x-dgux |
75bffa71 | 2572 | if test x$gas = xyes |
46f18e7b RK |
2573 | then |
2574 | tmake_file=m88k/t-dgux-gas | |
2575 | fi | |
46f18e7b RK |
2576 | ;; |
2577 | m88k-dolphin-sysv3*) | |
2578 | tm_file=m88k/dolph.h | |
2579 | extra_parts="crtbegin.o crtend.o" | |
61536478 | 2580 | xm_file="m88k/xm-sysv3.h ${xm_file}" |
46f18e7b | 2581 | xmake_file=m88k/x-dolph |
75bffa71 | 2582 | if test x$gas = xyes |
46f18e7b RK |
2583 | then |
2584 | tmake_file=m88k/t-m88k-gas | |
2585 | fi | |
2586 | ;; | |
2587 | m88k-tektronix-sysv3) | |
2588 | tm_file=m88k/tekXD88.h | |
2589 | extra_parts="crtbegin.o crtend.o" | |
61536478 | 2590 | xm_file="m88k/xm-sysv3.h ${xm_file}" |
46f18e7b | 2591 | xmake_file=m88k/x-tekXD88 |
75bffa71 | 2592 | if test x$gas = xyes |
46f18e7b RK |
2593 | then |
2594 | tmake_file=m88k/t-m88k-gas | |
2595 | fi | |
2596 | ;; | |
2597 | m88k-*-aout*) | |
2598 | tm_file=m88k/m88k-aout.h | |
2599 | ;; | |
2600 | m88k-*-coff*) | |
2601 | tm_file=m88k/m88k-coff.h | |
2602 | tmake_file=m88k/t-bug | |
2603 | ;; | |
2604 | m88k-*-luna*) | |
2605 | tm_file=m88k/luna.h | |
2606 | extra_parts="crtbegin.o crtend.o" | |
75bffa71 | 2607 | if test x$gas = xyes |
46f18e7b RK |
2608 | then |
2609 | tmake_file=m88k/t-luna-gas | |
2610 | else | |
2611 | tmake_file=m88k/t-luna | |
2612 | fi | |
2613 | ;; | |
1b4a979b ME |
2614 | m88k-*-openbsd*) |
2615 | tmake_file="${tmake_file} m88k/t-luna-gas" | |
891a3cfe JL |
2616 | tm_file="m88k/aout-dbx.h aoutos.h m88k/m88k.h openbsd.h ${tm_file}" |
2617 | xm_file="xm-openbsd.h m88k/xm-m88k.h ${xm_file}" | |
1b4a979b | 2618 | ;; |
46f18e7b RK |
2619 | m88k-*-sysv3*) |
2620 | tm_file=m88k/sysv3.h | |
2621 | extra_parts="crtbegin.o crtend.o" | |
61536478 | 2622 | xm_file="m88k/xm-sysv3.h ${xm_file}" |
46f18e7b | 2623 | xmake_file=m88k/x-sysv3 |
75bffa71 | 2624 | if test x$gas = xyes |
46f18e7b RK |
2625 | then |
2626 | tmake_file=m88k/t-m88k-gas | |
2627 | fi | |
2628 | ;; | |
2629 | m88k-*-sysv4*) | |
2630 | tm_file=m88k/sysv4.h | |
2631 | extra_parts="crtbegin.o crtend.o" | |
2632 | xmake_file=m88k/x-sysv4 | |
2633 | tmake_file=m88k/t-sysv4 | |
2634 | ;; | |
789a3090 NC |
2635 | mcore-*-elf) |
2636 | tm_file=mcore/mcore-elf.h | |
2637 | tmake_file=mcore/t-mcore | |
2638 | ;; | |
2639 | mcore-*-pe*) | |
2640 | tm_file=mcore/mcore-pe.h | |
2641 | tmake_file=mcore/t-mcore-pe | |
2642 | ;; | |
46f18e7b | 2643 | mips-sgi-irix6*) # SGI System V.4., IRIX 6 |
05476613 MM |
2644 | if test "x$gnu_ld" = xyes |
2645 | then | |
2646 | tm_file="mips/iris6.h mips/iris6gld.h" | |
05476613 MM |
2647 | else |
2648 | tm_file=mips/iris6.h | |
05476613 | 2649 | fi |
e3f5cc86 | 2650 | tmake_file=mips/t-iris6 |
46f18e7b | 2651 | xm_file=mips/xm-iris6.h |
46f18e7b | 2652 | xmake_file=mips/x-iris6 |
04069e5c | 2653 | # if test x$enable_threads = xyes; then |
6e148807 | 2654 | # thread_file='irix' |
04069e5c | 2655 | # fi |
46f18e7b | 2656 | ;; |
98bd9f0f | 2657 | mips-wrs-vxworks) |
7aae67a2 | 2658 | tm_file="mips/elf.h mips/vxworks.h" |
98bd9f0f DB |
2659 | tmake_file=mips/t-ecoff |
2660 | gas=yes | |
2661 | gnu_ld=yes | |
2662 | extra_parts="crtbegin.o crtend.o" | |
e9c0315e | 2663 | thread_file='vxworks' |
98bd9f0f | 2664 | ;; |
46f18e7b | 2665 | mips-sgi-irix5cross64) # Irix5 host, Irix 6 target, cross64 |
61536478 | 2666 | tm_file="mips/iris6.h mips/cross64.h" |
74c55ab0 JW |
2667 | xm_defines=USG |
2668 | xm_file="mips/xm-iris5.h" | |
46f18e7b RK |
2669 | xmake_file=mips/x-iris |
2670 | tmake_file=mips/t-cross64 | |
2671 | # See comment in mips/iris[56].h files. | |
2672 | use_collect2=yes | |
04069e5c | 2673 | # if test x$enable_threads = xyes; then |
6e148807 | 2674 | # thread_file='irix' |
04069e5c | 2675 | # fi |
46f18e7b RK |
2676 | ;; |
2677 | mips-sni-sysv4) | |
75bffa71 | 2678 | if test x$gas = xyes |
46f18e7b | 2679 | then |
75bffa71 | 2680 | if test x$stabs = xyes |
46f18e7b RK |
2681 | then |
2682 | tm_file=mips/iris5gdb.h | |
2683 | else | |
61536478 | 2684 | tm_file="mips/sni-svr4.h mips/sni-gas.h" |
46f18e7b RK |
2685 | fi |
2686 | else | |
2687 | tm_file=mips/sni-svr4.h | |
2688 | fi | |
61536478 | 2689 | xm_defines=USG |
46f18e7b RK |
2690 | xmake_file=mips/x-sni-svr4 |
2691 | tmake_file=mips/t-mips-gas | |
75bffa71 | 2692 | if test x$gnu_ld != xyes |
46f18e7b RK |
2693 | then |
2694 | use_collect2=yes | |
2695 | fi | |
46f18e7b RK |
2696 | ;; |
2697 | mips-sgi-irix5*) # SGI System V.4., IRIX 5 | |
75bffa71 | 2698 | if test x$gas = xyes |
46f18e7b | 2699 | then |
61536478 | 2700 | tm_file="mips/iris5.h mips/iris5gas.h" |
75bffa71 | 2701 | if test x$stabs = xyes |
46f18e7b RK |
2702 | then |
2703 | tm_file="${tm_file} dbx.h" | |
2704 | fi | |
2705 | else | |
2706 | tm_file=mips/iris5.h | |
2707 | fi | |
74c55ab0 JW |
2708 | xm_defines=USG |
2709 | xm_file="mips/xm-iris5.h" | |
46f18e7b RK |
2710 | xmake_file=mips/x-iris |
2711 | # mips-tfile doesn't work yet | |
2712 | tmake_file=mips/t-mips-gas | |
2713 | # See comment in mips/iris5.h file. | |
2714 | use_collect2=yes | |
04069e5c | 2715 | # if test x$enable_threads = xyes; then |
6e148807 | 2716 | # thread_file='irix' |
04069e5c | 2717 | # fi |
46f18e7b RK |
2718 | ;; |
2719 | mips-sgi-irix4loser*) # Mostly like a MIPS. | |
61536478 | 2720 | tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h" |
75bffa71 | 2721 | if test x$stabs = xyes; then |
46f18e7b RK |
2722 | tm_file="${tm_file} dbx.h" |
2723 | fi | |
61536478 | 2724 | xm_defines=USG |
46f18e7b | 2725 | xmake_file=mips/x-iris |
75bffa71 | 2726 | if test x$gas = xyes |
46f18e7b RK |
2727 | then |
2728 | tmake_file=mips/t-mips-gas | |
2729 | else | |
2730 | extra_passes="mips-tfile mips-tdump" | |
2731 | fi | |
75bffa71 | 2732 | if test x$gnu_ld != xyes |
46f18e7b RK |
2733 | then |
2734 | use_collect2=yes | |
2735 | fi | |
04069e5c | 2736 | # if test x$enable_threads = xyes; then |
6e148807 | 2737 | # thread_file='irix' |
04069e5c | 2738 | # fi |
46f18e7b RK |
2739 | ;; |
2740 | mips-sgi-irix4*) # Mostly like a MIPS. | |
61536478 | 2741 | tm_file="mips/iris3.h ${tm_file} mips/iris4.h" |
75bffa71 | 2742 | if test x$stabs = xyes; then |
46f18e7b RK |
2743 | tm_file="${tm_file} dbx.h" |
2744 | fi | |
61536478 | 2745 | xm_defines=USG |
46f18e7b | 2746 | xmake_file=mips/x-iris |
75bffa71 | 2747 | if test x$gas = xyes |
46f18e7b RK |
2748 | then |
2749 | tmake_file=mips/t-mips-gas | |
2750 | else | |
2751 | extra_passes="mips-tfile mips-tdump" | |
2752 | fi | |
75bffa71 | 2753 | if test x$gnu_ld != xyes |
46f18e7b RK |
2754 | then |
2755 | use_collect2=yes | |
2756 | fi | |
04069e5c | 2757 | # if test x$enable_threads = xyes; then |
6e148807 | 2758 | # thread_file='irix' |
04069e5c | 2759 | # fi |
46f18e7b RK |
2760 | ;; |
2761 | mips-sgi-*) # Mostly like a MIPS. | |
61536478 | 2762 | tm_file="mips/iris3.h ${tm_file}" |
75bffa71 | 2763 | if test x$stabs = xyes; then |
46f18e7b RK |
2764 | tm_file="${tm_file} dbx.h" |
2765 | fi | |
61536478 | 2766 | xm_defines=USG |
46f18e7b | 2767 | xmake_file=mips/x-iris3 |
75bffa71 | 2768 | if test x$gas = xyes |
46f18e7b RK |
2769 | then |
2770 | tmake_file=mips/t-mips-gas | |
2771 | else | |
2772 | extra_passes="mips-tfile mips-tdump" | |
2773 | fi | |
75bffa71 | 2774 | if test x$gnu_ld != xyes |
46f18e7b RK |
2775 | then |
2776 | use_collect2=yes | |
2777 | fi | |
2778 | ;; | |
2779 | mips-dec-osfrose*) # Decstation running OSF/1 reference port with OSF/rose. | |
61536478 | 2780 | tm_file="mips/osfrose.h ${tm_file}" |
46f18e7b RK |
2781 | xmake_file=mips/x-osfrose |
2782 | tmake_file=mips/t-osfrose | |
2783 | extra_objs=halfpic.o | |
2784 | use_collect2=yes | |
2785 | ;; | |
2786 | mips-dec-osf*) # Decstation running OSF/1 as shipped by DIGITAL | |
2787 | tm_file=mips/dec-osf1.h | |
75bffa71 | 2788 | if test x$stabs = xyes; then |
46f18e7b RK |
2789 | tm_file="${tm_file} dbx.h" |
2790 | fi | |
2791 | xmake_file=mips/x-dec-osf1 | |
75bffa71 | 2792 | if test x$gas = xyes |
46f18e7b RK |
2793 | then |
2794 | tmake_file=mips/t-mips-gas | |
2795 | else | |
2796 | tmake_file=mips/t-ultrix | |
2797 | extra_passes="mips-tfile mips-tdump" | |
2798 | fi | |
75bffa71 | 2799 | if test x$gnu_ld != xyes |
46f18e7b RK |
2800 | then |
2801 | use_collect2=yes | |
2802 | fi | |
2803 | ;; | |
2804 | mips-dec-bsd*) # Decstation running 4.4 BSD | |
2805 | tm_file=mips/dec-bsd.h | |
75bffa71 | 2806 | if test x$gas = xyes |
46f18e7b RK |
2807 | then |
2808 | tmake_file=mips/t-mips-gas | |
2809 | else | |
2810 | tmake_file=mips/t-ultrix | |
2811 | extra_passes="mips-tfile mips-tdump" | |
2812 | fi | |
75bffa71 | 2813 | if test x$gnu_ld != xyes |
46f18e7b RK |
2814 | then |
2815 | use_collect2=yes | |
2816 | fi | |
2817 | ;; | |
58600d24 | 2818 | mipsel-*-netbsd* | mips-dec-netbsd*) # Decstation running NetBSD |
46f18e7b | 2819 | tm_file=mips/netbsd.h |
be1ed94f | 2820 | # On NetBSD, the headers are already okay, except for math.h. |
e47f44f4 | 2821 | tmake_file=t-netbsd |
46f18e7b | 2822 | ;; |
6ed6b84a | 2823 | mips*-*-linux*) # Linux MIPS, either endian. |
18cae839 | 2824 | xmake_file=x-linux |
6ed6b84a AJ |
2825 | case $machine in |
2826 | mips*el-*) tm_file="mips/elfl.h mips/linux.h" ;; | |
2827 | *) tm_file="mips/elf.h mips/linux.h" ;; | |
2828 | esac | |
2829 | tmake_file=t-linux | |
e86e6730 | 2830 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" |
18cae839 RL |
2831 | gnu_ld=yes |
2832 | gas=yes | |
6ed6b84a AJ |
2833 | if test x$enable_threads = xyes; then |
2834 | thread_file='posix' | |
2835 | fi | |
18cae839 | 2836 | ;; |
1b4a979b ME |
2837 | mips*el-*-openbsd*) # mips little endian |
2838 | target_cpu_default="MASK_GAS|MASK_ABICALLS" | |
1b4a979b ME |
2839 | ;; |
2840 | mips*-*-openbsd*) # mips big endian | |
2841 | target_cpu_default="MASK_GAS|MASK_ABICALLS" | |
9e28024a | 2842 | tm_file="mips/openbsd-be.h ${tm_file}" |
1b4a979b | 2843 | ;; |
46f18e7b | 2844 | mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news. |
61536478 | 2845 | tm_file="mips/news4.h ${tm_file}" |
75bffa71 | 2846 | if test x$stabs = xyes; then |
46f18e7b RK |
2847 | tm_file="${tm_file} dbx.h" |
2848 | fi | |
75bffa71 | 2849 | if test x$gas = xyes |
46f18e7b RK |
2850 | then |
2851 | tmake_file=mips/t-mips-gas | |
2852 | else | |
2853 | extra_passes="mips-tfile mips-tdump" | |
2854 | fi | |
75bffa71 | 2855 | if test x$gnu_ld != xyes |
46f18e7b RK |
2856 | then |
2857 | use_collect2=yes | |
2858 | fi | |
2859 | xmake_file=mips/x-sony | |
2860 | ;; | |
2861 | mips-sony-sysv*) # Sony NEWS 3800 with NEWSOS5.0. | |
2862 | # That is based on svr4. | |
2863 | # t-svr4 is not right because this system doesn't use ELF. | |
61536478 | 2864 | tm_file="mips/news5.h ${tm_file}" |
75bffa71 | 2865 | if test x$stabs = xyes; then |
46f18e7b RK |
2866 | tm_file="${tm_file} dbx.h" |
2867 | fi | |
61536478 | 2868 | xm_defines=USG |
75bffa71 | 2869 | if test x$gas = xyes |
46f18e7b RK |
2870 | then |
2871 | tmake_file=mips/t-mips-gas | |
2872 | else | |
2873 | extra_passes="mips-tfile mips-tdump" | |
2874 | fi | |
75bffa71 | 2875 | if test x$gnu_ld != xyes |
46f18e7b RK |
2876 | then |
2877 | use_collect2=yes | |
2878 | fi | |
2879 | ;; | |
2880 | mips-tandem-sysv4*) # Tandem S2 running NonStop UX | |
61536478 | 2881 | tm_file="mips/svr4-5.h mips/svr4-t.h" |
75bffa71 | 2882 | if test x$stabs = xyes; then |
46f18e7b RK |
2883 | tm_file="${tm_file} dbx.h" |
2884 | fi | |
61536478 | 2885 | xm_defines=USG |
46f18e7b | 2886 | xmake_file=mips/x-sysv |
75bffa71 | 2887 | if test x$gas = xyes |
46f18e7b RK |
2888 | then |
2889 | tmake_file=mips/t-mips-gas | |
2890 | extra_parts="crtbegin.o crtend.o" | |
2891 | else | |
2892 | tmake_file=mips/t-mips | |
2893 | extra_passes="mips-tfile mips-tdump" | |
2894 | fi | |
75bffa71 | 2895 | if test x$gnu_ld != xyes |
46f18e7b RK |
2896 | then |
2897 | use_collect2=yes | |
2898 | fi | |
46f18e7b RK |
2899 | ;; |
2900 | mips-*-ultrix* | mips-dec-mach3) # Decstation. | |
61536478 | 2901 | tm_file="mips/ultrix.h ${tm_file}" |
75bffa71 | 2902 | if test x$stabs = xyes; then |
46f18e7b RK |
2903 | tm_file="${tm_file} dbx.h" |
2904 | fi | |
2905 | xmake_file=mips/x-ultrix | |
75bffa71 | 2906 | if test x$gas = xyes |
46f18e7b RK |
2907 | then |
2908 | tmake_file=mips/t-mips-gas | |
2909 | else | |
2910 | tmake_file=mips/t-ultrix | |
2911 | extra_passes="mips-tfile mips-tdump" | |
2912 | fi | |
75bffa71 | 2913 | if test x$gnu_ld != xyes |
46f18e7b RK |
2914 | then |
2915 | use_collect2=yes | |
2916 | fi | |
2917 | ;; | |
75bffa71 ILT |
2918 | changequote(,)dnl |
2919 | mips-*-riscos[56789]bsd*) | |
2920 | changequote([,])dnl | |
46f18e7b | 2921 | tm_file=mips/bsd-5.h # MIPS BSD 4.3, RISC-OS 5.0 |
75bffa71 | 2922 | if test x$stabs = xyes; then |
46f18e7b RK |
2923 | tm_file="${tm_file} dbx.h" |
2924 | fi | |
75bffa71 | 2925 | if test x$gas = xyes |
46f18e7b RK |
2926 | then |
2927 | tmake_file=mips/t-bsd-gas | |
2928 | else | |
2929 | tmake_file=mips/t-bsd | |
2930 | extra_passes="mips-tfile mips-tdump" | |
2931 | fi | |
75bffa71 | 2932 | if test x$gnu_ld != xyes |
46f18e7b RK |
2933 | then |
2934 | use_collect2=yes | |
2935 | fi | |
46f18e7b | 2936 | ;; |
75bffa71 ILT |
2937 | changequote(,)dnl |
2938 | mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[1234]bsd*) | |
2939 | changequote([,])dnl | |
61536478 | 2940 | tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0 |
75bffa71 | 2941 | if test x$stabs = xyes; then |
46f18e7b RK |
2942 | tm_file="${tm_file} dbx.h" |
2943 | fi | |
75bffa71 | 2944 | if test x$gas = xyes |
46f18e7b RK |
2945 | then |
2946 | tmake_file=mips/t-bsd-gas | |
2947 | else | |
2948 | tmake_file=mips/t-bsd | |
2949 | extra_passes="mips-tfile mips-tdump" | |
2950 | fi | |
75bffa71 | 2951 | if test x$gnu_ld != xyes |
46f18e7b RK |
2952 | then |
2953 | use_collect2=yes | |
2954 | fi | |
46f18e7b | 2955 | ;; |
75bffa71 ILT |
2956 | changequote(,)dnl |
2957 | mips-*-riscos[56789]sysv4*) | |
2958 | changequote([,])dnl | |
46f18e7b | 2959 | tm_file=mips/svr4-5.h # MIPS System V.4., RISC-OS 5.0 |
75bffa71 | 2960 | if test x$stabs = xyes; then |
46f18e7b RK |
2961 | tm_file="${tm_file} dbx.h" |
2962 | fi | |
46f18e7b | 2963 | xmake_file=mips/x-sysv |
75bffa71 | 2964 | if test x$gas = xyes |
46f18e7b RK |
2965 | then |
2966 | tmake_file=mips/t-svr4-gas | |
2967 | else | |
2968 | tmake_file=mips/t-svr4 | |
2969 | extra_passes="mips-tfile mips-tdump" | |
2970 | fi | |
75bffa71 | 2971 | if test x$gnu_ld != xyes |
46f18e7b RK |
2972 | then |
2973 | use_collect2=yes | |
2974 | fi | |
46f18e7b | 2975 | ;; |
75bffa71 ILT |
2976 | changequote(,)dnl |
2977 | mips-*-sysv4* | mips-*-riscos[1234]sysv4* | mips-*-riscossysv4*) | |
2978 | changequote([,])dnl | |
61536478 | 2979 | tm_file="mips/svr4-4.h ${tm_file}" |
75bffa71 | 2980 | if test x$stabs = xyes; then |
46f18e7b RK |
2981 | tm_file="${tm_file} dbx.h" |
2982 | fi | |
61536478 | 2983 | xm_defines=USG |
46f18e7b | 2984 | xmake_file=mips/x-sysv |
75bffa71 | 2985 | if test x$gas = xyes |
46f18e7b RK |
2986 | then |
2987 | tmake_file=mips/t-svr4-gas | |
2988 | else | |
2989 | tmake_file=mips/t-svr4 | |
2990 | extra_passes="mips-tfile mips-tdump" | |
2991 | fi | |
75bffa71 | 2992 | if test x$gnu_ld != xyes |
46f18e7b RK |
2993 | then |
2994 | use_collect2=yes | |
2995 | fi | |
46f18e7b | 2996 | ;; |
75bffa71 ILT |
2997 | changequote(,)dnl |
2998 | mips-*-riscos[56789]sysv*) | |
2999 | changequote([,])dnl | |
46f18e7b | 3000 | tm_file=mips/svr3-5.h # MIPS System V.3, RISC-OS 5.0 |
75bffa71 | 3001 | if test x$stabs = xyes; then |
46f18e7b RK |
3002 | tm_file="${tm_file} dbx.h" |
3003 | fi | |
61536478 | 3004 | xm_defines=USG |
46f18e7b | 3005 | xmake_file=mips/x-sysv |
75bffa71 | 3006 | if test x$gas = xyes |
46f18e7b RK |
3007 | then |
3008 | tmake_file=mips/t-svr3-gas | |
3009 | else | |
3010 | tmake_file=mips/t-svr3 | |
3011 | extra_passes="mips-tfile mips-tdump" | |
3012 | fi | |
75bffa71 | 3013 | if test x$gnu_ld != xyes |
46f18e7b RK |
3014 | then |
3015 | use_collect2=yes | |
3016 | fi | |
46f18e7b RK |
3017 | ;; |
3018 | mips-*-sysv* | mips-*-riscos*sysv*) | |
61536478 | 3019 | tm_file="mips/svr3-4.h ${tm_file}" |
75bffa71 | 3020 | if test x$stabs = xyes; then |
46f18e7b RK |
3021 | tm_file="${tm_file} dbx.h" |
3022 | fi | |
61536478 | 3023 | xm_defines=USG |
46f18e7b | 3024 | xmake_file=mips/x-sysv |
75bffa71 | 3025 | if test x$gas = xyes |
46f18e7b RK |
3026 | then |
3027 | tmake_file=mips/t-svr3-gas | |
3028 | else | |
3029 | tmake_file=mips/t-svr3 | |
3030 | extra_passes="mips-tfile mips-tdump" | |
3031 | fi | |
75bffa71 | 3032 | if test x$gnu_ld != xyes |
46f18e7b RK |
3033 | then |
3034 | use_collect2=yes | |
3035 | fi | |
46f18e7b | 3036 | ;; |
75bffa71 ILT |
3037 | changequote(,)dnl |
3038 | mips-*-riscos[56789]*) # Default MIPS RISC-OS 5.0. | |
3039 | changequote([,])dnl | |
46f18e7b | 3040 | tm_file=mips/mips-5.h |
75bffa71 | 3041 | if test x$stabs = xyes; then |
46f18e7b RK |
3042 | tm_file="${tm_file} dbx.h" |
3043 | fi | |
75bffa71 | 3044 | if test x$gas = xyes |
46f18e7b RK |
3045 | then |
3046 | tmake_file=mips/t-mips-gas | |
3047 | else | |
3048 | extra_passes="mips-tfile mips-tdump" | |
3049 | fi | |
75bffa71 | 3050 | if test x$gnu_ld != xyes |
46f18e7b RK |
3051 | then |
3052 | use_collect2=yes | |
3053 | fi | |
46f18e7b RK |
3054 | ;; |
3055 | mips-*-gnu*) | |
3056 | ;; | |
3057 | mipsel-*-ecoff*) | |
3058 | tm_file=mips/ecoffl.h | |
75bffa71 | 3059 | if test x$stabs = xyes; then |
46f18e7b RK |
3060 | tm_file="${tm_file} dbx.h" |
3061 | fi | |
3062 | tmake_file=mips/t-ecoff | |
3063 | ;; | |
3064 | mips-*-ecoff*) | |
1be12a4a | 3065 | tm_file="gofast.h mips/ecoff.h" |
75bffa71 | 3066 | if test x$stabs = xyes; then |
46f18e7b RK |
3067 | tm_file="${tm_file} dbx.h" |
3068 | fi | |
3069 | tmake_file=mips/t-ecoff | |
46f18e7b RK |
3070 | ;; |
3071 | mipsel-*-elf*) | |
7aae67a2 | 3072 | tm_file="mips/elfl.h" |
d8265d29 | 3073 | tmake_file=mips/t-elf |
46f18e7b RK |
3074 | ;; |
3075 | mips-*-elf*) | |
d8265d29 CM |
3076 | tm_file="mips/elf.h" |
3077 | tmake_file=mips/t-elf | |
46f18e7b RK |
3078 | ;; |
3079 | mips64el-*-elf*) | |
d8265d29 CM |
3080 | tm_file="mips/elfl64.h" |
3081 | tmake_file=mips/t-elf | |
46f18e7b RK |
3082 | ;; |
3083 | mips64orionel-*-elf*) | |
7aae67a2 | 3084 | tm_file="mips/elforion.h mips/elfl64.h" |
d8265d29 | 3085 | tmake_file=mips/t-elf |
46f18e7b RK |
3086 | ;; |
3087 | mips64-*-elf*) | |
d8265d29 CM |
3088 | tm_file="mips/elf64.h" |
3089 | tmake_file=mips/t-elf | |
46f18e7b RK |
3090 | ;; |
3091 | mips64orion-*-elf*) | |
7aae67a2 | 3092 | tm_file="mips/elforion.h mips/elf64.h" |
d8265d29 | 3093 | tmake_file=mips/t-elf |
46f18e7b RK |
3094 | ;; |
3095 | mips64orion-*-rtems*) | |
6e9856ba | 3096 | tm_file="mips/elforion.h mips/elf64.h mips/rtems64.h" |
d1476635 | 3097 | tmake_file="mips/t-elf t-rtems" |
46f18e7b | 3098 | ;; |
e9a25f70 | 3099 | mipstx39el-*-elf*) |
d8265d29 | 3100 | tm_file="mips/r3900.h mips/elfl.h mips/abi64.h" |
09e4daf5 | 3101 | tmake_file=mips/t-r3900 |
e9a25f70 JL |
3102 | ;; |
3103 | mipstx39-*-elf*) | |
d8265d29 | 3104 | tm_file="mips/r3900.h mips/elf.h mips/abi64.h" |
09e4daf5 | 3105 | tmake_file=mips/t-r3900 |
e9a25f70 | 3106 | ;; |
46f18e7b | 3107 | mips-*-*) # Default MIPS RISC-OS 4.0. |
75bffa71 | 3108 | if test x$stabs = xyes; then |
46f18e7b RK |
3109 | tm_file="${tm_file} dbx.h" |
3110 | fi | |
75bffa71 | 3111 | if test x$gas = xyes |
46f18e7b RK |
3112 | then |
3113 | tmake_file=mips/t-mips-gas | |
3114 | else | |
3115 | extra_passes="mips-tfile mips-tdump" | |
3116 | fi | |
75bffa71 | 3117 | if test x$gnu_ld != xyes |
46f18e7b RK |
3118 | then |
3119 | use_collect2=yes | |
3120 | fi | |
3121 | ;; | |
cef64ec4 | 3122 | mn10200-*-*) |
5e3c02a8 | 3123 | float_format=i32 |
cef64ec4 RK |
3124 | cpu_type=mn10200 |
3125 | tm_file="mn10200/mn10200.h" | |
75bffa71 | 3126 | if test x$stabs = xyes |
cef64ec4 RK |
3127 | then |
3128 | tm_file="${tm_file} dbx.h" | |
3129 | fi | |
3130 | use_collect2=no | |
3131 | ;; | |
46f18e7b RK |
3132 | mn10300-*-*) |
3133 | cpu_type=mn10300 | |
3134 | tm_file="mn10300/mn10300.h" | |
75bffa71 | 3135 | if test x$stabs = xyes |
46f18e7b RK |
3136 | then |
3137 | tm_file="${tm_file} dbx.h" | |
3138 | fi | |
3139 | use_collect2=no | |
3140 | ;; | |
3141 | ns32k-encore-bsd*) | |
3142 | tm_file=ns32k/encore.h | |
3143 | use_collect2=yes | |
3144 | ;; | |
3145 | ns32k-sequent-bsd*) | |
3146 | tm_file=ns32k/sequent.h | |
3147 | use_collect2=yes | |
3148 | ;; | |
3149 | ns32k-tek6100-bsd*) | |
3150 | tm_file=ns32k/tek6100.h | |
46f18e7b RK |
3151 | use_collect2=yes |
3152 | ;; | |
3153 | ns32k-tek6200-bsd*) | |
3154 | tm_file=ns32k/tek6200.h | |
46f18e7b RK |
3155 | use_collect2=yes |
3156 | ;; | |
46f18e7b RK |
3157 | ns32k-merlin-*) |
3158 | tm_file=ns32k/merlin.h | |
3159 | use_collect2=yes | |
3160 | ;; | |
3161 | ns32k-pc532-mach*) | |
3162 | tm_file=ns32k/pc532-mach.h | |
3163 | use_collect2=yes | |
3164 | ;; | |
3165 | ns32k-pc532-minix*) | |
3166 | tm_file=ns32k/pc532-min.h | |
61536478 JL |
3167 | xm_file="ns32k/xm-pc532-min.h ${xm-file}" |
3168 | xm_defines=USG | |
46f18e7b RK |
3169 | use_collect2=yes |
3170 | ;; | |
58600d24 | 3171 | ns32k-*-netbsd*) |
46f18e7b | 3172 | tm_file=ns32k/netbsd.h |
641d4216 | 3173 | xm_file="ns32k/xm-netbsd.h ${xm_file}" |
be1ed94f | 3174 | # On NetBSD, the headers are already okay, except for math.h. |
e47f44f4 | 3175 | tmake_file=t-netbsd |
ed4acb3b | 3176 | use_collect2=yes |
46f18e7b RK |
3177 | ;; |
3178 | pdp11-*-bsd) | |
3179 | tm_file="${tm_file} pdp11/2bsd.h" | |
3180 | ;; | |
3181 | pdp11-*-*) | |
3182 | ;; | |
d48120fe DC |
3183 | avr-*-*) |
3184 | ;; | |
1b4a979b ME |
3185 | ns32k-*-openbsd*) |
3186 | # Nothing special | |
3187 | ;; | |
1b992148 SC |
3188 | pj*-linux*) |
3189 | tm_file="svr4.h pj/linux.h ${tm_file}" | |
3190 | ;; | |
3191 | pj-*) | |
3192 | ;; | |
3193 | pjl-*) | |
3194 | tm_file="svr4.h pj/pjl.h ${tm_file}" | |
3195 | ;; | |
3196 | ||
46f18e7b RK |
3197 | romp-*-aos*) |
3198 | use_collect2=yes | |
3199 | ;; | |
3200 | romp-*-mach*) | |
3201 | xmake_file=romp/x-mach | |
3202 | use_collect2=yes | |
3203 | ;; | |
1b4a979b ME |
3204 | romp-*-openbsd*) |
3205 | # Nothing special | |
3206 | ;; | |
3207 | powerpc-*-openbsd*) | |
3208 | tmake_file="${tmake_file} rs6000/t-rs6000 rs6000/t-openbsd" | |
1b4a979b | 3209 | ;; |
c55dcc7d FF |
3210 | powerpc-*-beos*) |
3211 | cpu_type=rs6000 | |
3212 | tm_file=rs6000/beos.h | |
3213 | xm_file=rs6000/xm-beos.h | |
3214 | tmake_file=rs6000/t-beos | |
3215 | xmake_file=rs6000/x-beos | |
3216 | ;; | |
b26e3a82 | 3217 | powerpc-*-sysv*) |
46f18e7b | 3218 | tm_file=rs6000/sysv4.h |
2d092ffa | 3219 | xm_file="rs6000/xm-sysv4.h" |
61536478 | 3220 | xm_defines="USG POSIX" |
46f18e7b | 3221 | extra_headers=ppc-asm.h |
b26e3a82 | 3222 | tmake_file="rs6000/t-ppcos rs6000/t-ppccomm" |
46f18e7b RK |
3223 | xmake_file=rs6000/x-sysv4 |
3224 | ;; | |
3225 | powerpc-*-eabiaix*) | |
b26e3a82 | 3226 | tm_file="rs6000/sysv4.h rs6000/eabi.h rs6000/eabiaix.h" |
46f18e7b | 3227 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" |
46f18e7b RK |
3228 | extra_headers=ppc-asm.h |
3229 | ;; | |
3230 | powerpc-*-eabisim*) | |
b26e3a82 GK |
3231 | tm_file="rs6000/sysv4.h rs6000/eabi.h rs6000/eabisim.h" |
3232 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" | |
3233 | extra_headers=ppc-asm.h | |
3234 | ;; | |
3235 | powerpc-*-elf*) | |
3236 | tm_file="rs6000/sysv4.h" | |
46f18e7b | 3237 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" |
46f18e7b RK |
3238 | extra_headers=ppc-asm.h |
3239 | ;; | |
3240 | powerpc-*-eabi*) | |
b26e3a82 GK |
3241 | tm_file="rs6000/sysv4.h rs6000/eabi.h" |
3242 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" | |
46f18e7b RK |
3243 | extra_headers=ppc-asm.h |
3244 | ;; | |
dec3e070 | 3245 | powerpc-*-rtems*) |
b26e3a82 GK |
3246 | tm_file="rs6000/sysv4.h rs6000/eabi.h rs6000/rtems.h" |
3247 | tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm" | |
46f18e7b RK |
3248 | extra_headers=ppc-asm.h |
3249 | ;; | |
57119aa9 | 3250 | powerpc-*-linux*libc1) |
b26e3a82 | 3251 | tm_file="rs6000/sysv4.h rs6000/linux.h" |
ce514f57 FS |
3252 | xm_file=rs6000/xm-sysv4.h |
3253 | out_file=rs6000/rs6000.c | |
b26e3a82 | 3254 | tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm" |
ce514f57 | 3255 | xmake_file=x-linux |
ce514f57 | 3256 | extra_headers=ppc-asm.h |
75bffa71 | 3257 | if test x$enable_threads = xyes; then |
ce514f57 FS |
3258 | thread_file='posix' |
3259 | fi | |
3260 | ;; | |
57119aa9 | 3261 | powerpc-*-linux*) |
b26e3a82 | 3262 | tm_file="rs6000/sysv4.h rs6000/linux.h" |
2d092ffa | 3263 | xm_file="rs6000/xm-sysv4.h" |
61536478 | 3264 | xm_defines="USG ${xm_defines}" |
dec3e070 | 3265 | out_file=rs6000/rs6000.c |
b26e3a82 | 3266 | tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm" |
d7308c0c | 3267 | xmake_file=x-linux |
46f18e7b | 3268 | extra_headers=ppc-asm.h |
75bffa71 | 3269 | if test x$enable_threads = xyes; then |
d7308c0c RK |
3270 | thread_file='posix' |
3271 | fi | |
46f18e7b | 3272 | ;; |
7cc34889 | 3273 | powerpc-wrs-vxworks*) |
46f18e7b | 3274 | cpu_type=rs6000 |
2d092ffa | 3275 | xm_file="rs6000/xm-sysv4.h" |
61536478 | 3276 | xm_defines="USG POSIX" |
b26e3a82 | 3277 | tm_file="rs6000/sysv4.h rs6000/vxppc.h" |
46f18e7b RK |
3278 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" |
3279 | extra_headers=ppc-asm.h | |
7cc34889 | 3280 | thread_file='vxworks' |
46f18e7b | 3281 | ;; |
9ebbca7d GK |
3282 | powerpcle-wrs-vxworks*) |
3283 | cpu_type=rs6000 | |
3284 | xm_file="rs6000/xm-sysv4.h" | |
3285 | xm_defines="USG POSIX" | |
b26e3a82 | 3286 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h rs6000/vxppc.h" |
9ebbca7d GK |
3287 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" |
3288 | extra_headers=ppc-asm.h | |
3289 | thread_file='vxworks' | |
3290 | ;; | |
b26e3a82 GK |
3291 | powerpcle-*-sysv*) |
3292 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h" | |
2d092ffa | 3293 | xm_file="rs6000/xm-sysv4.h" |
61536478 | 3294 | xm_defines="USG POSIX" |
b26e3a82 | 3295 | tmake_file="rs6000/t-ppcos rs6000/t-ppccomm" |
46f18e7b RK |
3296 | xmake_file=rs6000/x-sysv4 |
3297 | extra_headers=ppc-asm.h | |
3298 | ;; | |
b26e3a82 GK |
3299 | powerpcle-*-elf*) |
3300 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h" | |
3301 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" | |
3302 | extra_headers=ppc-asm.h | |
3303 | ;; | |
46f18e7b | 3304 | powerpcle-*-eabisim*) |
b26e3a82 | 3305 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/eabisim.h" |
46f18e7b | 3306 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" |
46f18e7b RK |
3307 | extra_headers=ppc-asm.h |
3308 | ;; | |
3309 | powerpcle-*-eabi*) | |
b26e3a82 GK |
3310 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h" |
3311 | tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm" | |
46f18e7b RK |
3312 | extra_headers=ppc-asm.h |
3313 | ;; | |
46f18e7b | 3314 | powerpcle-*-solaris2*) |
b26e3a82 | 3315 | tm_file="rs6000/sysv4.h rs6000/sysv4le.h rs6000/sol2.h" |
2d092ffa | 3316 | xm_file="rs6000/xm-sysv4.h" |
61536478 | 3317 | xm_defines="USG POSIX" |
b26e3a82 | 3318 | tmake_file="rs6000/t-ppcos rs6000/t-ppccomm" |
46f18e7b | 3319 | xmake_file=rs6000/x-sysv4 |
46f18e7b RK |
3320 | extra_headers=ppc-asm.h |
3321 | ;; | |
75bffa71 ILT |
3322 | changequote(,)dnl |
3323 | rs6000-ibm-aix3.[01]*) | |
3324 | changequote([,])dnl | |
46f18e7b RK |
3325 | tm_file=rs6000/aix31.h |
3326 | xmake_file=rs6000/x-aix31 | |
45e24d08 | 3327 | float_format=none |
46f18e7b RK |
3328 | use_collect2=yes |
3329 | ;; | |
75bffa71 ILT |
3330 | changequote(,)dnl |
3331 | rs6000-ibm-aix3.2.[456789]* | powerpc-ibm-aix3.2.[456789]*) | |
3332 | changequote([,])dnl | |
46f18e7b | 3333 | tm_file=rs6000/aix3newas.h |
75bffa71 | 3334 | if test x$host != x$target |
46f18e7b RK |
3335 | then |
3336 | tmake_file=rs6000/t-xnewas | |
3337 | else | |
3338 | tmake_file=rs6000/t-newas | |
3339 | fi | |
45e24d08 | 3340 | float_format=none |
46f18e7b RK |
3341 | use_collect2=yes |
3342 | ;; | |
75bffa71 | 3343 | changequote(,)dnl |
05cea40f | 3344 | rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*) |
75bffa71 | 3345 | changequote([,])dnl |
590e30e7 | 3346 | tm_file=rs6000/aix41.h |
75bffa71 | 3347 | if test x$host != x$target |
46f18e7b RK |
3348 | then |
3349 | tmake_file=rs6000/t-xnewas | |
ffe51c8a AO |
3350 | else |
3351 | tmake_file=rs6000/t-newas | |
3352 | fi | |
3353 | if test "$gnu_ld" = yes | |
3354 | then | |
3355 | xmake_file=rs6000/x-aix41-gld | |
d5b7b3ae | 3356 | else |
2abdcaee | 3357 | tmake_file='rs6000/t-newas' |
46f18e7b | 3358 | fi |
9ebbca7d | 3359 | xmake_file=rs6000/x-aix41 |
45e24d08 | 3360 | float_format=none |
a260abc9 DE |
3361 | use_collect2=yes |
3362 | ;; | |
75bffa71 | 3363 | changequote(,)dnl |
7747ddb3 | 3364 | rs6000-ibm-aix4.[3456789]* | powerpc-ibm-aix4.[3456789]*) |
75bffa71 | 3365 | changequote([,])dnl |
a260abc9 | 3366 | tm_file=rs6000/aix43.h |
9ebbca7d GK |
3367 | tmake_file=rs6000/t-aix43 |
3368 | xmake_file=rs6000/x-aix41 | |
45e24d08 | 3369 | float_format=none |
a260abc9 | 3370 | use_collect2=yes |
a473fe45 | 3371 | thread_file='aix' |
a260abc9 | 3372 | ;; |
75bffa71 ILT |
3373 | changequote(,)dnl |
3374 | rs6000-ibm-aix[56789].* | powerpc-ibm-aix[56789].*) | |
3375 | changequote([,])dnl | |
a260abc9 | 3376 | tm_file=rs6000/aix43.h |
9ebbca7d GK |
3377 | tmake_file=rs6000/t-aix43 |
3378 | xmake_file=rs6000/x-aix41 | |
45e24d08 | 3379 | float_format=none |
46f18e7b | 3380 | use_collect2=yes |
a473fe45 | 3381 | thread_file='aix' |
46f18e7b RK |
3382 | ;; |
3383 | rs6000-ibm-aix*) | |
45e24d08 | 3384 | float_format=none |
46f18e7b RK |
3385 | use_collect2=yes |
3386 | ;; | |
3387 | rs6000-bull-bosx) | |
45e24d08 | 3388 | float_format=none |
46f18e7b RK |
3389 | use_collect2=yes |
3390 | ;; | |
3391 | rs6000-*-mach*) | |
3392 | tm_file=rs6000/mach.h | |
61536478 | 3393 | xm_file="${xm_file} rs6000/xm-mach.h" |
46f18e7b RK |
3394 | xmake_file=rs6000/x-mach |
3395 | use_collect2=yes | |
3396 | ;; | |
3397 | rs6000-*-lynxos*) | |
3398 | tm_file=rs6000/lynx.h | |
3399 | xm_file=rs6000/xm-lynx.h | |
3400 | tmake_file=rs6000/t-rs6000 | |
3401 | xmake_file=rs6000/x-lynx | |
3402 | use_collect2=yes | |
3403 | ;; | |
3404 | sh-*-elf*) | |
1a66cd67 | 3405 | tmake_file="sh/t-sh sh/t-elf" |
ffe51c8a | 3406 | tm_file="sh/sh.h sh/elf.h" |
46f18e7b RK |
3407 | float_format=sh |
3408 | ;; | |
b098f56d | 3409 | sh-*-rtemself*) |
1a66cd67 | 3410 | tmake_file="sh/t-sh sh/t-elf t-rtems" |
ffe51c8a | 3411 | tm_file="sh/sh.h sh/elf.h sh/rtemself.h" |
b098f56d JS |
3412 | float_format=sh |
3413 | ;; | |
5d84b57e JS |
3414 | sh-*-rtems*) |
3415 | tmake_file="sh/t-sh t-rtems" | |
ffe51c8a | 3416 | tm_file="sh/sh.h sh/rtems.h" |
5d84b57e JS |
3417 | float_format=sh |
3418 | ;; | |
93ca1662 NY |
3419 | sh-*-linux*) |
3420 | tm_file="sh/sh.h sh/elf.h sh/linux.h" | |
3421 | tmake_file="sh/t-sh sh/t-elf sh/t-linux" | |
3422 | xmake_file=x-linux | |
3423 | gas=yes gnu_ld=yes | |
3424 | if test x$enable_threads = xyes; then | |
3425 | thread_file='posix' | |
3426 | fi | |
3427 | float_format=sh | |
3428 | ;; | |
46f18e7b RK |
3429 | sh-*-*) |
3430 | float_format=sh | |
3431 | ;; | |
3432 | sparc-tti-*) | |
3433 | tm_file=sparc/pbd.h | |
61536478 JL |
3434 | xm_file="xm-alloca.h ${xm_file}" |
3435 | xm_defines=USG | |
46f18e7b RK |
3436 | ;; |
3437 | sparc-wrs-vxworks* | sparclite-wrs-vxworks*) | |
3438 | tm_file=sparc/vxsparc.h | |
3439 | tmake_file=sparc/t-vxsparc | |
3440 | use_collect2=yes | |
7cc34889 | 3441 | thread_file='vxworks' |
46f18e7b RK |
3442 | ;; |
3443 | sparc-*-aout*) | |
3444 | tmake_file=sparc/t-sparcbare | |
3445 | tm_file="sparc/aout.h libgloss.h" | |
3446 | ;; | |
3447 | sparc-*-netbsd*) | |
3448 | tm_file=sparc/netbsd.h | |
e47f44f4 | 3449 | tmake_file=t-netbsd |
ed4acb3b | 3450 | use_collect2=yes |
46f18e7b | 3451 | ;; |
1b4a979b ME |
3452 | sparc-*-openbsd*) |
3453 | # we need collect2 until our bug is fixed... | |
3454 | use_collect2=yes | |
3455 | ;; | |
46f18e7b RK |
3456 | sparc-*-bsd*) |
3457 | tm_file=sparc/bsd.h | |
3458 | ;; | |
ac52b80b DE |
3459 | sparc-*-elf*) |
3460 | tm_file=sparc/elf.h | |
3461 | tmake_file=sparc/t-elf | |
3462 | extra_parts="crti.o crtn.o crtbegin.o crtend.o" | |
3463 | #float_format=i128 | |
3464 | float_format=i64 | |
3465 | ;; | |
57119aa9 | 3466 | sparc-*-linux*aout*) # Sparc's running GNU/Linux, a.out |
61536478 | 3467 | xm_file="${xm_file} sparc/xm-linux.h" |
46f18e7b RK |
3468 | tm_file=sparc/linux-aout.h |
3469 | xmake_file=x-linux | |
46f18e7b | 3470 | gnu_ld=yes |
46f18e7b | 3471 | ;; |
57119aa9 | 3472 | sparc-*-linux*libc1*) # Sparc's running GNU/Linux, libc5 |
61536478 | 3473 | xm_file="${xm_file} sparc/xm-linux.h" |
2334126e | 3474 | xmake_file=x-linux |
46f18e7b | 3475 | tm_file=sparc/linux.h |
9d1ebd25 | 3476 | tmake_file="t-linux t-linux-gnulibc1" |
9ad03bc1 | 3477 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" |
9ad03bc1 | 3478 | gnu_ld=yes |
39c440fc | 3479 | float_format=sparc |
9ad03bc1 | 3480 | ;; |
57119aa9 | 3481 | sparc-*-linux*) # Sparc's running GNU/Linux, libc6 |
61536478 | 3482 | xm_file="${xm_file} sparc/xm-linux.h" |
2334126e | 3483 | xmake_file=x-linux |
9ad03bc1 | 3484 | tm_file=sparc/linux.h |
9d1ebd25 | 3485 | tmake_file="t-linux" |
9ad03bc1 | 3486 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" |
46f18e7b | 3487 | gnu_ld=yes |
75bffa71 | 3488 | if test x$enable_threads = xyes; then |
9ad03bc1 RK |
3489 | thread_file='posix' |
3490 | fi | |
39c440fc | 3491 | float_format=sparc |
46f18e7b RK |
3492 | ;; |
3493 | sparc-*-lynxos*) | |
75bffa71 | 3494 | if test x$gas = xyes |
46f18e7b RK |
3495 | then |
3496 | tm_file=sparc/lynx.h | |
3497 | else | |
3498 | tm_file=sparc/lynx-ng.h | |
3499 | fi | |
3500 | xm_file=sparc/xm-lynx.h | |
3501 | tmake_file=sparc/t-sunos41 | |
3502 | xmake_file=x-lynx | |
3503 | ;; | |
6e5138f0 JS |
3504 | sparc-*-rtemsaout*) |
3505 | tmake_file="sparc/t-sparcbare t-rtems" | |
3506 | tm_file=sparc/rtems.h | |
dae3a2d3 | 3507 | ;; |
d1476635 JS |
3508 | sparc-*-rtems*|sparc-*-rtemself*) |
3509 | tm_file="sparc/rtemself.h" | |
3510 | tmake_file="sparc/t-elf t-rtems" | |
3511 | extra_parts="crti.o crtn.o crtbegin.o crtend.o" | |
3512 | #float_format=i128 | |
3513 | float_format=i64 | |
3514 | ;; | |
d559a4db | 3515 | sparcv9-*-solaris2*) |
3b1c302f AO |
3516 | if test x$gnu_ld = xyes |
3517 | then | |
3518 | tm_file=sparc/sol2-64.h | |
3519 | else | |
3520 | tm_file=sparc/sol2-sld-64.h | |
3521 | fi | |
d559a4db DM |
3522 | xm_file="sparc/xm-sysv4-64.h sparc/xm-sol2.h" |
3523 | xm_defines="USG POSIX" | |
345a6161 | 3524 | tmake_file="sparc/t-sol2 sparc/t-sol2-64" |
aefa45d3 RH |
3525 | if test x$gnu_ld = xyes; then |
3526 | tmake_file="$tmake_file sparc/t-slibgcc" | |
3527 | else | |
3528 | tmake_file="$tmake_file sparc/t-slibgcc-sld" | |
3529 | fi | |
d559a4db DM |
3530 | xmake_file=sparc/x-sysv4 |
3531 | extra_parts="crt1.o crti.o crtn.o gcrt1.o crtbegin.o crtend.o" | |
027ea2a7 | 3532 | float_format=none |
d7496fbb | 3533 | if test x${enable_threads} = x ; then |
d559a4db | 3534 | enable_threads=$have_pthread_h |
d7496fbb | 3535 | if test x${enable_threads} = x ; then |
d559a4db DM |
3536 | enable_threads=$have_thread_h |
3537 | fi | |
3538 | fi | |
d7496fbb DM |
3539 | if test x${enable_threads} = xyes ; then |
3540 | if test x${have_pthread_h} = xyes ; then | |
d559a4db DM |
3541 | thread_file='posix' |
3542 | else | |
3543 | thread_file='solaris' | |
3544 | fi | |
3545 | fi | |
3546 | ;; | |
ab87f8c8 | 3547 | sparc-hal-solaris2*) |
2d092ffa | 3548 | xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h" |
a5037588 | 3549 | xm_defines="USG POSIX" |
ab87f8c8 JL |
3550 | tm_file="sparc/sol2.h sparc/hal.h" |
3551 | tmake_file="sparc/t-halos sparc/t-sol2" | |
aefa45d3 RH |
3552 | if test x$gnu_ld = xyes; then |
3553 | tmake_file="$tmake_file sparc/t-slibgcc" | |
3554 | else | |
3555 | tmake_file="$tmake_file sparc/t-slibgcc-sld" | |
3556 | fi | |
ab87f8c8 JL |
3557 | xmake_file=sparc/x-sysv4 |
3558 | extra_parts="crt1.o crti.o crtn.o gmon.o crtbegin.o crtend.o" | |
a5037588 | 3559 | case $machine in |
e7651ec5 | 3560 | changequote(,)dnl |
a5037588 | 3561 | *-*-solaris2.[0-4]) |
e7651ec5 | 3562 | changequote([,])dnl |
a5037588 CL |
3563 | float_format=i128 |
3564 | ;; | |
3565 | *) | |
3566 | float_format=none | |
3567 | ;; | |
3568 | esac | |
3569 | thread_file='solaris' | |
ab87f8c8 | 3570 | ;; |
46f18e7b | 3571 | sparc-*-solaris2*) |
75bffa71 | 3572 | if test x$gnu_ld = xyes |
0a9bdce3 PE |
3573 | then |
3574 | tm_file=sparc/sol2.h | |
3575 | else | |
3576 | tm_file=sparc/sol2-sld.h | |
3577 | fi | |
2d092ffa | 3578 | xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h" |
22ec3928 | 3579 | xm_defines="USG POSIX" |
46f18e7b | 3580 | tmake_file=sparc/t-sol2 |
aefa45d3 RH |
3581 | if test x$gnu_ld = xyes; then |
3582 | tmake_file="$tmake_file sparc/t-slibgcc" | |
3583 | else | |
3584 | tmake_file="$tmake_file sparc/t-slibgcc-sld" | |
3585 | fi | |
46f18e7b RK |
3586 | xmake_file=sparc/x-sysv4 |
3587 | extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o" | |
72882e08 KG |
3588 | # At the moment, 32-to-64 cross compilation doesn't work. |
3589 | # case $machine in | |
3590 | #changequote(,)dnl | |
3591 | # *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*) ;; | |
3592 | #changequote([,])dnl | |
3593 | # *-*-solaris2*) | |
3594 | # if test x$gnu_ld = xyes | |
3595 | # then | |
3596 | # tm_file=sparc/sol2-64.h | |
3597 | # else | |
3598 | # tm_file=sparc/sol2-sld-64.h | |
3599 | # fi | |
3600 | # tmake_file="$tmake_file sparc/t-sol2-64" | |
3601 | # ;; | |
3602 | # esac | |
a242e6f5 | 3603 | case $machine in |
75bffa71 ILT |
3604 | changequote(,)dnl |
3605 | *-*-solaris2.[0-4]) | |
3606 | changequote([,])dnl | |
027ea2a7 JW |
3607 | float_format=i128 |
3608 | ;; | |
61536478 | 3609 | *) |
027ea2a7 JW |
3610 | float_format=none |
3611 | ;; | |
61536478 | 3612 | esac |
75bffa71 | 3613 | if test x${enable_threads} = x; then |
f24af81b | 3614 | enable_threads=$have_pthread_h |
75bffa71 | 3615 | if test x${enable_threads} = x; then |
f24af81b TT |
3616 | enable_threads=$have_thread_h |
3617 | fi | |
3618 | fi | |
75bffa71 ILT |
3619 | if test x${enable_threads} = xyes; then |
3620 | if test x${have_pthread_h} = xyes; then | |
f24af81b TT |
3621 | thread_file='posix' |
3622 | else | |
0bbb1697 | 3623 | thread_file='solaris' |
f24af81b | 3624 | fi |
0bbb1697 | 3625 | fi |
46f18e7b RK |
3626 | ;; |
3627 | sparc-*-sunos4.0*) | |
3628 | tm_file=sparc/sunos4.h | |
3629 | tmake_file=sparc/t-sunos40 | |
3630 | use_collect2=yes | |
3631 | ;; | |
3632 | sparc-*-sunos4*) | |
3633 | tm_file=sparc/sunos4.h | |
3634 | tmake_file=sparc/t-sunos41 | |
3635 | use_collect2=yes | |
75bffa71 | 3636 | if test x$gas = xyes; then |
ca55abae JM |
3637 | tm_file="${tm_file} sparc/sun4gas.h" |
3638 | fi | |
46f18e7b RK |
3639 | ;; |
3640 | sparc-*-sunos3*) | |
3641 | tm_file=sparc/sun4o3.h | |
3642 | use_collect2=yes | |
3643 | ;; | |
3644 | sparc-*-sysv4*) | |
3645 | tm_file=sparc/sysv4.h | |
2d092ffa | 3646 | xm_file="sparc/xm-sysv4.h" |
61536478 | 3647 | xm_defines="USG POSIX" |
46f18e7b RK |
3648 | tmake_file=t-svr4 |
3649 | xmake_file=sparc/x-sysv4 | |
3650 | extra_parts="crtbegin.o crtend.o" | |
3651 | ;; | |
3652 | sparc-*-vxsim*) | |
2d092ffa | 3653 | xm_file="sparc/xm-sysv4.h sparc/xm-sol2.h" |
f5963e61 | 3654 | xm_defines="USG POSIX" |
46f18e7b RK |
3655 | tm_file=sparc/vxsim.h |
3656 | tmake_file=sparc/t-vxsparc | |
3657 | xmake_file=sparc/x-sysv4 | |
3658 | ;; | |
3659 | sparclet-*-aout*) | |
3660 | tm_file="sparc/splet.h libgloss.h" | |
3661 | tmake_file=sparc/t-splet | |
3662 | ;; | |
3663 | sparclite-*-coff*) | |
3664 | tm_file="sparc/litecoff.h libgloss.h" | |
3665 | tmake_file=sparc/t-sparclite | |
3666 | ;; | |
3667 | sparclite-*-aout*) | |
3668 | tm_file="sparc/lite.h aoutos.h libgloss.h" | |
3669 | tmake_file=sparc/t-sparclite | |
3670 | ;; | |
28df4168 | 3671 | sparclite-*-elf*) |
6eccdc81 | 3672 | tm_file="sparc/liteelf.h" |
28df4168 JL |
3673 | tmake_file=sparc/t-sparclite |
3674 | extra_parts="crtbegin.o crtend.o" | |
3675 | ;; | |
3676 | sparc86x-*-aout*) | |
3677 | tm_file="sparc/sp86x-aout.h aoutos.h libgloss.h" | |
3678 | tmake_file=sparc/t-sp86x | |
3679 | ;; | |
3680 | sparc86x-*-elf*) | |
6eccdc81 | 3681 | tm_file="sparc/sp86x-elf.h" |
28df4168 JL |
3682 | tmake_file=sparc/t-sp86x |
3683 | extra_parts="crtbegin.o crtend.o" | |
3684 | ;; | |
46f18e7b RK |
3685 | sparc64-*-aout*) |
3686 | tmake_file=sparc/t-sp64 | |
3687 | tm_file=sparc/sp64-aout.h | |
3688 | ;; | |
3689 | sparc64-*-elf*) | |
3690 | tmake_file=sparc/t-sp64 | |
3691 | tm_file=sparc/sp64-elf.h | |
3692 | extra_parts="crtbegin.o crtend.o" | |
3693 | ;; | |
956d6950 | 3694 | sparc64-*-linux*) # 64-bit Sparc's running GNU/Linux |
345a6161 | 3695 | tmake_file="t-linux sparc/t-linux64" |
2334126e DE |
3696 | xm_file="sparc/xm-sp64.h sparc/xm-linux.h" |
3697 | tm_file=sparc/linux64.h | |
3698 | xmake_file=x-linux | |
345a6161 | 3699 | extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" |
2334126e | 3700 | gnu_ld=yes |
9ce13279 JJ |
3701 | if test x$enable_threads = xyes; then |
3702 | thread_file='posix' | |
3703 | fi | |
39c440fc | 3704 | float_format=sparc |
2334126e | 3705 | ;; |
d5b7b3ae RE |
3706 | thumb*-*-*) |
3707 | AC_MSG_ERROR([ | |
3708 | *** The Thumb targets have been depreciated. The equivalent | |
3709 | *** ARM based toolchain can now generated Thumb instructions | |
3710 | *** when the -mthumb switch is given to the compiler.]) | |
cb805c2d | 3711 | ;; |
966f8bfd JS |
3712 | v850-*-rtems*) |
3713 | cpu_type=v850 | |
3714 | tm_file="v850/rtems.h" | |
3715 | xm_file="v850/xm-v850.h" | |
3716 | tmake_file="v850/t-v850 t-rtems" | |
3717 | if test x$stabs = xyes | |
3718 | then | |
3719 | tm_file="${tm_file} dbx.h" | |
3720 | fi | |
3721 | use_collect2=no | |
3722 | ;; | |
f84271d9 | 3723 | v850-*-*) |
7a846a6c | 3724 | target_cpu_default="TARGET_CPU_generic" |
f84271d9 JL |
3725 | cpu_type=v850 |
3726 | tm_file="v850/v850.h" | |
3727 | xm_file="v850/xm-v850.h" | |
62db76ee | 3728 | tmake_file=v850/t-v850 |
75bffa71 | 3729 | if test x$stabs = xyes |
f84271d9 JL |
3730 | then |
3731 | tm_file="${tm_file} dbx.h" | |
3732 | fi | |
3733 | use_collect2=no | |
3734 | ;; | |
46f18e7b RK |
3735 | vax-*-bsd*) # vaxen running BSD |
3736 | use_collect2=yes | |
3737 | float_format=vax | |
3738 | ;; | |
3739 | vax-*-sysv*) # vaxen running system V | |
3740 | tm_file="${tm_file} vax/vaxv.h" | |
61536478 | 3741 | xm_defines=USG |
46f18e7b RK |
3742 | float_format=vax |
3743 | ;; | |
3744 | vax-*-netbsd*) | |
3745 | tm_file="${tm_file} netbsd.h vax/netbsd.h" | |
e47f44f4 | 3746 | tmake_file=t-netbsd |
46f18e7b | 3747 | float_format=vax |
ed4acb3b | 3748 | use_collect2=yes |
46f18e7b | 3749 | ;; |
1b4a979b | 3750 | vax-*-openbsd*) |
766518a0 | 3751 | tmake_file="${tmake_file} vax/t-openbsd" |
97f2b269 ME |
3752 | tm_file="vax/vax.h vax/openbsd1.h openbsd.h ${tm_file}" |
3753 | xm_file="xm-openbsd.h vax/xm-vax.h" | |
3754 | float_format=vax | |
3755 | use_collect2=yes | |
1b4a979b | 3756 | ;; |
46f18e7b RK |
3757 | vax-*-ultrix*) # vaxen running ultrix |
3758 | tm_file="${tm_file} vax/ultrix.h" | |
46f18e7b RK |
3759 | float_format=vax |
3760 | ;; | |
3761 | vax-*-vms*) # vaxen running VMS | |
3762 | xm_file=vax/xm-vms.h | |
3763 | tm_file=vax/vms.h | |
3764 | float_format=vax | |
3765 | ;; | |
3766 | vax-*-*) # vax default entry | |
3767 | float_format=vax | |
3768 | ;; | |
3769 | we32k-att-sysv*) | |
3770 | xm_file="${xm_file} xm-svr3" | |
3771 | use_collect2=yes | |
3772 | ;; | |
3773 | *) | |
3774 | echo "Configuration $machine not supported" 1>&2 | |
3775 | exit 1 | |
3776 | ;; | |
3777 | esac | |
3778 | ||
3779 | case $machine in | |
57119aa9 | 3780 | *-*-linux*) |
61536478 | 3781 | ;; # Existing GNU/Linux systems do not use the GNU setup. |
46f18e7b RK |
3782 | *-*-gnu*) |
3783 | # On the GNU system, the setup is just about the same on | |
3784 | # each different CPU. The specific machines that GNU | |
3785 | # supports are matched above and just set $cpu_type. | |
61536478 | 3786 | xm_file="xm-gnu.h ${xm_file}" |
46f18e7b | 3787 | tm_file=${cpu_type}/gnu.h |
6b403743 | 3788 | extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" |
46f18e7b RK |
3789 | # GNU always uses ELF. |
3790 | elf=yes | |
3791 | # GNU tools are the only tools. | |
3792 | gnu_ld=yes | |
3793 | gas=yes | |
46f18e7b RK |
3794 | xmake_file=x-linux # These details are the same as Linux. |
3795 | tmake_file=t-gnu # These are not. | |
3796 | ;; | |
3797 | *-*-sysv4*) | |
46f18e7b | 3798 | xmake_try_sysv=x-sysv |
46f18e7b RK |
3799 | install_headers_dir=install-headers-cpio |
3800 | ;; | |
3801 | *-*-sysv*) | |
46f18e7b RK |
3802 | install_headers_dir=install-headers-cpio |
3803 | ;; | |
3804 | esac | |
3805 | ||
61536478 | 3806 | # Distinguish i[34567]86 |
46f18e7b RK |
3807 | # Also, do not run mips-tfile on MIPS if using gas. |
3808 | # Process --with-cpu= for PowerPC/rs6000 | |
3809 | target_cpu_default2= | |
3810 | case $machine in | |
3811 | i486-*-*) | |
3812 | target_cpu_default2=1 | |
3813 | ;; | |
3814 | i586-*-*) | |
83f4345f PT |
3815 | case $target_alias in |
3816 | k6-*) | |
3817 | target_cpu_default2=4 | |
3818 | ;; | |
3819 | *) | |
3820 | target_cpu_default2=2 | |
3821 | ;; | |
3822 | esac | |
46f18e7b | 3823 | ;; |
61536478 | 3824 | i686-*-* | i786-*-*) |
46f18e7b RK |
3825 | target_cpu_default2=3 |
3826 | ;; | |
08fc0184 RK |
3827 | alpha*-*-*) |
3828 | case $machine in | |
2618c083 | 3829 | changequote(,)dnl |
d8ee3e20 | 3830 | alphaev6[78]*) |
2618c083 | 3831 | changequote([,])dnl |
d8ee3e20 RH |
3832 | target_cpu_default2="MASK_CPU_EV6|MASK_BWX|MASK_MAX|MASK_FIX|MASK_CIX" |
3833 | ;; | |
e9a25f70 | 3834 | alphaev6*) |
de4abb91 | 3835 | target_cpu_default2="MASK_CPU_EV6|MASK_BWX|MASK_MAX|MASK_FIX" |
e9a25f70 JL |
3836 | ;; |
3837 | alphapca56*) | |
fbb5ed67 | 3838 | target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX" |
e9a25f70 | 3839 | ;; |
08fc0184 | 3840 | alphaev56*) |
e9a25f70 | 3841 | target_cpu_default2="MASK_CPU_EV5|MASK_BWX" |
08fc0184 RK |
3842 | ;; |
3843 | alphaev5*) | |
3844 | target_cpu_default2="MASK_CPU_EV5" | |
3845 | ;; | |
3846 | esac | |
3847 | ||
75bffa71 | 3848 | if test x$gas = xyes |
46f18e7b | 3849 | then |
75bffa71 | 3850 | if test "$target_cpu_default2" = "" |
08fc0184 | 3851 | then |
e71c3bb0 | 3852 | target_cpu_default2="MASK_GAS" |
08fc0184 | 3853 | else |
e71c3bb0 | 3854 | target_cpu_default2="${target_cpu_default2}|MASK_GAS" |
08fc0184 | 3855 | fi |
46f18e7b RK |
3856 | fi |
3857 | ;; | |
956d6950 JL |
3858 | arm*-*-*) |
3859 | case "x$with_cpu" in | |
3860 | x) | |
3861 | # The most generic | |
3862 | target_cpu_default2="TARGET_CPU_generic" | |
3863 | ;; | |
3864 | ||
3865 | # Distinguish cores, and major variants | |
3866 | # arm7m doesn't exist, but D & I don't affect code | |
7805bde9 | 3867 | changequote(,)dnl |
956d6950 JL |
3868 | xarm[23678] | xarm250 | xarm[67][01]0 \ |
3869 | | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \ | |
3870 | | xarm7100 | xarm7500 | xarm7500fe | xarm810 \ | |
8f8d3278 | 3871 | | xstrongarm | xstrongarm110 | xstrongarm1100) |
7805bde9 | 3872 | changequote([,])dnl |
956d6950 JL |
3873 | target_cpu_default2="TARGET_CPU_$with_cpu" |
3874 | ;; | |
3875 | ||
3876 | xyes | xno) | |
3877 | echo "--with-cpu must be passed a value" 1>&2 | |
3878 | exit 1 | |
3879 | ;; | |
3880 | ||
3881 | *) | |
75bffa71 | 3882 | if test x$pass2done = xyes |
956d6950 JL |
3883 | then |
3884 | echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2 | |
3885 | exit 1 | |
3886 | fi | |
3887 | ;; | |
3888 | esac | |
3889 | ;; | |
3890 | ||
46f18e7b | 3891 | mips*-*-ecoff* | mips*-*-elf*) |
75bffa71 | 3892 | if test x$gas = xyes |
46f18e7b | 3893 | then |
75bffa71 | 3894 | if test x$gnu_ld = xyes |
46f18e7b | 3895 | then |
e7651ec5 | 3896 | target_cpu_default2="MASK_GAS|MASK_SPLIT_ADDR" |
46f18e7b | 3897 | else |
e7651ec5 | 3898 | target_cpu_default2="MASK_GAS" |
46f18e7b RK |
3899 | fi |
3900 | fi | |
3901 | ;; | |
3902 | mips*-*-*) | |
75bffa71 | 3903 | if test x$gas = xyes |
46f18e7b | 3904 | then |
e7651ec5 | 3905 | target_cpu_default2="MASK_GAS" |
46f18e7b RK |
3906 | fi |
3907 | ;; | |
3908 | powerpc*-*-* | rs6000-*-*) | |
3909 | case "x$with_cpu" in | |
3910 | x) | |
3911 | ;; | |
3912 | ||
3913 | xcommon | xpower | xpower2 | xpowerpc | xrios \ | |
52cddadb MM |
3914 | | xrios1 | xrios2 | xrsc | xrsc1 \ |
3915 | | x601 | x602 | x603 | x603e | x604 | x604e | x620 \ | |
507ba956 | 3916 | | xec603e | x740 | x750 | x401 \ |
52cddadb | 3917 | | x403 | x505 | x801 | x821 | x823 | x860) |
f24b370a | 3918 | target_cpu_default2="\"$with_cpu\"" |
46f18e7b RK |
3919 | ;; |
3920 | ||
3921 | xyes | xno) | |
3922 | echo "--with-cpu must be passed a value" 1>&2 | |
3923 | exit 1 | |
3924 | ;; | |
3925 | ||
3926 | *) | |
75bffa71 | 3927 | if test x$pass2done = xyes |
956d6950 JL |
3928 | then |
3929 | echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2 | |
3930 | exit 1 | |
3931 | fi | |
46f18e7b RK |
3932 | ;; |
3933 | esac | |
3934 | ;; | |
3935 | sparc*-*-*) | |
3936 | case ".$with_cpu" in | |
3937 | .) | |
3938 | target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`" | |
3939 | ;; | |
8947065c | 3940 | .supersparc | .hypersparc | .ultrasparc | .v7 | .v8 | .v9) |
46f18e7b RK |
3941 | target_cpu_default2="TARGET_CPU_$with_cpu" |
3942 | ;; | |
3943 | *) | |
75bffa71 | 3944 | if test x$pass2done = xyes |
956d6950 JL |
3945 | then |
3946 | echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2 | |
3947 | exit 1 | |
3948 | fi | |
46f18e7b RK |
3949 | ;; |
3950 | esac | |
3951 | ;; | |
3952 | esac | |
3953 | ||
75bffa71 | 3954 | if test "$target_cpu_default2" != "" |
46f18e7b | 3955 | then |
75bffa71 | 3956 | if test "$target_cpu_default" != "" |
46f18e7b RK |
3957 | then |
3958 | target_cpu_default="(${target_cpu_default}|${target_cpu_default2})" | |
3959 | else | |
3960 | target_cpu_default=$target_cpu_default2 | |
3961 | fi | |
3962 | fi | |
3963 | ||
3964 | # No need for collect2 if we have the GNU linker. | |
d460fb3c JM |
3965 | # Actually, there is now; GNU ld doesn't handle the EH info or |
3966 | # collecting for shared libraries. | |
ca8c3b37 JM |
3967 | #case x$gnu_ld in |
3968 | #xyes) | |
3969 | # use_collect2= | |
3970 | # ;; | |
3971 | #esac | |
46f18e7b RK |
3972 | |
3973 | # Save data on machine being used to compile GCC in build_xm_file. | |
3974 | # Save data on host machine in vars host_xm_file and host_xmake_file. | |
75bffa71 | 3975 | if test x$pass1done = x |
46f18e7b | 3976 | then |
75bffa71 | 3977 | if test x"$xm_file" = x |
46f18e7b RK |
3978 | then build_xm_file=$cpu_type/xm-$cpu_type.h |
3979 | else build_xm_file=$xm_file | |
3980 | fi | |
61536478 | 3981 | build_xm_defines=$xm_defines |
46f18e7b RK |
3982 | build_install_headers_dir=$install_headers_dir |
3983 | build_exeext=$exeext | |
3984 | pass1done=yes | |
3985 | else | |
75bffa71 | 3986 | if test x$pass2done = x |
46f18e7b | 3987 | then |
75bffa71 | 3988 | if test x"$xm_file" = x |
46f18e7b RK |
3989 | then host_xm_file=$cpu_type/xm-$cpu_type.h |
3990 | else host_xm_file=$xm_file | |
3991 | fi | |
61536478 | 3992 | host_xm_defines=$xm_defines |
75bffa71 | 3993 | if test x"$xmake_file" = x |
46f18e7b RK |
3994 | then xmake_file=$cpu_type/x-$cpu_type |
3995 | fi | |
3996 | host_xmake_file="$xmake_file" | |
3997 | host_truncate_target=$truncate_target | |
3998 | host_extra_gcc_objs=$extra_gcc_objs | |
3999 | host_extra_objs=$extra_host_objs | |
6e26218f | 4000 | host_exeext=$exeext |
46f18e7b RK |
4001 | pass2done=yes |
4002 | fi | |
4003 | fi | |
4004 | done | |
4005 | ||
4006 | extra_objs="${host_extra_objs} ${extra_objs}" | |
4007 | ||
4008 | # Default the target-machine variables that were not explicitly set. | |
75bffa71 | 4009 | if test x"$tm_file" = x |
46f18e7b RK |
4010 | then tm_file=$cpu_type/$cpu_type.h; fi |
4011 | ||
75bffa71 | 4012 | if test x$extra_headers = x |
46f18e7b RK |
4013 | then extra_headers=; fi |
4014 | ||
75bffa71 | 4015 | if test x"$xm_file" = x |
46f18e7b RK |
4016 | then xm_file=$cpu_type/xm-$cpu_type.h; fi |
4017 | ||
75bffa71 | 4018 | if test x$md_file = x |
e98e406f | 4019 | then md_file=$cpu_type/$cpu_type.md; fi |
46f18e7b | 4020 | |
75bffa71 | 4021 | if test x$out_file = x |
46f18e7b RK |
4022 | then out_file=$cpu_type/$cpu_type.c; fi |
4023 | ||
75bffa71 | 4024 | if test x"$tmake_file" = x |
46f18e7b RK |
4025 | then tmake_file=$cpu_type/t-$cpu_type |
4026 | fi | |
4027 | ||
90e6a802 | 4028 | if test x"$dwarf2" = xyes |
756ee602 | 4029 | then tm_file="$tm_file tm-dwarf2.h" |
90e6a802 RL |
4030 | fi |
4031 | ||
75bffa71 | 4032 | if test x$float_format = x |
46f18e7b RK |
4033 | then float_format=i64 |
4034 | fi | |
4035 | ||
027ea2a7 JW |
4036 | if test $float_format = none |
4037 | then float_h_file=Makefile.in | |
4038 | else float_h_file=float-$float_format.h | |
4039 | fi | |
4040 | ||
9fc9b82a | 4041 | # Handle cpp installation. |
3ecc3258 | 4042 | if test x$enable_cpp != xno |
9fc9b82a L |
4043 | then |
4044 | tmake_file="$tmake_file t-install-cpp" | |
4045 | fi | |
4046 | ||
46f18e7b RK |
4047 | # Say what files are being used for the output code and MD file. |
4048 | echo "Using \`$srcdir/config/$out_file' to output insns." | |
4049 | echo "Using \`$srcdir/config/$md_file' as machine description file." | |
4050 | ||
4051 | count=a | |
4052 | for f in $tm_file; do | |
4053 | count=${count}x | |
4054 | done | |
75bffa71 | 4055 | if test $count = ax; then |
46f18e7b RK |
4056 | echo "Using \`$srcdir/config/$tm_file' as target machine macro file." |
4057 | else | |
4058 | echo "Using the following target machine macro files:" | |
4059 | for f in $tm_file; do | |
4060 | echo " $srcdir/config/$f" | |
4061 | done | |
4062 | fi | |
4063 | ||
4064 | count=a | |
4065 | for f in $host_xm_file; do | |
4066 | count=${count}x | |
4067 | done | |
75bffa71 | 4068 | if test $count = ax; then |
46f18e7b RK |
4069 | echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file." |
4070 | else | |
4071 | echo "Using the following host machine macro files:" | |
4072 | for f in $host_xm_file; do | |
4073 | echo " $srcdir/config/$f" | |
4074 | done | |
4075 | fi | |
4076 | ||
75bffa71 | 4077 | if test "$host_xm_file" != "$build_xm_file"; then |
46f18e7b RK |
4078 | count=a |
4079 | for f in $build_xm_file; do | |
4080 | count=${count}x | |
4081 | done | |
75bffa71 | 4082 | if test $count = ax; then |
46f18e7b RK |
4083 | echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file." |
4084 | else | |
4085 | echo "Using the following build machine macro files:" | |
4086 | for f in $build_xm_file; do | |
4087 | echo " $srcdir/config/$f" | |
4088 | done | |
4089 | fi | |
4090 | fi | |
4091 | ||
75bffa71 ILT |
4092 | if test x$thread_file = x; then |
4093 | if test x$target_thread_file != x; then | |
a851212a JW |
4094 | thread_file=$target_thread_file |
4095 | else | |
4096 | thread_file='single' | |
4097 | fi | |
46f18e7b | 4098 | fi |
46f18e7b RK |
4099 | |
4100 | # Set up the header files. | |
4101 | # $links is the list of header files to create. | |
4102 | # $vars is the list of shell variables with file names to include. | |
b7cb92ad | 4103 | # auto-host.h is the file containing items generated by autoconf and is |
e9a25f70 | 4104 | # the first file included by config.h. |
61536478 | 4105 | null_defines= |
64ccbc99 | 4106 | host_xm_file="auto-host.h gansidecl.h ${host_xm_file} hwint.h" |
db81d74a | 4107 | |
b7cb92ad | 4108 | # If host=build, it is correct to have hconfig include auto-host.h |
db81d74a RH |
4109 | # as well. If host!=build, we are in error and need to do more |
4110 | # work to find out the build config parameters. | |
75bffa71 | 4111 | if test x$host = x$build |
db81d74a | 4112 | then |
64ccbc99 | 4113 | build_xm_file="auto-host.h gansidecl.h ${build_xm_file} hwint.h" |
b7cb92ad JL |
4114 | else |
4115 | # We create a subdir, then run autoconf in the subdir. | |
4116 | # To prevent recursion we set host and build for the new | |
4117 | # invocation of configure to the build for this invocation | |
4118 | # of configure. | |
4119 | tempdir=build.$$ | |
4120 | rm -rf $tempdir | |
4121 | mkdir $tempdir | |
4122 | cd $tempdir | |
4123 | case ${srcdir} in | |
4124 | /*) realsrcdir=${srcdir};; | |
4125 | *) realsrcdir=../${srcdir};; | |
4126 | esac | |
fe81dd69 | 4127 | CC=${CC_FOR_BUILD} ${realsrcdir}/configure \ |
b7cb92ad JL |
4128 | --target=$target --host=$build --build=$build |
4129 | ||
4130 | # We just finished tests for the build machine, so rename | |
4131 | # the file auto-build.h in the gcc directory. | |
4132 | mv auto-host.h ../auto-build.h | |
4133 | cd .. | |
4134 | rm -rf $tempdir | |
64ccbc99 | 4135 | build_xm_file="auto-build.h gansidecl.h ${build_xm_file} hwint.h" |
db81d74a RH |
4136 | fi |
4137 | ||
0056a9b5 KG |
4138 | xm_file="gansidecl.h ${xm_file}" |
4139 | tm_file="gansidecl.h ${tm_file}" | |
4140 | ||
6baf1cc8 BS |
4141 | vars="host_xm_file tm_file tm_p_file xm_file build_xm_file" |
4142 | links="config.h tm.h tm_p.h tconfig.h hconfig.h" | |
4143 | defines="host_xm_defines null_defines null_defines xm_defines build_xm_defines" | |
46f18e7b RK |
4144 | |
4145 | rm -f config.bak | |
75bffa71 | 4146 | if test -f config.status; then mv -f config.status config.bak; fi |
46f18e7b RK |
4147 | |
4148 | # Make the links. | |
75bffa71 | 4149 | while test -n "$vars" |
46f18e7b | 4150 | do |
46f18e7b RK |
4151 | set $vars; var=$1; shift; vars=$* |
4152 | set $links; link=$1; shift; links=$* | |
61536478 | 4153 | set $defines; define=$1; shift; defines=$* |
46f18e7b RK |
4154 | |
4155 | rm -f $link | |
6baf1cc8 BS |
4156 | # Make sure the file is created, even if it is empty. |
4157 | echo >$link | |
46f18e7b RK |
4158 | |
4159 | # Define TARGET_CPU_DEFAULT if the system wants one. | |
4160 | # This substitutes for lots of *.h files. | |
75bffa71 | 4161 | if test "$target_cpu_default" != "" -a $link = tm.h |
46f18e7b | 4162 | then |
8fbf199e | 4163 | echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link |
46f18e7b RK |
4164 | fi |
4165 | ||
4166 | for file in `eval echo '$'$var`; do | |
ab87f8c8 | 4167 | case $file in |
6efa1582 | 4168 | auto-host.h | auto-build.h ) |
ab87f8c8 JL |
4169 | ;; |
4170 | *) | |
4171 | echo '#ifdef IN_GCC' >>$link | |
4172 | ;; | |
4173 | esac | |
46f18e7b | 4174 | echo "#include \"$file\"" >>$link |
ab87f8c8 | 4175 | case $file in |
6efa1582 | 4176 | auto-host.h | auto-build.h ) |
ab87f8c8 JL |
4177 | ;; |
4178 | *) | |
4179 | echo '#endif' >>$link | |
4180 | ;; | |
4181 | esac | |
46f18e7b | 4182 | done |
61536478 JL |
4183 | |
4184 | for def in `eval echo '$'$define`; do | |
4185 | echo "#ifndef $def" >>$link | |
4186 | echo "#define $def" >>$link | |
4187 | echo "#endif" >>$link | |
4188 | done | |
46f18e7b RK |
4189 | done |
4190 | ||
4191 | # Truncate the target if necessary | |
75bffa71 | 4192 | if test x$host_truncate_target != x; then |
46f18e7b RK |
4193 | target=`echo $target | sed -e 's/\(..............\).*/\1/'` |
4194 | fi | |
4195 | ||
f1943b77 | 4196 | # Get the version trigger filename from the toplevel |
75bffa71 | 4197 | if test "${with_gcc_version_trigger+set}" = set; then |
f1943b77 MH |
4198 | gcc_version_trigger=$with_gcc_version_trigger |
4199 | else | |
4200 | gcc_version_trigger=${srcdir}/version.c | |
4201 | fi | |
75bffa71 | 4202 | changequote(,)dnl |
8763704d JM |
4203 | gcc_version_full=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([^\"]*\)\".*/\1/'` |
4204 | gcc_version=`echo ${gcc_version_full} | sed -e 's/\([^ ]*\) .*/\1/'` | |
cc1e60ea JM |
4205 | |
4206 | # Compile in configure arguments. | |
8105825d | 4207 | if test -f configargs.h ; then |
cc1e60ea JM |
4208 | # Being re-configured. |
4209 | gcc_config_arguments=`grep configuration_arguments configargs.h | sed -e 's/.*\"\([^\"]*\)\".*/\1/'` | |
4210 | gcc_config_arguments="$gcc_config_arguments : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" | |
4211 | else | |
4212 | gcc_config_arguments="$TOPLEVEL_CONFIGURE_ARGUMENTS" | |
4213 | fi | |
4214 | cat > configargs.h <<EOF | |
4215 | /* Generated automatically. */ | |
4216 | static const char configuration_arguments[] = "$gcc_config_arguments"; | |
4217 | EOF | |
75bffa71 | 4218 | changequote([,])dnl |
46f18e7b | 4219 | |
ab87f8c8 JL |
4220 | # Internationalization |
4221 | PACKAGE=gcc | |
4222 | VERSION="$gcc_version" | |
119d24d1 KG |
4223 | AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", |
4224 | [Define to the name of the distribution.]) | |
4225 | AC_DEFINE_UNQUOTED(VERSION, "$VERSION", | |
4226 | [Define to the version of the distribution.]) | |
ab87f8c8 JL |
4227 | AC_SUBST(PACKAGE) |
4228 | AC_SUBST(VERSION) | |
4229 | ||
37aeda9a | 4230 | ALL_LINGUAS="en_GB" |
ab87f8c8 | 4231 | |
dc6746e7 | 4232 | # Enable NLS support by default |
ab87f8c8 | 4233 | AC_ARG_ENABLE(nls, |
dc6746e7 PT |
4234 | [ --enable-nls use Native Language Support (default)], |
4235 | , enable_nls=yes) | |
4236 | ||
4237 | # if cross compiling, disable NLS support. | |
4238 | # It's not worth the trouble, at least for now. | |
4239 | ||
063a4b85 | 4240 | if test "${build}" != "${host}" && test "x$enable_nls" = "xyes"; then |
dc6746e7 PT |
4241 | AC_MSG_WARN(Disabling NLS support for canadian cross compiler.) |
4242 | enable_nls=no | |
4243 | fi | |
ab87f8c8 | 4244 | |
4adee315 PT |
4245 | # if NLS is enabled, also enable check in po subdir |
4246 | if test $enable_nls = yes; then | |
4247 | CHECK_PO=check-po | |
4248 | else | |
4249 | CHECK_PO="" | |
4250 | fi | |
4251 | ||
4252 | AC_SUBST(CHECK_PO) | |
4253 | ||
ab87f8c8 JL |
4254 | AM_GNU_GETTEXT |
4255 | XGETTEXT="AWK='$AWK' \$(SHELL) \$(top_srcdir)/exgettext $XGETTEXT" | |
4256 | ||
f4ab28e3 MK |
4257 | # Windows32 Registry support for specifying GCC installation paths. |
4258 | AC_ARG_ENABLE(win32-registry, | |
4259 | [ --disable-win32-registry | |
4260 | Disable lookup of installation paths in the | |
4261 | Registry on Windows hosts. | |
4262 | --enable-win32-registry Enable registry lookup (default). | |
4263 | --enable-win32-registry=KEY | |
4264 | Use KEY instead of GCC version as the last portion | |
4265 | of the registry key.],,) | |
4266 | ||
4267 | AC_MSG_CHECKING(whether windows registry support is requested) | |
4268 | if test x$enable_win32_registry != xno; then | |
119d24d1 KG |
4269 | AC_DEFINE(ENABLE_WIN32_REGISTRY, 1, |
4270 | [Define to 1 if installation paths should be looked up in Windows32 | |
91029a29 | 4271 | Registry. Ignored on non windows32 hosts.]) |
f4ab28e3 MK |
4272 | AC_MSG_RESULT(yes) |
4273 | else | |
4274 | AC_MSG_RESULT(no) | |
4275 | fi | |
4276 | ||
4277 | # Check if user specified a different registry key. | |
4278 | case x${enable_win32_registry} in | |
4279 | x | xyes) | |
4280 | # default. | |
4281 | gcc_cv_win32_registry_key="$VERSION" | |
4282 | ;; | |
4283 | xno) | |
4284 | # no registry lookup. | |
4285 | gcc_cv_win32_registry_key='' | |
4286 | ;; | |
4287 | *) | |
4288 | # user-specified key. | |
4289 | gcc_cv_win32_registry_key="$enable_win32_registry" | |
4290 | ;; | |
4291 | esac | |
4292 | ||
4293 | if test x$enable_win32_registry != xno; then | |
4294 | AC_MSG_CHECKING(registry key on windows hosts) | |
119d24d1 KG |
4295 | AC_DEFINE_UNQUOTED(WIN32_REGISTRY_KEY, "$gcc_cv_win32_registry_key", |
4296 | [Define to be the last portion of registry key on windows hosts.]) | |
f4ab28e3 MK |
4297 | AC_MSG_RESULT($gcc_cv_win32_registry_key) |
4298 | fi | |
4299 | ||
7fa10b25 RK |
4300 | # Get an absolute path to the GCC top-level source directory |
4301 | holddir=`pwd` | |
4302 | cd $srcdir | |
4303 | topdir=`pwd` | |
4304 | cd $holddir | |
4305 | ||
af5e4ada | 4306 | # Conditionalize the makefile for this host machine. |
94f42018 DE |
4307 | # Make-host contains the concatenation of all host makefile fragments |
4308 | # [there can be more than one]. This file is built by configure.frag. | |
4309 | host_overrides=Make-host | |
af5e4ada | 4310 | dep_host_xmake_file= |
94f42018 DE |
4311 | for f in .. ${host_xmake_file} |
4312 | do | |
75bffa71 | 4313 | if test -f ${srcdir}/config/$f |
94f42018 DE |
4314 | then |
4315 | dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f" | |
4316 | fi | |
4317 | done | |
46f18e7b | 4318 | |
af5e4ada | 4319 | # Conditionalize the makefile for this target machine. |
94f42018 DE |
4320 | # Make-target contains the concatenation of all host makefile fragments |
4321 | # [there can be more than one]. This file is built by configure.frag. | |
4322 | target_overrides=Make-target | |
af5e4ada | 4323 | dep_tmake_file= |
94f42018 DE |
4324 | for f in .. ${tmake_file} |
4325 | do | |
75bffa71 | 4326 | if test -f ${srcdir}/config/$f |
94f42018 DE |
4327 | then |
4328 | dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f" | |
4329 | fi | |
4330 | done | |
5891b37d | 4331 | |
af5e4ada DE |
4332 | # If the host doesn't support symlinks, modify CC in |
4333 | # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works. | |
4334 | # Otherwise, we can use "CC=$(CC)". | |
4335 | rm -f symtest.tem | |
61536478 | 4336 | if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null |
af5e4ada DE |
4337 | then |
4338 | cc_set_by_configure="\$(CC)" | |
5aa82ace | 4339 | quoted_cc_set_by_configure="\$(CC)" |
af5e4ada DE |
4340 | stage_prefix_set_by_configure="\$(STAGE_PREFIX)" |
4341 | else | |
61536478 JL |
4342 | rm -f symtest.tem |
4343 | if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null | |
4344 | then | |
4345 | symbolic_link="cp -p" | |
4346 | else | |
4347 | symbolic_link="cp" | |
4348 | fi | |
af5e4ada | 4349 | cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`" |
5aa82ace | 4350 | quoted_cc_set_by_configure="\\\`case '\\\$(CC)' in stage*) echo '\\\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\\\$(CC)';; esac\\\`" |
af5e4ada DE |
4351 | stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`" |
4352 | fi | |
4353 | rm -f symtest.tem | |
5891b37d | 4354 | |
af5e4ada | 4355 | out_object_file=`basename $out_file .c`.o |
5891b37d | 4356 | |
af5e4ada DE |
4357 | tm_file_list= |
4358 | for f in $tm_file; do | |
64ccbc99 KG |
4359 | case $f in |
4360 | gansidecl.h ) | |
4361 | tm_file_list="${tm_file_list} $f" ;; | |
4362 | *) tm_file_list="${tm_file_list} \$(srcdir)/config/$f" ;; | |
4363 | esac | |
af5e4ada | 4364 | done |
46f18e7b | 4365 | |
af5e4ada DE |
4366 | host_xm_file_list= |
4367 | for f in $host_xm_file; do | |
64ccbc99 KG |
4368 | case $f in |
4369 | auto-host.h | gansidecl.h | hwint.h ) | |
4370 | host_xm_file_list="${host_xm_file_list} $f" ;; | |
4371 | *) host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f" ;; | |
4372 | esac | |
af5e4ada DE |
4373 | done |
4374 | ||
4375 | build_xm_file_list= | |
4376 | for f in $build_xm_file; do | |
64ccbc99 KG |
4377 | case $f in |
4378 | auto-build.h | auto-host.h | gansidecl.h | hwint.h ) | |
4379 | build_xm_file_list="${build_xm_file_list} $f" ;; | |
4380 | *) build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f" ;; | |
4381 | esac | |
af5e4ada | 4382 | done |
46f18e7b | 4383 | |
af5e4ada DE |
4384 | # Define macro CROSS_COMPILE in compilation |
4385 | # if this is a cross-compiler. | |
4386 | # Also use all.cross instead of all.internal | |
4387 | # and add cross-make to Makefile. | |
571a8de5 | 4388 | cross_overrides="/dev/null" |
75bffa71 | 4389 | if test x$host != x$target |
af5e4ada DE |
4390 | then |
4391 | cross_defines="CROSS=-DCROSS_COMPILE" | |
4392 | cross_overrides="${topdir}/cross-make" | |
4393 | fi | |
46f18e7b | 4394 | |
b39d221a EC |
4395 | # If this is a cross-compiler that does not |
4396 | # have its own set of headers then define | |
4397 | # inhibit_libc | |
4398 | ||
4399 | # If this is using newlib, then define inhibit_libc in | |
4400 | # LIBGCC2_CFLAGS. This will cause __eprintf to be left out of | |
4401 | # libgcc.a, but that's OK because newlib should have its own version of | |
4402 | # assert.h. | |
4403 | inhibit_libc= | |
4404 | if [test x$host != x$target] && [test x$with_headers = x]; then | |
4405 | inhibit_libc=-Dinhibit_libc | |
4406 | else | |
4407 | if [test x$with_newlib = xyes]; then | |
4408 | inhibit_libc=-Dinhibit_libc | |
4409 | fi | |
4410 | fi | |
4411 | AC_SUBST(inhibit_libc) | |
4412 | ||
af5e4ada DE |
4413 | # When building gcc with a cross-compiler, we need to fix a few things. |
4414 | # This must come after cross-make as we want all.build to override | |
4415 | # all.cross. | |
571a8de5 | 4416 | build_overrides="/dev/null" |
75bffa71 | 4417 | if test x$build != x$host |
af5e4ada DE |
4418 | then |
4419 | build_overrides="${topdir}/build-make" | |
4420 | fi | |
46f18e7b | 4421 | |
ae3a15bb DE |
4422 | # Expand extra_headers to include complete path. |
4423 | # This substitutes for lots of t-* files. | |
4424 | extra_headers_list= | |
75bffa71 | 4425 | if test "x$extra_headers" = x |
ae3a15bb DE |
4426 | then true |
4427 | else | |
4428 | # Prepend ${srcdir}/ginclude/ to every entry in extra_headers. | |
4429 | for file in $extra_headers; | |
4430 | do | |
4431 | extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}" | |
4432 | done | |
4433 | fi | |
4434 | ||
75bffa71 | 4435 | if test x$use_collect2 = xno; then |
2ce3c6c6 JM |
4436 | use_collect2= |
4437 | fi | |
4438 | ||
af5e4ada DE |
4439 | # Add a definition of USE_COLLECT2 if system wants one. |
4440 | # Also tell toplev.c what to do. | |
4441 | # This substitutes for lots of t-* files. | |
75bffa71 | 4442 | if test x$use_collect2 = x |
af5e4ada DE |
4443 | then |
4444 | will_use_collect2= | |
4445 | maybe_use_collect2= | |
4446 | else | |
10da1131 | 4447 | will_use_collect2="collect2" |
af5e4ada DE |
4448 | maybe_use_collect2="-DUSE_COLLECT2" |
4449 | fi | |
4450 | ||
4451 | # NEED TO CONVERT | |
4452 | # Set MD_DEPS if the real md file is in md.pre-cpp. | |
4453 | # Set MD_CPP to the cpp to pass the md file through. Md files use ';' | |
4454 | # for line oriented comments, so we must always use a GNU cpp. If | |
4455 | # building gcc with a cross compiler, use the cross compiler just | |
4456 | # built. Otherwise, we can use the cpp just built. | |
4457 | md_file_sub= | |
75bffa71 | 4458 | if test "x$md_cppflags" = x |
af5e4ada DE |
4459 | then |
4460 | md_file_sub=$srcdir/config/$md_file | |
4461 | else | |
4462 | md_file=md | |
4463 | fi | |
4464 | ||
4465 | # If we have gas in the build tree, make a link to it. | |
75bffa71 | 4466 | if test -f ../gas/Makefile; then |
6e26218f | 4467 | rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null |
af5e4ada DE |
4468 | fi |
4469 | ||
4b95eb49 | 4470 | # If we have nm in the build tree, make a link to it. |
75bffa71 | 4471 | if test -f ../binutils/Makefile; then |
4b95eb49 JL |
4472 | rm -f nm; $symbolic_link ../binutils/nm-new$host_exeext nm$host_exeext 2>/dev/null |
4473 | fi | |
4474 | ||
af5e4ada | 4475 | # If we have ld in the build tree, make a link to it. |
75bffa71 ILT |
4476 | if test -f ../ld/Makefile; then |
4477 | # if test x$use_collect2 = x; then | |
6e26218f | 4478 | # rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null |
aa32d841 | 4479 | # else |
6e26218f | 4480 | rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null |
aa32d841 | 4481 | # fi |
af5e4ada DE |
4482 | fi |
4483 | ||
981d4858 JM |
4484 | # Figure out what assembler we will be using. |
4485 | AC_MSG_CHECKING(what assembler to use) | |
9e423e6d | 4486 | gcc_cv_as= |
981d4858 JM |
4487 | gcc_cv_gas_major_version= |
4488 | gcc_cv_gas_minor_version= | |
a2f319ea | 4489 | gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas |
3ccc3a56 AO |
4490 | if test -x "$DEFAULT_ASSEMBLER"; then |
4491 | gcc_cv_as="$DEFAULT_ASSEMBLER" | |
4492 | elif test -x "$AS"; then | |
4493 | gcc_cv_as="$AS" | |
ab339d62 | 4494 | elif test -x as$host_exeext; then |
9e423e6d JW |
4495 | # Build using assembler in the current directory. |
4496 | gcc_cv_as=./as$host_exeext | |
5585c1bc | 4497 | elif test -f $gcc_cv_as_gas_srcdir/configure.in -a -f ../gas/Makefile; then |
9e423e6d | 4498 | # Single tree build which includes gas. |
a2c9d57c | 4499 | for f in $gcc_cv_as_gas_srcdir/configure $gcc_cv_as_gas_srcdir/configure.in $gcc_cv_as_gas_srcdir/Makefile.in |
9e423e6d | 4500 | do |
75bffa71 ILT |
4501 | changequote(,)dnl |
4502 | gcc_cv_gas_version=`grep '^VERSION=[0-9]*\.[0-9]*' $f` | |
4503 | changequote([,])dnl | |
4504 | if test x$gcc_cv_gas_version != x; then | |
9e423e6d JW |
4505 | break |
4506 | fi | |
4507 | done | |
75bffa71 ILT |
4508 | changequote(,)dnl |
4509 | gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"` | |
4510 | gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"` | |
4511 | changequote([,])dnl | |
981d4858 JM |
4512 | fi |
4513 | ||
4514 | if test "x$gcc_cv_as" = x -a x$host = x$target; then | |
9e423e6d | 4515 | # Native build. |
779243f7 JL |
4516 | # Search the same directories that the installed compiler will |
4517 | # search. Else we may find the wrong assembler and lose. If we | |
4518 | # do not find a suitable assembler binary, then try the user's | |
4519 | # path. | |
4520 | # | |
4521 | # Also note we have to check MD_EXEC_PREFIX before checking the | |
4522 | # user's path. Unfortunately, there is no good way to get at the | |
4523 | # value of MD_EXEC_PREFIX here. So we do a brute force search | |
4524 | # through all the known MD_EXEC_PREFIX values. Ugh. This needs | |
4525 | # to be fixed as part of the make/configure rewrite too. | |
4526 | ||
4527 | if test "x$exec_prefix" = xNONE; then | |
4528 | if test "x$prefix" = xNONE; then | |
4529 | test_prefix=/usr/local | |
4530 | else | |
4531 | test_prefix=$prefix | |
4532 | fi | |
4533 | else | |
4534 | test_prefix=$exec_prefix | |
4535 | fi | |
4536 | ||
4537 | # If the loop below does not find an assembler, then use whatever | |
4538 | # one we can find in the users's path. | |
4539 | # user's path. | |
4540 | as=as$host_exeext | |
4541 | ||
4542 | test_dirs="$test_prefix/lib/gcc-lib/$target/$gcc_version \ | |
4543 | $test_prefix/lib/gcc-lib/$target \ | |
4544 | /usr/lib/gcc/$target/$gcc_version \ | |
4545 | /usr/lib/gcc/$target \ | |
4546 | $test_prefix/$target/bin/$target/$gcc_version \ | |
4547 | $test_prefix/$target/bin \ | |
4548 | /usr/libexec \ | |
4549 | /usr/ccs/gcc \ | |
4550 | /usr/ccs/bin \ | |
4551 | /udk/usr/ccs/bin \ | |
4552 | /bsd43/usr/lib/cmplrs/cc \ | |
4553 | /usr/cross64/usr/bin \ | |
4554 | /usr/lib/cmplrs/cc \ | |
4555 | /sysv/usr/lib/cmplrs/cc \ | |
4556 | /svr4/usr/lib/cmplrs/cc \ | |
4557 | /usr/bin" | |
4558 | ||
4559 | for dir in $test_dirs; do | |
4560 | if test -f $dir/as$host_exeext; then | |
4561 | gcc_cv_as=$dir/as$host_exeext | |
4562 | break; | |
4563 | fi | |
4564 | done | |
9e423e6d | 4565 | fi |
981d4858 JM |
4566 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then |
4567 | AC_MSG_RESULT("newly built gas") | |
4568 | else | |
4569 | AC_MSG_RESULT($gcc_cv_as) | |
4570 | fi | |
4571 | ||
4572 | # Figure out what nm we will be using. | |
4573 | AC_MSG_CHECKING(what nm to use) | |
4574 | if test -x nm$host_exeext; then | |
4575 | gcc_cv_nm=./nm$host_exeext | |
4576 | elif test x$host = x$target; then | |
4577 | # Native build. | |
4578 | gcc_cv_nm=nm$host_exeext | |
4579 | fi | |
4580 | AC_MSG_RESULT($gcc_cv_nm) | |
4581 | ||
4582 | # Figure out what assembler alignment features are present. | |
4583 | AC_MSG_CHECKING(assembler alignment features) | |
4584 | gcc_cv_as_alignment_features= | |
4585 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then | |
4586 | # Gas version 2.6 and later support for .balign and .p2align. | |
4587 | # bytes to skip when using .p2align. | |
4588 | 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 | |
4589 | gcc_cv_as_alignment_features=".balign and .p2align" | |
4590 | AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN) | |
4591 | fi | |
4592 | # Gas version 2.8 and later support specifying the maximum | |
4593 | # bytes to skip when using .p2align. | |
4594 | 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 | |
4595 | gcc_cv_as_alignment_features=".p2align including maximum skip" | |
4596 | AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN) | |
4597 | fi | |
4598 | elif test x$gcc_cv_as != x; then | |
00ccc16d JL |
4599 | # Check if we have .balign and .p2align |
4600 | echo ".balign 4" > conftest.s | |
4601 | echo ".p2align 2" >> conftest.s | |
4602 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
4603 | gcc_cv_as_alignment_features=".balign and .p2align" | |
4604 | AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN) | |
4605 | fi | |
4606 | rm -f conftest.s conftest.o | |
9e423e6d JW |
4607 | # Check if specifying the maximum bytes to skip when |
4608 | # using .p2align is supported. | |
4609 | echo ".p2align 4,,7" > conftest.s | |
4610 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
4611 | gcc_cv_as_alignment_features=".p2align including maximum skip" | |
4612 | AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN) | |
4613 | fi | |
4614 | rm -f conftest.s conftest.o | |
4615 | fi | |
4616 | AC_MSG_RESULT($gcc_cv_as_alignment_features) | |
4617 | ||
d1accaa3 JJ |
4618 | AC_MSG_CHECKING(assembler subsection support) |
4619 | gcc_cv_as_subsections= | |
981d4858 JM |
4620 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then |
4621 | if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then | |
4622 | gcc_cv_as_subsections="working .subsection -1" | |
4623 | fi | |
4624 | elif test x$gcc_cv_as != x; then | |
d1accaa3 JJ |
4625 | # Check if we have .subsection |
4626 | echo ".subsection 1" > conftest.s | |
4627 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
4628 | gcc_cv_as_subsections=".subsection" | |
d1accaa3 JJ |
4629 | if test x$gcc_cv_nm != x; then |
4630 | cat > conftest.s <<EOF | |
4631 | conftest_label1: .word 0 | |
4632 | .subsection -1 | |
4633 | conftest_label2: .word 0 | |
4634 | .previous | |
4635 | EOF | |
4636 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
4637 | $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1 | |
4638 | $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2 | |
1b015bec AO |
4639 | if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1; then |
4640 | : | |
4641 | else | |
d1accaa3 | 4642 | gcc_cv_as_subsections="working .subsection -1" |
d1accaa3 JJ |
4643 | fi |
4644 | fi | |
4645 | fi | |
4646 | fi | |
4647 | rm -f conftest.s conftest.o conftest.nm1 conftest.nm2 | |
4648 | fi | |
981d4858 JM |
4649 | if test x"$gcc_cv_as_subsections" = x"working .subsection -1"; then |
4650 | AC_DEFINE(HAVE_GAS_SUBSECTION_ORDERING, 1, | |
4651 | [Define if your assembler supports .subsection and .subsection -1 starts | |
4652 | emitting at the beginning of your section.]) | |
4653 | fi | |
d1accaa3 JJ |
4654 | AC_MSG_RESULT($gcc_cv_as_subsections) |
4655 | ||
12822146 JL |
4656 | AC_MSG_CHECKING(assembler weak support) |
4657 | gcc_cv_as_weak= | |
981d4858 JM |
4658 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then |
4659 | if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 2 -o "$gcc_cv_gas_major_version" -gt 2; then | |
4660 | gcc_cv_as_weak="yes" | |
4661 | fi | |
4662 | elif test x$gcc_cv_as != x; then | |
12822146 JL |
4663 | # Check if we have .weak |
4664 | echo " .weak foobar" > conftest.s | |
4665 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
12822146 JL |
4666 | gcc_cv_as_weak="yes" |
4667 | fi | |
4668 | rm -f conftest.s conftest.o conftest.nm1 conftest.nm2 | |
4669 | fi | |
981d4858 JM |
4670 | if test x"$gcc_cv_as_weak" = xyes; then |
4671 | AC_DEFINE(HAVE_GAS_WEAK, 1, [Define if your assembler supports .weak.]) | |
4672 | fi | |
12822146 JL |
4673 | AC_MSG_RESULT($gcc_cv_as_weak) |
4674 | ||
6a9c5260 UD |
4675 | AC_MSG_CHECKING(assembler hidden support) |
4676 | gcc_cv_as_hidden= | |
981d4858 JM |
4677 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then |
4678 | if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 10 -o "$gcc_cv_gas_major_version" -gt 2 && grep 'obj_format = elf' ../gas/Makefile > /dev/null; then | |
4679 | gcc_cv_as_hidden="yes" | |
4680 | fi | |
4681 | elif test x$gcc_cv_as != x; then | |
6a9c5260 UD |
4682 | # Check if we have .hidden |
4683 | echo " .hidden foobar" > conftest.s | |
4684 | echo "foobar:" >> conftest.s | |
4685 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
6a9c5260 UD |
4686 | gcc_cv_as_hidden="yes" |
4687 | fi | |
4688 | rm -f conftest.s conftest.o conftest.nm1 conftest.nm2 | |
4689 | fi | |
981d4858 JM |
4690 | if test x"$gcc_cv_as_hidden" = xyes; then |
4691 | AC_DEFINE(HAVE_GAS_HIDDEN, 1, | |
4692 | [Define if your assembler supports .hidden.]) | |
4693 | fi | |
6a9c5260 UD |
4694 | AC_MSG_RESULT($gcc_cv_as_hidden) |
4695 | ||
1cb36a98 RH |
4696 | case "$target" in |
4697 | sparc*-*-*) | |
5b68c389 AO |
4698 | AC_CACHE_CHECK([assembler .register pseudo-op support], |
4699 | gcc_cv_as_register_pseudo_op, [ | |
4700 | gcc_cv_as_register_pseudo_op=unknown | |
4701 | if test x$gcc_cv_as != x; then | |
4702 | # Check if we have .register | |
4703 | echo ".register %g2, #scratch" > conftest.s | |
4704 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
1cb36a98 | 4705 | gcc_cv_as_register_pseudo_op=yes |
5b68c389 AO |
4706 | else |
4707 | gcc_cv_as_register_pseudo_op=no | |
4708 | fi | |
4709 | rm -f conftest.s conftest.o | |
1cb36a98 | 4710 | fi |
5b68c389 AO |
4711 | ]) |
4712 | if test "x$gcc_cv_as_register_pseudo_op" = xyes; then | |
119d24d1 KG |
4713 | AC_DEFINE(HAVE_AS_REGISTER_PSEUDO_OP, 1, |
4714 | [Define if your assembler supports .register.]) | |
1cb36a98 | 4715 | fi |
1cb36a98 | 4716 | |
e95b1e6a JJ |
4717 | AC_CACHE_CHECK([assembler supports -relax], |
4718 | gcc_cv_as_relax_opt, [ | |
4719 | gcc_cv_as_relax_opt=unknown | |
4720 | if test x$gcc_cv_as != x; then | |
4721 | # Check if gas supports -relax | |
4722 | echo ".text" > conftest.s | |
4723 | if $gcc_cv_as -relax -o conftest.o conftest.s > /dev/null 2>&1; then | |
4724 | gcc_cv_as_relax_opt=yes | |
4725 | else | |
4726 | gcc_cv_as_relax_opt=no | |
4727 | fi | |
4728 | rm -f conftest.s conftest.o | |
4729 | fi | |
4730 | ]) | |
4731 | if test "x$gcc_cv_as_relax_opt" = xyes; then | |
4732 | AC_DEFINE(HAVE_AS_RELAX_OPTION, 1, | |
4733 | [Define if your assembler supports -relax option.]) | |
4734 | fi | |
4735 | ||
5b68c389 AO |
4736 | case "$tm_file" in |
4737 | *64*) | |
4738 | AC_CACHE_CHECK([for 64 bit support in assembler ($gcc_cv_as)], | |
4739 | gcc_cv_as_flags64, [ | |
4740 | if test -n "$gcc_cv_as"; then | |
4741 | echo ".xword foo" > conftest.s | |
4742 | gcc_cv_as_flags64=no | |
8a90b95d | 4743 | for flag in "-xarch=v9" "-64 -Av9"; do |
5b68c389 AO |
4744 | if $gcc_cv_as $flag -o conftest.o conftest.s \ |
4745 | > /dev/null 2>&1; then | |
4746 | gcc_cv_as_flags64=$flag | |
4747 | break | |
4748 | fi | |
4749 | done | |
4750 | rm -f conftest.s conftest.o | |
4751 | else | |
4752 | if test "$gas" = yes; then | |
4753 | gcc_cv_as_flags64="-64 -Av9" | |
4754 | else | |
4755 | gcc_cv_as_flags64="-xarch=v9" | |
4756 | fi | |
1cb36a98 | 4757 | fi |
5b68c389 AO |
4758 | ]) |
4759 | if test "x$gcc_cv_as_flags64" = xno; then | |
4760 | changequote(, ) | |
4761 | tmake_file=`echo " $tmake_file " | sed -e 's, sparc/t-sol2-64 , ,' -e 's,^ ,,' -e 's, $,,'` | |
4762 | dep_tmake_file=`echo " $dep_tmake_file " | sed -e 's, [^ ]*/config/sparc/t-sol2-64 , ,' -e 's,^ ,,' -e 's, $,,'` | |
4763 | changequote([, ]) | |
4764 | else | |
119d24d1 KG |
4765 | AC_DEFINE_UNQUOTED(AS_SPARC64_FLAG, "$gcc_cv_as_flags64", |
4766 | [Define if the assembler supports 64bit sparc.]) | |
1cb36a98 | 4767 | fi |
5b68c389 AO |
4768 | ;; |
4769 | *) gcc_cv_as_flags64=${gcc_cv_as_flags64-no} | |
4770 | ;; | |
4771 | esac | |
4772 | ||
4773 | if test "x$gcc_cv_as_flags64" != xno; then | |
4774 | AC_CACHE_CHECK([for assembler offsetable %lo() support], | |
4775 | gcc_cv_as_offsetable_lo10, [ | |
4776 | gcc_cv_as_offsetable_lo10=unknown | |
4777 | if test "x$gcc_cv_as" != x; then | |
4778 | # Check if assembler has offsetable %lo() | |
4779 | echo "or %g1, %lo(ab) + 12, %g1" > conftest.s | |
4780 | echo "or %g1, %lo(ab + 12), %g1" > conftest1.s | |
4781 | if $gcc_cv_as $gcc_cv_as_flags64 -o conftest.o conftest.s \ | |
4782 | > /dev/null 2>&1 && | |
4783 | $gcc_cv_as $gcc_cv_as_flags64 -o conftest1.o conftest1.s \ | |
4784 | > /dev/null 2>&1; then | |
4785 | if cmp conftest.o conftest1.o > /dev/null 2>&1; then | |
4786 | gcc_cv_as_offsetable_lo10=no | |
4787 | else | |
4788 | gcc_cv_as_offsetable_lo10=yes | |
4789 | fi | |
4790 | else | |
4791 | gcc_cv_as_offsetable_lo10=no | |
1cb36a98 | 4792 | fi |
5b68c389 AO |
4793 | rm -f conftest.s conftest.o conftest1.s conftest1.o |
4794 | fi | |
4795 | ]) | |
4796 | if test "x$gcc_cv_as_offsetable_lo10" = xyes; then | |
119d24d1 KG |
4797 | AC_DEFINE(HAVE_AS_OFFSETABLE_LO10, 1, |
4798 | [Define if your assembler supports offsetable %lo().]) | |
1cb36a98 | 4799 | fi |
1cb36a98 | 4800 | fi |
1cb36a98 RH |
4801 | ;; |
4802 | ||
4803 | changequote(,)dnl | |
4804 | i[34567]86-*-*) | |
4805 | changequote([,])dnl | |
4806 | AC_MSG_CHECKING(assembler instructions) | |
4807 | gcc_cv_as_instructions= | |
981d4858 JM |
4808 | if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then |
4809 | if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 9 -o "$gcc_cv_gas_major_version" -gt 2; then | |
4810 | gcc_cv_as_instructions="filds fists" | |
4811 | fi | |
4812 | elif test x$gcc_cv_as != x; then | |
53b5ce19 JW |
4813 | set "filds fists" "filds mem; fists mem" |
4814 | while test $# -gt 0 | |
4815 | do | |
4816 | echo "$2" > conftest.s | |
4817 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
4818 | gcc_cv_as_instructions=${gcc_cv_as_instructions}$1" " | |
53b5ce19 JW |
4819 | fi |
4820 | shift 2 | |
4821 | done | |
4822 | rm -f conftest.s conftest.o | |
1cb36a98 | 4823 | fi |
981d4858 | 4824 | if test x"$gcc_cv_as_instructions" != x; then |
ee7692d2 | 4825 | AC_DEFINE_UNQUOTED(HAVE_GAS_`echo "$gcc_cv_as_instructions" | sed -e 's/ $//' | tr '[a-z ]' '[A-Z_]'`) |
981d4858 | 4826 | fi |
1cb36a98 RH |
4827 | AC_MSG_RESULT($gcc_cv_as_instructions) |
4828 | ;; | |
4829 | esac | |
53b5ce19 | 4830 | |
571a8de5 | 4831 | # Figure out what language subdirectories are present. |
71205e0b MH |
4832 | # Look if the user specified --enable-languages="..."; if not, use |
4833 | # the environment variable $LANGUAGES if defined. $LANGUAGES might | |
4834 | # go away some day. | |
4835 | if test x"${enable_languages+set}" != xset; then | |
4836 | if test x"${LANGUAGES+set}" = xset; then | |
4837 | enable_languages="`echo ${LANGUAGES} | tr ' ' ','`" | |
4838 | else | |
4839 | enable_languages=all | |
4840 | fi | |
d6c6b553 PE |
4841 | else |
4842 | if test x"${enable_languages}" = x; then | |
4843 | AC_MSG_ERROR([--enable-languages needs at least one argument]) | |
4844 | fi | |
71205e0b | 4845 | fi |
571a8de5 DE |
4846 | subdirs= |
4847 | for lang in ${srcdir}/*/config-lang.in .. | |
4848 | do | |
4849 | case $lang in | |
4850 | ..) ;; | |
4851 | # The odd quoting in the next line works around | |
4852 | # an apparent bug in bash 1.12 on linux. | |
75bffa71 ILT |
4853 | changequote(,)dnl |
4854 | ${srcdir}/[*]/config-lang.in) ;; | |
71205e0b MH |
4855 | *) |
4856 | lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang` | |
4857 | if test "x$lang_alias" = x | |
4858 | then | |
4859 | echo "$lang doesn't set \$language." 1>&2 | |
4860 | exit 1 | |
4861 | fi | |
a7b4171a | 4862 | if test x"${enable_languages}" = xall && test x"${lang_alias}" != xCHILL; then |
71205e0b MH |
4863 | add_this_lang=yes |
4864 | else | |
4865 | case "${enable_languages}" in | |
4866 | ${lang_alias} | "${lang_alias},"* | *",${lang_alias},"* | *",${lang_alias}" ) | |
4867 | add_this_lang=yes | |
4868 | ;; | |
4869 | * ) | |
4870 | add_this_lang=no | |
4871 | ;; | |
4872 | esac | |
4873 | fi | |
4874 | if test x"${add_this_lang}" = xyes; then | |
4875 | case $lang in | |
4876 | ${srcdir}/ada/config-lang.in) | |
4877 | if test x$gnat = xyes ; then | |
4878 | subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`" | |
4879 | fi | |
4880 | ;; | |
4881 | *) | |
4882 | subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`" | |
4883 | ;; | |
4884 | esac | |
4885 | fi | |
4886 | ;; | |
75bffa71 | 4887 | changequote([,])dnl |
571a8de5 DE |
4888 | esac |
4889 | done | |
4890 | ||
f24af81b TT |
4891 | # Make gthr-default.h if we have a thread file. |
4892 | gthread_flags= | |
75bffa71 | 4893 | if test $thread_file != single; then |
f24af81b | 4894 | rm -f gthr-default.h |
db0d1ed9 | 4895 | echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h |
f24af81b TT |
4896 | gthread_flags=-DHAVE_GTHR_DEFAULT |
4897 | fi | |
4898 | AC_SUBST(gthread_flags) | |
4899 | ||
81bf3d9e RH |
4900 | # Find out what GC implementation we want, or may, use. |
4901 | AC_ARG_WITH(gc, | |
4902 | [ --with-gc={simple,page} Choose the garbage collection mechanism to use | |
4903 | with the compiler.], | |
4904 | [case "$withval" in | |
4905 | simple | page) | |
4906 | GGC=ggc-$withval | |
4907 | ;; | |
4908 | *) | |
4909 | AC_MSG_ERROR([$withval is an invalid option to --with-gc]) | |
4910 | ;; | |
4911 | esac], | |
4acab94b AO |
4912 | [if test $ac_cv_func_mmap_anywhere = yes \ |
4913 | || test $ac_cv_func_valloc = yes; then | |
005537df | 4914 | GGC=ggc-page |
81bf3d9e RH |
4915 | else |
4916 | GGC=ggc-simple | |
4917 | fi]) | |
4918 | AC_SUBST(GGC) | |
4919 | echo "Using $GGC for garbage collection." | |
4920 | ||
3c809ba4 | 4921 | # Use the system's zlib library. |
b8dad04b ZW |
4922 | zlibdir=-L../zlib |
4923 | zlibinc="-I\$(srcdir)/../zlib" | |
3c809ba4 AG |
4924 | AC_ARG_WITH(system-zlib, |
4925 | [ --with-system-zlib use installed libz], | |
4926 | zlibdir= | |
4927 | zlibinc= | |
4928 | ) | |
4929 | AC_SUBST(zlibdir) | |
4930 | AC_SUBST(zlibinc) | |
4931 | ||
7441a352 NS |
4932 | # Build a new-abi (c++) system |
4933 | AC_ARG_ENABLE(new-gxx-abi, | |
4934 | [ --enable-new-gxx-abi | |
4935 | select the new abi for g++. You must select an ABI | |
4936 | at configuration time, so that the correct runtime | |
4937 | support is built. You cannot mix ABIs.], | |
119d24d1 KG |
4938 | [AC_DEFINE(ENABLE_NEW_GXX_ABI, 1, |
4939 | [Define if you want to always select the new-abi for g++.]) | |
7441a352 NS |
4940 | GXX_ABI_FLAG='-fnew-abi' |
4941 | echo "Building a new-abi g++ compiler." | |
4942 | ]) | |
4943 | AC_SUBST(GXX_ABI_FLAG) | |
4944 | ||
7822500a BK |
4945 | # Build a new-libstdc++ system (ie libstdc++-v3) |
4946 | AC_MSG_CHECKING([for libstdc++ to install]) | |
4947 | AC_ARG_ENABLE(libstdcxx-v3, | |
4948 | [ --enable-libstdcxx-v3 | |
4949 | enable libstdc++-v3 for building and installation], | |
34f6fbdb | 4950 | [enable_libstdcxx_v3="$enableval"], [enable_libstdcxx_v3=yes]) |
7822500a BK |
4951 | |
4952 | if test x$enable_libstdcxx_v3 = xyes; then | |
4953 | AC_MSG_RESULT(v3) | |
be5aeb60 | 4954 | HAVE_LIBSTDCXX_V3=1 |
119d24d1 | 4955 | ac_esn=1 |
7822500a BK |
4956 | else |
4957 | AC_MSG_RESULT(v2) | |
be5aeb60 | 4958 | HAVE_LIBSTDCXX_V3=0 |
119d24d1 | 4959 | ac_esn=0 |
7822500a | 4960 | fi |
119d24d1 KG |
4961 | AC_DEFINE_UNQUOTED(ENABLE_STD_NAMESPACE, $ac_esn, |
4962 | [Define to 1 if you want to enable namespaces (-fhonor-std) by default.]) | |
be5aeb60 | 4963 | AC_SUBST(HAVE_LIBSTDCXX_V3) |
7822500a | 4964 | |
dc6746e7 PT |
4965 | dnl Very limited version of automake's enable-maintainer-mode |
4966 | ||
4967 | AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) | |
4968 | dnl maintainer-mode is disabled by default | |
4969 | AC_ARG_ENABLE(maintainer-mode, | |
4970 | [ --enable-maintainer-mode enable make rules and dependencies not useful | |
4971 | (and sometimes confusing) to the casual installer], | |
4972 | maintainer_mode=$enableval, | |
4973 | maintainer_mode=no) | |
4974 | ||
4975 | AC_MSG_RESULT($maintainer_mode) | |
4976 | ||
4977 | if test "$maintainer_mode" = "yes"; then | |
4978 | MAINT='' | |
4979 | else | |
4980 | MAINT='#' | |
4981 | fi | |
4982 | AC_SUBST(MAINT)dnl | |
4983 | ||
571a8de5 DE |
4984 | # Make empty files to contain the specs and options for each language. |
4985 | # Then add #include lines to for a compiler that has specs and/or options. | |
4986 | ||
4987 | lang_specs_files= | |
4988 | lang_options_files= | |
3103b7db ML |
4989 | lang_tree_files= |
4990 | rm -f specs.h options.h gencheck.h | |
4991 | touch specs.h options.h gencheck.h | |
571a8de5 DE |
4992 | for subdir in . $subdirs |
4993 | do | |
75bffa71 | 4994 | if test -f $srcdir/$subdir/lang-specs.h; then |
571a8de5 DE |
4995 | echo "#include \"$subdir/lang-specs.h\"" >>specs.h |
4996 | lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h" | |
4997 | fi | |
75bffa71 | 4998 | if test -f $srcdir/$subdir/lang-options.h; then |
571a8de5 DE |
4999 | echo "#include \"$subdir/lang-options.h\"" >>options.h |
5000 | lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h" | |
5001 | fi | |
3103b7db ML |
5002 | if test -f $srcdir/$subdir/$subdir-tree.def; then |
5003 | echo "#include \"$subdir/$subdir-tree.def\"" >>gencheck.h | |
5004 | lang_tree_files="$lang_tree_files $srcdir/$subdir/$subdir-tree.def" | |
5005 | fi | |
571a8de5 DE |
5006 | done |
5007 | ||
5008 | # These (without "all_") are set in each config-lang.in. | |
5009 | # `language' must be a single word so is spelled singularly. | |
5010 | all_languages= | |
5011 | all_boot_languages= | |
5012 | all_compilers= | |
5013 | all_stagestuff= | |
5014 | all_diff_excludes= | |
3ec83fc2 | 5015 | all_outputs='Makefile intl/Makefile po/Makefile.in fixinc/Makefile gccbug mklibgcc' |
571a8de5 DE |
5016 | # List of language makefile fragments. |
5017 | all_lang_makefiles= | |
5018 | all_headers= | |
5019 | all_lib2funcs= | |
5020 | ||
5021 | # Add the language fragments. | |
5022 | # Languages are added via two mechanisms. Some information must be | |
5023 | # recorded in makefile variables, these are defined in config-lang.in. | |
5024 | # We accumulate them and plug them into the main Makefile. | |
5025 | # The other mechanism is a set of hooks for each of the main targets | |
5026 | # like `clean', `install', etc. | |
5027 | ||
5028 | language_fragments="Make-lang" | |
5029 | language_hooks="Make-hooks" | |
5030 | ||
5031 | for s in .. $subdirs | |
5032 | do | |
75bffa71 | 5033 | if test $s != ".." |
571a8de5 DE |
5034 | then |
5035 | language= | |
5036 | boot_language= | |
5037 | compilers= | |
5038 | stagestuff= | |
5039 | diff_excludes= | |
5040 | headers= | |
0280cf84 | 5041 | outputs= |
571a8de5 DE |
5042 | lib2funcs= |
5043 | . ${srcdir}/$s/config-lang.in | |
75bffa71 | 5044 | if test "x$language" = x |
571a8de5 DE |
5045 | then |
5046 | echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2 | |
5047 | exit 1 | |
5048 | fi | |
72aaffbd ZW |
5049 | all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in" |
5050 | if test -f ${srcdir}/$s/Makefile.in | |
5051 | then all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Makefile.in" | |
5052 | fi | |
571a8de5 | 5053 | all_languages="$all_languages $language" |
75bffa71 | 5054 | if test "x$boot_language" = xyes |
571a8de5 DE |
5055 | then |
5056 | all_boot_languages="$all_boot_languages $language" | |
5057 | fi | |
5058 | all_compilers="$all_compilers $compilers" | |
5059 | all_stagestuff="$all_stagestuff $stagestuff" | |
5060 | all_diff_excludes="$all_diff_excludes $diff_excludes" | |
5061 | all_headers="$all_headers $headers" | |
0280cf84 | 5062 | all_outputs="$all_outputs $outputs" |
571a8de5 DE |
5063 | all_lib2funcs="$all_lib2funcs $lib2funcs" |
5064 | fi | |
5065 | done | |
5066 | ||
5067 | # Since we can't use `::' targets, we link each language in | |
5068 | # with a set of hooks, reached indirectly via lang.${target}. | |
5069 | ||
5070 | rm -f Make-hooks | |
5071 | touch Make-hooks | |
5072 | target_list="all.build all.cross start.encap rest.encap \ | |
5073 | info dvi \ | |
5074 | install-normal install-common install-info install-man \ | |
436a88a6 | 5075 | uninstall \ |
571a8de5 DE |
5076 | mostlyclean clean distclean extraclean maintainer-clean \ |
5077 | stage1 stage2 stage3 stage4" | |
5078 | for t in $target_list | |
5079 | do | |
5080 | x= | |
ab87f8c8 | 5081 | for lang in .. $all_languages |
571a8de5 | 5082 | do |
ab87f8c8 JL |
5083 | if test $lang != ".."; then |
5084 | x="$x $lang.$t" | |
571a8de5 DE |
5085 | fi |
5086 | done | |
5087 | echo "lang.$t: $x" >> Make-hooks | |
5088 | done | |
5089 | ||
296e46bd DE |
5090 | # If we're not building in srcdir, create .gdbinit. |
5091 | ||
75bffa71 | 5092 | if test ! -f Makefile.in; then |
296e46bd DE |
5093 | echo "dir ." > .gdbinit |
5094 | echo "dir ${srcdir}" >> .gdbinit | |
75bffa71 | 5095 | if test x$gdb_needs_out_file_path = xyes |
296e46bd DE |
5096 | then |
5097 | echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit | |
5098 | fi | |
75bffa71 | 5099 | if test "x$subdirs" != x; then |
296e46bd DE |
5100 | for s in $subdirs |
5101 | do | |
5102 | echo "dir ${srcdir}/$s" >> .gdbinit | |
5103 | done | |
5104 | fi | |
5105 | echo "source ${srcdir}/.gdbinit" >> .gdbinit | |
5106 | fi | |
5107 | ||
88111b26 JL |
5108 | # Define variables host_canonical and build_canonical |
5109 | # because some Cygnus local changes in the Makefile depend on them. | |
5110 | build_canonical=${build} | |
5111 | host_canonical=${host} | |
5112 | target_subdir= | |
75bffa71 | 5113 | if test "${host}" != "${target}" ; then |
88111b26 JL |
5114 | target_subdir=${target}/ |
5115 | fi | |
5116 | AC_SUBST(build_canonical) | |
5117 | AC_SUBST(host_canonical) | |
5118 | AC_SUBST(target_subdir) | |
5119 | ||
8f8d3278 NC |
5120 | # If $(exec_prefix) exists and is not the same as $(prefix), then compute an |
5121 | # absolute path for gcc_tooldir based on inserting the number of up-directory | |
5122 | # movements required to get from $(exec_prefix) to $(prefix) into the basic | |
5123 | # $(libsubdir)/@(unlibsubdir) based path. | |
82cbf8f7 JL |
5124 | # Don't set gcc_tooldir to tooldir since that's only passed in by the toplevel |
5125 | # make and thus we'd get different behavior depending on where we built the | |
5126 | # sources. | |
5949a9fc | 5127 | if test x$exec_prefix = xNONE -o x$exec_prefix = x$prefix; then |
d062c304 JL |
5128 | gcc_tooldir='$(libsubdir)/$(unlibsubdir)/../$(target_alias)' |
5129 | else | |
8f8d3278 NC |
5130 | changequote(<<, >>)dnl |
5131 | # An explanation of the sed strings: | |
5132 | # -e 's|^\$(prefix)||' matches and eliminates 'prefix' from 'exec_prefix' | |
5133 | # -e 's|/$||' match a trailing forward slash and eliminates it | |
5134 | # -e 's|^[^/]|/|' forces the string to start with a forward slash (*) | |
5135 | # -e 's|/[^/]*|../|g' replaces each occurance of /<directory> with ../ | |
5136 | # | |
5137 | # (*) Note this pattern overwrites the first character of the string | |
5138 | # with a forward slash if one is not already present. This is not a | |
5139 | # problem because the exact names of the sub-directories concerned is | |
5140 | # unimportant, just the number of them matters. | |
5141 | # | |
5142 | # The practical upshot of these patterns is like this: | |
5143 | # | |
5144 | # prefix exec_prefix result | |
5145 | # ------ ----------- ------ | |
5146 | # /foo /foo/bar ../ | |
5147 | # /foo/ /foo/bar ../ | |
5148 | # /foo /foo/bar/ ../ | |
5149 | # /foo/ /foo/bar/ ../ | |
5150 | # /foo /foo/bar/ugg ../../ | |
5151 | # | |
4c112cda NC |
5152 | dollar='$$' |
5153 | gcc_tooldir="\$(libsubdir)/\$(unlibsubdir)/\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/\$(dollar)||' -e 's|^[^/]|/|' -e 's|/[^/]*|../|g'\`\$(target_alias)" | |
8f8d3278 | 5154 | changequote([, ])dnl |
d062c304 JL |
5155 | fi |
5156 | AC_SUBST(gcc_tooldir) | |
4c112cda | 5157 | AC_SUBST(dollar) |
d062c304 | 5158 | |
7e717196 JL |
5159 | # Nothing to do for FLOAT_H, float_format already handled. |
5160 | objdir=`pwd` | |
5161 | AC_SUBST(objdir) | |
5162 | ||
94f42018 DE |
5163 | # Process the language and host/target makefile fragments. |
5164 | ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file" | |
47866ac0 | 5165 | |
46f18e7b RK |
5166 | # Substitute configuration variables |
5167 | AC_SUBST(subdirs) | |
46f18e7b RK |
5168 | AC_SUBST(all_boot_languages) |
5169 | AC_SUBST(all_compilers) | |
46f18e7b | 5170 | AC_SUBST(all_diff_excludes) |
46f18e7b | 5171 | AC_SUBST(all_headers) |
9f3d1bc2 BK |
5172 | AC_SUBST(all_lang_makefiles) |
5173 | AC_SUBST(all_languages) | |
5174 | AC_SUBST(all_lib2funcs) | |
5175 | AC_SUBST(all_stagestuff) | |
5176 | AC_SUBST(build_exeext) | |
5177 | AC_SUBST(build_install_headers_dir) | |
5178 | AC_SUBST(build_xm_file_list) | |
5179 | AC_SUBST(cc_set_by_configure) | |
5aa82ace | 5180 | AC_SUBST(quoted_cc_set_by_configure) |
9f3d1bc2 | 5181 | AC_SUBST(cpp_install_dir) |
9f3d1bc2 BK |
5182 | AC_SUBST(dep_host_xmake_file) |
5183 | AC_SUBST(dep_tmake_file) | |
5184 | AC_SUBST(extra_c_flags) | |
9f3d1bc2 | 5185 | AC_SUBST(extra_headers_list) |
46f18e7b | 5186 | AC_SUBST(extra_objs) |
9f3d1bc2 BK |
5187 | AC_SUBST(extra_parts) |
5188 | AC_SUBST(extra_passes) | |
5189 | AC_SUBST(extra_programs) | |
9f3d1bc2 | 5190 | AC_SUBST(float_h_file) |
cc1e60ea | 5191 | AC_SUBST(gcc_config_arguments) |
9f3d1bc2 BK |
5192 | AC_SUBST(gcc_gxx_include_dir) |
5193 | AC_SUBST(gcc_version) | |
8763704d | 5194 | AC_SUBST(gcc_version_full) |
9f3d1bc2 BK |
5195 | AC_SUBST(gcc_version_trigger) |
5196 | AC_SUBST(host_exeext) | |
46f18e7b | 5197 | AC_SUBST(host_extra_gcc_objs) |
46f18e7b | 5198 | AC_SUBST(host_xm_file_list) |
9f3d1bc2 | 5199 | AC_SUBST(install) |
46f18e7b | 5200 | AC_SUBST(lang_options_files) |
9f3d1bc2 | 5201 | AC_SUBST(lang_specs_files) |
3103b7db | 5202 | AC_SUBST(lang_tree_files) |
46f18e7b | 5203 | AC_SUBST(local_prefix) |
46f18e7b | 5204 | AC_SUBST(maybe_use_collect2) |
9f3d1bc2 BK |
5205 | AC_SUBST(md_file) |
5206 | AC_SUBST(objc_boehm_gc) | |
5207 | AC_SUBST(out_file) | |
5208 | AC_SUBST(out_object_file) | |
46f18e7b | 5209 | AC_SUBST(stage_prefix_set_by_configure) |
e9a25f70 | 5210 | AC_SUBST(symbolic_link) |
9f3d1bc2 BK |
5211 | AC_SUBST(thread_file) |
5212 | AC_SUBST(tm_file_list) | |
5213 | AC_SUBST(will_use_collect2) | |
9fc9b82a | 5214 | |
46f18e7b RK |
5215 | |
5216 | AC_SUBST_FILE(target_overrides) | |
5217 | AC_SUBST_FILE(host_overrides) | |
5218 | AC_SUBST(cross_defines) | |
5219 | AC_SUBST_FILE(cross_overrides) | |
5220 | AC_SUBST_FILE(build_overrides) | |
5221 | AC_SUBST_FILE(language_fragments) | |
5222 | AC_SUBST_FILE(language_hooks) | |
5223 | ||
5224 | # Echo that links are built | |
75bffa71 | 5225 | if test x$host = x$target |
46f18e7b RK |
5226 | then |
5227 | str1="native " | |
5228 | else | |
5229 | str1="cross-" | |
5230 | str2=" from $host" | |
5231 | fi | |
5232 | ||
75bffa71 | 5233 | if test x$host != x$build |
46f18e7b RK |
5234 | then |
5235 | str3=" on a $build system" | |
5236 | fi | |
5237 | ||
75bffa71 | 5238 | if test "x$str2" != x || test "x$str3" != x |
46f18e7b RK |
5239 | then |
5240 | str4= | |
5241 | fi | |
5242 | ||
5243 | echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2 | |
5244 | ||
75bffa71 | 5245 | if test "x$str2" != x || test "x$str3" != x |
46f18e7b RK |
5246 | then |
5247 | echo " ${str2}${str3}." 1>&2 | |
5248 | fi | |
5249 | ||
61536478 | 5250 | # Truncate the target if necessary |
75bffa71 | 5251 | if test x$host_truncate_target != x; then |
61536478 JL |
5252 | target=`echo $target | sed -e 's/\(..............\).*/\1/'` |
5253 | fi | |
5254 | ||
46f18e7b RK |
5255 | # Configure the subdirectories |
5256 | # AC_CONFIG_SUBDIRS($subdirs) | |
5257 | ||
5258 | # Create the Makefile | |
5891b37d | 5259 | # and configure language subdirectories |
0280cf84 | 5260 | AC_OUTPUT($all_outputs, |
cdcc6a01 | 5261 | [ |
cdcc6a01 | 5262 | case x$CONFIG_HEADERS in |
b7cb92ad | 5263 | xauto-host.h:config.in) |
818b66cc | 5264 | echo > cstamp-h ;; |
cdcc6a01 | 5265 | esac |
93cf819d BK |
5266 | # If the host supports symlinks, point stage[1234] at ../stage[1234] so |
5267 | # bootstrapping and the installation procedure can still use | |
5268 | # CC="stage1/xgcc -Bstage1/". If the host doesn't support symlinks, | |
5269 | # FLAGS_TO_PASS has been modified to solve the problem there. | |
5270 | # This is virtually a duplicate of what happens in configure.lang; we do | |
5271 | # an extra check to make sure this only happens if ln -s can be used. | |
75bffa71 | 5272 | if test "$symbolic_link" = "ln -s"; then |
93cf819d | 5273 | for d in .. ${subdirs} ; do |
75bffa71 | 5274 | if test $d != ..; then |
4e8a434e BK |
5275 | STARTDIR=`pwd` |
5276 | cd $d | |
5277 | for t in stage1 stage2 stage3 stage4 include | |
5278 | do | |
5279 | rm -f $t | |
5280 | $symbolic_link ../$t $t 2>/dev/null | |
5281 | done | |
5282 | cd $STARTDIR | |
93cf819d BK |
5283 | fi |
5284 | done | |
5285 | else true ; fi | |
ab87f8c8 JL |
5286 | # Avoid having to add intl to our include paths. |
5287 | if test -f intl/libintl.h; then | |
5288 | echo creating libintl.h | |
5289 | echo '#include "intl/libintl.h"' >libintl.h | |
5290 | fi | |
cdcc6a01 DE |
5291 | ], |
5292 | [ | |
5891b37d RK |
5293 | host='${host}' |
5294 | build='${build}' | |
5295 | target='${target}' | |
52060267 | 5296 | target_alias='${target_alias}' |
5891b37d RK |
5297 | srcdir='${srcdir}' |
5298 | subdirs='${subdirs}' | |
5299 | symbolic_link='${symbolic_link}' | |
5300 | program_transform_set='${program_transform_set}' | |
5301 | program_transform_name='${program_transform_name}' | |
5891b37d RK |
5302 | dep_host_xmake_file='${dep_host_xmake_file}' |
5303 | host_xmake_file='${host_xmake_file}' | |
5304 | dep_tmake_file='${dep_tmake_file}' | |
5305 | tmake_file='${tmake_file}' | |
0bbb1697 | 5306 | thread_file='${thread_file}' |
cc1e60ea | 5307 | gcc_config_arguments='${gcc_config_arguments}' |
f1943b77 | 5308 | gcc_version='${gcc_version}' |
8763704d | 5309 | gcc_version_full='${gcc_version_full}' |
f1943b77 | 5310 | gcc_version_trigger='${gcc_version_trigger}' |
5891b37d | 5311 | local_prefix='${local_prefix}' |
5891b37d | 5312 | build_install_headers_dir='${build_install_headers_dir}' |
a204adc6 | 5313 | build_exeext='${build_exeext}' |
6e26218f | 5314 | host_exeext='${host_exeext}' |
7ed46111 | 5315 | out_file='${out_file}' |
5891b37d RK |
5316 | gdb_needs_out_file_path='${gdb_needs_out_file_path}' |
5317 | SET_MAKE='${SET_MAKE}' | |
5891b37d | 5318 | target_list='${target_list}' |
5891b37d RK |
5319 | target_overrides='${target_overrides}' |
5320 | host_overrides='${host_overrides}' | |
5321 | cross_defines='${cross_defines}' | |
5322 | cross_overrides='${cross_overrides}' | |
5323 | build_overrides='${build_overrides}' | |
9fc9b82a | 5324 | cpp_install_dir='${cpp_install_dir}' |
cdcc6a01 | 5325 | ]) |