> Sure in: > http://search.cpan.org/src/FWILES/Apache-DB-0.10/lib/Apache/DProf.pm > > it goes: > > use constant MP2 => eval { require mod_perl; $mod_perl::VERSION > 1.99 }; > > so MP2 can never be true,
never is an awfully long time :) > since it should be mod_perl2 not mod_perl. mod_perl2.pm has this # this stuff is here to assist back compat # basically, if you # PerlModule mod_perl2 # or take similar steps to load mod_perl2 at # startup you are protected against loading mod_perl.pm # (either 1.0 or 1.99) at a later time by accident. $mod_perl::VERSION = $mod_perl2::VERSION; > Since I don't have mp1 installed (which I guess happens to work instead) > the module doesn't work. I guess the difference is that frank is loading some module somewhere that loads mod_perl2.pm while you are not. > > FWIW, Apache::DB has 'require mod_perl2'; > http://search.cpan.org/src/FWILES/Apache-DB-0.10/DB.pm and there is the difference. but regardless, stas has a point - we need a definitive way to tell whether you are running under mp1 or mp2, then update the docs. my suggestion is to check for $ENV{MOD_PERL_API_VERSION}, which only exists in the official 2.0 API (mp 1.999_22 and later). if that isn't set at the earliest possible moment, before _any_ mod_perl hooks can be called, then we need to fix that. --Geoff --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
