# emerge -1vkB vorbis-tools These are the packages that would be built, in order: Calculating dependencies... done! [binary N ] media-libs/libkate-0.4.1-r3-1::gentoo USE="-debug -doc -wxwidgets" ABI_X86="32 64 -x32" PYTHON_TARGETS="python2_7" 0 KiB [binary N ] media-sound/vorbis-tools-1.4.0-r5-1::gentoo USE="flac kate nls ogg123 speex" 0 KiB Total: 2 packages (2 new, 2 binaries), Size of downloads: 0 KiB Would you like to merge these packages? [Yes/No] >>> Emerging binary (1 of 2) media-libs/libkate-0.4.1-r3::gentoo * libkate-0.4.1-r3-1.xpak MD5 SHA1 size ;-) ... [ ok ] >>> Extracting info >>> Extracting media-libs/libkate-0.4.1-r3 >>> Emerging binary (2 of 2) media-sound/vorbis-tools-1.4.0-r5::gentoo * vorbis-tools-1.4.0-r5-1.xpak MD5 SHA1 size ;-) ... [ ok ] >>> Extracting info >>> Extracting media-sound/vorbis-tools-1.4.0-r5 Sure, I guess there's no useful result to be expected there but unpacking binpackages and leaving them in ${PORTAGE_TMPDIR} is not something I'd expect.
I wonder if passing --buildpkgonly should disable --usepkg and --usepkgonly, or if emerge should just immediately exit with an error message given this combination of flags.
It doesn't clean ${PORTAGE_TMPDIR} because that normally happens after merge and the packages are never merged in --buildpkgonly mode.
(In reply to Mike Gilbert from comment #1) > I wonder if passing --buildpkgonly should disable --usepkg and --usepkgonly, > or if emerge should just immediately exit with an error message given this > combination of flags. --usepkgonly should definitely be an error, but --usepkg or --getbinpkg in EMERGE_DEFAULT_OPTS could be tolerated as long as we make them moot like this: > diff --git a/lib/_emerge/depgraph.py b/lib/_emerge/depgraph.py > index 51614fc14..17559ca84 100644 > --- a/lib/_emerge/depgraph.py > +++ b/lib/_emerge/depgraph.py > @@ -573,7 +573,8 @@ class _dynamic_depgraph_config(object): > db_keys = list(portdb._aux_cache_keys) > dbs.append((portdb, "ebuild", False, False, db_keys)) > > - if "--usepkg" in depgraph._frozen_config.myopts: > + if ("--usepkg" in depgraph._frozen_config.myopts and > + "--buildpkgonly" not in depgraph._frozen_config.myopts): > bindb = depgraph._frozen_config.trees[myroot]["bintree"].dbapi > db_keys = list(bindb._aux_cache_keys) > dbs.append((bindb, "binary", True, False, db_keys))