Sat Oct 15 17:53:51 2011 UTC ()
Fix build with perl 5.14... I think. Someone who actually knows how to
write Perl bindings should double-check this.

XXX: This will almost certainly not work on LP64 platforms as it casts
XXX: Perl-provided pointers to int and back. However, fixing this
XXX: requires changing the API of the parent Sablotron package, which
XXX: doesn't seem like a great idea at the moment.


(dholland)
diff -r1.3 -r1.4 pkgsrc/textproc/p5-XML-Sablotron/distinfo
diff -r0 -r1.1 pkgsrc/textproc/p5-XML-Sablotron/patches/patch-DOM_DOM_xsh
diff -r0 -r1.1 pkgsrc/textproc/p5-XML-Sablotron/patches/patch-Processor_Processor_h

cvs diff -r1.3 -r1.4 pkgsrc/textproc/p5-XML-Sablotron/Attic/distinfo (expand / switch to unified diff)

--- pkgsrc/textproc/p5-XML-Sablotron/Attic/distinfo 2010/09/19 11:20:37 1.3
+++ pkgsrc/textproc/p5-XML-Sablotron/Attic/distinfo 2011/10/15 17:53:51 1.4
@@ -1,5 +1,7 @@ @@ -1,5 +1,7 @@
1$NetBSD: distinfo,v 1.3 2010/09/19 11:20:37 wiz Exp $ 1$NetBSD: distinfo,v 1.4 2011/10/15 17:53:51 dholland Exp $
2 2
3SHA1 (XML-Sablotron-1.01.tar.gz) = 0a7b688b20300f95993e0c1f56761eb0d504772a 3SHA1 (XML-Sablotron-1.01.tar.gz) = 0a7b688b20300f95993e0c1f56761eb0d504772a
4RMD160 (XML-Sablotron-1.01.tar.gz) = e4a4a9ca520ed9096ea0fced2fe4d43f227e0953 4RMD160 (XML-Sablotron-1.01.tar.gz) = e4a4a9ca520ed9096ea0fced2fe4d43f227e0953
5Size (XML-Sablotron-1.01.tar.gz) = 53023 bytes 5Size (XML-Sablotron-1.01.tar.gz) = 53023 bytes
 6SHA1 (patch-DOM_DOM_xsh) = c9ea56c62f143b20ea671f1c17561fc608e01740
 7SHA1 (patch-Processor_Processor_h) = de8ca228c4249e7e00805dcc323b2383315b7b53

File Added: pkgsrc/textproc/p5-XML-Sablotron/patches/Attic/patch-DOM_DOM_xsh
$NetBSD: patch-DOM_DOM_xsh,v 1.1 2011/10/15 17:53:51 dholland Exp $

--- DOM/DOM.xsh~	2003-02-24 14:01:12.000000000 +0000
+++ DOM/DOM.xsh
@@ -635,7 +635,7 @@ xql_ns(object, expr, nsmap, ...)
          i = 0;
          hv_iterinit(maph);
          while (he = hv_iternext(maph)) {
-             int l;
+             ssize_t l;
              if (++nsnum > 10 * mapsize) {
                  mapsize++;
                  nsarr = realloc(nsarr, (10*2*mapsize + 1) * sizeof(char*));

File Added: pkgsrc/textproc/p5-XML-Sablotron/patches/Attic/patch-Processor_Processor_h
$NetBSD: patch-Processor_Processor_h,v 1.1 2011/10/15 17:53:51 dholland Exp $

--- Processor/Processor.h.orig	2004-06-04 13:20:40.000000000 +0000
+++ Processor/Processor.h
@@ -119,7 +119,7 @@ MessageHandlerMakeCodeStub(void *userDat
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSViv(severity)));
     XPUSHs(sv_2mortal(newSViv(facility)));
     XPUSHs(sv_2mortal(newSViv(code)));
@@ -167,7 +167,7 @@ MessageHandlerLogStub(void *userData, vo
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSViv(code)));
     XPUSHs(sv_2mortal(newSViv(level)));
     foo = fields;
@@ -215,7 +215,7 @@ MessageHandlerErrorStub(void *userData, 
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSViv(code)));
     XPUSHs(sv_2mortal(newSViv(level)));
     foo = fields;
@@ -250,7 +250,7 @@ int SchemeHandlerGetAllStub(void *userDa
   GV *gv;
   unsigned long ret = 0;
   SV *value;
-  unsigned int len;
+  size_t len;
 
   wrapper = (SV*)userData;
 
@@ -270,7 +270,7 @@ int SchemeHandlerGetAllStub(void *userDa
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSVpv((char*) scheme, strlen(scheme))));
     XPUSHs(sv_2mortal(newSVpv((char*) rest, strlen(rest))));
 
@@ -337,7 +337,7 @@ int SchemeHandlerOpenStub(void *userData
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSVpv((char*) scheme, strlen(scheme))));
     XPUSHs(sv_2mortal(newSVpv((char*) rest, strlen(rest))));
 
@@ -375,7 +375,7 @@ int SchemeHandlerGetStub(void *userData,
   GV *gv;
   unsigned long ret = 0;
   SV *value;
-  unsigned int len;
+  size_t len;
 
   wrapper = (SV*)userData;
 
@@ -395,7 +395,7 @@ int SchemeHandlerGetStub(void *userData,
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs((SV*)handle);
     XPUSHs(sv_2mortal(newSViv(*byteCount)));
     PUTBACK;
@@ -453,7 +453,7 @@ int SchemeHandlerPutStub(void *userData,
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs((SV*) handle);
     XPUSHs(sv_2mortal(newSVpv((char*) buffer, *byteCount)));
     PUTBACK;
@@ -506,7 +506,7 @@ int SchemeHandlerCloseStub(void *userDat
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs((SV*) handle);
 
     PUTBACK;
@@ -553,7 +553,7 @@ void SAXHandlerStartDocumentStub(void* u
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         PUTBACK;
         
@@ -593,7 +593,7 @@ void SAXHandlerStartElementStub(void* us
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) name, strlen(name))));
         att = (char**)atts;
@@ -639,7 +639,7 @@ void SAXHandlerEndElementStub(void* user
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) name, strlen(name))));
 
@@ -680,7 +680,7 @@ void SAXHandlerStartNamespaceStub(void* 
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) prefix, strlen(prefix))));
         XPUSHs(sv_2mortal(newSVpv((char*) uri, strlen(uri))));
@@ -722,7 +722,7 @@ void SAXHandlerEndNamespaceStub(void* us
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) prefix, strlen(prefix))));
 
@@ -763,7 +763,7 @@ void SAXHandlerCommentStub(void* userDat
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) contents, strlen(contents))));
 
@@ -804,7 +804,7 @@ void SAXHandlerPIStub(void* userData, vo
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) target, strlen(target))));
         XPUSHs(sv_2mortal(newSVpv((char*) contents, strlen(contents))));
@@ -846,7 +846,7 @@ void SAXHandlerCharactersStub(void* user
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         XPUSHs(sv_2mortal(newSVpv((char*) contents, length)));
 
@@ -886,7 +886,7 @@ void SAXHandlerEndDocumentStub(void* use
         if (processor_obj) 
             XPUSHs(processor_obj);
         else
-            XPUSHs(&sv_undef);
+            XPUSHs(&PL_sv_undef);
 
         PUTBACK;
         
@@ -931,7 +931,7 @@ MiscHandlerDocumentInfoStub(void* userDa
     if (processor_obj) 
       XPUSHs(processor_obj);
     else
-      XPUSHs(&sv_undef);
+      XPUSHs(&PL_sv_undef);
     XPUSHs(sv_2mortal(newSVpv((char*) contentType, strlen(contentType))));
     XPUSHs(sv_2mortal(newSVpv((char*) encoding, strlen(encoding))));