From mboxrd@z Thu Jan 1 00:00:00 1970 From: Neil Horman Subject: Re: [PATCH 07/11] pmdinfogen: fix build warnings Date: Fri, 8 Jul 2016 10:51:26 -0400 Message-ID: <20160708145126.GF14917@hmsreliant.think-freely.org> References: <1467905790-10597-1-git-send-email-thomas.monjalon@6wind.com> <1467905790-10597-8-git-send-email-thomas.monjalon@6wind.com> <20160707175527.GN26064@hmsreliant.think-freely.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: Thomas Monjalon , "dev@dpdk.org" To: "Mcnamara, John" Return-path: Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58]) by dpdk.org (Postfix) with ESMTP id 9AA97301 for ; Fri, 8 Jul 2016 16:52:19 +0200 (CEST) Content-Disposition: inline In-Reply-To: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, Jul 07, 2016 at 09:25:27PM +0000, Mcnamara, John wrote: >=20 >=20 > > -----Original Message----- > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Neil Horman > > Sent: Thursday, July 7, 2016 6:55 PM > > To: Thomas Monjalon > > Cc: dev@dpdk.org > > Subject: Re: [dpdk-dev] [PATCH 07/11] pmdinfogen: fix build warnings > >=20 > > On Thu, Jul 07, 2016 at 05:36:26PM +0200, Thomas Monjalon wrote: > > > When compiled with a standard clang, pmdinfogen can raise a warning= : > > > buildtools/pmdinfogen/pmdinfogen.c:365:1: warning: > > > control reaches end of non-void function > > > > > > Actually there can be more warnings with stricter compilers. > > > In order to catch them early and fix most of them, the DPDK standar= d > > > flags WERROR_FLAGS are used. > > > > > > The warnings fixed are: > > > no previous prototype for ... > > > no return statement in function returning non-void > > > variable =E2=80=98secstrings=E2=80=99 set but not used > > > =E2=80=98sec_name=E2=80=99 defined but not used > > > =E2=80=98get_symbol_index=E2=80=99 defined but not used > > > pointer of type =E2=80=98void *=E2=80=99 used in arithmetic > > > > > > Fixes: 98b0fdb0ffc6 ("pmdinfogen: add buildtools and pmdinfogen > > > utility") > > > > > > Signed-off-by: Thomas Monjalon > > > --- > > I'm not opposed to any of these changes, but I'm really starting to w= onder > > how well used/maintained clang is as a toolchain target. I assert th= at > > because, with my admittedly broken dependency rule, a native clang bu= ild > > for me errors out in any number of places: > >=20 > > /home/nhorman/git/dpdk/lib/librte_eal/linuxapp/eal/eal_pci.c:392:37: > > error: > > equality comparison with extraneous parentheses [-Werror,-Wparenthese= s- > > equality] if (((&pci_device_list)->tqh_first =3D=3D ((void*)0))) { > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~ > > /home/nhorman/git/dpdk/lib/librte_eal/linuxapp/eal/eal_pci.c:392:37: = note: > > remove extraneous parentheses around the comparison to silence this > > warning if (((&pci_device_list)->tqh_first =3D=3D ((void*)0))) { >=20 >=20 > It is due to the clang/ccache "issue" that is tripping up everyone. Exp= orting CCACHE_CPP2=3Dyes should fix it. There was a thread about this ear= lier in the week. >=20 > John. >=20 >=20 Ah, that did it, yes. Though I didnt' get any of the warnings the Thomas encountered when he posted those changes to pmdinfogen either=20 Regardless, theres nothing egregious in the chagnes, so I don't see the h= arm. Acked-by: Neil Horman