diff --git a/Recipe b/Recipe
index 6d50f588..bac258f1 100644
--- a/Recipe
+++ b/Recipe
@@ -131,10 +131,7 @@
# Additional text added verbatim to each individual Makefile.
!begin vc vars
-CFLAGS = $(CFLAGS) /DHAS_GSSAPI /DSECURITY_WIN32
-!end
-!begin cygwin vars
-CFLAGS += -DSECURITY_WIN32
+CFLAGS = $(CFLAGS) /DHAS_GSSAPI
!end
# `make install' target for Unix.
diff --git a/mkfiles.pl b/mkfiles.pl
index 977bcef4..fa05472e 100755
--- a/mkfiles.pl
+++ b/mkfiles.pl
@@ -1159,7 +1159,7 @@ if (defined $makefiles{'vstudio10'} || defined $makefiles{'vstudio12'}) {
" true\n" .
" Level3\n" .
" " . (join ";", map {"..\\..\\$dirpfx$_"} @srcdirs) . ";%(AdditionalIncludeDirectories)\n" .
- " WIN32;NDEBUG;_WINDOWS;SECURITY_WIN32;POSIX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)\n" .
+ " WIN32;NDEBUG;_WINDOWS;POSIX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)\n" .
" .\\Release\\\n" .
" .\\Release\\$windows_project.pch\n" .
" .\\Release\\\n" .
@@ -1198,7 +1198,7 @@ if (defined $makefiles{'vstudio10'} || defined $makefiles{'vstudio12'}) {
" true\n" .
" ProgramDatabase\n" .
" " . (join ";", map {"..\\..\\$dirpfx$_"} @srcdirs) . ";%(AdditionalIncludeDirectories)\n" .
- " WIN32;_DEBUG;_WINDOWS;SECURITY_WIN32;POSIX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)\n" .
+ " WIN32;_DEBUG;_WINDOWS;POSIX;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)\n" .
" .\\Debug\\\n" .
" .\\Debug\\$windows_project.pch\n" .
" .\\Debug\\\n" .
diff --git a/windows/wingss.c b/windows/wingss.c
index 237b3890..d08064d4 100644
--- a/windows/wingss.c
+++ b/windows/wingss.c
@@ -2,6 +2,7 @@
#include "putty.h"
+#define SECURITY_WIN32
#include
#include "pgssapi.h"
diff --git a/windows/winmisc.c b/windows/winmisc.c
index 3b57adf8..82216587 100644
--- a/windows/winmisc.c
+++ b/windows/winmisc.c
@@ -5,6 +5,7 @@
#include
#include
#include "putty.h"
+#define SECURITY_WIN32
#include
OSVERSIONINFO osVersion;