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 5DE1AA0548; Mon, 19 Apr 2021 20:55:27 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3599141448; Mon, 19 Apr 2021 20:55:27 +0200 (CEST) Received: from mail-lj1-f174.google.com (mail-lj1-f174.google.com [209.85.208.174]) by mails.dpdk.org (Postfix) with ESMTP id D32AC413DE for ; Mon, 19 Apr 2021 20:55:25 +0200 (CEST) Received: by mail-lj1-f174.google.com with SMTP id m7so29789723ljp.10 for ; Mon, 19 Apr 2021 11:55:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=pcKO3a3oN3oPzjxxZvYCvkQ7xC8N/Mpl5yq2jq5rMB8=; b=GSn5mAZanxbbrDT0sn7Yne5HJYyOLp1w9f7HbW+klOH1tDx9sJchkSH9Yl0o/T9hg8 WhnFDio6dbb8WuJ/74SY9UI3uf9yN5FgOkTEt7yrLeObehAMLIfyS3vBFgnK0F83+5jn zqi4sViixxboIs9fcrQZPMnBUvZq/eV5GxJIFNeI39BVjobBM3SZ1UaC/sAVCS4y2Fe2 KDxGPpuwLpSmlaUJfZ46wOtYYpKI15y3lsP77m9oIvvg+xbKowyKWwIX+LAXqewezsJy aoSwp86ZhuinwGh01irdqhdPjK225qYcrioMhuTvQQY4a01KCKMBYU8lPLyo6Z1WUPyL fj2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=pcKO3a3oN3oPzjxxZvYCvkQ7xC8N/Mpl5yq2jq5rMB8=; b=CU16gCmPp0t9Z1eYliV23EZUm64Bu1Vvdn4IpcSaxz05ThVZmHQNTPvfJ6Xy8JUHS3 IIzvF5t52jArLm243aVsGdFcgMxLaSaywM/iNAtEqN9vYaMXHhuDdMqjH7pHRENAmoF5 WajoRKFbDSmxuomjZBDM8YRX1DJxaomzxQ7mqpj3n3JCljbKo4ahqUaiEBNlB1ezrn0l B/R77gzeBpbPxA92wR8nc8R8xHTIw1k1IIOfP4rUBNiwNlXq+z5OP6VFd4xcmhk+7CeK 3GX7HE5sEBNZFGkS/tS6ohmxshxwMuU1MoAaXL3s22Ci9fa2doKflHTWUEHnQMBZC0qC +1kw== X-Gm-Message-State: AOAM532j4V+eNWdqy5cBFmjyF0eV7b6bdv6PU+RAF15ixD4eaxnHCcEa JbYp05uM1aQVNemYSRsuk3k= X-Google-Smtp-Source: ABdhPJySNrUpql4/+FRizlB572nIz9LcvTr+sA5bAUsuOCGbFUPLtxAVtqjw/diXmcn0zM99FqSg3A== X-Received: by 2002:a2e:5c49:: with SMTP id q70mr11782503ljb.364.1618858525370; Mon, 19 Apr 2021 11:55:25 -0700 (PDT) Received: from sovereign (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id j21sm1194885lja.39.2021.04.19.11.55.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Apr 2021 11:55:24 -0700 (PDT) Date: Mon, 19 Apr 2021 21:55:23 +0300 From: Dmitry Kozlyuk To: Tal Shnaiderman Cc: NBU-Contact-Thomas Monjalon , "dev@dpdk.org" , "pallavi.kadam@intel.com" , "navasile@linux.microsoft.com" , "dmitrym@microsoft.com" Message-ID: <20210419215523.33725f13@sovereign> In-Reply-To: References: <20210418170803.15684-1-talshn@nvidia.com> <2018619.JnGxiWPmQR@thomas> <20210418232330.2471f913@sovereign> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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" 2021-04-19 06:57 (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. --default-library=static it the key, it changes MinGW from using inline functions to using macros for strncasecmp(). MinGW portion devtools/check-meson-builds.sh should test this variant. I searched for other defines from rte_os_shim.h in MinGW includes and it seems strncasecmp() is the only problematic one. Thanks, I'm ready to ack v2 as soon as you send it.