Summary: | sys-libs/glibc is unable to detect version of gold linker | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Chris Smith <chris> |
Component: | [OLD] Core system | Assignee: | Gentoo Toolchain Maintainers <toolchain> |
Status: | RESOLVED UPSTREAM | ||
Severity: | normal | CC: | astralstorm, bug, dilfridge, ecyoung, esigra, gentoo-bugs, gentoo, genzilla, hasufell, mmokrejs, oas, plaes, polidevk.polidevk |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | http://sourceware.org/ml/binutils/2009-05/msg00192.html | ||
See Also: | http://sourceware.org/bugzilla/show_bug.cgi?id=10937 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 269315 | ||
Attachments: |
sys-libs:glibc-2.9_p20081201-r2:20090510-174545.log
config.log configure.in patch for ld configure patch for ld glibc modded ebuild configure.in patch for glibc-2.10 configure patch for glibc-2.10 |
Description
Chris Smith
2009-05-10 15:36:52 UTC
Please provide emerge --info and attach the config.log. Created attachment 190857 [details] sys-libs:glibc-2.9_p20081201-r2:20090510-174545.log emerge --info Portage 2.1.6.13 (default/linux/amd64/2008.0, gcc-4.4.0, glibc-2.9_p20081201-r2, 2.6.29-gentoo-r3 x86_64) ================================================================= System uname: Linux-2.6.29-gentoo-r3-x86_64-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-gentoo-2.0.0 Timestamp of tree: Sun, 10 May 2009 15:45:01 +0000 app-shells/bash: 4.0_p17-r1 dev-java/java-config: 2.1.7 dev-lang/python: 2.6.2 dev-util/cmake: 2.6.4 sys-apps/baselayout: 2.0.0 sys-apps/openrc: 0.4.3-r2 sys-apps/sandbox: 1.9 sys-devel/autoconf: 2.13, 2.63-r1 sys-devel/automake: 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.19.51.0.4 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6a virtual/os-headers: 2.6.29 ACCEPT_KEYWORDS="amd64 ~amd64" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=native -O2 -fomit-frame-pointer -pipe -floop-interchange -floop-strip-mine -floop-block" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/eselect/postgresql /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /etc/udev/rules.d" CXXFLAGS="-march=native -O2 -fomit-frame-pointer -pipe -floop-interchange -floop-strip-mine -floop-block" DISTDIR="/usr/portage/distfiles" EMERGE_DEFAULT_OPTS="--with-bdeps y" FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch" GENTOO_MIRRORS="http://distfiles.gentoo.org http://gentoo.mirrors.tds.net/gentoo http://gentoo.cites.uiuc.edu/pub/gentoo/ ftp://gentoo.chem.wisc.edu/gentoo/ http://gentoo.chem.wisc.edu/gentoo/" LANG="en_US.UTF-8" LDFLAGS="-Wl,--as-needed" LINGUAS="en_US en" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage/layman/gnome /usr/local/portage/layman/graaff /usr/local/portage" SYNC="rsync://davinci.realcomputerguy.soho/gentoo-portage" USE="X a52 aac aalib acl acpi addressbook alsa amd64 amr apache2 audiofile avahi avi bash-completion berkdb bzip2 cairo caps cdaudio cdparanoia cdr chm cli cracklib crypt cups curl dbus designer-plugin djvu dri dts dv dvb dvd dvdr dvdread ebook encode exif fam ffmpeg flac fortran gdbm gif glitz gmp gnome gphoto2 gpm gps graphite gstreamer gtk gtk2 hal htmlhandbook iconv ieee1394 imagemagick imap imlib ipv6 isdnlog jack java jpeg jpeg2k kpathsea lame lcd lcms ldap libnotify mad marble midi mmap mmx mozcalendar mozilla mp3 mudflap multilib musicbrainz ncurses nepomuk nls nodrm nptl nptlonly nsplugin nvidia ofx ogg oggvorbis openexr opengl openmp pam pcre pdf perl png pppd pulseaudio python qt3 qt4 quicktime readline reflection samba sasl scanner sdl semantic-desktop session slp smp sndfile spell spl sse sse2 ssl subversion svg sysfs tcltk theora threads tiff tk transparency truetype unicode usb utf8 v4l v4l2 vcd vim-syntax vorbis wav wavpack wmf x264 xattr xcomposite xine xml xorg xscreensaver xv xvid xvmc zlib" ALSA_CARDS="hda-intel hdsp" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CAMERAS="ptp2" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_US en" USERLAND="GNU" VIDEO_CARDS="nvidia nv vesa fbdev vmware v4l" Unset: CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS (In reply to comment #1) > Please provide emerge --info and attach the config.log. > config.log is not to be found in the work dir "find . |grep config.log" does not return anything inside the work dir? Created attachment 190859 [details]
config.log
ah yes, it is there...I was looking in the work/glibc-2.9-20081201 directory
Me too on amd64! Sending "gold" back in the closet for now ;) P.S. sys-boot/grb-1.96 also fails configure with the "gold" binuils : checking whether x86_64-pc-linux-gnu-objcopy works for absolute addresses... configure: error: x86_64-pc-linux-gnu-gcc cannot link at address 7C00 I've been debugging/patching for the last 2 hours... finally I got the sed regex to substitute (which was driving me insane, being a sed newbie): [...] checking for /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/as... /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/as checking version of /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/as... 2.19.51.0.4.20090418, ok checking for /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/ld... /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/ld checking version of /usr/lib/gcc/x86_64-pc-linux-gnu/4.3.3/../../../../x86_64-pc-linux-gnu/bin/ld... 2.19.51.0.4.20090418, ok checking for pwd... /bin/pwd checking for i686-pc-linux-gnu-gcc... (cached) x86_64-pc-linux-gnu-gcc checking version of x86_64-pc-linux-gnu-gcc... 4.3.3, ok [...] Sad is, it throws another error: [...after log above] checking for .preinit_array/.init_array/.fini_array support... yes checking for libunwind-support in compiler... no checking for -z nodelete option... yes checking for -z nodlopen option... yes checking for -z initfirst option... yes checking for -z relro option... no configure: error: linker with -z relro support required even if `ld --help` shows: -z relro Where possible mark variables read-only after relocation I'm on binutils-2.19.51.0.4.20090418. I'm attaching the two patches I made plus the modded ebuild (which does nothing except patching in eblit-src_unpack-post). I'm stuck with that error above.. and I don't know where to put my hands this time, since it should work as usual. Note that this ebuild patches if the gold USE flag is set in binutils, but if we have binutils-2.18.x + gold USE flag this patch gets applied anyway, which is not correct since 2.18.x exhibit old version tag even with gold USE flag: fabio@gentoo-node1 ~ $ ld -v GNU ld (GNU Binutils) 2.18 fabio@gentoo-node1 ~ $ emerge -s binutils Searching... * sys-devel/binutils Latest version available: 2.18-r3 Latest version installed: 2.18-r3 Since I'm not used to ebuild hacking (not at this level at least) and I'm not aware of any function to verify an installed version of a program, I'm leaving this to developers.. basically it should apply only on >=binutils-2.19.x Created attachment 191358 [details, diff]
configure.in patch for ld
Created attachment 191360 [details, diff]
configure patch for ld
Created attachment 191362 [details]
glibc modded ebuild
Lacks binutils version checking
Also glibc-2.10.1 fails with gold :( Created attachment 208584 [details, diff]
configure.in patch for glibc-2.10
The previous patch was not perfect. A "\" was missing before "/" and the version of glod linker was not the same as the binutils so the configure script detected as "too old".
Created attachment 208585 [details, diff]
configure patch for glibc-2.10
Will portage get a fixed sys-libs/glibc-2.9_p20081201-r2 I can try to build? (Or are we supposed to test the attached ebuild directly first?) (I assume that this is the case where the -r2 will just be fixed instead of adding a -r3 that everyone has to build, because if it is already built there is no reason to build it again with this kind of fix.) there are no plans to add configure fixes to glibc as it is understood that the build will fail in other places due to gold use /etc/portage/patches/ if you want to test things yourself So what is the plan for gold? Is it to have both gold and classic ld installed, and the packages that depend on classic ld will use it, while the rest use gold? Or is it to wait until gold works with everything and then switch over to it. I tried gold some months ago and it gave a noticeable improvement. Now I try to do some development on a medium-sized C++ project, but the linking takes several minutes. It is really painful and I could really use some serious improvement. I would prefer to have both kinds of ld installed, get the speed improvement for my development and most packages in portage, while keeping classic ld for glibc and maybe a few more trick packages. there are no plans. use it as you see fit. i have a similar problem: glibc-2.9_20081201-r2 configure fails with "configure: error: *** These critical programs are missing or too old: as ld" my binutils is classic (not gold) ------------------------------------------------------------------------- Portage 2.1.6.13 (default/linux/amd64/10.0/no-multilib, gcc-4.4.2, glibc-2.9_p20081201-r2, 2.6.31.1 x86_64) ================================================================= System uname: Linux-2.6.31.1-x86_64-Intel-R-_Core-TM-2_Duo_CPU_T9400_@_2.53GHz-with-gentoo-2.0.1 Timestamp of tree: Tue, 01 Dec 2009 00:45:01 +0000 app-shells/bash: 4.0_p28 dev-java/java-config: 2.1.9-r1 dev-lang/python: 2.6.2-r1 dev-util/cmake: 2.6.4-r3 sys-apps/baselayout: 2.0.1 sys-apps/openrc: 0.5.2-r2 sys-apps/sandbox: 1.6-r2 sys-devel/autoconf: 2.13, 2.63-r1 sys-devel/automake: 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.20 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6b virtual/os-headers: 2.6.27-r2 ACCEPT_KEYWORDS="amd64" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe -march=native -mfpmath=sse -fomit-frame-pointer -mmmx -msse -msse2 -msse3 -mssse3 -msse4.1" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/X11/xkb" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/eselect/postgresql /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d" CXXFLAGS="-O2 -pipe -march=native -mfpmath=sse -fomit-frame-pointer -mmmx -msse -msse2 -msse3 -mssse3 -msse4.1" DISTDIR="/srv/distfiles" FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch" GENTOO_MIRRORS="ftp://gentoo.kiev.ua/ http://mirrors.sec.informatik.tu-darmstadt.de/gentoo/ http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/" LANG="en_US.UTF8" LDFLAGS="-Wl,-O1" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage" USE="X amd64 mmx mmxext nls nptl opengl pam sse sse2 sse3 sse4_1 ssse3 truetype unicode" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="*" APACHE2_MODULES="authz_host dir mime rewrite env" APACHE2_MPMS="prefork" ELIBC="glibc" INPUT_DEVICES="keyboard mouse synaptics evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="intel" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS nothing for us to work on here, and `ld` wont be defaulting to gold any time soon *** Bug 406879 has been marked as a duplicate of this bug. *** *** Bug 412023 has been marked as a duplicate of this bug. *** *** Bug 429282 has been marked as a duplicate of this bug. *** (In reply to comment #20) > nothing for us to work on here, and `ld` wont be defaulting to gold any time > soon Awesome. Is there an upstream tracker bug somewhere? The linked e-mail is not particularly informative, and tbh sounds only like "we dont care to fix". *** Bug 430896 has been marked as a duplicate of this bug. *** Commit message: Force usage of bfd linker if active linker is gold http://sources.gentoo.org/sys-libs/glibc/files/eblits/src_compile.eblit?r1=1.29&r2=1.30 *** Bug 459888 has been marked as a duplicate of this bug. *** From Binutils Bugzilla(in case anyone is redirected here, like me): http://sourceware.org/bugzilla/show_bug.cgi?id=10937 That part is never going to work with gold. It is asking the linker for the default linker script, editing it, and passing it back to the linker. gold does not have a default linker script to edit. Building glibc with gold will require using a different approach of some sort. *** Bug 544194 has been marked as a duplicate of this bug. *** |