Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 66396 - glibc-2.3.4.20040808 fails to build on amd64
Summary: glibc-2.3.4.20040808 fails to build on amd64
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: AMD64 All
: High blocker (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-10-05 02:31 UTC by Tobias Klausmann (RETIRED)
Modified: 2004-10-10 00:35 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Klausmann (RETIRED) gentoo-dev 2004-10-05 02:31:21 UTC
During compile, this happens:

gcc   -shared -static-libgcc -Wl,-O1   -Wl,-dynamic-linker=/lib/ld-linux-x86-64.so.2  -B/var/tmp/portage/glibc-2.3.4.20040808/work/build/csu/  -Wl,--version-script=/var/tmp/portage/glibc-2.3.4.20040808/work/build/libc.map -Wl,-soname=libc.so.6 -Wl,-z,relro -nostdlib -nostartfiles -e __libc_main -Wl,-z,now -L/var/tmp/portage/glibc-2.3.4.20040808/work/build -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/math -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/elf -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/dlfcn -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/nss -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/nis -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/rt -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/resolv -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/crypt -L/var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads -Wl,-rpath-link=/var/tmp/portage/glibc-2.3.4.20040808/work/build:/var/tmp/portage/glibc-2.3.4.20040808/work/build/math:/var/tmp/portage/glibc-2.3.4.20040808/work/build/elf:/var/tmp/portage/glibc-2.3.4.20040808/work/build/dlfcn:/var/tmp/portage/glibc-2.3.4.20040808/work/build/nss:/var/tmp/portage/glibc-2.3.4.20040808/work/build/nis:/var/tmp/portage/glibc-2.3.4.20040808/work/build/rt:/var/tmp/portage/glibc-2.3.4.20040808/work/build/resolv:/var/tmp/portage/glibc-2.3.4.20040808/work/build/crypt:/var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads -o /var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads/libc.so -T /var/tmp/portage/glibc-2.3.4.20040808/work/build/shlib.lds /var/tmp/portage/glibc-2.3.4.20040808/work/build/csu/abi-note.o /var/tmp/portage/glibc-2.3.4.20040808/work/build/elf/soinit.os /var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads/libc_pic_lite.os /var/tmp/portage/glibc-2.3.4.20040808/work/build/elf/sofini.os /var/tmp/portage/glibc-2.3.4.20040808/work/build/elf/interp.os /var/tmp/portage/glibc-2.3.4.20040808/work/build/elf/ld.so -lgcc -lgcc_eh
/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: /var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads/libc_pic_lite.os: relocation R_X86_64_PC32 against `__GI___res_maybe_init' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
make[2]: *** [/var/tmp/portage/glibc-2.3.4.20040808/work/build/linuxthreads/libc.so] Error 1
make[2]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808/work/glibc-2.3.3/linuxthreads'
make[1]: *** [linuxthreads/others] Error 2
make[1]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808/work/glibc-2.3.3'
make: *** [all] Error 2

If tried both with and without "pic" in USE, same error.

Interestingly enough:# epm -q glibc
glibc-2.3.4.20040808

So this glibc used to work, but back then I used another compiler.

# emerge info
Portage 2.0.51_rc7 (default-amd64-2004.2, gcc-3.3.4, glibc-2.3.4.20040808-r0, 2.6.8-gentoo-r4 x86_64)
=================================================================
System uname: 2.6.8-gentoo-r4 x86_64 5
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2
Headers:  sys-kernel/linux26-headers-2.6.8.1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-O2"
CHOST="x86_64-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distlocks"
GENTOO_MIRRORS="ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://www.gigaload.org/gentoo.org/ ftp://ftp.join.uni-muenster.de/pub/linux/distributions/gentoo http://mirrors.sec.informatik.tu-darmstadt.de/gentoo/"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync5.de.gentoo.org/gentoo-portage/"
USE="acpi amd64 apm arts avi berkdb bitmap-fonts bzlib crypt encode foomaticdb ftp gdbm gif gmp gpm imlib jpeg kde libg++ libwww mikmod motif mpeg ncurses nls nogcj offensive oggvorbis opengl oss pam pdflib perl png python quicktime readline recode sdl shared sharedmem slang sockets spell ssl tcpd truetype unicode usb vhosts xml2 xmms xprint xv zlib"
Comment 1 SpanKY gentoo-dev 2004-10-05 05:28:25 UTC
base-system does not take care of our toolchain
Comment 2 Mark Duckworth 2004-10-07 07:20:53 UTC
What precisely does your comment mean Spanky?
Comment 3 Marco Squarcina 2004-10-08 01:28:29 UTC
Same here

darkstar lavish # emerge info
Portage 2.0.51_rc7 (default-linux/amd64/gcc34-2004.2, gcc-3.4.2, glibc-2.3.4.20040808-r0, 2.6.9-rc3 x86_64)
=================================================================
System uname: 2.6.9-rc3 x86_64 AMD Athlon(tm) 64 Processor 3200+
Gentoo Base System version 1.5.3
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2
Headers:  sys-kernel/linux26-headers-2.6.8.1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-march=athlon64 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.3/share/config:/usr/kde/3.3/env:/usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon64 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distlocks"
GENTOO_MIRRORS="ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo http://195.56.77.10/ http://194.149.10.102/ ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X acpi alsa amd64 avi berkdb bitmap-fonts cdr crypt dvd dvdr encode fam foomaticdb gdbm gif gpm gtk gtk2 imagemagick imlib ipv6 java jpeg libg++ libwww mad mikmod motif mozilla mpeg ncurses nls oggvorbis opengl pam pdflib perl png python quicktime readline sdl slang spell ssl svg tcltk tcpd tiff truetype xml2 xmms xprint xv zlib"
Comment 4 merwan kashouty 2004-10-08 09:51:10 UTC
i am getting this error too.


var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc_pic_lite.os: relocation R_X86_64_PC32 against `__GI___res_maybe_init' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.2/../../../../x86_64-pc-linux-gnu/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
make[2]: *** [/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc.so] Error 1
make[2]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808-r1/work/glibc-2.3.3/linuxthreads'
make[1]: *** [linuxthreads/others] Error 2
make[1]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808-r1/work/glibc-2.3.3'
make: *** [all] Error 2

!!! ERROR: sys-libs/glibc-2.3.4.20040808-r1 failed.
!!! Function src_compile, Line 575, Exitcode 2
!!! (no error message)
!!! If you need support, post the topmost build error, NOT this status message.


Portage 2.0.51_rc7 (default-linux/amd64/gcc34-2004.2, gcc-3.4.2, glibc-2.3.4.20040808-r0, 2.6.9-rc2-love4 x86_64)
=================================================================
System uname: 2.6.9-rc2-love4 x86_64 AMD Athlon(tm) 64 FX-53 Processor
Gentoo Base System version 1.5.3
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2
Headers:  sys-kernel/linux26-headers-2.6.8.1-r1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=k8 -pipe -ftracers -fweb"
CHOST="x86_64-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.2/share/config /usr/kde/3.3/share/config:/usr/kde/3.3/env:/usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=k8 -pipe -ftracers -fweb"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distlocks"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ http://adelie.polymtl.ca/"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X alsa amd64 apm arts avi berkdb bitmap-fonts cdr crypt dvd dvdr encode esd f77 fam flac foomaticdb freetds gdbm gif gnome gpm gtk gtk2 imagemagick imlib jpeg kde libg++ libwww mad mikmod motif mpeg mssql multilib mysql ncurses nls ntpl oggvorbis opengl oss pam pdflib perl png python qt quicktime readline sdl slang spell ssl tcltk tcpd tiff truetype xml2 xmms xprint xv zlib"
Comment 5 Michael Evans 2004-10-08 19:22:27 UTC
Same for me.

gcc   -shared -static-libgcc -Wl,-O1   -Wl,-dynamic-linker=/lib/ld-linux-x86-64.so.2  -B/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/csu/  -Wl,--version-script=/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/libc.map -Wl,-soname=libc.so.6 -Wl,-z,relro -nostdlib -nostartfiles -e __libc_main -Wl,-z,now -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/math -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/dlfcn -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/nss -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/nis -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/rt -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/resolv -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/crypt -L/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads -Wl,-rpath-link=/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/math:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/dlfcn:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/nss:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/nis:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/rt:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/resolv:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/crypt:/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads -o /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc.so -T /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/shlib.lds /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/csu/abi-note.o /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf/soinit.os /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc_pic_lite.os /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf/sofini.os /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf/interp.os /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/elf/ld.so -lgcc -lgcc_eh
/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: /var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc_pic_lite.os: relocation R_X86_64_PC32 against `__GI___res_maybe_init' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.4/../../../../x86_64-pc-linux-gnu/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
make[2]: *** [/var/tmp/portage/glibc-2.3.4.20040808-r1/work/build/linuxthreads/libc.so] Error 1
make[2]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808-r1/work/glibc-2.3.3/linuxthreads'
make[1]: *** [linuxthreads/others] Error 2
make[1]: Leaving directory `/var/tmp/portage/glibc-2.3.4.20040808-r1/work/glibc-2.3.3'
make: *** [all] Error 2

!!! ERROR: sys-libs/glibc-2.3.4.20040808-r1 failed.
!!! Function src_compile, Line 575, Exitcode 2
!!! (no error message)
!!! If you need support, post the topmost build error, NOT this status message.

tux ~ # emerge info
Portage 2.0.51_rc7 (default-amd64-2004.2, gcc-3.3.4, glibc-2.3.4.20040808-r0, 2.6.8-gentoo-r7 x86_64)
=================================================================
System uname: 2.6.8-gentoo-r7 x86_64 Mobile AMD Athlon(tm) 64 Processor 3400+
Gentoo Base System version 1.5.3
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2
Headers:  sys-kernel/linux26-headers-2.6.8.1-r1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=athlon64 -pipe"
CHOST="x86_64-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=athlon64 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distlocks"
GENTOO_MIRRORS="http://gentoo.osuosl.org http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X acpi amd64 apache2 apm arts asla audiofile avi berkdb bitmap-fonts bzlib calendar caps cdr cjk crypt cups curl curlwrappers dga dio directfb dvd dvdr encode ethereal exif f77 fftw flac flash foomaticdb ftp gb gdbm gif ginac gmp gnome gpm gps gtk gtk2 hardenedphp iconv imagemagick imap imlib inifile jabber java jikes jpeg junit kde lesstif libedit libg++ libwww mad maildir mcal mhash mikmod mime ming mmap mng motif mpeg mpi msn multilib ncurses nls nogcj offensive oggvorbis openal opengl oscar oss pam pcmcia pcre pda pdflib perl php pic pie plotutils png pnp portaudio posix postgres python qt quicktime readline recode samba scanner sdl session shared sharedmem simplexml slang sndfile soap sockets socks5 speex spell spl ssl szip tcltk tcpd theora tiff tokenizer truetype trusted unicode usb wddx wmf xine xml xml2 xmlrpc xmms xosd xpm xprint xv xvid zlib"

Comment 6 Michael Evans 2004-10-08 19:58:20 UTC
It fails the Exact same way while running /usr/portage/scripts/bootstrap-2.6.sh.

Possible Patch through google.

http://sources.redhat.com/ml/libc-alpha/2004-08/msg00076.html
Comment 7 Andreas Pokorny 2004-10-09 04:50:29 UTC
The patch works here.
Comment 8 merwan kashouty 2004-10-09 07:30:23 UTC
patch works here too... thanks for the find. i just added the epatch line and away it went. 

do_arch_amd64_patches() {
        cd ${S};
        # CONF_LIBDIR support
        epatch ${FILESDIR}/2.3.4/glibc-gentoo-libdir.patch
        epatch ${FILESDIR}/libc-res_init-2.patch
        sed -i -e "s:@GENTOO_LIBDIR@:$(get_libdir):g" ${S}/sysdeps/unix/sysv/linux/configure
}
Comment 9 Marco Squarcina 2004-10-09 09:39:10 UTC
Patched.... it works
I hope it will be fixed in portage too (soon :P )...
Comment 10 Brian O'Reilly 2004-10-09 18:42:51 UTC
Ditto. inserted this patch into the ebuild, and the package
compiles and installs as expected. So far, no catastrophe. =)

-B
Comment 11 Travis Tilley (RETIRED) gentoo-dev 2004-10-10 00:35:58 UTC
looks like the new binutils uncovered this bug in glibc. fixed in cvs, give it 15-30 minutes to reach rsync :)