aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bin/eapi.sh4
-rw-r--r--bin/install-qa-check.d/95empty-dirs4
-rw-r--r--man/make.conf.51
3 files changed, 8 insertions, 1 deletions
diff --git a/bin/eapi.sh b/bin/eapi.sh
index 455bc9b0d..4eafc1c87 100644
--- a/bin/eapi.sh
+++ b/bin/eapi.sh
@@ -247,3 +247,7 @@ ___eapi_bash_4_2() {
___eapi_has_ENV_UNSET() {
[[ ! ${1-${EAPI-0}} =~ ^(0|1|2|3|4|4-python|4-slot-abi|5|5-progress|6)$ ]]
}
+
+___eapi_has_strict_keepdir() {
+ [[ ! ${1-${EAPI-0}} =~ ^(0|1|2|3|4|4-python|5|5-progress|6|7)$ ]]
+}
diff --git a/bin/install-qa-check.d/95empty-dirs b/bin/install-qa-check.d/95empty-dirs
index 8599db395..34a1daf21 100644
--- a/bin/install-qa-check.d/95empty-dirs
+++ b/bin/install-qa-check.d/95empty-dirs
@@ -17,7 +17,9 @@ find_empty_dirs() {
local warn_dirs=()
local d striparg=
- [[ ${FEATURES} == *strict-keepdir* ]] && striparg=-delete
+ if ___eapi_has_strict_keepdir || [[ ${FEATURES} == *strict-keepdir* ]]; then
+ striparg=-delete
+ fi
while IFS= read -r -d $'\0' d; do
[[ ${d} == ${ED%/}/var/* ]] && warn_dirs+=( "${d}" )
diff --git a/man/make.conf.5 b/man/make.conf.5
index 0ad3e2f7d..4c9f00675 100644
--- a/man/make.conf.5
+++ b/man/make.conf.5
@@ -649,6 +649,7 @@ dangerous (like missing or incorrect digests for ebuilds).
.B strict-keepdir
Have portage strictly require keepdir calls in ebuilds. Empty
directories installed without explicit keepdir will be removed.
+This feature is automatically enabled for \fBEAPI 8\fR and later.
.TP
.B stricter
Have portage react strongly to conditions that may conflict with system