From 012118da8f5f46eb34240b6a804c3a8a768d126e Mon Sep 17 00:00:00 2001 From: Po Hu Date: Fri, 13 Mar 2020 14:14:27 +0800 Subject: [PATCH] Add PRODUCT_BOOT_JARS_EXTRA interface This interface allows vendor to append their boot jars after AOSP's without changing inherit order. Test: get_build_var PRODUCT_BOOT_JARS Change-Id: I6beb8cc9d7fcf0d474b24f634e81657aa42e7ed7 Bug: 152267233 --- core/product.mk | 6 ++++++ core/product_config.mk | 3 +++ 2 files changed, 9 insertions(+) diff --git a/core/product.mk b/core/product.mk index 364f0d827..b497abb5b 100644 --- a/core/product.mk +++ b/core/product.mk @@ -216,6 +216,12 @@ _product_list_vars += PRODUCT_VENDOR_KERNEL_HEADERS # A list of module names of BOOTCLASSPATH (jar files) _product_list_vars += PRODUCT_BOOT_JARS + +# A list of extra BOOTCLASSPATH jars (to be appended after common jars). +# Products that include device-specific makefiles before AOSP makefiles should use this +# instead of PRODUCT_BOOT_JARS, so that device-specific jars go after common jars. +_product_list_vars += PRODUCT_BOOT_JARS_EXTRA + _product_list_vars += PRODUCT_SUPPORTS_BOOT_SIGNER _product_list_vars += PRODUCT_SUPPORTS_VBOOT _product_list_vars += PRODUCT_SUPPORTS_VERITY diff --git a/core/product_config.mk b/core/product_config.mk index c4361d0bb..aabd47270 100644 --- a/core/product_config.mk +++ b/core/product_config.mk @@ -228,6 +228,9 @@ PRODUCT_AAPT_CONFIG := $(PRODUCT_LOCALES) $(PRODUCT_AAPT_CONFIG) PRODUCT_AAPT_CONFIG_SP := $(PRODUCT_AAPT_CONFIG) PRODUCT_AAPT_CONFIG := $(subst $(space),$(comma),$(PRODUCT_AAPT_CONFIG)) +# Extra boot jars must be appended at the end after common boot jars. +PRODUCT_BOOT_JARS += $(PRODUCT_BOOT_JARS_EXTRA) + ifndef PRODUCT_SYSTEM_NAME PRODUCT_SYSTEM_NAME := $(PRODUCT_NAME) endif