]> code.ossystems Code Review - openembedded-core.git/commitdiff
rm_work: Fix RM_WORK_EXCLUDE for image/sdk recipes
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 7 Jan 2015 23:45:08 +0000 (23:45 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 8 Jan 2015 09:22:37 +0000 (09:22 +0000)
A previous change meant image/sdk recipes were removed unconditionally
by the class and did not respect RM_WORK_EXCLUDE. This fixes that
problem.

[YOCTO #7114]

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/rm_work.bbclass

index 7979a53a3870655fb1348efbea3aa56e7e12989d..e68d02a7839283eca83ab96d740bece2601d44c8 100644 (file)
@@ -109,3 +109,12 @@ rm_work_rootfs () {
     :
 }
 rm_work_rootfs[cleandirs] = "${WORKDIR}/rootfs"
+
+python () {
+    # If the recipe name is in the RM_WORK_EXCLUDE, skip the recipe.
+    excludes = (d.getVar("RM_WORK_EXCLUDE", True) or "").split()
+    pn = d.getVar("PN", True)
+    if pn in excludes:
+        d.delVarFlag('rm_work_rootfs', 'cleandirs')
+        d.delVarFlag('rm_work_populatesdk', 'cleandirs')
+}