> 2019-12-18  Bruno Haible  <br...@clisp.org>
>       * modules/hard-locale (Depends-on): Remove strdup. Add setlocale-null.

This change has an effect on gettext's libgettextpo: Through this new
dependency chain
   hard-locale -> setlocale-null -> locale
there now is a gnulib-generated locale.h file in libgettextpo, and it
makes a '#define setlocale rpl_locale' definition visible, which in turn
cause the linking of libgettextpo to fail on mingw.

Ultimately this is caused by having two gnulib-tool invocations in the
scope of the same configure file; this is more fragile than having
them under different configure files. But anyway, there is an easy fix
in gnulib:


2019-12-24  Bruno Haible  <br...@clisp.org>

        localcharset: Avoid referencing rpl_setlocale on native Windows.
        * lib/localcharset.c (setlocale): Undefine.

diff --git a/lib/localcharset.c b/lib/localcharset.c
index ffc0d8f..5dd4429 100644
--- a/lib/localcharset.c
+++ b/lib/localcharset.c
@@ -58,6 +58,9 @@
 #elif defined WINDOWS_NATIVE
 # define WIN32_LEAN_AND_MEAN
 # include <windows.h>
+  /* For the use of setlocale() below, the Gnulib override in setlocale.c is
+     not needed; see the platform lists in setlocale_null.m4.  */
+# undef setlocale
 #endif
 #if defined OS2
 # define INCL_DOS


Reply via email to