mirror of
https://git.yoctoproject.org/poky
synced 2026-04-14 08:02:30 +02:00
bitbake: bitbake: command: Move split_mc_pn to runqueue
All of the other multiconfig splitting functions are located in runqueue so move the function to split a pn/fn there also so that its easier to see them all together. Fixes a case where the findBestProvider() command wasn't working for multiconfig because it was looking for a prefix of "multiconfig:" instead of the newer "mc:" (Bitbake rev: 325827af66434affc2da460cc8b9a5c460e38056) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
c90dd50939
commit
0ecab7a461
@@ -138,12 +138,6 @@ class Command:
|
||||
def reset(self):
|
||||
self.remotedatastores = bb.remotedata.RemoteDatastores(self.cooker)
|
||||
|
||||
def split_mc_pn(pn):
|
||||
if pn.startswith("multiconfig:"):
|
||||
_, mc, pn = pn.split(":", 2)
|
||||
return (mc, pn)
|
||||
return ('', pn)
|
||||
|
||||
class CommandsSync:
|
||||
"""
|
||||
A class of synchronous commands
|
||||
@@ -442,7 +436,7 @@ class CommandsSync:
|
||||
findProviders.readonly = True
|
||||
|
||||
def findBestProvider(self, command, params):
|
||||
(mc, pn) = split_mc_pn(params[0])
|
||||
(mc, pn) = bb.runqueue.split_mc(params[0])
|
||||
return command.cooker.findBestProvider(pn, mc)
|
||||
findBestProvider.readonly = True
|
||||
|
||||
|
||||
@@ -46,6 +46,12 @@ def split_tid(tid):
|
||||
(mc, fn, taskname, _) = split_tid_mcfn(tid)
|
||||
return (mc, fn, taskname)
|
||||
|
||||
def split_mc(n):
|
||||
if n.startswith("mc:"):
|
||||
_, mc, n = n.split(":", 2)
|
||||
return (mc, n)
|
||||
return ('', n)
|
||||
|
||||
def split_tid_mcfn(tid):
|
||||
if tid.startswith('mc:'):
|
||||
elems = tid.split(':')
|
||||
|
||||
Reference in New Issue
Block a user