From 768c89e306d0486acf8bc76cecef90436f6551b3 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Mon, 1 May 2023 12:01:35 +0100 Subject: gcc/go: Drop crosssdk suffix from virtual provides to improve dependency handling There is little point in having "crosssdk" suffex added to the virtual provider within gcc/go since the TARGET_PREFIX or SDK_PREFIX already encapsulates this. Remove it allowing some of the special case overriding to be removed. This also allows removal of some of the MLPREFIX usage since again, the triplet also covers this. (From OE-Core rev: fe0206ba482d209b24e636d578aa68ba5e67ba1b) Signed-off-by: Richard Purdie --- meta/lib/oe/classextend.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'meta/lib/oe/classextend.py') diff --git a/meta/lib/oe/classextend.py b/meta/lib/oe/classextend.py index 8d7e428d8a..5161d33d2d 100644 --- a/meta/lib/oe/classextend.py +++ b/meta/lib/oe/classextend.py @@ -32,7 +32,8 @@ class ClassExtender(object): if name.endswith("-" + self.extname): name = name.replace("-" + self.extname, "") if name.startswith("virtual/"): - if "binutils" in name: + # Assume large numbers of dashes means a triplet is present and we don't need to convert + if name.count("-") >= 3 and name.endswith(("-go", "-binutils", "-gcc", "-g++")): return name subs = name.split("/", 1)[1] if not subs.startswith(self.extname): @@ -152,9 +153,7 @@ class NativesdkClassExtender(ClassExtender): def map_depends(self, dep): if dep.startswith(self.extname): return dep - if dep.endswith(("-gcc", "-g++")): - return dep + "-crosssdk" - elif dep.endswith(("-native", "-native-runtime")) or ('nativesdk-' in dep) or ('-cross-' in dep) or ('-crosssdk-' in dep): + if dep.endswith(("-native", "-native-runtime")) or ('nativesdk-' in dep) or ('-cross-' in dep) or ('-crosssdk-' in dep): return dep else: return self.extend_name(dep) -- cgit v1.2.3-54-g00ecf