Commit 4ac3ae2c authored by Stylogey's avatar Stylogey Committed by prady

sdm660-common: move A/B stuff to common

Change-Id: I8770ea03a27f96e04daedaf021906842c0bcebce
parent fc5d4c34
......@@ -25,6 +25,18 @@
# Common Tree Path
COMMON_PATH := device/xiaomi/sdm660-common
# A/B
ifeq ($(ENABLE_AB), true)
AB_OTA_UPDATER := true
AB_OTA_PARTITIONS ?= \
boot \
system \
vendor
BOARD_BUILD_SYSTEM_ROOT_IMAGE := true
BOARD_USES_RECOVERY_AS_BOOT := true
TARGET_NO_RECOVERY := true
endif
# ANT+
BOARD_ANT_WIRELESS_DEVICE := "qualcomm-hidl"
......@@ -164,7 +176,7 @@ BOARD_USES_METADATA_PARTITION := true
# Partitions
BOARD_FLASH_BLOCK_SIZE := 262144
BOARD_BOOTIMAGE_PARTITION_SIZE := 67108864
ifneq ($(AB_OTA_UPDATER), true)
ifneq ($(ENABLE_AB), true)
BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE := ext4
BOARD_CACHEIMAGE_PARTITION_SIZE := 268435456
BOARD_RECOVERYIMAGE_PARTITION_SIZE := 67108864
......@@ -200,7 +212,7 @@ TARGET_USES_QCOM_BSP := false
# Recovery
ifneq ($(filter lavender,$(TARGET_DEVICE)),)
TARGET_RECOVERY_FSTAB := $(COMMON_PATH)/rootdir/etc/fstab_A.qcom
else ifeq ($(AB_OTA_UPDATER), true)
else ifeq ($(ENABLE_AB), true)
TARGET_RECOVERY_FSTAB := $(COMMON_PATH)/rootdir/etc/fstab_AB.qcom
else
TARGET_RECOVERY_FSTAB := $(COMMON_PATH)/rootdir/etc/fstab.qcom
......
......@@ -105,7 +105,7 @@ LOCAL_MODULE_TAGS := optional
LOCAL_MODULE_CLASS := ETC
ifneq ($(filter lavender,$(TARGET_DEVICE)),)
LOCAL_SRC_FILES := etc/fstab_A.qcom
else ifeq ($(AB_OTA_UPDATER), true)
else ifeq ($(ENABLE_AB), true)
LOCAL_SRC_FILES := etc/fstab_AB.qcom
else
LOCAL_SRC_FILES := etc/fstab.qcom
......
......@@ -40,6 +40,42 @@ COMMON_PATH := device/xiaomi/sdm660-common
# Inherit properties
$(call inherit-product, $(COMMON_PATH)/common_prop.mk)
# A/B
ifeq ($(ENABLE_AB), true)
AB_OTA_POSTINSTALL_CONFIG += \
RUN_POSTINSTALL_system=true \
POSTINSTALL_PATH_system=system/bin/otapreopt_script \
FILESYSTEM_TYPE_system=ext4 \
POSTINSTALL_OPTIONAL_system=true
PRODUCT_PACKAGES += \
otapreopt_script
# Boot control
PRODUCT_PACKAGES += \
android.hardware.boot@1.0-impl \
android.hardware.boot@1.0-impl.recovery \
android.hardware.boot@1.0-service \
bootctrl.sdm660 \
bootctrl.sdm660.recovery
# Boot control debug
PRODUCT_PACKAGES_DEBUG += \
bootctl
# Update engine
PRODUCT_PACKAGES += \
update_engine \
update_engine_sideload \
update_verifier
PRODUCT_HOST_PACKAGES += \
brillo_update_payload
PRODUCT_PACKAGES_DEBUG += \
update_engine_client
endif
# Audio
PRODUCT_PACKAGES += \
android.hardware.audio@5.0-impl \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment