declare -rx EBUILD_PHASE
+if [ "$*" != "depend" ] && [ "$*" != "clean" ] && [ "$*" != "nofetch" ]; then
+ if [ -f "${T}/environment" ]; then
+ source "${T}/environment" >& /dev/null
+ fi
+fi
+
# These two functions wrap sourcing and calling respectively. At present they
# perform a qa check to make sure eclasses and ebuilds and profiles don't mess
# with shell opts (shopts). Ebuilds/eclasses changing shopts should reset them
return 0
}
-if [ "$*" != "depend" ] && [ "$*" != "clean" ] && [ "$*" != "nofetch" ]; then
- if [ -f "${T}/environment" ]; then
- qa_source "${T}/environment" &>/dev/null
- fi
-fi
-
# subshell die support
EBUILD_MASTER_PID=$$
trap 'exit 1' SIGTERM
echo "${EAPI:-0}" > EAPI
set +f
set > environment
- export -p | sed 's:declare -rx:declare -x:' >> environment
+ export | sed 's:^declare -rx:declare -x:' >> environment
bzip2 -f9 environment
cp "${EBUILD}" "${PF}.ebuild"
# Save current environment and touch a success file. (echo for success)
umask 002
set | @EGREP@ -v "^SANDBOX_" > "${T}/environment" 2>/dev/null
- export | @EGREP@ -v "^declare -x SANDBOX_" >> "${T}/environment" 2>/dev/null
+ export | @EGREP@ -v "^declare -x SANDBOX_" | \
+ @SED@ 's:^declare -rx:declare -x:' >> "${T}/environment" 2>/dev/null
chown ${PORTAGE_USER:-portage}:${PORTAGE_GROUP:-portage} "${T}/environment" &>/dev/null
chmod g+w "${T}/environment" &>/dev/null
fi
This variable contains the command used to compress documentation during the
install phase.
.TP
-\fBPORTAGE_COMPRESS_FLAGS\fR = \fI"\-f9"\fR
+\fBPORTAGE_COMPRESS_FLAGS\fR = \fI"\-9"\fR
This variable contains flags for the \fBPORTAGE_COMPRESS\fR command.
.TP
.B PORTAGE_ELOG_CLASSES
if addme:
metadata = dict(izip(self._mydbapi_keys,
mydbapi.aux_get(mykey, self._mydbapi_keys)))
- if merging == 0 and vardbapi.cpv_exists(mykey):
- metadata["USE"] = vardbapi.aux_get(mykey, ["USE"])[0]
- myuse = metadata["USE"].split()
- metadata["SLOT"] = vardbapi.aux_get(mykey, ["SLOT"])[0]
+ if merging == 0 and vardbapi.cpv_exists(mykey) and \
+ mytype != "installed":
+ mybigkey[0] = "installed"
+ mydbapi = vardbapi
+ jbigkey = tuple(mybigkey)
+ metadata = dict(izip(self._mydbapi_keys,
+ mydbapi.aux_get(mykey, self._mydbapi_keys)))
+ myuse = mydbapi.aux_get(mykey, ["USE"])[0].split()
slot_atom = "%s:%s" % (portage.dep_getkey(mykey), metadata["SLOT"])
existing_node = self._slot_node_map[myroot].get(
slot_atom, None)
except ValueError:
pass
+ profile_atoms = self.mysettings.prevmaskdict.get(mycp)
+ if profile_atoms:
+ for x in profile_atoms:
+ #important: only match against the still-unmasked entries...
+ #notice how we pass "newlist" to the xmatch() call below....
+ #Without this, ~ deps in the packages files are broken.
+ mymatches=self.xmatch("match-list",x,mylist=newlist)
+ if mymatches is None:
+ #error in packages file; print warning and continue:
+ print "emerge: visible(): profile packages entry \""+x+"\" is invalid, ignoring..."
+ continue
+ newlist = [cpv for cpv in newlist if cpv in mymatches]
+
return newlist
def gvisible(self,mylist):