From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C5D94A0524; Mon, 19 Apr 2021 20:07:02 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 522FA413DE; Mon, 19 Apr 2021 20:07:01 +0200 (CEST) Received: from NAM04-CO1-obe.outbound.protection.outlook.com (mail-eopbgr690044.outbound.protection.outlook.com [40.107.69.44]) by mails.dpdk.org (Postfix) with ESMTP id 63FB6413B0 for ; Mon, 19 Apr 2021 20:06:59 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=P/smmp3jPH/mG73UgVrWT41GQQNkxfpIbjzylrRbEA4/1cX0vlOz0kGYO19Ber8LLHkvMQK+oR3u6m/1MkdQErbaPDZgYe6Hegj8XrwHnuClxwP4hJUeCdagsjwz1lFq3nmckRmh1chk6JpUEFy0yEbX3iToqdNNUhXT8nY/AKrCMbtgcx5IYycu1apLPDewC9hVnMZ+VHdug5zFYEz9PhZKbfHVNEv7j1di2eHG/cPCoyEecNqrDy+v7RClkzT54ABVZxO/5pwgmq/z1noeIthyd4jjP+ggOKDHqcAKgjbG88YhKMpiPWBJK85C+lddfHeVYASyrTezAtg1jQar4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TurMU00AknVOHveIy3o3PnmVaPz9VsXnTg45bWyGnD4=; b=SF4SVpegv10MQLozyGQ9gG6bOVOYFdyCB3Wb8Zs124t6QkUoWdx9ZeJWvnUKWhh3HJZIclZAMWJ477EFEx23IuqAlHNXLH1VW6OKbvalPANqNTyhV4u/W8Dv9SDf+iyXQliTKqHjMsYEzpaOiu82R+amryh//4jeNH+sFr5u1hIO//Uq+5fI8KX1c0SSphCpwc4mtD7TlcqR0h1wKpo3U8tdUf0CbrtOTdroCxEJII7ISdaVDtsq5J58iHUXhp0wrT75Kmva3HefnX1Udc4yvvdkrDuP5wqwB1kFVKS6JkNztVB3z5L4Kq4SoMP35Ipi4g5bpW+zcJ+tdkVMjly/Mg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TurMU00AknVOHveIy3o3PnmVaPz9VsXnTg45bWyGnD4=; b=DgeiF71YaHkV/iVNk9t1S0VM9SGsIaD5ecx0E0y0obH3Hpze4lj9sG8Q3wqNEoT0mTcHKYMVlyIxArm1CVHInDO2hQ9mmeEXwf149Wi3iTXw/TiiXL6iXCA1I06kLxbnDgw9PKrFr8dY9SngxJgECPd6JvEMmQmqviDMrSuGEgA0bHmIJauUpR7HgUjG7LSIvSO0uHW0lSA0gEm1whXczAKUOhQDdVi6xVwxTR8GGMm+UpsC47sqXMTlddHcdMIQmHJCW3/gbOybnTJq6d92N7YR6UADMBVDrRToKbFs7A1DnclHjpWVQV3bypMyJ12Hovhm1iSPPNBZTWjk/iHxhg== Received: from DM6PR12MB3945.namprd12.prod.outlook.com (2603:10b6:5:1c2::27) by DM5PR12MB1563.namprd12.prod.outlook.com (2603:10b6:4:a::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4042.16; Mon, 19 Apr 2021 18:06:57 +0000 Received: from DM6PR12MB3945.namprd12.prod.outlook.com ([fe80::9d62:2f16:264b:285d]) by DM6PR12MB3945.namprd12.prod.outlook.com ([fe80::9d62:2f16:264b:285d%5]) with mapi id 15.20.4042.024; Mon, 19 Apr 2021 18:06:57 +0000 From: Tal Shnaiderman To: Tal Shnaiderman , Dmitry Kozlyuk CC: NBU-Contact-Thomas Monjalon , "dev@dpdk.org" , "pallavi.kadam@intel.com" , "navasile@linux.microsoft.com" , "dmitrym@microsoft.com" Thread-Topic: [PATCH] eal/windows: fix build warnings in MinGW Thread-Index: AQHXNH6ZwWznH+guDkSl6v4FBquUUaq6mXjggAAe7wCAAKyvEIAAvW5A Date: Mon, 19 Apr 2021 18:06:57 +0000 Message-ID: References: <20210418170803.15684-1-talshn@nvidia.com> <2018619.JnGxiWPmQR@thomas> <20210418232330.2471f913@sovereign> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: nvidia.com; dkim=none (message not signed) header.d=none;nvidia.com; dmarc=none action=none header.from=nvidia.com; x-originating-ip: [5.29.61.36] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f2c72755-d103-4470-2803-08d9035debd8 x-ms-traffictypediagnostic: DM5PR12MB1563: x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: T8z44i4bp3Cwj684njd2Da2LzwniimcJvlBhk48tPzTJv2eEaUfSbM+1CLOWZQTLVrY7AzsMi2Eum+gWV8+yLkM+TinHWkJ3Szni4M06o+tJHoJ+HpiO7tlbcL/k0KGKQg8UWduGTGuxHLWwdJHDGnQrDi76co1Pt//3h2sJsRK/lq4sjoHuo8k9EUWXqg1V6B54z4e8rKOBZ8yu9ipVVz5gZ9zZCNcvE2eWX4N2QaiLMVtO5+w53L7iWTQ+3PhpWfd/koWtCnY5ErOjAfM1Ul5m9FukVHvOoB+bVU2JIlqfY0MyR6knTObiR4aLz+9fJDcRxkmIfWpSlCHwO88M6JDtSFAkLlnlikoZXOovnAvlTZHY7rhrYScLHplNuYbpnTzhuEtRsUQ4n89RqcbgyCCclAcs8rBo92yxIS7ur0r2gbfzGfCtwg2iW/NwIeyjGbxfh2T+kK1e6cr0rJOjA0WRfDGIARBxgW8K9O+7yaRYpWpgGSLB6TqgLGqrqLpwIuWGk+RxfbL/3cjSUZVOqhSNlUSKdHtQkblWtqwd7IiYypYNbcXq3QQvCphBqve6CpzrKc71XD2l/M8KptZ+JxPi0El9mS1uL/IsWyYz+O4= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR12MB3945.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(376002)(136003)(396003)(366004)(346002)(39860400002)(66946007)(478600001)(76116006)(66556008)(2940100002)(38100700002)(26005)(66446008)(9686003)(66476007)(64756008)(8936002)(186003)(4326008)(55016002)(2906002)(122000001)(86362001)(6506007)(83380400001)(110136005)(5660300002)(54906003)(52536014)(316002)(71200400001)(7696005)(33656002)(8676002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?xuX4yfFeat/IHbFjcN2pFMhNbDMgw0QpPVEr8qP9PU9/7zJRkN7XtqnfRhkk?= =?us-ascii?Q?xd2o2ZrtNalEgBSbqeCSLvxZwrXrRY8u0p5N9AEv24VueZZouPRm6j32IYMD?= =?us-ascii?Q?TXdDr9h7k+6NlkmjYzQq6XCU7c9svgEd9bL4fJmCzsGxVHtVPFT+SqN8gnYv?= =?us-ascii?Q?HykzbHm7lkJtzg5IbSRUkuStTemapf6YEQaUF/XdTKKdmIUAQmBhva5FrSd0?= =?us-ascii?Q?C5ZszVW/eePgGjTDxLioZtaqvHBRvmm6majy8LBzHvB9yrGcu8oSuSlON2d9?= =?us-ascii?Q?VoY++zwu222oBy3+zHWdDmGFydjRAQ6ayht0h75o7ZS4T+GPVHp+de4b/cL6?= =?us-ascii?Q?qvFKdcBStHodZ/LIwQPlxiWAx1t41rNJcyx45WCScrnVqt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pD9rLjfbL9aeZbb/PDqoEXNEDbj347FA8TrFv9xBNv/WMFKs?= =?us-ascii?Q?ht0=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR12MB3945.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f2c72755-d103-4470-2803-08d9035debd8 X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Apr 2021 18:06:57.1520 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: ATQMgcpyGntBcUZU5zdUEBa0XMqi2ctLza7puuPiiwG6juSBNYbJlCNLxPdo6DA02dviET6GeXZFpus4vFbLRA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1563 Subject: Re: [dpdk-dev] [PATCH] eal/windows: fix build warnings in MinGW X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > Subject: Re: [dpdk-dev] [PATCH] eal/windows: fix build warnings in MinGW >=20 > External email: Use caution opening links or attachments >=20 >=20 > > Subject: Re: [PATCH] eal/windows: fix build warnings in MinGW > > > > External email: Use caution opening links or attachments > > > > > > Hi Tal, > > > > 2021-04-18 19:04 (UTC+0000), Tal Shnaiderman: > > > > Subject: Re: [PATCH] eal/windows: fix build warnings in MinGW > > > > > > > > External email: Use caution opening links or attachments > > > > > > > > > > > > 18/04/2021 19:08, Tal Shnaiderman: > > > > > the strncasecmp marco defined in rte_os_shim.h is already > > > > > defined in MinGW-w64, as a result the compiler prints out the > > > > > warning below on function redefinition whenever compiling a file > > > > > including the > > header. > > > > > > > > > > ..\lib/librte_eal/windows/include/rte_os_shim.h:21: > > > > > warning: "strncasecmp" redefined #define strncasecmp(s1, s2, > > > > > count) _strnicmp(s1, s2, count) > > > > > > > > Why the tests are passing? Are we allowing warnings in build test? > > > > > > It's a good question, I see CI is passing without warnings, Dmitry > > > can you > > reproduce it? > > > > > > On my side the collision is with the following file: > > > > > > C:/mingw-w64/x86_64/mingw64/x86_64-w64- > > mingw32/include/string.h:119: > > > note: this is the location of the previous definition #define > > > strncasecmp _strnicmp > > > > > > I'm using: > > > -gcc (x86_64-win32-seh-rev0, Built by MinGW-W64 project) 8.1.0 > > > -meson > > > 0.53.2 > > > > I can't reproduce it using the same versions. > > Do you invoke meson with other options than "-Dexamples=3D..."? >=20 > This is the meson line I'm using: >=20 > meson "-Dexamples=3Dhelloworld" build --wipe --default-library=3Dstatic -= - > buildtype debug >=20 > The problem however is that MinGW's string.h defines the macro in line 11= 9, > for some reason my build includes it and the rest doesn't. Hi Dmitry, I also noticed warnings in clang on my setup that are related to rte_os_shi= m.h: [185/314] Compiling C object drivers/a715181@@tmp_rte_common_mlx5@sta/commo= n_mlx5_mlx5_common_mp.c.obj. In file included from ../drivers/common/mlx5/mlx5_common_mp.c:13: In file included from ..\drivers\common/mlx5/mlx5_common_utils.h:8: In file included from ..\drivers\common/mlx5/mlx5_common.h:17: ..\lib/librte_eal/windows/include\rte_os_shim.h:22:51: warning: token pasti= ng of ',' and __VA_ARGS__ is a GNU extension [-Wgnu-zero-variadic-macro-arg= uments] #define open(path, flags, ...) _open(path, flags, ##__VA_ARGS__) ^ However don't see it in CI, I'm using clang version 9.0.1