diff mbox series

[v2,6/9] qemu: extend PKG_CONFIG_LIBDIR when using the host search path

Message ID 20260209125628.640221-6-ross.burton@arm.com
State New
Headers show
Series [v2,1/9] pkgconfig: inherit the pkgconfig class | expand

Commit Message

Ross Burton Feb. 9, 2026, 12:56 p.m. UTC
The qemu recipe does something horrible when building natively and can
also search the build host's search path.

Now that we've moved from PKG_CONFIG_PATH to PKG_CONFIG_LIBDIR, this
code also needs to do the same as otherwise it will find packages on the
build host before the native sysroot.

Signed-off-by: Ross Burton <ross.burton@arm.com>
---
 meta/recipes-devtools/qemu/qemu.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta/recipes-devtools/qemu/qemu.inc b/meta/recipes-devtools/qemu/qemu.inc
index 7aa593bc5d..8abe366284 100644
--- a/meta/recipes-devtools/qemu/qemu.inc
+++ b/meta/recipes-devtools/qemu/qemu.inc
@@ -129,7 +129,7 @@  do_configure:prepend:class-native() {
 	# Append build host pkg-config paths for native target since the host may provide sdl
 	BHOST_PKGCONFIG_PATH=$(PATH=/usr/bin:/bin pkg-config --variable pc_path pkg-config || echo "")
 	if [ ! -z "$BHOST_PKGCONFIG_PATH" ]; then
-		export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$BHOST_PKGCONFIG_PATH
+		export PKG_CONFIG_LIBDIR=$PKG_CONFIG_LIBDIR:$BHOST_PKGCONFIG_PATH
 	fi
 }