From f380da37041a0f51d8054cd9b4e31c8dbeca4760 Mon Sep 17 00:00:00 2001 From: Badhri Jagan Sridharan Date: Fri, 27 May 2016 09:49:49 -0700 Subject: [PATCH] resolve merge conflicts of e053d5c to nyc-mr1-dev-plus-aosp Change-Id: I90684bbe225000a172cec85814e04a49a7aac3f7 --- core/Makefile | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/core/Makefile b/core/Makefile index 050817806..9ea3ddb6d 100644 --- a/core/Makefile +++ b/core/Makefile @@ -518,12 +518,6 @@ endif INTERNAL_BOOTIMAGE_FILES := $(filter-out --%,$(INTERNAL_BOOTIMAGE_ARGS)) -BOARD_KERNEL_CMDLINE := $(strip $(BOARD_KERNEL_CMDLINE)) -ifdef BOARD_KERNEL_CMDLINE - INTERNAL_BOOTIMAGE_ARGS += --cmdline "$(BOARD_KERNEL_CMDLINE)" - INTERNAL_BVBTOOL_MAKE_BOOT_IMAGE_ARGS += --kernel_cmdline "$(BOARD_KERNEL_CMDLINE)" -endif - BOARD_KERNEL_BASE := $(strip $(BOARD_KERNEL_BASE)) ifdef BOARD_KERNEL_BASE INTERNAL_BOOTIMAGE_ARGS += --base $(BOARD_KERNEL_BASE) @@ -534,6 +528,25 @@ ifdef BOARD_KERNEL_PAGESIZE INTERNAL_BOOTIMAGE_ARGS += --pagesize $(BOARD_KERNEL_PAGESIZE) endif +ifeq ($(PRODUCTS.$(INTERNAL_PRODUCT).PRODUCT_SUPPORTS_VERITY),true) +ifeq ($(BOARD_BUILD_SYSTEM_ROOT_IMAGE),true) +VERITY_KEYID := veritykeyid=id:`openssl x509 -in $(PRODUCTS.$(INTERNAL_PRODUCT).PRODUCT_VERITY_SIGNING_KEY).x509.pem -text \ + | grep keyid | sed 's/://g' | tr -d '[:space:]' | tr '[:upper:]' '[:lower:]' | sed 's/keyid//g'` +endif +endif + +ifeq ($(BOARD_BVB_ENABLE),true) +BOARD_KERNEL_CMDLINE := $(strip $(BOARD_KERNEL_CMDLINE)) +ifdef BOARD_KERNEL_CMDLINE + INTERNAL_BVBTOOL_MAKE_BOOT_IMAGE_ARGS += --kernel_cmdline "$(BOARD_KERNEL_CMDLINE)" +endif +else +BOARD_KERNEL_CMDLINE := $(strip $(BOARD_KERNEL_CMDLINE) $(VERITY_KEYID)) +ifdef BOARD_KERNEL_CMDLINE +INTERNAL_BOOTIMAGE_ARGS += --cmdline "$(BOARD_KERNEL_CMDLINE)" +endif +endif + INTERNAL_MKBOOTIMG_VERSION_ARGS := \ --os_version $(PLATFORM_VERSION) \ --os_patch_level $(PLATFORM_SECURITY_PATCH)