"emerge --buildpkgonly" tries to build package which have DEPEND hard blocking package(s) already installed. Depending on package combination, build process may fail (but it should not start in first place). Reproducible: Always Steps to Reproduce: 1. emerge --oneshot media-plugins/mediastreamer-bcg729 2. emerge --buildpkgonly net-libs/pjproject 3. Actual Results: "emerge --buildpkgonly net-libs/pjproject" fails at build stage Expected Results: "emerge --buildpkgonly net-libs/pjproject" exit with error message about dependencies problem or uninstall media-plugins/mediastreamer-bcg729 (if no package depends on it). emerge command without --buildpkgonly flag works flawlessly - exit with error message about dependency problem. Package net-libs/pjproject is just one example. Problem affect (more or less) all packages that have DEPEND hard blockers. Portage: latest stable (2.3.66-r1) Tested on several different AMD64 computers with different profiles.
They're ignored for --buildpkgonly because of this logic in the depgraph _accept_blocker_conflicts method: > def _accept_blocker_conflicts(self): > acceptable = False > for x in ("--buildpkgonly", "--fetchonly", > "--fetch-all-uri", "--nodeps"): > if x in self._frozen_config.myopts: > acceptable = True > break > return acceptable
Ping. This just wastes a few hours of my time on trying to figure out why pytest test are failing.
Patch posted for review: https://archives.gentoo.org/gentoo-portage-dev/message/2c0da4f5b3979cb38453b6287d2cfadb https://github.com/gentoo/portage/pull/480
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage.git/commit/?id=1b3131db0e22085dba7d0fb9fc6e5ec70c8c577d commit 1b3131db0e22085dba7d0fb9fc6e5ec70c8c577d Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2019-11-26 18:05:47 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-11-26 20:34:53 +0000 emerge --buildpkgonly: respect buildtime hard blockers Bug: https://bugs.gentoo.org/689226 Signed-off-by: Zac Medico <zmedico@gentoo.org> lib/_emerge/depgraph.py | 24 ++++++--- lib/portage/tests/resolver/test_blocker.py | 87 +++++++++++++++++++++++++++++- 2 files changed, 102 insertions(+), 9 deletions(-)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3e36007163e56015301e2146c671fb14b3b0af57 commit 3e36007163e56015301e2146c671fb14b3b0af57 Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2019-11-27 03:39:22 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-11-27 03:39:57 +0000 sys-apps/portage: Bump to version 2.3.80 #667432 Rename DCO_SIGNED_OFF_BY config variable to SIGNED_OFF_BY. #674562 eapply: Drop -s option for patch. #689226 emerge --buildpkgonly: respect buildtime hard blockers #699986 emerge: add --quickpkg-direct option Bug: https://bugs.gentoo.org/701268 Bug: https://bugs.gentoo.org/667432 Bug: https://bugs.gentoo.org/674562 Bug: https://bugs.gentoo.org/689226 Bug: https://bugs.gentoo.org/699986 Package-Manager: Portage-2.3.80, Repoman-2.3.18 Signed-off-by: Zac Medico <zmedico@gentoo.org> sys-apps/portage/Manifest | 1 + sys-apps/portage/portage-2.3.80.ebuild | 261 +++++++++++++++++++++++++++++++++ 2 files changed, 262 insertions(+)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage.git/commit/?id=a107f5bad841e5fad65298881e5a1feb9ffdbed1 commit a107f5bad841e5fad65298881e5a1feb9ffdbed1 Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2019-11-28 01:40:50 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-11-28 01:42:26 +0000 depgraph: fix buildtime_blockers logic Fixes: 1b3131db0e22 ("emerge --buildpkgonly: respect buildtime hard blockers") Bug: https://bugs.gentoo.org/689226 Signed-off-by: Zac Medico <zmedico@gentoo.org> lib/_emerge/depgraph.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7418f55285fcbde7b4f9aee3926b3a818b1b865e commit 7418f55285fcbde7b4f9aee3926b3a818b1b865e Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2019-11-27 17:57:30 -0800 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-11-27 17:58:23 -0800 sys-apps/portage: 2.3.80-r1 revbump for bug 689226 Package-Manager: Portage-2.3.80, Repoman-2.3.19 Signed-off-by: Zac Medico <zmedico@gentoo.org> sys-apps/portage/Manifest | 1 + sys-apps/portage/{portage-2.3.80.ebuild => portage-2.3.80-r1.ebuild} | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-)