diff options
author | Michał Górny <mgorny@gentoo.org> | 2022-02-21 19:27:02 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2022-02-25 16:53:05 +0100 |
commit | b5378fefeaf6c8414987b7830eb87d70b98074ad (patch) | |
tree | c4a41023c54182ef3ae8f22917b17763c1d895bb /eclass | |
parent | sys-auth/seatd: drop 0.5.0, 0.5.0-r1, 0.6.2-r1 (diff) | |
download | gentoo-b5378fefeaf6c8414987b7830eb87d70b98074ad.tar.gz gentoo-b5378fefeaf6c8414987b7830eb87d70b98074ad.tar.bz2 gentoo-b5378fefeaf6c8414987b7830eb87d70b98074ad.zip |
python-any-r1.eclass: Fix unsupported/invalid EPYTHON logic
Fix the unsupported/invalid EPYTHON logic to make more sense.
As a result of prior refactoring, the eclass would report all invalid
EPYTHON values as unsupported and the invalid branch would never
be reached -- except for the special case of python2_7 where it would
incorrectly reject it. Fix it, so that unsupported EPYTHON values
are reported either as "just unsupported" or incorrect values correctly.
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/python-any-r1.eclass | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/eclass/python-any-r1.eclass b/eclass/python-any-r1.eclass index 4e954f57cd2d..805981bb7aa8 100644 --- a/eclass/python-any-r1.eclass +++ b/eclass/python-any-r1.eclass @@ -302,9 +302,11 @@ python_setup() { local epython_impl=${EPYTHON/./_} if [[ ${epython_impl} ]]; then if ! has "${epython_impl}" "${_PYTHON_SUPPORTED_IMPLS[@]}"; then - einfo "EPYTHON (${EPYTHON}) not supported by the package" - elif ! has "${epython_impl}" "${_PYTHON_ALL_IMPLS[@]}"; then - ewarn "Invalid EPYTHON: ${EPYTHON}" + if ! has "${epython_impl}" "${_PYTHON_ALL_IMPLS[@]}"; then + ewarn "Invalid EPYTHON: ${EPYTHON}" + else + einfo "EPYTHON (${EPYTHON}) not supported by the package" + fi elif _python_run_check_deps "${epython_impl}"; then _python_export EPYTHON PYTHON _python_wrapper_setup |