[Gambas-user] Same problem as MJ in late Nov 2004....
Ron Onstenk
ronstk at ...239...
Mon Jan 31 21:20:58 CET 2005
On Monday 31 January 2005 11:22, David Edmiston wrote:
| On Tuesday 30 November 2004 11:37, MJ wrote:
| > CXmlRpc.c:31:30: libxml/xmlwriter.h: No such file or directory
|
| Rob wrote...
|
| You"re missing the libxml headers. In Mandrake, the package you
| would need is libxml2-devel. I think this became necessary in
| RC2 or RC3.
|
| Rob
|
|
| Rob et al... I get the same compilation error messages exactly, except
| that I have libxml-devel installed in my RH9 system
|
| Ideas?
|
| David Edmiston
|
|
Oeps, compile does not go OK.
Sorry if it is to long but this was under my pen.
Found this problem too. libxml-devel is installed
*********************************************************************************************
Making all in xml
make[4]: Entering directory `/usr/local/src/gambas2-1.9.2/src/lib/xml'
Making all in libxml
make[5]: Entering directory `/usr/local/src/gambas2-1.9.2/src/lib/xml/libxml'
Making all in xslt
make[6]: Entering directory `/usr/local/src/gambas2-1.9.2/src/lib/xml/libxml/xslt'
if /bin/sh ../../../../../libtool
--mode=compile gcc
-DHAVE_CONFIG_H
-I. -I. -I../../../../.. -I../../../../../src/share
-I/usr/include/libxml2
-g -O2 -pipe -Wall -fno-strict-aliasing -g -Os
-MT main.lo -MD -MP -MF ".deps/main.Tpo" -c -o main.lo main.c; \
then mv -f ".deps/main.Tpo" ".deps/main.Plo"; else rm -f ".deps/main.Tpo"; exit 1; fi
----8<----------
make[6]: Leaving directory `/usr/local/src/gambas2-1.9.2/src/lib/xml/libxml/xslt'
Making all in rpc
make[6]: Entering directory `/usr/local/src/gambas2-1.9.2/src/lib/xml/libxml/rpc'
if /bin/sh ../../../../../libtool
--mode=compile gcc -DHAVE_CONFIG_H
-I. -I. -I../../../../.. -I../../../../../src/share
-I/usr/include/libxml2
-g -O2 -pipe -Wall -fno-strict-aliasing -g-Os
-MT main.lo -MD -MP -MF ".deps/main.Tpo" -c -o main.lo main.c; \
then mv -f ".deps/main.Tpo" ".deps/main.Plo"; else rm -f ".deps/main.Tpo"; exit 1; fi
-------8<--------
XmlRpc.c -fPIC -DPIC -o .libs/CXmlRpc.o
CXmlRpc.c:31:30: libxml/xmlwriter.h: No such file or directory
CXmlRpc.c: In function `CXMLRPC_Call':
CXmlRpc.c:119: error: `xmlTextWriterPtr' undeclared (first use in this function)
-----8<------
make[1]: Leaving directory `/usr/local/src/gambas2-1.9.2'
make: *** [all] Error 2
*********************************************************************************************
GB_COMPONENT_PKG_CONFIG(
libxml,
LIBXML,
[XML parser component],
[libxml],
libxml-2.0)
dnl GB_COMPONENT(
dnl libxml,
dnl LIBXML,
dnl [XML parser component],
dnl [GB_FIND(libxml, /usr/local/lib /usr/local /opt /usr/lib /usr, include/libxml* include)],
dnl [GB_FIND(libxml2.$SHLIBEXT, /usr/local /opt /usr, lib)],
dnl [$C_LIB $THREAD_LIB -lxml2 -lm],
dnl [$THREAD_INC])
GB_COMPONENT(
xslt,
XSLT,
[XSLT/XML parser component],
[xslt],
[GB_FIND(libxslt, /usr/local/lib /usr/local /opt /usr/lib /usr, include/libxml* include/libxsl
t* include)],
[GB_FIND(libxslt.$SHLIBEXT, /usr/local /opt /usr, lib)],
[$LIBXML_LIB -lxslt])
dnl ---- Perl Compatible Regular Expression component
*********************************************************************************************
By the change to use GB_COMPONENT_PKG_CONFIG the include is broken.
libxml provides "xml2-config" and that is pointing to the correct include path
SuSE system has it in /usr/bin for the distributed rpm's.
If the provided version, curl in 8.2, is to old then the user add the
newer version in /usr/local and the "xml2-config" is in /usr/local/bin for new
development.
The "/usr/bin/xml2-config" is for distributed rpm's world wide.
Gambas version 1.0.2 uses the "xml2-config" one and compiles OK. 1.9.2 does not.
GB_COMPONENT_PKG_CONFIG should look in "/usr/local/bin" first, then in "/usr" for
a "xxxxx-config" executable, if not found then the /usr/pkgconfig system can be safe
used.
/usr/local/lib/pkgconfig can also exist and must be used before /usr/lib/pkgconfig
to manage updates from pkgconfig.
This is in respect that packages compiled with prefix=/usr/local and creates the
pkgconfig xxxxx.pc file put it in /usr/local/lib/pkgconfig as is done by i.e.
'fluidsynth' instead of /usr/lib/pkgconfig.
I beleave that a xxxx-config, is the most correct one, however the pkgconfig is
overall more informative and have advantages above the xxxx-config.
There are packages providing none, xxx-config, xxxxx.pc or both systems.
For the XML component it is the 'xmlwriter.h' that is missing in the old SuSE 8.2
package and a update of the systems xml2 breaks the other packages from SuSE,
Yast depends on the old one. It stopped working after xml2 update in /usr/lib
and was repaired by installing the original and the updated for gambas in /usr/local/lib.
No dll hell anymore but a lib hell instead with linux :=)
terminator: # pkg-config --modversion libxml-2.0
2.5.11
terminator: # pkg-config --cflags libxml-2.0
-I/usr/include/libxml2
**
** the orginal provided by SuSE 8.2 !! *
terminator: # xml2-config --version
2.6.13
terminator: # xml2-config --prefix
/usr/local
**
** this is the file in /usr/local/bin instead the original in /usr/bin !! **
terminator: # pkg-config --define-variable=prefix=/usr --cflags libxml-2.0
-I/usr/include/libxml2
terminator: # pkg-config --define-variable=prefix=/usr/local --cflags libxml-2.0
-I/usr/local/include/libxml2
terminator: # pkg-config --define-variable=prefix=/usr --modversion libxml-2.0
2.5.11
terminator: # pkg-config --define-variable=prefix=/usr/local --modversion libxml-2.0
2.5.11
**
** this is modifying the /usr to /usr/local OK, but version is wrong **
Several tests told me pkg-config is only working on the /usr/lib and not /usr/local/lib
and disregards local updates from user (sysadmin).!
using the following script:
#!/bin/sh
cd gambas2-1.9.2
./reconf
./configure --prefix=/opt \
--enable-libxml \
--with-include-xml=/usr/local/include \
--with-lib-xml=/usr/local/lib \
--enable-xslt \
--with-xslt-includes=/usr/include \
--with-xslt-libraries=/usr/lib \
make
gives still the error.
In config.log :
configure:#####: checking for XML parser.... with pkg-config
and
LIBXML_DIR='libxml'
LIBXML_INC='-I/usr/include/libxml2 '
LIBXML_LIB='-lxml2 -lptread -lz -lm'
XSLT_DIR='xslt'
XSLT_INC=' -I/usr/include'
XSLT_LIB=' -L/usr/lib -lxml2 -lptread -lz -lm -lxslt'
XSLT_PATH='/usr/lib/..'
I can't use XML now, in gambas2 but it works in gambas1 :(
pkg-config is not a good idea after all, I think.
---------
Ron O
More information about the User
mailing list