From duncan at research.bell-labs.com  Thu Oct  9 13:02:32 2003
From: duncan at research.bell-labs.com (Duncan Temple Lang)
Date: Thu Oct  9 18:01:52 2003
Subject: [Rd] building XML-0.95-1 on MacOS
In-Reply-To: <20031009104822.D21760@jessie.research.bell-labs.com>;
	from duncan@research.bell-labs.com on Thu, Oct 09, 2003 at
	10:48:22AM -0400
References: <15443B9C-FA64-11D7-B761-000A95D7BA10@mail.nih.gov>
	<20031009104822.D21760@jessie.research.bell-labs.com>
Message-ID: <20031009120231.M21760@jessie.research.bell-labs.com>


Stefano asked me to post something along the following lines
about the XML package.

I have modified the configuration for the XML package so that it
looks for libxml2 if instructed, or alternatively looks for libxml 1
and, if that is not present, then libxml 2.

The new version:  XML_0.95-4.tar.gz is on the Omegahat
Web site:
   http://www.omegahat.org/RSXML

So one should not have to set any environment variables or specify
configuration arguments if you only have libxml2 on your machine. If
you have both libxml and libxml2, you will get libxml 1 by default.
Use --configure-args='--with-libxml2' or set the environment variable
XML_CONFIG to xml2-config.

At some point in the future, we will stop supporting
old versions of libxml with no xml-config script,
header files in odd places, ...  This is what
makes the configuration so complex.


 D.



Duncan Temple Lang wrote:
> 
> Hi Sean.
> 
>   Two things. There is a new version of the XML package
> now on the Omegahat web site:
> 
>   http://www.omegahat.org/RSXML/XML_0.95-3.tar.gz
> 
> That uses a different approach to dealing with errors and avoids
> having to redefine the xmlParserError() routine.  As a result,
> one should not need the -m flag.
> 
> Secondly, unless there are good reasons for using
> libxml-1.8.*, it is preferrable to use the libxml2-2*
> series. 
> 
> The configuration for this version of the XML package has been
> "upgraded", but may require some assistance.  If it doesn't compile
> out of the box, please set the environment variable XML_CONFIG to the
> name of the xml-config or xml2-config script that provides the
> relevant information. I'll fix this up in the next release.
> 
>  D.
> 
> 
> Sean Davis wrote:
> > I am trying to build the XML package on MacOS.  I am using the fink 
> > installation of libxml-1.8.17.  The configuration information is:
> > 
> > Configuration information:
> > 
> > Libxml settings
> > 
> > libxml include directory: /sw/include/gnome-xml
> > libxml library directory: -L/sw/lib -lxml -lz -lz  -lxml
> > libxml 2:                 no
> > 
> > Compilation flags:         -I/sw/include/gnome-xml 
> > -I/sw/include/gnome-xml/libxml -DLIBXML -I/sw/include/gnome-xml
> > Link flags:               -L/sw/lib -lxml -lz -lz  -lxml
> > 
> > 
> > 
> > Compiling produced the following error:
> > gcc -bundle -flat_namespace -undefined suppress -L/sw/lib 
> > -L/usr/local/lib -o XML.so DocParse.o EventParse.o ExpatParse.o 
> > HTMLParse.o RSDTD.o RUtils.o Utils.o XMLEventParse.o XMLTree.o 
> > -L/sw/lib -lxml -lz -lz  -lxml -lcc_dynamic
> > ld: multiple definitions of symbol _xmlParserError
> > Utils.o definition of _xmlParserError in section (__TEXT,__text)
> > /sw/lib/libxml.dylib(error.lo) definition of _xmlParserError
> > make: *** [XML.so] Error 1
> > ERROR: compilation failed for package 'XML'
> > 
> > I saw that back in September there was a discussion about fixing this 
> > problem that involved passing -m to the linker.  My questions are (1) 
> > what do I need to modify (given that I am using R INSTALL to keep 
> > things simple for myself) to use the -Xlinker -m option when linking 
> > XML.so and (2) does this actually work despite the fact that there are 
> > then two definitions associated with the same symbol?  I guess a third 
> > question follows from the second--are there other fixes that I can use 
> > to build the package?
> > 
> > Thanks in advance,
> > Sean
> > 
> > ______________________________________________
> > R-devel@stat.math.ethz.ch mailing list
> > https://www.stat.math.ethz.ch/mailman/listinfo/r-devel
> 
> -- 
> _______________________________________________________________
> 
> Duncan Temple Lang                duncan@research.bell-labs.com
> Bell Labs, Lucent Technologies    office: (908)582-3217
> 700 Mountain Avenue, Room 2C-259  fax:    (908)582-3340
> Murray Hill, NJ  07974-2070       
>          http://cm.bell-labs.com/stat/duncan
> 
> ______________________________________________
> R-devel@stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-devel

-- 
_______________________________________________________________

Duncan Temple Lang                duncan@research.bell-labs.com
Bell Labs, Lucent Technologies    office: (908)582-3217
700 Mountain Avenue, Room 2C-259  fax:    (908)582-3340
Murray Hill, NJ  07974-2070       
         http://cm.bell-labs.com/stat/duncan


[Rd] building XML-0.95-1 on MacOS
Duncan Temple Lang