debug symbol level: Use config instead

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
This commit is contained in:
wangmingrong1
2024-12-04 17:26:22 +08:00
committed by Xiang Xiao
parent dcea1b90e7
commit cc88063646
7 changed files with 7 additions and 6 deletions
+1
View File
@@ -2495,6 +2495,7 @@ config DEBUG_SYMBOLS
config DEBUG_SYMBOLS_LEVEL config DEBUG_SYMBOLS_LEVEL
string "Custom symbols level" string "Custom symbols level"
depends on DEBUG_SYMBOLS
default "-g" default "-g"
---help--- ---help---
This string represents the custom symbol level that will be This string represents the custom symbol level that will be
+1 -1
View File
@@ -166,7 +166,7 @@ ifeq ($(CONFIG_DEBUG_LINK_MAP),y)
endif endif
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION += -g ARCHOPTIMIZATION += $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
LDFLAGS += --no-warn-rwx-segments LDFLAGS += --no-warn-rwx-segments
@@ -76,7 +76,7 @@ ARCHOPTIMIZATION += --tradeoff=2
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION += --debug-info=default ARCHOPTIMIZATION += --debug-info=default
ARCHOPTIMIZATION += --keep-temporary-files ARCHOPTIMIZATION += --keep-temporary-files
LDFLAGS += -g LDFLAGS += $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
# merge source code with assembly output # merge source code with assembly output
+1 -1
View File
@@ -21,7 +21,7 @@
############################################################################ ############################################################################
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g3 ARCHOPTIMIZATION = $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
ifneq ($(CONFIG_DEBUG_NOOPT),y) ifneq ($(CONFIG_DEBUG_NOOPT),y)
+1 -1
View File
@@ -25,7 +25,7 @@ DC := ldmd2
DFLAGS := -i DFLAGS := -i
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
DFLAGS += -g DFLAGS += $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
ifeq ($(CONFIG_DEBUG_NOOPT),y) ifeq ($(CONFIG_DEBUG_NOOPT),y)
+1 -1
View File
@@ -25,7 +25,7 @@ RUSTC := rustc --edition 2021
RUSTFLAGS := RUSTFLAGS :=
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
RUSTFLAGS += -g RUSTFLAGS += $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
ifeq ($(CONFIG_DEBUG_NOOPT),y) ifeq ($(CONFIG_DEBUG_NOOPT),y)
+1 -1
View File
@@ -27,7 +27,7 @@ SWIFTC := swiftc
SWIFTFLAGS := -enable-experimental-feature Embedded -wmo SWIFTFLAGS := -enable-experimental-feature Embedded -wmo
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
SWIFTFLAGS += -g SWIFTFLAGS += $(CONFIG_DEBUG_SYMBOLS_LEVEL)
endif endif
ifeq ($(CONFIG_DEBUG_NOOPT),y) ifeq ($(CONFIG_DEBUG_NOOPT),y)