Skip to content

Commit 8ff467b

Browse files
committed
modules: cmsis: only add cmsis path for Cortex A and R
The cmsis module is not supposed to be used for Cortex M, where cmsis_6 should be used instead, but the build system currently still adds the cmsis header directly in the include path if the module is present and we are building for Cortex M, this means a PR could still use the old headers, the CI would not catch it but then it would fail if an application only has cmsis_6 available. Fix this by moving the CMake add_subdirectory directory in the existing conditional for Cortex A and R. Signed-off-by: Fabio Baltieri <[email protected]>
1 parent 6413185 commit 8ff467b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

modules/cmsis/CMakeLists.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# Copyright (c) 2023 Nordic Semiconductor ASA
22
# SPDX-License-Identifier: Apache-2.0
33

4-
add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis)
5-
64
if(CONFIG_CPU_AARCH32_CORTEX_A OR CONFIG_CPU_AARCH32_CORTEX_R)
5+
add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis)
76
zephyr_include_directories(.)
87
endif()

0 commit comments

Comments
 (0)