Alex Harper wrote:

> 
>       >mod_perl 2.0 has solved these problems already, but it's not in
> 
>       >production yet :)
> 
> Well that give me something to look forward to :-)
> 
>       >Have you read this one?
>       
> 
>>http://perl.apache.org/guide/config.html#Is_There_a_Way_to_Modify_INC_o
>>
> n
>       >You probably need to use Apache::PerlVINC, but it's not very
> efficient.
> 
> 
> Actually, yes, I had. PerlVINC is not really what I needed, the goal was
> not to reload %INC per VirtualHost, the need was to have a single
> PerlRequire set up @INC properly per VirtualHost (so Apache::StatINC
> would work). Ordinary this would have been done with something like 'use
> lib "$FindBin::Bin/lib/", but since that doesn't work under mod_perl I
> was toying with using <Perl> sections.
> 
> For the record the problem was the line:
>       $PerlRequire = $somepath;
> Which needed to be:
>       push @PerlRequire, $somepath;


This won't work as you have seen already.

If you don't mind reloading the libs at run time, you can always call 
do() on FindBin which will force the reload of all its internals.


> Although why the previous version set the server spinning off I never
> could figure out. It happened even with
> Apache::Server::StrictPerlSections on.
> 
> In any case I've settled on absolute paths just like the examples. This
> increases the maintenance costs with multiple startup scripts, but
> solves the problem in the most obvious way.
> 
> Maybe this will be easier in mod_perl 2.0?


All I can tell you is that it works already :)

and it's very easy. Now let's see how soon httpd 2.0 gets released

and how soon we get mod_perl 2.0 out (which of course depends on 

Apache's release)


_____________________________________________________________________
Stas Bekman              JAm_pH     --   Just Another mod_perl Hacker
http://stason.org/       mod_perl Guide  http://perl.apache.org/guide
mailto:[EMAIL PROTECTED]   http://apachetoday.com http://eXtropia.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/


Reply via email to