Skip to contentSkip to conversation

optee: use CFLAGS{32,64} to pass --sysroot

PATCH Applied Jerome Forissier 2 participants 2 messages Aug 9, 2022 – Aug 15, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 optee: use CFLAGS{32,64} to pass --sysroot

Since upstream OP-TEE 3.16.0, CFLAGS32 and CFLAGS64 can be used to set the sysroot option that previously required the LIBGCC_LOCATE_CFLAGS patches.

---
 meta-arm/recipes-security/optee/optee-os_3.14.0.bb | 2 ++
 meta-arm/recipes-security/optee/optee-os_3.16.0.bb | 5 -----
 meta-arm/recipes-security/optee/optee.inc          | 3 ++-
 3 files changed, 4 insertions(+), 6 deletions(-)
meta-arm/recipes-security/optee/optee-os_3.14.0.bb +2 -0
index 92e1f88..88f683c 100644
@@ -7,3 +7,5 @@ SRC_URI:append = " \
     file://0007-allow-setting-sysroot-for-clang.patch \
 "
 DEPENDS = "python3-pycryptodome-native python3-pyelftools-native"
+
+EXTRA_OEMAKE += "LIBGCC_LOCATE_CFLAGS=--sysroot=${STAGING_DIR_HOST}"
meta-arm/recipes-security/optee/optee-os_3.16.0.bb +0 -5
index 873e964..ec83100 100644
@@ -1,8 +1,3 @@
 require optee-os.inc
 
 SRCREV = "d0b742d1564834dac903f906168d7357063d5459"
-
-SRC_URI:append = " \
-    file://0006-allow-setting-sysroot-for-libgcc-lookup.patch \
-    file://0007-allow-setting-sysroot-for-clang.patch \
-"
meta-arm/recipes-security/optee/optee.inc +2 -1
index 2ad7c95..417f56f 100644
@@ -21,7 +21,8 @@ OPTEE_COMPILER = "${@bb.utils.contains("BBFILE_COLLECTIONS", "clang-layer", "${O
 TA_DEV_KIT_DIR = "${STAGING_INCDIR}/optee/export-user_ta"
 
 EXTRA_OEMAKE += "V=1 \
-                 LIBGCC_LOCATE_CFLAGS=--sysroot=${STAGING_DIR_HOST} \
+                 CFLAGS32=--sysroot=${STAGING_DIR_HOST} \
+                 CFLAGS64=--sysroot=${STAGING_DIR_HOST} \
                  COMPILER=${OPTEE_COMPILER} \
                  OPTEE_CLIENT_EXPORT=${STAGING_DIR_HOST}${prefix} \
                  TEEC_EXPORT=${STAGING_DIR_HOST}${prefix} \
Signature · 1 line
2.34.1
Applied
#1 lore raw
Quoted 3 lines · Jerome Forissier

Since upstream OP-TEE 3.16.0, CFLAGS32 and CFLAGS64 can be used to set the sysroot option that previously required the LIBGCC_LOCATE_CFLAGS patches.

Applied, thanks!

[1/1] optee: use CFLAGS{32,64} to pass --sysroot

      commit: f2781a9c8df0e9b09c6cac498e506ce2f882c2d6

Best regards,

Signature · 1 line
Jon Mason <[email protected]>