From d5f50ebd04bae84a6d6351b5c28587873a1e66e5 Mon Sep 17 00:00:00 2001 From: Ruben Ayrapetyan Date: Tue, 19 Aug 2014 13:15:52 +0400 Subject: [PATCH] Add dbgsyms=1 option to override OPTION_DEBUG_SYMS to enable, OPTION_STRIP to disable. --- Makefile | 1 + Makefile.mk | 16 ++++++++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 5338f8ed3..1ec1289d6 100644 --- a/Makefile +++ b/Makefile @@ -71,6 +71,7 @@ export echo export todo export fixme export color +export dbgsyms build: clean $(JERRY_TARGETS) diff --git a/Makefile.mk b/Makefile.mk index f7a4b0fdb..5c0fff82e 100644 --- a/Makefile.mk +++ b/Makefile.mk @@ -57,6 +57,13 @@ else OPTION_MCU = disable endif +# Override debug symbols settings +ifeq ($(dbgsyms),1) + OPTION_OVERRIDE_ENABLE_DBGSYMS := enable +else + OPTION_OVERRIDE_ENABLE_DBGSYMS := disable +endif + # DWARF version ifeq ($(dwarf4),1) OPTION_DWARF4 := enable @@ -98,8 +105,13 @@ endif # JERRY_NDEBUG, debug symbols ifeq ($(TARGET_MODE),release) OPTION_NDEBUG = enable - OPTION_DEBUG_SYMS = disable - OPTION_STRIP = enable + ifeq ($(OPTION_OVERRIDE_ENABLE_DBGSYMS),enable) + OPTION_DEBUG_SYMS = enable + OPTION_STRIP = disable + else + OPTION_DEBUG_SYMS = disable + OPTION_STRIP = enable + endif else OPTION_NDEBUG = disable OPTION_DEBUG_SYMS = enable