mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 23:03:27 +08:00
build: fix memory manager compile options for CMake
This enables CMake based build for sim:ostest. Flags which are set by set_source_files_properties are not reflected in final build. Changing these to target_compile_options makes CMake build runnable. Signed-off-by: Daniel Jasinski <jasinskidaniel95szcz@gmail.com>
This commit is contained in:
committed by
Xiang Xiao
parent
1413fc0c1b
commit
7dbb887f07
@@ -19,7 +19,11 @@
|
|||||||
# ##############################################################################
|
# ##############################################################################
|
||||||
if(CONFIG_MM_KASAN)
|
if(CONFIG_MM_KASAN)
|
||||||
target_sources(mm PRIVATE kasan.c)
|
target_sources(mm PRIVATE kasan.c)
|
||||||
set_source_files_properties(kasan.c PROPERTIES COMPILE_FLAGS
|
|
||||||
-fno-sanitize=kernel-address)
|
target_compile_options(mm PRIVATE -fno-sanitize=kernel-address)
|
||||||
set_source_files_properties(kasan.c PROPERTIES COMPILE_FLAGS -fno-lto)
|
|
||||||
|
if(NOT CONFIG_LTO_NONE)
|
||||||
|
target_compile_options(mm PRIVATE -fno-lto)
|
||||||
|
endif()
|
||||||
|
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
Reference in New Issue
Block a user