diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2023-05-10 21:19:33 +0200 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2023-05-18 13:36:36 +0200 |
commit | ea9006c8e8ff30532f8ebd66d850cc6b2b8701b7 (patch) | |
tree | 7fbd47f2aaba2a5e0e6e095ada55a647472b82ab /textproc/xmlstarlet/files/patch-src_xml__elem.c | |
parent | multimedia/smpeg: fix build with clang 16 (diff) |
textproc/p5-XML-LibXML: fix build with clang 16
Clang 16 has a new error about incompatible function types, which shows
up when building textproc/p5-XML-LibXML:
perl-libxml-mm.c:142:18: error: incompatible function pointer types passing 'void (void *, void *, xmlChar *)' (aka 'void (void *, void *, unsigned char *)') to parameter of type 'xmlHashScanner' (aka 'void (*)(void *, void *, const unsigned char *)') [-Wincompatible-function-pointer-types]
xmlHashScan(r, PmmRegistryDumpHashScanner, NULL);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/libxml2/libxml/hash.h:213:22: note: passing argument to parameter 'f' here
xmlHashScanner f,
^
perl-libxml-mm.c:234:44: error: incompatible function pointer types passing 'void (void *, xmlChar *)' (aka 'void (void *, unsigned char *)') to parameter of type 'xmlHashDeallocator' (aka 'void (*)(void *, const unsigned char *)') [-Wincompatible-function-pointer-types]
if( xmlHashRemoveEntry(PmmREGISTRY, name, PmmRegistryHashDeallocator) )
^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/libxml2/libxml/hash.h:160:47: note: passing argument to parameter 'f' here
xmlHashDeallocator f);
^
perl-libxml-mm.c:301:38: error: incompatible function pointer types passing 'void *(void *, xmlChar *)' (aka 'void *(void *, unsigned char *)') to parameter of type 'xmlHashCopier' (aka 'void *(*)(void *, const unsigned char *)') [-Wincompatible-function-pointer-types]
reg_copy = xmlHashCopy(PmmREGISTRY, PmmRegistryHashCopier);
^~~~~~~~~~~~~~~~~~~~~
/usr/local/include/libxml2/libxml/hash.h:208:21: note: passing argument to parameter 'f' here
xmlHashCopier f);
^
In all three cases, the libxml2 callback functions require const xmlChar
pointers, so fix the parameters in their definitions.
PR: 271355
Approved by: portmgr (build fix blanket)
MFH: 2023Q2
Diffstat (limited to 'textproc/xmlstarlet/files/patch-src_xml__elem.c')
0 files changed, 0 insertions, 0 deletions