From: Matt Turner Date: Sun, 29 Mar 2020 07:03:02 +0000 (-0700) Subject: scripts/bootstrap.sh: Emerge the actual libc X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=b73bd14850491738363f3c8e60519b22d6ece063;p=gentoo.git scripts/bootstrap.sh: Emerge the actual libc The python program creates a set of bash variable assignments like myGCC="sys-devel/gcc"; which are used to make a list of packages to be rebuilt during catalyst's stage 2. The toolchain, including libc, is supposed to be rebuilt in this stage, but 'portage.settings.packages' contains 'virtual/libc' and not a provider, so it generates: myLIBC="virtual/libc"; This results in catalyst not rebuilding the libc itself but instead reemerging virtual/libc. Commit b9e8ca9b4aa1 (Make sure we rebuild actual libc and not the virtual package.) tried to fix this, but obviously missed the mark as any testing would have shown. The solution is to have the python program expand the virtual itself. Fixes: b9e8ca9b4aa1 (Make sure we rebuild actual libc and not the virtual package.) Closes: https://bugs.gentoo.org/511694 Signed-off-by: Matt Turner --- diff --git a/scripts/bootstrap.sh b/scripts/bootstrap.sh index 03ba014b6372..bfe81ac51ddf 100755 --- a/scripts/bootstrap.sh +++ b/scripts/bootstrap.sh @@ -259,11 +259,14 @@ done eval $(pycmd ' import portage +from portage.dbapi._expand_new_virt import expand_new_virt import sys +root = portage.settings["EROOT"] for atom in portage.settings.packages: if not isinstance(atom, portage.dep.Atom): atom = portage.dep.Atom(atom.lstrip("*")) varname = "my" + portage.catsplit(atom.cp)[1].upper().replace("-", "_") + atom = list(expand_new_virt(portage.db[root]["vartree"].dbapi, atom))[0] sys.stdout.write("%s=\"%s\"; " % (varname, atom)) ')