Subject: LD_LIBRARY and p5-XML-LibXML problems on Solaris 9
To: None <>
From: Ulrich Habel <>
List: tech-pkg
Date: 11/30/2007 22:54:59
Solaris 9 brings a libxml2 library by default. When I try to build
p5-XML-LibXML, pkgsrc checks for it's own libxml2 and builds it. After
that, p5-XML-LibXML will be build and results in a working package.

However when you call the module it checks against the Solaris libxml2
library and fails.

bash-2.05# /usr/pkg/bin/perl -MXML::LibXML -e 'print

Can't load
for module XML::LibXML: perl: fatal: relocation error: file
symbol xmlIsBaseCharGroup: referenced symbol not found at
/usr/pkg/lib/perl5/5.8.0/sparc-solaris-thread-multi/ line
230.  at
line 116 BEGIN failed--compilation aborted at
line 116.  Compilation failed in require.  BEGIN failed--compilation

if you, however, force LD_LIBRARY_PATH to /usr/pkg/lib it works as

bash-2.05# LD_LIBRARY_PATH=/usr/pkg/lib /usr/pkg/bin/perl -MXML::LibXML
-e 'print "$XML::LibXML::VERSION\n"

This results in other broken packages (like p5-XML-Atom) - is there any
chance to fix that? A solution might be to set /usr/pkg/lib with crle
before the other search paths. However, I don't like the solution.

Am I missing something, any ideas?