Microsoft considers these POSIX function names to be deprecated, and
provides alternative names starting with an underscore. A deprecation
warning is raised if the old names are used, which can be disabled
with the _CRT_NONSTDC_NO_WARNINGS macro.

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-3-c4996?view=msvc-170#posix-function-names

Signed-off-by: Antonin Décimo <anto...@tarides.com>
---
 mingw-w64-libraries/winpthreads/Makefile.am | 1 +
 1 file changed, 1 insertion(+)

diff --git a/mingw-w64-libraries/winpthreads/Makefile.am 
b/mingw-w64-libraries/winpthreads/Makefile.am
index 56f5cd3a2..54eca7b81 100644
--- a/mingw-w64-libraries/winpthreads/Makefile.am
+++ b/mingw-w64-libraries/winpthreads/Makefile.am
@@ -16,6 +16,7 @@ libwinpthread_la_SOURCES = \
 
 if MSVC
 AM_CFLAGS += -nologo
+libwinpthread_la_CPPFLAGS += -D_CRT_NONSTDC_NO_WARNINGS
 else
 libwinpthread_la_CPPFLAGS += -D__USE_MINGW_ANSI_STDIO=0
 libwinpthread_la_LDFLAGS += -L$(builddir)/fakelib -Wc,-no-pthread
-- 
2.43.0



_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to