rjahrman has asked for the wisdom of the Perl Monks concerning the following question:

OK monks, I've got a bit of a challenge for you. I'm stumped. My host doesn't have XML::Xpath, and I can't install new modules because I don't have permissions in the neccessary folder. So I took the files and dropped them into the same directory that the script is running in (so there's my script, and then a directory called "XML" in there). This worked fine.

However, I've recently copied the files to another account on the same host, but most likely a different server in the host's datacenter. Now it's all of the sudden having problems with the package. I get this error:

Can't locate object method "abs" via package "XML::XPath::Literal" at /usr/lib/perl5/site_perl/5.005/HTTP/Request.pm line 106.

I'm not sure what "abs" is or why it would be in the XML::Xpath package, or what that has to do with the HTTP::Request module. To see what would happen I installed the XML::Xpath module from the shell but in a designated directory (now /home/myusername/modules/) with "PREFIX=/dir" when I'm running "perl Makefile.PL", but that had no effect.

Any ideas?

Replies are listed 'Best First'.
Re: Package Installation Issues
by PodMaster (Abbot) on Dec 05, 2005 at 01:37 UTC
    To see what would happen I installed the XML::Xpath module from the shell but in a designated directory (now /home/myusername/modules/) with "PREFIX=/dir" when I'm running "perl Makefile.PL", but that had no effect.
    Did you add /home/myusername/modules to @INC? Do you have read/execute permissions for that directory? See A Guide to Installing Modules (and Simple Module Tutorial)

    MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
    I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
    ** The third rule of perl club is a statement of fact: pod is sexy.

Re: Package Installation Issues
by tinita (Parson) on Dec 05, 2005 at 12:05 UTC
    you might want to try cgipan. this requires that you have the permission to execute make and a compiler.
Re: Package Installation Issues
by vek (Prior) on Dec 05, 2005 at 21:45 UTC

    Try adding use lib '/home/myusername/modules'; to your program so that the directory can be added to @INC.

    -- vek --
      Yes, I've added that to the script. Is there anything else you can think of?