Help: How to install a *.pm module

A

Amy Lee

Hello,

I download a module for BLAST parsing called "BPlite.pm", however I don't
know how to install it. I just understand how to install modules packages
bu cpan.

Thanks in advance.

Amy
 
T

Tad J McClellan

Amy Lee said:
I download a module for BLAST parsing called "BPlite.pm", however I don't
know how to install it.


Here is a radical idea: read the file in the distribution named "INSTALL"!

Or maybe just try the standard way of installing modules:

perldoc -q module

How do I install a module from CPAN?

Thanks in advance.


Yeah, right.
 
C

cartercc

Hello,

I download a module for BLAST parsing called "BPlite.pm", however I don't
know how to install it. I just understand how to install modules packages
bu cpan.

If your BPlite.pm file is source, which it probably is, just place the
file in the appropriate directory, and use the appropriate 'use'
directive. As far as I know, a source file saved as a package is just
like any user defined file saved as a package. You might have other
problems is your pm file depends on other files, but for now, I'll
consider those kinds of problems outside the scope of your question.

CC
 
T

Tim Greer

Amy said:
Hello,

I download a module for BLAST parsing called "BPlite.pm", however I
don't know how to install it. I just understand how to install modules
packages bu cpan.

Thanks in advance.

Amy

The module should have a README and/or INSTALL file. If it doesn't come
with install instructions, I don't know that I'd suggest using it.
 
H

Henry Law

Tad said:
Here is a radical idea: read the file in the distribution named "INSTALL"!

And if the distribution doesn't have a file called that? (It doesn't).
And if the "distribution" isn't a distribution but just a bare Perl
module file? (It is).

Amy, I have downloaded the module and had a look at it for you. As far
as I can see I agree with the suggestion from cartercc: just get the
module into one of the @INC libraries and then "use" it. Mail me
directly if you need help with that.

The module has pod documentation which I presume you found (at a shell
issue perldoc /wherever/it/is/now/BPLite.pm ) but it only tells you how
to use it.
 
T

Tim Greer

C

cyrusgreats

Hello,

I download a module for BLAST parsing called "BPlite.pm", however I don't
know how to install it. I just understand how to install modules packages
bu cpan.

Thanks in advance.

Amy

from shell you can type:
perl -MCPAN -e shell
then type install module
for eaxmple: install
cpan> install Net::packet


Cheers
 
T

Tad J McClellan

Tim Greer said:
Isn't this a core module in BioPerl?


That is what I downloaded before replying, so that I could
ensure that it did have an "INSTALL" file.
 
A

Amy Lee

That is what I downloaded before replying, so that I could
ensure that it did have an "INSTALL" file.
Hi, thanks every one. I copy this module into
/usr/lib/perl5/site_perl/5.8.3 this directory then use this module
correctly.

Anyway, how can I know @INC contents?

Amy
 
P

Petr Vileta \(fidokomik\)

Tad said:
Or maybe just try the standard way of installing modules:

perldoc -q module

How do I install a module from CPAN?

Maybe will be good to add to FAQ some like:
"How do I install module to hosting server where it is not allowed?"
:)
 
T

Tad J McClellan

Petr Vileta (fidokomik) said:
Maybe will be good to add to FAQ some like:
"How do I install module to hosting server where it is not allowed?"


There is one:

How do I keep my own module/library directory?
 
E

Eric Pozharski

On 2008-10-18 said:
Hi, thanks every one. I copy this module into
/usr/lib/perl5/site_perl/5.8.3 this directory then use this module
correctly.

At first I wanted to bark "don't! there're better places!". But then,
just wondering, what's your distribution? Never mind, please upgrade.
Anyway, how can I know @INC contents?

C<perl -V> -- then look at last lines
 
H

Hans Mulder

Amy said:
Anyway, how can I know @INC contents?

One technique is to type on the command line:

perl -Mxxxxx -e0

Perl will tell you that it cannot find a module named xxxxx in @INC;
it will also tell you the contents of @INC.

Hope this helps,

-- HansM
 
J

Joost Diepenmaat

Hans Mulder said:
One technique is to type on the command line:

perl -Mxxxxx -e0

Perl will tell you that it cannot find a module named xxxxx in @INC;
it will also tell you the contents of @INC.

I really prefer

perl -le 'print for @INC'
 

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

No members online now.

Forum statistics

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

Latest Threads

Top