[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Warning in lib/stdlib.c
From: |
Paul Eggert |
Subject: |
Re: Warning in lib/stdlib.c |
Date: |
Thu, 26 Dec 2024 16:38:31 -0800 |
User-agent: |
Mozilla Thunderbird |
On 2024-12-21 05:10, Eli Zaretskii wrote:
stdlib.c:20: warning: "_GL_STDLIB_INLINE" redefined
That's a violation of the C standard and so should be fixed.
The real culprit here is that Emacs config.h includes <stdlib.h>. It's
generally not a good idea for config.h to include headers like
<stdlib.h>, as that's brittle (as shown here).
I adjusted Gnulib to work around this particular problem and merged that
into Emacs. However, the culprit may cause other lurking issues so I
also installed the attached patches to Emacs so that config.h no longer
includes <stdlib.h>.
In <https://bugs.gnu.org/52455#21> I just now proposed removing
no-longer-working code that attempts to support unexec on macOS. That
would have simplified the attached patches.
It would also simplify things to remove the HYBRID_MALLOC code but I
don't know whether that stuff is still used.
0001-Let-Gnulib-deal-with-MB_CUR_MAX.patch
Description: Text Data
0002-Don-t-include-stdlib.h-from-conf_post.h.patch
Description: Text Data