CPAN.pm can't find libs

K

kj

I'm trying to get CPAN.pm to install XML::LibXML for me. It aborts
the installation with a message saying that it can't find libxml2,
even though libxml2.so.2 is in /usr/lib. I tried running CPAN with

$ LIB=/usr/lib perl -MCPAN -e shell

but I got the same error. How can I get CPAN to find libxml2?

Thanks!

kj
 
J

James Willmore

I'm trying to get CPAN.pm to install XML::LibXML for me. It aborts
the installation with a message saying that it can't find libxml2,
even though libxml2.so.2 is in /usr/lib. I tried running CPAN with

$ LIB=/usr/lib perl -MCPAN -e shell

but I got the same error. How can I get CPAN to find libxml2?

Do you have xml2-config available? The reason, if I remember correctly,
that the install is failing is not because you don't have the library -
it's because the command *used* to find the library is in some funky path.

See if you can execute `xml2-config`. If you can and it reports properly,
then the issue is something else. But I have a feeling that's the
problem.

HTH

Jim
 
S

Sherm Pendley

kj said:
I'm trying to get CPAN.pm to install XML::LibXML for me. It aborts
the installation with a message saying that it can't find libxml2,
even though libxml2.so.2 is in /usr/lib.

A package manager - rpm, dpkg, Fink, something like that - will quite often
split libraries such as libxml2 into two packages; one with nothing but
the .so files which are used at run-time, and the other with the headers
and other tools needed at compile-time.

If you're using such a package manager (by whatever name), check to see if
there's an additional developer package for libxml2 and if so, if you have
installed it.

sherm--
 
J

James Willmore

A package manager - rpm, dpkg, Fink, something like that - will quite
often split libraries such as libxml2 into two packages; one with
nothing but the .so files which are used at run-time, and the other with
the headers and other tools needed at compile-time.

If you're using such a package manager (by whatever name), check to see
if there's an additional developer package for libxml2 and if so, if you
have installed it.

Which, on a SuSE 9.0 distro, is libxml2-devel-2.5.10-32. Which contains
/usr/bin/xml2-config. Which is what the OP needs to install XML::LibXML
:)

--
Jim

Copyright notice: all code written by the author in this post is
released under the GPL. http://www.gnu.org/licenses/gpl.txt
for more information.

a fortune quote ...
Ask not for whom the telephone bell tolls ... if thou art in the
bathtub, it tolls for thee.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top