[05/16] image.bbclass: Ensure ${S} is cleaned at the start of rootfs generation

Submitted by Scott Garman on June 12, 2012, 8:36 p.m.


Message ID 23b7d7dab475caca4558e3b20db534122bee1525.1339533128.git.scott.a.garman@intel.com
State New
Headers show

Commit Message

Scott Garman June 12, 2012, 8:36 p.m.
From: Richard Purdie <richard.purdie@linuxfoundation.org>

Some image classes such as bootimg save files into ${S} as part of rootfs
generation. For correctness we should therefore clean this at the start of
image generation to ensure reproducibility.

I found this issue when some files I thought should disappear from my rootfs
would not disappear.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
 meta/classes/image.bbclass |    1 +
 1 file changed, 1 insertion(+)

Patch hide | download patch | download mbox

diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 907c59b..9557433 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -131,6 +131,7 @@  PSEUDO_PASSWD = "${IMAGE_ROOTFS}"
 do_rootfs[nostamp] = "1"
 do_rootfs[dirs] = "${TOPDIR}"
 do_rootfs[lockfiles] += "${IMAGE_ROOTFS}.lock"
+do_rootfs[cleandirs] += "${S}"
 do_build[nostamp] = "1"
 # Must call real_do_rootfs() from inside here, rather than as a separate