|
From: Chris W. <ch...@cw...> - 2002-11-14 13:49:58
|
On Thu, 2002-11-14 at 03:01, Chris McDaniel wrote:
> Well, I've finally gotten trying to upgrade my OI installation. Following
> your outline below, I have installed (from cpan) the latest to a local lib
> directory (with PREFIX=/var/www/localperl/) and added the use lib statement
> to my .conf file - here's a little excerpt:
> ------------------
> <Perl>
> use lib qw( /var/www/commerce );
> use lib qw( /var/www/localperl/lib/site_perl/5.6.1 );
> use lib qw( /var/www/localperl/lib/5.6.1 );
> </Perl>
What happens if you do this instead:
<Perl>
use lib qw( /var/www/commerce
/var/www/localperl/lib/site_perl/5.6.1
/var/www/localperl/lib/5.6.1 );
</Perl>
> And I had some troubles starting up the server - here's the output
> ------------------
> [Thu Nov 14 02:38:40 2002] [error] Cannot read configuration file! Error: No
> configuration class corresponding to type (ini) at
> /usr/local/lib/perl5/site_perl/5.6.1/OpenInteract/Config.pm line 38.
> ...
> And it looks to me from the paths in the error message like my local modules
> are not being used... So I tried adding a use lib statement to startup.pl
> as well, just to see, and I get the same error.
Yes, that's the problem. Is the <Perl> section you listed above before
the PerlRequire that brings in startup.pl?
> Using a standalone script with the use lib statements as you suggested seems
> to be better - it just complains about a table not existing (which I
> expected) but I don't know if it is actually looking in my perllocal dir or
> not.
>
> Can anyone help me? Apologies if the solution is obvious, I have my
> wee-hours-of-the-morning-brain on...
Ok, so this is definitely an issue with the library directories in
mod_perl. If moving the <Perl> section before PerlRequire doesn't work,
something else to try would be explicitly placing the entries in @INC:
<Perl>
unshift @INC, qw( /var/www/commerce
/var/www/localperl/lib/site_perl/5.6.1
/var/www/localperl/lib/5.6.1 );
</Perl>
This does the same thing as 'use lib' (mostly) but at a lower level.
Also, add something like the following to startup.pl to see if the
changes are taking properly:
warn "My INC:\n", join( "\n", @INC ), "\n";
Good luck!
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|