print "Forcing test."
tmpsettings["EBUILD_FORCE_TEST"] = "1"
tmpsettings.backupenv["EBUILD_FORCE_TEST"] = "1"
+ tmpsettings.features.append("test")
+ tmpsettings["FEATURES"] = " ".join(tmpsettings.features)
+ tmpsettings.backup_changes("FEATURES")
if arg == "digest" and force:
discard_digests(ebuild, tmpsettings, portage.portdb)
a = portage.doebuild(ebuild, arg, portage.root, tmpsettings,
}
dyn_test() {
- [ "${EBUILD_FORCE_TEST}" == "1" ] && rm -f "${PORTAGE_BUILDDIR}/.tested"
+ if [ "${EBUILD_FORCE_TEST}" == "1" ] ; then
+ rm -f "${PORTAGE_BUILDDIR}/.tested"
+ # If USE came from ${T}/environment then it might not have USE=test
+ # like it's supposed to here.
+ ! hasq test ${USE} && export USE="${USE} test"
+ fi
[ "$(type -t pre_src_test)" == "function" ] && qa_call pre_src_test
if [ "${PORTAGE_BUILDDIR}/.tested" -nt "${WORKDIR}" ]; then
vecho ">>> It appears that ${PN} has already been tested; skipping."
Do not delete the ${T} directory after the merge process.
.TP
.B keepwork
-Do not delete the ${WORKDIR} directory after the merge process.
+Do not delete the ${WORKDIR} directory after the merge process. This also
+disables most of the clean phase that is run prior to each build. This causes it
+to interfere with normal emerge operation and therefore it should not be left
+enabled for more than a short period of time.
.TP
.B metadata\-transfer
Automatically perform a metadata transfer when `emerge \-\-sync` is run.
# FEATURES=test should imply USE=test
if "test" in self.configlist[-1].get("FEATURES","").split():
myflags.add("test")
+ if self.get("EBUILD_FORCE_TEST") == "1":
+ self.usemask.discard("test")
usesplit = [ x for x in myflags if \
x not in self.usemask]