From 664f02a60c98536e516ba8a802bceba40418a34c Mon Sep 17 00:00:00 2001 From: Kory Maincent Date: Thu, 11 Jul 2024 11:27:28 +0200 Subject: [PATCH] boot/optee-os: Add support to build with host-cmake Some specific versions of OP-TEE need cmake on the host to build the scmi firmware, like the newly release STMicroelectronics 3.19.0-stm32mp-r2 version. To allow building such OP-TEE OS versions, this commit adds the option BR2_TARGET_OPTEE_OS_NEEDS_CMAKE which when enabled ensures that host-cmake is built before OP-TEE OS. Signed-off-by: Kory Maincent [Arnout: use BR2_CMAKE_HOST_DEPENDENCY] Signed-off-by: Arnout Vandecappelle --- boot/optee-os/Config.in | 6 ++++++ boot/optee-os/optee-os.mk | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/boot/optee-os/Config.in b/boot/optee-os/Config.in index 34ea993136..7870629732 100644 --- a/boot/optee-os/Config.in +++ b/boot/optee-os/Config.in @@ -91,6 +91,12 @@ config BR2_TARGET_OPTEE_OS_NEEDS_PYTHON_CRYPTOGRAPHY python-cryptography. Select this option if optee-os needs python-cryptography to be built. +config BR2_TARGET_OPTEE_OS_NEEDS_CMAKE + bool "OP-TEE OS needs cmake" + help + Select this option if your OP-TEE OS platform configuration + requires the cmake build system to be available. + config BR2_TARGET_OPTEE_OS_CORE bool "Build core" default y diff --git a/boot/optee-os/optee-os.mk b/boot/optee-os/optee-os.mk index 33b4e2e1ab..6b04a0f5e1 100644 --- a/boot/optee-os/optee-os.mk +++ b/boot/optee-os/optee-os.mk @@ -30,6 +30,10 @@ endif OPTEE_OS_DEPENDENCIES = host-openssl host-python3 host-python-pyelftools +ifeq ($(BR2_TARGET_OPTEE_OS_NEEDS_CMAKE),y) +OPTEE_OS_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) +endif + ifeq ($(BR2_TARGET_OPTEE_OS_NEEDS_PYTHON_CRYPTOGRAPHY),y) OPTEE_OS_DEPENDENCIES += host-python-cryptography else