Skip to content
Snippets Groups Projects
Commit 02ee5fb9 authored by SY Chiu's avatar SY Chiu Committed by Joakim Bech
Browse files

mt8173: add build script for ARM-TF


Signed-off-by: default avatarSY Chiu <sy.chiu@linaro.org>
Tested-by: SY Chiu <sy.chiu@linaro.org> (MT8173 EVB)
Tested-by: Joakim Bech <joakim.bech@linaro.org> (MT8173 EVB)
Reviewed-by: default avatarJoakim Bech <joakim.bech@linaro.org>
parent 2c5101ae
No related branches found
No related tags found
No related merge requests found
...@@ -14,18 +14,38 @@ override COMPILE_S_KERNEL := 64 ...@@ -14,18 +14,38 @@ override COMPILE_S_KERNEL := 64
# Paths to git projects and various binaries # Paths to git projects and various binaries
################################################################################ ################################################################################
MTK_TOOLS_PATH ?= $(ROOT)/mtk_tools MTK_TOOLS_PATH ?= $(ROOT)/mtk_tools
ARM_TF_PATH ?= $(ROOT)/arm-trusted-firmware
OPTEE_OS_PAGER_BIN ?= $(OPTEE_OS_PATH)/out/arm/core/tee-pager.bin OPTEE_OS_PAGER_BIN ?= $(OPTEE_OS_PATH)/out/arm/core/tee-pager.bin
ARM_TF_BIN ?= $(ARM_TF_PATH)/build/mt8173/debug/bl31.bin
################################################################################ ################################################################################
# Targets # Targets
################################################################################ ################################################################################
all: linux optee-os optee-client optee-linuxdriver xtest all: arm-tf linux optee-os optee-client optee-linuxdriver xtest
all-clean: linux-clean busybox-clean optee-os-clean \ all-clean: arm-tf-clean linux-clean busybox-clean optee-os-clean \
optee-client-clean optee-linuxdriver-clean optee-client-clean optee-linuxdriver-clean
-include toolchain.mk -include toolchain.mk
################################################################################
# ARM Trusted Firmware
################################################################################
ARM_TF_EXPORTS ?= \
CFLAGS="-O0 -gdwarf-2" \
CROSS_COMPILE="$(CCACHE)$(AARCH64_NONE_CROSS_COMPILE)"
ARM_TF_FLAGS ?= \
DEBUG=1 \
PLAT=mt8173 \
SPD=opteed
arm-tf: optee-os
$(ARM_TF_EXPORTS) $(MAKE) -C $(ARM_TF_PATH) $(ARM_TF_FLAGS) all
arm-tf-clean:
$(ARM_TF_EXPORTS) $(MAKE) -C $(ARM_TF_PATH) $(ARM_TF_FLAGS) clean
################################################################################ ################################################################################
# Busybox # Busybox
################################################################################ ################################################################################
...@@ -125,7 +145,7 @@ update_rootfs: busybox optee-client optee-linuxdriver xtest filelist-tee ...@@ -125,7 +145,7 @@ update_rootfs: busybox optee-client optee-linuxdriver xtest filelist-tee
.PHONY: build_image flash_image run .PHONY: build_image flash_image run
build-image: update_rootfs optee-os build-image: update_rootfs optee-os
cd $(MTK_TOOLS_PATH); \ cd $(MTK_TOOLS_PATH); \
./build_trustzone.sh $(OPTEE_OS_PAGER_BIN); \ ./build_trustzone.sh $(OPTEE_OS_PAGER_BIN) $(ARM_TF_BIN); \
./build_bootimg.sh $(LINUX_PATH) $(GEN_ROOTFS_PATH)/filesystem.cpio.gz ./build_bootimg.sh $(LINUX_PATH) $(GEN_ROOTFS_PATH)/filesystem.cpio.gz
flash-image: build-image flash-image: build-image
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment