All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] data_smart: Fix multiple override interaction with append and prepend operators
@ 2012-07-04 15:50 Richard Purdie
  0 siblings, 0 replies; only message in thread
From: Richard Purdie @ 2012-07-04 15:50 UTC (permalink / raw)
  To: bitbake-devel

Variables which used multiple overrides and the append/prepend operators were
not functioning correctly. This change fixes that.

This fixes the testcase:

OVERRIDES = "linux:x86"
TESTVAR = "original"
TESTVAR_append_x86 = " x86"
TESTVAR_append_x86_linux = " x86+linux"
TESTVAR_append_linux_x86 = " linux+x86"

[YOCTO #2672]

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py
index 2c02cde..730deaa 100644
--- a/bitbake/lib/bb/data_smart.py
+++ b/bitbake/lib/bb/data_smart.py
@@ -198,7 +198,12 @@ class DataSmart(MutableMapping):
                 for append in appends:
                     keep = []
                     for (a, o) in self.getVarFlag(append, op) or []:
-                        if o and not o in overrides:
+                        match = True
+                        if o:
+                            for o2 in o.split("_"):
+                                if not o2 in overrides:
+                                    match = False
+                        if not match:
                             keep.append((a ,o))
                             continue
 





^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-07-04 16:01 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-04 15:50 [PATCH] data_smart: Fix multiple override interaction with append and prepend operators Richard Purdie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.