From patchwork Mon Oct 20 15:09:22 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Mason X-Patchwork-Id: 72723 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id D534ECCD1A4 for ; Mon, 20 Oct 2025 15:09:37 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web10.21330.1760972967966911203 for ; Mon, 20 Oct 2025 08:09:28 -0700 Authentication-Results: mx.groups.io; dkim=none (message not signed); spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: jon.mason@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id C10B51063 for ; Mon, 20 Oct 2025 08:09:19 -0700 (PDT) Received: from H24V3P4C17.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 4F4593F66E for ; Mon, 20 Oct 2025 08:09:27 -0700 (PDT) From: Jon Mason To: meta-arm@lists.yoctoproject.org Subject: [PATCH 3/5] arm/optee-ftpm: enable clang compilation Date: Mon, 20 Oct 2025 16:09:22 +0100 Message-ID: <20251020150924.84223-3-jon.mason@arm.com> X-Mailer: git-send-email 2.50.1 In-Reply-To: <20251020150924.84223-1-jon.mason@arm.com> References: <20251020150924.84223-1-jon.mason@arm.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Mon, 20 Oct 2025 15:09:37 -0000 X-Groupsio-URL: https://lists.yoctoproject.org/g/meta-arm/message/6741 Remove the forcing of GCC in the recipe, and make the changes necessary to get clang working. Signed-off-by: Jon Mason --- meta-arm/recipes-security/optee-ftpm/optee-ftpm_4.7.0.bb | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/meta-arm/recipes-security/optee-ftpm/optee-ftpm_4.7.0.bb b/meta-arm/recipes-security/optee-ftpm/optee-ftpm_4.7.0.bb index 756aeec6d6a1..9164f31bbc91 100644 --- a/meta-arm/recipes-security/optee-ftpm/optee-ftpm_4.7.0.bb +++ b/meta-arm/recipes-security/optee-ftpm/optee-ftpm_4.7.0.bb @@ -8,16 +8,14 @@ COMPATIBLE_MACHINE:qemuarm64 = "qemuarm64" COMPATIBLE_MACHINE:qemuarm64-secureboot = "qemuarm64" COMPATIBLE_MACHINE:qemuarm-secureboot = "qemuarm" -#FIXME - doesn't currently work with clang -TOOLCHAIN = "gcc" - inherit deploy python3native LICENSE = "MIT" LIC_FILES_CHKSUM = "file://LICENSE;md5=5a3925ece0806073ae9ebbb08ff6f11e" LIC_FILES_CHKSUM += "file://optee-ta/LICENSE;md5=5a3925ece0806073ae9ebbb08ff6f11e" -DEPENDS = "python3-pyelftools-native optee-os-tadevkit python3-cryptography-native " +DEPENDS = "python3-pyelftools-native optee-os-tadevkit python3-cryptography-native" +DEPENDS:append:toolchain-clang = " lld-native" FTPM_UUID = "bc50d971-d4c9-42c4-82cb-343fb7f37896" @@ -49,6 +47,7 @@ TEEC_EXPORT = "${STAGING_DIR_HOST}${prefix}" TA_DEV_KIT_DIR = "${STAGING_INCDIR}/optee/export-user_ta" EXTRA_OEMAKE += '\ + COMPILER=${TOOLCHAIN} \ TA_DEV_KIT_DIR=${TA_DEV_KIT_DIR} \ CROSS_COMPILE=${TARGET_PREFIX} \ CFG_MS_TPM_20_REF="${S}" \ @@ -59,6 +58,8 @@ EXTRA_OEMAKE:append:aarch64:qemuall = "\ CFG_ARM64_ta_arm64=y \ " +CFLAGS:append:toolchain-clang = " -Wno-unknown-warning-option" + # python3-cryptography needs the legacy provider, so set OPENSSL_MODULES to the # right path until this is relocated automatically. export OPENSSL_MODULES = "${STAGING_LIBDIR_NATIVE}/ossl-modules"