From: Ross Burton Date: Tue, 29 Jul 2025 08:59:35 +0000 (+0100) Subject: python_setuptools_build_meta: clean the build directory in configure X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=383862cfe4c5acf04124080827c8bc6d00b2e86d;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git python_setuptools_build_meta: clean the build directory in configure It's not currently possible to set the build tree to be somewhere we control, but we know it will always be in the build directory alongside the pyproject.toml so we can [cleandirs] that. Signed-off-by: Ross Burton Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie --- diff --git a/meta/classes-recipe/python_setuptools_build_meta.bbclass b/meta/classes-recipe/python_setuptools_build_meta.bbclass index 4c84d1e8d0..046b4ffb74 100644 --- a/meta/classes-recipe/python_setuptools_build_meta.bbclass +++ b/meta/classes-recipe/python_setuptools_build_meta.bbclass @@ -7,3 +7,7 @@ inherit setuptools3-base python_pep517 DEPENDS += "python3-setuptools-native python3-wheel-native" + +# This isn't nice, but is the best solutions to ensure clean builds for now. +# https://github.com/pypa/setuptools/issues/4732 +do_configure[cleandirs] = "${PEP517_SOURCE_PATH}/build"