mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-27 18:27:05 +08:00
cmake fix NuttX config import for 0 values
This commit is contained in:
@@ -96,13 +96,11 @@ foreach(NameAndValue ${ConfigContents})
|
|||||||
# Find the value
|
# Find the value
|
||||||
string(REPLACE "${Name}=" "" Value ${NameAndValue})
|
string(REPLACE "${Name}=" "" Value ${NameAndValue})
|
||||||
|
|
||||||
if(Value)
|
# remove extra quotes
|
||||||
# remove extra quotes
|
string(REPLACE "\"" "" Value ${Value})
|
||||||
string(REPLACE "\"" "" Value ${Value})
|
|
||||||
|
|
||||||
# Set the variable
|
# Set the variable
|
||||||
#message(STATUS "${Name} ${Value}")
|
#message(STATUS "${Name} ${Value}")
|
||||||
set(${Name} ${Value} CACHE INTERNAL "NUTTX DEFCONFIG: ${Name}" FORCE)
|
set(${Name} ${Value} CACHE INTERNAL "NUTTX DEFCONFIG: ${Name}" FORCE)
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|||||||
Reference in New Issue
Block a user