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 42E69A0548; Mon, 19 Apr 2021 22:36:33 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B1D8C41471; Mon, 19 Apr 2021 22:36:32 +0200 (CEST) Received: from mail-ej1-f49.google.com (mail-ej1-f49.google.com [209.85.218.49]) by mails.dpdk.org (Postfix) with ESMTP id 5982041448 for ; Mon, 19 Apr 2021 22:36:31 +0200 (CEST) Received: by mail-ej1-f49.google.com with SMTP id r9so54957678ejj.3 for ; Mon, 19 Apr 2021 13:36:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iol.unh.edu; s=unh-iol; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=/23I7viiOHIDleF2QNLcq3rt8+RbbOCvKtPi1MHaisw=; b=JB62LcWiuyIr4xVzrj7/OWNFmcCrwuSjFulyIW2sYLGsQuFkgzR0lB7f12fYbus3h3 unHWQbtK8HOM533N3YB8ZNuj7iW+iLVEgbAQaBJhaD3CY+a+rl03kRweGJ09aBdJpPNy XfDLmdYV/ViYjVQnfsrWVQvqOuyV4PUPuvSrs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=/23I7viiOHIDleF2QNLcq3rt8+RbbOCvKtPi1MHaisw=; b=W3g6aw0byIiT/OZbeCNPbduIx2exSoKStspYUqvzpmuu1e+rqURvLbfuDnVMNc9p99 jbp74fb3U5+6XqkPAdfwaNnroh2kZER1YRFzL/8n8hT94Z9xKksQWhUDX1Qwq7dcjv4j Znt/6ECADABMKJc8kgQgvfzFrfPf43a75Cm76su1bPjbbm5f84rqsDi6u8hJj0VTaVQx zNjaqLT57uH7MU8A+5Qr9kVm1IdPVSKJax0Bh64uem8sh6zg6o6/pGu6T98nN+9Zft9t kgMT9dLuJfHZjacXuES3wPP+vqB2beho+kkkuLw60KGwJ7jjYnqQ5B3qeoB3KYV3kFVo oQYQ== X-Gm-Message-State: AOAM531SynOyANX2kGC7h+la3qBq+YEe4F2THpN/4rpKDendg+FudgwC b5bZpzjv8iFxi8+dlrghxitsIAWF8ppjlWJ+54S0ig== X-Google-Smtp-Source: ABdhPJzOvtL2dTdbyIizpbtqBsqambD2XHuf7Jbisl4eDZM79ew0qFMWyUJNMAMk34eWK4hdqsrrX6HWbou6gN4/rUY= X-Received: by 2002:a17:906:b156:: with SMTP id bt22mr19959655ejb.181.1618864590958; Mon, 19 Apr 2021 13:36:30 -0700 (PDT) MIME-Version: 1.0 References: <20210418170803.15684-1-talshn@nvidia.com> <3259972.HMeeyuY8TW@thomas> <20210419230936.04e2f95c@sovereign> In-Reply-To: <20210419230936.04e2f95c@sovereign> From: Lincoln Lavoie Date: Mon, 19 Apr 2021 16:33:15 -0400 Message-ID: To: Dmitry Kozlyuk Cc: Aaron Conole , Thomas Monjalon , Tal Shnaiderman , "dev@dpdk.org" , "pallavi.kadam@intel.com" , "navasile@linux.microsoft.com" , "dmitrym@microsoft.com" , ci@dpdk.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [dpdk-dev] [dpdk-ci] [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" Is that related to a recent patch (I think it was David's, but don't quote me on that) that enabled a debug build mode when it sees git repo info within the build root? Cheers, Lincoln On Mon, Apr 19, 2021 at 4:09 PM Dmitry Kozlyuk wrote: > 2021-04-19 15:29 (UTC-0400), Aaron Conole: > > Thomas Monjalon writes: > > > > > 19/04/2021 20:06, Tal Shnaiderman: > > >> > > 2021-04-18 19:04 (UTC+0000), Tal Shnaiderman: > > >> > > > > 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=..."? > > >> > > > >> > This is the meson line I'm using: > > >> > > > >> > meson "-Dexamples=helloworld" build --wipe --default-library=static > -- > > >> > buildtype debug > > >> > > > >> > The problem however is that MinGW's string.h defines the macro in > line 119, > > >> > 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_shim.h: > > >> > > >> [185/314] Compiling C object drivers/a715181@@tmp_rte_common_mlx5@sta > /common_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 pasting of ',' and __VA_ARGS__ is a GNU extension > > >> [-Wgnu-zero-variadic-macro-arguments] > > >> #define open(path, flags, ...) _open(path, flags, ##__VA_ARGS__) > > >> ^ > > >> However don't see it in CI, I'm using clang version 9.0.1 > > > > > > It seems we should improve our CI. > > > Please open suggestions in the CI bugzilla. > > > > Please do. > > > > Will this only be caught by mingw64 on windows? Will we get the same > > issues with a linux mingw install? I'm guessing yes, but don't know > > mingw very well. We may be able to install the mingw package under our > > github actions pipeline. > > Yes, Linux MinGW-w64 produces the same warning (about strncasecmp). > __VA_ARGS__ warning won't show up with GNU compiler, obviously. > It may with ICC, but I don't have it to check. > > I figured out it's not --default-library=static, but --buildtype=debug that > caues the arning to appear, my mistake in previous message. > -- *Lincoln Lavoie* Principal Engineer, Broadband Technologies 21 Madbury Rd., Ste. 100, Durham, NH 03824 lylavoie@iol.unh.edu https://www.iol.unh.edu +1-603-674-2755 (m)