annotate gcc/config/vxworks.h @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents f6334be47118
children 84e7813d76e9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 /* Common VxWorks target definitions for GNU compiler.
111
kono
parents: 67
diff changeset
2 Copyright (C) 1999-2017 Free Software Foundation, Inc.
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
3 Contributed by Wind River Systems.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
4 Rewritten by CodeSourcery, LLC.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
5
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 This file is part of GCC.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
7
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
8 GCC is free software; you can redistribute it and/or modify it under
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
9 the terms of the GNU General Public License as published by the Free
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 Software Foundation; either version 3, or (at your option) any later
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 version.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
12
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
13 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
14 WARRANTY; without even the implied warranty of MERCHANTABILITY or
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
15 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
16 for more details.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
17
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 You should have received a copy of the GNU General Public License
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
19 along with GCC; see the file COPYING3. If not see
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 <http://www.gnu.org/licenses/>. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
21
111
kono
parents: 67
diff changeset
22 /* Assert that we are targeting VxWorks. */
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 #undef TARGET_VXWORKS
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 #define TARGET_VXWORKS 1
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
25
111
kono
parents: 67
diff changeset
26 /* If TARGET_VXWORKS7 is undefined, then we're not targeting it. */
kono
parents: 67
diff changeset
27 #ifndef TARGET_VXWORKS7
kono
parents: 67
diff changeset
28 #define TARGET_VXWORKS7 0
kono
parents: 67
diff changeset
29 #endif
kono
parents: 67
diff changeset
30
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
31 /* In kernel mode, VxWorks provides all the libraries itself, as well as
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
32 the functionality of startup files, etc. In RTP mode, it behaves more
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 like a traditional Unix, with more external files. Most of our specs
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
34 must be aware of the difference. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
35
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
36 /* We look for the VxWorks header files using the environment
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
37 variables that are set in VxWorks to indicate the location of the
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
38 system header files. We use -idirafter so that the GCC's own
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
39 header-file directories (containing <stddef.h>, etc.) come before
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
40 the VxWorks system header directories. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
41
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
42 /* Since we provide a default -isystem, expand -isystem on the command
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
43 line early. */
111
kono
parents: 67
diff changeset
44 #if TARGET_VXWORKS7
kono
parents: 67
diff changeset
45
kono
parents: 67
diff changeset
46 #undef VXWORKS_ADDITIONAL_CPP_SPEC
kono
parents: 67
diff changeset
47 #define VXWORKS_ADDITIONAL_CPP_SPEC \
kono
parents: 67
diff changeset
48 "%{!nostdinc: \
kono
parents: 67
diff changeset
49 %{isystem*} \
kono
parents: 67
diff changeset
50 %{mrtp: -idirafter %:getenv(VSB_DIR /h) \
kono
parents: 67
diff changeset
51 -idirafter %:getenv(VSB_DIR /share/h) \
kono
parents: 67
diff changeset
52 -idirafter %:getenv(VSB_DIR /usr/h/public) \
kono
parents: 67
diff changeset
53 -idirafter %:getenv(VSB_DIR /usr/h) \
kono
parents: 67
diff changeset
54 ;: -idirafter %:getenv(VSB_DIR /h) \
kono
parents: 67
diff changeset
55 -idirafter %:getenv(VSB_DIR /share/h) \
kono
parents: 67
diff changeset
56 -idirafter %:getenv(VSB_DIR /krnl/h/system) \
kono
parents: 67
diff changeset
57 -idirafter %:getenv(VSB_DIR /krnl/h/public)}}"
kono
parents: 67
diff changeset
58
kono
parents: 67
diff changeset
59 #else /* TARGET_VXWORKS7 */
kono
parents: 67
diff changeset
60
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
61 #undef VXWORKS_ADDITIONAL_CPP_SPEC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
62 #define VXWORKS_ADDITIONAL_CPP_SPEC \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
63 "%{!nostdinc: \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
64 %{isystem*} -idirafter \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
65 %{mrtp: %:getenv(WIND_USR /h) \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
66 ;: %:getenv(WIND_BASE /target/h)}}"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
67
111
kono
parents: 67
diff changeset
68 #endif
kono
parents: 67
diff changeset
69
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
70 /* The references to __init and __fini will be satisfied by
111
kono
parents: 67
diff changeset
71 libc_internal.a, and some versions of VxWorks rely on explicit
kono
parents: 67
diff changeset
72 extra libraries for system calls. */
kono
parents: 67
diff changeset
73
kono
parents: 67
diff changeset
74 #define VXWORKS_SYSCALL_LIBS_RTP
kono
parents: 67
diff changeset
75
kono
parents: 67
diff changeset
76 #define VXWORKS_LIBS_RTP \
kono
parents: 67
diff changeset
77 VXWORKS_SYSCALL_LIBS_RTP " -lc -lgcc -lc_internal -lnet -ldsi"
kono
parents: 67
diff changeset
78
kono
parents: 67
diff changeset
79 /* On Vx6 and previous, the libraries to pick up depends on the architecture,
kono
parents: 67
diff changeset
80 so cannot be defined for all archs at once. On Vx7, a VSB is always needed
kono
parents: 67
diff changeset
81 and its structure is fixed and does not depend on the arch. We can thus
kono
parents: 67
diff changeset
82 tell gcc where to look for when linking with RTP libraries. */
kono
parents: 67
diff changeset
83
kono
parents: 67
diff changeset
84 /* On Vx7 RTP, we need to drag the __tls__ symbol to trigger initialization of
kono
parents: 67
diff changeset
85 tlsLib, responsible for TLS support by the OS. */
kono
parents: 67
diff changeset
86
kono
parents: 67
diff changeset
87 #if TARGET_VXWORKS7
kono
parents: 67
diff changeset
88 #define VXWORKS_LIBS_DIR_RTP "-L%:getenv(VSB_DIR /usr/lib/common)"
kono
parents: 67
diff changeset
89 #define TLS_SYM "-u __tls__"
kono
parents: 67
diff changeset
90 #else
kono
parents: 67
diff changeset
91 #define VXWORKS_LIBS_DIR_RTP ""
kono
parents: 67
diff changeset
92 #define TLS_SYM ""
kono
parents: 67
diff changeset
93 #endif
kono
parents: 67
diff changeset
94
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
95 #undef VXWORKS_LIB_SPEC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
96 #define VXWORKS_LIB_SPEC \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
97 "%{mrtp:%{shared:-u " USER_LABEL_PREFIX "__init -u " USER_LABEL_PREFIX "__fini} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
98 %{!shared:%{non-static:-u " USER_LABEL_PREFIX "_STI__6__rtld -ldl} \
111
kono
parents: 67
diff changeset
99 " TLS_SYM " \
kono
parents: 67
diff changeset
100 --start-group " VXWORKS_LIBS_RTP " --end-group} \
kono
parents: 67
diff changeset
101 " VXWORKS_LIBS_DIR_RTP "}"
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
102
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
103 /* The no-op spec for "-shared" below is present because otherwise GCC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
104 will treat it as an unrecognized option. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
105 #undef VXWORKS_LINK_SPEC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
106 #define VXWORKS_LINK_SPEC \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
107 "%{!mrtp:-r} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
108 %{!shared: \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
109 %{mrtp:-q %{h*} \
67
f6334be47118 update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
110 %{R*} %{!T*: %(link_start) } \
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
111 %(link_target) %(link_os)}} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
112 %{v:-v} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
113 %{shared:-shared} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
114 %{Bstatic:-Bstatic} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
115 %{Bdynamic:-Bdynamic} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
116 %{!Xbind-lazy:-z now} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
117 %{Xbind-now:%{Xbind-lazy: \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
118 %e-Xbind-now and -Xbind-lazy are incompatible}} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
119 %{mrtp:%{!shared:%{!non-static:-static} \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
120 %{non-static:--force-dynamic --export-dynamic}}}"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
121
111
kono
parents: 67
diff changeset
122 /* For VxWorks static rtps, the system provides libc_internal.a, a superset
kono
parents: 67
diff changeset
123 of libgcc.a that we want to use. Make sure not to dynamically export any
kono
parents: 67
diff changeset
124 of its symbols, though, and always look for libgcc.a first so that we get
kono
parents: 67
diff changeset
125 the latest versions of the GNU intrinsics during our builds. */
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
126 #undef VXWORKS_LIBGCC_SPEC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
127 #define VXWORKS_LIBGCC_SPEC \
111
kono
parents: 67
diff changeset
128 "-lgcc %{mrtp:%{!shared:--exclude-libs=libc_internal,libgcc -lc_internal}}"
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
129
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
130 #undef VXWORKS_STARTFILE_SPEC
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
131 #define VXWORKS_STARTFILE_SPEC "%{mrtp:%{!shared:-l:crt0.o}}"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
132 #define VXWORKS_ENDFILE_SPEC ""
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
133
67
f6334be47118 update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
134 /* Do VxWorks-specific parts of TARGET_OPTION_OVERRIDE. */
111
kono
parents: 67
diff changeset
135
kono
parents: 67
diff changeset
136 #define VXWORKS_HAVE_TLS (TARGET_VXWORKS7 && TARGET_VXWORKS_RTP)
kono
parents: 67
diff changeset
137
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
138 #undef VXWORKS_OVERRIDE_OPTIONS
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
139 #define VXWORKS_OVERRIDE_OPTIONS vxworks_override_options ()
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
140 extern void vxworks_override_options (void);
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
141
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
142 /* Only RTPs support prioritized constructors and destructors:
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
143 the implementation relies on numbered .ctors* sections. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
144 #define SUPPORTS_INIT_PRIORITY TARGET_VXWORKS_RTP
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
145
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
146 /* VxWorks requires special handling of constructors and destructors.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
147 All VxWorks configurations must use these functions. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
148 #undef TARGET_ASM_CONSTRUCTOR
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
149 #define TARGET_ASM_CONSTRUCTOR vxworks_asm_out_constructor
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
150 #undef TARGET_ASM_DESTRUCTOR
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
151 #define TARGET_ASM_DESTRUCTOR vxworks_asm_out_destructor
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
152 extern void vxworks_asm_out_constructor (rtx symbol, int priority);
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
153 extern void vxworks_asm_out_destructor (rtx symbol, int priority);
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
154
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
155 /* Override the vxworks-dummy.h definitions. TARGET_VXWORKS_RTP
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
156 is defined by vxworks.opt. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
157 #undef VXWORKS_GOTT_BASE
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
158 #define VXWORKS_GOTT_BASE "__GOTT_BASE__"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
159 #undef VXWORKS_GOTT_INDEX
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
160 #define VXWORKS_GOTT_INDEX "__GOTT_INDEX__"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
161
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
162 #undef PTRDIFF_TYPE
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
163 #define PTRDIFF_TYPE "int"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
164
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
165 #undef SIZE_TYPE
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
166 #define SIZE_TYPE "unsigned int"
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
167
111
kono
parents: 67
diff changeset
168 #undef TARGET_LIBC_HAS_FUNCTION
kono
parents: 67
diff changeset
169 #define TARGET_LIBC_HAS_FUNCTION no_c99_libc_has_function
kono
parents: 67
diff changeset
170
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
171 /* Both kernels and RTPs have the facilities required by this macro. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
172 #define TARGET_POSIX_IO
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
173
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
174 /* A VxWorks implementation of TARGET_OS_CPP_BUILTINS. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
175 #define VXWORKS_OS_CPP_BUILTINS() \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
176 do \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
177 { \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
178 builtin_define ("__vxworks"); \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
179 builtin_define ("__VXWORKS__"); \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
180 builtin_assert ("system=unix"); \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
181 if (TARGET_VXWORKS_RTP) \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
182 builtin_define ("__RTP__"); \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
183 else \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
184 builtin_define ("_WRS_KERNEL"); \
111
kono
parents: 67
diff changeset
185 builtin_define ("_VX_TOOL_FAMILY=gnu"); \
kono
parents: 67
diff changeset
186 builtin_define ("_VX_TOOL=gnu"); \
kono
parents: 67
diff changeset
187 if (TARGET_VXWORKS7) \
kono
parents: 67
diff changeset
188 { \
kono
parents: 67
diff changeset
189 builtin_define ("_VSB_CONFIG_FILE=<config/vsbConfig.h>"); \
kono
parents: 67
diff changeset
190 \
kono
parents: 67
diff changeset
191 /* _ALLOW_KEYWORD_MACROS is needed on VxWorks 7 to \
kono
parents: 67
diff changeset
192 prevent compilation failures triggered by our \
kono
parents: 67
diff changeset
193 definition of "inline" in ansidecl when "inline" \
kono
parents: 67
diff changeset
194 is not a keyword. */ \
kono
parents: 67
diff changeset
195 if (!flag_isoc99 && !c_dialect_cxx()) \
kono
parents: 67
diff changeset
196 builtin_define ("_ALLOW_KEYWORD_MACROS"); \
kono
parents: 67
diff changeset
197 } \
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
198 } \
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
199 while (0)
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
200
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
201 #define VXWORKS_KIND VXWORKS_KIND_NORMAL
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
202
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
203 /* The diab linker does not handle .gnu_attribute sections. */
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
204 #undef HAVE_AS_GNU_ATTRIBUTE