#
# Copyright (c) [2020], MediaTek Inc. All rights reserved.
#
# This software/firmware and related documentation ("MediaTek Software") are
# protected under relevant copyright laws.
# The information contained herein is confidential and proprietary to
# MediaTek Inc. and/or its licensors.
# Except as otherwise provided in the applicable licensing terms with
# MediaTek Inc. and/or its licensors, any reproduction, modification, use or
# disclosure of MediaTek Software, and information contained herein, in whole
# or in part, shall be strictly prohibited.
#

UBOOTINCLUDE += -I$(srctree)/Mediatek-internal/impl/upgrade/include/secure/ \
		-I$(srctree)/Mediatek-internal/impl/system/include/ \
		-I$(srctree)/Customization/$(CUSTOMER)/console_lock/include/ \
		-I$(srctree)/Mediatek-internal/impl/upgrade/include/ \
		-I$(srctree)/Mediatek-internal/secure/

PLATFORM_CPPFLAGS += -DCONSOLE_LOCK_ENABLE

ifneq ($(UBOOT_CONSOLE_LOCK_PRJOECT_NAME),)
PLATFORM_CPPFLAGS += -DAN_BUILD_PROJ=$(UBOOT_CONSOLE_LOCK_PRJOECT_NAME)
endif

ccflags-y += -Werror -Wno-pointer-sign

PLATFORM_CPPFLAGS += -DMINI_GMP_UBOOT_PORTING
PLATFORM_CPPFLAGS += -DMINI_GMP_DONT_USE_FLOAT_H
#PLATFORM_CPPFLAGS += -DCMD_CE_DEBUG
PLATFORM_CPPFLAGS += -DCE_STORAGE_USE_OFFSET

obj-y += src/ce_impl.o
obj-y += src/console_impl.o
obj-y += src/ta_rpmb_impl.o
#obj-y += src/ce_test_impl.o
obj-y += src/mini-gmp.o
obj-y += src/bootenv_impl.o
obj-y += src/storage_offset_impl.o
obj-y += src/ce_ops_impl.o

obj-y += cmd/cmd_ce.o
obj-y += cmd/cmd_console_lock.o
obj-y += cmd/cmd_usbboot_check.o
#obj-y += cmd/cmd_ce_test.o
