toaster: resolve missing 'native[sdk]:' prefixes

Submitted by Reyna, David on March 2, 2017, 12:12 a.m. | Patch ID: 137727

Details

Message ID 5E53D14CE4667A45B9A06760DE5D13D0C344809F@ALA-MBC.corp.ad.wrs.com
State Superseded
Headers show

Commit Message

Reyna, David March 2, 2017, 12:12 a.m.
From b50e74277d8d4556388e34e3e9ed30837e401ae4 Mon Sep 17 00:00:00 2001
From: David Reyna <David.Reyna@windriver.com>
Date: Wed, 1 Mar 2017 15:56:55 -0800
Subject: [PATCH] toaster: resolve missing 'native[sdk]:' prefixes

Some task events are missing the 'virtual:native[sdk]:' prefixes.
The Toaster has code to help match missing prefixes, but needs
additional help resolving between 'native:' and 'nativesdk:', by
way of the '_package' event field.

[YOCTO #10849]

Signed-off-by: David Reyna <David.Reyna@windriver.com>
---
 bitbake/lib/bb/ui/buildinfohelper.py | 8 ++++++++
 1 file changed, 8 insertions(+)

Patch hide | download patch | download mbox

diff --git a/bitbake/lib/bb/ui/buildinfohelper.py b/bitbake/lib/bb/ui/buildinfohelper.py
index 5ed150d..92d1a1c 100644
--- a/bitbake/lib/bb/ui/buildinfohelper.py
+++ b/bitbake/lib/bb/ui/buildinfohelper.py
@@ -1258,6 +1258,14 @@  class BuildInfoHelper(object):
                 candidates = [x for x in self.internal_state['taskdata'].keys() if x.endswith(identifier)]
                 if len(candidates) == 1:
                     identifier = candidates[0]
+                elif len(candidates) > 1 and hasattr(event,'_package'):
+                    if 'native-' in event._package:
+                        identifier = 'native:' + identifier
+                    if 'nativesdk-' in event._package:
+                        identifier = 'nativesdk:' + identifier
+                    candidates = [x for x in self.internal_state['taskdata'].keys() if x.endswith(identifier)]
+                    if len(candidates) == 1:
+                        identifier = candidates[0]
 
         assert identifier in self.internal_state['taskdata']
         identifierlist = identifier.split(":")

Comments

Reyna, David March 2, 2017, 11:34 a.m.
This is a system generated Comment: Patch 137727 was automatically marked as superseded by patch 137728.