1 |
commit: eb752dfa3135774ddd9e409f007356528fba4391 |
2 |
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jul 5 08:39:24 2021 +0000 |
4 |
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jul 5 08:39:24 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=eb752dfa |
7 |
|
8 |
qmerge: ignore subslot in calculating replacing version |
9 |
|
10 |
Original patch by Joakim Tjernlund <Joakim.Tjernlund <AT> infinera.com> |
11 |
|
12 |
Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org> |
13 |
|
14 |
qmerge.c | 24 +++++++++++++++++------- |
15 |
1 file changed, 17 insertions(+), 7 deletions(-) |
16 |
|
17 |
diff --git a/qmerge.c b/qmerge.c |
18 |
index 9cbcc45..a624b89 100644 |
19 |
--- a/qmerge.c |
20 |
+++ b/qmerge.c |
21 |
@@ -1095,13 +1095,23 @@ pkg_merge(int level, const depend_atom *qatom, const tree_match_ctx *mpkg) |
22 |
|
23 |
previnst = best_version(slotatom, BV_INSTALLED); |
24 |
if (previnst != NULL) { |
25 |
- char *orepo = previnst->atom->REPO; |
26 |
- previnst->atom->REPO = NULL; |
27 |
- /* drop REPO from query, we don't care about where the |
28 |
- * replacement comes from here */ |
29 |
- replacing = atom_compare(mpkg->atom, previnst->atom); |
30 |
- replver = previnst->atom->PVR; |
31 |
- previnst->atom->REPO = orepo; |
32 |
+ char *orepo; |
33 |
+ char *osubslot; |
34 |
+ |
35 |
+ /* drop REPO and SUBSLOT from query, we don't care about where |
36 |
+ * the replacement comes from here, SUBSLOT only affects rebuild |
37 |
+ * triggering */ |
38 |
+ orepo = previnst->atom->REPO; |
39 |
+ osubslot = previnst->atom->SUBSLOT; |
40 |
+ previnst->atom->REPO = NULL; |
41 |
+ previnst->atom->SUBSLOT = NULL; |
42 |
+ |
43 |
+ replacing = atom_compare(mpkg->atom, previnst->atom); |
44 |
+ replver = previnst->atom->PVR; |
45 |
+ |
46 |
+ /* restore atom for later printing/handling */ |
47 |
+ previnst->atom->REPO = orepo; |
48 |
+ previnst->atom->SUBSLOT = osubslot; |
49 |
} |
50 |
|
51 |
(void)qprint_tree_node(level, mpkg, previnst, replacing); |