Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: ModPerl: ASP

@INC

 

 

ModPerl asp RSS feed   Index | Next | Previous | View Threaded


hz at hzlabs

Jan 24, 2005, 1:43 AM

Post #1 of 1 (1313 views)
Permalink
@INC

Hi all,

i have a problem concerning Apache::ASP and the @INC Array:

(Apache 2.0.52, MP 1.999.21)

httpd.conf:
..
PerlRequire /www/hmdb-lifa/conf/startup.pl
..

startup.pl:

#!/usr/bin/perl
use Apache2;
..print @INC to file..
1;

@INC (at server startup) contains:

/usr/lib/perl5/site_perl/5.9.1/i686-linux-thread-multi/Apache2
/usr/lib/perl5/5.9.1/i686-linux-thread-multi
/usr/lib/perl5/5.9.1
/usr/lib/perl5/site_perl/5.9.1/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.9.1
/usr/lib/perl5/site_perl
.
/usr/local/apache2

just what one expected.

After adding the line "use Apache::ASP" to startup.pl, @INC contains:

/usr/lib/perl5/site_perl/5.9.1//i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.9.1/
/usr/lib/perl5/site_perl/5.9.1/i686-linux-thread-multi/Apache2
/usr/lib/perl5/5.9.1/i686-linux-thread-multi
/usr/lib/perl5/5.9.1
/usr/lib/perl5/site_perl/5.9.1/i686-linux-thread-multi
/usr/lib/perl5/site_perl/5.9.1
/usr/lib/perl5/site_perl
.
/usr/local/apache2

Obviously the first two lines were added.

Problems:

- why are there double slashes in the first line?

- why adding paths, which allready exist?

- the main problem however is, when you have "use Apache::ASP" in your
startup.pl
or an "PerlOptions Autoload" in your httpd.conf,
the Apache::ASP handler is loaded at server startup and adjusts the @INC
array
in a manner that not the Apache2 path comes first.

This can cause wrong (non Apache2) modules being loaded at startup (if
there are any -
like at my machine) , so that the server
wouldn't start at all because of version mismatches of modules.

The problem does not exist, if you have only an "PerlModule Apache::ASP",
because then
the Apache::ASP module is loaded later where the handler is involked (at
least that's what i
read in the modperl docus).

To make things confusing, this problem first happend, when i upgraded to
mod_perl-2.0.0-RC4 (from RC1).

Anyway, could it be a solution to add the additional INC-pathes at server
startup behind the original ones and
not before them?

(The additional document-root path, that is added at handler runtime,
however should stay in front
of the other paths)




Helmut


---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe [at] perl
For additional commands, e-mail: asp-help [at] perl

ModPerl asp RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.