[bitbake-devel] [PATCH 01/22] toaster: make a workaround for old style index
brian avery
avery.brian at gmail.com
Tue Sep 29 04:45:11 UTC 2015
From: Ed Bartosh <ed.bartosh at linux.intel.com>
For a new style indexes 'inherits' field is used to determine if
recipe is an image recipe.
As old style indexes don't have 'inherits' field this can be
guessed from recipe name. Let's consider recipe an image recipe
if recipe name contains '-image-'.
Signed-off-by: Ed Bartosh <ed.bartosh at linux.intel.com>
Signed-off-by: brian avery <avery.brian at gmail.com>
---
lib/toaster/orm/models.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lib/toaster/orm/models.py b/lib/toaster/orm/models.py
index 883ecf4..b5c8643 100644
--- a/lib/toaster/orm/models.py
+++ b/lib/toaster/orm/models.py
@@ -974,6 +974,8 @@ class LayerIndexLayerSource(LayerSource):
ro.file_path = ri['filepath'] + "/" + ri['filename']
if 'inherits' in ri:
ro.is_image = 'image' in ri['inherits'].split()
+ else: # workaround for old style layer index
+ ro.is_image = "-image-" in ri['pn']
ro.save()
except IntegrityError as e:
logger.debug("Failed saving recipe, ignoring: %s (%s:%s)" % (e, ro.layer_version, ri['filepath']+"/"+ri['filename']))
--
1.9.1
More information about the bitbake-devel
mailing list