PKG_LICENSE:=BSD-3-Clause
PKG_INSTALL:=1
-PKG_BUILD_DEPENDS:=glslang/host python3/host libva
-HOST_BUILD_DEPENDS:=python3/host spirv-tools/host
+
+# arc, powerpc and powerpc64 LLVM builds are currently broken, but powerpc{,64} would support JIT in theory
+LLVM_SUPPORTED:=(aarch64||arm||i386||i686||loongarch64||mips||mipsel||mips64||mips64el||riscv64||x86_64)
+
+PKG_BUILD_DEPENDS:=glslang/host python3/host libva (x86_64||i386||i686):mesa/host $(LLVM_SUPPORTED):llvm
+HOST_BUILD_DEPENDS:=python3/host spirv-tools/host llvm
PKG_CONFIG_DEPENDS:= \
CONFIG_PACKAGE_libosmesa \
MESON_USE_STAGING_PYTHON:=1
HOST_PYTHON3_PACKAGE_BUILD_DEPENDS:=./host-pip-requirements.txt
-LLVM_SUPPORTED:=(aarch64||arm||i386||i686||loongarch64||mips||mipsel||mips64||mips64el||riscv64||x86_64)
-# arc, powerpc and powerpc64 LLVM builds are currently broken, but powerpc{,64} would support JIT in theory
-
ifneq ($(CONFIG_aarch64)$(CONFIG_arm)$(CONFIG_i386)$(CONFIG_i686)$(CONFIG_loongarch64)$(CONFIG_mips)$(CONFIG_mipsel)$(CONFIG_mips64)$(CONFIG_mips64el)$(CONFIG_riscv64)$(CONFIG_x86_64),)
-PKG_BUILD_DEPENDS+=llvm
-HOST_BUILD_DEPENDS+=llvm
MESA_USE_LLVM:=1
else
MESA_USE_LLVM:=
endif
-ifneq ($(CONFIG_x86_64)$(CONFIG_i386)$(CONFIG_i686),)
-PKG_BUILD_DEPENDS+=mesa/host
-endif
-
include $(TOPDIR)/feeds/packages/lang/rust/rust-values.mk
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/host-build.mk
Mako==1.2.0 --hash=sha256:9a7c7e922b87db3686210cf49d5d767033a41d4010b284e747682c92bddd8b39
MarkupSafe==2.1.1 --hash=sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b
-PyYAML==6.0.1 --hash=sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43
+ply==3.11 --hash=sha256:00c7c1aaa88358b9c765b6d3000c6eec0ba42abca5351b095321aef446081da3
pycparser==2.21 --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206
+PyYAML==6.0.1 --hash=sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43
--- a/meson.build
+++ b/meson.build
-@@ -1856,7 +1856,11 @@ endif
+@@ -1743,21 +1743,26 @@ _llvm = get_option('llvm')
+ dep_llvm = null_dep
+ with_llvm = false
+ if _llvm.allowed()
+- dep_llvm = dependency(
+- 'llvm',
+- method : host_machine.system() == 'windows' ? 'auto' : 'config-tool',
+- version : _llvm_version,
+- modules : llvm_modules,
+- optional_modules : llvm_optional_modules,
+- required : (
+- with_amd_vk or with_gallium_radeonsi or with_gallium_clover or with_clc
+- or _llvm.enabled()
+- ),
+- static : not _shared_llvm,
+- fallback : ['llvm', 'dep_llvm'],
+- include_type : 'system',
+- )
+- with_llvm = dep_llvm.found()
++ llvm_proj = subproject('llvm')
++ if llvm_proj.found()
++ dep_llvm = llvm_proj.get_variable('dep_llvm')
++ with_llvm = true
++ else
++ dep_llvm = dependency(
++ 'llvm',
++ method : host_machine.system() == 'windows' ? 'auto' : 'config-tool',
++ version : _llvm_version,
++ modules : llvm_modules,
++ optional_modules : llvm_optional_modules,
++ required : (
++ with_amd_vk or with_gallium_radeonsi or with_gallium_clover or with_clc
++ or _llvm.enabled()
++ ),
++ static : not _shared_llvm,
++ fallback : ['llvm', 'dep_llvm'],
++ include_type : 'system',
++ )
++ endif
+ endif
+ if with_llvm
+ pre_args += '-DMESA_LLVM_VERSION_STRING="@0@"'.format(dep_llvm.version())
+@@ -1856,7 +1861,11 @@ endif
dep_clang = null_dep
if with_clc or with_gallium_clover