[xml] [PATCH] Compile failure using libxml/globals.h from latest GIT head
- From: Paul Smith <psmith gnu org>
- To: xml gnome org
- Subject: [xml] [PATCH] Compile failure using libxml/globals.h from latest GIT head
- Date: Thu, 3 Sep 2009 14:46:22 -0400
Hi all;
I'm trying to compile Evolution on my system. It needs a newer libxml2
than is packaged for my system (Ubuntu 9.04) so I grabbed the latest git
HEAD and built and installed that in a separate location and configured
my builds to look there first.
Now when I compile evolution-data-server I'm seeing this error:
gcc -DHAVE_CONFIG_H -I. -I../../../../../evolution-data-server/servers/google/libgdata -I../../..
-DG_LOG_DOMAIN=\"libgdata\" -I../../../../../evolution-data-server -I../../.. -I/opt/evo/include/libxml2
-I/usr/include/libsoup-2.4 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -g -MT gdata-entry.lo
-MD -MP -MF .deps/gdata-entry.Tpo -c -o gdata-entry.lo
../../../../../evolution-data-server/servers/google/libgdata/gdata-entry.c
In file included from /opt/evo/include/libxml2/libxml/xmlIO.h:118,
from /opt/evo/include/libxml2/libxml/parser.h:803,
from ../../../../../evolution-data-server/servers/google/libgdata/gdata-entry.c:29:
/opt/evo/include/libxml2/libxml/globals.h:365: error: duplicate 'extern'
Looking at libxml/globals.h I see this at that line:
LIBXML_DLL_IMPORT extern void * xmlStructuredErrorContext;
This is incorrect on my system, because LIBXML_DLL_IMPORT is #defined to
be XMLPUBVAR, which is defined to be extern, so this resolves to:
extern extern void * xmlStructuredErrorContext;
and hence the error. I'm assuming, from the surrounding code, this
should have been XMLPUBVAR void * .... Attached is a patch to that
effect.
* include/libxml/globals.h: Use XMLPUBFUN rather than
LIBXML_DLL_IMPORT extern for xmlStructuredErrorContext
diff --git a/include/libxml/globals.h b/include/libxml/globals.h
index e74e1b1..d6fde7c 100644
--- a/include/libxml/globals.h
+++ b/include/libxml/globals.h
@@ -362,7 +362,7 @@ XMLPUBFUN void * * XMLCALL
__xmlStructuredErrorContext(void);
#define xmlStructuredErrorContext \
(*(__xmlStructuredErrorContext()))
#else
-LIBXML_DLL_IMPORT extern void * xmlStructuredErrorContext;
+XMLPUBFUN void * xmlStructuredErrorContext;
#endif
XMLPUBFUN int * XMLCALL __xmlGetWarningsDefaultValue(void);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]