[dpdk-dev] [PATCH] eal/windows: fix build warnings in MinGW

Thomas Monjalon thomas at monjalon.net
Sun Apr 18 20:13:51 CEST 2021


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?

> Fixed by defining the marco only to the clang compiler.

That's a very common typo: s/marco/macro/





More information about the dev mailing list