On Mon, 17 Mar 2003, Perrin Harkins wrote:

> Goehring, Chuck Mr., RCI - San Diego wrote:
> >     Where do you put your .pm files for application-specific code?
>
> Under mod_perl 1, I just put them in <SERVER_ROOT>/lib/perl, which is
> automatically added to @INC by mod_perl.  Can someone confirm if this
> still works for mp2?

I do not believe so. In mp2 when you do 'use Apache2();' it modifies your
@INC, but adds only <PERL_LIB>/Apache2 ... so my @INC inside my mp2 server
is:

/home/debug/perl/lib/site_perl/5.8.0/i386-freebsd/Apache2
/home/debug/perl/lib/5.8.0/i386-freebsd
/home/debug/perl/lib/5.8.0
/home/debug/perl/lib/site_perl/5.8.0/i386-freebsd
/home/debug/perl/lib/site_perl/5.8.0
/home/debug/perl/lib/site_perl
.



> Of course you can just put a "use lib" in your startup.pl, assuming that
> you are doing this for a server where you know the locations of things.

I do that anyway since I want to keep my application code separate from
the Apache/perl/mod_perl lib dirs. But that's just me. I'm a neat freak. I
used to use Partition Magic on my Windows boxes to make C: for the OS, D:
for apps, and E: for data, until I found out that Windows apps install
themselves wherever they feel like it :)

- nick

-- 

~~~~~~~~~~~~~~~~~~~~
Nick Tonkin   {|8^)>

Reply via email to