From 9d039f482c84dde264564fde93f39764113cc0d3 Mon Sep 17 00:00:00 2001 From: Robert Yang Date: Thu, 7 Mar 2013 11:26:13 +0800 Subject: rootfs_xxx.bbclass: fix bitbake -S hashes mismatch error The bitbake -S has errors, e.g.: NOTE: Reparsing files to collect dependency data ERROR: Bitbake's cached basehash does not match the one we just generated (/buildarea/lyang1/poky/meta/recipes-core/images/core-image-minimal.bb.do_rootfs)! ERROR: The mismatched hashes were 8e44f2296f2d6cdf2ccb0236910ef59b and 46357d5e36713646b47b0fe2233e3c8c This is caused by the BUILDNAME which is defined in cooker.py: if not self.configuration.data.getVar("BUILDNAME"): self.configuration.data.setVar("BUILDNAME", time.strftime('%Y%m%d%H%M')) The time changes during the first parsing and reparsing, so there is the error, we already have: do_rootfs[vardepsexclude] += "BUILDNAME" but what we need is rootfs_xxx_do_rootfs[vardepsexclude] += "BUILDNAME" The do_rootfs doesn't depend on BUILDNAME directly, but indirectly, the depends tree is: do_rootfs -> rootfs_xxx_do_rootfs -> BUILDNAME So add BUILDNAME to rootfs_xxx_do_rootfs[vardepsexclude] would fix the problem. [YOCTO #3299] Signed-off-by: Robert Yang Signed-off-by: Saul Wold --- meta/classes/rootfs_ipk.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'meta/classes/rootfs_ipk.bbclass') diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass index a609944e73..e38ba8689f 100644 --- a/meta/classes/rootfs_ipk.bbclass +++ b/meta/classes/rootfs_ipk.bbclass @@ -11,7 +11,7 @@ ROOTFS_PKGMANAGE_BOOTSTRAP = "run-postinsts" do_rootfs[depends] += "opkg-native:do_populate_sysroot opkg-utils-native:do_populate_sysroot" do_rootfs[recrdeptask] += "do_package_write_ipk" -do_rootfs[vardepsexclude] += "BUILDNAME" +rootfs_ipk_do_rootfs[vardepsexclude] += "BUILDNAME" do_rootfs[lockfiles] += "${WORKDIR}/ipk.lock" -- cgit 1.2.3-korg