if gcc -DHAVE_CONFIG_H -I. -I. -I. -Ilinux/i386 -I./linux/i386 -Ilinux -I./linux -Wall -D_GNU_SOURCE -mcpu=athlon-xp -march=athlon-xp -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -MT ioctl.o -MD -MP -MF ".deps/ioctl.Tpo" \ -c -o ioctl.o `test -f 'ioctl.c' || echo './'`ioctl.c; \ then mv ".deps/ioctl.Tpo" ".deps/ioctl.Po"; \ else rm -f ".deps/ioctl.Tpo"; exit 1; \ fi if gcc -DHAVE_CONFIG_H -I. -I. -I. -Ilinux/i386 -I./linux/i386 -Ilinux -I./linux -Wall -D_GNU_SOURCE -mcpu=athlon-xp -march=athlon-xp -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -MT mem.o -MD -MP -MF ".deps/mem.Tpo" \ -c -o mem.o `test -f 'mem.c' || echo './'`mem.c; \ then mv ".deps/mem.Tpo" ".deps/mem.Po"; \ else rm -f ".deps/mem.Tpo"; exit 1; \ fi io.c: In function `sys_sendfile': io.c:291: warning: long unsigned int format, different type arg (arg 2) io.c: At top level: io.c:321: error: redefinition of `sys_pread' io.c:249: error: `sys_pread' previously defined here io.c:339: error: redefinition of `sys_pwrite' io.c:267: error: `sys_pwrite' previously defined here make[1]: *** [io.o] Error 1 make[1]: *** Waiting for unfinished jobs.... make[1]: Leaving directory `/var/tmp/portage/strace-4.5/work/strace-4.5' make: *** [all] Error 2 !!! ERROR: dev-util/strace-4.5 failed. !!! Function src_compile, Line 27, Exitcode 2 !!! make failed Reproducible: Always Steps to Reproduce: didi root # emerge info Portage 2.0.49-r7 (default-x86-1.4, gcc-3.3.1, glibc-2.3.2-r1, 2.4.22) ================================================================= System uname: 2.4.22 i686 AMD Athlon(tm) XP 1800+ distcc 2.11 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] ccache version 2.2 [enabled] ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CFLAGS="-mcpu=athlon-xp -march=athlon-xp -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/kde/3/share/config /lib/modules /var/bind /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/config" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-mcpu=athlon-xp -march=athlon-xp -O2 -pipe -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE" DISTDIR="/usr/portage/distfiles" FEATURES="sandbox ccache autoaddcvs fixpackages" GENTOO_MIRRORS="ftp://gentoo.linux.no/pub/gentoo/ http://gentoo.linux.no/ ftp://ftp.tu-clausthal.de/pub/linux/gentoo/ http://ftp.easynet.nl/mirror/gentoo/ ftp://ftp.easynet.nl/mirror/gentoo/" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.de.gentoo.org/gentoo-portage/" USE="x86 oss apm avi crypt cups encode foomaticdb gif jpeg libg++ mad mikmod mmx mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gtkhtml alsa gdbm berkdb slang readline arts tetex aalib bonobo svga tcltk guile ruby mysql X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gnome gtk qt kde opengl mozilla gphoto2 cdr -snmp apache2 gd gpg ncures ogg vorbis -java -motif dvdr"
remove -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE from your CFLAGS i patched this once but i lost the patch ;( basically it's because theres a define at the top of the file that defines sys_pread64 as sys_pread and then later on in the source sys_pread64 is actually defined as a 64 bit read operation and *boom* gcc dont like it :)
same problem with 4.5.1, after remove -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE from your CFLAGS it works for me. But why isn't there an other solution?
oh well i added filter-flags for this to 4.5.1 cause i was tired of doing it myself in my make.conf
i've created a bug upstream http://sourceforge.net/tracker/index.php?func=detail&aid=845946&group_id=2861&atid=102861
I'm going to close this as UPSTREAM as we have a work around (filter-flags) 4.5.1 can probably be marked stable at this point.