Update devel/p5-Coro to 6.511

Plus additional patch for perl 5.24 and disable JIT due to W^X violations.

OK sthen@
This commit is contained in:
afresh1 2016-10-16 18:23:53 +00:00
parent d2b98b772a
commit e91a6d94b3
3 changed files with 29 additions and 5 deletions

View File

@ -1,10 +1,9 @@
# $OpenBSD: Makefile,v 1.13 2016/07/06 21:06:21 sthen Exp $
# $OpenBSD: Makefile,v 1.14 2016/10/16 18:23:53 afresh1 Exp $
COMMENT = coroutines for perl
MODULES = cpan
DISTNAME = Coro-6.49
REVISION = 0
DISTNAME = Coro-6.511
CATEGORIES = devel
# perl
@ -26,4 +25,7 @@ RUN_DEPENDS = devel/p5-Event>=0.89 \
# CONFIGURE_ENV = CORO_INTERFACE=s
# The Coro JIT violates W^X, so we can't use it.
CONFIGURE_ENV += CORO_JIT=n
.include <bsd.port.mk>

View File

@ -1,2 +1,2 @@
SHA256 (Coro-6.49.tar.gz) = B4z0wM0efgx40+DPvAfN4sHvkBpPSwc2nBF3MPriFSI=
SIZE (Coro-6.49.tar.gz) = 191823
SHA256 (Coro-6.511.tar.gz) = fj7UjNs/N0LZSuOrPQiMOrgYxSH4aB2mxfZWvUmsU+o=
SIZE (Coro-6.511.tar.gz) = 195173

View File

@ -0,0 +1,22 @@
$OpenBSD: patch-Coro_State_xs,v 1.1 2016/10/16 18:23:53 afresh1 Exp $
Description: fix for Coro with 5.24
Origin: https://paste.debian.net/688072
Bug-Debian: https://bugs.debian.org/838851
Bug: https://rt.cpan.org/Public/Bug/Display.html?id=114708
Author: Anonymous
Last-Update: 2016-09-25
--- Coro/State.xs.orig Sun Jun 26 14:44:30 2016
+++ Coro/State.xs Sat Oct 15 13:38:04 2016
@@ -1412,7 +1412,11 @@ runops_trace (pTHX)
PUSHMARK (SP);
PUSHs (&PL_sv_yes);
PUSHs (fullname);
+# if PERL_VERSION_ATLEAST(5,24,0)
+ PUSHs (CxHASARGS (cx) ? sv_2mortal (newRV_inc (PL_curpad[0])) : &PL_sv_undef);
+#else
PUSHs (CxHASARGS (cx) ? sv_2mortal (newRV_inc ((SV *)cx->blk_sub.argarray)) : &PL_sv_undef);
+#endif
PUTBACK;
cb = hv_fetch ((HV *)SvRV (coro_current), "_trace_sub_cb", sizeof ("_trace_sub_cb") - 1, 0);
if (cb) call_sv (*cb, G_KEEPERR | G_EVAL | G_VOID | G_DISCARD);