patches/glibc/2.3.3/bad/glibc-2.3.3-alpha-pwrite64.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Sat Feb 24 11:00:05 2007 +0000 (2007-02-24)
changeset 1 eeea35fbf182
permissions -rw-r--r--
Add the full crosstool-NG sources to the new repository of its own.
You might just say: 'Yeah! crosstool-NG's got its own repo!".
Unfortunately, that's because the previous repo got damaged beyond repair and I had no backup.
That means I'm putting backups in place in the afternoon.
That also means we've lost history... :-(
     1 Attempted fix for this error:
     2 
     3 
     4 crosstool-0.30/build/alpha-unknown-linux-gnu/gcc-3.3.4-glibc-2.3.3/build-glibc/libc_pic.os(.text+0xc8bd0): In function `__posix_fallocate64_l64':
     5 : undefined reference to `__GI___pwrite64'
     6 collect2: ld returned 1 exit status
     7 make[1]: Leaving directory `/home/dank/queue/jobdir.fast2/crosstool-0.30/build/alpha-unknown-linux-gnu/gcc-3.3.4-glibc-2.3.3/glibc-2.3.3'
     8 make[1]: *** [/home/dank/queue/jobdir.fast2/crosstool-0.30/build/alpha-unknown-linux-gnu/gcc-3.3.4-glibc-2.3.3/build-glibc/libc.so] Error 1
     9 make: *** [all] Error 2
    10 
    11 extracted from GLIBC CVS by Dan Kegel
    12 wget 'http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/sysdeps/unix/sysv/linux/alpha/sysdep.h.diff?r1=1.14&r2=1.15&cvsroot=glibc'
    13 (to match context of...)
    14 wget 'http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/sysdeps/unix/sysv/linux/alpha/sysdep.h.diff?r1=1.16&r2=1.17&cvsroot=glibc'
    15 and rediffed.
    16 
    17 cf. 
    18 http://sources.redhat.com/ml/libc-alpha/2003-10/msg00038.html
    19 
    20 Originally thought we needed this hunk, too:
    21 http://sources.redhat.com/ml/libc-alpha/2003-10/msg00037.html
    22 but it seems the sysdep.h change is sufficient, and works better 
    23 when compiling against linux-2.4.
    24 
    25 And then rediffed again against glibc-2.3.3
    26 
    27 --- glibc-2.3.3.orig/sysdeps/unix/sysv/linux/alpha/sysdep.h	Fri Jun 20 09:24:36 2003
    28 +++ glibc-2.3.3/sysdeps/unix/sysv/linux/alpha/sysdep.h	Wed Mar 23 23:59:58 2005
    29 @@ -1,4 +1,4 @@
    30 -/* Copyright (C) 1992, 1993, 1995, 1996, 1997, 2002, 2003
    31 +/* Copyright (C) 1992, 1993, 1995, 1996, 1997, 2002, 2003, 2004
    32     Free Software Foundation, Inc.
    33     This file is part of the GNU C Library.
    34     Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>, August 1995.
    35 @@ -63,6 +63,16 @@
    36  /* Help old kernel headers where particular syscalls are not available.  */
    37  #ifndef __NR_semtimedop
    38  # define __NR_semtimedop	423
    39 +#endif
    40 +
    41 +/* This is a kludge to make syscalls.list find these under the names
    42 +   pread and pwrite, since some kernel headers define those names
    43 +   and some define the *64 names for the same system calls.  */
    44 +#if !defined __NR_pread && defined __NR_pread64
    45 +# define __NR_pread __NR_pread64
    46 +#endif
    47 +#if !defined __NR_pwrite && defined __NR_pwrite64
    48 +# define __NR_pwrite __NR_pwrite64
    49  #endif
    50  
    51  /*