Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 90846 - emerge sandbox-1.2.2 fails with configure error "cannot find /emul/linux/x86/lib/libc.so.6"
Summary: emerge sandbox-1.2.2 fails with configure error "cannot find /emul/linux/x86/...
Status: RESOLVED CANTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Sandbox (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: AMD64 Project
URL:
Whiteboard:
Keywords:
: 90852 94015 94619 97962 98232 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-04-29 05:06 UTC by mikepolniak
Modified: 2005-07-12 11:36 UTC (History)
9 users (show)

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


Attachments
config log for sandbox-1.2.3-x86 (sandbox-1.2.3-x86_config.log.txt,7.57 KB, text/plain)
2005-04-29 09:19 UTC, mikepolniak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description mikepolniak 2005-04-29 05:06:14 UTC
emerge sandbox
...
checking for x86_64-pc-linux-gnu-gcc... x86_64-pc-linux-gnu-gcc checking
for C compiler default output file name... configure: error: C compiler
cannot create executables

...and config.log shows it cannot find libc.so.6

/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3/../../../../x86_64-pc-linux-gnu/bin/ld:
c annot find /emul/linux/x86/lib/libc.so.6 collect2: ld returned 1 exit


Reproducible: Always
Steps to Reproduce:
1.emerge sandbox
2.
3.

Actual Results:  
checking for x86_64-pc-linux-gnu-gcc... x86_64-pc-linux-gnu-gcc checking
for C compiler default output file name... configure: error: C compiler
cannot create executables

...and config.log shows it cannot find libc.so.6

/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3/../../../../x86_64-pc-linux-gnu/bin/ld:
c annot find /emul/linux/x86/lib/libc.so.6 collect2: ld returned 1 exit



emerge info                                                   /home/mike
Portage 2.0.51.19 (default-linux/amd64/2005.0, gcc-3.4.3,
glibc-2.3.4.20050125-r1, 2.6.11-ck4 x86_64)
=================================================================
System uname: 2.6.11-ck4 x86_64 AMD Athlon(tm) 64 Processor 2800+
Gentoo Base System version 1.6.11
Python:              dev-lang/python-2.3.5 [2.3.5 (#1, Feb 19 2005, 08:42:36)]
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
dev-lang/python:     2.3.5
sys-apps/sandbox:    [Not Present]
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.9.5, 1.8.5-r3, 1.6.3, 1.5, 1.7.9-r1, 1.4_p6
sys-devel/binutils:  2.15.92.0.2-r8
sys-devel/libtool:   1.5.14
virtual/os-headers:  2.6.11
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=athlon64 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /var/bind /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=athlon64 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox strict"
GENTOO_MIRRORS="ftp://ftp.ussg.iu.edu/pub/linux/gentoo ftp://chod.cwru.edu/gentoo/"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X acpi bash-completion berkdb bitmap-fonts cdr crypt cups curl
font-server foomaticdb fortran freetype gdbm gif gimpprint gpm gtk gtk2
imagemagick imap imlib ipv6 java jp2 jpeg junit lzw lzw-tiff mad maildir mikmod
motif mp3 ncurses nls nptl ogg opengl oss pam perl png ppds python qt readline
scanner sdl slang sox ssl tcltk tcpd tiff truetype truetype-fonts type1-fonts
usb userlocales vorbis xml2 xmms xpm xrandr xv zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS
Comment 1 Martin Schlemmer (RETIRED) gentoo-dev 2005-04-29 06:45:59 UTC
Please try sandbox-1.2.3 - we changed the libc detection stuff.
Comment 2 Jason Stubbs (RETIRED) gentoo-dev 2005-04-29 07:03:29 UTC
*** Bug 90852 has been marked as a duplicate of this bug. ***
Comment 3 Martin Schlemmer (RETIRED) gentoo-dev 2005-04-29 07:05:16 UTC
Jeremy, should amd64 2005.0 use the emu stuff btw??
Comment 4 mikepolniak 2005-04-29 08:03:54 UTC
emerge sandbox-1.2.1-r3 gives the same eroor.




Comment 5 Martin Schlemmer (RETIRED) gentoo-dev 2005-04-29 08:08:34 UTC
No, sandbox-1.2.3 (was added about an hour ago I think).
Comment 6 mikepolniak 2005-04-29 08:39:00 UTC
OK i just tried sandbox-1.2.3 with the tar file from 
http://dev.gentoo.org/~azarah/sandbox/sandbox-1.2.3.tar.bz2

and it fails with the exact same error.
Comment 7 Martin Schlemmer (RETIRED) gentoo-dev 2005-04-29 08:46:36 UTC
Configure should have aborted.  But I still think its a multilib related issue.
Comment 8 Martin Schlemmer (RETIRED) gentoo-dev 2005-04-29 08:51:13 UTC
Can you please attach the whole emerge log + config.log from each dir (if more than one I think for multilib)?
Comment 9 mikepolniak 2005-04-29 09:19:05 UTC
Created attachment 57588 [details]
config log for sandbox-1.2.3-x86

sandbox-1.2.3-amd64 does not get configured, just sandbox-1.2.3-x86


The emerge log is:
1114791027: Started emerge on: Apr 29, 2005 12:10:27
1114791027:  *** emerge  sandbox
1114791027:  >>> emerge (1 of 1) sys-apps/sandbox-1.2.3 to /
1114791027:  === (1 of 1) Cleaning
(sys-apps/sandbox-1.2.3::/usr/portage/sys-apps/sandbox/sandbox-1.2.3.ebuild)
1114791027:  === (1 of 1) Compiling/Merging
(sys-apps/sandbox-1.2.3::/usr/portage/sys-apps/sandbox/sandbox-1.2.3.ebuild)
1114791031:  *** terminating.
Comment 10 Jeremy Huddleston (RETIRED) gentoo-dev 2005-04-29 10:30:36 UTC
Ok... why is it looking for /emul/linux/x86/lib/libc.so.6?  Did you follow the 2005.0 upgrade guide?  Can you please cat /usr/lib32/libc.so?  Is /usr/lib32 a symlink or directory?







'
Comment 11 mikepolniak 2005-04-29 10:42:24 UTC
I did the manual upgrade to 2005.0 profile about a month ago.

cat /usr/lib32/libc.so                                       /home/mike
/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf32-i386)
GROUP ( /lib32/libc.so.6 /usr/lib32/libc_nonshared.a )

...
drwxr-xr-x   61 root root 24576 Apr 22 08:33 lib
drwxr-xr-x    8 root root  4096 Apr  8 09:29 lib32
lrwxrwxrwx    1 root root     3 Mar 31 09:01 lib64 -> lib
Comment 12 SpanKY gentoo-dev 2005-04-29 14:07:01 UTC
what does `grep /emul /etc/ld.so.conf /etc/env.d/*` show ?

azarah: the configure script did abort, just very very early :)
Comment 13 mikepolniak 2005-04-29 17:08:24 UTC
20:03 >>grep /emul /etc/ld.so.conf /etc/env.d/*                      /etc/env.d
/etc/ld.so.conf:/emul/linux/x86/lib
/etc/ld.so.conf:/emul/linux/x86/usr/lib
/etc/env.d/75emul-linux-x86-base:LDPATH=/emul/linux/x86/lib:/emul/linux/x86/usr/lib
Comment 14 Roy Marples (RETIRED) gentoo-dev 2005-05-02 23:52:09 UTC
I'm getting this too - and I did the scripted install shortly after 2005.0 was released.

Other apps which will not build include glibc, and portage (stable and ~amd64) and all seem to be the same error.

Note that many other apps build just fine and dandy - weird
Comment 15 Martin Schlemmer (RETIRED) gentoo-dev 2005-05-03 04:17:01 UTC
Well, I cannot do much here, as I do not have the setup to test this.  Somebody with an amd64 will either have to tell me what to fix, or sort out the 2005.0 borkage which seems to be possibly present.
Comment 16 Daniel Gryniewicz (RETIRED) gentoo-dev 2005-05-03 06:52:40 UTC
Notice that all the apps that fail to build are ones that build 32-bit components.  I bet gcc fails to build as well.  This is a symptom of (so far, at least) an upgrade from 2004.3 no-multilib to 2005.0 multilib.  I helped someone make this transition yesterday, and it turned out that this link helped:

http://forums.gentoo.org/viewtopic-t-293507-start-25.html
Comment 17 mikepolniak 2005-05-03 08:06:44 UTC
Well, I had 2004.3 with multilib when i upgraded tp 2005.0
Comment 18 Daniel Gryniewicz (RETIRED) gentoo-dev 2005-05-03 08:48:16 UTC
In 2005.0, there shouldn't be a /emul/linux/x86/lib/libc.so.6, it should be in /lib32/libc.so.6.  Obviously, your upgrade didn't proceed correctly.

Do you have a /lib32/libc.so.6?  Do you have
/lib32
/usr/lib32
/usr/local/lib32
in your /etc/ld.so.conf?
Comment 19 mikepolniak 2005-05-03 09:43:09 UTC
Yes i have all of those:

12:34 >>locate libc.so.6                                             /home/mike
/lib/libc.so.6
/lib32/libc.so.6

and

# ld.so.conf autogenerated by env-update; make all changes to
# contents of /etc/env.d directory
/usr/local/lib
/usr/lib32/opengl/nvidia/lib
/usr/lib/opengl/nvidia/lib
/lib
/usr/lib
/usr/local/lib
/lib32
/usr/lib32
/usr/local/lib32
/lib64
/usr/lib64
/usr/local/lib64
Comment 20 Daniel Gryniewicz (RETIRED) gentoo-dev 2005-05-03 12:01:35 UTC
Couple of thoughts:

Do you use ccache?

What's the output of
find / -name "*.la" -exec grep -H "emul" {} \;
Comment 21 Jeremy Huddleston (RETIRED) gentoo-dev 2005-05-03 12:12:15 UTC
Mike, what's the output of both of these:

file /lib/libc.so.6
file /lib32/libc.so.6
Comment 22 mikepolniak 2005-05-03 13:42:28 UTC
file /lib/libc.so.6                                          /home/mike
/lib/libc.so.6: symbolic link to `libc-2.3.4.so'
16:40 >>file /lib32/libc.so.6                                        /home/mike
/lib32/libc.so.6: symbolic link to `libc-2.3.4.so'

Also i have never used ccache.

find / -name "*.la" -exec grep -H "emul" {} \;               /home/mike
find: WARNING: Hard link count is wrong for /proc: this may be a bug in your filesystem driver.  Automatically turning on find's -noleaf option.  Earlier results may have failed to include directories that should have been searched.
/emul/linux/x86/usr/lib/libGLU.la:libdir='/emul/linux/x86/usr/lib'
Comment 23 Mikko Tiihonen 2005-05-03 13:57:11 UTC
I've had this same problem since upgrading to 2005.0.

I just quick-fix it always when I need to compile a 32bit ebuild by editing the
/etc/make.profile/make.defaults file to contain -L/lib32 -L/usr/lib32 in
CFLAGS_x86 and LDFLAGS_x86.

After that for example sandbox can be emerged.

I'm not sure which component is responsible for passing the correct library paths to gcc. /etc/ld.so.conf etc all list the correct /lib32 and /usr/lib32 paths that have libc.so but gcc of course needs to be pointed to the libraries by some other means.

Maybe the gcc's 32bit configuration files... goes and have a look:
in my /usr/lib/gcc/x86_64-pc-linux-gnu/3.4.3-20050110/specs file there is only one entry that could have a bug when comparing all m32 vs !m32 settings:
%{m32:%{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}}       %{!m32:%{!dynamic-linker:-dynamic-linker /lib64/ld-linux-x86-64.so.2}}}

The problem is that /lib is a symbolic link to /lib64. Changing of /lib/ld-linux.so.2 to /lib32/ld-linux.so.2 might have a chance of working if someone wants to try it out.
Comment 24 Jeremy Huddleston (RETIRED) gentoo-dev 2005-05-03 14:06:55 UTC
whoops... I meant:
file /lib/libc-2.3.4.so
file /lib32/libc-2.3.4.so

Can youu try recompiling binutils and gcc with USE=multilib?
Comment 25 mikepolniak 2005-05-03 14:25:45 UTC
17:21 >>file /lib/libc-2.3.4.so                                  /usr/src/linux
/lib/libc-2.3.4.so: ELF 64-bit LSB shared object, AMD x86-64, version 1 (SYSV), stripped
17:22 >>file /lib32/libc-2.3.4.so                                /usr/src/linux
/lib32/libc-2.3.4.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), stripped

I am re-emerging binutils & gcc now
Comment 26 mikepolniak 2005-05-03 15:05:34 UTC
OK re-emerged binutils and gcc, but the multilib flag doesn't get recognized as expected.

But i did what was suggested in comment #23 i.e. 

edit /etc/make.profile/make.defaults file to contain -L/lib32 -L/usr/lib32 in
CFLAGS_x86 and LDFLAGS_x86.

and now sandbox compiles.
Comment 27 Gour 2005-05-19 02:58:43 UTC
Hi! 
 
Even after applying quick-fix mentioned in #23, I still have the problem that 
sandbox (1.2.8) cannot be emerged. 
 
I have /lib32/libc.so.6, cleared ccache...but the problem remains. 
 
However, I'm not the only one - see the 
thread:http://forums.gentoo.org/viewtopic-t-331684.html in Forums. 
 
Do you have any further idea how to resolve this issue? 
 
(Otherwise, I normally emerge different packages. I'm on ~amd64 and updated 
profile from 'multilib 2004.3' to 2005.0 with the script.) 
 
 
Sincerely, 
Gour 
 
 
Comment 28 Thomas Petersen 2005-05-23 14:18:11 UTC
I think I also had this problem. I was trying to emerge wine which is compiled 
as 32 bit but it gave me the same error. I knew it was possible to emerge wine 
because I had just done it earlier today on another computer. This computer is a 
much newer installation while the one where the compilation failed is a more 
than 1 year old installation.

I started to look for differences on the two computers and found that I had a 
lot of old stuff laying around in the /emul directory. Among others I had some 
broken symlinks, some old ati-drivers, some crt*.o files for gcc and alot of 
other stuff. I decided to simply move away the old /emul directory and then 
reemerge all installed emul-linux packages.

I tried emerging wine again and this time with success!
Comment 29 mikepolniak 2005-05-27 15:50:55 UTC
Yes, removing the /emul directory and re-emerging the emul* packages also lets
me emerge sandbox now.
Comment 30 Gour 2005-05-27 22:19:40 UTC
Hi! 
 
Confirmed. 
 
Removing /emul & re-emerging (I did it because of problems with pytgk 
applications not running - #76791) solved the problem. 
 
One hit - two flies :-) 
 
Sincerely, 
Gour 
 
Comment 31 Martin Schlemmer (RETIRED) gentoo-dev 2005-06-08 06:31:19 UTC
*** Bug 94015 has been marked as a duplicate of this bug. ***
Comment 32 Martin Schlemmer (RETIRED) gentoo-dev 2005-07-05 00:04:55 UTC
*** Bug 97962 has been marked as a duplicate of this bug. ***
Comment 33 Jeremy Huddleston (RETIRED) gentoo-dev 2005-07-05 00:42:50 UTC
Ok, Im going to close this as CANTFIX as it seems to be a problem with portage
not cleaning out a package thuroughly on an unmerge (perhaps because of touched
files or something else...)

So for these problems, it looks like 'rm -rf'ing /emul and re-emerging the emul-
packages cleans it out...  Please open a new bug if that doesn't fix the problem
for you...
Comment 34 Jeremy Huddleston (RETIRED) gentoo-dev 2005-07-05 00:44:01 UTC
*** Bug 94619 has been marked as a duplicate of this bug. ***
Comment 35 Jeremy Huddleston (RETIRED) gentoo-dev 2005-07-07 22:36:53 UTC
*** Bug 98232 has been marked as a duplicate of this bug. ***
Comment 36 Lucero del Alba 2005-07-11 09:14:49 UTC
Hi,

'rm -rf /emul' and re-emerging the emul-* packages didn't work for me.

My emul-* packages, just in case:

  emul-linux-x86-baselibs
  emul-linux-x86-compat
  emul-linux-x86-glibc
  emul-linux-x86-gtklibs
  emul-linux-x86-qtlibs
  emul-linux-x86-xlibs
Comment 37 Jeremy Huddleston (RETIRED) gentoo-dev 2005-07-12 11:36:26 UTC
Lucero, please come speak with me on IRC so we can work out your problem.