From: Johannes Schneider Date: Thu, 20 Jun 2024 10:32:18 +0000 (+0200) Subject: meson: bpf: propagate 'sysroot' for cross compilation X-Git-Tag: v257-rc1~1082 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b608bf5620765de20851eca55cbd6c42ce1af450;p=thirdparty%2Fsystemd.git 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 --- 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