From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [148.163.129.52]) by dpdk.org (Postfix) with ESMTP id EDC7129D6 for ; Sun, 21 Jan 2018 10:48:48 +0100 (CET) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (webmail.solarflare.com [12.187.104.26]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1-us1.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id A7863A80070; Sun, 21 Jan 2018 09:48:47 +0000 (UTC) Received: from ocex03.SolarFlarecom.com (10.20.40.36) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Sun, 21 Jan 2018 01:48:44 -0800 Received: from opal.uk.solarflarecom.com (10.17.10.1) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25 via Frontend Transport; Sun, 21 Jan 2018 01:48:44 -0800 Received: from uklogin.uk.solarflarecom.com (uklogin.uk.solarflarecom.com [10.17.10.10]) by opal.uk.solarflarecom.com (8.13.8/8.13.8) with ESMTP id w0L9mhIf024459; Sun, 21 Jan 2018 09:48:43 GMT Received: from uklogin.uk.solarflarecom.com (localhost.localdomain [127.0.0.1]) by uklogin.uk.solarflarecom.com (8.13.8/8.13.8) with ESMTP id w0L9mho9000779; Sun, 21 Jan 2018 09:48:43 GMT From: Andrew Rybchenko To: CC: Liang Ma , Peter Mccarthy , Jerin Jacob , Thomas Monjalon Date: Sun, 21 Jan 2018 09:48:39 +0000 Message-ID: <1516528119-720-1-git-send-email-arybchenko@solarflare.com> X-Mailer: git-send-email 1.8.2.3 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-MDID: 1516528128-P2ss8xcbdzxY Subject: [dpdk-dev] [PATCH] event/opdl: fix build using C99 mode X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Jan 2018 09:48:49 -0000 RHEL 7.4 gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16) ‘for’ loop initial declarations are only allowed in C99 mode Fixes: 4236ce9bf5bf ("event/opdl: add OPDL ring infrastructure library") Signed-off-by: Andrew Rybchenko --- Other option is to move declarations outside of for loop. I just want it to be fixed. drivers/event/opdl/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/event/opdl/Makefile b/drivers/event/opdl/Makefile index 747ae5b..a8aff2c 100644 --- a/drivers/event/opdl/Makefile +++ b/drivers/event/opdl/Makefile @@ -7,6 +7,8 @@ include $(RTE_SDK)/mk/rte.vars.mk LIB = librte_pmd_opdl_event.a # build flags +CFLAGS += -std=c99 +CFLAGS += -D_XOPEN_SOURCE=600 CFLAGS += -O3 CFLAGS += $(WERROR_FLAGS) # for older GCC versions, allow us to initialize an event using -- 2.7.4