added a new function called list_flag_with_info to list all the flags given all four storage files (package.map, flag.map, flag.val, flag.info). also exported this api thru cxx interface so aconfigd can use it. Bug: b/312444587 Test: atest -c Change-Id: Ibbfe657b980d40e25e5e28962b930338192e2d98
20 lines
509 B
Rust
20 lines
509 B
Rust
use protobuf_codegen::Codegen;
|
|
|
|
fn main() {
|
|
let proto_files = vec!["protos/aconfig_storage_metadata.proto"];
|
|
|
|
// tell cargo to only re-run the build script if any of the proto files has changed
|
|
for path in &proto_files {
|
|
println!("cargo:rerun-if-changed={}", path);
|
|
}
|
|
|
|
Codegen::new()
|
|
.pure()
|
|
.include("protos")
|
|
.inputs(proto_files)
|
|
.cargo_out_dir("aconfig_storage_protos")
|
|
.run_from_script();
|
|
|
|
let _ = cxx_build::bridge("src/lib.rs");
|
|
}
|