PR target/55160
[official-gcc.git] / gcc / config / mips / linux-common.h
blob513590544c7a33fbbcec4d0632878ddcb95e647d
1 /* Definitions for MIPS running Linux-based GNU systems with ELF format.
2 Copyright (C) 2012 Free Software Foundation, Inc.
4 This file is part of GCC.
6 GCC is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3, or (at your option)
9 any later version.
11 GCC is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GCC; see the file COPYING3. If not see
18 <http://www.gnu.org/licenses/>. */
20 #undef TARGET_OS_CPP_BUILTINS
21 #define TARGET_OS_CPP_BUILTINS() \
22 do { \
23 GNU_USER_TARGET_OS_CPP_BUILTINS(); \
24 /* The GNU C++ standard library requires this. */ \
25 if (c_dialect_cxx ()) \
26 builtin_define ("_GNU_SOURCE"); \
27 ANDROID_TARGET_OS_CPP_BUILTINS(); \
28 } while (0)
30 #undef LINK_SPEC
31 #define LINK_SPEC \
32 LINUX_OR_ANDROID_LD (GNU_USER_TARGET_LINK_SPEC, \
33 GNU_USER_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)
35 #undef SUBTARGET_CC1_SPEC
36 #define SUBTARGET_CC1_SPEC \
37 LINUX_OR_ANDROID_CC (GNU_USER_TARGET_CC1_SPEC, \
38 GNU_USER_TARGET_CC1_SPEC " " ANDROID_CC1_SPEC)
40 #undef CC1PLUS_SPEC
41 #define CC1PLUS_SPEC \
42 LINUX_OR_ANDROID_CC ("", ANDROID_CC1PLUS_SPEC)
44 #undef LIB_SPEC
45 #define LIB_SPEC \
46 LINUX_OR_ANDROID_LD (GNU_USER_TARGET_LIB_SPEC, \
47 GNU_USER_TARGET_LIB_SPEC " " ANDROID_LIB_SPEC)
49 #undef STARTFILE_SPEC
50 #define STARTFILE_SPEC \
51 LINUX_OR_ANDROID_LD (GNU_USER_TARGET_STARTFILE_SPEC, ANDROID_STARTFILE_SPEC)
53 #undef ENDFILE_SPEC
54 #define ENDFILE_SPEC \
55 LINUX_OR_ANDROID_LD (GNU_USER_TARGET_MATHFILE_SPEC " " \
56 GNU_USER_TARGET_ENDFILE_SPEC, \
57 GNU_USER_TARGET_MATHFILE_SPEC " " \
58 ANDROID_ENDFILE_SPEC)
60 /* Define this to be nonzero if static stack checking is supported. */
61 #define STACK_CHECK_STATIC_BUILTIN 1
63 /* The default value isn't sufficient in 64-bit mode. */
64 #define STACK_CHECK_PROTECT (TARGET_64BIT ? 16 * 1024 : 12 * 1024)