summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2021-02-06 12:52:49 +0100
committerMichał Górny <mgorny@gentoo.org>2021-02-11 21:31:14 +0100
commitafda6ba12b1e96a5a2f487ec26b67802e39c7152 (patch)
tree6a0481a71073caafa93d6b4932d168adaabcb1ea /eclass
parentdev-python/tikzplotlib: Use distutils-r1 pyproject.toml support (diff)
downloadgentoo-afda6ba12b1e96a5a2f487ec26b67802e39c7152.tar.gz
gentoo-afda6ba12b1e96a5a2f487ec26b67802e39c7152.tar.bz2
gentoo-afda6ba12b1e96a5a2f487ec26b67802e39c7152.zip
distutils-r1.eclass: Require EPYTHON to be set
There is no context in which the function is called without EPYTHON set, so require it to be set instead of adding a fallback. Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r--eclass/distutils-r1.eclass4
1 files changed, 3 insertions, 1 deletions
diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
index cb64938c8c32..780becc3ace9 100644
--- a/eclass/distutils-r1.eclass
+++ b/eclass/distutils-r1.eclass
@@ -518,6 +518,8 @@ distutils_enable_tests() {
esetup.py() {
debug-print-function ${FUNCNAME} "${@}"
+ [[ -n ${EPYTHON} ]] || die "EPYTHON unset, invalid call context"
+
local die_args=()
[[ ${EAPI} != [45] ]] && die_args+=( -n )
@@ -529,7 +531,7 @@ esetup.py() {
setup_py=( -m pyproject2setuppy.main )
fi
- set -- "${EPYTHON:-python}" "${setup_py[@]}" "${mydistutilsargs[@]}" "${@}"
+ set -- "${EPYTHON}" "${setup_py[@]}" "${mydistutilsargs[@]}" "${@}"
echo "${@}" >&2
"${@}" || die "${die_args[@]}"