This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 82fc9f41512b8865036d5e8ef70b3a0a517e2c6c
Author: xuxin19 <[email protected]>
AuthorDate: Fri Mar 21 15:51:30 2025 +0800

    cmake(bugfix):Separate extra flags to avoid parsing errors
    
    cc1: note: unrecognized command-line option '-Wno-cpp -Werror' may have 
been intended to silence earlier diagnostics
    cc1: note: unrecognized command-line option '-Wno-cpp -Werror' may have 
been intended to silence earlier diagnostics
    
    Signed-off-by: xuxin19 <[email protected]>
---
 cmake/nuttx_toolchain.cmake | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/cmake/nuttx_toolchain.cmake b/cmake/nuttx_toolchain.cmake
index 55ac9f92b33..3156d880414 100644
--- a/cmake/nuttx_toolchain.cmake
+++ b/cmake/nuttx_toolchain.cmake
@@ -49,7 +49,8 @@ endif()
 # Support CMake to define additional configuration options
 
 if(EXTRA_FLAGS)
-  add_compile_options(${EXTRA_FLAGS})
+  separate_arguments(EXTRA_FLAGS_LIST UNIX_COMMAND "${EXTRA_FLAGS}")
+  add_compile_options(${EXTRA_FLAGS_LIST})
 endif()
 
 # ~~~

Reply via email to