From f687f3e002777934d101033c9baab6db7fa83406 Mon Sep 17 00:00:00 2001 From: Nick Wellnhofer Date: Wed, 27 Apr 2022 12:39:12 +0200 Subject: [PATCH] Define LFS macros before including system headers xmlstring.h includes stdarg.h, so it must be included after defining macros like _FILE_OFFSET_BITS. --- libxml.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/libxml.h b/libxml.h index 1090729c..d40fcf86 100644 --- a/libxml.h +++ b/libxml.h @@ -9,8 +9,10 @@ #ifndef __XML_LIBXML_H__ #define __XML_LIBXML_H__ -#include - +/* + * These macros must be defined before including system headers. + * Do not add any #include directives above this block. + */ #ifndef NO_LARGEFILE_SOURCE #ifndef _LARGEFILE_SOURCE #define _LARGEFILE_SOURCE @@ -39,6 +41,7 @@ #include "config.h" #include #endif +#include #if defined(__Lynx__) #include /* pull definition of size_t */