Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

There's no page on the Internet discussing the specific problem below so here goes:

I've tried running perl with ActivePerl, Apache/Perl, niPerl, PXPerl and SiePerl on Windows 2000 and I get this error:

>perl -w swatcher.pl
Can't locate Sys/Syslog.pm in @INC (@INC contains: C:/perl/perl/lib C:/perl/perl /site/lib .) at swatcher.pl line 54.
BEGIN failed--compilation aborted at swatcher.pl line 54.

How do I solve this?

Replies are listed 'Best First'.
Re: Sys::Syslog module problem
by aukjan (Friar) on Jul 01, 2005 at 07:04 UTC
    Sys::Syslog is a frontend to the syslog command on Unix.... So it would not make much sense to use this on a Windows machine... Hope this makes it more clear.
      Correct, but he doesn't even have Sys::Syslog installed.
        And that is also correct.. This module should not be installed on a Windows machine. (and probably won't but I can't verify that since I don't use Perl under windows.)
Re: Sys::Syslog module problem
by anonymized user 468275 (Curate) on Jul 01, 2005 at 08:02 UTC
    ...so you could create a module Syslog.pm containing the  sub syslog {} - i.e. a dummy.

    One world, one people

      Thanks guys!
      I now have dummy functions in syslog.pm, which solved the problem:
      sub syslog {} sub setlogsock {} sub openlog {} 1;
      I installed other modules required by swatcher and applied the same method where the program gave a similiar error about a module. The code, of course, needed to be worked on after this. Had to comment out lines and fix things.