BPF: Implement build time feature flag for libbpf
For trunk stable development, we use a build time feature flag for the
libbpf functionality to be added to bpfloader. For now, simply stub it
out.
This approach will allow merging and testing of libbpf functionality
without changing the binaries produced with the feature disabled going
forward.
Bug: 359646531
Test: manual/treehugger
Change-Id: I230e81b5f23b49a17f3731e0c40e184cde1c49c1
Signed-off-by: Neill Kapron <nkapron@google.com>
diff --git a/loader/Android.bp b/loader/Android.bp
index 5854f86..4f66cdf 100644
--- a/loader/Android.bp
+++ b/loader/Android.bp
@@ -113,6 +113,10 @@
rust_binary {
name: "bpfloader",
+ cfgs: select(release_flag("RELEASE_BPF_ENABLE_LIBBPF"), {
+ true: ["enable_libbpf"],
+ default: [],
+ }),
srcs: [
"bpfloader.rs",
],