1*4882a593Smuzhiyun################################################################################ 2*4882a593Smuzhiyun# 3*4882a593Smuzhiyun# optee-examples 4*4882a593Smuzhiyun# 5*4882a593Smuzhiyun################################################################################ 6*4882a593Smuzhiyun 7*4882a593SmuzhiyunOPTEE_EXAMPLES_VERSION = 3.15.0 8*4882a593SmuzhiyunOPTEE_EXAMPLES_SITE = $(call github,linaro-swg,optee_examples,$(OPTEE_EXAMPLES_VERSION)) 9*4882a593SmuzhiyunOPTEE_EXAMPLES_LICENSE = BSD-2-Clause 10*4882a593SmuzhiyunOPTEE_EXAMPLES_LICENSE_FILES = LICENSE 11*4882a593Smuzhiyun 12*4882a593SmuzhiyunOPTEE_EXAMPLES_DEPENDENCIES = optee-client optee-os 13*4882a593Smuzhiyun 14*4882a593Smuzhiyun# Trusted Application are not built from CMake due to ta_dev_kit dependencies. 15*4882a593Smuzhiyun# We must build and install them on target. 16*4882a593Smuzhiyundefine OPTEE_EXAMPLES_BUILD_TAS 17*4882a593Smuzhiyun $(foreach f,$(wildcard $(@D)/*/ta/Makefile), \ 18*4882a593Smuzhiyun $(TARGET_CONFIGURE_OPTS) \ 19*4882a593Smuzhiyun $(MAKE) CROSS_COMPILE=$(TARGET_CROSS) \ 20*4882a593Smuzhiyun TA_DEV_KIT_DIR=$(OPTEE_OS_SDK) \ 21*4882a593Smuzhiyun O=out -C $(dir $f) all 22*4882a593Smuzhiyun ) 23*4882a593Smuzhiyunendef 24*4882a593Smuzhiyundefine OPTEE_EXAMPLES_INSTALL_TAS 25*4882a593Smuzhiyun @mkdir -p $(TARGET_DIR)/lib/optee_armtz 26*4882a593Smuzhiyun @$(INSTALL) -D -m 444 -t $(TARGET_DIR)/lib/optee_armtz $(@D)/*/ta/out/*.ta 27*4882a593Smuzhiyunendef 28*4882a593SmuzhiyunOPTEE_EXAMPLES_POST_BUILD_HOOKS += OPTEE_EXAMPLES_BUILD_TAS 29*4882a593SmuzhiyunOPTEE_EXAMPLES_POST_INSTALL_TARGET_HOOKS += OPTEE_EXAMPLES_INSTALL_TAS 30*4882a593Smuzhiyun 31*4882a593Smuzhiyun$(eval $(cmake-package)) 32