aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Hilliard <james.hilliard1@gmail.com>2022-01-30 19:33:55 -0700
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-01-31 14:27:11 +0900
commit408832e603b930d6d6062eb3bc6d6954a6ecb4f2 (patch)
tree95545be3be6fb50cdfee93d350eea5f8644018d2
parentbasic: update CIFS magic (diff)
downloadsystemd-408832e603b930d6d6062eb3bc6d6954a6ecb4f2.tar.xz
systemd-408832e603b930d6d6062eb3bc6d6954a6ecb4f2.zip
meson: set minimum clang/llvm versions for bpf support
The minimum clang/llvm-strip version needed for building libbpf based programs is 10.0.0, this is documented here: https://github.com/libbpf/libbpf/tree/v0.6.1#bpf-co-re-compile-once--run-everywhere Using an older version such as 9.0.0 will generate objects that bpftool will not be able to generate skeletons for.
-rw-r--r--meson.build4
1 files changed, 2 insertions, 2 deletions
diff --git a/meson.build b/meson.build
index 9faa6583a07..43c3252e361 100644
--- a/meson.build
+++ b/meson.build
@@ -988,7 +988,7 @@ else
# Support 'versioned' clang/llvm-strip binaries, as seen on Debian/Ubuntu
# (like clang-10/llvm-strip-10)
if meson.is_cross_build() or cc.get_id() != 'clang' or cc.cmd_array()[0].contains('afl-clang') or cc.cmd_array()[0].contains('hfuzz-clang')
- r = find_program('clang', required : bpf_framework_required)
+ r = find_program('clang', required : bpf_framework_required, version : '>= 10.0.0')
clang_found = r.found()
if clang_found
if meson.version().version_compare('>= 0.55')
@@ -1018,7 +1018,7 @@ else
else
llvm_strip_bin = 'llvm-strip'
endif
- llvm_strip = find_program(llvm_strip_bin, required : bpf_framework_required)
+ llvm_strip = find_program(llvm_strip_bin, required : bpf_framework_required, version : '>= 10.0.0')
# Debian installs this in /usr/sbin/ which is not in $PATH.
# We check for 'bpftool' first, honouring $PATH, and in /usr/sbin/ for Debian.