Don't use SDK variant for vendor JNI libraries
Vendor JNI libraries already have stable APIs enforced by the VNDK,
they shouldn't use SDK variants.
Bug: 156225490
Test: TestJNISDK
Change-Id: I21ba67e8e9fb05016caf5888129adc1a939545c2
Merged-In: I21ba67e8e9fb05016caf5888129adc1a939545c2
(cherry picked from commit c2d24050c5e3a09b7bc5236d15f24afa2405911f)
diff --git a/android/module.go b/android/module.go
index f164072..baf348a 100644
--- a/android/module.go
+++ b/android/module.go
@@ -886,6 +886,13 @@
return Bool(m.commonProperties.System_ext_specific)
}
+// RequiresStableAPIs returns true if the module will be installed to a partition that may
+// be updated separately from the system image.
+func (m *ModuleBase) RequiresStableAPIs(ctx BaseModuleContext) bool {
+ return m.SocSpecific() || m.DeviceSpecific() ||
+ (m.ProductSpecific() && ctx.Config().EnforceProductPartitionInterface())
+}
+
func (m *ModuleBase) PartitionTag(config DeviceConfig) string {
partition := "system"
if m.SocSpecific() {