[gnome-continuous-yocto/gnomeostree-3.28-rocko: 8163/8267] image.bbclass: Fix 'vardepsexclude' mechanism for image_cmd_${FSTYPE}



commit e6fe54ce386e0edb72cbcbdcc4b5cddb151535f2
Author: Igor Romanov <i romanov inango-systems com>
Date:   Thu Sep 28 21:08:31 2017 +0300

    image.bbclass: Fix 'vardepsexclude' mechanism for image_cmd_${FSTYPE}
    
    Current mechanism doesn't allow to use any non-determenistic variable, except 'DATE' and 'DATETIME', 
inside IMAGE_CMD_${FSTYPE} prototype.
    
    Passing 'vardepsexclude' values from IMAGE_CMD_${FSTYPE}, so users will be able to avoid taskhash 
mismatch problems.
    
    (From OE-Core rev: 92bd01eba742e2bcb146ca24a1443af833f5a2ba)
    
    Signed-off-by: Igor Romanov <i romanov inango-systems com>
    Signed-off-by: Ross Burton <ross burton intel com>
    Signed-off-by: Armin Kuster <akuster mvista com>
    Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>

 meta/classes/image.bbclass |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 0d14250..20240ba 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -440,6 +440,9 @@ python () {
         localdata.delVar('DATETIME')
         localdata.delVar('DATE')
         localdata.delVar('TMPDIR')
+        vardepsexclude = (d.getVarFlag('IMAGE_CMD_' + realt, 'vardepsexclude', True) or '').split()
+        for dep in vardepsexclude:
+            localdata.delVar(dep)
 
         image_cmd = localdata.getVar("IMAGE_CMD")
         vardeps.add('IMAGE_CMD_' + realt)
@@ -503,7 +506,7 @@ python () {
         d.prependVarFlag(task, 'postfuncs', ' create_symlinks')
         d.appendVarFlag(task, 'subimages', ' ' + ' '.join(subimages))
         d.appendVarFlag(task, 'vardeps', ' ' + ' '.join(vardeps))
-        d.appendVarFlag(task, 'vardepsexclude', 'DATETIME DATE')
+        d.appendVarFlag(task, 'vardepsexclude', 'DATETIME DATE ' + ' '.join(vardepsexclude))
 
         bb.debug(2, "Adding task %s before %s, after %s" % (task, 'do_image_complete', after))
         bb.build.addtask(task, 'do_image_complete', after, d)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]