Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 407117 - sys-apps/portage-2.2.0_alpha90 --newuse does not detect REQUIRED_USE conflict for built packages
Summary: sys-apps/portage-2.2.0_alpha90 --newuse does not detect REQUIRED_USE conflict...
Status: RESOLVED INVALID
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-06 13:50 UTC by Paweł Rumian
Modified: 2012-03-06 15:22 UTC (History)
1 user (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 Paweł Rumian 2012-03-06 13:50:30 UTC
Emerge does not always throw warning about conflict in USE flags.
Compare these results:

# emerge -pvuDN world
These are the packages that would be merged, in order:
Calculating dependencies... done!
Total: 0 packages, Size of downloads: 0 kB

# emerge -pvuD world
These are the packages that would be merged, in order:
Calculating dependencies... done!
Total: 0 packages, Size of downloads: 0 kB

# emerge -pvu world
These are the packages that would be merged, in order:
Calculating dependencies... done!
Total: 0 packages, Size of downloads: 0 kB

# emerge -pvDN world
These are the packages that would be merged, in order:
Calculating dependencies... done!
Total: 0 packages, Size of downloads: 0 kB


BUT:


# emerge -pvD world

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

Calculating dependencies -

!!! Problem resolving dependencies for sci-libs/hdf5 from @selected                                   ... done!

!!! The ebuild selected to satisfy "sci-libs/hdf5" has unmet requirements.
- sci-libs/hdf5-1.8.8::gentoo USE="cxx fortran (multilib) threads zlib -debug -examples -fortran2003 -mpi -static-libs -szip"

  The following REQUIRED_USE flag constraints are unsatisfied:
    threads? ( !cxx !fortran )

  The above constraints are a subset of the following complete expression:
    cxx? ( !mpi ) mpi? ( !cxx ) threads? ( !cxx !mpi !fortran ) fortran2003? ( fortran )

(dependency required by "@selected" [set])
(dependency required by "@world" [argument])

# emerge -pv world

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

Calculating dependencies |

!!! Problem resolving dependencies for sci-libs/hdf5 from @selected                                   ... done!

!!! The ebuild selected to satisfy "sci-libs/hdf5" has unmet requirements.
- sci-libs/hdf5-1.8.8::gentoo USE="cxx fortran (multilib) threads zlib -debug -examples -fortran2003 -mpi -static-libs -szip"

  The following REQUIRED_USE flag constraints are unsatisfied:
    threads? ( !cxx !fortran )

  The above constraints are a subset of the following complete expression:
    cxx? ( !mpi ) mpi? ( !cxx ) threads? ( !cxx !mpi !fortran ) fortran2003? ( fortran )

(dependency required by "@selected" [set])
(dependency required by "@world" [argument])


Still, the package is installed with now-conflicting options:

# eix hdf5
[I] sci-libs/hdf5
     Available versions:  1.8.4-r1 (~)1.8.7 (~)1.8.8 {cxx debug examples fortran fortran2003 mpi static-libs szip threads zlib}
     Installed versions:  1.8.8(14:36:12 18.11.2011)(cxx fortran threads zlib -debug -examples -fortran2003 -mpi -static-libs -szip)
     Homepage:            http://www.hdfgroup.org/HDF5/
     Description:         General purpose library and file format for storing scientific data

Of course now I get:

# emerge -1 hdf5
Calculating dependencies \

!!! Problem resolving dependencies for sci-libs/hdf5                                                  ... done!

!!! The ebuild selected to satisfy "hdf5" has unmet requirements.
- sci-libs/hdf5-1.8.8::gentoo USE="cxx fortran (multilib) threads zlib -debug -examples -fortran2003 -mpi -static-libs -szip"

  The following REQUIRED_USE flag constraints are unsatisfied:
    threads? ( !cxx !fortran )

  The above constraints are a subset of the following complete expression:
    cxx? ( !mpi ) mpi? ( !cxx ) threads? ( !cxx !mpi !fortran ) fortran2003? ( fortran )

From the changelog it looks like some REQUIRED_USE had been changed in the meantime (no mention of threads? (!cxx !fortran) conflict, though:

# equery c -l hdf5
05 Dec 2011; Kacper Kowalik <xarthisius@gentoo.org> hdf5-1.8.8.ebuild:
  Fix REQUIRED_USE being defined twice. Thanks to Arfrever

  05 Dec 2011; Kacper Kowalik <xarthisius@gentoo.org> hdf5-1.8.8.ebuild:
  Use REQUIRED_USE instead of providing sane defaults wrt #392683 by Murph
  <MattFinn@gmail.com>

  21 Nov 2011; Kacper Kowalik <xarthisius@gentoo.org>
  +files/hdf5-1.8.8-array_bounds.patch, +files/hdf5-1.8.8-implicits.patch,
  hdf5-1.8.8.ebuild:
  Fix implicits and array out of bounds


Is it just a result of changing options in the ebuild without bumping version, or a bug in portage?

Reproducible: Didn't try

Steps to Reproduce:
1. Obviously I cannot reproduce it now because I cannot rebuild hdf5 with now-conflicting options.
2.
3.



# emerge --info
Portage 2.2.0_alpha90 (default/linux/amd64/10.0/desktop, gcc-4.5.3, glibc-2.14.1-r2, 3.2.2-gentoo x86_64)
=================================================================
System uname: Linux-3.2.2-gentoo-x86_64-AMD_Athlon-tm-_II_X3_450_Processor-with-gentoo-2.1
Timestamp of tree: Tue, 06 Mar 2012 12:30:01 +0000
app-shells/bash:          4.2_p20
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.7.2-r3, 3.2.2
dev-util/cmake:           2.8.7-r3
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1
sys-apps/openrc:          0.9.9.2
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.11.3
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.5.3-r2
sys-devel/gcc-config:     1.5.1
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.2-r1 (virtual/os-headers)
sys-libs/glibc:           2.14.1-r2
Repositories: gentoo local-repo
Installed sets: 
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /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="-march=native -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y"
FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="pl_PL.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="pl"
MAKEOPTS="-j4"
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/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext X a52 aac acpi alsa amd64 bash-completion bluetooth branding bzip2 cairo cdda cdr cli cracklib crypt cups cxx dga dri dts dvd dvdr emboss encode exif fam firefox flac fortran gdu gif gnutls gpm gtk iconv ipv6 jpeg lapack lcms mad mmx mmxext mng modules mp3 mp4 mpeg mudflap multilib ncurses nls nptl nptlonly ogg opengl openmp pam pango pcre pdf png ppds pppd python readline session smp spell sse sse2 ssl svg sysfs tcpd threads tiff truetype udev unicode usb vorbis x264 xcb xml xmp xorg xulrunner xv xvid zlib" ALSA_CARDS="emu10k1" 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="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 stage tables krita karbon braindump" CAMERAS="directory" 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="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="pl" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby19" USERLAND="GNU" VIDEO_CARDS="radeon r600" 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, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Zac Medico gentoo-dev 2012-03-06 14:56:08 UTC
REQUIRED_USE is a build-time dependency, so apparently the REQUIRED_USE conflicts that you see were added only after you built the packages. So, it's not a problem until you try to rebuild the packages. Note that -u and -N imply --selective, so the commands with those options don't force a bunch of rebuilds like the other ones do.
Comment 2 Paweł Rumian 2012-03-06 15:08:51 UTC
(In reply to comment #1)
> Note that -u and -N imply --selective, so the commands with those options don't > force a bunch of rebuilds like the other ones do.

Ah, now I understand. Thank you for explaining. 
I guess I can close the bug now?
Comment 3 Zac Medico gentoo-dev 2012-03-06 15:22:05 UTC
Yeah, I guess we could add another option like --newuse for this, but it's probably not worth the trouble.