Click here to get back home

Installing modules locally as a non root

 HomeNewsGroups | Search | About
 comp.lang.perl.modules    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Installing modules locally as a non root sravi 05-23-2005
Posted by sravi on May 23, 2005, 5:21 am
Please log in for more thread options


I need the perl module Digest::Nilsimsa. Since I don't have root
permissions, I have to install this locally. I used the following
commands

perl Makefile.PL PREFIX=/home/sravi/perl
make
make test
make install

All the commands where executed successfully, but the following program
is giving the error
"Can't locate Digest/Nilsimsa.pm in @INC (@INC contains:
/home/sravi/perl /home/sravi/perl
/usr/local/lib/perl5/sun4-solaris/5.00404 /usr/local/lib/perl5
/usr/local/lib/perl5/site_perl/sun4-solaris
/usr/local/lib/perl5/site_perl /usr/local/lib/perl5/sun4-solaris .) at
../tmp.pl line 5.
BEGIN failed--compilation aborted at ./tmp.pl line 5."

#!/usr/local/bin/perl -w

use lib "/home/sravi/perl";

use Digest::Nilsimsa;

my $nils = Digest::Nilsimsa;

my $digest = $nils->text2digest("hi");

print $digest, "\n";


Does anyone know what is the problem with this?



Posted by Mark Clements on May 23, 2005, 12:39 pm
Please log in for more thread options


sravi wrote:

> I need the perl module Digest::Nilsimsa. Since I don't have root
> permissions, I have to install this locally. I used the following
> commands
>
> perl Makefile.PL PREFIX=/home/sravi/perl
> make
> make test
> make install
>
> All the commands where executed successfully, but the following
> program is giving the error
> "Can't locate Digest/Nilsimsa.pm in @INC (@INC contains:
> /home/sravi/perl /home/sravi/perl
> /usr/local/lib/perl5/sun4-solaris/5.00404 /usr/local/lib/perl5
> /usr/local/lib/perl5/site_perl/sun4-solaris
> /usr/local/lib/perl5/site_perl /usr/local/lib/perl5/sun4-solaris .) at
> ./tmp.pl line 5.
> BEGIN failed--compilation aborted at ./tmp.pl line 5."
>
> #!/usr/local/bin/perl -w
>
> use lib "/home/sravi/perl";
>
> use Digest::Nilsimsa;
>
<snip>
That is a seriously ancient version of Perl you have there. You may
like to ask your admin to do something about it.

Assuming you have read

http://www.cpan.org/misc/cpan-faq.html#How_use_private

or similar, you can try a few things.

does

find /home/sravi/perl -print

give you the result you expect?

What happens if you set the use lib line to eg

use lib qw(/home/sravi/perl/perl5/site_perl/5.00404);

or wherever it is the module has actually been installed? You may have
to toy with this.

Mark




Posted by sravi on May 23, 2005, 6:07 am
Please log in for more thread options


Here is the output of "find /home/sravi/perl -print"
/home/sravi/perl
/home/sravi/perl/lib
/home/sravi/perl/lib/site_perl
/home/sravi/perl/lib/site_perl/sun4-solaris
/home/sravi/perl/lib/site_perl/sun4-solaris/auto
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa/Nilsimsa.so
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa/Nilsimsa.bs
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa/.packlist
/home/sravi/perl/lib/site_perl/Digest
/home/sravi/perl/lib/site_perl/Digest/Nilsimsa.pm
/home/sravi/perl/lib/sun4-solaris
/home/sravi/perl/lib/sun4-solaris/5.00404
/home/sravi/perl/lib/sun4-solaris/5.00404/perllocal.pod
/home/sravi/perl/man
/home/sravi/perl/man/man3
/home/sravi/perl/man/man3/Digest::Nilsimsa.3



Posted by Mark Clements on May 23, 2005, 1:13 pm
Please log in for more thread options


sravi wrote:

> Here is the output of "find /home/sravi/perl -print"
You need to give some context to your posts. Please read the posting
guidelines.

<snip>

> /home/sravi/perl/lib/site_perl/Digest/Nilsimsa.pm

try setting

use lib qw(/home/sravi/perl/lib);

and failing that

use lib qw(/home/sravi/perl/lib/site_perl);

Mark


Posted by sravi on May 23, 2005, 6:18 am
Please log in for more thread options



Mark Clements wrote:
> sravi wrote:
>
> > Here is the output of "find /home/sravi/perl -print"
> You need to give some context to your posts. Please read the posting
> guidelines.
>
> <snip>
>
> > /home/sravi/perl/lib/site_perl/Digest/Nilsimsa.pm
>
> try setting
>
> use lib qw(/home/sravi/perl/lib);

This gave the following error

Can't locate Digest/Nilsimsa.pm in @INC (@INC contains:
/home/sravi/perl/lib /usr/local/perl-5.8.3/lib/5.8.3/sun4-solaris
/usr/local/perl-5.8.3/lib/5.8.3
/usr/local/perl-5.8.3/lib/site_perl/5.8.3/sun4-solaris
/usr/local/perl-5.8.3/lib/site_perl/5.8.3
/usr/local/perl-5.8.3/lib/site_perl .) at /home/sravi/tmp.pl line 9.


>
> and failing that
>
> use lib qw(/home/sravi/perl/lib/site_perl);
>

This gave the following error,

Can't load
'/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa/Nilsimsa.so'
for module Digest::Nilsimsa: ld.so.1: /usr/local/bin/perl5.8.3: fatal:
relocation error: file
/home/sravi/perl/lib/site_perl/sun4-solaris/auto/Digest/Nilsimsa/Nilsimsa.so:
symbol Perl_markstack_ptr: referenced symbol not found at
/usr/local/perl-5.8.3/lib/5.8.3/sun4-solaris/DynaLoader.pm line 229.
at /home/sravi/tmp.pl line 9
Compilation failed in require at /home/sravi/tmp.pl line 9.
BEGIN failed--compilation aborted at /home/sravi/tmp.pl line 9.


Should I move some files to other directory to work?



Similar ThreadsPosted
write permissions installing XML-SAX-Expat-0.38 locally June 9, 2007, 10:44 am
Installing Net::SMTP as non-root March 19, 2007, 4:03 pm
compiling/add modules when no root access March 22, 2006, 4:21 pm
Local install of modules - no root; no telnet November 9, 2004, 12:54 am
[RFC] What's a good CPAN root name for mobile and wireless modules? January 2, 2005, 4:49 pm
installing modules? September 29, 2005, 1:52 pm
Installing modules August 5, 2005, 8:32 pm
Problem with installing modules November 24, 2006, 6:15 pm
Newbie: Installing Modules February 22, 2007, 5:42 am
Errors when Installing Modules June 23, 2008, 6:09 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap