summaryrefslogtreecommitdiffstats
path: root/meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb
diff options
context:
space:
mode:
authorAymeric Aillet <aymeric.aillet@iot.bzh>2019-09-20 16:48:04 +0200
committerAymeric Aillet <aymeric.aillet@iot.bzh>2019-12-10 10:46:04 +0100
commit42c95e5aee43e943ef581fb60263f3b77ad47c60 (patch)
tree29643348f28db5b4f39b5174561305046358da94 /meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb
parenta63ad959fed4b4afecda33165202e5643bb3f815 (diff)
[Community] Add optee packages recipesicefish_8.99.3icefish/8.99.38.99.3
Allow us to use the xtest suite and examples in order to test the functionning of optee. More information on the optee official website. Add a user-app example. Allow us to build a custom app working in both optee side. Fix optee examples recipe. Allow us to to access functions from examples TA's from other apps. BUG-AGL: SPEC-3030 Change-Id: I28f2c117dfa7a66ef2ebc0ede2ec32d7b218b549 Signed-off-by: Aymeric Aillet <aymeric.aillet@iot.bzh>
Diffstat (limited to 'meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb')
-rw-r--r--meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb55
1 files changed, 55 insertions, 0 deletions
diff --git a/meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb b/meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb
new file mode 100644
index 0000000..ea58e24
--- /dev/null
+++ b/meta-rcar-gen3/recipes-bsp/optee/optee-test_git.bb
@@ -0,0 +1,55 @@
+DESCRIPTION = "OP-TEE TEST"
+
+LICENSE = "GPLv2 & BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://${S}/host/LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+inherit pythonnative
+
+PV = "3.1.0+git${SRCPV}"
+
+SRCREV = "45218eb59b006ad20cc7610904f291dd85157a43"
+
+SRC_URI = " \
+ git://github.com/OP-TEE/optee_test.git;branch=master;name=master \
+ file://optee_xtest_fix.diff \
+"
+
+COMPATIBLE_MACHINE = "(salvator-x|h3ulcb|m3ulcb|m3nulcb|ebisu)"
+PLATFORM = "rcar"
+
+DEPENDS = "optee-os optee-client python-pycrypto-native"
+
+export CROSS_COMPILE64="${TARGET_PREFIX}"
+
+# Let the Makefile handle setting up the flags as it is a standalone application
+LD[unexport] = "1"
+LDFLAGS[unexport] = "1"
+export CCcore="${CC}"
+export LDcore="${LD}"
+libdir[unexport] = "1"
+
+CFLAGS += "-Wno-extra -Wno-error=stringop-overflow -Wno-error=array-bounds"
+TARGET_CFLAGS += "-Wno-extra -Wno-error=stringop-overflow -Wno-error=array-bounds"
+
+TARGET_CC_ARCH += "${LDFLAGS}"
+INSANE_SKIP_${PN} = "ldflags"
+
+S = "${WORKDIR}/git"
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+do_compile() {
+ oe_runmake CROSS_COMPILE=${CROSS_COMPILE64} PLATFORM=${PLATFORM} OPTEE_CLIENT_EXPORT=${STAGING_DIR_TARGET}/usr --no-builtin-variables TA_DEV_KIT_DIR="${STAGING_DIR_TARGET}/usr/share/optee/export-ta_arm64"
+}
+
+do_install () {
+ install -D -p -m0755 ${S}/out/xtest/xtest ${D}${bindir}/xtest
+
+ # install path should match the value set in optee-client/tee-supplicant
+ # default TEEC_LOAD_PATH is /lib
+ mkdir -p ${D}${nonarch_base_libdir}/optee_armtz/
+ install -D -p -m0444 ${S}/out/ta/*/*.ta ${D}${nonarch_base_libdir}/optee_armtz/
+}
+
+FILES_${PN} += "${nonarch_base_libdir}/optee_armtz/"