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

Bug 545754

Summary: 'flip-flop of @preserved-rebuild' of sys-power/upower
Product: Portage Development Reporter: Toralf Förster <toralf>
Component: Core - Interface (emerge)Assignee: Portage team <dev-portage>
Status: UNCONFIRMED ---    
Severity: normal CC: esigra, freedesktop-bugs
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 155723    

Description Toralf Förster gentoo-dev 2015-04-06 17:17:36 UTC
A particular lib is required by 2 different packages in 2 different versions.
Each revdep-rebuild is requesting to run itself again and again.

First I got : 

Calculating dependencies  ..... done!
[ebuild   R    ] gnome-extra/gnome-power-manager-3.14.1 
[blocks b      ] sys-power/upower ("sys-power/upower" is blocking sys-power/upower-pm-utils-0.9.23-r2)
[uninstall     ]  sys-power/upower-pm-utils-0.9.23-r2 
[nomerge       ] gnome-extra/gnome-power-manager-3.14.1 
[ebuild  N     ]  sys-power/upower-0.99.2-r1  USE="introspection -ios (-selinux)" 

and immediately after that :

Use emerge @preserved-rebuild to rebuild packages using these libraries

 * IMPORTANT: 2 config files in '/etc' need updating.
 * See the CONFIGURATION FILES section of the emerge
 * man page to learn how to update config files.

 * IMPORTANT: 2 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

These are the packages that would be merged, in reverse order:

Calculating dependencies  .... done!
[ebuild   R    ] x11-plugins/wmbattery-2.45 
[ebuild   R    ] net-im/telepathy-mission-control-5.16.3 
[nomerge       ] kde-base/khelpcenter-4.14.3 
[nomerge       ]  kde-base/kdesu-4.14.3 
[nomerge       ]   kde-base/kdelibs-4.14.6-r1 
[nomerge       ]    sys-power/upower-pm-utils-0.9.23-r2  USE="introspection -ios" 
[blocks b      ]     sys-power/upower ("sys-power/upower" is blocking sys-power/upower-pm-utils-0.9.23-r2)
[uninstall     ]      sys-power/upower-0.99.2-r1 
[ebuild  N     ]    sys-power/upower-pm-utils-0.9.23-r2  USE="introspection -ios" 

 * IMPORTANT: 2 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

This is an unstable amd64 chroot image (named amd64-unstable_20150401) at a hardened host acting as a tinderbox.

Portage 2.2.18 (python 2.7.9-final-0, default/linux/amd64/13.0/desktop/kde, gcc-4.8.3, glibc-2.20-r2, 3.19.3-hardened x86_64)
System uname: Linux-3.19.3-hardened-x86_64-Intel-R-_Core-TM-_i7-3770_CPU_@_3.40GHz-with-gentoo-2.2
KiB Mem:    16164756 total,   4414292 free
KiB Swap:   16777212 total,  16734064 free
Timestamp of repository gentoo: Sun, 05 Apr 2015 20:00:01 +0000
sh bash 4.3_p33-r2
ld GNU ld (Gentoo 2.25 p1.0) 2.25
ccache version 3.2.1 [disabled]
app-shells/bash:          4.3_p33-r2::gentoo
dev-java/java-config:     2.2.0::gentoo
dev-lang/perl:            5.20.2::gentoo
dev-lang/python:          2.7.9-r2::gentoo, 3.3.5-r1::gentoo
dev-util/ccache:          3.2.1-r1::gentoo
dev-util/cmake:           3.1.0::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.13.11::gentoo
sys-apps/sandbox:         2.6-r1::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r1::gentoo
sys-devel/automake:       1.10.3-r1::gentoo, 1.11.6-r1::gentoo, 1.13.4::gentoo, 1.14.1::gentoo, 1.15::gentoo
sys-devel/binutils:       2.25::gentoo
sys-devel/gcc:            4.8.3::gentoo, 4.9.2::gentoo
sys-devel/gcc-config:     1.8::gentoo
sys-devel/libtool:        2.4.6-r1::gentoo
sys-devel/make:           4.1-r1::gentoo
sys-kernel/linux-headers: 3.19::gentoo (virtual/os-headers)
sys-libs/glibc:           2.20-r2::gentoo

    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://
    priority: -1000

ACCEPT_KEYWORDS="amd64 ~amd64"
CFLAGS="-march=native -O2 -pipe"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.2/conf /usr/share/qpsmtpd/plugins /var/lib/hsqldb /var/yp/Makefile"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.5/ext-active/ /etc/php/apache2-php5.6/ext-active/ /etc/php/cgi-php5.5/ext-active/ /etc/php/cgi-php5.6/ext-active/ /etc/php/cli-php5.5/ext-active/ /etc/php/cli-php5.6/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"
CXXFLAGS="-march=native -O2 -pipe"
EMERGE_DEFAULT_OPTS="--nospinner --tree --quiet-build --jobs 1"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS=" rsync:// rsync://"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
USE="X a52 aac acl acpi aes-ni alsa amd64 apache2 avx avx2 berkdb bluetooth branding bzip2 cairo cdda cdr cli consolekit corefonts cracklib crypt cups cxx dbus declarative designer dnssec dot dri drmkms dts dvd dvdr ecc emboss encode exif extraengine fam ffmpeg firefox flac fontconfig fortran fpm gd gdbm gif glamor gpm gtk gudev gui iconv icu isag jadetex jpeg kde kipi kvm lapack lcms libav libkms libnotify libvirtd logrotate mad mbox minizip mmx mmxext mng modules mp3 mp4 mpeg multilib mysql ncurses nls nptl ogg opengl openmp openssl pam pango pax_kernel pcre pcre16 pdf phonon plasma png policykit ppds python qemu qt3support qt4 readline sdl session spell spice sqlite sse sse2 sse4 sse4_1 sse4_2 ssh-askpass ssl ssse3 startup-notification svg tcpd theora thinkpad threads tiff tk tls truetype udev udisks uml unicode upower usb usbredir uxa v4l v4l2 video vorbis wxwidgets x264 xa xcb xcomposite xinerama xkb xml xmp xscreensaver xslt xv xvfb xvid xvmc zenmap zlib" 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" 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 author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserve r oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox 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" LINGUAS="en en_GB" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" RUBY_TARGETS="ruby19 ruby20" 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"
Comment 1 Pacho Ramos gentoo-dev 2015-04-11 10:02:35 UTC
I think something is wrong here in portage side:
- gnome-power-manager needs upower
- kdelibs supports both

=> it should then choose plain upower instead of switching from one to another constantly
Comment 2 Zac Medico gentoo-dev 2015-04-11 17:21:35 UTC
It seems that gnome-extra/gnome-power-manager is eligible for removal by emerge --depclean, because otherwise emerge should not uninstall sys-power/upower. In cases like this, I would recommend to run `emerge --ask --depclean` before running revdep-rebuild. If --depclean would remove a package that you want to keep, then you should add it to your world file like this:

   emerge --noreplace gnome-extra/gnome-power-manager

Since revdep-rebuild only looks at installed packages, it is not aware that gnome-power-manager is eligible for removal by emerge --depclean.
Comment 3 Toralf Förster gentoo-dev 2015-04-11 18:06:25 UTC
(In reply to Zac Medico from comment #2)
Wouldn't "emerge --depclean" complain to run "emerge @preserved-rebuild" first ?
Comment 4 Zac Medico gentoo-dev 2015-04-11 18:22:02 UTC
(In reply to Toralf Förster from comment #3)
> (In reply to Zac Medico from comment #2)
> Wouldn't "emerge --depclean" complain to run "emerge @preserved-rebuild"
> first ?

The @preserved-rebuild message is never anything more that a suggestion, so it will not stop you from running "emerge --depclean". I think we should adjust the message to recommend that you run "emerge --depclean" first.
Comment 5 Pacho Ramos gentoo-dev 2015-04-11 20:17:14 UTC
In my case I *always* run: eix-sync && emerge -avuDN world && emerge -a --depclean && emerge @preserved-rebuild && revdep-rebuild 

That way I ensure even broken packages with automagic deps are rebuild once the tree is clean. I am using that order for years without major issues, and with "preserved-libs" it's even safer :)