[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-modperl
Subject:    Re[2]: Apache::Reload and @INC
From:       Igor Vylusko <versus () aha ! ru>
Date:       2002-11-27 11:21:57
[Download RAW message or body]

> > in doc
> > http://perl.apache.org/docs/2.0/api/mod_perl-2.0/Apache/Reload.html
> > declared that when using Apache::Reload I may define additional lib
> > in httpd.conf: PerlSetEnv PERL5LIB /home/httpd/perl/extra
> > But when I enable PerlInitHandler Apache::Reload in config all libs defined in
> > PERL5LIB are gone away from @INC.
> > I have Apache 1.3.27, mod_perl 1.27, Apache::Reload 0.07, perl 5.8.0
> > on RH7.2 and try PerlSetEnv PERL5LIB in main config section as well as
> > in VirtualHost sections.
> > I have bulk of VirtualHosts and would like make @INC different for each
> > one(i.e. not use lib ... in startup.pl).

SB> It's not easy with mod_perl 1.0. The manpage is talking about changing 
SB> @INC globally for the whole server. I usually do that with 'use lib' in 
SB> startup.pl.

I define PerlSetEnv PERL5LIB globaly for the whole server but PERL5LIB
was stripped out from @INC anyway on enabling PerlInitHandler Apache::Reload
in _any_ vhost.
I am using PerlSetEnv PERL5LIB per vhost basis and it works fine for me
without Apache::Reload.

> > Has anybody run across this problem?
> > If so....what is my solution?

SB> There are several solutions, none of which is very helpful in 
SB> production, since they either slow things down or may cause collisions 
SB> when modules with the same names are loaded, see:
SB> http://perl.apache.org/docs/1.0/guide/config.html#Is_There_a_Way_to_Modify__INC_on_a_Per_Virtual_Host_or_Per_Location_Basis_


I would like just set PerlInitHandler Apache::Reload on several vhosts
only for developing purposes and preserve everything else at that.

Thanks for advice,
Igor.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic