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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

package installation with no shell access 1

Status
Not open for further replies.

effennel

Technical User
Oct 15, 2002
60
CA
Hi,

How can I install modules and package when I have no shell access?

For example GD.pm is pretty self explanatory, I would just copy is somewhere use "use lib'path';" - but what about GD::Text::Align?

Thanks
FNL
 
It should be able to find it from the use lib "GD", I'd have thought ... no
--Paul

cigless ...
 
If you have GD.pm in (for example) /home/username/lib/GD.pm (and your 'use lib' is /home/username/lib), then GD::Text::Align should be:
/home/username/lib/GD/Text/Align.pm
 
FNL,
I'm thinking no ....so star the man, ishnid
--Paul

cigless ...
 
More on Packages...

I have a package installed by the systadmin and available via @INC. Now I want to use my own version of that package available in /home/username/lib/.

How do I specify the priority on which package is to be use?

FNL
 
Either putting a "use lib '/home/username/lib';" line in your script or setting the PERL5LIB environment variable (probably in your .bashrc) will add that directory to the start of @INC (i.e. it'll be the first place the interpreter will look for modules.
 
Ishnid,

I already use the "use lib '/home/username/lib';" line in my script but it still goes to the @INC first and then I haven't got what I want.

I do not have access to the configuration of the server I use. In this one case, I could ask the admin to make the change for me, but what else is possible when the admin refuses to make the change to the .bashrc?

FNL
 
Make sure that you put your 'use Module::Name' after 'use lib' and that the path in your 'use lib' line is definitely the correct path - perl will not check to see if that directory exists, only if /home/usename/lib/Module/Name.pm exists - obviously if the directory path is incorrect, it won't find that and continue down through @INC until it finds what it's looking for. It'll only throw an error if it can't find it anywhere.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top