Date: Thu, 7 Jun 2007 23:43:10 +0800 (KRAST) From: Eugene Grosbein <eugen@grosbein.pp.ru> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/113458: net-im/vicq does not work with perl5.8 Message-ID: <200706071543.l57FhAn8002403@grosbein.pp.ru> Resent-Message-ID: <200706071600.l57G0DhQ092744@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 113458 >Category: ports >Synopsis: net-im/vicq does not work with perl5.8 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Jun 07 16:00:12 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Eugene Grosbein >Release: FreeBSD 6.2-STABLE i386 >Organization: Svyaz Service JSC >Environment: System: FreeBSD grosbein.pp.ru 6.2-STABLE FreeBSD 6.2-STABLE #16: Tue Apr 17 23:08:38 KRAST 2007 eu@grosbein.pp.ru:/mnt/home/obj/usr/local/src/sys/DADV i386 perl 5.8, vicq-0.4.2 >Description: Quoting some web page: Perl 5.8 has this wonderful thing called "safe interrupts", which essentially defers them. So the "alarm" that's supposed to interrupt the readline was deferred until AFTER the readline. Beautiful, no? So, vicq doesn't update status nor deliver messages asyncronously with input from keyboard when used with perl 5.8. >How-To-Repeat: Run vicq using perl 5.8 and try to receive a message. >Fix: diff -urN vicq.orig/Makefile vicq/Makefile --- vicq.orig/Makefile Thu Jun 7 23:26:53 2007 +++ vicq/Makefile Thu Jun 7 23:36:18 2007 @@ -30,4 +30,13 @@ ${MKDIR} ${PREFIX}/share/examples/vicq ${INSTALL_DATA} ${WRKSRC}/vicqrc.example ${PREFIX}/share/examples/vicq -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${PERL_LEVEL} >= 500800 +SIGNAL_PATCH=p5.8-patch-sigalrm +post-patch: + @${ECHO_MSG} "===> Applying patch ${SIGNAL_PATCH} for ${PKGNAME}" + @${PATCH} ${PATCH_ARGS} < ${PATCHDIR}/${SIGNAL_PATCH} +.endif + +.include <bsd.port.post.mk> diff -urN vicq.orig/files/p5.8-patch-sigalrm vicq/files/p5.8-patch-sigalrm --- vicq.orig/files/p5.8-patch-sigalrm Thu Jan 1 07:00:00 1970 +++ vicq/files/p5.8-patch-sigalrm Thu Jun 7 23:19:53 2007 @@ -0,0 +1,19 @@ +--- vicq.orig Thu Jun 7 23:15:28 2007 ++++ vicq Thu Jun 7 23:16:41 2007 +@@ -20,6 +20,7 @@ + use Getopt::Std; + use Socket; + use POSIX qw(mktime getcwd); ++use POSIX ':signal_h'; + package main; + use locale; + #use Data::Dumper; +@@ -3347,7 +3348,7 @@ + if(!$err) + { + print "done!\n"; +- $SIG{ALRM} = \&tick_handler; ++ sigaction SIGALRM, new POSIX::SigAction \&tick_handler; + alarm 1; + return 0; + } else Eugene Grosbein >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200706071543.l57FhAn8002403>