mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-05 05:17:07 +02:00
community/pidgin-sipe: fix build with gcc 14
This commit is contained in:
parent
868d723d0a
commit
c87c90aaf4
@ -2,7 +2,7 @@
|
|||||||
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
|
||||||
pkgname=pidgin-sipe
|
pkgname=pidgin-sipe
|
||||||
pkgver=1.25.0
|
pkgver=1.25.0
|
||||||
pkgrel=1
|
pkgrel=2
|
||||||
pkgdesc="Pidgin protocol plugin to connect to MS Office Communicator"
|
pkgdesc="Pidgin protocol plugin to connect to MS Office Communicator"
|
||||||
url="https://sipe.sourceforge.net/"
|
url="https://sipe.sourceforge.net/"
|
||||||
arch="all"
|
arch="all"
|
||||||
@ -24,6 +24,7 @@ checkdepends="appstream"
|
|||||||
subpackages="$pkgname-lang"
|
subpackages="$pkgname-lang"
|
||||||
source="https://downloads.sourceforge.net/project/sipe/sipe/pidgin-sipe-$pkgver/pidgin-sipe-$pkgver.tar.bz2
|
source="https://downloads.sourceforge.net/project/sipe/sipe/pidgin-sipe-$pkgver/pidgin-sipe-$pkgver.tar.bz2
|
||||||
asc.patch
|
asc.patch
|
||||||
|
gcc14-update-for-libxml2.patch
|
||||||
"
|
"
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
@ -58,4 +59,5 @@ package() {
|
|||||||
sha512sums="
|
sha512sums="
|
||||||
37992bc133eadb05c3f187e97cd82cf8d8bf344d176a73827e78ff9521dbd66b3d0a8ff5d3b27bc1b7eb2797d3484b289390821634d11a7545c0cd2da38953b3 pidgin-sipe-1.25.0.tar.bz2
|
37992bc133eadb05c3f187e97cd82cf8d8bf344d176a73827e78ff9521dbd66b3d0a8ff5d3b27bc1b7eb2797d3484b289390821634d11a7545c0cd2da38953b3 pidgin-sipe-1.25.0.tar.bz2
|
||||||
644cc4719dc0ee3a431ec1b9232137a06bd27e48693f2232478035cce8e503bbe2109fc232032cd2d91a316addbc895e44a0f40028839b753e710c6149dca356 asc.patch
|
644cc4719dc0ee3a431ec1b9232137a06bd27e48693f2232478035cce8e503bbe2109fc232032cd2d91a316addbc895e44a0f40028839b753e710c6149dca356 asc.patch
|
||||||
|
8709fafc1375b3876d2f02623a08f46e01a45e3157155e35417f83d0f9dae2888a4ecdd0674b683f4461207de6abd1d155c4a59867bed7d31902434fbdc86d95 gcc14-update-for-libxml2.patch
|
||||||
"
|
"
|
||||||
|
68
community/pidgin-sipe/gcc14-update-for-libxml2.patch
Normal file
68
community/pidgin-sipe/gcc14-update-for-libxml2.patch
Normal file
@ -0,0 +1,68 @@
|
|||||||
|
Source: https://src.fedoraproject.org/rpms/pidgin-sipe/blob/rawhide/f/pidgin-sipe-1.25.0-fix-libxml2-2.12-build.patch
|
||||||
|
---
|
||||||
|
From 8c37bad762decd3aad86cfe758187a610804b196 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Stefan Becker <chemobejk@gmail.com>
|
||||||
|
Date: Mon, 22 Jan 2024 22:47:20 +0200
|
||||||
|
Subject: [PATCH 1/2] xml: update for libxml2 >= 2.12 API changes
|
||||||
|
|
||||||
|
- error callback is now passed a const error
|
||||||
|
- provide alternative implementation for the deprecated
|
||||||
|
xmlSAXUserParseMemory() API
|
||||||
|
---
|
||||||
|
src/core/sipe-xml.c | 31 ++++++++++++++++++++++++++++++-
|
||||||
|
1 file changed, 30 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/core/sipe-xml.c b/src/core/sipe-xml.c
|
||||||
|
index cfc53115..e69d6d02 100644
|
||||||
|
--- a/src/core/sipe-xml.c
|
||||||
|
+++ b/src/core/sipe-xml.c
|
||||||
|
@@ -154,7 +154,13 @@ static void callback_error(void *user_data, const char *msg, ...)
|
||||||
|
g_free(errmsg);
|
||||||
|
}
|
||||||
|
|
||||||
|
-static void callback_serror(void *user_data, xmlErrorPtr error)
|
||||||
|
+static void callback_serror(void *user_data,
|
||||||
|
+#if LIBXML_VERSION > 21200
|
||||||
|
+ const xmlError *error
|
||||||
|
+#else
|
||||||
|
+ xmlErrorPtr error
|
||||||
|
+#endif
|
||||||
|
+)
|
||||||
|
{
|
||||||
|
struct _parser_data *pd = user_data;
|
||||||
|
|
||||||
|
@@ -217,8 +223,31 @@ sipe_xml *sipe_xml_parse(const gchar *string, gsize length)
|
||||||
|
if (string && length) {
|
||||||
|
struct _parser_data *pd = g_new0(struct _parser_data, 1);
|
||||||
|
|
||||||
|
+#if LIBXML_VERSION > 21200
|
||||||
|
+ xmlParserCtxtPtr ctxt = xmlNewSAXParserCtxt(&parser, pd);
|
||||||
|
+
|
||||||
|
+ if (ctxt) {
|
||||||
|
+ xmlCtxtReadMemory(ctxt,
|
||||||
|
+ string,
|
||||||
|
+ length,
|
||||||
|
+ NULL,
|
||||||
|
+ NULL,
|
||||||
|
+ 0);
|
||||||
|
+
|
||||||
|
+ pd->error = !ctxt->wellFormed;
|
||||||
|
+
|
||||||
|
+ if (ctxt->myDoc) {
|
||||||
|
+ xmlFreeDoc(ctxt->myDoc);
|
||||||
|
+ ctxt->myDoc = NULL;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ xmlFreeParserCtxt(ctxt);
|
||||||
|
+ } else
|
||||||
|
+ pd->error = TRUE;
|
||||||
|
+#else
|
||||||
|
if (xmlSAXUserParseMemory(&parser, pd, string, length))
|
||||||
|
pd->error = TRUE;
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
if (pd->error) {
|
||||||
|
sipe_xml_free(pd->root);
|
||||||
|
--
|
||||||
|
2.43.0
|
||||||
|
|
Loading…
Reference in New Issue
Block a user