diff --git a/CMakeLists.txt b/CMakeLists.txt
index e6b30f2bcea3c1d422d4e13c62b97ff06413dee4..ed63026eb4b6211e0be7bac7521bae0a63c2187e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -82,7 +82,7 @@ if(WIN32)
   add_definitions("-DHAVE_PREAD")
   add_definitions("-DHAVE_MMAP")
   add_definitions("-DHAVE_STRNDUP")
-  add_definitions("-DWINVER=0x0600 -D_WIN32_WINNT=0x0600")
+  add_compile_definitions(WINVER=0x0600 _WIN32_WINNT=0x0600)
 
   if(DAP_RELEASE)
     set(_CCOPT "-static -std=gnu11 -Wall -O3 -fno-ident -ffast-math -ftree-vectorize -mfpmath=sse -mmmx -msse2 -fno-asynchronous-unwind-tables -ffunction-sections -Wl,--gc-sections -Wl,--strip-all")
diff --git a/sources/main.c b/sources/main.c
index 67eb8b33e6382dd57cc4c35dff95f346d8653f13..fa798513cc4e4a98824a398efda3b73f1393bbe8 100755
--- a/sources/main.c
+++ b/sources/main.c
@@ -39,7 +39,6 @@
 #include <mswsock.h>
 #include <ws2tcpip.h>
 #include <io.h>
-//#include "wrappers.h"
 #include <pthread.h>
 #include "userenv.h"
 
diff --git a/sources/main_node_cli_net.c b/sources/main_node_cli_net.c
index 35c81bbab7b9e45875dd9be24877921df6310238..7a8006dc0e672b164f13710f4d860ba5c0d7aca4 100644
--- a/sources/main_node_cli_net.c
+++ b/sources/main_node_cli_net.c
@@ -44,7 +44,6 @@
 #include <mswsock.h>
 #include <ws2tcpip.h>
 #include <io.h>
-//#include "wrappers.h"
 #include <pthread.h>
 #else
 #include <sys/socket.h>
diff --git a/sources/main_node_cli_shell.c b/sources/main_node_cli_shell.c
index 797d81778608bb26183343f6ad45e15bafad0ebd..c72067016439ef04871b1be835a0f4fe0c5f9a20 100644
--- a/sources/main_node_cli_shell.c
+++ b/sources/main_node_cli_shell.c
@@ -20,7 +20,6 @@
 #include <mswsock.h>
 #include <ws2tcpip.h>
 #include <io.h>
-//#include "wrappers.h"
 #include <pthread.h>
 #else
 #include <sys/ttydefaults.h>
diff --git a/sources/main_node_tool.c b/sources/main_node_tool.c
index f9185835270f6d53a45d12b96be2f196682ee44c..404b2da0c82ddd7c87a1cdf56f81eee7d20c3326 100644
--- a/sources/main_node_tool.c
+++ b/sources/main_node_tool.c
@@ -34,7 +34,6 @@
 #include <mswsock.h>
 #include <ws2tcpip.h>
 #include <io.h>
-//#include "wrappers.h"
 #endif
 
 #include <pthread.h>