On Fri, Jan 16, 2004 at 01:03:00PM -0500, William McKee wrote:
On Thu, Jan 15, 2004 at 04:24:41PM -0800, Stas Bekman wrote:
I don't have apache 1.3 with ssl so I can't test it. And it doesn't quite work with apache/mp 2.0 because you have hardcoded mp1 API. Please see the porting doc: http://perl.apache.org/docs/2.0/user/porting/porting.html
http://perl.apache.org/docs/2.0/user/porting/porting.html#Making_Code_Conditional_on_Running_mod_perl_Version
Oops. Nice info in the links.
While trying to implement this checking in my Apache::TestTest module, I had problems with the following pragmas:
use Apache::Const -compile('OK'); use Apache::Constants ':common';
Because we must convert use to require to do the testing, I had to then run the import command to get the common tags into my module's namespace.
Yes, just like the document explains. Have you read further down? It goes:
if (MP2) { require Apache::RequestRec; require Apache::RequestIO; require Apache::Const; Apache::Const->import(-compile => 'OK'); } else { require Apache; require Apache::Constants; Apache::Constants->import('OK'); }
After that everything worked. I haven't tested under MP2 and was only guessing about my conversion so you may need to make some modifications to the module before testing the latest release[1]. I'd appreciate your feedback on my conversion efforts to support both mp1 and mp2. (Yeah, I know that I should install a test server locally. Too many things to do!).
[1] http://www.knowmad.com/~william/Apache-TestTest-0.03.tar.gz
And then 4 hours later you posted another email with a list of problems/questions. So is that the final working version or are you still working on it?
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com