On 11/6/06, C. R. <[EMAIL PROTECTED]> wrote:
System: Solaris v5.9
My previous messages reflect that I am having trouble installing any
module via the CPAN module in perl. So what are my options?
I want to start using XML and have some modules in mind that I need. I
have downloaded XML::Simple, XML::Parser, XML::XPath and XML::DOM. Do I
just unzip these to the perl/lib directory? Or are there other variables
(system, perl or otherwise) I have to modify?
I looked into the tar files and the directory names for each module
contain version numbers, like "XML-DOM-lib-1.44\XML\DOM" or something
like that. If that is the dir where XML::DOM is installed, how does perl
know where to find the XML::DOM module?
Thank you.
Chuck,
The answer is both "yes" and "no." You don't have to use the cpan
module or command line utility to install modules. You can download
them from CPAN and install them manually; there should be an INSTALL
and/or README file with each module that details the build process for
each module. In most cases on most platforms, modules follow a pretty
straight forward unix installation path: make, make test, make
install.
And there's the rub, of course: your issue with CPAN--or one of
them--is that you don't have make. CPAN modules aren't distributed as
compiled binaries (insofar as such a thing exists for Perl). They
require configuration for each individual machine and OS they're
installed on; that's why you can install them on such a wide range of
platforms and operating systems: author include forking, platform
specific logic in the configure routines. Make is the standard for
this kind of configuration, and Perl modules rely on it. Many also
rely on the presence of a C compiler, particularly XML parsers, which
often link to standard external libraries.
This is one reason I make a habit of installing Perl myself even when
a machine/OS comes with a precompiled binary: If Perl won't compile,
the modules I want probably won't, either.
Bottom line: install, at the very least, gnu make--and preferrably gcc
or equivalent cc/cpp--and then you can either install by hand or or
with cpan, which will probably start working.
HTH,
-- jay
--------------------------------------------------
This email and attachment(s): [ ] blogable; [ x ] ask first; [ ]
private and confidential
daggerquill [at] gmail [dot] com
http://www.tuaw.com http://www.downloadsquad.com http://www.engatiki.org
values of β will give rise to dom!