1 /* Definitions for MIPS running Linux-based GNU systems with ELF format
3 Copyright 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
5 This file is part of GCC.
7 GCC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3, or (at your option)
12 GCC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GCC; see the file COPYING3. If not see
19 <http://www.gnu.org/licenses/>. */
21 /* Force the default endianness and ABI flags onto the command line
22 in order to make the other specs easier to write. */
23 #undef DRIVER_SELF_SPECS
24 #define DRIVER_SELF_SPECS \
25 BASE_DRIVER_SELF_SPECS, \
26 LINUX_DRIVER_SELF_SPECS \
27 " %{!EB:%{!EL:%(endian_spec)}}" \
28 " %{!mabi=*: -mabi=n32}"
32 %{pthread:-lpthread} \
35 %{profile:-lc_p} %{!profile:-lc}}"
37 #define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
38 #define GLIBC_DYNAMIC_LINKER64 "/lib64/ld.so.1"
39 #define GLIBC_DYNAMIC_LINKERN32 "/lib32/ld.so.1"
40 #define UCLIBC_DYNAMIC_LINKERN32 "/lib32/ld-uClibc.so.0"
41 #define LINUX_DYNAMIC_LINKERN32 \
42 CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32)
46 %{G*} %{EB} %{EL} %{mips1} %{mips2} %{mips3} %{mips4} \
47 %{bestGnum} %{shared} %{non_shared} \
48 %{call_shared} %{no_archive} %{exact_version} \
53 %{rdynamic:-export-dynamic} \
55 %{mabi=n32: -dynamic-linker " LINUX_DYNAMIC_LINKERN32 "} \
56 %{mabi=64: -dynamic-linker " LINUX_DYNAMIC_LINKER64 "} \
57 %{mabi=32: -dynamic-linker " LINUX_DYNAMIC_LINKER32 "}}} \
59 %{mabi=n32:-melf32%{EB:b}%{EL:l}tsmipn32} \
60 %{mabi=64:-melf64%{EB:b}%{EL:l}tsmip} \
61 %{mabi=32:-melf32%{EB:b}%{EL:l}tsmip}"
63 #undef LOCAL_LABEL_PREFIX
64 #define LOCAL_LABEL_PREFIX (TARGET_OLDABI ? "$" : ".")
66 /* GNU/Linux doesn't use the same floating-point format that IRIX uses
67 for long double. There's no need to override this here, since
68 ieee_quad_format is the default, but let's put this here to make
69 sure nobody thinks we just forgot to set it to something else. */
70 #define MIPS_TFMODE_FORMAT mips_quad_format