From b608bf5620765de20851eca55cbd6c42ce1af450 Mon Sep 17 00:00:00 2001 From: Johannes Schneider Date: Thu, 20 Jun 2024 12:32:18 +0200 Subject: [PATCH] meson: bpf: propagate 'sysroot' for cross compilation During cross-compilation of systemd, the compiler used to build the bpf's needs to be pointed at the correct include searchpath. Which can be done by passing the corresponding directory in through the cflags; for example in yocto/bitbake this would work: CFLAGS += "--sysroot=${STAGING_DIR_TARGET}" Signed-off-by: Johannes Schneider --- meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/meson.build b/meson.build index dd335c12445..aa36e72b024 100644 --- a/meson.build +++ b/meson.build @@ -1740,6 +1740,7 @@ if conf.get('BPF_FRAMEWORK') == 1 '-ffile-prefix-map=', '-fdebug-prefix-map=', '-fmacro-prefix-map=', + '--sysroot=', ] foreach opt : c_args -- 2.47.3