diff --git a/libxml2-2.12.9.tar.xz b/libxml2-2.12.9.tar.xz new file mode 100644 index 0000000..d82cf49 --- /dev/null +++ b/libxml2-2.12.9.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:59912db536ab56a3996489ea0299768c7bcffe57169f0235e7f962a91f483590 +size 2643456 diff --git a/libxml2-2.13.5.tar.xz b/libxml2-2.13.5.tar.xz deleted file mode 100644 index b5e5e8f..0000000 --- a/libxml2-2.13.5.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:74fc163217a3964257d3be39af943e08861263c4231f9ef5b496b6f6d4c7b2b6 -size 2586872 diff --git a/libxml2-make-XPATH_MAX_NODESET_LENGTH-configurable.patch b/libxml2-make-XPATH_MAX_NODESET_LENGTH-configurable.patch index 62c7ebc..98cf465 100644 --- a/libxml2-make-XPATH_MAX_NODESET_LENGTH-configurable.patch +++ b/libxml2-make-XPATH_MAX_NODESET_LENGTH-configurable.patch @@ -2,10 +2,10 @@ xpath.c | 40 +++++++++++++++++++++++++++++----------- 1 file changed, 29 insertions(+), 11 deletions(-) -Index: libxml2-2.13.5/xpath.c +Index: libxml2-2.12.0/xpath.c =================================================================== ---- libxml2-2.13.5.orig/xpath.c -+++ libxml2-2.13.5/xpath.c +--- libxml2-2.12.0.orig/xpath.c ++++ libxml2-2.12.0/xpath.c @@ -25,6 +25,7 @@ #include #include @@ -14,7 +14,7 @@ Index: libxml2-2.13.5/xpath.c #include #include #include -@@ -104,14 +105,32 @@ +@@ -106,14 +107,32 @@ #define XPATH_MAX_STACK_DEPTH 1000000 /* @@ -52,57 +52,57 @@ Index: libxml2-2.13.5/xpath.c /* * XPATH_MAX_RECRUSION_DEPTH: -@@ -2881,7 +2900,7 @@ xmlXPathNodeSetAddNs(xmlNodeSetPtr cur, +@@ -3095,7 +3114,7 @@ xmlXPathNodeSetAddNs(xmlNodeSetPtr cur, } else if (cur->nodeNr == cur->nodeMax) { xmlNodePtr *temp; -- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (cur->nodeMax >= get_max_nodeset_len()) +- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (cur->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "growing nodeset hit limit\n"); return(-1); - temp = (xmlNodePtr *) xmlRealloc(cur->nodeTab, cur->nodeMax * 2 * - sizeof(xmlNodePtr)); -@@ -2933,7 +2952,7 @@ xmlXPathNodeSetAdd(xmlNodeSetPtr cur, xm + } +@@ -3153,7 +3172,7 @@ xmlXPathNodeSetAdd(xmlNodeSetPtr cur, xm } else if (cur->nodeNr == cur->nodeMax) { xmlNodePtr *temp; -- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (cur->nodeMax >= get_max_nodeset_len()) +- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (cur->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "growing nodeset hit limit\n"); return(-1); - temp = (xmlNodePtr *) xmlRealloc(cur->nodeTab, cur->nodeMax * 2 * - sizeof(xmlNodePtr)); -@@ -2983,7 +3002,7 @@ xmlXPathNodeSetAddUnique(xmlNodeSetPtr c + } +@@ -3209,7 +3228,7 @@ xmlXPathNodeSetAddUnique(xmlNodeSetPtr c } else if (cur->nodeNr == cur->nodeMax) { xmlNodePtr *temp; -- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (cur->nodeMax >= get_max_nodeset_len()) +- if (cur->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (cur->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "growing nodeset hit limit\n"); return(-1); - temp = (xmlNodePtr *) xmlRealloc(cur->nodeTab, cur->nodeMax * 2 * - sizeof(xmlNodePtr)); -@@ -3071,7 +3090,7 @@ xmlXPathNodeSetMerge(xmlNodeSetPtr val1, + } +@@ -3302,7 +3321,7 @@ xmlXPathNodeSetMerge(xmlNodeSetPtr val1, } else if (val1->nodeNr == val1->nodeMax) { xmlNodePtr *temp; -- if (val1->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (val1->nodeMax >= get_max_nodeset_len()) +- if (val1->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (val1->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "merging nodeset hit limit\n"); goto error; - temp = (xmlNodePtr *) xmlRealloc(val1->nodeTab, val1->nodeMax * 2 * - sizeof(xmlNodePtr)); -@@ -3157,7 +3176,7 @@ xmlXPathNodeSetMergeAndClear(xmlNodeSetP + } +@@ -3394,7 +3413,7 @@ xmlXPathNodeSetMergeAndClear(xmlNodeSetP } else if (set1->nodeNr >= set1->nodeMax) { xmlNodePtr *temp; -- if (set1->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (set1->nodeMax >= get_max_nodeset_len()) +- if (set1->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (set1->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "merging nodeset hit limit\n"); goto error; - temp = (xmlNodePtr *) xmlRealloc( - set1->nodeTab, set1->nodeMax * 2 * sizeof(xmlNodePtr)); -@@ -3212,7 +3231,7 @@ xmlXPathNodeSetMergeAndClearNoDupls(xmlN + } +@@ -3455,7 +3474,7 @@ xmlXPathNodeSetMergeAndClearNoDupls(xmlN } else if (set1->nodeNr >= set1->nodeMax) { xmlNodePtr *temp; -- if (set1->nodeMax >= XPATH_MAX_NODESET_LENGTH) -+ if (set1->nodeMax >= get_max_nodeset_len()) +- if (set1->nodeMax >= XPATH_MAX_NODESET_LENGTH) { ++ if (set1->nodeMax >= get_max_nodeset_len()) { + xmlXPathErrMemory(NULL, "merging nodeset hit limit\n"); goto error; - temp = (xmlNodePtr *) xmlRealloc( - set1->nodeTab, set1->nodeMax * 2 * sizeof(xmlNodePtr)); + } diff --git a/libxml2-python3-string-null-check.patch b/libxml2-python3-string-null-check.patch index 9a8d18a..621e92b 100644 --- a/libxml2-python3-string-null-check.patch +++ b/libxml2-python3-string-null-check.patch @@ -11,11 +11,11 @@ invalid string. python/types.c | 4 ++++ 1 file changed, 4 insertions(+) -Index: libxml2-2.13.5/python/types.c +Index: libxml2-2.10.3/python/types.c =================================================================== ---- libxml2-2.13.5.orig/python/types.c -+++ libxml2-2.13.5/python/types.c -@@ -276,6 +276,10 @@ libxml_charPtrConstWrap(const char *str) +--- libxml2-2.10.3.orig/python/types.c ++++ libxml2-2.10.3/python/types.c +@@ -274,6 +274,10 @@ libxml_charPtrConstWrap(const char *str) return (Py_None); } ret = PY_IMPORT_STRING(str); diff --git a/libxml2-python3-unicode-errors.patch b/libxml2-python3-unicode-errors.patch index 67544c7..81d565e 100644 --- a/libxml2-python3-unicode-errors.patch +++ b/libxml2-python3-unicode-errors.patch @@ -2,11 +2,11 @@ python/libxml.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) -Index: libxml2-2.13.5/python/libxml.c +Index: libxml2-2.12.0/python/libxml.c =================================================================== ---- libxml2-2.13.5.orig/python/libxml.c -+++ libxml2-2.13.5/python/libxml.c -@@ -1491,6 +1491,7 @@ libxml_xmlErrorFuncHandler(ATTRIBUTE_UNU +--- libxml2-2.12.0.orig/python/libxml.c ++++ libxml2-2.12.0/python/libxml.c +@@ -1505,6 +1505,7 @@ libxml_xmlErrorFuncHandler(ATTRIBUTE_UNU PyObject *message; PyObject *result; char str[1000]; @@ -14,7 +14,7 @@ Index: libxml2-2.13.5/python/libxml.c if (libxml_xmlPythonErrorFuncHandler == NULL) { va_start(ap, msg); -@@ -1502,12 +1503,20 @@ libxml_xmlErrorFuncHandler(ATTRIBUTE_UNU +@@ -1516,12 +1517,20 @@ libxml_xmlErrorFuncHandler(ATTRIBUTE_UNU str[999] = 0; va_end(ap); diff --git a/libxml2.changes b/libxml2.changes index b5ba2f7..08ac238 100644 --- a/libxml2.changes +++ b/libxml2.changes @@ -1,5 +1,5 @@ ------------------------------------------------------------------- -Tue Nov 12 14:57:06 UTC 2024 - pgajdos@suse.com +Wed Nov 13 09:47:49 UTC 2024 - pgajdos@suse.com - add %{?sle15allpythons} macro [jsc#PED-68] diff --git a/libxml2.spec b/libxml2.spec index 59f09e9..3a91e5e 100644 --- a/libxml2.spec +++ b/libxml2.spec @@ -26,12 +26,12 @@ %{?sle15allpythons} Name: libxml2%{?dash}%{flavor} -Version: 2.13.5 +Version: 2.12.9 Release: 0 License: MIT Summary: A Library to Manipulate XML Files URL: https://gitlab.gnome.org/GNOME/libxml2 -Source0: https://download.gnome.org/sources/%{name}/2.13/libxml2-%{version}.tar.xz +Source0: https://download.gnome.org/sources/%{name}/2.12/libxml2-%{version}.tar.xz Source1: baselibs.conf # W3C Conformance tests Source2: https://www.w3.org/XML/Test/xmlts20080827.tar.gz @@ -244,6 +244,8 @@ rm -rf xmlconf/ # remove the conformance tests afterwards %files -n %{base_name}-doc %{_datadir}/gtk-doc/html/* +%doc %{_docdir}/%{base_name}/examples +%doc %{_docdir}/%{base_name}/tutorial %doc %{_docdir}/%{base_name}/*.html # owning these directories prevents gtk-doc <-> libxml2 build loop: %dir %{_datadir}/gtk-doc