[libxml++] Ver. 2.6 vs 2.7 installation question
- From: Vladislav Grinchenko <3rdshift comcast net>
- To: libxml++ List <libxmlplusplus-general lists sourceforge net>
- Cc: 3rdshift comcast net
- Subject: [libxml++] Ver. 2.6 vs 2.7 installation question
- Date: Sat, 07 Aug 2004 15:23:02 -0400
Hi,
first off, thanks for writing and maintaining libxml++ - it greately
simplifies parsing XML files.
I have an app that used ver libxml++-0.26.0 till now on
Fedora Core 2 with libxml2-2.6.8.
The question I have is about a proper way of detecting
the version (and cflags/libs parms) of libxml++ installed.
Here's what I've discovered:
CASE 1) When libxml++ 0.26.0 is installed from an RPM package
packaged by Fedora Linux this is what's installed
Name : libxml++
Relocations : (not relocatable)
Version : 0.26.0
Vendor : Fedora Linux
Release : 0.fdr.3.rh90
Build Date : Wed 12 Nov 2003 06:23:02 PM EST
Install Date: Thu 05 Aug 2004 11:03:28 PM EDT
Build Host : build-rh90
Group : System Environment/Libraries
Source RPM : libxml++-0.26.0-0.fdr.3.rh90.src.rpm
installs these files:
/usr/lib/libxml++-0.1.so.12
/usr/lib/libxml++-0.1.so.12.0.0
Name : libxml++-devel
Relocations : (not relocatable)
Version : 0.26.0
Vendor : Fedora Linux
Release : 0.fdr.3.rh90
Build Date : Wed 12 Nov 2003 06:23:02 PM EST
Install Date: Thu 05 Aug 2004 11:03:29 PM EDT
Build Host : build-rh90
Group : Development/Libraries
Source RPM : libxml++-0.26.0-0.fdr.3.
installs these files:
/usr/include/libxml++-1.0
/usr/include/libxml++-1.0/libxml++/parsers
/usr/include/libxml++-1.0/libxml++/parsers/domparser.h
/usr/include/libxml++-1.0/libxml++/parsers/parser.h
/usr/include/libxml++-1.0/libxml++/parsers/saxparser.h
/usr/lib/libxml++-0.1.a
/usr/lib/libxml++-0.1.so
/usr/lib/pkgconfig/libxml++-1.0.pc
I have no problem with this installation because I can
get the vitals from 'configure.in' like so:
PKG_CHECK_MODULES(XMLCPP, libxml++-1.0 >= 0.26.0)
AC_SUBST(XMLCPP_CFLAGS)
AC_SUBST(XMLCPP_LIBS)
CASE 2) For non-RPM system, building libxml++-2.6.1 from a tarball:
% ./configure --prefix=/usr && make && make install
/usr/include
/usr/include/libxml++-2.6
/usr/include/libxml++-2.6/libxml++
/usr/include/libxml++-2.6/libxml++/parsers
...
/usr/include/libxml++-2.6/libxml++/parsers/parser.h
/usr/lib
/usr/lib/libxml++-2.6.so.1.0.1
/usr/lib/libxml++-2.6.so.1
/usr/lib/libxml++-2.6.so
/usr/lib/libxml++-2.6.la
/usr/lib/libxml++-2.6.a
/usr/lib/pkgconfig
/usr/lib/pkgconfig/libxml++-2.6.pc
CASE 3) For non-RPM system, building libxml++-2.7.0 from a tarball:
% ./configure --prefix=/usr && make && make install
libxml++-2.7.0
==============
/usr/include
/usr/include/libxml++-2.6
/usr/include/libxml++-2.6/libxml++
/usr/include/libxml++-2.6/libxml++/parsers
/usr/include/libxml++-2.6/libxml++/parsers/parser.h
...
/usr/include/libxml++-2.6/libxml++/keepblanks.h
/usr/lib
/usr/lib/libxml++-2.6.so.1.0.2
/usr/lib/libxml++-2.6.so.1
/usr/lib/libxml++-2.6.so
/usr/lib/libxml++-2.6.la
/usr/lib/libxml++-2.6.a
/usr/lib/pkgconfig
/usr/lib/pkgconfig/libxml++-2.6.pc
------------------
DISCUSSION:
It seems that as far as pkg-config tool is concerned, the *.pc
file should have the same name in all 3 cases rather then
case 1 : /usr/lib/pkgconfig/libxml++-1.0.pc
case 2 : /usr/lib/pkgconfig/libxml++-2.6.pc
case 3 : /usr/lib/pkgconfig/libxml++-2.6.pc
Is there a problem with the way case 1 packages the files?
Should then name of PC file be libxml++2.6.pc in all 3 cases?
The installation itself is confusing too:
case 1 : /usr/include/libxml++-1.0
case 2 : /usr/include/libxml++-2.6
case 3 : /usr/include/libxml++-2.6
case 1 : /usr/lib/libxml++-0.1.so
case 2 : /usr/lib/libxml++-2.6.so
case 3 : /usr/lib/libxml++-2.6.so
Looks like there is no version difference between 2.6 and 2.7 ???
But according to http://libxmlplusplus.sourceforge.net/, 2.6 and 2.7
have different APIs but they suppose to work just fine with
libxml2 >=2.6.1 and glibmm-2.4 >=2.4.0.
BTW, here is the place where I've got RPM from:
http://dag.wieers.com/packages/libxml++/
And this is THE ONLY place where I could get libxml++ RPMs from.
I wouldn't mind building my own RPM from a tarball, but for
installations without development environment, this is out of
question. I should be able to point my users to some RPM repository
with sane properly built libxml++ RPMs.
Sounds like the RPM is wrong and for all libxml++-2.k.x where k >= 6,
they all should be identified as libxml++-2.6.pc and should
all install in $prefix/include/libxml++-2.6 and so forth.
Conclusively, 'configure.in' should test for:
PKG_CHECK_MODULES(XMLCPP, libxml++-2.6 >= 0.26.0)
AC_SUBST(XMLCPP_CFLAGS)
AC_SUBST(XMLCPP_LIBS)
The only problem I have with this approach is that it doesn't
mirror libxml2's structure itself (but perhaps it shouldn't):
/usr/lib/libxml2.so.2
/usr/lib/libxml2.so.2.6.8
/usr/lib/libxml2.so
/usr/include/libxml2/libxml
/usr/include/libxml2/libxml/DOCBparser.h
/usr/include/libxml2/libxml/HTMLparser.h
/usr/include/libxml2/libxml/HTMLtree.h
/usr/include/libxml2/libxml/SAX.h
/usr/include/libxml2/libxml/SAX2.h
...
/usr/include/libxml2/libxml/xpointer.h
/usr/lib/pkgconfig/libxml-2.0.pc
/usr/lib/xml2Conf.sh
/usr/share/aclocal/libxml.m4
I'd like to hear your comments/suggestions,
-- Vlad
_____________________________________________________________
Vladislav Grinchenko http://home.comcast.net/~3rdshift/
e-mail: 3rdshift comcast net
Focus on quality, and productivity will follow.
_____________________________________________________________
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]