1169689Skan/* Definitions for MIPS running Linux-based GNU systems with ELF format 2169689Skan using n32/64 abi. 3169689Skan Copyright 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 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/* Force the default endianness and ABI flags onto the command line 23169689Skan in order to make the other specs easier to write. */ 24169689Skan#define DRIVER_SELF_SPECS \ 25169689Skan"%{!EB:%{!EL:%(endian_spec)}}", \ 26169689Skan"%{!mabi=*: -mabi=n32}" 27169689Skan 28169689Skan#undef SUBTARGET_ASM_SPEC 29169689Skan#define SUBTARGET_ASM_SPEC "\ 30169689Skan%{!fno-PIC:%{!fno-pic:-KPIC}} \ 31169689Skan%{fno-PIC:-non_shared} %{fno-pic:-non_shared}" 32169689Skan 33169689Skan#undef LIB_SPEC 34169689Skan#define LIB_SPEC "\ 35169689Skan%{shared: -lc} \ 36169689Skan%{!shared: %{pthread:-lpthread} \ 37169689Skan %{profile:-lc_p} %{!profile: -lc}}" 38169689Skan 39169689Skan#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1" 40169689Skan#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld.so.1" 41169689Skan#define GLIBC_DYNAMIC_LINKERN32 "/lib32/ld.so.1" 42169689Skan#define UCLIBC_DYNAMIC_LINKERN32 "/lib32/ld-uClibc.so.0" 43169689Skan#define LINUX_DYNAMIC_LINKERN32 \ 44169689Skan CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32) 45169689Skan 46169689Skan#undef LINK_SPEC 47169689Skan#define LINK_SPEC "\ 48169689Skan%{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} %{mips4} \ 49169689Skan%{bestGnum} %{shared} %{non_shared} \ 50169689Skan%{call_shared} %{no_archive} %{exact_version} \ 51169689Skan %(endian_spec) \ 52169689Skan %{!shared: \ 53169689Skan %{!ibcs: \ 54169689Skan %{!static: \ 55169689Skan %{rdynamic:-export-dynamic} \ 56169689Skan %{!dynamic-linker: \ 57169689Skan %{mabi=n32: -dynamic-linker " LINUX_DYNAMIC_LINKERN32 "} \ 58169689Skan %{mabi=64: -dynamic-linker " LINUX_DYNAMIC_LINKER64 "} \ 59169689Skan %{mabi=32: -dynamic-linker " LINUX_DYNAMIC_LINKER32 "}}} \ 60169689Skan %{static:-static}}} \ 61169689Skan%{mabi=n32:-melf32%{EB:b}%{EL:l}tsmipn32} \ 62169689Skan%{mabi=64:-melf64%{EB:b}%{EL:l}tsmip} \ 63169689Skan%{mabi=32:-melf32%{EB:b}%{EL:l}tsmip}" 64169689Skan 65169689Skan#undef LOCAL_LABEL_PREFIX 66169689Skan#define LOCAL_LABEL_PREFIX (TARGET_OLDABI ? "$" : ".") 67169689Skan 68169689Skan/* GNU/Linux doesn't use the same floating-point format that IRIX uses 69169689Skan for long double. There's no need to override this here, since 70169689Skan ieee_quad_format is the default, but let's put this here to make 71169689Skan sure nobody thinks we just forgot to set it to something else. */ 72169689Skan#define MIPS_TFMODE_FORMAT mips_quad_format 73