windows sim:add MSCV atomic support for fix windows build error

VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(36,24): error C2061: syntax error: identifier 'atomic_bool'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(36,24): error C2059: syntax error: ';'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(37,23): error C2061: syntax error: identifier 'atomic_char'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(37,23): error C2059: syntax error: ';'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(38,30): error C2061: syntax error: identifier 'atomic_schar'
VC\Tools\MSVC\14.40.33807\include\vcruntime_c11_stdatomic.h(38,30): error C2059: syntax error: ';'

Co-authored-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
Co-authored-by: xuxin19 <xuxin19@xiaomi.com>
This commit is contained in:
chenxiaoyi 2024-06-13 11:41:50 +08:00 committed by Xiang Xiao
parent b65efdba12
commit f512f5e8a9

View File

@ -50,6 +50,11 @@ if(NOT WIN32)
TARGET nuttx
APPEND
PROPERTY NUTTX_COMPILE_OPTIONS -fno-common)
else()
set_property(
TARGET nuttx
APPEND
PROPERTY NUTTX_COMPILE_OPTIONS /std:c11 /experimental:c11atomics)
endif()
if(CONFIG_SIM_SANITIZE)