From 8730ed52976712ec9e0cd98afc997d6ad88f0adf Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Sat, 2 Apr 2016 09:21:55 +0100 Subject: [PATCH] Windows: compile with /D_CRT_SECURE_NO_WARNINGS. With all due respect to Microsoft, a cross-platform program simply cannot switch to using MS's assorted 'secure' versions of standard C functions if it wants to continue compiling on platforms other than Windows. So I might as well squash the warnings, so that any other more interesting compiler warnings can avoid being swamped in the mess. --- mkfiles.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkfiles.pl b/mkfiles.pl index 46ae3189..a96aa9ae 100755 --- a/mkfiles.pl +++ b/mkfiles.pl @@ -636,7 +636,7 @@ if (defined $makefiles{'vc'}) { "# C compilation flags\n". "CFLAGS = /nologo /W3 /O1 " . (join " ", map {"-I$dirpfx$_"} @srcdirs) . - " /D_WINDOWS /D_WIN32_WINDOWS=0x500 /DWINVER=0x500\n". + " /D_WINDOWS /D_WIN32_WINDOWS=0x500 /DWINVER=0x500 /D_CRT_SECURE_NO_WARNINGS\n". "LFLAGS = /incremental:no /fixed\n". "RCFLAGS = ".(join " ", map {"-I$dirpfx$_"} @srcdirs). " -DWIN32 -D_WIN32 -DWINVER=0x0400\n".