From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6FE38138359 for ; Tue, 8 Sep 2020 00:47:54 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9282DE086B; Tue, 8 Sep 2020 00:47:53 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 56DE2E086B for ; Tue, 8 Sep 2020 00:47:53 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BFE0A340E00 for ; Tue, 8 Sep 2020 00:47:51 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 31EDD320 for ; Tue, 8 Sep 2020 00:47:50 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1599526034.16262dc8ab9ab6cc03565bcefc444726b4dfb32f.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: man/, lib/portage/package/ebuild/ X-VCS-Repository: proj/portage X-VCS-Files: lib/portage/package/ebuild/config.py man/make.conf.5 X-VCS-Directories: man/ lib/portage/package/ebuild/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 16262dc8ab9ab6cc03565bcefc444726b4dfb32f X-VCS-Branch: master Date: Tue, 8 Sep 2020 00:47:50 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 1be3a0f9-d62f-4caf-8cfe-c1536e099406 X-Archives-Hash: 5f1951faa182707c7b8944d9570dcf73 commit: 16262dc8ab9ab6cc03565bcefc444726b4dfb32f Author: Arfrever Frehtes Taifersar Arahesis Apache Org> AuthorDate: Sat Sep 5 22:37:05 2020 +0000 Commit: Zac Medico gentoo org> CommitDate: Tue Sep 8 00:47:14 2020 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=16262dc8 make.conf: Treat __* variables as local and do not propagate them. Bug: https://bugs.gentoo.org/740588 Signed-off-by: Arfrever Frehtes Taifersar Arahesis Apache.Org> Signed-off-by: Zac Medico gentoo.org> lib/portage/package/ebuild/config.py | 6 ++++++ man/make.conf.5 | 4 +++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/portage/package/ebuild/config.py b/lib/portage/package/ebuild/config.py index b62ad3069..a09fdbced 100644 --- a/lib/portage/package/ebuild/config.py +++ b/lib/portage/package/ebuild/config.py @@ -370,6 +370,9 @@ class config: _("Found 2 make.conf files, using both '%s' and '%s'") % tuple(make_conf_paths), noiselevel=-1) + # __* variables set in make.conf are local and are not be propagated. + make_conf = {k: v for k, v in make_conf.items() if not k.startswith("__")} + # Allow ROOT setting to come from make.conf if it's not overridden # by the constructor argument (from the calling environment). locations_manager.set_root_override(make_conf.get("ROOT")) @@ -621,6 +624,9 @@ class config: tolerant=tolerant, allow_sourcing=True, expand=expand_map, recursive=True) or {}) + # __* variables set in make.conf are local and are not be propagated. + mygcfg = {k: v for k, v in mygcfg.items() if not k.startswith("__")} + # Don't allow the user to override certain variables in make.conf profile_only_variables = self.configdict["defaults"].get( "PROFILE_ONLY_VARIABLES", "").split() diff --git a/man/make.conf.5 b/man/make.conf.5 index 1b997ad37..8a1ea0603 100644 --- a/man/make.conf.5 +++ b/man/make.conf.5 @@ -1,4 +1,4 @@ -.TH "MAKE.CONF" "5" "Jun 2020" "Portage VERSION" "Portage" +.TH "MAKE.CONF" "5" "Sep 2020" "Portage VERSION" "Portage" .SH "NAME" make.conf \- custom settings for Portage .SH "SYNOPSIS" @@ -36,6 +36,8 @@ make.defaults to make.globals to make.conf to the environment settings. Clearing these variables requires a clear\-all as in: export USE="\-*" .br +__* variables set in make.conf are local and are not be propagated. +.br In order to create per\-package environment settings, refer to \fBpackage.env\fR in \fBportage\fR(5). .SH "VARIABLES"