]> code.ossystems Code Review - openembedded-core.git/commitdiff
lib/oe/classextend: Ensure we don't extend expressions more than once
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 6 Nov 2012 08:29:00 +0000 (09:29 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 6 Nov 2012 08:29:03 +0000 (09:29 +0100)
We could end up with MLPREFIX being prepended to variables like
PACKAGE_DYNAMIC. This patch avoids the problem and unbreaks builds.

[YOCTO #3389]

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/oe/classextend.py

index c46332c7855a922d56d3f2e26a240a6227d0f6ff..19e1254637202f5f429ba7e02122bc1704e489ba 100644 (file)
@@ -40,7 +40,9 @@ class ClassExtender(object):
         var = var.split()
         newvar = []
         for v in var:
-            if v.startswith("^"):
+            if v.startswith("^" + self.extname):
+                newvar.append(v)
+            elif v.startswith("^"):
                 newvar.append("^" + self.extname + "-" + v[1:])
             else:
                 newvar.append(self.extend_name(v))