Hi, I'm currently looking into why the glibc 2.3.2-5 fails to build on hppa. I know almost nothing about hppa at the moment but patch as so far attached. I'm currently struggling with __NR_ipc undefined. I can't find this syscall in the asm/unistd.h of 2.4.19. Isn't this implemented on parisc? Regards, -- Guido
--- sysdeps/unix/sysv/linux/hppa/sysdep.h.orig Thu Sep 4 09:05:05 2003 +++ sysdeps/unix/sysv/linux/hppa/sysdep.h Thu Sep 4 09:38:33 2003 @@ -128,6 +128,7 @@ #define PSEUDO_END_NOERRNO(name) \ END (name) +#undef JUMPTARGET #define JUMPTARGET(name) name #define SYSCALL_PIC_SETUP /* Nothing. */ @@ -198,8 +199,9 @@ #else -#undef INLINE_SYSCALL -#define INLINE_SYSCALL(name, nr, args...) ({ \ + +#undef INTERNAL_SYSCALL +#define INTERNAL_SYSCALL(name, err, nr, args...)({ \ long __sys_res; \ { \ register unsigned long __res asm("r28"); \ @@ -212,12 +214,30 @@ ); \ __sys_res = __res; \ } \ - if ((unsigned long)__sys_res >= (unsigned long)-4095) { \ - __set_errno(-__sys_res); \ - __sys_res = -1; \ - } \ __sys_res; \ }) + +#undef INTERNAL_SYSCALL_DECL +#define INTERNAL_SYSCALL_DECL(err) do { } while (0) + +#undef INTERNAL_SYSCALL_ERROR_P +#define INTERNAL_SYSCALL_ERROR_P(val, err) ((unsigned long)val >= (unsigned long)-4095) + +#undef INTERNAL_SYSCALL_ERRNO +#define INTERNAL_SYSCALL_ERRNO(val, err) (-(val)) + +/* Define a macro which expands into the inline wrapper code for a system + call. */ +#undef INLINE_SYSCALL +#define INLINE_SYSCALL(name, nr, args...) \ + ({ \ + long result_var = INTERNAL_SYSCALL (name, , nr, args); \ + if ( __builtin_expect( INTERNAL_SYSCALL_ERROR_P(result_var, ), 0)) \ + { \ + __set_errno (INTERNAL_SYSCALL_ERRNO (result_var, )); \ + result_var = -1; \ + } \ + result_var; }) #define LOAD_ARGS_0() #define LOAD_ARGS_1(r26) \
Attachment:
pgpbahFh74oCM.pgp
Description: PGP signature