pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel/p5-Params-Classify Fix build with Perl 5.26.0 wi...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/bd52476250c2
branches:  trunk
changeset: 363346:bd52476250c2
user:      ryoon <ryoon%pkgsrc.org@localhost>
date:      Tue Jun 06 14:38:05 2017 +0000

description:
Fix build with Perl 5.26.0 with rt.cpan.org patch

diffstat:

 devel/p5-Params-Classify/distinfo                             |   3 +-
 devel/p5-Params-Classify/patches/patch-lib_Params_Classify.xs |  84 +++++++++++
 2 files changed, 86 insertions(+), 1 deletions(-)

diffs (100 lines):

diff -r db3c8e762662 -r bd52476250c2 devel/p5-Params-Classify/distinfo
--- a/devel/p5-Params-Classify/distinfo Tue Jun 06 14:22:36 2017 +0000
+++ b/devel/p5-Params-Classify/distinfo Tue Jun 06 14:38:05 2017 +0000
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.4 2015/11/03 03:28:38 agc Exp $
+$NetBSD: distinfo,v 1.5 2017/06/06 14:38:05 ryoon Exp $
 
 SHA1 (Params-Classify-0.013.tar.gz) = 00bcfc849ca40a2136366760641ff5650dd7950f
 RMD160 (Params-Classify-0.013.tar.gz) = 2e971e5358080f11a20af0c4a8015d5ad932d888
 SHA512 (Params-Classify-0.013.tar.gz) = 8638d0d952854770049a8cf382ce02f6164025ad7224588d41be02f504947cb9d309d95c33d8fc1c2e3b5de6dfdbeac7fdaf9cd16dd6ba0a3d546c7a002e65e6
 Size (Params-Classify-0.013.tar.gz) = 21014 bytes
+SHA1 (patch-lib_Params_Classify.xs) = fb2c032c97f1b99bffa4be5e37076df9425f348a
diff -r db3c8e762662 -r bd52476250c2 devel/p5-Params-Classify/patches/patch-lib_Params_Classify.xs
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/p5-Params-Classify/patches/patch-lib_Params_Classify.xs     Tue Jun 06 14:38:05 2017 +0000
@@ -0,0 +1,84 @@
+$NetBSD: patch-lib_Params_Classify.xs,v 1.1 2017/06/06 14:38:05 ryoon Exp $
+
+* Fix build with Perl 5.26.0
+  From https://rt.cpan.org/Public/Bug/Display.html?id=114490
+
+--- lib/Params/Classify.xs.orig        2010-11-16 20:35:47.000000000 +0000
++++ lib/Params/Classify.xs
+@@ -41,6 +41,26 @@
+ # define FPTR2DPTR(t,x) ((t)(UV)(x))
+ #endif /* !FPTR2DPTR */
+ 
++#ifndef OpHAS_SIBLING
++#  define OpHAS_SIBLING(o)               (cBOOL((o)->op_sibling))
++#endif
++
++#ifndef OpSIBLING
++#  define OpSIBLING(o)                   (0 + (o)->op_sibling)
++#endif
++
++#ifndef OpMORESIB_set
++#  define OpMORESIB_set(o, sib)          ((o)->op_sibling = (sib))
++#endif
++
++#ifndef OpLASTSIB_set
++#  define OpLASTSIB_set(o, parent)       ((o)->op_sibling = NULL)
++#endif
++
++#ifndef OpMAYBESIB_set
++#  define OpMAYBESIB_set(o, sib, parent) ((o)->op_sibling = (sib))
++#endif
++
+ #ifndef ptr_table_new
+ 
+ struct q_ptr_tbl_ent {
+@@ -625,8 +645,8 @@ static OP *myck_entersub(pTHX_ OP *op)
+       OP *(*ppfunc)(pTHX);
+       I32 cvflags;
+       pushop = cUNOPx(op)->op_first;
+-      if(!pushop->op_sibling) pushop = cUNOPx(pushop)->op_first;
+-      for(cvop = pushop; cvop->op_sibling; cvop = cvop->op_sibling) ;
++      if(!OpHAS_SIBLING(pushop)) pushop = cUNOPx(pushop)->op_first;
++      for(cvop = pushop; OpHAS_SIBLING(cvop); cvop = OpSIBLING(cvop)) ;
+       if(!(cvop->op_type == OP_RV2CV &&
+                       !(cvop->op_private & OPpENTERSUB_AMPER) &&
+                       (cv = rvop_cv(cUNOPx(cvop)->op_first)) &&
+@@ -635,20 +655,20 @@ static OP *myck_entersub(pTHX_ OP *op)
+               return nxck_entersub(aTHX_ op);
+       cvflags = CvXSUBANY(cv).any_i32;
+       op = nxck_entersub(aTHX_ op);   /* for prototype checking */
+-      aop = pushop->op_sibling;
+-      bop = aop->op_sibling;
++      aop = OpSIBLING(pushop);
++      bop = OpSIBLING(aop);
+       if(bop == cvop) {
+               if(!(cvflags & PC_ALLOW_UNARY)) return op;
+               unary:
+-              pushop->op_sibling = bop;
+-              aop->op_sibling = NULL;
++              OpLASTSIB_set(pushop, bop);
++              OpLASTSIB_set(aop, NULL);
+               op_free(op);
+               op = newUNOP(OP_NULL, 0, aop);
+               op->op_type = OP_RAND;
+               op->op_ppaddr = ppfunc;
+               op->op_private = (U8)cvflags;
+               return op;
+-      } else if(bop && bop->op_sibling == cvop) {
++      } else if(bop && OpSIBLING(op) == cvop) {
+               if(!(cvflags & PC_ALLOW_BINARY)) return op;
+               if(ppfunc == THX_pp_check_sclass &&
+                               (cvflags & PC_TYPE_MASK) == SCLASS_REF) {
+@@ -667,9 +687,9 @@ static OP *myck_entersub(pTHX_ OP *op)
+                       cvflags &= ~PC_TYPE_MASK;
+                       ppfunc = THX_pp_check_dyn_battr;
+               }
+-              pushop->op_sibling = cvop;
+-              aop->op_sibling = NULL;
+-              bop->op_sibling = NULL;
++              OpLASTSIB_set(pushop, cvop);
++              OpLASTSIB_set(aop, NULL);
++              OpLASTSIB_set(bop, NULL);
+               op_free(op);
+               op = newBINOP(OP_NULL, 0, aop, bop);
+               op->op_type = OP_RAND;



Home | Main Index | Thread Index | Old Index