rev |
line source |
nuclear@0
|
1 /***************************************************************************/
|
nuclear@0
|
2 /* */
|
nuclear@0
|
3 /* ftconfig.h */
|
nuclear@0
|
4 /* */
|
nuclear@0
|
5 /* ANSI-specific configuration file (specification only). */
|
nuclear@0
|
6 /* */
|
nuclear@0
|
7 /* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2010 by */
|
nuclear@0
|
8 /* David Turner, Robert Wilhelm, and Werner Lemberg. */
|
nuclear@0
|
9 /* */
|
nuclear@0
|
10 /* This file is part of the FreeType project, and may only be used, */
|
nuclear@0
|
11 /* modified, and distributed under the terms of the FreeType project */
|
nuclear@0
|
12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
|
nuclear@0
|
13 /* this file you indicate that you have read the license and */
|
nuclear@0
|
14 /* understand and accept it fully. */
|
nuclear@0
|
15 /* */
|
nuclear@0
|
16 /***************************************************************************/
|
nuclear@0
|
17
|
nuclear@0
|
18
|
nuclear@0
|
19 /*************************************************************************/
|
nuclear@0
|
20 /* */
|
nuclear@0
|
21 /* This header file contains a number of macro definitions that are used */
|
nuclear@0
|
22 /* by the rest of the engine. Most of the macros here are automatically */
|
nuclear@0
|
23 /* determined at compile time, and you should not need to change it to */
|
nuclear@0
|
24 /* port FreeType, except to compile the library with a non-ANSI */
|
nuclear@0
|
25 /* compiler. */
|
nuclear@0
|
26 /* */
|
nuclear@0
|
27 /* Note however that if some specific modifications are needed, we */
|
nuclear@0
|
28 /* advise you to place a modified copy in your build directory. */
|
nuclear@0
|
29 /* */
|
nuclear@0
|
30 /* The build directory is usually `freetype/builds/<system>', and */
|
nuclear@0
|
31 /* contains system-specific files that are always included first when */
|
nuclear@0
|
32 /* building the library. */
|
nuclear@0
|
33 /* */
|
nuclear@0
|
34 /* This ANSI version should stay in `include/freetype/config'. */
|
nuclear@0
|
35 /* */
|
nuclear@0
|
36 /*************************************************************************/
|
nuclear@0
|
37
|
nuclear@0
|
38 #ifndef __FTCONFIG_H__
|
nuclear@0
|
39 #define __FTCONFIG_H__
|
nuclear@0
|
40
|
nuclear@0
|
41 #include <ft2build.h>
|
nuclear@0
|
42 #include FT_CONFIG_OPTIONS_H
|
nuclear@0
|
43 #include FT_CONFIG_STANDARD_LIBRARY_H
|
nuclear@0
|
44
|
nuclear@0
|
45
|
nuclear@0
|
46 FT_BEGIN_HEADER
|
nuclear@0
|
47
|
nuclear@0
|
48
|
nuclear@0
|
49 /*************************************************************************/
|
nuclear@0
|
50 /* */
|
nuclear@0
|
51 /* PLATFORM-SPECIFIC CONFIGURATION MACROS */
|
nuclear@0
|
52 /* */
|
nuclear@0
|
53 /* These macros can be toggled to suit a specific system. The current */
|
nuclear@0
|
54 /* ones are defaults used to compile FreeType in an ANSI C environment */
|
nuclear@0
|
55 /* (16bit compilers are also supported). Copy this file to your own */
|
nuclear@0
|
56 /* `freetype/builds/<system>' directory, and edit it to port the engine. */
|
nuclear@0
|
57 /* */
|
nuclear@0
|
58 /*************************************************************************/
|
nuclear@0
|
59
|
nuclear@0
|
60
|
nuclear@0
|
61 /* There are systems (like the Texas Instruments 'C54x) where a `char' */
|
nuclear@0
|
62 /* has 16 bits. ANSI C says that sizeof(char) is always 1. Since an */
|
nuclear@0
|
63 /* `int' has 16 bits also for this system, sizeof(int) gives 1 which */
|
nuclear@0
|
64 /* is probably unexpected. */
|
nuclear@0
|
65 /* */
|
nuclear@0
|
66 /* `CHAR_BIT' (defined in limits.h) gives the number of bits in a */
|
nuclear@0
|
67 /* `char' type. */
|
nuclear@0
|
68
|
nuclear@0
|
69 #ifndef FT_CHAR_BIT
|
nuclear@0
|
70 #define FT_CHAR_BIT CHAR_BIT
|
nuclear@0
|
71 #endif
|
nuclear@0
|
72
|
nuclear@0
|
73
|
nuclear@0
|
74 /* The size of an `int' type. */
|
nuclear@0
|
75 #if FT_UINT_MAX == 0xFFFFUL
|
nuclear@0
|
76 #define FT_SIZEOF_INT (16 / FT_CHAR_BIT)
|
nuclear@0
|
77 #elif FT_UINT_MAX == 0xFFFFFFFFUL
|
nuclear@0
|
78 #define FT_SIZEOF_INT (32 / FT_CHAR_BIT)
|
nuclear@0
|
79 #elif FT_UINT_MAX > 0xFFFFFFFFUL && FT_UINT_MAX == 0xFFFFFFFFFFFFFFFFUL
|
nuclear@0
|
80 #define FT_SIZEOF_INT (64 / FT_CHAR_BIT)
|
nuclear@0
|
81 #else
|
nuclear@0
|
82 #error "Unsupported size of `int' type!"
|
nuclear@0
|
83 #endif
|
nuclear@0
|
84
|
nuclear@0
|
85 /* The size of a `long' type. A five-byte `long' (as used e.g. on the */
|
nuclear@0
|
86 /* DM642) is recognized but avoided. */
|
nuclear@0
|
87 #if FT_ULONG_MAX == 0xFFFFFFFFUL
|
nuclear@0
|
88 #define FT_SIZEOF_LONG (32 / FT_CHAR_BIT)
|
nuclear@0
|
89 #elif FT_ULONG_MAX > 0xFFFFFFFFUL && FT_ULONG_MAX == 0xFFFFFFFFFFUL
|
nuclear@0
|
90 #define FT_SIZEOF_LONG (32 / FT_CHAR_BIT)
|
nuclear@0
|
91 #elif FT_ULONG_MAX > 0xFFFFFFFFUL && FT_ULONG_MAX == 0xFFFFFFFFFFFFFFFFUL
|
nuclear@0
|
92 #define FT_SIZEOF_LONG (64 / FT_CHAR_BIT)
|
nuclear@0
|
93 #else
|
nuclear@0
|
94 #error "Unsupported size of `long' type!"
|
nuclear@0
|
95 #endif
|
nuclear@0
|
96
|
nuclear@0
|
97
|
nuclear@0
|
98 /* Preferred alignment of data */
|
nuclear@0
|
99 #define FT_ALIGNMENT 8
|
nuclear@0
|
100
|
nuclear@0
|
101
|
nuclear@0
|
102 /* FT_UNUSED is a macro used to indicate that a given parameter is not */
|
nuclear@0
|
103 /* used -- this is only used to get rid of unpleasant compiler warnings */
|
nuclear@0
|
104 #ifndef FT_UNUSED
|
nuclear@0
|
105 #define FT_UNUSED( arg ) ( (arg) = (arg) )
|
nuclear@0
|
106 #endif
|
nuclear@0
|
107
|
nuclear@0
|
108
|
nuclear@0
|
109 /*************************************************************************/
|
nuclear@0
|
110 /* */
|
nuclear@0
|
111 /* AUTOMATIC CONFIGURATION MACROS */
|
nuclear@0
|
112 /* */
|
nuclear@0
|
113 /* These macros are computed from the ones defined above. Don't touch */
|
nuclear@0
|
114 /* their definition, unless you know precisely what you are doing. No */
|
nuclear@0
|
115 /* porter should need to mess with them. */
|
nuclear@0
|
116 /* */
|
nuclear@0
|
117 /*************************************************************************/
|
nuclear@0
|
118
|
nuclear@0
|
119
|
nuclear@0
|
120 /*************************************************************************/
|
nuclear@0
|
121 /* */
|
nuclear@0
|
122 /* Mac support */
|
nuclear@0
|
123 /* */
|
nuclear@0
|
124 /* This is the only necessary change, so it is defined here instead */
|
nuclear@0
|
125 /* providing a new configuration file. */
|
nuclear@0
|
126 /* */
|
nuclear@0
|
127 #if ( defined( __APPLE__ ) && !defined( DARWIN_NO_CARBON ) ) || \
|
nuclear@0
|
128 ( defined( __MWERKS__ ) && defined( macintosh ) )
|
nuclear@0
|
129 /* no Carbon frameworks for 64bit 10.4.x */
|
nuclear@0
|
130 #include "AvailabilityMacros.h"
|
nuclear@0
|
131 #if defined( __LP64__ ) && \
|
nuclear@0
|
132 ( MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_4 )
|
nuclear@0
|
133 #define DARWIN_NO_CARBON 1
|
nuclear@0
|
134 #else
|
nuclear@0
|
135 #define FT_MACINTOSH 1
|
nuclear@0
|
136 #endif
|
nuclear@0
|
137
|
nuclear@0
|
138 #elif defined( __SC__ ) || defined( __MRC__ )
|
nuclear@0
|
139 /* Classic MacOS compilers */
|
nuclear@0
|
140 #include "ConditionalMacros.h"
|
nuclear@0
|
141 #if TARGET_OS_MAC
|
nuclear@0
|
142 #define FT_MACINTOSH 1
|
nuclear@0
|
143 #endif
|
nuclear@0
|
144
|
nuclear@0
|
145 #endif
|
nuclear@0
|
146
|
nuclear@0
|
147
|
nuclear@0
|
148 /*************************************************************************/
|
nuclear@0
|
149 /* */
|
nuclear@0
|
150 /* <Section> */
|
nuclear@0
|
151 /* basic_types */
|
nuclear@0
|
152 /* */
|
nuclear@0
|
153 /*************************************************************************/
|
nuclear@0
|
154
|
nuclear@0
|
155
|
nuclear@0
|
156 /*************************************************************************/
|
nuclear@0
|
157 /* */
|
nuclear@0
|
158 /* <Type> */
|
nuclear@0
|
159 /* FT_Int16 */
|
nuclear@0
|
160 /* */
|
nuclear@0
|
161 /* <Description> */
|
nuclear@0
|
162 /* A typedef for a 16bit signed integer type. */
|
nuclear@0
|
163 /* */
|
nuclear@0
|
164 typedef signed short FT_Int16;
|
nuclear@0
|
165
|
nuclear@0
|
166
|
nuclear@0
|
167 /*************************************************************************/
|
nuclear@0
|
168 /* */
|
nuclear@0
|
169 /* <Type> */
|
nuclear@0
|
170 /* FT_UInt16 */
|
nuclear@0
|
171 /* */
|
nuclear@0
|
172 /* <Description> */
|
nuclear@0
|
173 /* A typedef for a 16bit unsigned integer type. */
|
nuclear@0
|
174 /* */
|
nuclear@0
|
175 typedef unsigned short FT_UInt16;
|
nuclear@0
|
176
|
nuclear@0
|
177 /* */
|
nuclear@0
|
178
|
nuclear@0
|
179
|
nuclear@0
|
180 /* this #if 0 ... #endif clause is for documentation purposes */
|
nuclear@0
|
181 #if 0
|
nuclear@0
|
182
|
nuclear@0
|
183 /*************************************************************************/
|
nuclear@0
|
184 /* */
|
nuclear@0
|
185 /* <Type> */
|
nuclear@0
|
186 /* FT_Int32 */
|
nuclear@0
|
187 /* */
|
nuclear@0
|
188 /* <Description> */
|
nuclear@0
|
189 /* A typedef for a 32bit signed integer type. The size depends on */
|
nuclear@0
|
190 /* the configuration. */
|
nuclear@0
|
191 /* */
|
nuclear@0
|
192 typedef signed XXX FT_Int32;
|
nuclear@0
|
193
|
nuclear@0
|
194
|
nuclear@0
|
195 /*************************************************************************/
|
nuclear@0
|
196 /* */
|
nuclear@0
|
197 /* <Type> */
|
nuclear@0
|
198 /* FT_UInt32 */
|
nuclear@0
|
199 /* */
|
nuclear@0
|
200 /* A typedef for a 32bit unsigned integer type. The size depends on */
|
nuclear@0
|
201 /* the configuration. */
|
nuclear@0
|
202 /* */
|
nuclear@0
|
203 typedef unsigned XXX FT_UInt32;
|
nuclear@0
|
204
|
nuclear@0
|
205 /* */
|
nuclear@0
|
206
|
nuclear@0
|
207 #endif
|
nuclear@0
|
208
|
nuclear@0
|
209 #if FT_SIZEOF_INT == (32 / FT_CHAR_BIT)
|
nuclear@0
|
210
|
nuclear@0
|
211 typedef signed int FT_Int32;
|
nuclear@0
|
212 typedef unsigned int FT_UInt32;
|
nuclear@0
|
213
|
nuclear@0
|
214 #elif FT_SIZEOF_LONG == (32 / FT_CHAR_BIT)
|
nuclear@0
|
215
|
nuclear@0
|
216 typedef signed long FT_Int32;
|
nuclear@0
|
217 typedef unsigned long FT_UInt32;
|
nuclear@0
|
218
|
nuclear@0
|
219 #else
|
nuclear@0
|
220 #error "no 32bit type found -- please check your configuration files"
|
nuclear@0
|
221 #endif
|
nuclear@0
|
222
|
nuclear@0
|
223
|
nuclear@0
|
224 /* look up an integer type that is at least 32 bits */
|
nuclear@0
|
225 #if FT_SIZEOF_INT >= (32 / FT_CHAR_BIT)
|
nuclear@0
|
226
|
nuclear@0
|
227 typedef int FT_Fast;
|
nuclear@0
|
228 typedef unsigned int FT_UFast;
|
nuclear@0
|
229
|
nuclear@0
|
230 #elif FT_SIZEOF_LONG >= (32 / FT_CHAR_BIT)
|
nuclear@0
|
231
|
nuclear@0
|
232 typedef long FT_Fast;
|
nuclear@0
|
233 typedef unsigned long FT_UFast;
|
nuclear@0
|
234
|
nuclear@0
|
235 #endif
|
nuclear@0
|
236
|
nuclear@0
|
237
|
nuclear@0
|
238 /* determine whether we have a 64-bit int type for platforms without */
|
nuclear@0
|
239 /* Autoconf */
|
nuclear@0
|
240 #if FT_SIZEOF_LONG == (64 / FT_CHAR_BIT)
|
nuclear@0
|
241
|
nuclear@0
|
242 /* FT_LONG64 must be defined if a 64-bit type is available */
|
nuclear@0
|
243 #define FT_LONG64
|
nuclear@0
|
244 #define FT_INT64 long
|
nuclear@0
|
245
|
nuclear@0
|
246 #elif defined( _MSC_VER ) && _MSC_VER >= 900 /* Visual C++ (and Intel C++) */
|
nuclear@0
|
247
|
nuclear@0
|
248 /* this compiler provides the __int64 type */
|
nuclear@0
|
249 #define FT_LONG64
|
nuclear@0
|
250 #define FT_INT64 __int64
|
nuclear@0
|
251
|
nuclear@0
|
252 #elif defined( __BORLANDC__ ) /* Borland C++ */
|
nuclear@0
|
253
|
nuclear@0
|
254 /* XXXX: We should probably check the value of __BORLANDC__ in order */
|
nuclear@0
|
255 /* to test the compiler version. */
|
nuclear@0
|
256
|
nuclear@0
|
257 /* this compiler provides the __int64 type */
|
nuclear@0
|
258 #define FT_LONG64
|
nuclear@0
|
259 #define FT_INT64 __int64
|
nuclear@0
|
260
|
nuclear@0
|
261 #elif defined( __WATCOMC__ ) /* Watcom C++ */
|
nuclear@0
|
262
|
nuclear@0
|
263 /* Watcom doesn't provide 64-bit data types */
|
nuclear@0
|
264
|
nuclear@0
|
265 #elif defined( __MWERKS__ ) /* Metrowerks CodeWarrior */
|
nuclear@0
|
266
|
nuclear@0
|
267 #define FT_LONG64
|
nuclear@0
|
268 #define FT_INT64 long long int
|
nuclear@0
|
269
|
nuclear@0
|
270 #elif defined( __GNUC__ )
|
nuclear@0
|
271
|
nuclear@0
|
272 /* GCC provides the `long long' type */
|
nuclear@0
|
273 #define FT_LONG64
|
nuclear@0
|
274 #define FT_INT64 long long int
|
nuclear@0
|
275
|
nuclear@0
|
276 #endif /* FT_SIZEOF_LONG == (64 / FT_CHAR_BIT) */
|
nuclear@0
|
277
|
nuclear@0
|
278
|
nuclear@0
|
279 /*************************************************************************/
|
nuclear@0
|
280 /* */
|
nuclear@0
|
281 /* A 64-bit data type will create compilation problems if you compile */
|
nuclear@0
|
282 /* in strict ANSI mode. To avoid them, we disable its use if __STDC__ */
|
nuclear@0
|
283 /* is defined. You can however ignore this rule by defining the */
|
nuclear@0
|
284 /* FT_CONFIG_OPTION_FORCE_INT64 configuration macro. */
|
nuclear@0
|
285 /* */
|
nuclear@0
|
286 #if defined( FT_LONG64 ) && !defined( FT_CONFIG_OPTION_FORCE_INT64 )
|
nuclear@0
|
287
|
nuclear@0
|
288 #ifdef __STDC__
|
nuclear@0
|
289
|
nuclear@0
|
290 /* undefine the 64-bit macros in strict ANSI compilation mode */
|
nuclear@0
|
291 #undef FT_LONG64
|
nuclear@0
|
292 #undef FT_INT64
|
nuclear@0
|
293
|
nuclear@0
|
294 #endif /* __STDC__ */
|
nuclear@0
|
295
|
nuclear@0
|
296 #endif /* FT_LONG64 && !FT_CONFIG_OPTION_FORCE_INT64 */
|
nuclear@0
|
297
|
nuclear@0
|
298
|
nuclear@0
|
299 #define FT_BEGIN_STMNT do {
|
nuclear@0
|
300 #define FT_END_STMNT } while ( 0 )
|
nuclear@0
|
301 #define FT_DUMMY_STMNT FT_BEGIN_STMNT FT_END_STMNT
|
nuclear@0
|
302
|
nuclear@0
|
303
|
nuclear@0
|
304 #ifndef FT_CONFIG_OPTION_NO_ASSEMBLER
|
nuclear@0
|
305 /* Provide assembler fragments for performance-critical functions. */
|
nuclear@0
|
306 /* These must be defined `static __inline__' with GCC. */
|
nuclear@0
|
307
|
nuclear@0
|
308 #if defined( __CC_ARM ) || defined( __ARMCC__ ) /* RVCT */
|
nuclear@0
|
309 #define FT_MULFIX_ASSEMBLER FT_MulFix_arm
|
nuclear@0
|
310
|
nuclear@0
|
311 /* documentation is in freetype.h */
|
nuclear@0
|
312
|
nuclear@0
|
313 static __inline FT_Int32
|
nuclear@0
|
314 FT_MulFix_arm( FT_Int32 a,
|
nuclear@0
|
315 FT_Int32 b )
|
nuclear@0
|
316 {
|
nuclear@0
|
317 register FT_Int32 t, t2;
|
nuclear@0
|
318
|
nuclear@0
|
319
|
nuclear@0
|
320 __asm
|
nuclear@0
|
321 {
|
nuclear@0
|
322 smull t2, t, b, a /* (lo=t2,hi=t) = a*b */
|
nuclear@0
|
323 mov a, t, asr #31 /* a = (hi >> 31) */
|
nuclear@0
|
324 add a, a, #0x8000 /* a += 0x8000 */
|
nuclear@0
|
325 adds t2, t2, a /* t2 += a */
|
nuclear@0
|
326 adc t, t, #0 /* t += carry */
|
nuclear@0
|
327 mov a, t2, lsr #16 /* a = t2 >> 16 */
|
nuclear@0
|
328 orr a, a, t, lsl #16 /* a |= t << 16 */
|
nuclear@0
|
329 }
|
nuclear@0
|
330 return a;
|
nuclear@0
|
331 }
|
nuclear@0
|
332
|
nuclear@0
|
333 #endif /* __CC_ARM || __ARMCC__ */
|
nuclear@0
|
334
|
nuclear@0
|
335
|
nuclear@0
|
336 #ifdef __GNUC__
|
nuclear@0
|
337
|
nuclear@0
|
338 #if defined( __arm__ ) && !defined( __thumb__ ) && \
|
nuclear@0
|
339 !( defined( __CC_ARM ) || defined( __ARMCC__ ) )
|
nuclear@0
|
340 #define FT_MULFIX_ASSEMBLER FT_MulFix_arm
|
nuclear@0
|
341
|
nuclear@0
|
342 /* documentation is in freetype.h */
|
nuclear@0
|
343
|
nuclear@0
|
344 static __inline__ FT_Int32
|
nuclear@0
|
345 FT_MulFix_arm( FT_Int32 a,
|
nuclear@0
|
346 FT_Int32 b )
|
nuclear@0
|
347 {
|
nuclear@0
|
348 register FT_Int32 t, t2;
|
nuclear@0
|
349
|
nuclear@0
|
350
|
nuclear@0
|
351 __asm__ __volatile__ (
|
nuclear@0
|
352 "smull %1, %2, %4, %3\n\t" /* (lo=%1,hi=%2) = a*b */
|
nuclear@0
|
353 "mov %0, %2, asr #31\n\t" /* %0 = (hi >> 31) */
|
nuclear@0
|
354 "add %0, %0, #0x8000\n\t" /* %0 += 0x8000 */
|
nuclear@0
|
355 "adds %1, %1, %0\n\t" /* %1 += %0 */
|
nuclear@0
|
356 "adc %2, %2, #0\n\t" /* %2 += carry */
|
nuclear@0
|
357 "mov %0, %1, lsr #16\n\t" /* %0 = %1 >> 16 */
|
nuclear@0
|
358 "orr %0, %2, lsl #16\n\t" /* %0 |= %2 << 16 */
|
nuclear@0
|
359 : "=r"(a), "=&r"(t2), "=&r"(t)
|
nuclear@0
|
360 : "r"(a), "r"(b) );
|
nuclear@0
|
361 return a;
|
nuclear@0
|
362 }
|
nuclear@0
|
363
|
nuclear@0
|
364 #endif /* __arm__ && !__thumb__ && !( __CC_ARM || __ARMCC__ ) */
|
nuclear@0
|
365
|
nuclear@0
|
366 #if defined( __i386__ )
|
nuclear@0
|
367 #define FT_MULFIX_ASSEMBLER FT_MulFix_i386
|
nuclear@0
|
368
|
nuclear@0
|
369 /* documentation is in freetype.h */
|
nuclear@0
|
370
|
nuclear@0
|
371 static __inline__ FT_Int32
|
nuclear@0
|
372 FT_MulFix_i386( FT_Int32 a,
|
nuclear@0
|
373 FT_Int32 b )
|
nuclear@0
|
374 {
|
nuclear@0
|
375 register FT_Int32 result;
|
nuclear@0
|
376
|
nuclear@0
|
377
|
nuclear@0
|
378 __asm__ __volatile__ (
|
nuclear@0
|
379 "imul %%edx\n"
|
nuclear@0
|
380 "movl %%edx, %%ecx\n"
|
nuclear@0
|
381 "sarl $31, %%ecx\n"
|
nuclear@0
|
382 "addl $0x8000, %%ecx\n"
|
nuclear@0
|
383 "addl %%ecx, %%eax\n"
|
nuclear@0
|
384 "adcl $0, %%edx\n"
|
nuclear@0
|
385 "shrl $16, %%eax\n"
|
nuclear@0
|
386 "shll $16, %%edx\n"
|
nuclear@0
|
387 "addl %%edx, %%eax\n"
|
nuclear@0
|
388 : "=a"(result), "=d"(b)
|
nuclear@0
|
389 : "a"(a), "d"(b)
|
nuclear@0
|
390 : "%ecx", "cc" );
|
nuclear@0
|
391 return result;
|
nuclear@0
|
392 }
|
nuclear@0
|
393
|
nuclear@0
|
394 #endif /* i386 */
|
nuclear@0
|
395
|
nuclear@0
|
396 #endif /* __GNUC__ */
|
nuclear@0
|
397
|
nuclear@0
|
398 #endif /* !FT_CONFIG_OPTION_NO_ASSEMBLER */
|
nuclear@0
|
399
|
nuclear@0
|
400
|
nuclear@0
|
401 #ifdef FT_CONFIG_OPTION_INLINE_MULFIX
|
nuclear@0
|
402 #ifdef FT_MULFIX_ASSEMBLER
|
nuclear@0
|
403 #define FT_MULFIX_INLINED FT_MULFIX_ASSEMBLER
|
nuclear@0
|
404 #endif
|
nuclear@0
|
405 #endif
|
nuclear@0
|
406
|
nuclear@0
|
407
|
nuclear@0
|
408 #ifdef FT_MAKE_OPTION_SINGLE_OBJECT
|
nuclear@0
|
409
|
nuclear@0
|
410 #define FT_LOCAL( x ) static x
|
nuclear@0
|
411 #define FT_LOCAL_DEF( x ) static x
|
nuclear@0
|
412
|
nuclear@0
|
413 #else
|
nuclear@0
|
414
|
nuclear@0
|
415 #ifdef __cplusplus
|
nuclear@0
|
416 #define FT_LOCAL( x ) extern "C" x
|
nuclear@0
|
417 #define FT_LOCAL_DEF( x ) extern "C" x
|
nuclear@0
|
418 #else
|
nuclear@0
|
419 #define FT_LOCAL( x ) extern x
|
nuclear@0
|
420 #define FT_LOCAL_DEF( x ) x
|
nuclear@0
|
421 #endif
|
nuclear@0
|
422
|
nuclear@0
|
423 #endif /* FT_MAKE_OPTION_SINGLE_OBJECT */
|
nuclear@0
|
424
|
nuclear@0
|
425
|
nuclear@0
|
426 #ifndef FT_BASE
|
nuclear@0
|
427
|
nuclear@0
|
428 #ifdef __cplusplus
|
nuclear@0
|
429 #define FT_BASE( x ) extern "C" x
|
nuclear@0
|
430 #else
|
nuclear@0
|
431 #define FT_BASE( x ) extern x
|
nuclear@0
|
432 #endif
|
nuclear@0
|
433
|
nuclear@0
|
434 #endif /* !FT_BASE */
|
nuclear@0
|
435
|
nuclear@0
|
436
|
nuclear@0
|
437 #ifndef FT_BASE_DEF
|
nuclear@0
|
438
|
nuclear@0
|
439 #ifdef __cplusplus
|
nuclear@0
|
440 #define FT_BASE_DEF( x ) x
|
nuclear@0
|
441 #else
|
nuclear@0
|
442 #define FT_BASE_DEF( x ) x
|
nuclear@0
|
443 #endif
|
nuclear@0
|
444
|
nuclear@0
|
445 #endif /* !FT_BASE_DEF */
|
nuclear@0
|
446
|
nuclear@0
|
447
|
nuclear@0
|
448 #ifndef FT_EXPORT
|
nuclear@0
|
449
|
nuclear@0
|
450 #ifdef __cplusplus
|
nuclear@0
|
451 #define FT_EXPORT( x ) extern "C" x
|
nuclear@0
|
452 #else
|
nuclear@0
|
453 #define FT_EXPORT( x ) extern x
|
nuclear@0
|
454 #endif
|
nuclear@0
|
455
|
nuclear@0
|
456 #endif /* !FT_EXPORT */
|
nuclear@0
|
457
|
nuclear@0
|
458
|
nuclear@0
|
459 #ifndef FT_EXPORT_DEF
|
nuclear@0
|
460
|
nuclear@0
|
461 #ifdef __cplusplus
|
nuclear@0
|
462 #define FT_EXPORT_DEF( x ) extern "C" x
|
nuclear@0
|
463 #else
|
nuclear@0
|
464 #define FT_EXPORT_DEF( x ) extern x
|
nuclear@0
|
465 #endif
|
nuclear@0
|
466
|
nuclear@0
|
467 #endif /* !FT_EXPORT_DEF */
|
nuclear@0
|
468
|
nuclear@0
|
469
|
nuclear@0
|
470 #ifndef FT_EXPORT_VAR
|
nuclear@0
|
471
|
nuclear@0
|
472 #ifdef __cplusplus
|
nuclear@0
|
473 #define FT_EXPORT_VAR( x ) extern "C" x
|
nuclear@0
|
474 #else
|
nuclear@0
|
475 #define FT_EXPORT_VAR( x ) extern x
|
nuclear@0
|
476 #endif
|
nuclear@0
|
477
|
nuclear@0
|
478 #endif /* !FT_EXPORT_VAR */
|
nuclear@0
|
479
|
nuclear@0
|
480 /* The following macros are needed to compile the library with a */
|
nuclear@0
|
481 /* C++ compiler and with 16bit compilers. */
|
nuclear@0
|
482 /* */
|
nuclear@0
|
483
|
nuclear@0
|
484 /* This is special. Within C++, you must specify `extern "C"' for */
|
nuclear@0
|
485 /* functions which are used via function pointers, and you also */
|
nuclear@0
|
486 /* must do that for structures which contain function pointers to */
|
nuclear@0
|
487 /* assure C linkage -- it's not possible to have (local) anonymous */
|
nuclear@0
|
488 /* functions which are accessed by (global) function pointers. */
|
nuclear@0
|
489 /* */
|
nuclear@0
|
490 /* */
|
nuclear@0
|
491 /* FT_CALLBACK_DEF is used to _define_ a callback function. */
|
nuclear@0
|
492 /* */
|
nuclear@0
|
493 /* FT_CALLBACK_TABLE is used to _declare_ a constant variable that */
|
nuclear@0
|
494 /* contains pointers to callback functions. */
|
nuclear@0
|
495 /* */
|
nuclear@0
|
496 /* FT_CALLBACK_TABLE_DEF is used to _define_ a constant variable */
|
nuclear@0
|
497 /* that contains pointers to callback functions. */
|
nuclear@0
|
498 /* */
|
nuclear@0
|
499 /* */
|
nuclear@0
|
500 /* Some 16bit compilers have to redefine these macros to insert */
|
nuclear@0
|
501 /* the infamous `_cdecl' or `__fastcall' declarations. */
|
nuclear@0
|
502 /* */
|
nuclear@0
|
503 #ifndef FT_CALLBACK_DEF
|
nuclear@0
|
504 #ifdef __cplusplus
|
nuclear@0
|
505 #define FT_CALLBACK_DEF( x ) extern "C" x
|
nuclear@0
|
506 #else
|
nuclear@0
|
507 #define FT_CALLBACK_DEF( x ) static x
|
nuclear@0
|
508 #endif
|
nuclear@0
|
509 #endif /* FT_CALLBACK_DEF */
|
nuclear@0
|
510
|
nuclear@0
|
511 #ifndef FT_CALLBACK_TABLE
|
nuclear@0
|
512 #ifdef __cplusplus
|
nuclear@0
|
513 #define FT_CALLBACK_TABLE extern "C"
|
nuclear@0
|
514 #define FT_CALLBACK_TABLE_DEF extern "C"
|
nuclear@0
|
515 #else
|
nuclear@0
|
516 #define FT_CALLBACK_TABLE extern
|
nuclear@0
|
517 #define FT_CALLBACK_TABLE_DEF /* nothing */
|
nuclear@0
|
518 #endif
|
nuclear@0
|
519 #endif /* FT_CALLBACK_TABLE */
|
nuclear@0
|
520
|
nuclear@0
|
521
|
nuclear@0
|
522 FT_END_HEADER
|
nuclear@0
|
523
|
nuclear@0
|
524
|
nuclear@0
|
525 #endif /* __FTCONFIG_H__ */
|
nuclear@0
|
526
|
nuclear@0
|
527
|
nuclear@0
|
528 /* END */
|