From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 273D6159 for ; Fri, 4 Apr 2014 11:57:27 +0200 (CEST) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP; 04 Apr 2014 02:59:02 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.97,794,1389772800"; d="scan'208";a="514371882" Received: from irsmsx103.ger.corp.intel.com ([163.33.3.157]) by fmsmga002.fm.intel.com with ESMTP; 04 Apr 2014 02:59:00 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.78]) by IRSMSX103.ger.corp.intel.com ([163.33.3.157]) with mapi id 14.03.0123.003; Fri, 4 Apr 2014 10:57:48 +0100 From: "Ananyev, Konstantin" To: Cyril Chemparathy , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH] mk: add support for gdb debug info generation Thread-Index: AQHPT2NJVMrXNSUOXkymmhsma6CA05sBOVJw Date: Fri, 4 Apr 2014 09:57:47 +0000 Message-ID: <2601191342CEEE43887BDE71AB9772580EF948F7@IRSMSX105.ger.corp.intel.com> References: <1396546285-29972-1-git-send-email-cchemparathy@tilera.com> In-Reply-To: <1396546285-29972-1-git-send-email-cchemparathy@tilera.com> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 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: Fri, 04 Apr 2014 09:57:28 -0000 Hi Cyril, We already do have 'EXTRA_CFLAGS' and 'EXTRA_LDFLAGS' that you can use to e= nable debug, or any other compiler/linker options you need. Wonder, why that is not enough? Thanks Konstantin -----Original Message----- From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Cyril Chemparathy Sent: Thursday, April 03, 2014 6:31 PM To: dev@dpdk.org Subject: [dpdk-dev] [PATCH] mk: add support for gdb debug info generation 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 autho= r pleads abject ignorance in this regard, and welcomes recommendations. :-) Signed-off-by: Cyril Chemparathy --- config/defconfig_x86_64-default-linuxapp-gcc | 1 + mk/toolchain/gcc/rte.vars.mk | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/config/defconfig_x86_64-default-linuxapp-gcc b/config/defconfi= g_x86_64-default-linuxapp-gcc index f11ffbf..3b36efd 100644 --- a/config/defconfig_x86_64-default-linuxapp-gcc +++ b/config/defconfig_x86_64-default-linuxapp-gcc @@ -67,6 +67,7 @@ CONFIG_RTE_ARCH_X86_64=3Dy # CONFIG_RTE_TOOLCHAIN=3D"gc= c" CONFIG_RTE_TOOLCHAIN_GCC=3Dy +CONFIG_RTE_TOOLCHAIN_DEBUG=3Dn =20 # # Use intrinsics or assembly code for key routines diff --git a/mk/toolcha= in/gcc/rte.vars.mk b/mk/toolchain/gcc/rte.vars.mk index 0edb93f..81ed3fa 10= 0644 --- a/mk/toolchain/gcc/rte.vars.mk +++ b/mk/toolchain/gcc/rte.vars.mk @@ -68,6 +68,11 @@ ifeq (,$(findstring -O0,$(EXTRA_CFLAGS))) endif endif =20 +ifeq ($(CONFIG_RTE_TOOLCHAIN_DEBUG),y) +TOOLCHAIN_CFLAGS +=3D -g -ggdb +TOOLCHAIN_LDFLAGS +=3D -g -ggdb +endif + WERROR_FLAGS :=3D -W -Wall -Werror -Wstrict-prototypes -Wmissing-prototype= s WERROR_FLAGS +=3D -Wmissing-declarations -Wold-style-definition -Wpointe= r-arith WERROR_FLAGS +=3D -Wcast-align -Wnested-externs -Wcast-qual -- 1.8.3.1