mirror of
https://git.yoctoproject.org/poky
synced 2026-04-20 00:32:13 +02:00
multilib: Add support for cross-canadian multilib packages
Add support for the generation of cross-canadian packages.
Each cross-canadian package has:
PN = "pkg-cross-canadian-${TRANSLATED_TARGET_ARCH}"
in order for that to be evaluated properly with multilibs enabled, it was
necessary to detect both the presence of the cross-canadian packages and
then update the vars using the OVERRIDE for the multilib. Additional checks
were made to ensure that any dependency that sais "cross-canadian" did not
get prefixed with the MLPREFIX.
Also, make sure that even when building multilib cross-canadian packages,
we only use the single SDK PACKAGE_ARCH, we don't want or need variants.
(From OE-Core rev: 132a182e2f6c330aa645de42c1aeb386e43bddd3)
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
511f7f9d04
commit
ea22010560
@@ -183,6 +183,8 @@ def preferred_ml_updates(d):
|
||||
providers.append(v)
|
||||
|
||||
for pkg, reason in blacklists.items():
|
||||
if pkg.endswith("-native") or pkg.startswith("nativesdk-") or 'cross-canadian' in pkg:
|
||||
continue
|
||||
for p in prefixes:
|
||||
newpkg = p + "-" + pkg
|
||||
if not d.getVarFlag('PNBLACKLIST', newpkg, True):
|
||||
@@ -193,6 +195,17 @@ def preferred_ml_updates(d):
|
||||
pkg = v.replace("PREFERRED_VERSION_", "")
|
||||
if pkg.endswith("-native") or pkg.startswith("nativesdk-"):
|
||||
continue
|
||||
if 'cross-canadian' in pkg:
|
||||
for p in prefixes:
|
||||
localdata = bb.data.createCopy(d)
|
||||
override = ":virtclass-multilib-" + p
|
||||
localdata.setVar("OVERRIDES", localdata.getVar("OVERRIDES", False) + override)
|
||||
bb.data.update_data(localdata)
|
||||
newname = localdata.expand(v)
|
||||
if newname != v:
|
||||
newval = localdata.getVar(v, True)
|
||||
d.setVar(newname, newval)
|
||||
continue
|
||||
for p in prefixes:
|
||||
newname = "PREFERRED_VERSION_" + p + "-" + pkg
|
||||
if not d.getVar(newname, False):
|
||||
@@ -203,14 +216,36 @@ def preferred_ml_updates(d):
|
||||
pkg = prov.replace("PREFERRED_PROVIDER_", "")
|
||||
if pkg.endswith("-native") or pkg.startswith("nativesdk-"):
|
||||
continue
|
||||
if 'cross-canadian' in pkg:
|
||||
for p in prefixes:
|
||||
localdata = bb.data.createCopy(d)
|
||||
override = ":virtclass-multilib-" + p
|
||||
localdata.setVar("OVERRIDES", localdata.getVar("OVERRIDES", False) + override)
|
||||
bb.data.update_data(localdata)
|
||||
newname = localdata.expand(prov)
|
||||
if newname != prov:
|
||||
newval = localdata.expand(val)
|
||||
d.setVar(newname, newval)
|
||||
continue
|
||||
virt = ""
|
||||
if pkg.startswith("virtual/"):
|
||||
pkg = pkg.replace("virtual/", "")
|
||||
virt = "virtual/"
|
||||
for p in prefixes:
|
||||
newname = "PREFERRED_PROVIDER_" + virt + p + "-" + pkg
|
||||
if pkg != "kernel":
|
||||
val = p + "-" + val
|
||||
|
||||
# implement variable keys
|
||||
localdata = bb.data.createCopy(d)
|
||||
override = ":virtclass-multilib-" + p
|
||||
localdata.setVar("OVERRIDES", localdata.getVar("OVERRIDES", False) + override)
|
||||
bb.data.update_data(localdata)
|
||||
newname = localdata.expand(prov)
|
||||
if newname != prov:
|
||||
d.setVar(newname, localdata.expand(val))
|
||||
|
||||
# implement alternative multilib name
|
||||
newname = localdata.expand("PREFERRED_PROVIDER_" + virt + p + "-" + pkg)
|
||||
if not d.getVar(newname, False):
|
||||
d.setVar(newname, val)
|
||||
|
||||
@@ -218,7 +253,7 @@ def preferred_ml_updates(d):
|
||||
mp = (d.getVar("MULTI_PROVIDER_WHITELIST", True) or "").split()
|
||||
extramp = []
|
||||
for p in mp:
|
||||
if p.endswith("-native") or p.startswith("nativesdk-"):
|
||||
if p.endswith("-native") or p.startswith("nativesdk-") or 'cross-canadian' in p:
|
||||
continue
|
||||
virt = ""
|
||||
if p.startswith("virtual/"):
|
||||
|
||||
Reference in New Issue
Block a user