fix(main/xmlstarlet): Fix building with current clang

This commit is contained in:
Fredrik Fornwall 2024-05-21 14:19:39 +02:00
parent 292d4624eb
commit 816fb69dfa
3 changed files with 25 additions and 1 deletions

View File

@ -3,7 +3,7 @@ TERMUX_PKG_DESCRIPTION="Command line XML toolkit"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=1.6.1
TERMUX_PKG_REVISION=5
TERMUX_PKG_REVISION=6
TERMUX_PKG_SRCURL=http://downloads.sourceforge.net/project/xmlstar/xmlstarlet/${TERMUX_PKG_VERSION}/xmlstarlet-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=15d838c4f3375332fd95554619179b69e4ec91418a3a5296e7c631b7ed19e7ca
TERMUX_PKG_DEPENDS="libxslt, libxml2"

View File

@ -0,0 +1,12 @@
diff -u -r ../xmlstarlet-1.6.1/src/xml.c ./src/xml.c
--- ../xmlstarlet-1.6.1/src/xml.c 2014-08-09 21:50:55.000000000 +0000
+++ ./src/xml.c 2024-05-21 12:15:20.663891778 +0000
@@ -104,7 +104,7 @@
/* by default all errors are reported */
static ErrorInfo errorInfo = { NULL, NULL, VERBOSE, CONTINUE };
-void reportError(void *ptr, xmlErrorPtr error)
+void reportError(void *ptr, const xmlError * error)
{
ErrorInfo *errorInfo = (ErrorInfo*) ptr;
assert(errorInfo);

View File

@ -0,0 +1,12 @@
diff -u -r ../xmlstarlet-1.6.1/src/xmlstar.h ./src/xmlstar.h
--- ../xmlstarlet-1.6.1/src/xmlstar.h 2014-03-03 00:15:08.000000000 +0000
+++ ./src/xmlstar.h 2024-05-21 12:15:09.735932324 +0000
@@ -32,7 +32,7 @@
ErrorStop stop;
} ErrorInfo;
-void reportError(void *ptr, xmlErrorPtr error);
+void reportError(void *ptr, const const xmlError * error);
void suppressErrors(void);
typedef struct _gOptions {