* [PATCH v3] llvm/mesa/rust: simplify llvm-config handling
@ 2026-06-12 3:46 Deepesh.Varatharajan
2026-06-12 8:39 ` Richard Purdie
2026-07-11 16:50 ` Dmitry Baryshkov
0 siblings, 2 replies; 5+ messages in thread
From: Deepesh.Varatharajan @ 2026-06-12 3:46 UTC (permalink / raw)
To: openembedded-core; +Cc: Sundeep.Kokkonda, Deepesh.Varatharajan, richard.purdie
From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
Replace PATH-based llvm-config discovery with explicit sysroot-native
resolution and simplify the target llvm-config wrapper to act as a pure
pass-through while preserving Yocto alternate path handling.
The previous implementation relied on:
* `which -a llvm-config | sed -n 2p`
which is unreliable in cross-build environments because it only
searches executables present in $PATH. Native sysroot tools
(e.g. recipe-sysroot-native llvm-config) are not guaranteed to be
exposed via PATH, so they may not be discovered at all.
* `echo $base_libdir | sed -n '/lib64/p'`
which depends on a BitBake variable that may be empty or unset
in certain build contexts, leading to incorrect libdir selection.
Update the wrapper to:
* Use an @LLVM_CONFIG_PATH@ placeholder that is replaced during the
build with the appropriate native llvm-config path.
* Detect libdir using filesystem inspection rather than variable
parsing.
* Preserve `YOCTO_ALTERNATE_EXE_PATH` and
`YOCTO_ALTERNATE_LIBDIR` handling.
* Delegate all arguments directly to the native llvm-config.
Update rust and mesa recipes to replace the placeholder with the native
llvm-config path during target and nativesdk builds.
Also remove the native llvm-config copy logic and lib/lib64 symlink
workarounds, relying instead on explicit native tool resolution.
Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
---
...unwind.pc.in-and-llvm-config-scripts.patch | 52 +++----------------
meta/recipes-devtools/rust/rust_1.96.0.bb | 52 ++++++-------------
meta/recipes-graphics/mesa/mesa.inc | 16 ++++++
3 files changed, 39 insertions(+), 81 deletions(-)
diff --git a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
index eeb802732b..72ffdc6c1f 100644
--- a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
+++ b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
@@ -8,6 +8,7 @@ These are added by OE project
Upstream-Status: Inappropriate [ OE-Specific ]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
---
libunwind/libunwind.pc.in | 9 ++++++
llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
@@ -35,56 +36,19 @@ new file mode 100644
index 000000000000..6a0dd54b8eab
--- /dev/null
+++ b/llvm/tools/llvm-config/llvm-config
-@@ -0,0 +1,52 @@
+@@ -0,0 +1,15 @@
+#!/bin/bash
+#
-+# Wrapper script for llvm-config. Supplies the right environment variables
-+# for the target and delegates to the native llvm-config for anything else. This
-+# is needed because arguments like --ldflags, --cxxflags, etc. are set by the
-+# native compile rather than the target compile.
++# The llvm-config wrapper will act as a pure pass-through to the native llvm-config
++# while preserving Yocto-specific environment variables used for alternate executable
++# and library path resolution.
+#
+SCRIPT_DIR="$(dirname "$(readlink -f "$0")")"
-+NEXT_LLVM_CONFIG="$(which -a llvm-config | sed -n 2p)"
++NEXT_LLVM_CONFIG="@LLVM_CONFIG_PATH@"
+export YOCTO_ALTERNATE_EXE_PATH="${YOCTO_ALTERNATE_EXE_PATH:="$(readlink -f "$SCRIPT_DIR/../llvm-config")"}"
-+if [ -n "$( echo $base_libdir | sed -n '/lib64/p')" ]; then
++if [ -d "$(readlink -f "$SCRIPT_DIR/../../lib64")" ]; then
+ export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib64"}"
+else
+ export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib"}"
+fi
-+if [[ $# == 0 ]]; then
-+ exec "$NEXT_LLVM_CONFIG"
-+fi
-+
-+remain=""
-+output=""
-+for arg in "$@"; do
-+ case "$arg" in
-+ --cppflags)
-+ output="${output} ${CPPFLAGS}"
-+ ;;
-+ --cflags)
-+ output="${output} ${CFLAGS}"
-+ ;;
-+ --cxxflags)
-+ output="${output} ${CXXFLAGS}"
-+ ;;
-+ --ldflags)
-+ output="${output} ${LDFLAGS}"
-+ ;;
-+ --shared-mode)
-+ output="${output} shared"
-+ ;;
-+ --link-shared)
-+ break
-+ ;;
-+ *)
-+ remain="${remain} ${arg}"
-+ ;;
-+ esac
-+done
-+
-+if [ "${remain}" != "" ]; then
-+ output="${output} "$("$NEXT_LLVM_CONFIG" ${remain})
-+fi
-+
-+echo "${output}"
++exec "$NEXT_LLVM_CONFIG" "$@"
diff --git a/meta/recipes-devtools/rust/rust_1.96.0.bb b/meta/recipes-devtools/rust/rust_1.96.0.bb
index 3eb2a36406..8b0f1d1459 100644
--- a/meta/recipes-devtools/rust/rust_1.96.0.bb
+++ b/meta/recipes-devtools/rust/rust_1.96.0.bb
@@ -31,7 +31,7 @@ PV .= "${@bb.utils.contains('RUST_CHANNEL', 'stable', '', '-${RUST_CHANNEL}', d)
export FORCE_CRATE_HASH = "${BB_TASKHASH}"
-RUST_ALTERNATE_EXE_PATH ?= "${STAGING_BINDIR}/llvm-config"
+RUST_ALTERNATE_EXE_PATH = "${STAGING_BINDIR_CROSS}/llvm-config"
RUST_ALTERNATE_EXE_PATH_NATIVE = "${STAGING_BINDIR_NATIVE}/llvm-config"
# We don't want to use bitbakes vendoring because the rust sources do their
@@ -192,37 +192,22 @@ python do_configure() {
bb.build.exec_func("setup_cargo_environment", d)
}
-# llvm-config expects static/dynamic libraries to be in the 'lib' directory rather than 'lib64' when
-# multilibs enabled. Since we are copying the natively built llvm-config into the target sysroot
-# and executing it there, it will default to searching in 'lib', as it is unaware of the 'lib64'
-# directory. To ensure llvm-config can locate the necessary libraries, create a symlink from 'lib'
-do_compile:append:class-target() {
- # Ensure llvm-config can find static libraries in multilib setup
- lib64_dir="${STAGING_DIR_TARGET}/usr/lib64"
- lib_dir="${STAGING_DIR_TARGET}/usr/lib"
-
- if [ -d "$lib64_dir" ]; then
- # If lib does not exist, symlink it to lib64
- if [ ! -e "$lib_dir" ]; then
- ln -s lib64 "$lib_dir"
- fi
-
- # Only do per-file symlinking if lib is a real directory (not symlink)
- if [ -d "$lib_dir" ] && [ ! -L "$lib_dir" ]; then
- for lib64_file in "${lib64_dir}"/libLLVM*.a "${lib64_dir}"/libLLVM*.so*; do
- if [ -e "$lib64_file" ]; then
- lib_name=$(basename "${lib64_file}")
- target_link="${lib_dir}/${lib_name}"
-
- if [ ! -e "${target_link}" ]; then
- ln -s "../lib64/${lib_name}" "${target_link}"
- fi
- fi
- done
- fi
+replace_llvm_config_path() {
+ if [ -f "${STAGING_BINDIR_CROSS}/llvm-config" ]; then
+ sed -i \
+ 's#@LLVM_CONFIG_PATH@#${RUST_ALTERNATE_EXE_PATH_NATIVE}#g' \
+ ${RUST_ALTERNATE_EXE_PATH}
fi
}
+do_compile:append:class-target() {
+ replace_llvm_config_path
+}
+
+do_compile:append:class-nativesdk() {
+ replace_llvm_config_path
+}
+
rust_runx () {
echo "COMPILE ${PN}" "$@"
@@ -236,14 +221,6 @@ rust_runx () {
export RUSTFLAGS="${RUST_DEBUG_REMAP} -Clink-arg=-lz -Clink-arg=-lzstd"
- # Copy the natively built llvm-config into the target so we can run it. Horrible,
- # but works!
- if [ ${RUST_ALTERNATE_EXE_PATH_NATIVE} != ${RUST_ALTERNATE_EXE_PATH} -a ! -f ${RUST_ALTERNATE_EXE_PATH} ]; then
- mkdir -p `dirname ${RUST_ALTERNATE_EXE_PATH}`
- cp ${RUST_ALTERNATE_EXE_PATH_NATIVE} ${RUST_ALTERNATE_EXE_PATH}
- patchelf --remove-rpath ${RUST_ALTERNATE_EXE_PATH}
- fi
-
oe_cargo_fix_env
python3 src/bootstrap/bootstrap.py ${@oe.utils.parallel_make_argument(d, '-j %d')} "$@" --verbose
@@ -263,6 +240,7 @@ do_compile () {
do_test_compile[dirs] = "${B}"
do_test_compile () {
+ replace_llvm_config_path
rust_runx build src/tools/remote-test-server --target "${RUST_TARGET_SYS}"
}
diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc
index 15dad6eedd..f40fed5ebc 100644
--- a/meta/recipes-graphics/mesa/mesa.inc
+++ b/meta/recipes-graphics/mesa/mesa.inc
@@ -51,6 +51,22 @@ ANY_OF_DISTRO_FEATURES = "opencl opengl vulkan"
PLATFORMS ??= "${@bb.utils.filter('PACKAGECONFIG', 'x11 wayland', d)}"
+replace_llvm_config_path() {
+ if [ -f "${STAGING_BINDIR_CROSS}/llvm-config" ]; then
+ sed -i \
+ 's#@LLVM_CONFIG_PATH@#${STAGING_BINDIR_NATIVE}/llvm-config#g' \
+ ${STAGING_BINDIR_CROSS}/llvm-config
+ fi
+}
+
+do_configure:prepend:class-target() {
+ replace_llvm_config_path
+}
+
+do_configure:prepend:class-nativesdk() {
+ replace_llvm_config_path
+}
+
# set the MESA_BUILD_TYPE to either 'release' (default) or 'debug'
# by default the upstream mesa sources build a debug release
# here we assume the user will want a release build by default
--
2.49.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v3] llvm/mesa/rust: simplify llvm-config handling
2026-06-12 3:46 [PATCH v3] llvm/mesa/rust: simplify llvm-config handling Deepesh.Varatharajan
@ 2026-06-12 8:39 ` Richard Purdie
2026-06-15 3:45 ` Deepesh Varatharajan
2026-07-11 16:50 ` Dmitry Baryshkov
1 sibling, 1 reply; 5+ messages in thread
From: Richard Purdie @ 2026-06-12 8:39 UTC (permalink / raw)
To: Deepesh.Varatharajan, openembedded-core; +Cc: Sundeep.Kokkonda
On Thu, 2026-06-11 at 20:46 -0700, Deepesh.Varatharajan@windriver.com wrote:
> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>
> Replace PATH-based llvm-config discovery with explicit sysroot-native
> resolution and simplify the target llvm-config wrapper to act as a pure
> pass-through while preserving Yocto alternate path handling.
>
> The previous implementation relied on:
>
> * `which -a llvm-config | sed -n 2p`
> which is unreliable in cross-build environments because it only
> searches executables present in $PATH. Native sysroot tools
> (e.g. recipe-sysroot-native llvm-config) are not guaranteed to be
> exposed via PATH, so they may not be discovered at all.
We always configure PATH to contain the cross scripts and native
sysroot. Is there something which is reconfiguring PATH to skip the
native sysroot?
> * `echo $base_libdir | sed -n '/lib64/p'`
> which depends on a BitBake variable that may be empty or unset
> in certain build contexts, leading to incorrect libdir selection.
>
> Update the wrapper to:
>
> * Use an @LLVM_CONFIG_PATH@ placeholder that is replaced during the
> build with the appropriate native llvm-config path.
> * Detect libdir using filesystem inspection rather than variable
> parsing.
> * Preserve `YOCTO_ALTERNATE_EXE_PATH` and
> `YOCTO_ALTERNATE_LIBDIR` handling.
> * Delegate all arguments directly to the native llvm-config.
>
> Update rust and mesa recipes to replace the placeholder with the native
> llvm-config path during target and nativesdk builds.
>
> Also remove the native llvm-config copy logic and lib/lib64 symlink
> workarounds, relying instead on explicit native tool resolution.
>
> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> ---
> ...unwind.pc.in-and-llvm-config-scripts.patch | 52 +++----------------
> meta/recipes-devtools/rust/rust_1.96.0.bb | 52 ++++++-------------
> meta/recipes-graphics/mesa/mesa.inc | 16 ++++++
> 3 files changed, 39 insertions(+), 81 deletions(-)
>
> diff --git a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> index eeb802732b..72ffdc6c1f 100644
> --- a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> +++ b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> @@ -8,6 +8,7 @@ These are added by OE project
> Upstream-Status: Inappropriate [ OE-Specific ]
>
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> +Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> ---
> libunwind/libunwind.pc.in | 9 ++++++
> llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
> @@ -35,56 +36,19 @@ new file mode 100644
> index 000000000000..6a0dd54b8eab
> --- /dev/null
> +++ b/llvm/tools/llvm-config/llvm-config
> -@@ -0,0 +1,52 @@
> +@@ -0,0 +1,15 @@
> +#!/bin/bash
> +#
> -+# Wrapper script for llvm-config. Supplies the right environment variables
> -+# for the target and delegates to the native llvm-config for anything else. This
> -+# is needed because arguments like --ldflags, --cxxflags, etc. are set by the
> -+# native compile rather than the target compile.
> ++# The llvm-config wrapper will act as a pure pass-through to the native llvm-config
> ++# while preserving Yocto-specific environment variables used for alternate executable
> ++# and library path resolution.
> +#
> +SCRIPT_DIR="$(dirname "$(readlink -f "$0")")"
> -+NEXT_LLVM_CONFIG="$(which -a llvm-config | sed -n 2p)"
> ++NEXT_LLVM_CONFIG="@LLVM_CONFIG_PATH@"
As I understand it, this is always being configured to point at the
llvm-config in the native sysroot?
I think this script is only ever installed into STAGING_BINDIR_CROSS?
If that is the case, could we just set this to a relative path to
SCRIPT_DIR, which would then always point at the right places without
needing to be adjusted each time?
> +export YOCTO_ALTERNATE_EXE_PATH="${YOCTO_ALTERNATE_EXE_PATH:="$(readlink -f "$SCRIPT_DIR/../llvm-config")"}"
> -+if [ -n "$( echo $base_libdir | sed -n '/lib64/p')" ]; then
> ++if [ -d "$(readlink -f "$SCRIPT_DIR/../../lib64")" ]; then
> + export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib64"}"
> +else
> + export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib"}"
> +fi
> -+if [[ $# == 0 ]]; then
> -+ exec "$NEXT_LLVM_CONFIG"
> -+fi
> -+
> -+remain=""
> -+output=""
> -+for arg in "$@"; do
> -+ case "$arg" in
> -+ --cppflags)
> -+ output="${output} ${CPPFLAGS}"
> -+ ;;
> -+ --cflags)
> -+ output="${output} ${CFLAGS}"
> -+ ;;
Can you remind me, how does the native llvm-config provide the target
cflags? Is that triggered by setting the YOCTO_ALTERNATE_LIBDIR above?
Cheers,
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] llvm/mesa/rust: simplify llvm-config handling
2026-06-12 8:39 ` Richard Purdie
@ 2026-06-15 3:45 ` Deepesh Varatharajan
0 siblings, 0 replies; 5+ messages in thread
From: Deepesh Varatharajan @ 2026-06-15 3:45 UTC (permalink / raw)
To: Richard Purdie, openembedded-core; +Cc: Sundeep.Kokkonda
On 12-06-2026 14:09, Richard Purdie wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
> On Thu, 2026-06-11 at 20:46 -0700, Deepesh.Varatharajan@windriver.com wrote:
>> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>>
>> Replace PATH-based llvm-config discovery with explicit sysroot-native
>> resolution and simplify the target llvm-config wrapper to act as a pure
>> pass-through while preserving Yocto alternate path handling.
>>
>> The previous implementation relied on:
>>
>> * `which -a llvm-config | sed -n 2p`
>> which is unreliable in cross-build environments because it only
>> searches executables present in $PATH. Native sysroot tools
>> (e.g. recipe-sysroot-native llvm-config) are not guaranteed to be
>> exposed via PATH, so they may not be discovered at all.
> We always configure PATH to contain the cross scripts and native
> sysroot. Is there something which is reconfiguring PATH to skip the
> native sysroot?
After running bitbake rust -c devshell, I checked echo $PATH and seen native
sysroot path present there.
In this case, since we already know the exact location from which
llvm-config should
be used, would it make sense to reference that path directly instead of
recursively
searching for llvm-config from the current directory?
>
>> * `echo $base_libdir | sed -n '/lib64/p'`
>> which depends on a BitBake variable that may be empty or unset
>> in certain build contexts, leading to incorrect libdir selection.
>>
>> Update the wrapper to:
>>
>> * Use an @LLVM_CONFIG_PATH@ placeholder that is replaced during the
>> build with the appropriate native llvm-config path.
>> * Detect libdir using filesystem inspection rather than variable
>> parsing.
>> * Preserve `YOCTO_ALTERNATE_EXE_PATH` and
>> `YOCTO_ALTERNATE_LIBDIR` handling.
>> * Delegate all arguments directly to the native llvm-config.
>>
>> Update rust and mesa recipes to replace the placeholder with the native
>> llvm-config path during target and nativesdk builds.
>>
>> Also remove the native llvm-config copy logic and lib/lib64 symlink
>> workarounds, relying instead on explicit native tool resolution.
>>
>> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>> ---
>> ...unwind.pc.in-and-llvm-config-scripts.patch | 52 +++----------------
>> meta/recipes-devtools/rust/rust_1.96.0.bb | 52 ++++++-------------
>> meta/recipes-graphics/mesa/mesa.inc | 16 ++++++
>> 3 files changed, 39 insertions(+), 81 deletions(-)
>>
>> diff --git a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
>> index eeb802732b..72ffdc6c1f 100644
>> --- a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
>> +++ b/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
>> @@ -8,6 +8,7 @@ These are added by OE project
>> Upstream-Status: Inappropriate [ OE-Specific ]
>>
>> Signed-off-by: Khem Raj <raj.khem@gmail.com>
>> +Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>> ---
>> libunwind/libunwind.pc.in | 9 ++++++
>> llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
>> @@ -35,56 +36,19 @@ new file mode 100644
>> index 000000000000..6a0dd54b8eab
>> --- /dev/null
>> +++ b/llvm/tools/llvm-config/llvm-config
>> -@@ -0,0 +1,52 @@
>> +@@ -0,0 +1,15 @@
>> +#!/bin/bash
>> +#
>> -+# Wrapper script for llvm-config. Supplies the right environment variables
>> -+# for the target and delegates to the native llvm-config for anything else. This
>> -+# is needed because arguments like --ldflags, --cxxflags, etc. are set by the
>> -+# native compile rather than the target compile.
>> ++# The llvm-config wrapper will act as a pure pass-through to the native llvm-config
>> ++# while preserving Yocto-specific environment variables used for alternate executable
>> ++# and library path resolution.
>> +#
>> +SCRIPT_DIR="$(dirname "$(readlink -f "$0")")"
>> -+NEXT_LLVM_CONFIG="$(which -a llvm-config | sed -n 2p)"
>> ++NEXT_LLVM_CONFIG="@LLVM_CONFIG_PATH@"
> As I understand it, this is always being configured to point at the
> llvm-config in the native sysroot?
yes
>
> I think this script is only ever installed into STAGING_BINDIR_CROSS?
yes
>
> If that is the case, could we just set this to a relative path to
> SCRIPT_DIR, which would then always point at the right places without
> needing to be adjusted each time?
This script is used in both target and nativesdk builds, and the
directory layout differs between them.
For example:
target : "../recipe-sysroot/usr/bin/crossscripts"
nativesdk :
"../recipe-sysroot/usr/local/oe-sdk-hardcoded-buildpath/sysroots/x86_64-oesdk-linux/usr/bin/crossscripts"
Because the relative location of native llvm-config with respect to
SCRIPT_DIR is not the same in these two environments,
a single path relative from SCRIPT_DIR would not resolve correctly in
both cases. Therefore, the path cannot be expressed
as one fixed relative path and still work for both target and nativesdk
builds.
>
>> +export YOCTO_ALTERNATE_EXE_PATH="${YOCTO_ALTERNATE_EXE_PATH:="$(readlink -f "$SCRIPT_DIR/../llvm-config")"}"
>> -+if [ -n "$( echo $base_libdir | sed -n '/lib64/p')" ]; then
>> ++if [ -d "$(readlink -f "$SCRIPT_DIR/../../lib64")" ]; then
>> + export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib64"}"
>> +else
>> + export YOCTO_ALTERNATE_LIBDIR="${YOCTO_ALTERNATE_LIBDIR:="/lib"}"
>> +fi
>> -+if [[ $# == 0 ]]; then
>> -+ exec "$NEXT_LLVM_CONFIG"
>> -+fi
>> -+
>> -+remain=""
>> -+output=""
>> -+for arg in "$@"; do
>> -+ case "$arg" in
>> -+ --cppflags)
>> -+ output="${output} ${CPPFLAGS}"
>> -+ ;;
>> -+ --cflags)
>> -+ output="${output} ${CFLAGS}"
>> -+ ;;
> Can you remind me, how does the native llvm-config provide the target
> cflags? Is that triggered by setting the YOCTO_ALTERNATE_LIBDIR above?
Yes.
>
> Cheers,
>
> Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] llvm/mesa/rust: simplify llvm-config handling
2026-06-12 3:46 [PATCH v3] llvm/mesa/rust: simplify llvm-config handling Deepesh.Varatharajan
2026-06-12 8:39 ` Richard Purdie
@ 2026-07-11 16:50 ` Dmitry Baryshkov
2026-07-13 8:50 ` Deepesh Varatharajan
1 sibling, 1 reply; 5+ messages in thread
From: Dmitry Baryshkov @ 2026-07-11 16:50 UTC (permalink / raw)
To: Deepesh.Varatharajan; +Cc: openembedded-core, Sundeep.Kokkonda, richard.purdie
On Thu, Jun 11, 2026 at 08:46:43PM -0700, Deepesh.Varatharajan@windriver.com wrote:
> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>
> Replace PATH-based llvm-config discovery with explicit sysroot-native
> resolution and simplify the target llvm-config wrapper to act as a pure
> pass-through while preserving Yocto alternate path handling.
>
> The previous implementation relied on:
>
> * `which -a llvm-config | sed -n 2p`
> which is unreliable in cross-build environments because it only
> searches executables present in $PATH. Native sysroot tools
> (e.g. recipe-sysroot-native llvm-config) are not guaranteed to be
> exposed via PATH, so they may not be discovered at all.
>
> * `echo $base_libdir | sed -n '/lib64/p'`
> which depends on a BitBake variable that may be empty or unset
> in certain build contexts, leading to incorrect libdir selection.
>
> Update the wrapper to:
>
> * Use an @LLVM_CONFIG_PATH@ placeholder that is replaced during the
> build with the appropriate native llvm-config path.
> * Detect libdir using filesystem inspection rather than variable
> parsing.
> * Preserve `YOCTO_ALTERNATE_EXE_PATH` and
> `YOCTO_ALTERNATE_LIBDIR` handling.
> * Delegate all arguments directly to the native llvm-config.
>
> Update rust and mesa recipes to replace the placeholder with the native
> llvm-config path during target and nativesdk builds.
>
> Also remove the native llvm-config copy logic and lib/lib64 symlink
> workarounds, relying instead on explicit native tool resolution.
>
> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> ---
> ...unwind.pc.in-and-llvm-config-scripts.patch | 52 +++----------------
> meta/recipes-devtools/rust/rust_1.96.0.bb | 52 ++++++-------------
> meta/recipes-graphics/mesa/mesa.inc | 16 ++++++
> 3 files changed, 39 insertions(+), 81 deletions(-)
This got applied and now it broken building of OpenCL:
FAILED: [code=1] src/gallium/frontends/rusticl/rusticl_llvm_bindings.rs
/home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot-native/usr/bin/bindgen ../sources/mesa-26.1.2/src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp --output /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/build/src/gallium/frontends/rusticl/rusticl_llvm_bindings.rs --wrap-unsafe-ops --raw-line '#![allow(clippy::all)]' --raw-line '#![allow(improper_ctypes)]' --raw-line '#![allow(unused_unsafe)]' --raw-line '#![allow(non_camel_case_types)]' --raw-line '#![allow(non_snake_case)]' --raw-line '#![allow(non_upper_case_globals)]' --raw-line '#![allow(unsafe_op_in_unsafe_fn)]' --raw-line '#![allow(unnecessary_transmutes)]' --generate constructors,functions,types,vars --opaque-type '.*' --allowlist-function clang::getClangFullVersion --allowlist-function llvm::LLVMContext::LLVMContext --allowlist-function llvm::writeSpirv --allowlist-var 'LLVM_VERSION_.*' --rust-target 1.96.0 --rust-edition 2021 -- -fno-builtin-malloc -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS '-DPACKAGE_VERSION="26.1.2"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_OPENGL=1 -DHAVE_OPENGL_ES_1=1 -DHAVE_OPENGL_ES_2=1 -DHAVE_FREEDRENO -DHAVE_LLVMPIPE -DHAVE_SOFTPIPE -DHAVE_VIRGL -DHAVE_ZINK -DHAVE_SWRAST -DMESA_SYSTEM_HAS_KMS_DRM=1 -DVIDEO_CODEC_VC1DEC=0 -DVIDEO_CODEC_H264DEC=0 -DVIDEO_CODEC_H264ENC=0 -DVIDEO_CODEC_H265DEC=0 -DVIDEO_CODEC_H265ENC=0 -DVIDEO_CODEC_AV1DEC=1 -DVIDEO_CODEC_AV1ENC=1 -DVIDEO_CODEC_VP9DEC=1 -DVIDEO_CODEC_MPEG12DEC=1 -DVIDEO_CODEC_JPEGDEC=1 -DHAVE_LIBGBM -DHAVE_WAYLAND_PLATFORM -DHAVE_X11_PLATFORM -DHAVE_SURFACELESS_PLATFORM -DHAVE_DRM_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_LIBGLVND=1 -DHAVE_GFX_COMPUTE -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DGLAPI_EXPORT_PROTO_ENTRY_POINTS=0 -DALLOW_KCMP -DMESA_DEBUG=0 -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE___BUILTIN_TYPES_COMPATIBLE_P -DHAVE___BUILTIN_ADD_OVERFLOW -DHAVE___BUILTIN_ADD_OVERFLOW_P -DHAVE___BUILTIN_SUB_OVERFLOW_P -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_OPTIMIZE -DHAVE_FUNC_ATTRIBUTE_COLD -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DHAVE_REALLOCARRAY -DHAVE_FMEMOPEN -D_GNU_SOURCE -DUSE_GCC_ATOMIC_BUILTINS -DMAJOR_IN_SYSMACROS -DHAS_SCHED_H -DHAS_SCHED_GETAFFINITY -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_POLL_H -DHAVE_SYS_INOTIFY_H -DHAVE_LINUX_UDMABUF_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_POSIX_FALLOCATE -DHAVE_SECURE_GETENV -DHAVE_SYSCONF -DHAVE_GNU_QSORT_R -DHAVE_STRUCT_TIMESPEC -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_ISSIGNALING -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM '-DMESA_LLVM_VERSION_STRING="22.1.8"' -DLLVM_IS_SHARED=1 -DDRAW_LLVM_AVAILABLE=1 -DAMD_LLVM_AVAILABLE=1 -DGALLIVM_USE_ORCJIT=0 -DHAVE_SPIRV_TOOLS -DUSE_LIBELF -DTHREAD_SANITIZER=0 -DWL_HIDE_DEPRECATED -DHAVE_WL_DISPATCH_QUEUE_TIMEOUT -DHAVE_WL_CREATE_QUEUE_WITH_NAME -DHAVE_X11_DRM -DHAVE_DRI -DHAVE_DRI2 -DHAVE_DRI3_EXPLICIT_SYNC -DHAVE_DRISW_KMS -DHAVE_RENDERDOC_INTEGRATION=1 -march=armv8-a+crc -mbranch-protection=standard -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot --target=aarch64-qcom-linux -D_FILE_OFFSET_BITS=64 -DNDEBUG -D_GNU_SOURCE -D_GLIBCXX_USE_CXX11_ABI=1 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -pthread -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS '-DPACKAGE_VERSION="26.1.2"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_OPENGL=1 -DHAVE_OPENGL_ES_1=1 -DHAVE_OPENGL_ES_2=1 -DHAVE_FREEDRENO -DHAVE_LLVMPIPE -DHAVE_SOFTPIPE -DHAVE_VIRGL -DHAVE_ZINK -DHAVE_SWRAST -DMESA_SYSTEM_HAS_KMS_DRM=1 -DVIDEO_CODEC_VC1DEC=0 -DVIDEO_CODEC_H264DEC=0 -DVIDEO_CODEC_H264ENC=0 -DVIDEO_CODEC_H265DEC=0 -DVIDEO_CODEC_H265ENC=0 -DVIDEO_CODEC_AV1DEC=1 -DVIDEO_CODEC_AV1ENC=1 -DVIDEO_CODEC_VP9DEC=1 -DVIDEO_CODEC_MPEG12DEC=1 -DVIDEO_CODEC_JPEGDEC=1 -DHAVE_LIBGBM -DHAVE_WAYLAND_PLATFORM -DHAVE_X11_PLATFORM -DHAVE_SURFACELESS_PLATFORM -DHAVE_DRM_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_LIBGLVND=1 -DHAVE_GFX_COMPUTE -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DGLAPI_EXPORT_PROTO_ENTRY_POINTS=0 -DALLOW_KCMP -DMESA_DEBUG=0 -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE___BUILTIN_TYPES_COMPATIBLE_P -DHAVE___BUILTIN_ADD_OVERFLOW -DHAVE___BUILTIN_ADD_OVERFLOW_P -DHAVE___BUILTIN_SUB_OVERFLOW_P -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_OPTIMIZE -DHAVE_FUNC_ATTRIBUTE_COLD -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DHAVE_REALLOCARRAY -DHAVE_FMEMOPEN -D_GNU_SOURCE -DUSE_GCC_ATOMIC_BUILTINS -DMAJOR_IN_SYSMACROS -DHAS_SCHED_H -DHAS_SCHED_GETAFFINITY -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_POLL_H -DHAVE_SYS_INOTIFY_H -DHAVE_LINUX_UDMABUF_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_POSIX_FALLOCATE -DHAVE_SECURE_GETENV -DHAVE_SYSCONF -DHAVE_GNU_QSORT_R -DHAVE_STRUCT_TIMESPEC -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_ISSIGNALING -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM '-DMESA_LLVM_VERSION_STRING="22.1.8"' -DLLVM_IS_SHARED=1 -DDRAW_LLVM_AVAILABLE=1 -DAMD_LLVM_AVAILABLE=1 -DGALLIVM_USE_ORCJIT=0 -DHAVE_SPIRV_TOOLS -DUSE_LIBELF -DTHREAD_SANITIZER=0 -DWL_HIDE_DEPRECATED -DHAVE_WL_DISPATCH_QUEUE_TIMEOUT -DHAVE_WL_CREATE_QUEUE_WITH_NAME -DHAVE_X11_DRM -DHAVE_DRI -DHAVE_DRI2 -DHAVE_DRI3_EXPLICIT_SYNC -DHAVE_DRISW_KMS -DHAVE_RENDERDOC_INTEGRATION=1 -x c++ -std=c++17 -MD -MQ ../sources/mesa-26.1.2/src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp -MF src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp.d
/home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot/usr/lib/aarch64-qcom-linux/16.1.0/../../../include/c++/16.1.0/cstddef:5
2:10: fatal error: 'stddef.h' file not found
Unable to generate bindings: clang diagnosed error: /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot/usr/lib/aarch64-qcom-linux/16.1.0/../../../include/c++/16.1.0/cstddef:52:10: fatal error: 'stddef.h' file not found
$ git bisect log
git bisect start
# status: waiting for both good and bad commits
# good: [dfc5720ac709828543e9599597ff836021bd1561] bitbake.conf: drop opencl from DISTRO_FEATURES_FILTER_NATIVE/_NATIVESDK
git bisect good dfc5720ac709828543e9599597ff836021bd1561
# status: waiting for bad commit, 1 good commit known
# bad: [cddc75dcf041c0e1c86baa36840caf1a8073e40f] glib-2.0: add back Signed-off-by in CVE-2026-58016 patch
git bisect bad cddc75dcf041c0e1c86baa36840caf1a8073e40f
# good: [5b718f4c044147dfa0742caacbc20133ead53f10] ptest-packagelists.inc: disable glib-2.0 for RISCV64
git bisect good 5b718f4c044147dfa0742caacbc20133ead53f10
# bad: [a82e2ac1d08439c2c19015632f622940a15d00c3] python3-uv-build: upgrade 0.11.21 -> 0.11.26
git bisect bad a82e2ac1d08439c2c19015632f622940a15d00c3
# good: [d3eb9f2ae9e887dcb70cf3bb6e284c0f861546c0] python3-certifi: upgrade 2026.5.20 -> 2026.6.17
git bisect good d3eb9f2ae9e887dcb70cf3bb6e284c0f861546c0
# bad: [9e1513b29849c56fe372e0d73ce229cebed32d9e] classes/meson: use ninja explicitly when compiling
git bisect bad 9e1513b29849c56fe372e0d73ce229cebed32d9e
# bad: [a02059069443cfe0dc5860eae4aebba68b9a4ec4] baremetal-helloworld: Fix override order
git bisect bad a02059069443cfe0dc5860eae4aebba68b9a4ec4
# good: [46b79c40c7ee5fa79e3889b77ca71bebc3136b9c] classes/gtk-doc: inherit python3native only if gtk-doc is enabled
git bisect good 46b79c40c7ee5fa79e3889b77ca71bebc3136b9c
# bad: [8337a9330c1fdbe36575c5e7495046b3df7f69d2] package: replace copydebugsources shell pipelines
git bisect bad 8337a9330c1fdbe36575c5e7495046b3df7f69d2
# good: [f810998ac90f7a3e20e26555f39d754b16ce8b69] bitbake.conf: drop opencl from DISTRO_FEATURES_FILTER_NATIVE/_NATIVESDK
git bisect good f810998ac90f7a3e20e26555f39d754b16ce8b69
# bad: [8aace29b692a8f3902a675fb4c022c223ba49531] llvm/mesa/rust: simplify llvm-config handling
git bisect bad 8aace29b692a8f3902a675fb4c022c223ba49531
# first bad commit: [8aace29b692a8f3902a675fb4c022c223ba49531] llvm/mesa/rust: simplify llvm-config handling
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] llvm/mesa/rust: simplify llvm-config handling
2026-07-11 16:50 ` Dmitry Baryshkov
@ 2026-07-13 8:50 ` Deepesh Varatharajan
0 siblings, 0 replies; 5+ messages in thread
From: Deepesh Varatharajan @ 2026-07-13 8:50 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: openembedded-core, Sundeep.Kokkonda, richard.purdie, yogesh.tyagi
Hi Dmitry,
Yogesh has already posted a potential fix for this issue, and it is
currently available in Mathieu's master-next branch.
https://git.openembedded.org/openembedded-core-contrib/commit/?h=mathieu/master-next&id=2e8ada1cb07d6dce8a0894b427b18b2bc585a2c8
I tested it locally, and it appears to resolve the issue. Could you
please give it a try on your side and let us know if it
fixes the problem for you?
Regards,
Deepesh
On 11-07-2026 22:20, Dmitry Baryshkov wrote:
> This got applied and now it broken building of OpenCL:
>
> FAILED: [code=1] src/gallium/frontends/rusticl/rusticl_llvm_bindings.rs
> /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot-native/usr/bin/bindgen
> ../sources/mesa-26.1.2/src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp
> --output
> /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/build/src/gallium/frontends/rusticl/rusticl_llvm_bindings.rs
> --wrap-unsafe-ops --raw-line '#![allow(clippy::all)]' --raw-line
> '#![allow(improper_ctypes)]' --raw-line '#![allow(unused_unsafe)]'
> --raw-line '#![allow(non_camel_case_types)]' --raw-line
> '#![allow(non_snake_case)]' --raw-line
> '#![allow(non_upper_case_globals)]' --raw-line
> '#![allow(unsafe_op_in_unsafe_fn)]' --raw-line
> '#![allow(unnecessary_transmutes)]' --generate
> constructors,functions,types,vars --opaque-type '.*'
> --allowlist-function clang::getClangFullVersion --allowlist-function
> llvm::LLVMContext::LLVMContext --allowlist-function llvm::writeSpirv
> --allowlist-var 'LLVM_VERSION_.*' --rust-target 1.96.0 --rust-edition
> 2021 -- -fno-builtin-malloc -D__STDC_CONSTANT_MACROS
> -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
> '-DPACKAGE_VERSION="26.1.2"'
> '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_OPENGL=1 -DHAVE_OPENGL_ES_1=1 -DHAVE_OPENGL_ES_2=1 -DHAVE_FREEDRENO -DHAVE_LLVMPIPE -DHAVE_SOFTPIPE -DHAVE_VIRGL -DHAVE_ZINK -DHAVE_SWRAST -DMESA_SYSTEM_HAS_KMS_DRM=1 -DVIDEO_CODEC_VC1DEC=0 -DVIDEO_CODEC_H264DEC=0 -DVIDEO_CODEC_H264ENC=0 -DVIDEO_CODEC_H265DEC=0 -DVIDEO_CODEC_H265ENC=0 -DVIDEO_CODEC_AV1DEC=1 -DVIDEO_CODEC_AV1ENC=1 -DVIDEO_CODEC_VP9DEC=1 -DVIDEO_CODEC_MPEG12DEC=1 -DVIDEO_CODEC_JPEGDEC=1 -DHAVE_LIBGBM -DHAVE_WAYLAND_PLATFORM -DHAVE_X11_PLATFORM -DHAVE_SURFACELESS_PLATFORM -DHAVE_DRM_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_LIBGLVND=1 -DHAVE_GFX_COMPUTE -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DGLAPI_EXPORT_PROTO_ENTRY_POINTS=0 -DALLOW_KCMP -DMESA_DEBUG=0 -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE___BUILTIN_TYPES_COMPATIBLE_P -DHAVE___BUILTIN_ADD_OVERFLOW -DHAVE___BUILTIN_ADD_OVERFLOW_P -DHAVE___BUILTIN_SUB_OVERFLOW_P -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_OPTIMIZE -DHAVE_FUNC_ATTRIBUTE_COLD -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DHAVE_REALLOCARRAY -DHAVE_FMEMOPEN -D_GNU_SOURCE -DUSE_GCC_ATOMIC_BUILTINS -DMAJOR_IN_SYSMACROS -DHAS_SCHED_H -DHAS_SCHED_GETAFFINITY -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_POLL_H -DHAVE_SYS_INOTIFY_H -DHAVE_LINUX_UDMABUF_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_POSIX_FALLOCATE -DHAVE_SECURE_GETENV -DHAVE_SYSCONF -DHAVE_GNU_QSORT_R -DHAVE_STRUCT_TIMESPEC -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_ISSIGNALING -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM '-DMESA_LLVM_VERSION_STRING="22.1.8"' -DLLVM_IS_SHARED=1 -DDRAW_LLVM_AVAILABLE=1 -DAMD_LLVM_AVAILABLE=1 -DGALLIVM_USE_ORCJIT=0 -DHAVE_SPIRV_TOOLS -DUSE_LIBELF -DTHREAD_SANITIZER=0 -DWL_HIDE_DEPRECATED -DHAVE_WL_DISPATCH_QUEUE_TIMEOUT -DHAVE_WL_CREATE_QUEUE_WITH_NAME -DHAVE_X11_DRM -DHAVE_DRI -DHAVE_DRI2 -DHAVE_DRI3_EXPLICIT_SYNC -DHAVE_DRISW_KMS -DHAVE_RENDERDOC_INTEGRATION=1 -march=armv8-a+crc -mbranch-protection=standard -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot
> --target=aarch64-qcom-linux -D_FILE_OFFSET_BITS=64 -DNDEBUG
> -D_GNU_SOURCE -D_GLIBCXX_USE_CXX11_ABI=1 -D__STDC_CONSTANT_MACROS
> -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -pthread
> -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
> '-DPACKAGE_VERSION="26.1.2"'
> '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_OPENGL=1 -DHAVE_OPENGL_ES_1=1 -DHAVE_OPENGL_ES_2=1 -DHAVE_FREEDRENO -DHAVE_LLVMPIPE -DHAVE_SOFTPIPE -DHAVE_VIRGL -DHAVE_ZINK -DHAVE_SWRAST -DMESA_SYSTEM_HAS_KMS_DRM=1 -DVIDEO_CODEC_VC1DEC=0 -DVIDEO_CODEC_H264DEC=0 -DVIDEO_CODEC_H264ENC=0 -DVIDEO_CODEC_H265DEC=0 -DVIDEO_CODEC_H265ENC=0 -DVIDEO_CODEC_AV1DEC=1 -DVIDEO_CODEC_AV1ENC=1 -DVIDEO_CODEC_VP9DEC=1 -DVIDEO_CODEC_MPEG12DEC=1 -DVIDEO_CODEC_JPEGDEC=1 -DHAVE_LIBGBM -DHAVE_WAYLAND_PLATFORM -DHAVE_X11_PLATFORM -DHAVE_SURFACELESS_PLATFORM -DHAVE_DRM_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_LIBGLVND=1 -DHAVE_GFX_COMPUTE -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DGLAPI_EXPORT_PROTO_ENTRY_POINTS=0 -DALLOW_KCMP -DMESA_DEBUG=0 -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE___BUILTIN_TYPES_COMPATIBLE_P -DHAVE___BUILTIN_ADD_OVERFLOW -DHAVE___BUILTIN_ADD_OVERFLOW_P -DHAVE___BUILTIN_SUB_OVERFLOW_P -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_OPTIMIZE -DHAVE_FUNC_ATTRIBUTE_COLD -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DHAVE_REALLOCARRAY -DHAVE_FMEMOPEN -D_GNU_SOURCE -DUSE_GCC_ATOMIC_BUILTINS -DMAJOR_IN_SYSMACROS -DHAS_SCHED_H -DHAS_SCHED_GETAFFINITY -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_POLL_H -DHAVE_SYS_INOTIFY_H -DHAVE_LINUX_UDMABUF_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_POSIX_FALLOCATE -DHAVE_SECURE_GETENV -DHAVE_SYSCONF -DHAVE_GNU_QSORT_R -DHAVE_STRUCT_TIMESPEC -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_ISSIGNALING -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM '-DMESA_LLVM_VERSION_STRING="22.1.8"' -DLLVM_IS_SHARED=1 -DDRAW_LLVM_AVAILABLE=1 -DAMD_LLVM_AVAILABLE=1 -DGALLIVM_USE_ORCJIT=0 -DHAVE_SPIRV_TOOLS -DUSE_LIBELF -DTHREAD_SANITIZER=0 -DWL_HIDE_DEPRECATED -DHAVE_WL_DISPATCH_QUEUE_TIMEOUT -DHAVE_WL_CREATE_QUEUE_WITH_NAME -DHAVE_X11_DRM -DHAVE_DRI -DHAVE_DRI2 -DHAVE_DRI3_EXPLICIT_SYNC -DHAVE_DRISW_KMS -DHAVE_RENDERDOC_INTEGRATION=1 -x c++ -std=c++17 -MD -MQ ../sources/mesa-26.1.2/src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp -MF src/gallium/frontends/rusticl/rusticl_llvm_bindings.hpp.d
> /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot/usr/lib/aarch64-qcom-linux/16.1.0/../../../include/c++/16.1.0/cstddef:5
> 2:10: fatal error: 'stddef.h' file not found
> Unable to generate bindings: clang diagnosed error: /home/lumag/Projects/RPB/build/tmp-qcom-distro/work/armv8a-qcom-linux/mesa/26.1.2/recipe-sysroot/usr/lib/aarch64-qcom-linux/16.1.0/../../../include/c++/16.1.0/cstddef:52:10: fatal error: 'stddef.h' file not found
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-07-13 8:50 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-12 3:46 [PATCH v3] llvm/mesa/rust: simplify llvm-config handling Deepesh.Varatharajan
2026-06-12 8:39 ` Richard Purdie
2026-06-15 3:45 ` Deepesh Varatharajan
2026-07-11 16:50 ` Dmitry Baryshkov
2026-07-13 8:50 ` Deepesh Varatharajan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox