in reply to Re^2: Overriding the registry's PERL5LIB in mod_perl on Win32
in thread Overriding the registry's PERL5LIB in mod_perl on Win32

I have no idea how it works on Windows, but on Linux all you need to do to set PERL5LIB is put it on the command-line when you start apache: PERL5LIB=/my/path apachectl start

Replies are listed 'Best First'.
Re^4: Overriding the registry's PERL5LIB in mod_perl on Win32
by shay (Beadle) on May 22, 2009 at 08:02 UTC
    On Win32 Apache is run as a service. The command-line to run is specified in the registry under

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Apache2.2

    In my case this is:

    "C:\apache2.2\bin\httpd.exe" -k runservice

    It isn't as simple as just changing that to something like:

    set PERL5LIB=C:\perl\lib;C:\perl\site\lib && "C:\apache2.2\bin\httpd.exe" -k runservice

    but possibly some kind of wrapper program could be worked in there which sets PERL5LIB and then runs the service.

    I think I'm going to settle for just removing the registry lookup from my perl build, though.