1169689Skan/* Support for GCC on MIPS using WindISS simulator.
2169689Skan   Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
3169689Skan   Contributed by CodeSourcery, LLC.
4169689Skan
5169689SkanThis file is part of GCC.
6169689Skan
7169689SkanGCC is free software; you can redistribute it and/or modify
8169689Skanit under the terms of the GNU General Public License as published by
9169689Skanthe Free Software Foundation; either version 2, or (at your option)
10169689Skanany later version.
11169689Skan
12169689SkanGCC is distributed in the hope that it will be useful,
13169689Skanbut WITHOUT ANY WARRANTY; without even the implied warranty of
14169689SkanMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15169689SkanGNU General Public License for more details.
16169689Skan
17169689SkanYou should have received a copy of the GNU General Public License
18169689Skanalong with GCC; see the file COPYING.  If not, write to
19169689Skanthe Free Software Foundation, 51 Franklin Street, Fifth Floor,
20169689SkanBoston, MA 02110-1301, USA.  */
21169689Skan
22169689Skan#undef TARGET_VERSION
23169689Skan#define TARGET_VERSION fprintf (stderr, " (MIPS WindISS)");
24169689Skan
25169689Skan/* Combination of mips.h and svr4.h.  */
26169689Skan#undef  SWITCH_TAKES_ARG
27169689Skan#define SWITCH_TAKES_ARG(CHAR)          \
28169689Skan  (DEFAULT_SWITCH_TAKES_ARG (CHAR)      \
29169689Skan   || (CHAR) == 'G'                     \
30169689Skan   || (CHAR) == 'h'                     \
31169689Skan   || (CHAR) == 'x'                     \
32169689Skan   || (CHAR) == 'z')
33169689Skan
34169689Skan#undef SUBTARGET_CPP_SPEC
35169689Skan#define SUBTARGET_CPP_SPEC \
36169689Skan"%{!DCPU=*: %{mips3|mips4|mips64:-DCPU=MIPS64;:-DCPU=MIPS32}} \
37169689Skan  %{EL|mel:-DMIPSEL;:-DMIPSEB} \
38169689Skan  %{msoft-float:-DSOFT_FLOAT} \
39169689Skan  %{mips1:-D_WRS_R3K_EXC_SUPPORT}"
40169689Skan
41169689Skan#undef  ASM_SPEC
42169689Skan#define ASM_SPEC "\
43169689Skan%{!G:-G 0} %{G*} %(endian_spec) %{mips1} %{mips2} %{mips3} %{mips4} \
44169689Skan%{mips32} %{mips32r2} %{mips64} \
45169689Skan%{mips16:%{!mno-mips16:-mips16}} %{mno-mips16:-no-mips16} \
46169689Skan%(subtarget_asm_optimizing_spec) \
47169689Skan%(subtarget_asm_debugging_spec) \
48169689Skan%{mabi=*} %{!mabi*: %(asm_abi_default_spec)} \
49169689Skan%{mgp32} %{mgp64} %{march=*} %{mxgot:-xgot} \
50169689Skan%{mtune=*} %{v} \
51169689Skan%(subtarget_asm_spec)"
52169689Skan
53169689Skan#undef LINK_SPEC
54169689Skan/* LINK_SPEC is clobbered in svr4.h. ugh!  */
55169689Skan#define LINK_SPEC "\
56169689Skan-m elf32mipswindiss \
57169689Skan%{!G:-G 0} %{G*} %{mips1} %{mips2} %{mips3} %{mips4} %{mips32} %{mips64} \
58169689Skan%{bestGnum}"
59169689Skan
60169689Skan/* Diab libs MIPS{,E,F,L,M,W,X,Y,Z}{,H,N,S}
61169689Skan
62169689Skan   .
63169689Skan   E - Elf (small-data/const=8
64169689Skan   F - Elf Far (small-data/const=0)
65169689Skan   L - Little Elf
66169689Skan   M - Little Elf Far
67169689Skan   W - elf32 bigmips
68169689Skan   X - elf32 bigmips (far?)
69169689Skan   Y - elf32 littlemips
70169689Skan   Z - elf32 littlemips (far?)
71169689Skan
72169689Skan   . - Integer routines
73169689Skan   H - Hard float
74169689Skan   N - No float
75169689Skan   S - Soft float
76169689Skan
77169689Skan   Want {F,M}{,H,S}
78169689Skan
79169689Skan*/
80169689Skan
81169689Skan#undef LIB_SPEC
82169689Skan#define LIB_SPEC "--start-group -li -lcfp -lwindiss -lram -limpl -limpfp --end-group"
83169689Skan
84169689Skan#undef STARTFILE_SPEC
85169689Skan#define STARTFILE_SPEC "crt0.o%s crtbegin.o%s"
86169689Skan
87169689Skan#undef ENDFILE_SPEC
88169689Skan#define ENDFILE_SPEC "crtend.o%s"
89169689Skan
90169689Skan/* We have no shared libraries.  These two shouldn't be necessary.  */
91169689Skan#undef LINK_SHLIB_SPEC
92169689Skan#define LINK_SHLIB_SPEC ""
93169689Skan#undef LINK_EH_SPEC
94169689Skan#define LINK_EH_SPEC ""
95169689Skan
96169689Skan#undef CRTSAVRES_DEFAULT_SPEC
97169689Skan#define CRTSAVRES_DEFAULT_SPEC ""
98169689Skan
99169689Skan/* No sdata.  */
100169689Skan#undef MIPS_DEFAULT_GVALUE
101169689Skan#define MIPS_DEFAULT_GVALUE 0
102