summaryrefslogtreecommitdiffstats
path: root/lib/bb
diff options
context:
space:
mode:
authorTomasz Dziendzielski <tomasz.dziendzielski@gmail.com>2021-01-30 20:47:12 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-01-31 11:30:04 +0000
commit3ce4b2caccfe608a54dff159459f3687ea610597 (patch)
treecc11bfc1015492f956fe808b2a4be9cc48a90213 /lib/bb
parent0efac66043662e7a2027192f50e92e982db2ba1c (diff)
downloadbitbake-3ce4b2caccfe608a54dff159459f3687ea610597.tar.gz
lib/bb: Don't treat mc recipe (Midnight Commander) as a multiconfig target
When we run `devtool build mc` recipe's task dependencies are expanded to "mc:do_populate_sysroot" where "mc" name is treated as multiconfig and "do_package_sysroot" as multiconfigname. | ERROR: Multiconfig dependency mc:do_populate_sysroot depends on | nonexistent multiconfig configuration named do_populate_sysroot Signed-off-by: Tomasz Dziendzielski <tomasz.dziendzielski@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb')
-rw-r--r--lib/bb/cache.py4
-rw-r--r--lib/bb/cooker.py4
-rw-r--r--lib/bb/runqueue.py6
-rw-r--r--lib/bb/siggen.py2
4 files changed, 8 insertions, 8 deletions
diff --git a/lib/bb/cache.py b/lib/bb/cache.py
index 36270d009..c85effd6f 100644
--- a/lib/bb/cache.py
+++ b/lib/bb/cache.py
@@ -238,7 +238,7 @@ def virtualfn2realfn(virtualfn):
Convert a virtual file name to a real one + the associated subclass keyword
"""
mc = ""
- if virtualfn.startswith('mc:'):
+ if virtualfn.startswith('mc:') and virtualfn.count(':') >= 2:
elems = virtualfn.split(':')
mc = elems[1]
virtualfn = ":".join(elems[2:])
@@ -268,7 +268,7 @@ def variant2virtual(realfn, variant):
"""
if variant == "":
return realfn
- if variant.startswith("mc:"):
+ if variant.startswith("mc:") and variant.count(':') >= 2:
elems = variant.split(":")
if elems[2]:
return "mc:" + elems[1] + ":virtual:" + ":".join(elems[2:]) + ":" + realfn
diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index 83cfee7fb..4446addc7 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -614,7 +614,7 @@ class BBCooker:
# Replace string such as "mc:*:bash"
# into "mc:A:bash mc:B:bash bash"
for k in targetlist:
- if k.startswith("mc:"):
+ if k.startswith("mc:") and k.count(':') >= 2:
if wildcard:
bb.fatal('multiconfig conflict')
if k.split(":")[1] == "*":
@@ -648,7 +648,7 @@ class BBCooker:
for k in fulltargetlist:
origk = k
mc = ""
- if k.startswith("mc:"):
+ if k.startswith("mc:") and k.count(':') >= 2:
mc = k.split(":")[1]
k = ":".join(k.split(":")[2:])
ktask = task
diff --git a/lib/bb/runqueue.py b/lib/bb/runqueue.py
index 28bdadb45..7d493eb40 100644
--- a/lib/bb/runqueue.py
+++ b/lib/bb/runqueue.py
@@ -38,7 +38,7 @@ def taskname_from_tid(tid):
return tid.rsplit(":", 1)[1]
def mc_from_tid(tid):
- if tid.startswith('mc:'):
+ if tid.startswith('mc:') and tid.count(':') >= 2:
return tid.split(':')[1]
return ""
@@ -47,13 +47,13 @@ def split_tid(tid):
return (mc, fn, taskname)
def split_mc(n):
- if n.startswith("mc:"):
+ if n.startswith("mc:") and n.count(':') >= 2:
_, mc, n = n.split(":", 2)
return (mc, n)
return ('', n)
def split_tid_mcfn(tid):
- if tid.startswith('mc:'):
+ if tid.startswith('mc:') and tid.count(':') >= 2:
elems = tid.split(':')
mc = elems[1]
fn = ":".join(elems[2:-1])
diff --git a/lib/bb/siggen.py b/lib/bb/siggen.py
index 0ac395246..e0e03318a 100644
--- a/lib/bb/siggen.py
+++ b/lib/bb/siggen.py
@@ -748,7 +748,7 @@ def clean_basepath(basepath):
if basepath[0] == '/':
return cleaned
- if basepath.startswith("mc:"):
+ if basepath.startswith("mc:") and basepath.count(':') >= 2:
mc, mc_name, basepath = basepath.split(":", 2)
mc_suffix = ':mc:' + mc_name
else: