On Mon, Jun 16, 2008 at 8:13 PM, John Wright <[EMAIL PROTECTED]> wrote: > Package: glibc > Version: 2.7-12 > Severity: normal > > I'm trying to test rebuilding the archive against an nptl-enabled glibc > on hppa, but I'm having trouble building glibc. I have attached the > patch against 2.7-12 that I used to enable nptl, as well as the failed > build log.
This is already fixed upstream. > In file included from ../nptl/descr.h:30, > from ../ports/sysdeps/hppa/nptl/tls.h:63, > from ../include/tls.h:6, > from <stdin>:2: > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h: In function > '__lll_unlock': > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:297: warning: > implicit declaration of function 'THREAD_GETMEM' > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:297: error: > 'THREAD_SELF' undeclared (first use in this function) > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:297: error: (Each > undeclared identifier is reported only once > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:297: error: for > each function it appears in.) > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:297: error: > 'header' undeclared (first use in this function) > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h: In function > '__lll_robust_unlock': > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:306: error: > 'THREAD_SELF' undeclared (first use in this function) > ../ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h:306: error: > 'header' undeclared (first use in this function) > make[3]: *** [/tmp/buildd/glibc-2.7/build-tree/hppa-libc/tcb-offsets.h] Error > 1 > make[3]: Leaving directory `/tmp/buildd/glibc-2.7/build-tree/glibc-2.7/csu' > make[2]: *** [csu/subdir_lib] Error 2 > make[2]: Leaving directory `/tmp/buildd/glibc-2.7/build-tree/glibc-2.7' > make[1]: *** [all] Error 2 > make[1]: Leaving directory `/tmp/buildd/glibc-2.7/build-tree/hppa-libc' > make: *** [/tmp/buildd/glibc-2.7/stamp-dir/build_libc] Error 2 > dpkg-buildpackage: failure: debian/rules build gave error exit status 2 > pbuilder: Failed autobuilding of package This was fixed upstream by Jeff Bailey with this patch: 2007-12-05 Jeff Bailey <[EMAIL PROTECTED]> * sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h (__lll_unlock): Use define instead of inline function. (__lll_robust_unlock): Likewise. Cheers, Carlos.
=================================================================== RCS file: /cvs/glibc/ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h 2007/10/19 01:47:47 1.5 +++ ports/sysdeps/unix/sysv/linux/hppa/nptl/lowlevellock.h 2007/12/09 02:20:34 1.6 @@ -289,22 +289,20 @@ #define lll_robust_timedlock(futex, abstime, id, private) \ __lll_robust_timedlock (&(futex), abstime, id, private) -static inline void __attribute__ ((always_inline)) -__lll_unlock (lll_lock_t *futex, int private) -{ - int val = atomic_exchange_rel (futex, 0); - if (__builtin_expect (val > 1, 0)) - lll_futex_wake (futex, 1, private); -} +#define __lll_unlock(futex, private) \ + (void) \ + ({ int val = atomic_exchange_rel (futex, 0); \ + if (__builtin_expect (val > 1, 0)) \ + lll_futex_wake (futex, 1, private); \ + }) #define lll_unlock(futex, private) __lll_unlock(&(futex), private) -static inline void __attribute__ ((always_inline)) -__lll_robust_unlock (int *futex, int private) -{ - int val = atomic_exchange_rel (futex, 0); - if (__builtin_expect (val & FUTEX_WAITERS, 0)) - lll_futex_wake (futex, 1, private); -} +#define __lll_robust_unlock(futex,private) \ + (void) \ + ({ int val = atomic_exchange_rel (futex, 0); \ + if (__builtin_expect (val & FUTEX_WAITERS, 0)) \ + lll_futex_wake (futex, 1, private); \ + }) #define lll_robust_unlock(futex, private) \ __lll_robust_unlock(&(futex), private)