svn commit: trunk/uClibc/include

Mike Frysinger vapier at gentoo.org
Mon Nov 28 07:17:30 UTC 2005


On Sun, Nov 27, 2005 at 11:50:05PM +0100, Peter S. Mazinger wrote:
> On Sun, 27 Nov 2005, Mike Frysinger wrote:
> 
> > On Sat, Nov 26, 2005 at 05:35:53PM -0800, psm at uclibc.org wrote:
> > > Log:
> > > headers patched w/ sed -i 's:extern int errno:#include <errno.h>' linux/unistd.h fail here
> > > 
> > > --- trunk/uClibc/include/ssp-internal.h	2005-11-27 01:20:58 UTC (rev 12542)
> > > +++ trunk/uClibc/include/ssp-internal.h	2005-11-27 01:35:52 UTC (rev 12543)
> > > @@ -21,6 +21,10 @@
> > >  #include <signal.h>
> > >  #include <linux/unistd.h>
> > >  
> > > +#ifndef errno
> > > +extern int errno;
> > > +#endif
> > > +
> > 
> > uhh, what ?  doing 'extern int errno' will never work with TLS
> 
> can't tell you what TLS will do, but the gentoo unistd.h patch to 
> linux-headers (2.4.26-r1) killed the uClibc build.

no it doesnt

> Probably it will fail everywhere, when kernel syscalls are used.

this statement is just plain wrong as well

the reason __uClibc_main.os fails to build with SSP support is because
at the top of the file is this:
#define _ERRNO_H
which prevents errno from ever being defined by the errno headers

i dont know why ssp-internal.h is forced to be included by dl-osinfo.h,
but the issue can be fixed in __uClibc_main.c by moving the include of
ssp-internal.h from dl-osinfo.h to __uClibc_main.c and then adding this
before including the file:
#define errno *(__errno_location())
-mike



More information about the uClibc mailing list