perl-asp mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joel reed <joel.r...@ddiworld.com>
Subject [patch]fix for modperl-2.0.0-0.rc5
Date Wed, 22 Jun 2005 14:36:54 GMT
i needed to make the following change to get Apache::ASP 2.59 to 
work with fedora core 4's mod_perl-2.0.0-0.rc5.3.

without it i see:

[Wed Jun 22 09:10:21 2005] [error] [client 127.0.0.1] Can't locate object
method "get" via package "APR::Table" at /usr/lib/perl5/site_perl/5.8.6/Apache
/ASP.pm line 2022.\n at /usr/lib/perl5/site_perl/5.8.6/Apache/ASP.pm line 20
22\n\tApache::ASP::get_dir_config('APR::Table=HASH(0x80422a94)', 'Global')
called at /usr/lib/perl5/site_perl/5.8.6/Apache/ASP.pm line 
277\n\tApache::ASP::new('Apache::ASP', 'Apache2::RequestRec=SCALAR(0x8014fec4)',
'/usr/local/share/lm-4.0/web/status.asp') called at 
/usr/lib/perl5/site_perl/5.8.6/Apache/ASP.pm line 183\n\tApache::ASP::handler('Apache2::RequestRec=SCALAR(0x8014fec4)')
called at -e line 0\n\teval {...} called at -e line 0\n

because $mod_perl2 is not set as it should be.

HTH,

jr

here's what worked for me:

--- /usr/lib/perl5/site_perl/5.8.6/Apache/ASP.pm.orig	2005-06-22 10:10:37.000000000 -0400
+++ /usr/lib/perl5/site_perl/5.8.6/Apache/ASP.pm	2005-06-22 10:13:13.000000000 -0400
@@ -63,7 +63,11 @@ unless($LoadModPerl++) {
     }
 
     if($ENV{MOD_PERL}) {
-	$ModPerl2 = ($mod_perl::VERSION >= 1.99);
+  # release 1.999_22 of mod_perl seems to require 
+  # using $ENV{MOD_PERL_API_VERSION} not $mod_perl::VERSION
+	my $ver = $mod_perl::VERSION;
+	if ($ver eq "") { $ver = $ENV{MOD_PERL_API_VERSION}; }
+	$ModPerl2 = ($ver >= 1.99);
 	if($ModPerl2) {
 	    eval "use Apache::ASP::ApacheCommon ();";
 	    die($@) if $@;

---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe@perl.apache.org
For additional commands, e-mail: asp-help@perl.apache.org


Mime
View raw message