OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [newlib-1.18.0/] [newlib/] [libc/] [include/] [sys/] [config.h] - Blame information for rev 283

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 207 jeremybenn
#ifndef __SYS_CONFIG_H__
2
#define __SYS_CONFIG_H__
3
 
4
#include <machine/ieeefp.h>  /* floating point macros */
5
 
6
/* exceptions first */
7
#if defined(__H8500__) || defined(__W65__)
8
#define __SMALL_BITFIELDS
9
/* ???  This conditional is true for the h8500 and the w65, defining H8300
10
   in those cases probably isn't the right thing to do.  */
11
#define H8300 1
12
#endif
13
 
14
/* 16 bit integer machines */
15
#if defined(__Z8001__) || defined(__Z8002__) || defined(__H8500__) || defined(__W65__) || defined (__mn10200__) || defined (__AVR__)
16
 
17
#undef INT_MAX
18
#undef UINT_MAX
19
#define INT_MAX 32767
20
#define UINT_MAX 65535
21
#endif
22
 
23
#if defined (__H8300__) || defined (__H8300H__) || defined(__H8300S__) || defined (__H8300SX__)
24
#define __SMALL_BITFIELDS
25
#define H8300 1
26
#undef INT_MAX
27
#undef UINT_MAX
28
#define INT_MAX __INT_MAX__
29
#define UINT_MAX (__INT_MAX__ * 2U + 1)
30
#endif
31
 
32
#if defined (__xc16x__) || defined (__xc16xL__) || defined (__xc16xS__)
33
#define __SMALL_BITFIELDS
34
#endif
35
 
36
#ifdef __W65__
37
#define __SMALL_BITFIELDS
38
#endif
39
 
40
#if defined(__D10V__)
41
#define __SMALL_BITFIELDS
42
#undef INT_MAX
43
#undef UINT_MAX
44
#define INT_MAX __INT_MAX__
45
#define UINT_MAX (__INT_MAX__ * 2U + 1)
46
#define _POINTER_INT short
47
#endif
48
 
49
#if defined(__mc68hc11__) || defined(__mc68hc12__) || defined(__mc68hc1x__)
50
#undef INT_MAX
51
#undef UINT_MAX
52
#define INT_MAX __INT_MAX__
53
#define UINT_MAX (__INT_MAX__ * 2U + 1)
54
#define _POINTER_INT short
55
#endif
56
 
57
#ifdef ___AM29K__
58
#define _FLOAT_RET double
59
#endif
60
 
61
#ifdef __i386__
62
#ifndef __unix__
63
/* in other words, go32 */
64
#define _FLOAT_RET double
65
#endif
66
#if defined(__linux__) || defined(__RDOS__)
67
/* we want the reentrancy structure to be returned by a function */
68
#define __DYNAMIC_REENT__
69
#define HAVE_GETDATE
70
#define _HAVE_SYSTYPES
71
#define _READ_WRITE_RETURN_TYPE _ssize_t
72
#define __LARGE64_FILES 1
73
/* we use some glibc header files so turn on glibc large file feature */
74
#define _LARGEFILE64_SOURCE 1
75
#endif
76
#endif
77
 
78
#ifdef __mn10200__
79
#define __SMALL_BITFIELDS
80
#endif
81
 
82
#ifdef __AVR__
83
#define __SMALL_BITFIELDS
84
#define _POINTER_INT short
85
#endif
86
 
87
#ifdef __v850
88
#define __ATTRIBUTE_IMPURE_PTR__ __attribute__((__sda__))
89
#endif
90
 
91
/* For the PowerPC eabi, force the _impure_ptr to be in .sdata */
92
#if defined(__PPC__)
93
#if defined(_CALL_SYSV)
94
#define __ATTRIBUTE_IMPURE_PTR__ __attribute__((__section__(".sdata")))
95
#endif
96
#ifdef __SPE__
97
#define _LONG_DOUBLE double
98
#endif
99
#endif
100
 
101
/* Configure small REENT structure for Xilinx MicroBlaze platforms */
102
#if defined (__MICROBLAZE__)
103
#ifndef _REENT_SMALL
104
#define _REENT_SMALL
105
#endif
106
/* Xilinx XMK uses Unix98 mutex */
107
#ifdef __XMK__
108
#define _UNIX98_THREAD_MUTEX_ATTRIBUTES
109
#endif
110
#endif
111
 
112
#if defined(__mips__) && !defined(__rtems__)
113
#define __ATTRIBUTE_IMPURE_PTR__ __attribute__((__section__(".sdata")))
114
#endif
115
 
116
#ifdef __xstormy16__
117
#define __SMALL_BITFIELDS
118
#undef INT_MAX
119
#undef UINT_MAX
120
#define INT_MAX __INT_MAX__
121
#define UINT_MAX (__INT_MAX__ * 2U + 1)
122
#define MALLOC_ALIGNMENT 8
123
#define _POINTER_INT short
124
#define __BUFSIZ__ 16
125
#define _REENT_SMALL
126
#endif
127
#ifdef __m32c__
128
#define __SMALL_BITFIELDS
129
#undef INT_MAX
130
#undef UINT_MAX
131
#define INT_MAX __INT_MAX__
132
#define UINT_MAX (__INT_MAX__ * 2U + 1)
133
#define MALLOC_ALIGNMENT 8
134
#if defined(__r8c_cpu__) || defined(__m16c_cpu__)
135
#define _POINTER_INT short
136
#else
137
#define _POINTER_INT long
138
#endif
139
#define __BUFSIZ__ 16
140
#define _REENT_SMALL
141
#endif /* __m32c__ */
142
 
143
#ifdef __SPU__
144
#define MALLOC_ALIGNMENT 16
145
#define __CUSTOM_FILE_IO__
146
#endif
147
 
148
/* This block should be kept in sync with GCC's limits.h.  The point
149
   of having these definitions here is to not include limits.h, which
150
   would pollute the user namespace, while still using types of the
151
   the correct widths when deciding how to define __int32_t and
152
   __int64_t.  */
153
#ifndef __INT_MAX__
154
# ifdef INT_MAX
155
#  define __INT_MAX__ INT_MAX
156
# else
157
#  define __INT_MAX__ 2147483647
158
# endif
159
#endif
160
 
161
#ifndef __LONG_MAX__
162
# ifdef LONG_MAX
163
#  define __LONG_MAX__ LONG_MAX
164
# else
165
#  if defined (__alpha__) || (defined (__sparc__) && defined(__arch64__)) \
166
      || defined (__sparcv9)
167
#   define __LONG_MAX__ 9223372036854775807L
168
#  else
169
#   define __LONG_MAX__ 2147483647L
170
#  endif /* __alpha__ || sparc64 */
171
# endif
172
#endif
173
/* End of block that should be kept in sync with GCC's limits.h.  */
174
 
175
#ifndef _POINTER_INT
176
#define _POINTER_INT long
177
#endif
178
 
179
#ifdef __frv__
180
#define __ATTRIBUTE_IMPURE_PTR__ __attribute__((__section__(".sdata")))
181
#endif
182
#undef __RAND_MAX
183
#if __INT_MAX__ == 32767
184
#define __RAND_MAX 32767
185
#else
186
#define __RAND_MAX 0x7fffffff
187
#endif
188
 
189
#if defined(__CYGWIN__)
190
#include <cygwin/config.h>
191
#define __LINUX_ERRNO_EXTENSIONS__ 1
192
#define _MB_EXTENDED_CHARSETS_ALL 1
193
#if !defined (__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L)
194
#define __USE_XOPEN2K 1
195
#endif
196
#endif
197
 
198
#if defined(__rtems__)
199
#define __FILENAME_MAX__ 255
200
#define _READ_WRITE_RETURN_TYPE _ssize_t
201
#endif
202
 
203
#ifndef __EXPORT
204
#define __EXPORT
205
#endif
206
 
207
#ifndef __IMPORT
208
#define __IMPORT
209
#endif
210
 
211
/* Define return type of read/write routines.  In POSIX, the return type
212
   for read()/write() is "ssize_t" but legacy newlib code has been using
213
   "int" for some time.  If not specified, "int" is defaulted.  */
214
#ifndef _READ_WRITE_RETURN_TYPE
215
#define _READ_WRITE_RETURN_TYPE int
216
#endif
217
 
218
#ifndef __WCHAR_MAX__
219
#if __INT_MAX__ == 32767 || defined (_WIN32)
220
#define __WCHAR_MAX__ 0xffffu
221
#endif
222
#endif
223
 
224
/* See if small reent asked for at configuration time and
225
   is not chosen by the platform by default.  */
226
#ifdef _WANT_REENT_SMALL
227
#ifndef _REENT_SMALL
228
#define _REENT_SMALL
229
#endif
230
#endif
231
 
232
/* If _MB_EXTENDED_CHARSETS_ALL is set, we want all of the extended
233
   charsets.  The extended charsets add a few functions and a couple
234
   of tables of a few K each. */
235
#ifdef _MB_EXTENDED_CHARSETS_ALL
236
#define _MB_EXTENDED_CHARSETS_ISO 1
237
#define _MB_EXTENDED_CHARSETS_WINDOWS 1
238
#endif
239
 
240
#endif /* __SYS_CONFIG_H__ */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.