Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup

[prev] [thread] [next] [Date index for 2004/11/26]

From: Stas Bekman
Subject: Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup
Date: 20:31 on 26 Nov 2004
Thierry Valentin wrote:
> Hello,
> I've tried the My::HappyWorkaround::CLONE trick...
> But sorry, same punishment as before:
> => Apache refuses to start + MS Failure Dialog.

Does this function get to run at all? Add:

   warn "CLONE is running\n";

inside this function and check the logs/console while starting the server.

I'd expect that it should work, since CLONE is run inside the cloned 
interprters.

Of course you need to remove any other instances of:

   use Win32::OLE

and inside CLONE it must be require().
[...]
>> There is one possible solution that will work for you though. Try to 
>> add to startup.pl the following code:
>>
>> sub My::HappyWorkaround::CLONE {
>>    require Win32::OLE;
>> }
>>
>> CLONE is a special function which is called when a new interpreter is 
>> started. Think of it as ChildInit but for the interpreter.



        -- 
        __________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@xxxxxx.xxx http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html

(message missing)

Re: Apache2/Modperl2 fails to preload Win32::OLE at server startup
Stas Bekman 20:31 on 26 Nov 2004

Generated at 11:26 on 21 Dec 2004 by mariachi v0.52