Skip to content

Commit 41e283c

Browse files
tejlmandcarlescufi
authored andcommitted
cmake: move the BOARD variable watch below deprecated board handling
Fixes: zephyrproject-rtos#33138 Board alias and deprecated board handling is setting the BOARD variable after zephyr_boilerplate_watch(BOARD) has been executed. This results in the board changed warning. This commit moves the zephyr_boilerplate_watch(BOARD) code below the board alias and deprecation handling. Signed-off-by: Torsten Rasmussen <[email protected]>
1 parent d697d26 commit 41e283c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmake/app/boilerplate.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,8 +224,6 @@ if(NOT (REVISION_SEPARATOR_INDEX EQUAL -1))
224224
string(SUBSTRING ${BOARD} 0 ${REVISION_SEPARATOR_INDEX} BOARD)
225225
endif()
226226

227-
zephyr_boilerplate_watch(BOARD)
228-
229227
set(BOARD_MESSAGE "Board: ${BOARD}")
230228

231229
if(DEFINED ENV{ZEPHYR_BOARD_ALIASES})
@@ -243,6 +241,8 @@ if(${BOARD}_DEPRECATED)
243241
message(WARNING "Deprecated BOARD=${BOARD_DEPRECATED} name specified, board automatically changed to: ${BOARD}.")
244242
endif()
245243

244+
zephyr_boilerplate_watch(BOARD)
245+
246246
foreach(root ${BOARD_ROOT})
247247
# Check that the board root looks reasonable.
248248
if(NOT IS_DIRECTORY "${root}/boards")

0 commit comments

Comments
 (0)