cmake fix NuttX config import for 0 values

This commit is contained in:
Daniel Agar 2021-11-20 18:04:33 -05:00
parent 7a1a4ea7a6
commit 7653bd1757
1 changed files with 5 additions and 7 deletions

View File

@ -96,13 +96,11 @@ foreach(NameAndValue ${ConfigContents})
# Find the value
string(REPLACE "${Name}=" "" Value ${NameAndValue})
if(Value)
# remove extra quotes
string(REPLACE "\"" "" Value ${Value})
# remove extra quotes
string(REPLACE "\"" "" Value ${Value})
# Set the variable
#message(STATUS "${Name} ${Value}")
set(${Name} ${Value} CACHE INTERNAL "NUTTX DEFCONFIG: ${Name}" FORCE)
endif()
# Set the variable
#message(STATUS "${Name} ${Value}")
set(${Name} ${Value} CACHE INTERNAL "NUTTX DEFCONFIG: ${Name}" FORCE)
endif()
endforeach()