From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from sclab-apps-2.localdomain (sc-fw1.tilera.com [12.218.212.162]) by dpdk.org (Postfix) with ESMTP id 8D39FC934 for ; Fri, 19 Jun 2015 23:29:41 +0200 (CEST) X-CheckPoint: {558489C4-8-A3D4DA0C-C0000002} Received: by sclab-apps-2.localdomain (Postfix, from userid 1318) id 7288422048B; Fri, 19 Jun 2015 14:29:40 -0700 (PDT) From: Cyril Chemparathy To: dev@dpdk.org Date: Fri, 19 Jun 2015 14:29:37 -0700 Message-Id: <1434749378-8578-1-git-send-email-cchemparathy@ezchip.com> X-Mailer: git-send-email 2.1.2 Subject: [dpdk-dev] [PATCH] mk: add support for gdb debug info generation X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jun 2015 21:29:52 -0000 From: Cyril Chemparathy It is often useful to build with debug enabled, we add a config (CONFIG_RTE_TOOLCHAIN_DEBUG) to do so. Note: This patch does not include corresponding changes for ICC. The author pleads abject ignorance in this regard, and welcomes recommendations. :-) Change-Id: I499e591e1b7d71df751fd40d1fdcbe6975eeeb27 Signed-off-by: Cyril Chemparathy --- mk/toolchain/gcc/rte.vars.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/mk/toolchain/gcc/rte.vars.mk b/mk/toolchain/gcc/rte.vars.mk index 0f51c66..22c4c1f 100644 --- a/mk/toolchain/gcc/rte.vars.mk +++ b/mk/toolchain/gcc/rte.vars.mk @@ -71,6 +71,11 @@ ifeq (,$(findstring -O0,$(EXTRA_CFLAGS))) endif endif +ifeq ($(CONFIG_RTE_TOOLCHAIN_DEBUG),y) +TOOLCHAIN_CFLAGS += -g -ggdb +TOOLCHAIN_LDFLAGS += -g -ggdb +endif + WERROR_FLAGS := -W -Wall -Werror -Wstrict-prototypes -Wmissing-prototypes WERROR_FLAGS += -Wmissing-declarations -Wold-style-definition -Wpointer-arith WERROR_FLAGS += -Wcast-align -Wnested-externs -Wcast-qual -- 2.1.2