[oe-commits] [openembedded-core] 03/17: distutils: clean the build tree in do_configure

git at git.openembedded.org git at git.openembedded.org
Fri Jul 6 21:55:32 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master
in repository openembedded-core.

commit b805cefb24566772a2beb5d02036266e45370913
Author: Ross Burton <ross.burton at intel.com>
AuthorDate: Thu Jul 5 13:29:29 2018 +0100

    distutils: clean the build tree in do_configure
    
    base_do_configure() tries to do "make clean" if there is a Makefile present.
    For most recipes using distutils there is not a Makefile, but we do know that
    "setup.py clean" will work so call that instead.
    
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/classes/distutils3.bbclass | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/meta/classes/distutils3.bbclass b/meta/classes/distutils3.bbclass
index 6c30306..99ad64d 100644
--- a/meta/classes/distutils3.bbclass
+++ b/meta/classes/distutils3.bbclass
@@ -8,6 +8,12 @@ DISTUTILS_STAGE_ALL_ARGS ?= "--prefix=${STAGING_DIR_HOST}${prefix} \
 DISTUTILS_INSTALL_ARGS ?= "--prefix=${D}/${prefix} \
     --install-data=${D}/${datadir}"
 
+distutils3_do_configure() {
+	if [ "${CLEANBROKEN}" != "1" ] ; then
+		${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py clean
+	fi
+}
+
 distutils3_do_compile() {
         STAGING_INCDIR=${STAGING_INCDIR} \
         STAGING_LIBDIR=${STAGING_LIBDIR} \
@@ -71,6 +77,6 @@ distutils3_do_install() {
 }
 distutils3_do_install[vardepsexclude] = "MACHINE"
 
-EXPORT_FUNCTIONS do_compile do_install
+EXPORT_FUNCTIONS do_configure do_compile do_install
 
 export LDSHARED="${CCLD} -shared"

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list