summaryrefslogtreecommitdiff
path: root/mk/vars.mk
diff options
context:
space:
mode:
Diffstat (limited to 'mk/vars.mk')
-rw-r--r--mk/vars.mk7
1 files changed, 5 insertions, 2 deletions
diff --git a/mk/vars.mk b/mk/vars.mk
index 6f3f5d270..bf51a378b 100644
--- a/mk/vars.mk
+++ b/mk/vars.mk
@@ -237,12 +237,15 @@ TARGET_CFLAGS+= -mlongcalls -mtext-section-literals
TARGET_CXXFLAGS+= -mlongcalls -mtext-section-literals
endif
-# add configured cflags for optimization
+# add configured compiler flags for optimization
TARGET_CFLAGS+= $(ADK_TARGET_CFLAGS_OPT)
TARGET_CXXFLAGS+= $(ADK_TARGET_CFLAGS_OPT)
-# always add debug information
+
+# add compiler flags for debug information
+ifeq ($(ADK_BUILD_WITH_DEBUG),y)
TARGET_CFLAGS+= -g3
TARGET_CXXFLAGS+= -g3
+endif
ifneq ($(ADK_DEBUG),)
TARGET_CFLAGS+= -fno-omit-frame-pointer