All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Zoltán Böszörményi" <zboszor@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: "Zoltán Böszörményi" <zboszor@gmail.com>
Subject: [PATCH 4/4] mesa: Add PACKAGECONFIG "rusticl"
Date: Fri, 24 Feb 2023 10:38:50 +0100	[thread overview]
Message-ID: <20230224093850.3393567-4-zboszor@gmail.com> (raw)
In-Reply-To: <20230224093850.3393567-1-zboszor@gmail.com>

Signed-off-by: Zoltán Böszörményi <zboszor@gmail.com>
---
 meta/recipes-graphics/mesa/mesa.inc | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc
index 9ec10c49ca..e70cf9a42a 100644
--- a/meta/recipes-graphics/mesa/mesa.inc
+++ b/meta/recipes-graphics/mesa/mesa.inc
@@ -45,7 +45,7 @@ PROVIDES = " \
     virtual/mesa \
     "
 
-inherit meson pkgconfig python3native gettext features_check
+inherit meson pkgconfig python3native gettext features_check rust
 
 BBCLASSEXTEND = "native nativesdk"
 
@@ -119,6 +119,13 @@ PACKAGECONFIG[egl] = "-Degl=enabled, -Degl=disabled"
 OPENCL_NATIVE = "${@bb.utils.contains('PACKAGECONFIG', 'freedreno', '-Dopencl-native=true', '', d)}"
 PACKAGECONFIG[clover] = "-Dgallium-opencl=icd -Dopencl-spirv=true ${OPENCL_NATIVE},-Dgallium-opencl=disabled -Dopencl-spirv=false,libclc spirv-tools"
 
+# "rusticl" requires libclc and spirv-llvm-translator from meta-clang and spirv-tools from OE-Core
+PACKAGECONFIG[rusticl] = "-Dgallium-rusticl=true -Drust_std=2021,-Dgallium-rusticl=false,bindgen-cli-native libclc spirv-tools spirv-llvm-translator,libclc spirv-tools spirv-llvm-translator"
+
+# "rusticl" runs bindgen.
+# This setting is needed by bindgen to dlopen the correct libclang.
+export LIBCLANG_PATH = "${STAGING_LIBDIR_NATIVE}"
+
 PACKAGECONFIG[broadcom] = ""
 PACKAGECONFIG[etnaviv] = ""
 PACKAGECONFIG[freedreno] = ""
@@ -197,6 +204,7 @@ DEV_PKG_DEPENDENCY = ""
 RDEPENDS:libgles3-mesa-dev += "libgles2-mesa-dev"
 
 RDEPENDS:libopencl-mesa += "${@bb.utils.contains('PACKAGECONFIG', 'clover', 'libclc spirv-tools', '', d)}"
+RDEPENDS:libopencl-mesa += "${@bb.utils.contains('PACKAGECONFIG', 'rusticl', 'libclc spirv-tools spirv-llvm-translator', '', d)}"
 
 PACKAGES =+ "libegl-mesa libegl-mesa-dev \
              libosmesa libosmesa-dev \
@@ -242,7 +250,8 @@ python __anonymous() {
               ("gles", "libgles1", "libglesv1-cm1"),
               ("gles", "libgles2", "libglesv2-2"),
               ("gles", "libgles3",),
-              ("clover", "libopencl",)):
+              ("clover", "libopencl",),
+              ("rusticl", "libopencl",)):
         if not p[0] in pkgconfig:
             continue
         mlprefix = d.getVar("MLPREFIX")
@@ -303,7 +312,8 @@ FILES:libgles1-mesa = "${libdir}/libGLESv1*.so.*"
 FILES:libgles2-mesa = "${libdir}/libGLESv2.so.*"
 FILES:libgl-mesa = "${libdir}/libGL.so.*"
 FILES:libglx-mesa = "${libdir}/libGLX*.so.*"
-FILES:libopencl-mesa = "${libdir}/libMesaOpenCL.so.* ${libdir}/gallium-pipe/*.so ${sysconfdir}/OpenCL/vendors/mesa.icd"
+FILES:libopencl-mesa = "${libdir}/libMesaOpenCL.so.* ${libdir}/libRusticlOpenCL.so ${libdir}/gallium-pipe/*.so ${sysconfdir}/OpenCL/vendors/mesa.icd ${sysconfdir}/OpenCL/vendors/rusticl.icd"
+INSANE_SKIP:libopencl-mesa += "${@bb.utils.contains('PACKAGECONFIG', 'rusticl', 'dev-so', '', d)}"
 FILES:libglapi = "${libdir}/libglapi.so.*"
 FILES:libosmesa = "${libdir}/libOSMesa.so.*"
 FILES:libxatracker = "${libdir}/libxatracker.so.*"
-- 
2.39.2



  parent reply	other threads:[~2023-02-24  9:39 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-24  9:38 [PATCH 1/4] bindgen-cli: Add new recipe Zoltán Böszörményi
2023-02-24  9:38 ` [PATCH 2/4] mesa, mesa-gl: 23.0.0 Zoltán Böszörményi
2023-02-24  9:38 ` [PATCH 3/4] mesa: Rename PACKAGECONFIG "opencl" to "clover" Zoltán Böszörményi
2023-02-24 12:28   ` [OE-core] " Alexandre Belloni
2023-02-24 14:29     ` Alexander Kanavin
2023-02-24  9:38 ` Zoltán Böszörményi [this message]
2023-02-24  9:45   ` [OE-core] [PATCH 4/4] mesa: Add PACKAGECONFIG "rusticl" Ross Burton
2023-02-24 10:05     ` Böszörményi Zoltán
     [not found]     ` <1746BAA6D62E4C0A.18951@lists.openembedded.org>
2023-02-24 10:34       ` Böszörményi Zoltán
2023-02-24 10:52         ` Alexander Kanavin
     [not found]         ` <1746BD3631A1C7C1.29542@lists.openembedded.org>
2023-02-24 11:12           ` Alexander Kanavin
2023-02-24 16:41             ` Böszörményi Zoltán
2023-02-24  9:44 ` [OE-core] [PATCH 1/4] bindgen-cli: Add new recipe Alexander Kanavin
2023-02-24  9:59   ` Böszörményi Zoltán
2023-02-24 10:13     ` Alexander Kanavin
2023-02-24 10:36       ` Böszörményi Zoltán
2023-02-24 13:32 ` Alex Kiernan
2023-02-24 16:43   ` Böszörményi Zoltán
2023-02-26  5:08 ` [PATCH v2 0/3] Mesa 23.0.0 Zoltán Böszörményi
2023-02-26  5:08   ` [PATCH v2 1/3] mesa, mesa-gl: 23.0.0 Zoltán Böszörményi
2023-02-26  5:08   ` [PATCH v2 2/3] mesa: Rename PACKAGECONFIG "opencl" to "clover" Zoltán Böszörményi
2023-02-27  9:18     ` Alexander Kanavin
2023-02-26  5:08   ` [PATCH v2 3/3] mesa: Add PACKAGECONFIG "rusticl" Zoltán Böszörményi
2023-02-27  8:03     ` Alex Kiernan
2023-02-27  9:31       ` Alexander Kanavin
2023-02-27 10:39         ` Böszörményi Zoltán
     [not found]     ` <17479FC3A76A2964.29542@lists.openembedded.org>
2023-02-27  9:32       ` [OE-core] " Alex Kiernan
2023-02-27 10:36         ` Böszörményi Zoltán
2023-02-27 11:28           ` Alex Kiernan
2023-02-27 11:36             ` Alexander Kanavin

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=20230224093850.3393567-4-zboszor@gmail.com \
    --to=zboszor@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.