A "sort -n" command in db.eclass is not functioning properly resulting in symlinks in /usr/lib being messed up. The problem line is: target=`find . -maxdepth 1 -type f -name "${name}-*.${ext}" |sort -n |tail -n 1` "sort -n" should be changed to "sort -V" -- otherwise it will sort completely wrong and not do the right thing. With sort -V, it will properly handle db-18.x and understand that it's newer than db-6.x.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=43e83e8d56f14bde00be2994995c5191a7a5ca88 commit 43e83e8d56f14bde00be2994995c5191a7a5ca88 Author: Lars Wendler <polynomial-c@gentoo.org> AuthorDate: 2019-07-18 07:27:20 +0000 Commit: Lars Wendler <polynomial-c@gentoo.org> CommitDate: 2019-07-18 07:52:00 +0000 db.eclass: Fixed version sort Thanks-to: Daniel Robbins <drobbins@funtoo.org> Closes: https://bugs.gentoo.org/690118 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> eclass/db.eclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)