]> code.delx.au - pulseaudio/commitdiff
win32: define WIN32_LEAN_AND_MEAN
authorMaarten Bosmans <mkbosmans@gmail.com>
Tue, 7 Jun 2011 21:46:08 +0000 (23:46 +0200)
committerArun Raghavan <arun.raghavan@collabora.co.uk>
Sun, 12 Jun 2011 18:14:59 +0000 (11:14 -0700)
This makes windows.h include less headers.
Otherwise boolean is typedef'ed and that clashes with libjson.

configure.ac
src/pulsecore/dllmain.c

index 9d388ef326d586bc16651be33892c4e5248bb3cd..56d4e6325fa385f34408d86f90e95684f3e4060f 100644 (file)
@@ -91,6 +91,9 @@ case $host in
    *-*-darwin* )
       AC_DEFINE([_DARWIN_C_SOURCE], [200112L], [Needed to get NSIG on Mac OS X])
       ;;
+   *-*-mingw* )
+      AC_DEFINE([WIN32_LEAN_AND_MEAN], 1, [Needed to avoid including unnecessary headers])
+      ;;
 esac
 
 # M4
index c826bc0893cb7b07a1a43bad0d4d23340c9f95fa..cb88c92834c6ef781ce3b36a6c6b9eb643e61c71 100644 (file)
@@ -30,6 +30,7 @@
 #include <string.h>
 
 #include <windows.h>
+#include <winsock2.h>
 
 extern pa_win32_get_toplevel(HANDLE handle);