diff options
author | Julia Kartseva <hex@fb.com> | 2020-11-14 02:08:15 +0100 |
---|---|---|
committer | Julia Kartseva <hex@fb.com> | 2021-04-27 01:20:58 +0200 |
commit | 7d861e12637892f1fcf7bbd69e4aec5a096f4bcb (patch) | |
tree | db9ca703607e12be7bfbd6a9feb57167da1829ba /meson_options.txt | |
parent | bpf: add build script for bpf programs (diff) | |
download | systemd-7d861e12637892f1fcf7bbd69e4aec5a096f4bcb.tar.xz systemd-7d861e12637892f1fcf7bbd69e4aec5a096f4bcb.zip |
meson, bpf: add HAVE_LIBBPF, BPF_FRAMEWORK options
* Add `bpf-framework` feature gate with 'auto', 'true' and 'false' choices
* Add libbpf [0] dependency
* Search for clang llvm-strip and bpftool binaries in compile time to
generate bpf skeleton.
For libbpf [0], make 0.2.0 [1] the minimum required version.
If libbpf is satisfied, set HAVE_LIBBPF config option to 1.
If `bpf-framework` feature gate is set to 'auto', means that whether
bpf feature is enabled or now is defined by the presence of all of
libbpf, clang, llvm and bpftool in build
environment.
With 'auto' all dependencies are optional.
If the gate is set to `true`, make all of the libbpf, clang and llvm
dependencies mandatory.
If it's set to `false`, set `BPF_FRAMEWORK` to false and make libbpf
dependency optional.
libbpf dependency is dynamic followed by the common pattern in systemd.
meson, bpf: add build rule for socket_bind program
Diffstat (limited to 'meson_options.txt')
-rw-r--r-- | meson_options.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/meson_options.txt b/meson_options.txt index 9441b88dec..ad7174cf69 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -403,3 +403,6 @@ option('kernel-install', type: 'boolean', value: 'true', description : 'install kernel-install and associated files') option('analyze', type: 'boolean', value: 'true', description : 'install systemd-analyze') + +option('bpf-framework', type : 'combo', choices : ['auto', 'true', 'false'], + description: 'build BPF programs from source code in restricted C') |