Bug 89957 - xml2-config prints -L/usr/lib64 on Hammer
Summary: xml2-config prints -L/usr/lib64 on Hammer
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Raw Hide
Classification: Retired
Component: libxml2
Version: 1.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Daniel Veillard
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 1131998
TreeView+ depends on / blocked
 
Reported: 2003-04-30 11:07 UTC by Joe Orton
Modified: 2015-02-10 14:47 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-11-30 15:43:19 UTC
Embargoed:


Attachments (Terms of Use)

Description Joe Orton 2003-04-30 11:07:39 UTC
libxml2-devel-2.5.4-1

# xml2-config --libs
-L/usr/lib64 -lxml2 -lz -lm

this should not include -L/usr/lib64 else Things Go Horribly Wrong.

Comment 1 Daniel Veillard 2003-04-30 11:16:48 UTC
Why ? If libxml2 is compiled for 64bits, then the library is stored
in /usr/lib64 ? I don't see what else should be done to make sure the
library is found. 
Pointers to appropriate documentation seems essential to resolve this
bug report one way or another,

Daniel

Comment 2 Joe Orton 2003-04-30 11:24:32 UTC
Because it reorders the library search path - /usr/lib or /usr/lib64 are already
searched by default by the compiler.

Comment 3 Daniel Veillard 2003-04-30 11:53:10 UTC
Well it seems to me that if there is an hardcoded semantic to some
paths in the tools then the tools should assume that semantic completely.
I will try anyway to remove -L/usr/lib and -L/usr/lib64 if present when
compiling on a Linux system

Daniel

Comment 4 Joe Orton 2003-04-30 12:25:04 UTC
Oh, it's not just Hammer. Just patch for RHL to change:

        echo -L${libdir} -lxml2 -lz   -lm
to
        echo -lxml2 -lz   -lm

that's correct for RHL (but not in general, of course).

Comment 5 Joe Orton 2003-04-30 12:25:04 UTC
Oh, it's not just Hammer. Just patch for RHL to change:

        echo -L${libdir} -lxml2 -lz   -lm
to
        echo -lxml2 -lz   -lm

that's correct for RHL (but not in general, of course).

Comment 6 Daniel Veillard 2003-04-30 12:40:42 UTC
I don't want RHL only fixes, your suggestion would break nearly
everybody else installation. I don't want to maintain RHL only
patches because I want community feedback on my code, so same
code for everybody, and since I compile on RHL I want to run
the same code as my userbase in general.

There is no "echo -L${libdir} -lxml2 -lz   -lm" in the source,
there is echo @XML_LIBDIR@ @XML_LIBS@ . In the specific case of
Linux and if @XML_LIBDIR@ matches "-L/usr/lib64" then I will do the
special case since apparently the toolchain don't apply the 
hardcoded semantic consistently. I have yet to get feedback that
adding -L/usr/lib would ever be a problem, so I will keep this
as is in the general case. The following patch has been commited
to the CVS base it will be included in teh next libxml2 release.
Libxml2 is *very* portable, I will try to keep it that way and 
try to minimize special case configuration as much as possible,

Daniel

*** xml2-config.in      3 May 2002 07:29:37 -0000       1.4
--- xml2-config.in      30 Apr 2003 12:20:34 -0000      1.5
***************
*** 60,66 ****
                ;;
   
      --libs)
!               echo @XML_LIBDIR@ @XML_LIBS@
                ;;
   
      *)
--- 60,76 ----
                ;;
   
      --libs)
!         if [ "`uname`" = "Linux" ]
!       then
!           if [ "@XML_LIBDIR@" = "-L/usr/lib64" ]
!           then
!               echo @XML_LIBS@
!           else
!               echo @XML_LIBDIR@ @XML_LIBS@
!           fi
!       else
!           echo @XML_LIBDIR@ @XML_LIBS@
!       fi
                ;;
   
      *)



Comment 7 Daniel Veillard 2004-11-30 15:43:19 UTC
This is fixed for ages in the various libxml2 packages we ship,

test64:~ -> xml2-config --libs
-lxml2 -lz -lpthread -lm
test64:~ ->

Daniel


Note You need to log in before you can comment on or make changes to this bug.