For bug #157134, make `emerge --digest` automatically reload the config with FEATURES...
authorZac Medico <zmedico@gentoo.org>
Mon, 4 Dec 2006 21:49:17 +0000 (21:49 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 4 Dec 2006 21:49:17 +0000 (21:49 -0000)
svn path=/main/trunk/; revision=5173

bin/emerge

index 0651da960015033995e22843785f5198a30d6e40..1c20cc14e0280b4c1e7b20a66055ce0264411b5b 100755 (executable)
@@ -4456,6 +4456,13 @@ def emerge_main():
        tmpcmdline.extend(sys.argv[1:])
        myaction, myopts, myfiles = parse_opts(tmpcmdline)
 
+       if "--digest" in myopts:
+               os.environ["FEATURES"] = os.environ.get("FEATURES","") + " digest"
+               # Reload the whole config from scratch so that the portdbapi internal
+               # config is updated with new FEATURES.
+               settings, trees, mtimedb = load_emerge_config(trees=trees)
+               portdb = trees[settings["ROOT"]]["porttree"].dbapi
+
        for myroot in trees:
                mysettings =  trees[myroot]["vartree"].settings
                mysettings.unlock()