Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using CPAN for the first time 1

Status
Not open for further replies.

ShadwSrch

IS-IT--Management
Joined
Mar 9, 2005
Messages
72
Location
US
I am getting started with Linux, and I am starting with a very specific project...

I only have loaded the terminal environment, and I am trying to load some perl modules needed for <a href=" ASSP</a>.

I need Compress::Zlib for my project, and as I understand it, I also need it for the CPAN shell.

I have found that I need the following 2 modules before I can install (maybe wrong word) Compress::Zlib:
Compress::Raw::Zlib
IO::Compress::Gzip

I downloaded those two and Compress::Zlib and burned them onto a CD using my Windows box which I am very familliar with.

I have used tar very little. how can I uncompress these modules onto my Debian Etch box from my CD?

After I have uncompressed them, I think I can Install (Make...whatever word goes here) those modules.

It is my understanding that I can then use the CPAN shell to get the other modules I need.

And one other thing...After decompressing and Making/Installing the modules, can I then delete the decompressed folders?

Any help would be greatly appreciated.
 
Assuming you have an internet connection on your Linux box, you should be able to use the CPAN shell already. That would remove the need to download each module individually. In many cases, CPAN will be able to grab all the dependencies automatically, which will save you a load of time too.

On some systems, from the command line you should be able to simply type (as root: it's a little more complex when you're trying to install just as a user):
Code:
cpan Compress::Zlib

If that doesn't work, try:
Code:
perl -MCPAN -e 'install Compress::Zlib'
 
I can't do the cpan Compress::Zlib
I get:
-bash: cpan: command not found

When I do the second I get:
Can't locate CPAN.pm in @INC(@INC contains: /etc/perl /usr/local/lib/perl/5.8.8 /usr/local/share/perl/5.8.8 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.8 /usr/shar/perl/5.8 /usr/local/lib/site_perl .).
Begin failed--compilation aborted.
 
What Linux distribution are you using?
 
I got Debian Etch...I did not install any of the preconfigured packages...

I just want a bare OS to run 2 or 3 specific packages...
 
What about the original question?

I can downlowa and install Bundle::CPAN the same way if I could get that answer.
 
CPAN should be amongst the core Perl modules. Try (as root):
Code:
apt-get install perl-modules
 
thanks!

That allowed me to cpan Compress::Zlib

It still did not work though...every time, it said that it had a complete kit, and the Make gave a --NOT OK

As it was going, it did ask me to prepend all of the dependencies, but none of the packages wold make that I could tell...it was scrolling pretty fast...

I was told that the modules I mentioned earler were required to use the cpan shell...you seem to be telling me that this is not true...Did I have wrong information?
 
AFAIK you shouldn't need to install any more modules in order to use the CPAN shell. There should have been an error message above where make gave you the NOT OK that should shed more light on what happened.

One of the dangers of installing a totally minimal Debian system without any of the prepackaged options is that you can find yourself without utilities that are usually considered standard but you may not have seen as vital when you installed. So whereas Compress::Zlib just installed fine on my Etch machine, if you're missing some of the compression utilities that might cause the installation to fail. I can't be certain that's what's happening without seeing your error message.
 
I am looking into all kinds of prereq problems because of my chosen path...I know I have created a bear for myself...

What about the deleted install folders question?

If I decompress these modules into a folder and do the Makefile.pl thing...can I delete the original decompressed folders after the install?
 
I went back and re-installed, and chose the last option..."standard system"

now when I ran cpan Compress::Zlib, it worked...

I think that without the standard install, there was no c compiler..that is why cpan was not working...

(Anyone reading this diagnosis...take it with a grain of salt...I do not have many hours logged on a Linux box yet...)
 
That would make sense. I've been bitten by something similar before. May not have been the C compiler but it certainly was something like that.
 
Sorry, to answer the other question above:

When installing via a downloaded .tar.gz, once you've completed the "make install" step (as root), the module is installed. It is now safe to delete the directory that was created when you untarred it.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top