libxml2-mingw.patch (4ee0f98c) libxml2-mingw.patch (887c5134)
1--- misc/libxml2-2.7.6/configure 2008-01-11 17:01:56.000000000 +0900
2+++ misc/build/libxml2-2.7.6/configure 2009-09-07 20:48:47.656250000 +0900
3@@ -19914,6 +19914,8 @@
1--- misc/libxml2-2.7.8/configure 2008-01-11 17:01:56.000000000 +0900
2+++ misc/build/libxml2-2.7.8/configure 2009-09-07 20:48:47.656250000 +0900
3@@ -13566,6 +13566,8 @@
4
5 if test "$with_modules" != "no" ; then
6 case "$host" in
7+ *-*-mingw*)
8+ ;;
9 *-*-cygwin*)
10 MODULE_EXTENSION=".dll"
4
5 if test "$with_modules" != "no" ; then
6 case "$host" in
7+ *-*-mingw*)
8+ ;;
9 *-*-cygwin*)
10 MODULE_EXTENSION=".dll"
11 { $as_echo "$as_me:$LINENO: checking for dlopen in -lcygwin" >&5
12@@ -20632,11 +20636,10 @@
11 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lcygwin" >&5
12@@ -13868,11 +13868,10 @@
13
14 fi
15 case $host_os in
16- *mingw32*) if test "$THREAD_LIBS" != "-lpthread"; then
17+ *mingw32*)
18 WITH_THREADS="1"
19 THREADS_W32="Win32"
20 THREAD_CFLAGS="$THREAD_CFLAGS -DHAVE_WIN32_THREADS"
21- fi
22 ;;
23 *cygwin*) THREAD_LIBS=""
24 ;;
13
14 fi
15 case $host_os in
16- *mingw32*) if test "$THREAD_LIBS" != "-lpthread"; then
17+ *mingw32*)
18 WITH_THREADS="1"
19 THREADS_W32="Win32"
20 THREAD_CFLAGS="$THREAD_CFLAGS -DHAVE_WIN32_THREADS"
21- fi
22 ;;
23 *cygwin*) THREAD_LIBS=""
24 ;;
25--- misc/libxml2-2.7.6/libxml.h 2007-11-23 19:47:23.000000000 +0900
26+++ misc/build/libxml2-2.7.6/libxml.h 2009-07-10 14:37:34.988250000 +0900
25--- misc/libxml2-2.7.8/libxml.h 2007-11-23 19:47:23.000000000 +0900
26+++ misc/build/libxml2-2.7.8/libxml.h 2009-07-10 14:37:34.988250000 +0900
27@@ -30,6 +30,10 @@
28 #include <libxml/xmlversion.h>
29 #else
30 #include "config.h"
31+#ifdef __MINGW32__
32+#undef HAVE_LIBPTHREAD
33+#undef HAVE_PTHREAD_H
34+#endif
35 #include <libxml/xmlversion.h>
36 #endif
37
27@@ -30,6 +30,10 @@
28 #include <libxml/xmlversion.h>
29 #else
30 #include "config.h"
31+#ifdef __MINGW32__
32+#undef HAVE_LIBPTHREAD
33+#undef HAVE_PTHREAD_H
34+#endif
35 #include <libxml/xmlversion.h>
36 #endif
37
38--- misc/libxml2-2.7.6/include/libxml/xmlexports.h 2009-09-25 00:31:59.000000000 +0900
39+++ misc/build/libxml2-2.7.6/include/libxml/xmlexports.h 2010-06-06 11:15:54.160750000 +0900
40@@ -113,7 +113,7 @@
41 * _imp__xmlFree listed as missing. Try to workaround the problem
42 * by also making that declaration when compiling client code.
43 */
44- #if !defined(LIBXML_STATIC)
45+ #if defined(IN_LIBXML) && !defined(LIBXML_STATIC)
46 #define XMLPUBFUN __declspec(dllexport)
47 #define XMLPUBVAR __declspec(dllexport)
48 #else