GConf and libxml....



hi all,

I have seen the folowing problem more than once in the past 2 years but
I have not folowed Gnome development closely recently which is why I
have not commited the fix on my own.

So, in (gconftool.c), there is:
#include <libxml/tree.h>
#include <libxml/parser.h>
#include <libxml/xmlmemory.h>

The build fails with:
gconftool.c: In function `extract_global_info':
gconftool.c:1729: structure has no member named `childs'
....
....

I have both libxml1 and libxml2 installed on my machine: they are both
installed in /usr/local:
[root mathieu gconf]# xml2-config --cflags
-I/usr/local/include/libxml -I/usr/local/include

[root mathieu gconf]# xml-config --cflags
-I/usr/local/include/gnome-xml

Looking in these two include directories, I see:
[root mathieu gconf]# ls /usr/local/include/gnome-xml/
HTMLparser.h  SAX.h       encoding.h  nanoftp.h   parser.h          
tree.h  valid.h  xml-error.h  xmlmemory.h
HTMLtree.h    debugXML.h  entities.h  nanohttp.h  parserInternals.h 
uri.h   xlink.h  xmlIO.h      xpath.h

[root mathieu gconf]# ls /usr/local/include/libxml/      
DOCBparser.h  catalog.h   hash.h     nanohttp.h         uri.h      
xmlIO.h       xmlwin32version.h
HTMLparser.h  debugXML.h  libxml     parser.h           valid.h    
xmlerror.h    xpath.h
HTMLtree.h    encoding.h  list.h     parserInternals.h  xinclude.h 
xmlmemory.h   xpathInternals.h
SAX.h         entities.h  nanoftp.h  tree.h             xlink.h    
xmlversion.h  xpointer.h

Obviously, the correct patch to get the stuff to build is:
-#include <libxml/tree.h>
-#include <libxml/parser.h>
-#include <libxml/xmlmemory.h>
+#include <tree.h>       /* libxml */
+#include <parser.h>     /* libxml */
+#include <xmlmemory.h>  /* libxml */

I thought personally that libxml2 was supposed to allow users to use
things such as:
#include <libxml/tree.h>
#include <libxml/parser.h>
#include <libxml/xmlmemory.h>

Which does not seem to be the case on my system (I have built with
tarballs, without using any configure flag).

Before someone asks:
[root mathieu gconf]# xml2-config --version
2.4.3
[root mathieu gconf]# xml-config --version
1.8.15

So, there are two issues:
	- should someone "fix" GConf for libxml1 usage ?
	- is it normal that libxml2 should be still "broken" in regard to this
header issue ?

regards,
Mathieu
-- 
Mathieu Lacage <mathieu gnu org>




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