]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/xtensa/elf.h
elf.h (TARGET_SECTION_TYPE_FLAGS): Define to xtensa_multibss_section_type_flags.
[thirdparty/gcc.git] / gcc / config / xtensa / elf.h
CommitLineData
03984308
BW
1/* Xtensa/Elf configuration.
2 Derived from the configuration for GCC for Intel i386 running Linux.
3 Copyright (C) 2001 Free Software Foundation, Inc.
4
5This file is part of GCC.
6
7GCC is free software; you can redistribute it and/or modify it under
8the terms of the GNU General Public License as published by the Free
9Software Foundation; either version 2, or (at your option) any later
10version.
11
12GCC is distributed in the hope that it will be useful, but WITHOUT ANY
13WARRANTY; without even the implied warranty of MERCHANTABILITY or
14FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15for more details.
16
17You should have received a copy of the GNU General Public License
18along with GCC; see the file COPYING. If not, write to the Free
19Software Foundation, 59 Temple Place - Suite 330, Boston, MA
2002111-1307, USA. */
21
624f0d60
BW
22#define TARGET_OS_CPP_BUILTINS() \
23 do { \
24 builtin_define ("__ELF__"); \
25 } while (0)
26
01abf342
BW
27#define TARGET_SECTION_TYPE_FLAGS xtensa_multibss_section_type_flags
28
03984308
BW
29/* Don't assume anything about the header files. */
30#define NO_IMPLICIT_EXTERN_C
31
32#undef ASM_APP_ON
33#define ASM_APP_ON "#APP\n"
34
35#undef ASM_APP_OFF
36#define ASM_APP_OFF "#NO_APP\n"
37
38#undef MD_EXEC_PREFIX
39#undef MD_STARTFILE_PREFIX
40
41#undef TARGET_VERSION
42#define TARGET_VERSION fputs (" (Xtensa/ELF)", stderr);
43
44#undef SIZE_TYPE
45#define SIZE_TYPE "unsigned int"
46
47#undef PTRDIFF_TYPE
48#define PTRDIFF_TYPE "int"
49
50#undef WCHAR_TYPE
51#define WCHAR_TYPE "int"
52
53#undef WCHAR_TYPE_SIZE
54#define WCHAR_TYPE_SIZE BITS_PER_WORD
55
56#undef ASM_SPEC
57#define ASM_SPEC "%{v} %{mno-density:--no-density} \
58 %{mtext-section-literals:--text-section-literals} \
59 %{mno-text-section-literals:--no-text-section-literals} \
60 %{mtarget-align:--target-align} \
61 %{mno-target-align:--no-target-align} \
62 %{mlongcalls:--longcalls} \
63 %{mno-longcalls:--no-longcalls}"
64
65#undef ASM_FINAL_SPEC
66
67#undef LIB_SPEC
68#define LIB_SPEC "-lc -lsim -lc -lhandlers-sim"
69
70#undef STARTFILE_SPEC
71#define STARTFILE_SPEC "crt1-sim%O%s crti%O%s crtbegin%O%s _vectors%O%s"
72
73#undef ENDFILE_SPEC
74#define ENDFILE_SPEC "crtend%O%s crtn%O%s"
75
76#undef LINK_SPEC
77#define LINK_SPEC \
78 "%{shared:-shared} \
79 %{!shared: \
80 %{!static: \
81 %{rdynamic:-export-dynamic} \
82 %{static:-static}}}"
83
03984308
BW
84/* Local compiler-generated symbols must have a prefix that the assembler
85 understands. By default, this is $, although some targets (e.g.,
86 NetBSD-ELF) need to override this. */
87
88#ifndef LOCAL_LABEL_PREFIX
89#define LOCAL_LABEL_PREFIX "."
90#endif
91
92/* By default, external symbols do not have an underscore prepended. */
93
94#ifndef USER_LABEL_PREFIX
95#define USER_LABEL_PREFIX ""
96#endif
97
98/* Define this macro if the assembler does not accept the character
99 "." in label names. By default constructors and destructors in G++
100 have names that use ".". If this macro is defined, these names
101 are rewritten to avoid ".". */
102#define NO_DOT_IN_LABEL
103
104/* Define NO_DOLLAR_IN_LABEL in your favorite tm file if your assembler
105 doesn't allow $ in symbol names. */
106#undef NO_DOLLAR_IN_LABEL
107
03984308
BW
108/* Do not force "-fpic" for this target. */
109#define XTENSA_ALWAYS_PIC 0
110
111/* Redefine the standard ELF version of ASM_DECLARE_FUNCTION_SIZE to
112 allow adding the ".end literal_prefix" directive at the end of the
113 function. */
114#undef ASM_DECLARE_FUNCTION_SIZE
115#define ASM_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL) \
116 do \
117 { \
118 if (!flag_inhibit_size_directive) \
99086d59 119 ASM_OUTPUT_MEASURED_SIZE (FILE, FNAME); \
03984308
BW
120 XTENSA_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL); \
121 } \
122 while (0)