diff options
author | Michał Górny <mgorny@gentoo.org> | 2019-12-01 17:12:55 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2019-12-01 21:19:34 +0100 |
commit | f9b70d39ab2c06e476f3e8dc09d1d8f16e74e099 (patch) | |
tree | ecbdfb341770c2a5289c872ecca41c03c8acd563 /eclass/distutils-r1.eclass | |
parent | xfce-base/exo: Bump to 0.12.10 (diff) | |
download | gentoo-f9b70d39ab2c06e476f3e8dc09d1d8f16e74e099.tar.gz gentoo-f9b70d39ab2c06e476f3e8dc09d1d8f16e74e099.tar.bz2 gentoo-f9b70d39ab2c06e476f3e8dc09d1d8f16e74e099.zip |
distutils-r1.eclass: Handle missing BUILD_DIR for any-r1 API
When any-r1 API is used for *_all sub-phases, an implementation that
was not selected by the user may be used. In this case,
DISTUTILS_IN_SOURCE_BUILD will not create the BUILD_DIR for this
implementation; however, the phase runner will still try to enter it
and fail. Handle this gracefully by falling back to ${S}.
Closes: https://bugs.gentoo.org/701506
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass/distutils-r1.eclass')
-rw-r--r-- | eclass/distutils-r1.eclass | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index f44f0aee9c21..0c5d6781f83d 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -821,7 +821,11 @@ distutils-r1_run_phase() { debug-print-function ${FUNCNAME} "${@}" if [[ ${DISTUTILS_IN_SOURCE_BUILD} ]]; then - if [[ ! ${DISTUTILS_SINGLE_IMPL} ]]; then + # only force BUILD_DIR if implementation is explicitly enabled + # for building; any-r1 API may select one that is not + # https://bugs.gentoo.org/701506 + if [[ ! ${DISTUTILS_SINGLE_IMPL} ]] && + has "${EPYTHON/./_}" ${PYTHON_TARGETS}; then cd "${BUILD_DIR}" || die fi local BUILD_DIR=${BUILD_DIR}/build |