mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-16 17:44:19 +00:00
build!: check boolean flags are not empty
For numeric flags, there is a check for the value to be set. Do the same for boolean flags. This avoids issues where a flag is defined but without a value, leading to potential unexpected behaviors. Signed-off-by: Yann Gautier <yann.gautier@st.com> Change-Id: Ib00da2784339471058887e93434d96ccba2aebb2
This commit is contained in:
parent
4d32f9138d
commit
1369fb82c8
1 changed files with 1 additions and 0 deletions
|
@ -73,6 +73,7 @@ endef
|
|||
# Convenience function for verifying option has a boolean value
|
||||
# $(eval $(call assert_boolean,FOO)) will assert FOO is 0 or 1
|
||||
define assert_boolean
|
||||
$(if $($(1)),,$(error $(1) must not be empty))
|
||||
$(if $(filter-out 0 1,$($1)),$(error $1 must be boolean))
|
||||
endef
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue