[evolution-data-server/gnome-2-30] Don't dupplicate wspiapi.h internally This will put the responsibility to load a libary correctly to



commit a1e2670ff27d5c4d865551a07b256e12cad5c736
Author: Fridrich Å trba <fridrich strba bluewin ch>
Date:   Mon Sep 13 23:49:55 2010 +0200

    Don't dupplicate wspiapi.h internally
    This will put the responsibility to load a libary correctly to the
    one who implements teh wspiapi.h header.

 camel/Makefile.am             |    3 +-
 camel/camel-net-utils-win32.h |  381 -----------------------------------------
 camel/camel-net-utils.c       |    6 +-
 configure.ac                  |    3 +
 4 files changed, 9 insertions(+), 384 deletions(-)
---
diff --git a/camel/Makefile.am b/camel/Makefile.am
index 1f2e26d..bbb0b0c 100644
--- a/camel/Makefile.am
+++ b/camel/Makefile.am
@@ -2,8 +2,7 @@ SUBDIRS = . providers tests
 
 if OS_WIN32
 LIBCAMEL_PLATFORM_DEP_SOURCES = \
-	camel-win32.c \
-	camel-net-utils-win32.h
+	camel-win32.c
 LIBCAMEL_PROVIDER_PLATFORM_DEP_SOURCES =
 LOCK_HELPER =
 else
diff --git a/camel/camel-net-utils.c b/camel/camel-net-utils.c
index 3ca1ae1..aa97ce0 100644
--- a/camel/camel-net-utils.c
+++ b/camel/camel-net-utils.c
@@ -35,7 +35,11 @@
 #include "camel-msgport.h"
 #include "camel-net-utils.h"
 #ifdef G_OS_WIN32
-#include "camel-net-utils-win32.h"
+#include <winsock2.h>
+#include <ws2tcpip.h>
+#ifdef HAVE_WSPIAPI_H
+#include <wspiapi.h>
+#endif
 #endif
 #include "camel-operation.h"
 
diff --git a/configure.ac b/configure.ac
index faffef0..f648675 100644
--- a/configure.ac
+++ b/configure.ac
@@ -933,6 +933,9 @@ fi
 
 AM_CONDITIONAL(ENABLE_IPv6, [test "x$enable_ipv6" = "xyes"])
 
+AC_CHECK_HEADER([wspiapi.h],
+	[AC_DEFINE([HAVE_WSPIAPI_H], 1, [Have <wspiapi.h>])],,)
+
 dnl ******************************
 dnl Calendar support
 dnl ******************************



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]