From d60aa68500d33b4bf0a74e94b0ba2e302fb62927 Mon Sep 17 00:00:00 2001 From: Robin Kastberg Date: Mon, 20 Jan 2025 10:30:32 +0000 Subject: [PATCH] cmsis_6: Integrate with zephyr build system ARM has deprecated 5.9.0 and we will need to start using CMSIS_6 to get upstream features and continue supporting tf-m. This commit will integrate it just like CMSIS_5. Signed-off-by: Robin Kastberg Signed-off-by: Sudan Landge --- CMSIS/CMakeLists.txt | 3 +++ CMSIS/Core/CMakeLists.txt | 11 +++++++++++ CMakeLists.txt | 1 + zephyr/module.yml | 3 +++ 4 files changed, 18 insertions(+) create mode 100644 CMSIS/CMakeLists.txt create mode 100644 CMSIS/Core/CMakeLists.txt create mode 100644 CMakeLists.txt create mode 100644 zephyr/module.yml diff --git a/CMSIS/CMakeLists.txt b/CMSIS/CMakeLists.txt new file mode 100644 index 000000000..e0c61fef0 --- /dev/null +++ b/CMSIS/CMakeLists.txt @@ -0,0 +1,3 @@ +# SPDX-License-Identifier: Apache-2.0 + +add_subdirectory_ifdef(CONFIG_HAS_CMSIS_CORE_M Core) diff --git a/CMSIS/Core/CMakeLists.txt b/CMSIS/Core/CMakeLists.txt new file mode 100644 index 000000000..08d3c9934 --- /dev/null +++ b/CMSIS/Core/CMakeLists.txt @@ -0,0 +1,11 @@ +# SPDX-License-Identifier: Apache-2.0 + +zephyr_include_directories(Include) + +# As of CMSIS v5.6.0, __PROGRAM_START is to indicate whether the +# ARM vendor or the OS supplies data/bss init routine, otherwise +# the default data/bss init routine for the selected toolchain is +# added. We set the macro in build-time to guarantee compatibility +# with all existing ARM platforms. + +zephyr_compile_definitions(__PROGRAM_START) diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 000000000..928093133 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1 @@ +add_subdirectory(CMSIS) diff --git a/zephyr/module.yml b/zephyr/module.yml new file mode 100644 index 000000000..c6f8a4e6b --- /dev/null +++ b/zephyr/module.yml @@ -0,0 +1,3 @@ +build: + cmake-ext: true + kconfig-ext: true