On Fri, Feb 3, 2012 at 10:55 AM, Khem Raj <[email protected]> wrote: > This commit below broke ppc and mips for me > since they assign to err specifically in > INTERNAL_SYSCALL_NCS definitions so now
here is something that fixes it http://git.openembedded.org/openembedded-core-contrib/tree/meta/recipes-core/uclibc/uclibc-0.9.33/0001-Declare-__err-and-pass-it-to-INTERNAL_SYSCALL_NCS-so.patch?h=kraj/misc > > commit 549fa53225910f5341092d6647a1e3dd705b605f > Author: Bernhard Reutner-Fischer <[email protected]> > Date: Thu Jan 26 15:15:23 2012 +0100 > > *: silence some warnings > > warning: ISO C90 forbids mixed declarations and code > [-Wdeclaration-after-statement] > > Signed-off-by: Bernhard Reutner-Fischer <[email protected]> > > > this is the hunk I am talking about __err declaration has been > commented out. Do you know Bernhard why ? > now any functions using _syscall_noerr0 and _syscall_noerr1 wont compile > anymore > if this was just meant as a cleanup then please reinsert it since we > really need it. > > diff --git a/libc/sysdeps/linux/common/bits/syscalls-common.h > b/libc/sysdeps/linux/common/bits/syscalls-common.h > index 1b84d9e..faebd1b 100644 > --- a/libc/sysdeps/linux/common/bits/syscalls-common.h > +++ b/libc/sysdeps/linux/common/bits/syscalls-common.h > @@ -40,21 +40,27 @@ > /* Just like INLINE_SYSCALL(), but take a non-constant syscall (NCS) > argument */ > #ifndef INLINE_SYSCALL_NCS > # define INLINE_SYSCALL_NCS(name, nr, args...) \ > -({ \ > +(__extension__ \ > + ({ \ > INTERNAL_SYSCALL_DECL(__err); \ > - long __res = INTERNAL_SYSCALL_NCS(name, __err, nr, args); \ > - if (unlikely(INTERNAL_SYSCALL_ERROR_P(__res, __err))) { \ > + (__extension__ \ > + ({ \ > + long __res = INTERNAL_SYSCALL_NCS(name, __err, nr, args); \ > + if (unlikely(INTERNAL_SYSCALL_ERROR_P(__res, __err))) { \ > __set_errno(INTERNAL_SYSCALL_ERRNO(__res, __err)); \ > __res = -1L; \ > - } \ > - __res; \ > -}) > + } \ > + __res; \ > + }) \ > + ); \ > + }) \ > +) > #endif > #ifndef INLINE_SYSCALL_NOERR_NCS > # define INLINE_SYSCALL_NOERR_NCS(name, nr, args...) \ > ({ \ > - INTERNAL_SYSCALL_DECL(__err); \ > - long __res = INTERNAL_SYSCALL_NCS(name, __err, nr, args); \ > + /*INTERNAL_SYSCALL_DECL(__err);*/ > \ > + long __res = INTERNAL_SYSCALL_NCS(name, /*__err*/, nr, args); \ > __res; \ > }) > #endif _______________________________________________ uClibc mailing list [email protected] http://lists.busybox.net/mailman/listinfo/uclibc
