diff --git a/cmake/nuttx_add_application.cmake b/cmake/nuttx_add_application.cmake index 1c8259e3a76..b27ba7611ea 100644 --- a/cmake/nuttx_add_application.cmake +++ b/cmake/nuttx_add_application.cmake @@ -90,11 +90,13 @@ function(nuttx_add_application) DEFINITIONS OPTIONS NO_MAIN_ALIAS - REQUIRED - NAME ARGN ${ARGN}) + if(NOT NAME) + return() + endif() + # check if SRCS exist if(SRCS) file(GLOB SRCS_EXIST ${SRCS})