Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 28185 - GCC 3.3.1-r1 breaks Python, which breaks Portage.
Summary: GCC 3.3.1-r1 breaks Python, which breaks Portage.
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High critical
Assignee: Alexander Gabert (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-08 08:09 UTC by Lisa Seelye (RETIRED)
Modified: 2003-09-29 11:26 UTC (History)
7 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 Lisa Seelye (RETIRED) gentoo-dev 2003-09-08 08:09:59 UTC
Since Python isn't working I can't give an emerge info, so don't ask. :)

Using kernel 2.4.20-hardened-r4, with ~x86, Python version 2.2.3-r1, 
hardened-gcc-2.2.0 and with selinux enabled in the kernel, glibc-2.3.2-r1.

Use flags are:
USE="-3dfx -3dnow aalib acl -acpi -afs -alsa -apache2 -apm -arts -atlas \
    -avi berkdb -bonobo -canna -cdr -cjk crypt -cscope -cups -curl -directfb \
    -doc -dvd -dvb -emacs -encode -esd -ethereal -ev6 -evo -fbcon -firebird \
    -flash -foomaticdb freetds -freewnn -gd -gd -gdbm -ggi -gif -gnome \
    -gphoto2 -gpm -gps -gstreamer -gtk -gtk2 -gtkhtml -guile -icc -icc-pro \
    -imap -imlib innodb informix ipv6 -jack -java -jikes -joystick -jpeg \
    junit -kde -kerberos -krb4 -ladcca -lcms ldap -leim libg++ -libgda \
    -libwww -lirc -mad maidir -matrix -mbox -mcal -mikmod memlimit mmx \
    -motif -mozilla -mpeg mpi -mule -mysql -nas ncurses nhc98 -nls -nocardbus \
    -nocd oci8 odbc -oggvorbis -opengl -oss pam -pcmcia -pda -ppds -pdflib \
    perl -plotutils -png postgres -bindist prelude python -qt -quicktime \
    readline -ruby -samba sasl -scanner -sdl slang -slp -snmp -socks5 -spell
    -sse ssl -svga -tcltk -tcpd -tetex -tiff -truetype -trusted -usb -videos \
    -voodoo3 -wavelan -wmf -wxindows -X -Xaw3d -xface -xinerama -xosd xml \
    xml2 -xmms -xv selinux"



============
time root # emerge
python2.2: /lib/libgcc_s.so.1: version `GCC_3.3' not found (required by 
/usr/lib/gcc-lib/i586-pc-linux-gnu/3.3.1/libstdc++.so.5)

time root # ldd /lib/libgcc_s.so.1
        libc.so.6 => /lib/libc.so.6 (0x46329000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x0c7e5000)

time root # ldd /usr/lib/gcc-lib/i586-pc-linux-gnu/3.3.1/libstdc++.so.5
/usr/lib/gcc-lib/i586-pc-linux-gnu/3.3.1/libstdc++.so.5: /lib/libgcc_s.so.1: 
version `GCC_3.3' not found (required by /usr/lib/gcc-lib/i586-pc-linux-gnu/3.3.
1/libstdc++.so.5)
        libm.so.6 => /lib/libm.so.6 (0x46d03000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x46d26000)
        libc.so.6 => /lib/libc.so.6 (0x46d2f000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x12708000)


This is on a fresh install, after relabelling and rebooting I emerge sync'd, and 
the emerge -U world.
Comment 1 Lisa Seelye (RETIRED) gentoo-dev 2003-09-08 10:49:39 UTC
Pappy?
Comment 2 Colin Fox 2003-09-08 11:09:40 UTC
I've got the same problem - how do you fix this? I tried to execute emerge under python2.1, but there's no 'output' module (and probably others).

Fortunately epm & qpkg still work, so:

# epm -qa | grep glibc
glibc-2.2.5-r4
glibc-2.3.2-r1

USE = "X gtk2 gnome2 alsa -kde -qt -qtmt -arts mozsvg ssl"
CHOST = "i686-pc-linux-gnu"
kernel = 2.4.20-gentoo-r6
Comment 3 Michael J. Haehnel 2003-09-08 11:49:04 UTC
I had the same problem - but after these two steps (i did not know wich one fixed it) everything was ok.
1) ldconfig
2) close your current session

Now, you should be able to use "emerge" again.

Comment 4 Lisa Seelye (RETIRED) gentoo-dev 2003-09-08 12:00:32 UTC
The tip in comment 3 didn't help (doh).  As for comment 2, I don't have gentoolkit installed, so no qpkg.
Comment 5 Colin Fox 2003-09-08 12:19:20 UTC
This may be a little offtopic, but there seems to be the occasional bump in the emerge road where a library goes away that was required by various packages.

Isn't the whole portage thing supposed to protect against broken upgrades? When I upgrade a library version, why does the old one get deleted (thus breaking everything that was compiled against it). Why not just leave these libraries there? Or have some kind of cleanup process that can be run much later to determine if there's nothing using that library? (say, via last access date or something).
Comment 6 Michael J. Haehnel 2003-09-08 13:12:36 UTC
@Lisa: Sorry for my fist "doh" comment.

Ok, i got a few mashines here to reproduce this.
Please try this:
move the /lib/libgcc_s.so.1 out ouf this directory and then
ldconfig (ignore the errors)

Now emerge should work.
Sorry but i missed this step in Comment NR. 3.

Greetings
Comment 7 Colin Fox 2003-09-08 13:35:28 UTC
In my case, /lib/libgcc_s.so.1 was a symbolic link to /lib/libgcc_s-3.0.4.so.1

Getting rid of the -3.0.4 file as well as the link, then ldconfig'ing, worked.

Incidentally, the ldconfig complained that two libraries were not symbolic links:
libstdc++-libc6.1-1.so.2 and 
libstdc++-libc6.2-2.so.3

I moved both of those files into /tmp, then re-did the ldconfig. Those now appear as symbolic links in /usr/lib, and I don't get any warnings.

Is there a reason they weren't links in the first place?
Comment 8 Martin Schlemmer (RETIRED) gentoo-dev 2003-09-08 13:38:44 UTC
Right, its specific to gcc-3.2.3 in symbols.

Ok, quick question - where is the '5 min to learn hardened' docs ?
Where does that libgcc_s.so.1 come from, and should it not rather be
generated in the gcc ebuild whith 'hardened' in USE or such ?
Comment 9 Martin Schlemmer (RETIRED) gentoo-dev 2003-09-08 13:39:39 UTC
They come from libcompat.  If you move them away, things like flash may
not work anymore.  Btw, the warning is cosmetic only, so no need to worry.
Comment 10 Michael J. Haehnel 2003-09-08 13:47:11 UTC
Hy Colin,

of course you were right with the two files (ok, one file and a link). I just want to correct my fault in my first comment with a simple step (of course quick and dirty) so that a few other users can use emerge again.

Thanks for testing (and your comment), now i am happy and can go to sleep...
Comment 11 Alexander Gabert (RETIRED) gentoo-dev 2003-09-08 13:55:00 UTC
hardened-gcc -A (called in gcc ebuild) will be prepared to remedy these situations which come up when gcc gets updated/downgraded.

thanks for your support,

Alex
Comment 12 Bjarke Istrup Pedersen (RETIRED) gentoo-dev 2003-09-09 04:05:10 UTC
Going to follow this one before I upgrade my systems :)
Comment 13 Scott A. Friedman 2003-09-09 16:58:43 UTC
Hi

a different problem - or related?

# emerge
python2.2: error while loading shared libraries: /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/libstdc++.so.5: undefined symbol: , version GLIBCPP_3.2

this is with glibc-2.3.2-r1

ldconfig runs without complaint on my system but does not resolve this error.

# ldd libstdc++.so.5
        libm.so.6 => /lib/libm.so.6 (0x400c5000)
        libgcc_s.so.1 => /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/libgcc_s.so.1 (0x400e8000)
        libc.so.6 => /lib/libc.so.6 (0x400f1000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)

and

-rw-r--r--    1 root     root       238754 Sep  8 18:18 libgcc.a
-rw-r--r--    1 root     root        90398 Sep  8 18:18 libgcc_eh.a
lrwxrwxrwx    1 root     root           13 Sep  8 18:18 libgcc_s.so -> libgcc_s.so.1
-rw-r--r--    1 root     root       158232 Sep  8 18:18 libgcc_s.so.1
Comment 14 Alexander Gabert (RETIRED) gentoo-dev 2003-09-10 13:59:12 UTC
okay, thanks for your patience,

hardened-gcc-2.2.1 has just hit cvs, tomorrow it will be ready
it has logic for -A which will copy the libgcc of the new gcc if found.
the gcc ebuild calls -A if hardened-gcc is on the system

it has been tested here on my system with upgrading to 3.3.1 from 3.2.3

please test and report back!

thanks again,

Alex
Comment 15 Ulrich Plate (RETIRED) gentoo-dev 2003-09-11 02:44:25 UTC
Just out of curiosity, why did that happen on one of my two machines 
during emerge -u world, and not the other, despite of them doing the
update run at exactly the same time and from the same sources?

Host 1 (desktop), broken Python as described above: 

Portage 2.0.49-r3 (default-x86-1.4, gcc-3.3.1, glibc-2.2.5-r2,2.3.2-r1, 2.6.0-test4-mm1)
=================================================================
System uname: 2.6.0-test4-mm1 i686 Intel(R) Pentium(R) 4 CPU 1.80GHz
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=pentium3 -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config /usr/kde/3/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="-O3 -march=pentium3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs sandbox ccache distcc usersandbox"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="x86 oss apm avi crypt cups encode foomaticdb gif jpeg libg++ mad mikmod mmx mpeg ncurses pdflib png quicktime spell truetype xml2 xmms xv gtkhtml gdbm berkdb slang readline arts tetex bonobo svga tcltk java guile X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gnome gtk qt kde motif opengl mozilla ldap scanner dvd -zlib canna cdr cjk nls xfs xface"

Host 2 (notebook), everything hunkydory:

Portage 2.0.49-r3 (default-x86-1.4, gcc-3.3.1, glibc-2.3.2-r1, 2.6.0-test4-mm1)
=================================================================
System uname: 2.6.0-test4-mm1 i686 Pentium III (Coppermine)
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=pentium3 -O3 -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/kde/3/share/config /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="-march=pentium3 -O3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs sandbox ccache distcc userpriv usersandbox fixpackages"
GENTOO_MIRRORS="http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://www.mirror.ac.uk/sites/www.ibiblio.org/gentoo/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="x86 oss apm avi crypt cups encode foomaticdb gif jpeg gnome libg++ mad mikmod mmx mpeg ncurses pdflib png quicktime spell truetype xml2 xmms xv gdbm berkdb slang readline arts tetex svga java guile X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gtk qt kde motif opengl dvd -zlib canna cdr cjk nls xfs xface"
Comment 16 Martin Schlemmer (RETIRED) gentoo-dev 2003-09-11 08:16:52 UTC
Your baby Alex - just close up when you are ok about the temp fix.
Thanks.
Comment 17 Alexander Gabert (RETIRED) gentoo-dev 2003-09-11 13:04:01 UTC
dear bug followers,

please emerge hardened-gcc-2.2.1 and test the new behaviour by making a chroot transition from gcc-3.2.3 with hardened-gcc-2.2.1 to gcc-3.3.x as in ~x86.

report back and we will try to work it out.

also remember that we have slight issues with -static in coherence to propolice and the library order in collect2, investigating it...
Comment 18 Alexander Gabert (RETIRED) gentoo-dev 2003-09-29 11:26:03 UTC
hcc-2.4.1 will come soon, until then use hcc-2.4.0

problems with libgcc_so should disappear in 2.4.x versions of hcc

TIA