* Move filtering of a bunch of portage config variables from
authorZac Medico <zmedico@gentoo.org>
Mon, 26 Nov 2007 02:05:16 +0000 (02:05 -0000)
committerZac Medico <zmedico@gentoo.org>
Mon, 26 Nov 2007 02:05:16 +0000 (02:05 -0000)
save_ebuild_env() to config.environ().
* Add EMERGE_FROM to the READONLY_PORTAGE_VARS list.

svn path=/main/trunk/; revision=8670

bin/ebuild.sh
bin/isolated-functions.sh
pym/portage/__init__.py

index 7276a7ceb4a84ca98ee3803043f13f61eedb46cd..c3209f88644a56c05ce9968e62eba3caa7a542e5 100755 (executable)
@@ -1340,8 +1340,9 @@ READONLY_EBUILD_METADATA="DEPEND DESCRIPTION
        EAPI HOMEPAGE INHERITED IUSE KEYWORDS LICENSE
        PDEPEND PROVIDE RDEPEND RESTRICT SLOT SRC_URI"
 
-READONLY_PORTAGE_VARS="D EBUILD EBUILD_PHASE EBUILD_SH_ARGS FILESDIR \
-       PORTAGE_BIN_PATH PORTAGE_PYM_PATH PORTAGE_TMPDIR T WORKDIR"
+READONLY_PORTAGE_VARS="D EBUILD EBUILD_PHASE \
+       EBUILD_SH_ARGS EMERGE_FROM FILESDIR PORTAGE_BIN_PATH \
+       PORTAGE_PYM_PATH PORTAGE_TMPDIR T WORKDIR"
 
 # @FUNCTION: filter_readonly_variables
 # @DESCRIPTION: [--filter-sandbox]
index d764be5f1c69169cc1143981bee4b8a9f5ff005b..30d57526604d8c43d9a93e91ad8933ce9eb90e22 100755 (executable)
@@ -413,34 +413,23 @@ save_ebuild_env() {
                        source_all_bashrcs ebuild_phase ebuild_phase_with_hooks
 
                # portage config variables and variables set directly by portage
-               unset ACCEPT_KEYWORDS AUTOCLEAN BAD BRACKET BUILD_PREFIX CLEAN_DELAY \
-                       COLLISION_IGNORE COLS CONFIG_PROTECT CONFIG_PROTECT_MASK \
+               unset BAD BRACKET BUILD_PREFIX COLS \
                        DISTCC_DIR DISTDIR DOC_SYMLINKS_DIR EBUILD_MASTER_PID \
-                       ECLASSDIR ECLASS_DEPTH EMERGE_DEFAULT_OPTS \
-                       EMERGE_WARNING_DELAY ENDCOL FAKEROOTKEY FEATURES \
-                       FETCHCOMMAND FETCHCOMMAND_FTP FETCHCOMMAND_HTTP FETCHCOMMAND_SFTP \
-                       GENTOO_MIRRORS GOOD HILITE HOME IMAGE \
+                       ECLASSDIR ECLASS_DEPTH ENDCOL FAKEROOTKEY FEATURES \
+                       GOOD HILITE HOME IMAGE \
                        KV LAST_E_CMD LAST_E_LEN LD_PRELOAD MOPREFIX \
-                       NORMAL PATH PKGDIR PKGUSE PKG_LOGDIR PKG_TMPDIR \
+                       NORMAL PATH PKGDIR PKGUSE PKG_LOGDIR PKG_TMPDIR \
                        PORTAGE_ACTUAL_DISTDIR PORTAGE_ARCHLIST PORTAGE_BASHRC \
-                       PORTAGE_BINHOST_CHUNKSIZE PORTAGE_BINPKG_TMPFILE \
-                       PORTAGE_BUILDDIR PORTAGE_CALLER \
+                       PORTAGE_BINPKG_TMPFILE PORTAGE_BUILDDIR \
                        PORTAGE_COLORMAP PORTAGE_CONFIGROOT PORTAGE_DEBUG \
-                       PORTAGE_DEPCACHEDIR PORTAGE_ELOG_CLASSES PORTAGE_ELOG_MAILFROM \
-                       PORTAGE_ELOG_MAILSUBJECT PORTAGE_ELOG_MAILURI PORTAGE_ELOG_SYSTEM \
-                       PORTAGE_GID PORTAGE_GPG_DIR PORTAGE_GPG_KEY PORTAGE_INST_GID \
+                       PORTAGE_DEPCACHEDIR PORTAGE_GID PORTAGE_INST_GID \
                        PORTAGE_INST_UID PORTAGE_LOG_FILE PORTAGE_MASTER_PID \
-                       PORTAGE_REPO_NAME PORTAGE_RESTRICT \
-                       PORTAGE_RSYNC_EXTRA_OPTS PORTAGE_RSYNC_OPTS \
-                       PORTAGE_RSYNC_RETRIES PORTAGE_TMPFS PORTAGE_WORKDIR_MODE PORTDIR \
-                       PORTDIR_OVERLAY PORT_LOGDIR PROFILE_PATHS PWORKDIR \
-                       QUICKPKG_DEFAULT_OPTS QA_INTERCEPTORS \
+                       PORTAGE_REPO_NAME PORTAGE_RESTRICT PORTAGE_WORKDIR_MODE PORTDIR \
+                       PORTDIR_OVERLAY PROFILE_PATHS PWORKDIR QA_INTERCEPTORS \
                        RC_DEFAULT_INDENT RC_DOT_PATTERN RC_ENDCOL \
                        RC_INDENTATION READONLY_EBUILD_METADATA READONLY_PORTAGE_VARS \
-                       RESUMECOMMAND RESUMECOMMAND_HTTP \
-                       RESUMECOMMAND_HTTP RESUMECOMMAND_SFTP ROOT ROOTPATH RPMDIR \
-                       STARTDIR SYNC TMP TMPDIR USE_EXPAND \
-                       USE_EXPAND_HIDDEN USE_ORDER WARN XARGS _RC_GET_KV_CACHE
+                       ROOT ROOTPATH RPMDIR STARTDIR TMP TMPDIR USE_EXPAND \
+                       WARN XARGS _RC_GET_KV_CACHE
 
                set
                export
index b739a4cfcc85e223586cb616d661a2b587ec89fb..36bd65ee3ebc070a9b1991277353aef2742938e9 100644 (file)
@@ -860,7 +860,19 @@ class config(object):
 
        # Filter selected variables in the config.environ() method so that
        # they don't needlessly propagate down into the ebuild environment.
-       _environ_filter = frozenset(["PORTAGE_ECLASS_WARNING_ENABLE"])
+       _environ_filter = frozenset(["ACCEPT_KEYWORDS", "AUTOCLEAN",
+               "CLEAN_DELAY", "COLLISION_IGNORE", "CONFIG_PROTECT",
+               "CONFIG_PROTECT_MASK", "EMERGE_DEFAULT_OPTS",
+               "EMERGE_WARNING_DELAY", "FETCHCOMMAND", "FETCHCOMMAND_FTP",
+               "FETCHCOMMAND_HTTP", "FETCHCOMMAND_SFTP", "GENTOO_MIRRORS", "O",
+               "PORTAGE_BINHOST_CHUNKSIZE", "PORTAGE_CALLER",
+               "PORTAGE_ECLASS_WARNING_ENABLE", "PORTAGE_ELOG_CLASSES",
+               "PORTAGE_ELOG_MAILFROM", "PORTAGE_ELOG_MAILSUBJECT",
+               "PORTAGE_ELOG_MAILURI", "PORTAGE_ELOG_SYSTEM", "PORTAGE_GPG_DIR",
+               "PORTAGE_GPG_KEY", "PORTAGE_RSYNC_EXTRA_OPTS", "PORTAGE_RSYNC_OPTS",
+               "PORTAGE_RSYNC_RETRIES", "PORT_LOGDIR", "QUICKPKG_DEFAULT_OPTS",
+               "RESUMECOMMAND", "RESUMECOMMAND_HTTP", "RESUMECOMMAND_HTTP",
+               "RESUMECOMMAND_SFTP", "SYNC", "USE_EXPAND_HIDDEN", "USE_ORDER"])
 
        def __init__(self, clone=None, mycpv=None, config_profile_path=None,
                config_incrementals=None, config_root=None, target_root=None,