Moved binder_common to rpcbinder package under binder directory.
Bug: 234019127
Bug: 184872979
Test: atest compos_key_tests MicrodroidHostTestCases MicrodroidTestApp libbinder_rs-internal_test
Change-Id: Iceac394d2341f463362e9bbe8908e5d8a1b3f34f
diff --git a/microdroid_manager/Android.bp b/microdroid_manager/Android.bp
index 3ba2700..da63434 100644
--- a/microdroid_manager/Android.bp
+++ b/microdroid_manager/Android.bp
@@ -16,7 +16,6 @@
"libanyhow",
"libapexutil_rust",
"libapkverify",
- "libbinder_common",
"libbinder_rs",
"libbyteorder",
"libdiced_utils",
@@ -33,6 +32,7 @@
"libonce_cell",
"libopenssl",
"libprotobuf",
+ "librpcbinder_rs",
"librustutils",
"libscopeguard",
"libserde",
diff --git a/microdroid_manager/src/main.rs b/microdroid_manager/src/main.rs
index 531c707..c226e9d 100644
--- a/microdroid_manager/src/main.rs
+++ b/microdroid_manager/src/main.rs
@@ -26,7 +26,6 @@
use anyhow::{anyhow, bail, ensure, Context, Error, Result};
use apkverify::{get_public_key_der, verify};
use binder::{wait_for_interface, Strong};
-use binder_common::rpc_client::connect_rpc_binder;
use diced_utils::cbor::encode_header;
use glob::glob;
use idsig::V4Signature;
@@ -37,6 +36,7 @@
use openssl::sha::Sha512;
use payload::{get_apex_data_from_payload, load_metadata, to_metadata};
use rand::Fill;
+use rpcbinder::get_vsock_rpc_interface;
use rustutils::system_properties;
use rustutils::system_properties::PropertyWatcher;
use std::convert::TryInto;
@@ -141,7 +141,7 @@
}
fn get_vms_rpc_binder() -> Result<Strong<dyn IVirtualMachineService>> {
- connect_rpc_binder(VMADDR_CID_HOST, VM_BINDER_SERVICE_PORT as u32)
+ get_vsock_rpc_interface(VMADDR_CID_HOST, VM_BINDER_SERVICE_PORT as u32)
.context("Cannot connect to RPC service")
}