Re: Avoid gnulib redefinitions - MDA

2022-10-29 Thread Gavin Smith
On Sun, Oct 30, 2022 at 12:09:50AM +0200, Bruno Haible wrote: > Gavin Smith wrote: > > so it sounds like we are better off using #undef before > > including the Perl headers to avoid depending on undocumented > > functionalities. Thanks. > > Using #undef means to decline all corrections done by G

Re: Avoid gnulib redefinitions - MDA

2022-10-29 Thread Bruno Haible
Gavin Smith wrote: > so it sounds like we are better off using #undef before > including the Perl headers to avoid depending on undocumented > functionalities. Thanks. Using #undef means to decline all corrections done by Gnulib. These are documented in the manual. For example, for 'fdopen' [1] w

Re: Avoid gnulib redefinitions - MDA

2022-10-29 Thread Gavin Smith
On Sat, Oct 29, 2022 at 11:48:41PM +0200, Bruno Haible wrote: > > Should we use the variables with the GL_ prefix now and is this something > > we can rely on? Or should we simply #undef fdopen and the other symbols? > > The way to avoid a particular MDA symbol definition (GNULIB_MDA_FDOPEN=0 > b

Re: Avoid gnulib redefinitions - MDA

2022-10-29 Thread Bruno Haible
Hi Gavin, > Previously in the Texinfo project, we added variables to configure.ac to > stop the redefinition of "Microsoft deprecated aliases": > > https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg4.html > > For example, GNULIB_MDA_FDOPEN to stop the redefinition of 'fdopen'. > > Re

Re: Avoid gnulib redefinitions - MDA, free-posix

2022-10-29 Thread Gavin Smith
On Sat, Oct 29, 2022 at 09:58:25AM -0700, Paul Eggert wrote: > If it's just 'free', I might prefer the latter solution, to underline the > special case and to avoid even more complexity in gnulib-tool. Is that > something you could write? Here is a first attempt. I am not very familiar with the G

Re: Avoid gnulib redefinitions - MDA, free-posix

2022-10-29 Thread Paul Eggert
On 2022-10-29 06:36, Gavin Smith wrote: Here is one idea. When using a module like 'free-posix', if it is loaded as a dependency only, use the redefinition in Gnulib code only, but do not override symbols in user code. It would be as if there were two modules, say gl-free-posix and free-posix,

Avoid gnulib redefinitions - MDA, free-posix

2022-10-29 Thread Gavin Smith
Previously in the Texinfo project, we added variables to configure.ac to stop the redefinition of "Microsoft deprecated aliases": https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg4.html For example, GNULIB_MDA_FDOPEN to stop the redefinition of 'fdopen'. Recently, it was reported tha