OSDN Git Service

Added Vladimir's ctype locale support. Make Config setting visible in features.h...
[uclinux-h8/uClibc.git] / include / features.h
1 #ifndef __FEATURES_H
2 #define __FEATURES_H
3
4
5 /* Major and minor version number of the uClibc library package.  Use
6    these macros to test for features in specific releases.  */
7 #define __UCLIBC__              0
8 #define __UCLIBC_MAJOR__        9
9 #define __UCLIBC_MINOR__        5
10
11 /*  There is an unwholesomely huge amount of code out there that depends on the
12  *  presence of GNU libc header files.  We have GNU libc header files.  So here
13  *  we commit a horrible sin.  At this point, we _lie_ and claim to be GNU libc
14  *  to make things like /usr/include/linux/socket.h and lots of apps work as
15  *  their developers intended.  This is IMHO, pardonable, since these defines
16  *  are not really intended to check for the presence of a particular library,
17  *  but rather are used to define an _interface_.  */
18 #if !defined __LIBC__ || defined __FORCE_GLIBC__ 
19 #   define __GNU_LIBRARY__ 6
20 #   define __GLIBC__       2
21 #   define __GLIBC_MINOR__ 1
22 #endif  
23
24 /* Make a half-hearted attempt to accomodate non-gcc compilers */
25 #ifndef __GNUC__
26 #define __attribute(foo)  /* Ignore */
27 #endif
28
29 /* __restrict is known in EGCS 1.2 and above. */
30 #if !defined __GNUC__ || __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 92)
31 # define __restrict     /* Ignore */
32 #endif
33
34
35 #ifdef __STDC__
36
37 #define __P(x)      x
38 #define __PMT(x)    x
39 #ifndef __const
40 #define __const const
41 #endif
42
43 /* Almost ansi */
44 #if __STDC__ != 1
45 #ifndef const
46 #define const
47 #endif
48 #define volatile
49 #endif
50
51 #else /* K&R */
52
53 #define __P(x) ()
54 #ifndef __const
55 #define __const
56 #endif
57 #ifndef const
58 #define const
59 #endif
60 #define volatile
61
62 #endif
63
64 /* No C++ */
65 #define __BEGIN_DECLS
66 #define __END_DECLS
67
68 /* GNUish things */
69 #define __CONSTVALUE
70 #define __CONSTVALUE2
71
72 #define __USE_BSD
73 #define __USE_MISC
74 #define __USE_POSIX
75 #define __USE_POSIX2
76 #define __USE_XOPEN
77
78 #undef  __KERNEL_STRICT_NAMES
79 #ifndef _LOOSE_KERNEL_NAMES
80 # define __KERNEL_STRICT_NAMES
81 #endif
82
83 #ifdef  _GNU_SOURCE
84 # define __USE_GNU      1
85 #endif
86
87 #include <sys/cdefs.h>
88
89 #define __need_uClibc_config_h
90 #include <bits/uClibc_config.h>
91 #undef __need_uClibc_config_h
92
93 #endif
94