Skip to content
Commit 84fe1ec6 authored by Sebastian Bøe's avatar Sebastian Bøe Committed by Anas Nashif
Browse files

cmake: Don't remember misnamed boards



CMake prints a helpful error message with all the boards supported
when a board name has been misspelled. But CMake also
remembers (caches) the corrupted board name and refuses to change it
until the board directory has been cleared.

CMake is rightly hesitant to change the board, as other cached
variables depend on what the board is. But it is safe to change the
board just after it has been selected, because we verify it's
correctness before using it to calculate other variables.

So to support the use-case of changing a misspelled board
name (without clearing the build directory) we unset the cached board
when it is invalid.

Also; change the now unused (in-tree) macro 'assert_with_usage' to
'print_usage'.

Signed-off-by: default avatarSebastian Bøe <sebastian.boe@nordicsemi.no>
parent 098dbfd1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment