Subject: | Does not build on Solaris 10 |
Date: | Wed, 26 Aug 2009 16:24:07 +0100 |
To: | "bug-Tie-Syslog [...] rt.cpan.org" <bug-Tie-Syslog [...] rt.cpan.org> |
From: | Brad W Macpherson <brad.w.macpherson [...] jpmchase.com> |
Failure message:
PERL_DL_NONLAZY=1 /opt/ds/perl5.10.1/bin/perl "-Iblib/lib" "-Iblib/arch" test.pl
1..2
ok 1
no connection to syslog available
- getservbyname failed for syslog/tcp and syslogng/tcp
- udp connect: nobody listening at blib/lib/Tie/Syslog.pm line 81
*** Error code 255
make: Fatal error: Command failed for target `test_dynamic'
BROCSEIB/Tie-Syslog-1.07.tar.gz
Applying the following patch fixes the module:
diff -rupN Tie-Syslog-1.07-0Zhwyn/Syslog.pm Tie-Syslog-1.07-PjmBLL/Syslog.pm
--- Tie-Syslog-1.07-0Zhwyn/Syslog.pm 2002-01-21 03:24:46.000000000 +0000
+++ Tie-Syslog-1.07-PjmBLL/Syslog.pm 2009-07-28 17:31:27.000000000 +0100
@@ -60,8 +60,8 @@ sub TIEHANDLE {
## test in Sys::Syslog, so we'll test the symbol table to see
## if the routine exists. If not, skip this gracefully.
if ( defined($Sys::Syslog::{'setlogsock'}) ) {
- my $sock = shift || 'inet';
- return undef unless ($sock =~ /^(unix|inet)$/);
+ my $sock = shift || 'native';
+ return undef unless ($sock =~ /^(native|tcp|udp|eventlog|pipe|stream|console|unix|inet)$/);
## boy this is messy... must be this way, else compile time error
no strict 'refs';
@@ -156,9 +156,9 @@ Tie::Syslog - Tie a filehandle to Syslog
## facility.priority ('local0.error') ## note Linux uses 'err'
## identity ('my_program')
## log options ('pid')
- ## setlogsock ('inet'|'unix')
+ ## setlogsock (native|tcp|udp|eventlog|pipe|stream|console|unix|inet)
###
- tie *MYLOG, 'Tie::Syslog','local0.error','my_program','pid','inet';
+ tie *MYLOG, 'Tie::Syslog','local0.error','my_program','pid','native';
print MYLOG "I made an error."; ## this will be syslogged
printf MYLOG "Error %d", 42; ## syslog as "Error 42"
@@ -170,7 +170,7 @@ Tie::Syslog - Tie a filehandle to Syslog
## This stores the filehandle and uses it to implement calls
## like fileno() and binmode() etc...
###
- tie *STDERR, \*STDERR, 'Tie::Syslog','local0.error','my_app','pid','inet';
+ tie *STDERR, \*STDERR, 'Tie::Syslog','local0.error','my_app','pid','native';
###
## yeah, it looks funny, but is the only way...?
Cheers
Brad
This communication is for informational purposes only. It is not
intended as an offer or solicitation for the purchase or sale of
any financial instrument or as an official confirmation of any
transaction. All market prices, data and other information are not
warranted as to completeness or accuracy and are subject to change
without notice. Any comments or statements made herein do not
necessarily reflect those of JPMorgan Chase & Co., its subsidiaries
and affiliates.
This transmission may contain information that is privileged,
confidential, legally privileged, and/or exempt from disclosure
under applicable law. If you are not the intended recipient, you
are hereby notified that any disclosure, copying, distribution, or
use of the information contained herein (including any reliance
thereon) is STRICTLY PROHIBITED. Although this transmission and any
attachments are believed to be free of any virus or other defect
that might affect any computer system into which it is received and
opened, it is the responsibility of the recipient to ensure that it
is virus free and no responsibility is accepted by JPMorgan Chase &
Co., its subsidiaries and affiliates, as applicable, for any loss
or damage arising in any way from its use. If you received this
transmission in error, please immediately contact the sender and
destroy the material in its entirety, whether in electronic or hard
copy format. Thank you.
Please refer to http://www.jpmorgan.com/pages/disclosures for
disclosures relating to European legal entities.
Message body is not shown because it is too large.