From 308d02fd62dd997d4e83c0efe71fd4f8a6e0c975 Mon Sep 17 00:00:00 2001 From: Justin Yun Date: Tue, 21 Mar 2023 14:26:02 +0900 Subject: [PATCH] Enforce product interface by default We have both with/without product interface enforced targets. Because of this, unbundled apps in the product partition must consider bundled cases and has to add `jni_uses_platform_apis: true` to use jni libraries. As targets with PRODUCT_SHIPPING_API_LEVEL > 29 must enforce the product interfaces, if PRODUCT_SHIPPING_API_LEVEL is not defined, enforce the product stable interface by default. Bug: 273386586 Test: TH Change-Id: I5874bf0ae8477fab7b1097ad24c9cc0d95543eb1 --- core/product_config.mk | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/product_config.mk b/core/product_config.mk index 1ef8890d46..9db881f7e5 100644 --- a/core/product_config.mk +++ b/core/product_config.mk @@ -517,7 +517,8 @@ ifdef OVERRIDE_PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE := $(OVERRIDE_PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE) endif else ifeq ($(PRODUCT_SHIPPING_API_LEVEL),) - # No shipping level defined + # No shipping level defined. Enforce the product interface by default. + PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE := true else ifeq ($(call math_gt,$(PRODUCT_SHIPPING_API_LEVEL),29),true) # Enforce product interface if PRODUCT_SHIPPING_API_LEVEL is greater than 29. PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE := true @@ -532,7 +533,8 @@ PRODUCT_USE_PRODUCT_VNDK := false ifneq ($(PRODUCT_USE_PRODUCT_VNDK_OVERRIDE),) PRODUCT_USE_PRODUCT_VNDK := $(PRODUCT_USE_PRODUCT_VNDK_OVERRIDE) else ifeq ($(PRODUCT_SHIPPING_API_LEVEL),) - # No shipping level defined + # No shipping level defined. Enforce the product interface by default. + PRODUCT_USE_PRODUCT_VNDK := true else ifeq ($(call math_gt,$(PRODUCT_SHIPPING_API_LEVEL),29),true) # Enforce product interface for VNDK if PRODUCT_SHIPPING_API_LEVEL is greater # than 29.