From ad5b2e474a3fb84a34f394c6305dd823e15cad7c Mon Sep 17 00:00:00 2001 From: Michał Górny Date: Sun, 30 Jan 2022 11:17:38 +0100 Subject: distutils-r1.eclass: Disable stale egg-info cleaning in PEP517 mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- eclass/distutils-r1.eclass | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'eclass/distutils-r1.eclass') diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index 8d03d2d1771d..4ec252958408 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -1428,6 +1428,10 @@ distutils-r1_src_compile() { # Those files ended up being unversioned, and caused issues: # https://bugs.gentoo.org/534058 _distutils-r1_clean_egg_info() { + if [[ ${DISTUTILS_USE_PEP517} ]]; then + die "${FUNCNAME} is not implemented in PEP517 mode" + fi + rm -rf "${BUILD_DIR}"/lib/*.egg-info || die } @@ -1436,7 +1440,9 @@ distutils-r1_src_test() { if declare -f python_test >/dev/null; then _distutils-r1_run_foreach_impl python_test - _distutils-r1_run_foreach_impl _distutils-r1_clean_egg_info + if [[ ! ${DISTUTILS_USE_PEP517} ]]; then + _distutils-r1_run_foreach_impl _distutils-r1_clean_egg_info + fi fi if declare -f python_test_all >/dev/null; then -- cgit v1.2.3-65-gdbad