From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 33C4DC7FE for ; Mon, 22 Jun 2015 09:44:44 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP; 22 Jun 2015 00:44:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,658,1427785200"; d="scan'208";a="750923507" Received: from smonroyx-mobl.ger.corp.intel.com (HELO [10.237.220.129]) ([10.237.220.129]) by orsmga002.jf.intel.com with ESMTP; 22 Jun 2015 00:44:42 -0700 Message-ID: <5587BCE9.4000809@intel.com> Date: Mon, 22 Jun 2015 08:44:41 +0100 From: "Gonzalez Monroy, Sergio" User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Cyril Chemparathy , dev@dpdk.org References: <1434749378-8578-1-git-send-email-cchemparathy@ezchip.com> In-Reply-To: <1434749378-8578-1-git-send-email-cchemparathy@ezchip.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [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: Mon, 22 Jun 2015 07:44:44 -0000 On 19/06/2015 22:29, Cyril Chemparathy wrote: > 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 I don't think you need to modify the makefiles and introduce a new compile time option for this. The same result can be easily achieved by setting EXTRA_CFLAGS in the command line. ie: $ make install T=x86_64-native-linuxapp-gcc EXTRA_CFLAGS='-g -ggdb' Sergio