From f2140ea87306a4da8fcb3332fd644210fa224f24 Mon Sep 17 00:00:00 2001 From: Cyan_Hsieh Date: Thu, 18 Apr 2024 16:01:02 +0800 Subject: [PATCH] Switch bootloader directory to control by build flag Bug: 333834221 Change-Id: I045c65830b8c04dff0720e509108659d45a400ac --- cheetah/BoardConfig.mk | 12 +++--------- cloudripper/BoardConfig.mk | 12 +++--------- device-cheetah.mk | 18 ------------------ device-cloudripper.mk | 9 --------- device-panther.mk | 18 ------------------ device-ravenclaw.mk | 18 ------------------ panther/BoardConfig.mk | 12 +++--------- ravenclaw/BoardConfig.mk | 12 +++--------- 8 files changed, 12 insertions(+), 99 deletions(-) diff --git a/cheetah/BoardConfig.mk b/cheetah/BoardConfig.mk index 26a5563..e2b74b6 100644 --- a/cheetah/BoardConfig.mk +++ b/cheetah/BoardConfig.mk @@ -18,15 +18,9 @@ BOARD_BOOTCONFIG += androidboot.load_modules_parallel=true RELEASE_GOOGLE_PRODUCT_RADIO_DIR := $(RELEASE_GOOGLE_CHEETAH_RADIO_DIR) -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q3 -else -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/trunk -endif +RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR ?= trunk # Keep this for pdk TODO: b/327119000 +RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR) +$(call soong_config_set,bootloader,prebuilt_dir,$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR)) # The modules which need to be loaded in sequential BOARD_KERNEL_CMDLINE += exynos_drm.load_sequential=1 diff --git a/cloudripper/BoardConfig.mk b/cloudripper/BoardConfig.mk index 39410c9..33e7706 100644 --- a/cloudripper/BoardConfig.mk +++ b/cloudripper/BoardConfig.mk @@ -15,15 +15,9 @@ # TARGET_BOARD_INFO_FILE := device/google/pantah/board-info.txt TARGET_BOOTLOADER_BOARD_NAME := cloudripper -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q3 -else -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/trunk -endif +RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR ?= trunk # Keep this for pdk TODO: b/327119000 +RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR) +$(call soong_config_set,bootloader,prebuilt_dir,$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR)) TARGET_SCREEN_DENSITY := 440 BOARD_USES_GENERIC_AUDIO := true USES_DEVICE_GOOGLE_CLOUDRIPPER := true diff --git a/device-cheetah.mk b/device-cheetah.mk index ecf1b42..d843668 100644 --- a/device-cheetah.mk +++ b/device-cheetah.mk @@ -280,15 +280,6 @@ PRODUCT_SOONG_NAMESPACES += \ # Fingerprint HAL GOODIX_CONFIG_BUILD_VERSION := g7_trusty -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/trunk -endif $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_common.mk) ifeq ($(filter factory%, $(TARGET_PRODUCT)),) $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_shipping.mk) @@ -304,15 +295,6 @@ PRODUCT_SOONG_NAMESPACES += device/google/pantah/cheetah/ # Trusty liboemcrypto.so PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/trunk -endif # Location ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) diff --git a/device-cloudripper.mk b/device-cloudripper.mk index 579133a..4286433 100644 --- a/device-cloudripper.mk +++ b/device-cloudripper.mk @@ -156,15 +156,6 @@ PRODUCT_SOONG_NAMESPACES += device/google/pantah/cheetah/ # Trusty liboemcrypto.so PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/trunk -endif # Location ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) diff --git a/device-panther.mk b/device-panther.mk index 71874b9..8919ae2 100644 --- a/device-panther.mk +++ b/device-panther.mk @@ -260,15 +260,6 @@ PRODUCT_SOONG_NAMESPACES += \ # Fingerprint HAL GOODIX_CONFIG_BUILD_VERSION := g7_trusty -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/trunk -endif $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_common.mk) ifeq ($(filter factory%, $(TARGET_PRODUCT)),) $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_shipping.mk) @@ -288,15 +279,6 @@ PRODUCT_SOONG_NAMESPACES += device/google/pantah/panther/ # Trusty liboemcrypto.so PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/trunk -endif # Location ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) diff --git a/device-ravenclaw.mk b/device-ravenclaw.mk index a0ccfba..19f0afc 100644 --- a/device-ravenclaw.mk +++ b/device-ravenclaw.mk @@ -146,15 +146,6 @@ PRODUCT_SOONG_NAMESPACES += \ # Fingerprint HAL GOODIX_CONFIG_BUILD_VERSION := g6_trusty -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/firmware/fingerprint/trunk -endif $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_common.mk) ifeq ($(filter factory%, $(TARGET_PRODUCT)),) $(call inherit-product-if-exists, vendor/goodix/udfps/configuration/udfps_shipping.mk) @@ -171,15 +162,6 @@ PRODUCT_SOONG_NAMESPACES += device/google/pantah/cheetah/ # Trusty liboemcrypto.so PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/24Q3 -else -PRODUCT_SOONG_NAMESPACES += vendor/google_devices/pantah/prebuilts/trusty/trunk -endif # Location ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) diff --git a/panther/BoardConfig.mk b/panther/BoardConfig.mk index b4ff5a7..69ca934 100644 --- a/panther/BoardConfig.mk +++ b/panther/BoardConfig.mk @@ -21,15 +21,9 @@ BOARD_BOOTCONFIG += androidboot.load_modules_parallel=true BOARD_KERNEL_CMDLINE += exynos_drm.load_sequential=1 RELEASE_GOOGLE_PRODUCT_RADIO_DIR := $(RELEASE_GOOGLE_PANTHER_RADIO_DIR) -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q3 -else -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/trunk -endif +RELEASE_GOOGLE_BOOTLOADER_PANTHER_DIR ?= trunk # Keep this for pdk TODO: b/327119000 +RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/$(RELEASE_GOOGLE_BOOTLOADER_PANTHER_DIR) +$(call soong_config_set,bootloader,prebuilt_dir,$(RELEASE_GOOGLE_BOOTLOADER_PANTHER_DIR)) ifdef PHONE_CAR_BOARD_PRODUCT include device/google_car/$(PHONE_CAR_BOARD_PRODUCT)/BoardConfig.mk diff --git a/ravenclaw/BoardConfig.mk b/ravenclaw/BoardConfig.mk index 861cc28..722dbc6 100644 --- a/ravenclaw/BoardConfig.mk +++ b/ravenclaw/BoardConfig.mk @@ -15,15 +15,9 @@ # TARGET_BOARD_INFO_FILE := device/google/pantah/board-info.txt TARGET_BOOTLOADER_BOARD_NAME := ravenclaw -ifneq (,$(filter AP1%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q1 -else ifneq (,$(filter AP2%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q2 -else ifneq (,$(filter AP3%,$(RELEASE_PLATFORM_VERSION))) -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/24Q3 -else -RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/trunk -endif +RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR ?= trunk # Keep this for pdk TODO: b/327119000 +RELEASE_GOOGLE_PRODUCT_BOOTLOADER_DIR := bootloader/$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR) +$(call soong_config_set,bootloader,prebuilt_dir,$(RELEASE_GOOGLE_BOOTLOADER_CHEETAH_DIR)) TARGET_SCREEN_DENSITY := 560 BOARD_USES_GENERIC_AUDIO := true USES_DEVICE_GOOGLE_CLOUDRIPPER := true