Extract a library for common CompOS things
A small refactoring as a preliminary step to creating composd.
Create a Rust library for useful things shared by various
CompOS-related binaries. This initially includes the code to start the
VM and connect to CompOS, as well as various useful constants.
As part of extracting the start VM code I migrated to using logging
directly rather than writing to stdout/stderr for greater reusability,
as suggested by Victor.
Bug: 186126194
Test: Get odsign to run compos_verify_key, still works
Change-Id: I57b7ebcdd1a6cb604b5d739b8a8e028fd59e7b90
diff --git a/compos/verify_key/Android.bp b/compos/verify_key/Android.bp
index dd54f76..a5892b8 100644
--- a/compos/verify_key/Android.bp
+++ b/compos/verify_key/Android.bp
@@ -5,18 +5,17 @@
rust_binary {
name: "compos_verify_key",
srcs: ["verify_key.rs"],
+ edition: "2018",
rustlibs: [
- "android.system.virtualizationservice-rust",
"compos_aidl_interface-rust",
+ "libandroid_logger",
"libanyhow",
- "libbinder_rpc_unstable_bindgen",
"libbinder_rs",
"libclap",
+ "libcompos_common",
+ "liblog_rust",
],
prefer_rlib: true,
- shared_libs: [
- "libbinder_rpc_unstable",
- ],
apex_available: [
"com.android.compos",
],