Re: [xslt] libxml2-2.6.11 -- 1. gcc warning, 2. elfgcchack Question
- From: Daniel Veillard <veillard redhat com>
- To: The Gnome XSLT library mailing-list <xslt gnome org>
- Subject: Re: [xslt] libxml2-2.6.11 -- 1. gcc warning, 2. elfgcchack Question
- Date: Wed, 7 Jul 2004 10:21:13 -0400
On Wed, Jul 07, 2004 at 03:36:59PM +0200, Peter Breitenlohner wrote:
> Hi,
Hi,
> 1. when building the brand new libxml2-2.6.11 I noticed the gcc warning:
>
> gcc -DHAVE_CONFIG_H -I. -I. -I. -I./include -I./include -D_REENTRANT \
> -O2 -Wall -MT uri.lo -MD -MP -MF .deps/uri.Tpo -c uri.c \
> -fPIC -DPIC -o .libs/uri.o
> uri.c:53:1: warning: "IS_DIGIT" redefined
> In file included from include/libxml/DOCBparser.h:18,
> from elfgcchack.h:16,
> from libxml.h:56,
> from uri.c:12:
> include/libxml/parserInternals.h:121:1: warning: this is the location \
> of the previous definition
>
> I think the IS_DIGIT macro in uri.c ought to be renamed!
#ifdef IS_DIGIT
#undef IS_DIGIT
#endif
sounds simpler and makes sense in that module :-)
> 2. As far as I can see, the elfgcchack stuff has the purpose to speed up
> calls within the library. That's fine and presumably profitable for a shared
> library. For a static library, however, I can imagine no such gain. I only
> see the disadvantage that the (--strip-debug'ed) static library increases in
> size approx. from 1MB to 4MB.
I didn't noticed that. But it's all ELF metadata, the verious code and
data sections size are unaffected as well as size of binraies linked against
the static lib, so damage is limited to the size of the file and time
spent by the linker. The file size grew from 2+MB to 4+MB, right.
> I would therefore suggest that the file "elfgcchack.h" should only be
> included into "libxml.h" when building a shared library but not for a static
> one. The only problem might be how to detect the difference (an additional
> "ifdef PIC" might suffice).
#ifdef __PIC__
...
#endif
in libxml.h seems to avoid the problem, right,
thanks for the reports, that should be fixed in CVs soonish,
Daniel
--
Daniel Veillard | Red Hat Desktop team http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]