Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
To: openembedded-core@lists.openembedded.org
Cc: Khem Raj <raj.khem@gmail.com>
Subject: [PATCH v6 10/13] llvm: enable more targets to build
Date: Mon, 07 Apr 2025 12:48:15 +0300	[thread overview]
Message-ID: <20250407-mesa-25-v6-10-29bf4cae8d28@oss.qualcomm.com> (raw)
In-Reply-To: <20250407-mesa-25-v6-0-29bf4cae8d28@oss.qualcomm.com>

Pull in the list of targets being enabled by meta-clang in order to
make the libllvm from OE-Core runtime compatible with the one built by
the clang recipe inside meta-clang.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
---
 meta/recipes-devtools/llvm/llvm_20.1.1.bb | 20 +-------------------
 1 file changed, 1 insertion(+), 19 deletions(-)

diff --git a/meta/recipes-devtools/llvm/llvm_20.1.1.bb b/meta/recipes-devtools/llvm/llvm_20.1.1.bb
index 027de04bdd6d340792d1a9ca303dcd508a6d87c4..1c6e9bc48fb832fe67c14ca6d8f93410cb268c00 100644
--- a/meta/recipes-devtools/llvm/llvm_20.1.1.bb
+++ b/meta/recipes-devtools/llvm/llvm_20.1.1.bb
@@ -51,24 +51,6 @@ OECMAKE_SOURCEPATH = "${S}/llvm"
 
 LLVM_INSTALL_DIR = "${WORKDIR}/llvm-install"
 
-def get_llvm_arch(bb, d, arch_var):
-    import re
-    a = d.getVar(arch_var)
-    if   re.match(r'(i.86|athlon|x86.64)$', a):         return 'X86'
-    elif re.match(r'arm$', a):                          return 'ARM'
-    elif re.match(r'armeb$', a):                        return 'ARM'
-    elif re.match(r'aarch64$', a):                      return 'AArch64'
-    elif re.match(r'aarch64_be$', a):                   return 'AArch64'
-    elif re.match(r'loongarch(32|64|)$', a):            return 'LoongArch'
-    elif re.match(r'mips(isa|)(32|64|)(r6|)(el|)$', a): return 'Mips'
-    elif re.match(r'riscv(32|64)(eb|)$', a):            return 'RISCV'
-    elif re.match(r'p(pc|owerpc)(|64)', a):             return 'PowerPC'
-    else:
-        raise bb.parse.SkipRecipe("Cannot map '%s' to a supported LLVM architecture" % a)
-
-def get_llvm_host_arch(bb, d):
-    return get_llvm_arch(bb, d, 'HOST_ARCH')
-
 PACKAGECONFIG ??= "libllvm libclc spirv-llvm-translator"
 # if optviewer OFF, force the modules to be not found or the ones on the host would be found
 PACKAGECONFIG[optviewer] = ",-DPY_PYGMENTS_FOUND=OFF -DPY_PYGMENTS_LEXERS_C_CPP_FOUND=OFF -DPY_YAML_FOUND=OFF,python3-pygments python3-pyyaml,python3-pygments python3-pyyaml"
@@ -79,7 +61,7 @@ PACKAGECONFIG[spirv-llvm-translator] = "-DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR
 #
 # Default to build all OE-Core supported target arches (user overridable).
 #
-LLVM_TARGETS ?= "AMDGPU;NVPTX;SPIRV;${@get_llvm_host_arch(bb, d)}"
+LLVM_TARGETS ?= "AMDGPU;AArch64;ARM;BPF;Mips;PowerPC;RISCV;X86;LoongArch;NVPTX;SPIRV"
 
 ARM_INSTRUCTION_SET:armv5 = "arm"
 ARM_INSTRUCTION_SET:armv4t = "arm"

-- 
2.39.5



  parent reply	other threads:[~2025-04-07  9:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-07  9:48 [PATCH v6 00/13] mesa: upgrade to 25.0.2 Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 01/13] runqemu: also set GBM_BACKENDS_PATH Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 02/13] llvm: move libLLVM.so.N.M to llvm-libllvm package Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 03/13] llvm: use OECMAKE_SOURCEPATH to specify cmake dir Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 04/13] llvm: handle libdir in llvm-config Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 05/13] llvm: also use llvm-config wrapper for nativesdk recipes Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 06/13] llvm: remove LLVM_LDFLAGS from llvm-config --ldflags output Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 07/13] llvm: forcibly disable __isoc23_strtol usage Dmitry Baryshkov
2025-04-07 11:22   ` [OE-core] " Alexander Kanavin
2025-04-07 11:58     ` Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 08/13] llvm: support building libclc Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 09/13] llvm: add SPIRV-LLVM-Translator support Dmitry Baryshkov
2025-04-07  9:48 ` Dmitry Baryshkov [this message]
2025-04-07  9:48 ` [PATCH v6 11/13] mesa: upgrade 24.0.7 -> 25.0.2 Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 12/13] bindgen-cli: a tool to generate Rust bindings Dmitry Baryshkov
2025-04-07  9:48 ` [PATCH v6 13/13] mesa: add support for RustiCL under PACKAGECONFIG "opencl" Dmitry Baryshkov
2025-04-08 13:34 ` [OE-core] [PATCH v6 00/13] mesa: upgrade to 25.0.2 Mathieu Dubois-Briand
2025-04-08 19:08   ` Dmitry Baryshkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250407-mesa-25-v6-10-29bf4cae8d28@oss.qualcomm.com \
    --to=dmitry.baryshkov@oss.qualcomm.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=raj.khem@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox