From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B976EA04A3 for ; Tue, 16 Jun 2020 15:51:54 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id AD8485B3A; Tue, 16 Jun 2020 15:51:54 +0200 (CEST) Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by dpdk.org (Postfix) with ESMTP id E29A01BE99 for ; Tue, 16 Jun 2020 15:51:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1592315513; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=AaYI18fTgiCHt1o3PcJ25RBYfsmC6oaQfjryVy3lxBI=; b=BUl8Gt++YGsr0/cQow0o28+V0Cb7efHUVX/hrN9NF7m5/Td/oDzcAHve18Udt2HjMQIBgy 4JGhAVybOOgxPG5JiqII/TKoFuTYnx9o9sJv4gEdbnL3ao5dA44srJutCLNpUKPmtKSJnr YPt0JNGsq1gMGv4MMnAvvMqDHJ9OVbU= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-465-cawPslqaNoq9Kt7Eg8rQNg-1; Tue, 16 Jun 2020 09:51:51 -0400 X-MC-Unique: cawPslqaNoq9Kt7Eg8rQNg-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 87C31803315; Tue, 16 Jun 2020 13:51:50 +0000 (UTC) Received: from rh.redhat.com (unknown [10.33.36.205]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7B2E56ED96; Tue, 16 Jun 2020 13:51:49 +0000 (UTC) From: Kevin Traynor To: stable@dpdk.org Cc: bluca@debian.org, ferruh.yigit@intel.com, Kevin Traynor Date: Tue, 16 Jun 2020 14:51:37 +0100 Message-Id: <20200616135137.8563-5-ktraynor@redhat.com> In-Reply-To: <20200616135137.8563-1-ktraynor@redhat.com> References: <20200616135137.8563-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] [PATCH 18.11 4/4] app/testpmd: disable gcc 10 -fno-common build errors X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" gcc 10 defaults to -fno-common and as a result when building testpmd, there are errors. These could be fixed with a rebased version of commit f6e63e59e7e2 ("app/testpmd: fix global variable multiple definitions") but there are conflicts with that patch. When DPDK 18.11 was released -fcommon was the default on gcc, so disable the warnings for testpmd. Signed-off-by: Kevin Traynor --- app/test-pmd/Makefile | 6 ++++++ app/test-pmd/meson.build | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/app/test-pmd/Makefile b/app/test-pmd/Makefile index d5258eae4a..f36137fd44 100644 --- a/app/test-pmd/Makefile +++ b/app/test-pmd/Makefile @@ -16,4 +16,10 @@ CFLAGS += $(WERROR_FLAGS) CFLAGS += -Wno-deprecated-declarations +ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y) +ifeq ($(shell test $(GCC_VERSION) -ge 100 && echo 1), 1) +CFLAGS += -fcommon +endif +endif + # # all source are stored in SRCS-y diff --git a/app/test-pmd/meson.build b/app/test-pmd/meson.build index 6006c60f99..adeeeeedba 100644 --- a/app/test-pmd/meson.build +++ b/app/test-pmd/meson.build @@ -6,4 +6,9 @@ name = 'testpmd' allow_experimental_apis = true cflags += '-Wno-deprecated-declarations' + +if (toolchain == 'gcc' and cc.version().version_compare('>=10.0.0')) + cflags += '-fcommon' +endif + sources = files('cmdline.c', 'cmdline_flow.c', -- 2.21.3