Eric Blake wrote: > This patch implements a solution - move the translatable strings into a .c > file, so that they are owned by gnulib's POTFILES.in and the actual > [d]gettext > call occurs within the library. It also moves the testsuite out of xstrtol.c > into the tests directory, so that I could automate the tests with './gnulib- > tool --with-tests --test xstrtoimax xstrtoumax'.
Thanks for doing all this! It looks absolutely right. > +#include "gettext.h" > + > +#ifndef _ > +# define _(str) gettext (str) > +#endif You can remove this #ifndef/#endif pair. It comes from old ancient times, when it was not clear which include file should do what around gettext() and _(). Now it's clear for a long time: <libintl.h> defines gettext() as a function, unconditionally. gettext.h handles ENABLE_NLS but doesn't define _(). The .c file is responsible for defining _() itself. Bruno