Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Need to install Perl Modules

by mrmurdock (Initiate)
on May 17, 2017 at 18:27 UTC ( #1190488=perlquestion: print w/replies, xml ) Need Help??
mrmurdock has asked for the wisdom of the Perl Monks concerning the following question:

Be nice, all I know about Perl is how to spell it (perl). I have a Solaris 10 server with latest Kernel patch set on it. The perl installed is 5.8.4 that came with the OS (This is perl, v5.8.4 built for sun4-solaris-64int) The end developer is needing LWP Simple.pm module installed. I have tried to run perlgcc as directed by articles, but its failing on the download (??) the make (??), tests (??). Not sure what the issue is. Is there a simpler way to install modules then through the cli perlgcc? What Packages do I need to install to get Simple.pm from? Is there perl bundles that can be installed that contains simple.pm and really the basic standard Modules (if there is such a thing as standard modules) most frequently used?

Replies are listed 'Best First'.
Re: Need to install Perl Modules
by marto (Bishop) on May 18, 2017 at 08:41 UTC

    "Be nice, all I know about Perl is how to spell it"

    Don't worry, you're in the right place. I'm not a Solaris sysadmin, but our client insist on using it. Yes, 'modern' Solaris ships with a really old version of Perl (as you say 5.8.4, from 2004). As a perl developer who works primarily on Solaris on a daily basis I'd advise the following. Install gcc, install a modern perl elsewhere on your system (see INSTALL - installation prefix), e.g. /app/applicationname. Then the developer can just work away as normal, or as normal as you can on Solaris.

    I'd suggest installing App::cpanminus to get cpanm, which is a faster tool for installing modules than cpan. If your developer is going to be installing/updating cpan modules fairly regularly this will make things easier. If this server does not have internet access, you can create a portable mini cpan mirror on a machine which does have internet access, using the minicpan tool.

Re: Need to install Perl Modules
by stevieb (Monsignor) on May 17, 2017 at 19:03 UTC

    CPAN Testers says that LWP::Simple tests and installs fine all the way down to 5.8.1 at least on some Unix platforms. There aren't any tests on Solaris at that low a version, but hopefully it'll be ok.

    I would use the cpanm command, or if it isn't installed, cpan. This will fetch, test and install the module from the Comprehensive Perl Archive Network (aka "the CPAN"). That's the global central repository for all publicly available Perl modules and distributions, and is open to all to download from, and add to (the latter requires an account).

    Simply run cpanm LWP::Simple. If you don't have cpanm, run cpan LWP::Simple.

    You may need to elevate to root privileges, so either use sudo before the above commands, or log into a superuser shell if that's the case.

Re: Need to install Perl Modules -- dont mess with system Perl
by Discipulus (Prior) on May 18, 2017 at 06:59 UTC
    Hi mrmurdock and welcome to the monastery and to the wonderful world of Perl!

    I hope, after you got this answered, you remain here to learn some bit more.

    As side note to what stevieb already said, I suggest you to NOT use the system Perl you have already installed on the machine.

    First the system Perl you have is 5.8.4 ie a grand-grand-mother release of July 2004.

    Second, and more important: tomorrow your developper needs Some::Module so you go to install it. It happens that Some::Module has as requisite Another::Module with minimal version x.y but your system has Another::Module version u.v so you upgrade it and it might happens that your system Perl becomes buggy. Not always the story is that bad, but it can happen. So play safe.

    It is very easy to have multiple perl installation on the same machine: just install into another directory and dont mess with the PERL5LIB env var. You can do a link to the new perl and tell the dev to use it.

    Laziest ones can also use perlbrew to manage several installations of Perl. But in your case is a bit overkilling.

    Doing this you can offer a modern Perl release to your dev, currently 5.24 with all modules at the last release.

    For your reference take a look to following posts:

  • Multiple instances of Perl
  • Can Multiple perl versions coexist without effecting one another on Solaris?
  • Re: targetting for multiple perl versions (ignore the direct resposnse to the last post i linked, although)



    HTH

    L*

    There are no rules, there are no thumbs..
    Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1190488]
Approved by Corion
Front-paged by Corion
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (11)
As of 2017-05-25 17:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?