Revert "Revert "vib example client on product"" am: 3e776b9e04 am: b192b1cec2

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2475244

Change-Id: I7b1e91ffc6ed1c143f40a1e809737822c19296f3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Steven Moreland 2023-03-14 00:23:42 +00:00 committed by Automerger Merge Worker
commit a38302413a
5 changed files with 22 additions and 2 deletions

View file

@ -10,7 +10,8 @@ package {
cc_library { cc_library {
name: "libexample_vib_getter", name: "libexample_vib_getter",
srcs: ["getter.cpp"], srcs: ["getter.cpp"],
vendor: true, product_available: true,
vendor_available: true,
shared_libs: [ shared_libs: [
"liblog", "liblog",
"libbinder_ndk", "libbinder_ndk",
@ -22,13 +23,32 @@ cc_library {
android_app { android_app {
name: "ExampleVibratorJavaVendorClient", name: "ExampleVibratorJavaVendorClient",
privileged: true,
vendor: true, vendor: true,
static_libs: ["android.hardware.vibrator-V1-java"], static_libs: ["android.hardware.vibrator-V1-java"],
jni_libs: ["libexample_vib_getter"], jni_libs: ["libexample_vib_getter"],
use_embedded_native_libs: true,
jarjar_rules: "jarjar.txt", jarjar_rules: "jarjar.txt",
stl: "c++_shared", stl: "c++_shared",
srcs: ["example/vib/MyActivity.java"], srcs: ["example/vib/MyActivity.java"],
sdk_version: "system_current", sdk_version: "system_current",
visibility: [":__subpackages__"], visibility: [":__subpackages__"],
} }
android_app {
name: "ExampleVibratorJavaProductClient",
product_specific: true,
static_libs: ["android.hardware.vibrator-V1-java"],
jni_libs: ["libexample_vib_getter"],
use_embedded_native_libs: true,
jarjar_rules: "jarjar.txt",
stl: "c++_shared",
srcs: ["example/vib/MyActivity.java"],
sdk_version: "system_current",
visibility: [":__subpackages__"],
// If PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE is not true, product apps
// may use unstable APIs. jni_uses_platform_apis must set to use the
// non-SDK jni libs in this case.
// This is not required if PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE is
// set to true.
jni_uses_platform_apis: true,
}