From 4b35628e97472eaf23d8a841d2f711f7c2f96255 Mon Sep 17 00:00:00 2001 From: Daniel Garcia Moreno Date: Tue, 24 Feb 2026 14:47:57 +0100 Subject: [PATCH] Fix nanohttp.c build when --without-output The xmlRegisterHTTPPostCallbacks and xmlRegisterDefaultOutputCallbacks are inside "#ifdef LIBXML_OUTPUT_ENABLED" in the xmlIO.h, so we should have the same in the nanohttp.c Fix https://gitlab.gnome.org/GNOME/libxml2/-/issues/1057 --- nanohttp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/nanohttp.c b/nanohttp.c index c87ce4451..a7c04de75 100644 --- a/nanohttp.c +++ b/nanohttp.c @@ -294,6 +294,7 @@ xmlIOHTTPClose (void *context ATTRIBUTE_UNUSED) { return 0; } +#ifdef LIBXML_OUTPUT_ENABLED /** * @deprecated HTTP support was removed in 2.15. */ @@ -301,5 +302,6 @@ void xmlRegisterHTTPPostCallbacks(void) { xmlRegisterDefaultOutputCallbacks(); } +#endif #endif /* LIBXML_HTTP_STUBS_ENABLED */