You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
105 lines
3.1 KiB
105 lines
3.1 KiB
AOSP_PLATFORM_VERSION ?= 12
|
|
ifdef CFG_ADVCA_AVB
|
|
|
|
ORIGINAL_AVB_DIR := $(shell cd $(VENDOR_DIR)/../external/avb && pwd)
|
|
NEW_AVB_DIR := $(shell cd $(SDK_DIR)/source/apps/avb && pwd)
|
|
|
|
$(shell ln -snf $(ORIGINAL_AVB_DIR)/libavb $(NEW_AVB_DIR)/libavb)
|
|
$(shell ln -snf $(ORIGINAL_AVB_DIR)/libavb_ab $(NEW_AVB_DIR)/libavb_ab)
|
|
$(shell ln -snf $(ORIGINAL_AVB_DIR)/libavb_user $(NEW_AVB_DIR)/libavb_user)
|
|
|
|
ccflags-y += \
|
|
-I$(SDK_DIR)/source/apps/avb/hal/include \
|
|
-I$(SDK_DIR)/source/apps/avb/hal/hal_key_manager \
|
|
-I$(SDK_DIR)/source/apps/include/avb \
|
|
-I$(SDK_DIR)/source/apps/avb/src/common \
|
|
-I$(SDK_DIR)/source/drivers/include/generic \
|
|
-I$(SDK_DIR)/source/drivers/include/cipher \
|
|
-I$(SDK_DIR)/source/drivers/include/klad \
|
|
-I$(SDK_DIR)/source/drivers/include/keyslot \
|
|
-I$(SDK_DIR)/source/drivers/include/flash \
|
|
-I$(VENDOR_DIR)/../external/avb \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb_ab \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb_user
|
|
|
|
ccflags-y += -DAVB_COMPILATION \
|
|
-DAVB_AB_I_UNDERSTAND_LIBAVB_AB_IS_DEPRECATED \
|
|
-DWITH_CIPHER_HASH \
|
|
-DWITH_CIPHER_RSA
|
|
|
|
ifeq ($(CFG_PRODUCT_TYPE),android)
|
|
ccflags-y += -DANDROID_BOOT_SUPPORT
|
|
endif
|
|
obj-y += src/sec_verify.o \
|
|
src/common/verified_common.o \
|
|
hal/hal_cipher/hal_unified_cipher.o \
|
|
hal/hal_flash/hal_flash.o \
|
|
hal/hal_klad/hal_klad.o \
|
|
hal/hal_key_manager/hal_key_manager.o
|
|
ifneq ($(findstring $(CFG_SOCT_CHIP_TYPE), reserved13 reserved9 reserved6 reserved8),)
|
|
obj-y += \
|
|
hal/hal_key_manager/hal_key_manager_v2.o
|
|
endif
|
|
ifneq ($(findstring $(CFG_SOCT_CHIP_TYPE), reserved5 reserved19 reserved17 hi3751v811), )
|
|
obj-y += \
|
|
hal/hal_key_manager/hal_key_manager_v1.o
|
|
endif
|
|
|
|
ifdef CFG_HVB_SUPPORT
|
|
ccflags-y += \
|
|
-I$(SDK_DIR)/source/apps/avb/src/hvb \
|
|
-I$(SDK_DIR)/source/apps/avb/src/user_adapter/hvb
|
|
|
|
ccflags-y += -DCFG_HVB_SUPPORT
|
|
|
|
obj-y += \
|
|
src/hvb/ca_verify.o \
|
|
src/user_adapter/hvb/hvb_ops_user.o
|
|
endif
|
|
|
|
ifdef CFG_AVB_SUPPORT
|
|
ccflags-y += \
|
|
-I$(SDK_DIR)/source/apps/avb/src/avb_ext/sha \
|
|
-I$(SDK_DIR)/source/apps/avb/src/avb_ext/rsa_verify \
|
|
-I$(SDK_DIR)/source/apps/avb/src/sec_verify_adapter \
|
|
-I$(SDK_DIR)/source/apps/avb/src/user_adapter/avb \
|
|
-I$(VENDOR_DIR)/../external/avb \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb_ab \
|
|
-I$(VENDOR_DIR)/../external/avb/libavb_user
|
|
|
|
ccflags-y += -DCFG_AVB_SUPPORT
|
|
|
|
obj-y += \
|
|
src/sec_verify_adapter/sec_verify_adapter.o \
|
|
src/avb_ext/sha/avb_sha256_ext.o \
|
|
src/avb_ext/sha/avb_sha512_ext.o \
|
|
src/avb_ext/rsa_verify/avb_rsa_ext.o \
|
|
src/user_adapter/avb/avb_ops_user.o \
|
|
src/user_adapter/avb/avb_ops_user_ext.o \
|
|
libavb/avb_crypto.o \
|
|
libavb/avb_sysdeps_posix.o \
|
|
libavb/avb_descriptor.o \
|
|
libavb/avb_version.o \
|
|
libavb/avb_crc32.o \
|
|
libavb/avb_util.o \
|
|
libavb/avb_hashtree_descriptor.o \
|
|
libavb/avb_vbmeta_image.o \
|
|
libavb/avb_slot_verify.o \
|
|
libavb/avb_property_descriptor.o \
|
|
libavb/avb_footer.o \
|
|
libavb/avb_hash_descriptor.o \
|
|
libavb/avb_rsa.o \
|
|
libavb/avb_chain_partition_descriptor.o \
|
|
libavb/avb_cmdline.o \
|
|
libavb/avb_kernel_cmdline_descriptor.o \
|
|
libavb_ab/avb_ab_flow.o \
|
|
libavb_user/avb_user_verity.o \
|
|
libavb_user/avb_user_verification.o
|
|
endif
|
|
|
|
else
|
|
obj- += dummy.o
|
|
endif
|