Skip to content

Commit 94290ee

Browse files
Marti BolivarAnas Nashif
Marti Bolivar
authored and
Anas Nashif
committed
cmake: extensions: support list arguments to set_ifndef()
I keep tripping over not being able to use set_ifndef to set a value to a list, like this: set_ifndef(VARIABLE value1 value2 value3...) Allow that to work without changing its existing behavior when called with one argument. Signed-off-by: Marti Bolivar <[email protected]>
1 parent f4ace33 commit 94290ee

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmake/extensions.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -680,7 +680,7 @@ endmacro()
680680
# See 3.1 *_ifdef
681681
function(set_ifndef variable value)
682682
if(NOT ${variable})
683-
set(${variable} ${value} PARENT_SCOPE)
683+
set(${variable} ${value} ${ARGN} PARENT_SCOPE)
684684
endif()
685685
endfunction()
686686

0 commit comments

Comments
 (0)