From ae296b2178f05754c2000583ab9bd0618607675d Mon Sep 17 00:00:00 2001 From: Ken Chen Date: Wed, 20 Apr 2022 15:13:31 +0800 Subject: [PATCH] Add wrappers for the latest stable version of netd_aidl_interface-V*-cpp Currently, we need to update linked AILD interface in several places when we freeze a new interface version. Otherwise, it will have multiple versions of an AIDL lib and waste space/memory (b/220392885). To avoid manually update all AILD interface users every time, adds wrappers for the latest version of netd_aidl_interface-V*-cpp. The reason to use cc_default as a wrapper instead of cc_library is that it doesn't create an extra .so. Bug: 220392885 Test: TH Change-Id: I281b2e5f7d04fadfae0ede4db7565e9f222dbe95 --- staticlibs/netd/Android.bp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/staticlibs/netd/Android.bp b/staticlibs/netd/Android.bp index 85a756c725..6bc7c01400 100644 --- a/staticlibs/netd/Android.bp +++ b/staticlibs/netd/Android.bp @@ -53,6 +53,7 @@ cc_library_static { min_sdk_version: "29", } +// TODO: delete this one when AOSP is no longer auto-merge to git_sc-mainline-prod. cc_library_static { name: "netd_aidl_interface-lateststable-cpp", whole_static_libs: [ @@ -60,6 +61,16 @@ cc_library_static { ], } +cc_defaults { + name: "netd_aidl_interface_lateststable_cpp_static", + static_libs: ["netd_aidl_interface-V8-cpp"], +} + +cc_defaults { + name: "netd_aidl_interface_lateststable_cpp_shared", + shared_libs: ["netd_aidl_interface-V8-cpp"], +} + aidl_interface { name: "netd_aidl_interface", local_include_dir: "binder",