libmpc.so.2 was a dependency of the internal gcc binaries: :; readelf -d /usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.1/cc1 | egrep NEEDED 0x0000000000000001 (NEEDED) Shared library: [libmpc.so.2] but when portage updated dev-libs/mpc (due to dev-libs/mpc-1.0 landing in the sage-on-gentoo overlay), /usr/lib64/libmpc.so.2 was not preserved. Portage should check the internal gcc libs and binaries for lib dependecies, just as it does /usr/bin/*, et al.
(Incidently, the only way I can see to fix such a damaged system is to: :; ln -s libmpc.so.3 /usr/lib64/libmpc.so.2 before re-compiling.)
(In reply to comment #1) > (Incidently, the only way I can see to fix such a damaged system is to: > > :; ln -s libmpc.so.3 /usr/lib64/libmpc.so.2 That's a pretty bad idea, there. Try http://tinderbox.dev.gentoo.org/default-linux/amd64/dev-libs/mpc-0.8.2.tbz2 next time.
i have no idea what this "sage-on-gentoo" business is, but it has nothing to do with the toolchain. mpc-0.9 is in the main tree.
yes when mpc-1.0 is added it'll preserve libmpc.so.2.
This is not invalid. How exaclty could portage ever preserve a library version just because the ebuild is in the primary tree and not in an overlay. The replies here make no sense.
portage already has FEATURES=preserve-libs
Also, this is not a toolchain bug, nor did I write anything to suggest that it were. It is a sys-devel/portage bug, as I specified.
Yes, and I obviously have FEATURES=preserve-libs enabled or I wouldn’t have reported the damned bug. Please don’t interfere if you don’t understand the bug or the report.
(In reply to comment #8) you might want to adjust your attitude considering the OP (you) mis-reported it in the first place
OK. I see. Portage is a product, not a component. My browser history link is to the G-L product, so appologies for that confusion. But the prose in the opening report still should be obvious; I don’t see any ambiguity in it....
ambiguity: you need to post `emerge --info` in all bug reports. nowhere did you say you used FEATURES=preserve-libs, and most non-devs don't unmask the latest portage let alone know about that feature. so assuming anything there isn't really feasible. the original subject line you used was more accurate and probably should have been touched up rather than rewritten, but too late now. now that we're all on the same page, we can focus on the bug at hand. my understanding is that FEATURES=preserve-libs doesn't focus on specific paths but relies on the NEEDED database in /var/db/pkg to determine when something is still needed. i don't know what debugging information Zac could use here though to trace things down so he'll have to request.
I know for a fact that preserved-libs covers gcc libs already. Also the dev-libs/mpc-1.0 bump I forgot to commit in my overlay does indeed cause libmpc.so.2 to be preserved with preserve-libs so I'm not sure what the problem you're running into could be.
I don’t know, but it certainly did not preserve it here. I use portage-9999, but I haven’t updated it in a couple of weeks. Perhaps a bug already fixed? Or one only in the master branch?
(In reply to comment #13) > I use portage-9999, but I haven’t updated it in a couple of weeks. Please post the output of emerge --version (it reports the version relative to the closed tag). > Perhaps a bug already fixed? Or one only in the master branch? The most recently fixed preserve-libs bug in the master branch was bug 406837, and it's already been released since portage-2.2.0_alpha90.
(In reply to comment #0) > Portage should check the internal gcc libs and binaries for lib dependecies, > just as it does /usr/bin/*, et al. It accounts for the NEEDED fields of all installed ELF binaries. Please attach /var/db/pkg/sys-devel/4.7.1/NEEDED.ELF.2 which contains the data that preserve-libs uses.
Created attachment 321956 [details] gcc-4.7.1 NEEDED file Here is the NEEDED.ELF.2 file. libmpc.so.2 is in it. It is also mentioned in all of: /var/db/pkg/cross-alpha-linux-gnu/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-arm-linux-gnueabi/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-arm-linux-gnueabi/gcc-4.6.2/NEEDED.ELF.2 /var/db/pkg/cross-armv7a-hardfloat-linux-gnueabi/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-armv7a-hardfloat-linux-gnueabi/gcc-4.6.3/NEEDED.ELF.2 /var/db/pkg/cross-avr/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-bfin-elf/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-h8300-elf/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-ia64-linux-gnu/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-mingw32/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-mingw32/gcc-4.6.2/NEEDED.ELF.2 /var/db/pkg/cross-mips-linux-gnu/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-mips64-linux-gnu/gcc-4.5.2/NEEDED.ELF.2 /var/db/pkg/cross-powerpc-linux-gnu/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-powerpc64-linux-gnu/gcc-4.5.2/NEEDED.ELF.2 /var/db/pkg/cross-s390x-linux-gnu/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-sh4-linux-gnu/gcc-4.5.2/NEEDED.ELF.2 /var/db/pkg/cross-sparc-linux-gnu/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-sparc64-linux-gnu/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-sparc64-linux-gnu/gcc-4.6.2/NEEDED.ELF.2 /var/db/pkg/cross-spu-elf/gcc-4.5.3-r1/NEEDED.ELF.2 /var/db/pkg/cross-x86_64-w64-mingw32/gcc-4.5.3-r2/NEEDED.ELF.2 /var/db/pkg/cross-x86_64-w64-mingw32/gcc-4.6.2/NEEDED.ELF.2
I’ve already updated portage; the build log shows: GIT update --> repository: git://git.overlays.gentoo.org/proj/portage.git updating from commit: 0c46edc9290a459f693c12fbb34a2f361e40e168 to commit: b986bcdd49c5523ffe6972377071d556a819c776
now try grep -F libmpc.so.2 /var/db/pkg/*/CONTENTS if that matches (multiple times), there's the problem
sorry, that needs to be grep -F libmpc.so.2 /var/db/pkg/*/*/CONTENTS
I should take responsibility for putting it in the overlay without opening a bug for it in bugzilla. I fixed the ebuild in the sage-on-gentoo overlay to preserve the old library. I didn't know about preserving old libraries for portage 2.1.
The grep(1) (the correction was obvious) for libmpc.so.2 in the CONTENTS files returned no matches.
(In reply to comment #20) > I should take responsibility for putting it in the overlay without opening a > bug for it in bugzilla. I fixed the ebuild in the sage-on-gentoo overlay to > preserve the old library. > I didn't know about preserving old libraries for portage 2.1. So, this bug has nothing to do with FEATURES=preserve-libs then?
> So, this bug has nothing to do with FEATURES=preserve-libs then? As stated earlier, I do have FEATURES=preserve-libs set. Everything else is preserved w/o adding preserve_old_lib calls in pkg_preinst() and pkg_postinst() functions. If mpc-1.0 needs it, then wouldn’t *every* ebuild which installs a library need it, too?
If you have FEATURES=preserve-libs enabled, and your installed portage supports it, then preserve_old_lib is entirely irrelevant.
Well I am not sure if this is right bug, so correct me if I am wrong, but after update mpc to version 1.0, portage cries after every install that libmpc.so.2 is missing and needed by gcc. Gcc itself works, however this messages still presist after reemerging gcc.
Do you have USE=multislot? In that case this would be the same as bug 434536 (This is the kind of thing following the instructions about emerge --info helps with)
No, I do not USE multislot.
From eix -e sys-devel/gcc: 4.6.3 and 4.7.1: cxx doc fortran gcj go graphite gtk mudflap multilib nls nptl objc objc++ objc-gc openmp 4.4.7 and 4.5.4: the same except for go.
I think I encountered a similar problem, although I'm not using preserve-libs: I upgraded mpc, manually ran a revdep-rebuild which said "Dynamic linking on your system is consistent... All done.", then deleted libmpc.so.2 and gcc stopped working: "/usr/libexec/gcc/x86_64-pc-linux-gnu/4.5.4/cc1: error while loading shared libraries: libmpc.so.2: cannot open shared object file: No such file or directory" emerge --info (after switching to gcc 4.4.5 which still works): Portage 2.1.11.55 (default/linux/amd64/13.0, gcc-4.4.5, glibc-2.15-r3, 2.6.35.4-rscloud x86_64) ================================================================= System uname: Linux-2.6.35.4-rscloud-x86_64-Quad-Core_AMD_Opteron-tm-_Processor_2374_HE-with-gentoo-2.1 KiB Mem: 251140 total, 15696 free KiB Swap: 2097144 total, 1848740 free Timestamp of tree: Tue, 02 Apr 2013 00:30:01 +0000 ld GNU ld (GNU Binutils) 2.22 distcc 3.1 x86_64-pc-linux-gnu [disabled] app-shells/bash: 4.2_p37 dev-java/java-config: 2.1.12-r1 dev-lang/python: 2.7.3-r3, 3.2.3-r2 dev-util/pkgconfig: 0.28 sys-apps/baselayout: 2.1-r1 sys-apps/openrc: 0.9.8.4 sys-apps/sandbox: 2.5 sys-devel/autoconf: 2.69 sys-devel/automake: 1.11.6 sys-devel/binutils: 2.22-r1 sys-devel/gcc: 4.4.5, 4.5.4 sys-devel/gcc-config: 1.7.3 sys-devel/libtool: 2.4-r1 sys-devel/make: 3.82-r4 sys-kernel/linux-headers: 3.7 (virtual/os-headers) sys-libs/glibc: 2.15-r3 Repositories: gentoo aditsu ACCEPT_KEYWORDS="amd64" ACCEPT_LICENSE="* -@EULA" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe -march=native" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/openvpn/easy-rsa /var/bind" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo" CXXFLAGS="-O2 -pipe -march=native" DISTDIR="/usr/portage/distfiles" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://gentoo.cites.uiuc.edu/pub/gentoo/" LANG="en_US.UTF-8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" MAKEOPTS="-j1" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/home/aditsu/ebuilds" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="acl amd64 berkdb bzip2 cjk cli cracklib crypt cxx dovecot-sasl dri gdbm geoip iconv ipv6 java managesieve mmx modules mudflap multilib ncurses nls nptl openmp pam pcre postgres readline session sieve sse sse2 ssl tcpd threads unicode vhosts zlib zsh-completion" ABI_X86="64" 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="authn_core authz_core socache_shmcb unixd 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 cgi cgid 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" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga nouveau nv r128 radeon savage sis tdfx trident vesa via vmware dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
(In reply to comment #29) > manually ran a revdep-rebuild which said > "Dynamic linking on your system is consistent... All done." Correction: the first time I ran "revdep-rebuild --library '/usr/lib64/libmpc.so.2' -- -av" which said "There are no dynamic links to /usr/lib64/libmpc.so.2... All done." After deleting libmpc.so.2 (and seeing gcc stop working) I ran "revdep-rebuild -i -- -av" which said "Dynamic linking on your system is consistent... All done."
(In reply to comment #30) > (In reply to comment #29) > > manually ran a revdep-rebuild which said > > "Dynamic linking on your system is consistent... All done." > > Correction: the first time I ran "revdep-rebuild --library > '/usr/lib64/libmpc.so.2' -- -av" which said "There are no dynamic links to > /usr/lib64/libmpc.so.2... All done." > > After deleting libmpc.so.2 (and seeing gcc stop working) I ran > "revdep-rebuild -i -- -av" which said "Dynamic linking on your system is > consistent... All done." That could be a bug in revdep-rebuild, which is different from preserve-libs. Please file a new bug.