OSDN Git Service

9c7b85aab67a0e85981d163c27e5113d98d75e71
[pf3gnuchains/gcc-fork.git] / gcc / config.host
1 # GCC host-specific configuration file.
2 # Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003
3 # Free Software Foundation, Inc.
4
5 #This file is part of GCC.
6
7 #GCC is free software; you can redistribute it and/or modify it under
8 #the terms of the GNU General Public License as published by the Free
9 #Software Foundation; either version 2, or (at your option) any later
10 #version.
11
12 #GCC is distributed in the hope that it will be useful, but WITHOUT
13 #ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 #FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15 #for more details.
16
17 #You should have received a copy of the GNU General Public License
18 #along with GCC; see the file COPYING.  If not, write to the Free
19 #Software Foundation, 59 Temple Place - Suite 330, Boston, MA
20 #02111-1307, USA.
21
22 # This is the GCC host-specific configuration file
23 # where a configuration type is mapped to different system-specific
24 # definitions and files.  This is invoked by the autoconf-generated
25 # configure script.  Putting it in a separate shell file lets us skip
26 # running autoconf when modifying host-specific information.
27
28 # This file switches on the shell variable ${host}.  As much of this as
29 # is reasonable should be replaced with autoconf tests in the future.
30
31 # This file sets the following shell variables for use by the
32 # autoconf-generated configure script:
33 #
34 #  host_xm_file         List of files to include when compiling for the
35 #                       host machine.
36 #
37 #  host_xm_defines      List of macros to define when compiling for the
38 #                       host machine.
39 #
40 #  host_xmake_file      List of host-specific makefile-fragments.
41 #
42 #  host_exeext          Set to the suffix, if the host machine requires
43 #                       executables to have a file name suffix.
44 #
45 #  host_extra_objs      List of extra host-dependent objects that should
46 #                       be linked into the compiler proper.
47 #
48 #  host_extra_gcc_objs  List of extra host-dependent objects that should
49 #                       be linked into the gcc driver.
50 #
51 #  out_host_hook_obj    An object file that provides the host hooks.
52
53 # When setting any of these variables, check to see if a corresponding
54 # variable is present in config.build; if so, you will likely want to 
55 # set it in both places.
56
57 # Default settings.
58 host_xm_file=
59 host_xm_defines=
60 host_xmake_file=
61 host_exeext=
62 host_extra_objs=
63 host_extra_gcc_objs=
64 out_host_hook_obj=host-default.o
65
66 # Obsolete configurations.
67 case ${host} in
68  dummy)
69     if test "x$enable_obsolete" != xyes; then
70       echo "*** Configuration for host ${host} is obsolete." >&2
71       echo "*** Specify --enable-obsolete to build it anyway." >&2
72       echo "*** Support will be REMOVED in the next major release of GCC," >&2
73       echo "*** unless a maintainer comes forward." >&2
74       exit 1
75     fi
76     ;;
77 esac
78
79 # Unsupported hosts list.  Do not put an entry in this list unless
80 # it would otherwise be caught by a more permissive pattern.  The list
81 # should be in alphabetical order.
82 case ${host} in
83    alpha*-*-linux*libc1* \
84  | i[34567]86-sequent-sysv \
85  | i[34567]86-sequent-sysv[123]* \
86  | i[34567]86-go32-* \
87  | i[34567]86-*-go32* \
88  | m68k-*-linux*aout* \
89  | m68k-*-linux*libc1* \
90  | mips64orion*-*-rtems* \
91  | powerpc-*-linux*libc1* \
92  | sparc-*-linux*aout* \
93  | sparc-*-linux*libc1* \
94  | sparc-hal-solaris2* \
95  | thumb-*-* \
96  | *-*-linux*coff* \
97  | *-*-linux*oldld* \
98  | *-*-rtemsaout* \
99  | *-*-rtemscoff* \
100  )
101     echo "*** Configuration for host ${host} not supported" 1>&2
102     exit 1
103     ;;
104 esac
105
106 # Machine-specific settings.
107 case ${host} in
108   alpha*-*-unicosmk*)
109     ;;
110   alpha*-*-linux*)
111     ;;
112   alpha*-*-gnu*)
113     ;;
114   alpha*-*-freebsd*)
115     ;;
116   alpha*-*-netbsd*)
117     ;;
118   alpha*-*-openbsd*)
119     ;;
120   alpha*-dec-osf[45]*)
121     ;;
122   alpha*-dec-*vms*)
123     host_xm_file=alpha/xm-vms.h
124     host_xmake_file=alpha/x-vms
125     host_exeext=.exe
126     # This removes the cpu type and manufacturer components and
127     #  replaces "." with "_" in the operating system version.
128     target_alias=`echo $host | sed 's/.*-.*-\(.*\)$/\1/' | sed 's/\./_/g'`
129     prefix=/gnu
130     local_prefix=/gnu
131     ;;
132   arc-*-elf*)
133     ;;
134   arm-*-coff* | armel-*-coff*)
135     ;;
136   arm-semi-aof | armel-semi-aof)
137     ;;
138   arm*-*-freebsd*|strongarm*-*-freebsd*)
139     ;;
140   arm*-*-netbsdelf*)
141     ;;
142   arm*-*-netbsd*)
143     ;;
144   arm*-*-linux*) # ARM GNU/Linux with ELF
145     ;;
146   arm*-*-uclinux*) # ARM ucLinux
147     ;;
148   arm*-*-ecos-elf)
149     ;;
150   arm*-*-rtems*)
151     ;;
152   arm*-*-elf | ep9312-*-elf)
153     ;;
154   arm*-wince-pe*)
155     ;;
156   arm-*-pe*)
157     ;;
158   arm*-*-kaos*)
159     ;;
160   avr-*-*)
161     ;;
162   c4x-*-rtems* | tic4x-*-rtems*)
163     ;;
164   c4x-* | tic4x-*)
165     ;;
166   cris-*-aout)
167     ;;
168   cris-*-elf | cris-*-none)
169     ;;
170   cris-*-linux*)
171     ;;
172   d30v-*)
173     ;;
174   dsp16xx-*)
175     ;;
176   fr30-*-elf)
177     ;;
178   frv-*-elf)
179     ;;
180   h8300-*-rtems*)
181     ;;
182   h8300-*-elf*)
183     ;;
184   h8300-*-*)
185     ;;
186   hppa*64*-*-linux* | parisc*64*-*-linux*)
187     ;;
188   hppa*-*-linux* | parisc*-*-linux*)
189     ;;
190 #  port not yet contributed.
191 #  hppa*-*-openbsd*)
192 #    ;;
193   hppa1.1-*-pro*)
194     host_xmake_file="pa/x-ada"
195     ;;
196   hppa1.1-*-osf*)
197     host_xmake_file="pa/x-ada"
198     ;;
199   hppa1.1-*-rtems*)
200     host_xmake_file="pa/x-ada"
201     ;;
202   hppa1.1-*-bsd*)
203     host_xmake_file="pa/x-ada"
204     ;;
205   hppa1.1-*-hpux10* | hppa2*-*-hpux10*)
206     host_xmake_file="pa/x-ada"
207     ;;
208   hppa1.0-*-hpux10*)
209     host_xmake_file="pa/x-ada"
210     ;;
211   hppa*64*-*-hpux11*)
212     host_xmake_file="pa/x-ada"
213     ;;
214   hppa1.1-*-hpux11* | hppa2*-*-hpux11*)
215     host_xmake_file="pa/x-ada"
216     ;;
217   hppa1.0-*-hpux11*)
218     host_xmake_file="pa/x-ada"
219     ;;
220   i370-*-opened*) # IBM 360/370/390 Architecture
221     host_xm_defines='FATAL_EXIT_CODE=12'
222     ;;
223   i370-*-mvs*)
224     host_xm_defines='FATAL_EXIT_CODE=12'
225     ;;
226   i370-*-linux*)
227     ;;
228   i[34567]86-*-darwin*)
229     ;;
230   i[34567]86-*-elf*)
231     ;;
232   i[34567]86-ncr-sysv4*) # NCR 3000 - ix86 running system V.4
233     host_xm_defines="SMALL_ARG_MAX"
234     ;;
235   i[34567]86-*-netware) # Intel 80386's running netware
236     ;;
237   i[34567]86-sequent-ptx4* | i[34567]86-sequent-sysv4*)
238     host_xm_defines="SMALL_ARG_MAX"
239     ;;
240   i[34567]86-*-aout*)
241     ;;
242   i[34567]86-*-beoself* | i[34567]86-*-beos*)
243     ;;
244   i[34567]86-*-freebsd2 | i[34567]86-*-freebsd2.* | i[34567]86-*-freebsd*aout*)
245     ;;
246   i[34567]86-*-freebsd*)
247     ;;
248   x86_64-*-freebsd*)
249     ;;
250   i[34567]86-*-netbsdelf*)
251     ;;
252   i[34567]86-*-netbsd*)
253     ;;
254   x86_64-*-netbsd*)
255     ;;
256   i[34567]86-*-openbsd*)
257     ;;
258   i[34567]86-*-coff*)
259     ;;
260   i[34567]86-*-linux*aout*) # Intel 80386's running GNU/Linux with a.out format
261     ;;
262   i[34567]86-*-linux*libc1) # Intel 80386's running GNU/Linux
263                             # with ELF format using the
264                             # GNU/Linux C library 5
265     ;;
266   i[34567]86-*-linux*) # Intel 80386's running GNU/Linux
267                        # with ELF format using glibc 2
268                        # aka GNU/Linux C library 6
269     ;;
270   x86_64-*-linux*)
271     ;;
272   i[34567]86-*-gnu*)
273     ;;
274   i[34567]86-pc-msdosdjgpp*)
275     host_xm_file=i386/xm-djgpp.h
276     host_exeext=.exe
277     # Shorten $target_alias for 8.3 filename conventions.
278     case ${target} in
279       *pc-msdosdjgpp*)
280         target_alias=djgpp
281         ;;
282     esac
283     ;;
284   i[34567]86-moss-msdos* | i[34567]86-*-moss*)
285     ;;
286   i[34567]86-*-lynxos*)
287     ;;
288   i[34567]86-*-mach*)
289     ;;
290   i[34567]86-*-nto-qnx*)
291     ;;
292   i[34567]86-*-rtems*)
293     ;;
294   i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
295     ;;
296   i[34567]86-*-solaris2*)
297     host_xm_defines="SMALL_ARG_MAX"
298     ;;
299   i[34567]86-*-sysv5*) # Intel x86 on System V Release 5
300     ;;
301   i[34567]86-*-sysv4*) # Intel 80386's running System V Release 4
302     host_xm_defines="SMALL_ARG_MAX"
303     ;;
304   i[34567]86-*-udk*) # Intel x86 on SCO UW/OSR5 Dev Kit
305     ;;
306   i[34567]86-*-sysv*) # Intel 80386's running System V
307     ;;
308   i386-*-vsta) # Intel 80386's running VSTa kernel
309     ;;
310   i[34567]86-*-pe | i[34567]86-*-cygwin*)
311     host_xm_file=i386/xm-cygwin.h
312     host_exeext=.exe
313     ;;
314   i[34567]86-*-mingw32*)
315     host_xm_file=i386/xm-mingw32.h
316     host_xmake_file=i386/x-mingw32
317     host_exeext=.exe
318     ;;
319   i[34567]86-*-uwin*)
320     host_exeext=.exe
321     ;;
322   i[34567]86-*-interix3*)
323     host_xmake_file="x-interix"
324     ;;
325   i[34567]86-*-interix*)
326     ;;
327   i[34567]86-*-kaos*)
328     ;;
329   i860-*-sysv4*)
330     host_xmake_file=i860/x-sysv4
331     ;;
332   i960-*-coff*)
333     ;;
334   i960-*-rtems)
335     ;;
336   i960-*-*) # Default i960 environment.
337     ;;
338   ia64*-*-elf*)
339     ;;
340   ia64*-*-freebsd*)
341     ;;
342   ia64*-*-linux*)
343     ;;
344   ia64*-*-hpux*)
345     ;;
346   ip2k-*-elf)
347     ;;
348   iq2000*-*-elf*)
349     ;;
350   m32r-*-elf*)
351     ;;
352   # m68hc11 and m68hc12 share the same machine description.
353   m68hc11-*-*|m6811-*-*)
354     ;;
355   m68hc12-*-*|m6812-*-*)
356     ;;
357   m68000-hp-hpux*) # HP 9000 series 300
358     ;;
359   m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
360     ;;
361   m68k-hp-hpux*) # HP 9000 series 300
362     ;;
363   m68k-*-aout*)
364     ;;
365   m68k-*-coff*)
366     ;;
367   m68020-*-elf* | m68k-*-elf*)
368     ;;
369   m68010-*-netbsdelf* | m68k*-*-netbsdelf*)
370     ;;
371   m68k*-*-netbsd*)
372     ;;
373   m68k*-*-openbsd*)
374     ;;
375   m68k-*-sysv4*) # Motorola m68k's running system V r4
376     ;;
377   m68k-*-linux*) # Motorola m68k's running GNU/Linux
378                  # with ELF format using glibc 2
379                  # aka the GNU/Linux C library 6.
380     ;;
381   m68k-*-rtems*)
382     ;;
383   mcore-*-elf)
384     ;;
385   mcore-*-pe*)
386     ;;
387   mips-sgi-irix6*o32) # SGI System V.4., IRIX 6, O32 ABI
388     host_xm_file=mips/xm-iris5.h
389     ;;
390   mips-sgi-irix6*) # SGI System V.4., IRIX 6
391     ;;
392   mips-sgi-irix5cross64) # Irix5 host, Irix 6 target, cross64
393     host_xm_file=mips/xm-iris5.h
394     ;;
395   mips-sgi-irix5*) # SGI System V.4., IRIX 5
396     host_xm_file=mips/xm-iris5.h
397     ;;
398   mips*-*-netbsd*) # NetBSD/mips, either endian.
399     ;;
400   mips64*-*-linux*)
401     ;;
402   mips*-*-linux*) # Linux MIPS, either endian.
403     ;;
404   mips*-*-openbsd*)
405     ;;
406   mipsisa32-*-elf* | mipsisa32el-*-elf*)
407     ;;
408   mipsisa32r2-*-elf* | mipsisa32r2el-*-elf*)
409     ;;
410   mipsisa64-*-elf* | mipsisa64el-*-elf*)
411     ;;
412   mipsisa64sr71k-*-elf*)
413     ;;
414   mipsisa64sb1-*-elf* | mipsisa64sb1el-*-elf*)
415     ;;
416   mips-*-elf* | mipsel-*-elf*)
417     ;;
418   mips64-*-elf* | mips64el-*-elf*)
419     ;;
420   mips64vr-*-elf* | mips64vrel-*-elf*)
421     ;;
422   mips64orion-*-elf* | mips64orionel-*-elf*)
423     ;;
424   mips*-*-rtems*)
425     ;;
426   mipstx39-*-elf* | mipstx39el-*-elf*)
427     ;;
428   mmix-knuth-mmixware)
429     ;;
430   mn10300-*-*)
431     ;;
432   ns32k-*-netbsdelf*)
433     echo "GCC does not yet support the ${host} host"; exit 1
434     ;;
435   ns32k-*-netbsd*)
436     ;;
437   pdp11-*-bsd)
438     ;;
439   pdp11-*-*)
440     ;;
441   avr-*-*)
442     ;;
443 #  port not yet contributed
444 #  powerpc-*-openbsd*)
445 #    ;;
446   powerpc64-*-linux*)
447     ;;
448   powerpc64-*-gnu*)
449     ;;
450   powerpc-*-beos*)
451     ;;
452   powerpc-*-darwin*)
453     # powerpc-darwin host support.
454     out_host_hook_obj=host-darwin.o
455     host_xmake_file=rs6000/x-darwin
456     ;;
457   powerpc*-*-freebsd*)
458     ;;
459   powerpc-*-netbsd*)
460     ;;
461   powerpc-*-chorusos*)
462     ;;
463   powerpc-*-eabispe*)
464     ;;
465   powerpc-*-eabisimaltivec*)
466     ;;
467   powerpc-*-eabisim*)
468     ;;
469   powerpc-*-elf*)
470     ;;
471   powerpc-*-eabialtivec*)
472     ;;
473   powerpc-*-eabi*)
474     ;;
475   powerpc-*-rtems*)
476     ;;
477   powerpc-*-linux*altivec*)
478     ;;
479   powerpc-*-linux*spe*)
480     ;;
481   powerpc-*-linux*)
482     ;;
483   powerpc-*-gnu-gnualtivec*)
484     ;;
485   powerpc-*-gnu*)
486     ;;
487   powerpc-wrs-vxworks*)
488     ;;
489   powerpc-wrs-windiss*)
490     ;;
491   powerpcle-*-sysv*)
492     ;;
493   powerpcle-*-elf*)
494     ;;
495   powerpcle-*-eabisim*)
496     ;;
497   powerpcle-*-eabi*)
498     ;;
499   powerpc-*-kaos*)
500     ;;
501   powerpcle-*-kaos*)
502     ;;
503   rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*)
504     ;;
505   rs6000-ibm-aix4.[3456789]* | powerpc-ibm-aix4.[3456789]*)
506     ;;
507   rs6000-ibm-aix5.1.* | powerpc-ibm-aix5.1.*)
508     ;;
509   rs6000-ibm-aix[56789].* | powerpc-ibm-aix[56789].*)
510     ;;
511   rs6000-*-lynxos*)
512     ;;
513   s390-*-linux*)
514     ;;
515   s390x-*-linux*)
516     ;;
517   sh-*-elf* | sh[2346l]*-*-elf* | sh*-*-kaos*)
518     ;;
519   sh-*-rtemself*)
520     ;;
521   sh-*-rtems*)
522     ;;
523   sh-*-linux* | sh[2346lbe]*-*-linux*)
524     ;;
525   sh-*-netbsdelf* | shl*-*-netbsdelf* | sh5-*-netbsd* | sh5l*-*-netbsd* | \
526   sh64-*-netbsd* | sh64l*-*-netbsd*)
527     ;;
528   sh-*-*)
529     ;;
530   sparc-tti-*)
531     ;;
532   sparc-*-netbsdelf*)
533     ;;
534   sparc-*-openbsd*)
535     ;;
536   sparc64-*-openbsd*)
537     ;;
538   sparc-*-elf*)
539     ;;
540   sparc-*-linux*) # SPARC's running GNU/Linux, libc6
541     ;;
542   sparc-*-rtems*)
543     ;;
544   sparc64-*-solaris2* | sparcv9-*-solaris2*)
545     ;;
546   sparc-*-solaris2*)
547     ;;
548   sparc-*-sysv4*)
549     ;;
550   sparclite-*-coff*)
551     ;;
552   sparclite-*-elf*)
553     ;;
554   sparc86x-*-elf*)
555     ;;
556   sparc64-*-aout*)
557     ;;
558   sparc64-*-elf*)
559     ;;
560   sparc64-*-freebsd*|ultrasparc-*-freebsd*)
561     ;;
562   sparc64-*-linux*) # 64-bit SPARC's running GNU/Linux
563     ;;
564   sparc64-*-netbsd*)
565     ;;
566   strongarm-*-elf*)
567     ;;
568   strongarm-*-pe)
569     ;;
570   strongarm-*-kaos*)
571     ;;
572   v850e-*-*)
573     ;;
574   v850-*-*)
575     ;;
576   vax-*-bsd*) # VAXen running BSD
577     ;;
578   vax-*-sysv*) # VAXen running System V
579     ;;
580   vax-*-netbsdelf*)
581     ;;
582   vax-*-netbsd*)
583     ;;
584   vax-*-openbsd*)
585     ;;
586   vax-*-ultrix*) # VAXen running ultrix
587     ;;
588   vax-*-vms*) # VAXen running VMS
589     echo "Host ${host} no longer supported" 1>&2
590     exit 1
591     ;;
592   vax-*-*) # VAX default entry
593     ;;
594   xscale-*-elf)
595     ;;
596   xscale-*-coff)
597     ;;
598   xstormy16-*-elf)
599     ;;
600   xtensa-*-elf*)
601     ;;
602   xtensa-*-linux*)
603     ;;
604   am33_2.0-*-linux*)
605     ;;
606   *)
607     echo "*** Configuration ${host} not supported" 1>&2
608     exit 1
609     ;;
610 esac