Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 467896

Summary: sys-apps/portage-2.2.0_alpha173: /usr/lib/libpng12.so.0 is seemingly preserved for app-backup/spideroak-bin-4.8.3-r1, when it is actually preserved for another package (like dropbox)
Product: Gentoo Linux Reporter: Jauhien Piatlicki (RETIRED) <jauhien>
Component: Current packagesAssignee: Portage team <dev-portage>
Status: RESOLVED FIXED    
Severity: normal CC: blueness, dschridde+gentoobugs, esigra
Priority: Normal Keywords: InVCS
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=277433
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 240323, 468524    
Attachments: NEEDED.ELF.2

Description Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-29 17:41:03 UTC
app-backup/spideroak-bin should have dependency on media-libs/libpng:1.2
I've found it out after depclean, when there was nothing else dependent on media-libs/libpng:1.2, so it was removed, and I got:

!!! existing preserved libs:
>>> package: media-libs/libpng-1.2.50
 *  - /usr/lib/libpng12.so.0
 *      used by /opt/SpiderOak/lib/libQtGui.so.4 (app-backup/spideroak-bin-4.8.3-r1)
Comment 1 Dennis Schridde 2013-04-30 00:17:40 UTC
Could this be an instance of bug #402081 comment #6? I.e. is libpng bundled with spideroak-bin? I currently do not use it anymore, so please have a look for me, Jauhien.
Comment 2 Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-30 10:29:16 UTC
It seems it is the case.

jauhien@kamputar ~ % equery files spideroak-bin | grep png
/opt/SpiderOak/lib/libpng12.so.0
Comment 3 Dennis Schridde 2013-04-30 11:00:32 UTC
blueness: Could it be that the patch applied from bug #400979 comment #19 does not work anymore...?

Jauhien: Could you please check the output of the following command?
# scanelf --rpath /opt/SpiderOak/lib/libQtGui.so.4
Comment 4 Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-30 11:09:46 UTC
Dennis:

jauhien@kamputar ~ % scanelf --rpath /opt/SpiderOak/lib/libQtGui.so.4
 TYPE   RPATH FILE 
ET_DYN $ORIGIN /opt/SpiderOak/lib/libQtGui.so.4
Comment 5 Dennis Schridde 2013-04-30 11:59:38 UTC
Very weird. From all I know until now, I think it should work as intended. Maybe it is a portage bug?

Zac, sorry for bothering you with this, but do you see any obvious mistake on our side?
Comment 6 Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-30 12:03:43 UTC
I've just tested it once again:

jauhien@kamputar ~ % sudo emerge --unmerge 'libpng:1.2'
 * This action can remove important packages! In order to be safer, use
 * `emerge -pv --depclean <atom>` to check for reverse dependencies before
 * removing packages.

 media-libs/libpng
    selected: 1.2.50 
   protected: none 
     omitted: 1.5.15 

All selected packages: media-libs/libpng-1.2.50

>>> 'Selected' packages are slated for removal.
>>> 'Protected' and 'omitted' packages will not be removed.

>>> Waiting 5 seconds before starting...
>>> (Control-C to abort)...
>>> Unmerging in:  5 4 3 2 1 
>>> Unmerging (1 of 1) media-libs/libpng-1.2.50...
>>> needed   obj /usr/lib/libpng12.so.0

 * GNU info directory index is up-to-date.

!!! existing preserved libs:
>>> package: media-libs/libpng-1.2.50
 *  - /usr/lib/libpng12.so.0
 *      used by /opt/SpiderOak/lib/libQtGui.so.4 (app-backup/spideroak-bin-4.8.3-r1)
 *      used by /opt/dropbox/libwx_gtk2ud_adv-2.8.so.0 (net-misc/dropbox-1.6.16)
 *      used by /opt/dropbox/libwx_gtk2ud_core-2.8.so.0 (net-misc/dropbox-1.6.16)
 *      used by /opt/dropbox/libwx_gtk2ud_qa-2.8.so.0 (net-misc/dropbox-1.6.16)
Use emerge @preserved-rebuild to rebuild packages using these libraries


So /opt/SpiderOak/lib/libQtGui.so.4 still appears.
Comment 7 Anthony Basile gentoo-dev 2013-04-30 12:20:32 UTC
(In reply to comment #5)
> Very weird. From all I know until now, I think it should work as intended.
> Maybe it is a portage bug?
> 
> Zac, sorry for bothering you with this, but do you see any obvious mistake
> on our side?


blueness@yellow / $ ldd /opt/SpiderOak/lib/libQtGui.so.4  | grep libpng
	libpng12.so.0 => /opt/SpiderOak/lib/libpng12.so.0 (0x00007f5411413000)

Looks like something wierd in portage still thinking that libQtGui.so.4 links against the system libpng12.so.0 rather than the one in the SpiderOak/lib.
Comment 8 Zac Medico gentoo-dev 2013-04-30 14:34:31 UTC
Please attach /var/db/pkg/app-backup/spideroak-bin-4.8.3-r1/NEEDED.ELF.2
Comment 9 Zac Medico gentoo-dev 2013-04-30 21:20:00 UTC
I've tested this by installing spideroak-bin-4.8.3-r1 on an x86 system, but I couldn't reproduce the problem when I uninstalled libpng:1.2. The relevant entry from /var/db/pkg/app-backup/spideroak-bin-4.8.3-r1/NEEDED.ELF.2 looked like this:

386;/opt/SpiderOak/lib/libQtGui.so.4;libQtGui.so.4;$ORIGIN;libQtCore.so.4,libpthread.so.0,libgthread-2.0.so.0,libglib-2.0.so.0,libpng12.so.0,libz.so.1,libfreetype.so.6,libSM.so.6,libICE.so.6,libXrender.so.1,libfontconfig.so.1,libXext.so.6,libX11.so.6,libstdc++.so.6,libm.so.6,libgcc_s.so.1,libc.so.6

If you are able to reproduce the problem, then please attach your /var/db/pkg/app-backup/spideroak-bin-4.8.3-r1/NEEDED.ELF.2 file.
Comment 10 Zac Medico gentoo-dev 2013-04-30 21:23:40 UTC
The libpng12.so.0 entry is also relevant. It worked for me with this entry:

386;/opt/SpiderOak/lib/libpng12.so.0;libpng12.so.0;$ORIGIN;libz.so.1,libm.so.6,libc.so.6
Comment 11 Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-30 21:38:03 UTC
Created attachment 347012 [details]
NEEDED.ELF.2

The entire NEEDED.ELF.2 attached. Do you need any additional info?
Comment 12 Zac Medico gentoo-dev 2013-04-30 21:52:57 UTC
(In reply to comment #11)
> Created attachment 347012 [details]
> NEEDED.ELF.2
> 
> The entire NEEDED.ELF.2 attached. Do you need any additional info?

Your entries seem perfectly identical to mine. Please post emerge --info output.
Comment 13 Jauhien Piatlicki (RETIRED) gentoo-dev 2013-04-30 22:00:59 UTC
jauhien@kamputar ~ % emerge --info
Portage 2.2.0_alpha173 (default/linux/x86/13.0/desktop, gcc-4.8.0, glibc-2.15-r3, 3.8.3-gentoo-r1 i686)
=================================================================
System uname: Linux-3.8.3-gentoo-r1-i686-Intel-R-_Atom-TM-_CPU_N280_@_1.66GHz-with-gentoo-2.2
KiB Mem:     1020144 total,     28164 free
KiB Swap:    5242872 total,   4496792 free
Timestamp of tree: Fri, 26 Apr 2013 00:45:01 +0000
ld GNU ld (GNU Binutils) 2.22
ccache version 3.1.9 [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/ccache:          3.1.9
dev-util/cmake:           2.8.9
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6, 1.13.1
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.6.3, 4.8.0
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 sunrise science sage-on-gentoo lisp gnu-elpa marmalade melpa java-overlay jauhien mv fix
ACCEPT_KEYWORDS="x86"
ACCEPT_LICENSE="* -@EULA"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=native -mtune=native -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="${EPREFIX}/etc/gconf /etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /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"
CXXFLAGS="-O2 -march=native -mtune=native -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -march=i686 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -march=i686 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="uk_UA.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="/usr/layman/sunrise /usr/layman/science /usr/layman/sage-on-gentoo /usr/layman/lisp /usr/layman/gnu-elpa /usr/layman/marmalade /usr/layman/melpa /usr/layman/java-overlay /usr/layman/jauhien /usr/layman/mv /usr/local/portage/fix"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa bash-completion berkdb bluetooth branding bzip2 c++0x cairo cdr cli consolekit cracklib crypt curl cxx dbus djvu dri dts dvd dvdr emacs emboss encode exif expat fam ffmpeg fftw firefox flac fortran gdbm gif gpm gtk gtk3 iconv icu ipv6 javascript jpeg jpeg2k latex lcms libnotify lm_sensors mad mbox mmx mmxext mng modplug modules mp3 mp4 mpeg mudflap ncurses networkmanager nls nptl nsplugin ogg opengl openmp pam pango pcre pdf perl png policykit ppds pythia8 python qt3support readline sdl session smp sndfile spell sqlite sqlite3 sse sse2 ssl startup-notification svg system-sqlite tcpd threads tiff truetype udev udisks unicode upower usb v4l vorbis wxwidgets x264 x86 xcb xml xmlrpc xv xvid zlib zsh-completion" ABI_X86="32" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 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="synaptics evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="be be_BY en en_GB ru uk pl" 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="intel" 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

P.S. I will have no Internet till 04.05, so it's may be the last info I can post until this time. But  Anthony Basile have reproduced this issue, so I hope he will provide any necessary additional info before I'll return.
Comment 14 Zac Medico gentoo-dev 2013-05-01 01:37:38 UTC
(In reply to comment #6)
> !!! existing preserved libs:
> >>> package: media-libs/libpng-1.2.50
>  *  - /usr/lib/libpng12.so.0
>  *      used by /opt/SpiderOak/lib/libQtGui.so.4
> (app-backup/spideroak-bin-4.8.3-r1)
>  *      used by /opt/dropbox/libwx_gtk2ud_adv-2.8.so.0
> (net-misc/dropbox-1.6.16)
>  *      used by /opt/dropbox/libwx_gtk2ud_core-2.8.so.0
> (net-misc/dropbox-1.6.16)
>  *      used by /opt/dropbox/libwx_gtk2ud_qa-2.8.so.0
> (net-misc/dropbox-1.6.16)
> Use emerge @preserved-rebuild to rebuild packages using these libraries

Has anyone observed this issue with libQtGui.so.4 as the only consumer, and no other consumers (like the dropbox consumers shown above)? If not, then this could just be a display issue, where the library is really preserved only for dropbox, but /opt/SpiderOak/lib/libQtGui.so.4 is displayed as a consumer erroneously. I've already checked the code, and I can confirm the the display issue certainly exists.
Comment 15 Zac Medico gentoo-dev 2013-05-01 01:59:12 UTC
(In reply to comment #14)
> I've already checked the code, and I can confirm the
> the display issue certainly exists.

A similar issue will also cause @preserved-rebuild to pull in the displayed packages for rebuild.
Comment 16 Zac Medico gentoo-dev 2013-05-01 04:06:52 UTC
(In reply to comment #15)
> (In reply to comment #14)
> > I've already checked the code, and I can confirm the
> > the display issue certainly exists.
> 
> A similar issue will also cause @preserved-rebuild to pull in the displayed
> packages for rebuild.

These issues are fixed in git:

http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=f3b2054cb599d6ef34612874b5e067f67667dcac
Comment 17 Zac Medico gentoo-dev 2013-05-01 04:37:34 UTC
(In reply to comment #16)
> http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;
> h=f3b2054cb599d6ef34612874b5e067f67667dcac

Here's a new version of that commit with a small fixup:

http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=361706c50ca591c22ac3ca5fca6450a7cbe510d2
Comment 18 Zac Medico gentoo-dev 2013-05-03 21:13:28 UTC
This is fixed in 2.1.11.63 and 2.2.0_alpha174.