Subject: | Syslog.pm does not match Syslog.xs for LOG_UPTO usage |
Date: | Thu, 19 Mar 2009 01:59:26 +0100 |
To: | bug-Sys-Syslog [...] rt.cpan.org |
From: | Guenter Knauf <info [...] gknw.de> |
Hi,
While Syslog.xs has a conditional for LOG_UPTO at line 95ff, Syslog.pm
uses it unconditionally at line 98; this renders the whole module
useless when the LOG_UPTO macro is not defined in the OS headers:
perl -mSys::Syslog -e 'print $Sys::Syslog::VERSION'
Your vendor has not defined the Sys::Syslog macro LOG_UPTO at
sys:\perl\lib/Sys/Syslog.pm line 98.
I think if Syslog.pm requires LOG_UPTO from Syslog.xs then its nonsense
to have a conditonal in the xs file which checks for presense of the
LOG_UPTO macro - why should I build a module only for having it croak
directly when it loads? Then its far better that it breaks at compile
time so I know that the module isnt usable at all.
Either make compilation break when mandatory system header macros are
missing, or rewrite Syslog.pm so that they are not mandatory.
Thanks, Guen.