summaryrefslogtreecommitdiffstats
path: root/recipes-security/optee-imx/optee-os_3.19.0.imx.bb
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-security/optee-imx/optee-os_3.19.0.imx.bb')
-rw-r--r--recipes-security/optee-imx/optee-os_3.19.0.imx.bb19
1 files changed, 18 insertions, 1 deletions
diff --git a/recipes-security/optee-imx/optee-os_3.19.0.imx.bb b/recipes-security/optee-imx/optee-os_3.19.0.imx.bb
index f5e727b3..82751a80 100644
--- a/recipes-security/optee-imx/optee-os_3.19.0.imx.bb
+++ b/recipes-security/optee-imx/optee-os_3.19.0.imx.bb
@@ -8,8 +8,13 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=c1f21c4f72f372ef38a5a4aee55ec173"
8 8
9DEPENDS = "python3-pyelftools-native u-boot-mkimage-native \ 9DEPENDS = "python3-pyelftools-native u-boot-mkimage-native \
10 python3-cryptography-native" 10 python3-cryptography-native"
11DEPENDS:append:toolchain-clang = " compiler-rt"
11 12
12SRC_URI = "git://github.com/nxp-imx/imx-optee-os.git;protocol=https;branch=${SRCBRANCH}" 13SRC_URI = "git://github.com/nxp-imx/imx-optee-os.git;protocol=https;branch=${SRCBRANCH} \
14 file://0001-core-Define-section-attributes-for-clang.patch \
15 file://0006-allow-setting-sysroot-for-libgcc-lookup.patch \
16 file://0007-allow-setting-sysroot-for-clang.patch \
17 file://0010-add-note-GNU-stack-section.patch"
13SRCBRANCH = "lf-5.15.71_2.2.0" 18SRCBRANCH = "lf-5.15.71_2.2.0"
14SRCREV = "00919403f040fad4f8603e605932281ff8451b1d" 19SRCREV = "00919403f040fad4f8603e605932281ff8451b1d"
15 20
@@ -44,6 +49,9 @@ PLATFORM_FLAVOR:mx93-nxp-bsp = "mx93evk"
44OPTEE_ARCH:arm = "arm32" 49OPTEE_ARCH:arm = "arm32"
45OPTEE_ARCH:aarch64 = "arm64" 50OPTEE_ARCH:aarch64 = "arm64"
46 51
52COMPILER ?= "gcc"
53COMPILER:toolchain-clang = "clang"
54
47# Optee-os can be built for 32 bits and 64 bits at the same time 55# Optee-os can be built for 32 bits and 64 bits at the same time
48# as long as the compilers are correctly defined. 56# as long as the compilers are correctly defined.
49# For 64bits, CROSS_COMPILE64 must be set 57# For 64bits, CROSS_COMPILE64 must be set
@@ -56,15 +64,24 @@ EXTRA_OEMAKE = " \
56 CFG_TEE_TA_LOG_LEVEL=0 \ 64 CFG_TEE_TA_LOG_LEVEL=0 \
57 CFG_TEE_CORE_LOG_LEVEL=0 \ 65 CFG_TEE_CORE_LOG_LEVEL=0 \
58 OPENSSL_MODULES=${STAGING_LIBDIR_NATIVE}/ossl-modules \ 66 OPENSSL_MODULES=${STAGING_LIBDIR_NATIVE}/ossl-modules \
67 COMPILER=${COMPILER} \
59 -C ${S} O=${B} \ 68 -C ${S} O=${B} \
60" 69"
61 70
62LDFLAGS[unexport] = "1" 71LDFLAGS[unexport] = "1"
72CPPFLAGS[unexport] = "1"
73AS[unexport] = "1"
74LD[unexport] = "1"
75
63CFLAGS += "--sysroot=${STAGING_DIR_HOST}" 76CFLAGS += "--sysroot=${STAGING_DIR_HOST}"
64CXXFLAGS += "--sysroot=${STAGING_DIR_HOST}" 77CXXFLAGS += "--sysroot=${STAGING_DIR_HOST}"
65 78
66do_configure[noexec] = "1" 79do_configure[noexec] = "1"
67 80
81do_compile:prepend() {
82 PLAT_LIBGCC_PATH=$(${CC} -print-libgcc-file-name)
83}
84
68do_compile:arm () { 85do_compile:arm () {
69 oe_runmake all uTee 86 oe_runmake all uTee
70} 87}