From 8cae183a22ee059afcd27dc215848aeb9bda12d2 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Thu, 27 Jan 2011 20:58:38 +0000 Subject: staging.bbclass: Only clean out the sysroot if we rerun configure, not at setscene time Signed-off-by: Richard Purdie --- meta/classes/sstate.bbclass | 1 - meta/classes/staging.bbclass | 7 ++++++- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'meta') diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass index d7d30c012..4435abc34 100644 --- a/meta/classes/sstate.bbclass +++ b/meta/classes/sstate.bbclass @@ -238,7 +238,6 @@ def sstate_clean(ss, d): oe.path.remove(d.getVar("STAMP", True) + ".do_" + ss['task'] + "*") -SCENEFUNCS += "sstate_cleanall" CLEANFUNCS += "sstate_cleanall" python sstate_cleanall() { diff --git a/meta/classes/staging.bbclass b/meta/classes/staging.bbclass index 718b2f1f2..a713734c3 100644 --- a/meta/classes/staging.bbclass +++ b/meta/classes/staging.bbclass @@ -65,6 +65,12 @@ SYSROOT_PREPROCESS_FUNCS ?= "" SYSROOT_DESTDIR = "${WORKDIR}/sysroot-destdir/" SYSROOT_LOCK = "${STAGING_DIR}/staging.lock" +# We clean out any existing sstate from the sysroot if we rerun configure +python sysroot_cleansstate () { + ss = sstate_state_fromvars(d, "populate_sysroot") + sstate_clean(ss, d) +} +do_configure[prefuncs] += "sysroot_cleansstate" python do_populate_sysroot () { # @@ -92,7 +98,6 @@ python do_populate_sysroot_setscene () { } addtask do_populate_sysroot_setscene - python () { if bb.data.getVar('do_stage', d, True) is not None: bb.fatal("Legacy staging found for %s as it has a do_stage function. This will need conversion to a do_install or often simply removal to work with Poky" % bb.data.getVar("FILE", d, True)) -- cgit v1.2.3