Skip to contentSkip to conversation

toaster: buildinfohelper Create target list for all types of build

PATCH In review Michael Wood 2 participants 2 messages Mar 15, 2016 – Mar 18, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 toaster: buildinfohelper Create target list for all types of build

Create the target list cache for command line builds and toaster triggered builds. This fixes a regression where the target is not identified as an image after building as the target cache is empty for toaster triggered builds

[YOCTO #9266]

---
 bitbake/lib/bb/ui/buildinfohelper.py | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
bitbake/lib/bb/ui/buildinfohelper.py +8 -7
index 7805086..28c7353 100644
@@ -977,15 +977,16 @@ class BuildInfoHelper(object):
         event: a TargetsAcquired event with a task property (e.g. "build")
         and a targetsList property (e.g. ["zlib", "dropbear"])
         """
-        if self.internal_state['build'].project.is_default:
-            targets = map(lambda target: target + ':' + event.task, event.targetsList)
+        targets = map(lambda target: target + ':' + event.task,
+                      event.targetsList)
 
-            target_information = {
-              'targets': targets,
-              'build': self.internal_state['build']
-            }
+        target_information = {
+            'targets': targets,
+            'build': self.internal_state['build']
+        }
 
-            self.internal_state['targets'] = self.orm_wrapper.get_or_create_targets(target_information)
+        self.internal_state['targets'] = \
+            self.orm_wrapper.get_or_create_targets(target_information)
 
     def update_build(self, event):
         """
Signature · 1 line
2.5.0
#1 lore raw
Quoted 6 lines · On 15/03/2016 18:36, "[email protected] on behalf of Michael…

Create the target list cache for command line builds and toaster triggered builds. This fixes a regression where the target is not identified as an image after building as the target cache is empty for toaster triggered builds

[YOCTO #9266]

This works for me. Image information is back :)

Thanks!

Belén

Quoted 46 lines

---
bitbake/lib/bb/ui/buildinfohelper.py | 15 ++++++++-------

1 file changed, 8 insertions(+), 7 deletions(-)
bitbake/lib/bb/ui/buildinfohelper.py +8 -7
index 7805086..28c7353 100644
@@ -977,15 +977,16 @@ class BuildInfoHelper(object):
        event: a TargetsAcquired event with a task property (e.g.
 "build")
        and a targetsList property (e.g. ["zlib", "dropbear"])
        """
-        if self.internal_state['build'].project.is_default:
-            targets = map(lambda target: target + ':' + event.task,
 event.targetsList)
+        targets = map(lambda target: target + ':' + event.task,
+                      event.targetsList)
 
-            target_information = {
-              'targets': targets,
-              'build': self.internal_state['build']
-            }
+        target_information = {
+            'targets': targets,
+            'build': self.internal_state['build']
+        }
 
-            self.internal_state['targets'] =
 self.orm_wrapper.get_or_create_targets(target_information)
+        self.internal_state['targets'] = \
+            self.orm_wrapper.get_or_create_targets(target_information)

def update_build(self, event):
"""

Signature · 7 lines
2.5.0

-- 
_______________________________________________
toaster mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/toaster