Summary: | sys-apps/portage-2.3.20 does not completely preserve old libs [Prefix] | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Steven Trogdon <strogdon> |
Component: | Core | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | esigra, frp.bissey, heroxbd |
Priority: | Normal | Keywords: | InVCS |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
See Also: |
https://bugs.gentoo.org/show_bug.cgi?id=664890 https://bugs.gentoo.org/show_bug.cgi?id=675542 |
||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 240323, 691278 | ||
Attachments: | prefix-preserve-libs.patch |
Description
Steven Trogdon
2018-01-29 23:48:41 UTC
There are further issues with this particular upgrade but the main point is that gcc broke because libmpfr.so.3{,.xx} has been removed when it should have been preserved. My understanding is that by default libraries are preserved in FEATURES so this shouldn't have happened. Possibly a fault of the mpfr-4.0.0-r1 ebuild rather than portage, see bug 642316. Check if the ebuild that you used had this commit: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=02da1bfffe30537bf7fe7680fc628acc9d6ec289 (In reply to Zac Medico from comment #3) > Check if the ebuild that you used had this commit: > > https://gitweb.gentoo.org/repo/gentoo.git/commit/ > ?id=02da1bfffe30537bf7fe7680fc628acc9d6ec289 Yes, the ebuild I used had the commit. (In reply to Zac Medico from comment #3) > Check if the ebuild that you used had this commit: > > https://gitweb.gentoo.org/repo/gentoo.git/commit/ > ?id=02da1bfffe30537bf7fe7680fc628acc9d6ec289 It should, he specified mpfr-4.0.0-r1. And that commit goes from 4.0.0 to 4.0.0-r1. My last comment on #642316 was for a different issue where some code will trigger ICE if you upgrade mpfr then mpc but not gcc immediately after that. OK, 2nd attempt. I unmasked mpfr-4.0.0-r1 and installed it. Old mpfr libs are preserved ls /storage/strogdon/gentoo-rap/usr/lib/libmpfr* /storage/strogdon/gentoo-rap/usr/lib/libmpfr.so /storage/strogdon/gentoo-rap/usr/lib/libmpfr.so.4 /storage/strogdon/gentoo-rap/usr/lib/libmpfr.so.4.1.6 /storage/strogdon/gentoo-rap/usr/lib/libmpfr.so.6 /storage/strogdon/gentoo-rap/usr/lib/libmpfr.so.6.0.0 However, gcc is not in my list of rebuilds emerge -p @preserved-rebuild These are the packages that would be merged, in order: Calculating dependencies... done! [ebuild R ] sci-libs/fplll-5.2.0 I'm now sure if I simply run emerge @preserved-rebuild the old mpfr libs will be deleted and my gcc will be broken. Instead, at this point, I rebuilt gcc and then performed the @preserved-rebuild. This then required a manual emerge of dev-python/fpylll because of 'stale' links to the old mpfr libs. But my gcc seems fine. Created attachment 586400 [details, diff]
prefix-preserve-libs.patch
Hi Zac,
I have been bitten by the same bug, and finally found the root cause is that portage looked into ROOT for consumers of a shared library, which returns nothing on Prefix. Here is a patch that fixes this long standing bug.
Benda
(In reply to Benda Xu from comment #7) > Created attachment 586400 [details, diff] [details, diff] > prefix-preserve-libs.patch Looks good, except it should use self._dbapi.settings['EROOT'], since portage.const.EPREFIX is not necessarily correct for a cross-prefix configuration which has two independent EPREFIX values. (In reply to Zac Medico from comment #8) > (In reply to Benda Xu from comment #7) > > Created attachment 586400 [details, diff] [details, diff] [details, diff] > > prefix-preserve-libs.patch > > Looks good, except it should use self._dbapi.settings['EROOT'], since > portage.const.EPREFIX is not necessarily correct for a cross-prefix > configuration which has two independent EPREFIX values. Agreed. I have overlooked it, sorry. Benda The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage.git/commit/?id=1120e6f62feb1aa0d3202beb00c01537d352f420 commit 1120e6f62feb1aa0d3202beb00c01537d352f420 Author: Benda Xu <heroxbd@gentoo.org> AuthorDate: 2019-08-10 02:26:12 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-08-11 18:07:43 +0000 lib/p/util/_dyn_libs/LinkageMapELF.py: get dep graph from EROOT. On Prefix, the preserve-libs feature should search for shared libraries consumers from EROOT instead of ROOT. Bug: https://bugs.gentoo.org/646090 Signed-off-by: Zac Medico <zmedico@gentoo.org> lib/portage/util/_dyn_libs/LinkageMapELF.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) Thanks, Zac! The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=08557524dc6c8eec3a366e43ab2587d2cdd8f133 commit 08557524dc6c8eec3a366e43ab2587d2cdd8f133 Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2019-08-19 04:24:07 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-08-19 05:06:15 +0000 sys-apps/portage: Bump to version 2.3.72 #463952 glsa-check: install in /usr/bin #646090 preserve-libs: get dep graph from EROOT #690484 detect internal collisions for /usr merge #690786 repoman: support metadata/layout.conf restrict-allowed #691776 unpack: Unconditionally die if an unpacker returns an error #691638 Show get/setfattr stderr #692024 econf: Unconditionally die on error in EAPIs 0 to 3 #692262 QA Notice: EXPORT_FUNCTIONS is called before inherit in kernel-2.eclass #692412 emerge IndexError for ambiguous package atom with pypy Bug: https://bugs.gentoo.org/691278 Bug: https://bugs.gentoo.org/463952 Bug: https://bugs.gentoo.org/646090 Bug: https://bugs.gentoo.org/690484 Bug: https://bugs.gentoo.org/690786 Bug: https://bugs.gentoo.org/691776 Bug: https://bugs.gentoo.org/691638 Bug: https://bugs.gentoo.org/692024 Bug: https://bugs.gentoo.org/692262 Bug: https://bugs.gentoo.org/692412 Package-Manager: Portage-2.3.71, Repoman-2.3.17 Signed-off-by: Zac Medico <zmedico@gentoo.org> sys-apps/portage/Manifest | 1 + sys-apps/portage/portage-2.3.72.ebuild | 264 +++++++++++++++++++++++++++++++++ 2 files changed, 265 insertions(+) |