|
|
Rockbox mail archiveSubject: Re: Getting Sim to build on FC4Re: Getting Sim to build on FC4
From: George Styles <ripnetuk_at_gmail.com>
Date: 2005-10-28
It would seem that errno.c also contains a (non extern?) definition
It also seems to be defined seperately in
apps/codecs/vorbis.c:int errno;
as well.
Changing the definition in errno.h to extern __thread int errno;
Any change of some help developing a patch to fix this? i think the
Here is a compelte cvs diff of a working (well compiling at least) sim on FC4:
Index: apps/codecs/vorbis.c
--- > //int errno; Index: apps/tagdb/parser.c =================================================================== RCS file: /cvsroot/rockbox/apps/tagdb/parser.c,v retrieving revision 1.1 diff -r1.1 parser.c 7c7 < int errno; --- > //int errno; Index: firmware/common/errno.c =================================================================== RCS file: /cvsroot/rockbox/firmware/common/errno.c,v retrieving revision 1.1 diff -r1.1 errno.c 1c1 < int errno; --- > //int errno; Index: firmware/include/errno.h =================================================================== RCS file: /cvsroot/rockbox/firmware/include/errno.h,v retrieving revision 1.1 diff -r1.1 errno.h 7c7 < extern int errno; --- > extern __thread int errno; :) g On 10/28/05, George Styles <ripnetuk@gmail.com> wrote: > Hi, > > I have upgraded my Mandrake box to FC4, and can no longer compile the > rockbox sim :( > > The error I get is: > > > LD rockboxui > /usr/bin/ld: errno: TLS definition in /lib/libc.so.6 section .tbss mismatches no > n-TLS reference in /projects/rockbox/cvs/rockbox/build/sim/librockbox.a(errno.o) > /lib/libc.so.6: could not read symbols: Bad value > collect2: ld returned 1 exit status > make[1]: *** [/projects/rockbox/cvs/rockbox/build/sim/rockboxui] Error 1 > make: *** [all] Error 2 > > > > This seems to be because the libc on FC4 uses thread level storage for > its errno variable, which is defined on errno.h as an extern: > > extern int errno; > > Im guessing to compile on FC4 i need to use a directive to specify > that the external variable uses TLS. Googling suggests that the > __thread directive is what I need, but I am not good enough with gcc / > c to work out the precise syntax. Ive tried various combinations of > __thread and extern, but they all give the same (or similar) errors. > > Any rockbox-ers know the answer? (apart from switching distro)? > > thanks > > george >Received on Fri Oct 28 17:40:12 2005 Page was last modified "Jan 10 2012" The Rockbox Crew |