summaryrefslogtreecommitdiffstats
path: root/bitbake
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-02-06 09:12:00 +0000
commit1d2fe91db54e171fe66a697596a8f268d6ca8bbe (patch)
treedbbd6c352219e884a7aa6d32bcc9c560be8702d1 /bitbake
parent2fcbd0f11547d21bd18dbbc555a95a531beb5e63 (diff)
downloadpoky-1d2fe91db54e171fe66a697596a8f268d6ca8bbe.tar.gz
bitbake: 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 (Bitbake rev: 3ce4b2caccfe608a54dff159459f3687ea610597) Signed-off-by: Tomasz Dziendzielski <tomasz.dziendzielski@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/cache.py4
-rw-r--r--bitbake/lib/bb/cooker.py4
-rw-r--r--bitbake/lib/bb/runqueue.py6
-rw-r--r--bitbake/lib/bb/siggen.py2
4 files changed, 8 insertions, 8 deletions
diff --git a/bitbake/lib/bb/cache.py b/bitbake/lib/bb/cache.py
index 36270d0093..c85effd6f0 100644
--- a/bitbake/lib/bb/cache.py
+++ b/bitbake/lib/bb/cache.py
@@ -238,7 +238,7 @@ def virtualfn2realfn(virtualfn):
238 Convert a virtual file name to a real one + the associated subclass keyword 238 Convert a virtual file name to a real one + the associated subclass keyword
239 """ 239 """
240 mc = "" 240 mc = ""
241 if virtualfn.startswith('mc:'): 241 if virtualfn.startswith('mc:') and virtualfn.count(':') >= 2:
242 elems = virtualfn.split(':') 242 elems = virtualfn.split(':')
243 mc = elems[1] 243 mc = elems[1]
244 virtualfn = ":".join(elems[2:]) 244 virtualfn = ":".join(elems[2:])
@@ -268,7 +268,7 @@ def variant2virtual(realfn, variant):
268 """ 268 """
269 if variant == "": 269 if variant == "":
270 return realfn 270 return realfn
271 if variant.startswith("mc:"): 271 if variant.startswith("mc:") and variant.count(':') >= 2:
272 elems = variant.split(":") 272 elems = variant.split(":")
273 if elems[2]: 273 if elems[2]:
274 return "mc:" + elems[1] + ":virtual:" + ":".join(elems[2:]) + ":" + realfn 274 return "mc:" + elems[1] + ":virtual:" + ":".join(elems[2:]) + ":" + realfn
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index 83cfee7fb4..4446addc77 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -614,7 +614,7 @@ class BBCooker:
614 # Replace string such as "mc:*:bash" 614 # Replace string such as "mc:*:bash"
615 # into "mc:A:bash mc:B:bash bash" 615 # into "mc:A:bash mc:B:bash bash"
616 for k in targetlist: 616 for k in targetlist:
617 if k.startswith("mc:"): 617 if k.startswith("mc:") and k.count(':') >= 2:
618 if wildcard: 618 if wildcard:
619 bb.fatal('multiconfig conflict') 619 bb.fatal('multiconfig conflict')
620 if k.split(":")[1] == "*": 620 if k.split(":")[1] == "*":
@@ -648,7 +648,7 @@ class BBCooker:
648 for k in fulltargetlist: 648 for k in fulltargetlist:
649 origk = k 649 origk = k
650 mc = "" 650 mc = ""
651 if k.startswith("mc:"): 651 if k.startswith("mc:") and k.count(':') >= 2:
652 mc = k.split(":")[1] 652 mc = k.split(":")[1]
653 k = ":".join(k.split(":")[2:]) 653 k = ":".join(k.split(":")[2:])
654 ktask = task 654 ktask = task
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index 28bdadb45e..7d493eb402 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -38,7 +38,7 @@ def taskname_from_tid(tid):
38 return tid.rsplit(":", 1)[1] 38 return tid.rsplit(":", 1)[1]
39 39
40def mc_from_tid(tid): 40def mc_from_tid(tid):
41 if tid.startswith('mc:'): 41 if tid.startswith('mc:') and tid.count(':') >= 2:
42 return tid.split(':')[1] 42 return tid.split(':')[1]
43 return "" 43 return ""
44 44
@@ -47,13 +47,13 @@ def split_tid(tid):
47 return (mc, fn, taskname) 47 return (mc, fn, taskname)
48 48
49def split_mc(n): 49def split_mc(n):
50 if n.startswith("mc:"): 50 if n.startswith("mc:") and n.count(':') >= 2:
51 _, mc, n = n.split(":", 2) 51 _, mc, n = n.split(":", 2)
52 return (mc, n) 52 return (mc, n)
53 return ('', n) 53 return ('', n)
54 54
55def split_tid_mcfn(tid): 55def split_tid_mcfn(tid):
56 if tid.startswith('mc:'): 56 if tid.startswith('mc:') and tid.count(':') >= 2:
57 elems = tid.split(':') 57 elems = tid.split(':')
58 mc = elems[1] 58 mc = elems[1]
59 fn = ":".join(elems[2:-1]) 59 fn = ":".join(elems[2:-1])
diff --git a/bitbake/lib/bb/siggen.py b/bitbake/lib/bb/siggen.py
index 0ac3952466..e0e03318a6 100644
--- a/bitbake/lib/bb/siggen.py
+++ b/bitbake/lib/bb/siggen.py
@@ -748,7 +748,7 @@ def clean_basepath(basepath):
748 if basepath[0] == '/': 748 if basepath[0] == '/':
749 return cleaned 749 return cleaned
750 750
751 if basepath.startswith("mc:"): 751 if basepath.startswith("mc:") and basepath.count(':') >= 2:
752 mc, mc_name, basepath = basepath.split(":", 2) 752 mc, mc_name, basepath = basepath.split(":", 2)
753 mc_suffix = ':mc:' + mc_name 753 mc_suffix = ':mc:' + mc_name
754 else: 754 else: