Hi all, I tried Eli's advice in this message[1] reg. silencing of compiler warnings about "free" redefined. The change below made them go away:
--8<---------------cut here---------------start------------->8--- diff --git a/tp/Texinfo/XS/MiscXS.xs b/tp/Texinfo/XS/MiscXS.xs index a8c58cc539..65b6eca2f8 100644 --- a/tp/Texinfo/XS/MiscXS.xs +++ b/tp/Texinfo/XS/MiscXS.xs @@ -5,6 +5,9 @@ #define PERL_NO_GET_CONTEXT #include "EXTERN.h" #include "perl.h" +#if defined _WIN32 && !defined __CYGWIN__ +# undef free +#endif #include "XSUB.h" #include "ppport.h" diff --git a/tp/Texinfo/XS/misc.c b/tp/Texinfo/XS/misc.c index f582a81ee2..6d8fac3c3d 100644 --- a/tp/Texinfo/XS/misc.c +++ b/tp/Texinfo/XS/misc.c @@ -37,6 +37,9 @@ #include "EXTERN.h" #include "perl.h" +#if defined _WIN32 && !defined __CYGWIN__ +# undef free +#endif #include "XSUB.h" #include "ppport.h" diff --git a/tp/Texinfo/XS/parsetexi/Parsetexi.xs b/tp/Texinfo/XS/parsetexi/Parsetexi.xs index 176f162e21..342c40dfaa 100644 --- a/tp/Texinfo/XS/parsetexi/Parsetexi.xs +++ b/tp/Texinfo/XS/parsetexi/Parsetexi.xs @@ -6,6 +6,9 @@ #define PERL_NO_GET_CONTEXT #include "EXTERN.h" #include "perl.h" +#if defined _WIN32 && !defined __CYGWIN__ +# undef free +#endif #include "XSUB.h" #undef context diff --git a/tp/Texinfo/XS/xspara.c b/tp/Texinfo/XS/xspara.c index 96a4b81a17..d72ef2c8d3 100644 --- a/tp/Texinfo/XS/xspara.c +++ b/tp/Texinfo/XS/xspara.c @@ -37,6 +37,9 @@ #include "EXTERN.h" #include "perl.h" +#if defined _WIN32 && !defined __CYGWIN__ +# undef free +#endif #include "XSUB.h" #include "ppport.h" --8<---------------cut here---------------end--------------->8--- Please note that I'm not familiar with internals of Texinfo; this was more trial and error. The only other warnings I get are (linebreaks added manually): --8<---------------cut here---------------start------------->8--- parsetexi/handle_commands.c: In function 'handle_other_command': parsetexi/handle_commands.c:399:31: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] 399 | max_columns = (long) k->value; | ^ parsetexi/handle_commands.c: In function 'handle_line_command': parsetexi/handle_commands.c:755:29: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] 755 | level = (long) k->value + 1; | ^ parsetexi/extra.c: In function 'add_extra_integer': parsetexi/extra.c:124:48: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] 124 | add_associated_info_key (e->extra_info, key, (ELEMENT *) value, extra_integer); | ^ --8<---------------cut here---------------end--------------->8--- This is with gcc 12.2.0 inside a MinGW64 shell with an up to date local repo. Best, Arash Footnotes: [1] https://lists.gnu.org/archive/html/bug-texinfo/2023-04/msg00007.html