pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/textproc/libxml2 libxml2: Fix building with ICU 68.1



details:   https://anonhg.NetBSD.org/pkgsrc/rev/5a565168b3a6
branches:  trunk
changeset: 441545:5a565168b3a6
user:      adam <adam%pkgsrc.org@localhost>
date:      Thu Nov 05 17:45:55 2020 +0000

description:
libxml2: Fix building with ICU 68.1

diffstat:

 textproc/libxml2/distinfo                 |   4 ++--
 textproc/libxml2/patches/patch-encoding.c |  29 +++++++++++++++++++++--------
 2 files changed, 23 insertions(+), 10 deletions(-)

diffs (97 lines):

diff -r 10a4645744bc -r 5a565168b3a6 textproc/libxml2/distinfo
--- a/textproc/libxml2/distinfo Thu Nov 05 17:41:28 2020 +0000
+++ b/textproc/libxml2/distinfo Thu Nov 05 17:45:55 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.132 2020/01/24 10:40:36 kim Exp $
+$NetBSD: distinfo,v 1.133 2020/11/05 17:45:55 adam Exp $
 
 SHA1 (libxml2-2.9.10.tar.gz) = db6592ec9ca9708c4e71bf6bfd907bbb5cd40644
 RMD160 (libxml2-2.9.10.tar.gz) = 455f81e1f121c63dac96802de7f83ce4483f1afe
@@ -8,7 +8,7 @@
 SHA1 (patch-catalog.c) = 34afe787f6012b460a85be993048e133907a1621
 SHA1 (patch-configure) = f6e9f08377a537657df08deee17a5cc66c60b808
 SHA1 (patch-doc_examples_Makefile.in) = 4eede9719724f94402e850ee6d6043a74aaf62b2
-SHA1 (patch-encoding.c) = 6cf0a7d421828b9f40a4079ee85adb791c54d096
+SHA1 (patch-encoding.c) = 62b3343f0a0ea51e3fb8eb693e495520eefb6ffd
 SHA1 (patch-parser.c) = 9dcda6b8bc71c1abb095fc2c840ac40c1ae04a33
 SHA1 (patch-python_libxml.c) = cfa07b4f3dfddb501c2ba210bb32b8ee14e3df9d
 SHA1 (patch-python_libxml.py) = 869a72ae5ba2e27e6d46552878890acb22337675
diff -r 10a4645744bc -r 5a565168b3a6 textproc/libxml2/patches/patch-encoding.c
--- a/textproc/libxml2/patches/patch-encoding.c Thu Nov 05 17:41:28 2020 +0000
+++ b/textproc/libxml2/patches/patch-encoding.c Thu Nov 05 17:45:55 2020 +0000
@@ -1,14 +1,27 @@
-$NetBSD: patch-encoding.c,v 1.2 2016/05/24 21:08:21 wiz Exp $
+$NetBSD: patch-encoding.c,v 1.3 2020/11/05 17:45:55 adam Exp $
 
+Fix building with ICU 68.1.
 Avoid potential undefined behaviour by casting arg to toupper()
 to an appropriate value range.
 https://bugzilla.gnome.org/show_bug.cgi?id=766838
 
 Also, on NetBSD, add CP1141 encoding alias.
 
---- encoding.c.orig    2016-05-23 07:25:25.000000000 +0000
+--- encoding.c.orig    2019-10-22 18:46:01.000000000 +0000
 +++ encoding.c
-@@ -1018,7 +1018,7 @@ xmlGetEncodingAlias(const char *alias) {
+@@ -48,6 +48,11 @@
+ #include "buf.h"
+ #include "enc.h"
+ 
++#if !defined(FALSE)
++# define FALSE (1 == 0)
++# define TRUE (! FALSE)
++#endif
++
+ static xmlCharEncodingHandlerPtr xmlUTF16LEHandler = NULL;
+ static xmlCharEncodingHandlerPtr xmlUTF16BEHandler = NULL;
+ 
+@@ -1027,7 +1032,7 @@ xmlGetEncodingAlias(const char *alias) {
        return(NULL);
  
      for (i = 0;i < 99;i++) {
@@ -17,7 +30,7 @@
        if (upper[i] == 0) break;
      }
      upper[i] = 0;
-@@ -1053,7 +1053,7 @@ xmlAddEncodingAlias(const char *name, co
+@@ -1062,7 +1067,7 @@ xmlAddEncodingAlias(const char *name, co
        return(-1);
  
      for (i = 0;i < 99;i++) {
@@ -26,7 +39,7 @@
        if (upper[i] == 0) break;
      }
      upper[i] = 0;
-@@ -1155,7 +1155,7 @@ xmlParseCharEncoding(const char* name)
+@@ -1164,7 +1169,7 @@ xmlParseCharEncoding(const char* name)
        name = alias;
  
      for (i = 0;i < 499;i++) {
@@ -35,7 +48,7 @@
        if (upper[i] == 0) break;
      }
      upper[i] = 0;
-@@ -1331,7 +1331,7 @@ xmlNewCharEncodingHandler(const char *na
+@@ -1340,7 +1345,7 @@ xmlNewCharEncodingHandler(const char *na
        return(NULL);
      }
      for (i = 0;i < 499;i++) {
@@ -44,7 +57,7 @@
        if (upper[i] == 0) break;
      }
      upper[i] = 0;
-@@ -1433,6 +1433,9 @@ xmlInitCharEncodingHandlers(void) {
+@@ -1442,6 +1447,9 @@ xmlInitCharEncodingHandlers(void) {
      xmlRegisterCharEncodingHandlersISO8859x ();
  #endif
  #endif
@@ -54,7 +67,7 @@
  
  }
  
-@@ -1660,7 +1663,7 @@ xmlFindCharEncodingHandler(const char *n
+@@ -1669,7 +1677,7 @@ xmlFindCharEncodingHandler(const char *n
       * Check first for directly registered encoding names
       */
      for (i = 0;i < 99;i++) {



Home | Main Index | Thread Index | Old Index