Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > New Perl installation can't find module

Reply
Thread Tools

New Perl installation can't find module

 
 
JONL
Guest
Posts: n/a
 
      04-11-2005
Hi,
Please excuse me if this is an ignorant question. I have been slowly
backing my self up into the care and feeding of our perl subsystem.
I having been trying to get our new Perl (5.8.0) load to recognize the
ReadKey.pm module. What I did was to go to a directory in the @INC
array and add the file Term/ReadKey.pm. But still when I run the
program which has the statement use Term/ReadKey it comes back with
Can't locate loadable object for module Term::ReadKey in @INC
it then list the directories in INC, one of which is the directory
holding Term/ReadKey.pm

I have been pouring over man pages for PerlMod and PerlModLib and
thought I had it right but apparently I am missing something. Can
someone give me a clu? Thanks in advance
JonL

 
Reply With Quote
 
 
 
 
phaylon
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:

> Can someone give me a clu?


Hm. Would you mind giving us a bit more information? Like code, *exact*
(copy&paste) path's of the files and version information of perl would
help I guess.

You know, not all of us are wizzards

--
http://www.dunkelheit.at/

Ordinary morality is only for ordinary people.
-- Aleister Crowley

 
Reply With Quote
 
 
 
 
J. Gleixner
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:
> Hi,
> Please excuse me if this is an ignorant question. I have been slowly
> backing my self up into the care and feeding of our perl subsystem.
> I having been trying to get our new Perl (5.8.0) load to recognize the
> ReadKey.pm module. What I did was to go to a directory in the @INC
> array and add the file Term/ReadKey.pm. But still when I run the
> program which has the statement use Term/ReadKey it comes back with
> Can't locate loadable object for module Term::ReadKey in @INC
> it then list the directories in INC, one of which is the directory
> holding Term/ReadKey.pm
>
> I have been pouring over man pages for PerlMod and PerlModLib and
> thought I had it right but apparently I am missing something. Can
> someone give me a clu? Thanks in advance
> JonL
>


Copying ReadKey.pm isn't enough. Install it the "correct" way:

perl Makefile.PL
make
make test
make install
 
Reply With Quote
 
Chris Mattern
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:

> Hi,
> Please excuse me if this is an ignorant question. I have been slowly
> backing my self up into the care and feeding of our perl subsystem.
> I having been trying to get our new Perl (5.8.0) load to recognize the
> ReadKey.pm module. What I did was to go to a directory in the @INC
> array and add the file Term/ReadKey.pm. But still when I run the
> program which has the statement use Term/ReadKey it comes back with
> Can't locate loadable object for module Term::ReadKey in @INC
> it then list the directories in INC, one of which is the directory
> holding Term/ReadKey.pm


ReadKey has C code that must be compiled. Use CPAN to install it.
>
> I have been pouring over man pages for PerlMod and PerlModLib and
> thought I had it right but apparently I am missing something. Can
> someone give me a clu? Thanks in advance
> JonL


--
Christopher Mattern

"Which one you figure tracked us?"
"The ugly one, sir."
"...Could you be more specific?"
 
Reply With Quote
 
Jeff Stampes
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:
> What I did was to go to a directory in the @INC
> array and add the file Term/ReadKey.pm. But still when I run the
> program which has the statement use Term/ReadKey it comes back with
> Can't locate loadable object for module Term::ReadKey in @INC
> it then list the directories in INC, one of which is the directory
> holding Term/ReadKey.pm


(my terminology may be incorrect here, but I'm sure someone will correct me)

ReadKey is an XS module. The .pm file is simply a wrapper around a
compiled C module, ReadKey.so:

stampes@flux[41] lib > find . -name ReadKey.*
../site_perl/i686-linux-thread-multi/auto/Term/ReadKey/ReadKey.so
../site_perl/i686-linux-thread-multi/auto/Term/ReadKey/ReadKey.bs
../site_perl/i686-linux-thread-multi/Term/ReadKey.pm

Additionally, you need to be concerned about whether ReadKey is
autosplit or not.

Copying files around is a dangerous way to install modules. Use cpan,
or download the sources and recompile modules yourself for safety

~Jeff
 
Reply With Quote
 
JONL
Guest
Posts: n/a
 
      04-11-2005
Ok,
So I see I should have compiled it. I had run this route before but I
come up with so many obstacles. Remember I am new to this. I have been
pouring through the local man pages and through the internet. So this
takes me to my next ignorant question. I go to perl.org --> get perl
--> modules and extensions. I then search CPAN for ReadKey.pm and
follow the hyperlink for "source" code
-- http://search.cpan.org/~kjalb/TermRe....14/ReadKey.pm --
Frankly I was expecting a tar.gz file But I get a file which looks
like a lot of comments eventually coming up to some readable perl .
This, in fact, looks just like the ReadKey.pm that I had moved to the
area. So if there is a module that can be compiled I am not sure where
to go for it .

 
Reply With Quote
 
J. Gleixner
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:
> Ok,
> So I see I should have compiled it. I had run this route before but I
> come up with so many obstacles. Remember I am new to this. I have been
> pouring through the local man pages and through the internet. So this
> takes me to my next ignorant question. I go to perl.org --> get perl
> --> modules and extensions. I then search CPAN for ReadKey.pm and
> follow the hyperlink for "source" code
> -- http://search.cpan.org/~kjalb/TermRe....14/ReadKey.pm --
> Frankly I was expecting a tar.gz file But I get a file which looks
> like a lot of comments eventually coming up to some readable perl .
> This, in fact, looks just like the ReadKey.pm that I had moved to the
> area. So if there is a module that can be compiled I am not sure where
> to go for it .
>


On this page:
http://search.cpan.org/~jstowe/TermR....30/ReadKey.pm

select the 'TermReadKey-2.30' link at the top. From the page that
follows it, you'll see a 'download' link near the top of the page.

You may want to look at the CPAN module, which will go out and fetch,
compile, install modules for you:

http://search.cpan.org/~andk/CPAN-1.76/lib/CPAN.pm
 
Reply With Quote
 
Chris Mattern
Guest
Posts: n/a
 
      04-11-2005
JONL wrote:

> Ok,
> So I see I should have compiled it. I had run this route before but I
> come up with so many obstacles. Remember I am new to this. I have been
> pouring through the local man pages and through the internet. So this
> takes me to my next ignorant question. I go to perl.org --> get perl
> --> modules and extensions. I then search CPAN for ReadKey.pm and
> follow the hyperlink for "source" code
> -- http://search.cpan.org/~kjalb/TermRe....14/ReadKey.pm --
> Frankly I was expecting a tar.gz file But I get a file which looks
> like a lot of comments eventually coming up to some readable perl .
> This, in fact, looks just like the ReadKey.pm that I had moved to the
> area. So if there is a module that can be compiled I am not sure where
> to go for it .


Use CPAN. CPAN will download everything you need, build it, and put it
where it belongs.

--
Christopher Mattern

"Which one you figure tracked us?"
"The ugly one, sir."
"...Could you be more specific?"
 
Reply With Quote
 
Tad McClellan
Guest
Posts: n/a
 
      04-11-2005
JONL <(E-Mail Removed)> wrote:

> program which has the statement use Term/ReadKey

^^^

Do you mean a program which has the statement use Term::ReadKey?


--
Tad McClellan SGML consulting
http://www.velocityreviews.com/forums/(E-Mail Removed) Perl programming
Fort Worth, Texas
 
Reply With Quote
 
JONL
Guest
Posts: n/a
 
      04-11-2005
J. G

When I go to the URL you provided-- which is the same one I went to in
the description above I do click on the TermReadKey-2.30 I get a page
with Module Version 2.30 SOURCE.
Followed by Name, Synopsis Discription , Author, I scroll that whole
thing and dont find a download.
Now if I click on Source I get a download dialog which will download
ReadKey.pm which I alreay have. Either I am downloading the wrong thing
r I need to know how to create the so files from that .pm file. Still
I am missing something .

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
query regarding perl module installation in local directory contactviswa@gmail.com Perl Misc 1 07-28-2007 08:22 PM
DB Module installation issue in Perl Pioneer Perl Misc 0 04-21-2007 11:28 PM
perl cgi session module installation problem. bhuvana.aradhya@gmail.com Perl Misc 0 06-05-2006 01:31 PM
Installation Problem with XML::Parser perl module HarishN Perl Misc 4 02-23-2004 01:37 AM
Installation of a perl module mistletoe Perl Misc 5 11-13-2003 01:11 PM



Advertisments