mirror of
https://github.com/apache/nuttx.git
synced 2026-05-19 03:03:37 +08:00
kasan/lto: Turn off lto by default anyway
Of course, there is an error here, that is, the conditional judgment of
ifeq ($(CONFIG_LTO_NONE),n)
CFLAGS += -fno-lto
endif
is wrong, it should be judged as "ifneq ($(CONFIG_LTO_NONE),)"
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
This commit is contained in:
committed by
Xiang Xiao
parent
fed3da9f03
commit
ee20aa888b
@@ -22,12 +22,9 @@
|
||||
set(SRCS hook.c)
|
||||
|
||||
if(CONFIG_MM_KASAN)
|
||||
list(APPEND FLAGS ${NO_LTO})
|
||||
list(APPEND FLAGS -fno-builtin)
|
||||
list(APPEND FLAGS -fno-sanitize=kernel-address)
|
||||
|
||||
if(CONFIG_LTO_NONE)
|
||||
list(APPEND FLAGS -fno-lto)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
target_sources(mm PRIVATE ${SRCS})
|
||||
|
||||
+1
-4
@@ -23,12 +23,9 @@
|
||||
CSRCS += hook.c
|
||||
|
||||
ifeq ($(CONFIG_MM_KASAN),y)
|
||||
CFLAGS += -fno-lto
|
||||
CFLAGS += -fno-builtin
|
||||
CFLAGS += -fno-sanitize=kernel-address
|
||||
|
||||
ifeq ($(CONFIG_LTO_NONE),n)
|
||||
CFLAGS += -fno-lto
|
||||
endif
|
||||
endif
|
||||
|
||||
# Add the core heap directory to the build
|
||||
|
||||
Reference in New Issue
Block a user