[OE-core] [PATCH] image.bbclass: Fix 'vardepsexclude' mechanism for image_cmd_${FSTYPE}
Igor Romanov
i.romanov at inango-systems.com
Thu Sep 28 18:08:31 UTC 2017
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.
Signed-off-by: Igor Romanov <i.romanov at inango-systems.com>
---
meta/classes/image.bbclass | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 0d14250c0d..20240ba9f0 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)
--
2.14.2
More information about the Openembedded-core
mailing list