Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 308925 - sys-libs/glibc-2.10.1-r1 build error: ld-linux.so.2: cannot execute binary file
Summary: sys-libs/glibc-2.10.1-r1 build error: ld-linux.so.2: cannot execute binary file
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-11 01:43 UTC by Ricardo Fabbri
Modified: 2010-11-16 05:58 UTC (History)
1 user (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 Ricardo Fabbri 2010-03-11 01:43:51 UTC
Hi,

my system hasn't been updated in quite a while. Here are the last lines of build.log:

.././scripts/mkinstalldirs /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc
.././scripts/mkinstalldirs /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc
CPP='x86_64-pc-linux-gnu-gcc -E -x c-header'  /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2 --library-path /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/math:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/dlfcn:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nss:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nis:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/rt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/resolv:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/crypt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nptl /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcgen -Y ../scripts -c rpcsvc/bootparam_prot.x -o /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xbootparam_prot.T
CPP='x86_64-pc-linux-gnu-gcc -E -x c-header'  /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2 --library-path /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/math:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/dlfcn:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nss:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nis:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/rt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/resolv:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/crypt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nptl /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcgen -Y ../scripts -c rpcsvc/rstat.x -o /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xrstat.T
CPP='x86_64-pc-linux-gnu-gcc -E -x c-header'  /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2 --library-path /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/math:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/dlfcn:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nss:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nis:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/rt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/resolv:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/crypt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nptl /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcgen -Y ../scripts -c rpcsvc/nlm_prot.x -o /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xnlm_prot.T
/bin/sh: /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2: cannot execute binary file
mkdir /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc
make[2]: *** [/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xbootparam_prot.stmp] Error 126
make[2]: *** Waiting for unfinished jobs....
/bin/sh: /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2: cannot execute binary file
make[2]: *** [/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xrstat.stmp] Error 126
/bin/sh: /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2: cannot execute binary file
make[2]: *** [/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/xnlm_prot.stmp] Error 126
CPP='x86_64-pc-linux-gnu-gcc -E -x c-header'  /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2 --library-path /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/math:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/dlfcn:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nss:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nis:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/rt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/resolv:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/crypt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nptl /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcgen -Y ../scripts -h rpcsvc/bootparam_prot.x -o /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc/bootparam_prot.T
CPP='x86_64-pc-linux-gnu-gcc -E -x c-header'  /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2 --library-path /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/math:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/dlfcn:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nss:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nis:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/rt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/resolv:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/crypt:/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/nptl /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcgen -Y ../scripts -h rpcsvc/nlm_prot.x -o /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc/nlm_prot.T
/bin/sh: /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2: cannot execute binary file
make[2]: *** [/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc/bootparam_prot.stmp] Error 126
/bin/sh: /var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/elf/ld-linux.so.2: cannot execute binary file
make[2]: *** [/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/build-x86-x86_64-pc-linux-gnu-nptl/sunrpc/rpcsvc/nlm_prot.stmp] Error 126
make[2]: Leaving directory `/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/glibc-2.10.1/sunrpc'
make[1]: *** [sunrpc/others] Error 2
make[1]: Leaving directory `/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/glibc-2.10.1'
make: *** [all] Error 2
 * ERROR: sys-libs/glibc-2.10.1-r1 failed:
 *   make for x86 failed
 *
 * Call stack:
 *           ebuild.sh, line   54:  Called src_compile
 *         environment, line 3831:  Called eblit-run 'src_compile'
 *         environment, line 1238:  Called eblit-glibc-src_compile
 *   src_compile.eblit, line  199:  Called src_compile
 *         environment, line 3831:  Called eblit-run 'src_compile'
 *         environment, line 1238:  Called eblit-glibc-src_compile
 *   src_compile.eblit, line  207:  Called toolchain-glibc_src_compile
 *   src_compile.eblit, line  123:  Called die
 * The specific snippet of code:
 *              make PARALLELMFLAGS="${MAKEOPTS}" || die "make for ${ABI} failed"
 *
 * If you need support, post the output of 'emerge --info =sys-libs/glibc-2.10.1-r1',
 * the complete build log and the output of 'emerge -pqv =sys-libs/glibc-2.10.1-r1'.
 * The complete build log is located at '/var/tmp/portage/sys-libs/glibc-2.10.1-r1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-libs/glibc-2.10.1-r1/temp/environment'.
 * S: '/var/tmp/portage/sys-libs/glibc-2.10.1-r1/work/glibc-2.10.1'



Here is the output of emerge info on the package:

oo-r5 x86_64)
=================================================================
                        System Settings
=================================================================
System uname: Linux-2.6.28-gentoo-r5-x86_64-Intel-R-_Xeon-TM-_CPU_3.40GHz-with-gentoo-1.12.13
Timestamp of tree: Wed, 10 Mar 2010 22:30:24 +0000
ccache version 2.4 [disabled]
app-shells/bash:     4.0_p35
dev-java/java-config: 2.1.10
dev-lang/python:     2.5.4-r2, 2.6.4-r1
dev-util/ccache:     2.4-r7
dev-util/cmake:      2.6.4-r3
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
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.3
sys-devel/binutils:  2.18-r3
sys-devel/gcc:       4.3.2-r3
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
virtual/os-headers:  2.6.30-r1
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /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 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.netnitco.net ftp://mirror.datapipe.net/gentoo http://mirror.datapipe.net/gentoo"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1"
LINGUAS="en pt"
MAKEOPTS="-j5"
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"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X aac acl alsa amd64 apache2 arts avi bash-completion berkdb bitmap-fonts bzip2 cairo caps cddb cdparanoia cdr cli cracklib crypt cscope cups curl cvs cxx dbus dga djvu dri dvd dvdr dvdread dvipdfm embedded emf encode exif expat fam ffmpeg fftw fortran gcj gd gdbm gif gimp gimpprint glitz gnome gphoto2 gpm graphviz gs gtk gtkhtml hal iconv ieee1394 imagemagick imlib ipod ipv6 jpeg kde kpathsea latex lcms ldap libwww lua matroska mikmod mmx mng modules motif mp3 mpeg mplayer mudflap multilib mysql ncurses nis nls nptl nptlonly nsplugin nvidia ogg oggvorbis opengl openmp pam pcre pdf perl php plotutils png postscript ppds pppd python qt3support qt4 quicktime raw readline reflection scanner sdl session smp spell spl sql sse sse2 ssl subversion svg svnserve sysfs tcltk tcpd theora threads tiff tk truetype truetype-fonts type1-fonts unicode vcd vim-syntax vim-with-x visualization vnc vorbis wacom webkit wmf wxwindows xinerama xml xorg xprint xscreensaver xv xvmc zlib" 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="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 auth_digest authn_anon authn_dbd 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 dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en pt" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nvidia vesa fbdev"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY


Here is the output of emerge -vp on the package:
[ebuild     U ] sys-libs/glibc-2.10.1-r1 [2.8_p20080602-r1] USE="gd (multilib) nls -debug -glibc-omitfp (-hardened) -profile (-selinux) -vanilla"
Comment 1 SpanKY gentoo-dev 2010-03-17 23:15:08 UTC
see if turning off sandbox makes a difference: FEATURES=-sandbox
Comment 2 SpanKY gentoo-dev 2010-04-15 22:45:36 UTC
also make sure you arent setting weird mount perms or disabled 32bit support in the kernel
Comment 3 Jaak Ristioja 2010-05-08 13:17:14 UTC
Enabling 32-bit support in kernel worked around the problem for me, although I actually wanted to switch to no-multilib.
Comment 4 Tom Noonan 2010-11-12 18:49:07 UTC
I encountered this bug and was able to complete the glibc emerge by setting IA32_EMULATION=y and IA32_AOUT=y in the kernel.  Is there a pressing reason why glibc needs to use 32bit binaries?
Comment 5 SpanKY gentoo-dev 2010-11-15 22:12:29 UTC
you cant enable multilib support in userspace and disable 32bit support in the kernel.  this is a misconfiguration in your system, not a bug in glibc.
Comment 6 Jaak Ristioja 2010-11-16 05:58:59 UTC
(In reply to comment #5)
> you cant enable multilib support in userspace and disable 32bit support in the
> kernel.  this is a misconfiguration in your system, not a bug in glibc.

So one can't build a multilib glibc when not running a kernel with 32-bit support? If this is really inevitable, maybe the ebuild should check the config of the running kernel before attempting the build to provide users with better error messages. I think it should at least output a warning before the compile.