Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

how to add a library

Posted on 1999-01-18
4
Medium Priority
?
280 Views
Last Modified: 2010-03-05
I am trying to teach myself perl the 'look at other peoples code' method.  It is going well enough.  Now, I have collected a script that starts as follows:

#!/usr/bin/perl
## Program Name: fetch.cgi
use CGI;
use CGI::Carp (fatalsToBrowser);
use LWP::Simple;

My problem is the last line shown above.  I do not have the Simple routines.  How do I get them and install them.

Actually, I do not really understand how to add libraries at all, or where to find them.  By server is running linux on a 386 arcgitecture macgine if this matters.
0
Comment
Question by:jhurst
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 1210204
0
 

Expert Comment

by:tdv
ID: 1210205
The easiest way to install a module is using the CPAN module that is installed with recent perls.
Try (on the command line):
perl -MCPAN -e "install LWP::Simple"
CPAN stands for Comprehensive Perl Archive Network, a mirrored set of sites that store perl and its modules. The CPAN module automatically locates a CPAN site, downloads the module and installs it.
0
 
LVL 8

Author Comment

by:jhurst
ID: 1210206
tdv,

your method does not work.  

Actually, I discovered that I could just tar the file that ozo recommended in the appropriate place, end of story.

ozo, If you will post an answer, saying anything, I will give you the points.

0
 
LVL 84

Accepted Solution

by:
ozo earned 400 total points
ID: 1210207
You can search for modules at
http://cpan.perl.com/
or
http://theory.uwinnipeg.ca/mod_perl/cpan-search.pl
I'd also second tdv's suggestion on using the CPAN module http://www.perl.com/CPAN/authors/id/ANDK/CPAN-1.44.tar.gz
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question