[uClibc]#if defined(__GLIBC__) ???

Erik Andersen andersen at codepoet.org
Sat Nov 23 05:42:31 UTC 2002


On Fri Nov 22, 2002 at 07:27:08PM +0100, Steven Scholz wrote:
> Hi there,
> 
> does uClibc (or the uClibc toolchain) define some stuff like __GLIBC__ so I can
> test if the target is build with uClibc or with the real glibc?
> 
> I am asking because the PCMCIA CS 3.2.1 has the lines
> 
> #if defined(__GLIBC__) && (__GLIBC__ >= 2) && (__GLIBC_MINOR__ >= 1)
> #define USE_WORDEXP
> #include <wordexp.h>
> #else
> #include <glob.h>
> #endif
> 
> in the file cardmgr/lex_config.c. Although I am using uClibc toolchain the above
> expression seems to be true since he tries to include wordexp.h and of course
> fails!

See include/features.h...  __UCLIBC__, __UCLIBC_MAJOR__, 
__UCLIBC_MINOR__, and __UCLIBC_SUBLEVEL__ are all defined,

 -Erik

--
Erik B. Andersen             http://codepoet-consulting.com/
--This message was written using 73% post-consumer electrons--



More information about the uClibc mailing list