mirror of
https://github.com/mirror/wget.git
synced 2024-12-25 20:30:37 +08:00
Use a separate domain for translating gnulib
Use the --po-domain option to gnulib-tool to create a new textdomain that can be used by gnulib files for translations. This way, we don't have to maintain the list of all files that require translations in gnulib. * bootstrap.conf: Use --po-domain and --po-base options to create a separate base for gnulib translations * src/main.c(i18n_initialize): Call bindtextdomain on wget-gnulib to include those translations as well * Makefile.am: Add new directory gnulib_po to SUBDIRS * configure.ac: Generate gnulib_po/Makefile.in * lib/Makefile.am: Set AM_CPPFLAGS to empty since gnulib.mk expects it to be set
This commit is contained in:
parent
8d68a6307b
commit
a11bfc2d4e
@ -40,7 +40,7 @@ distuninstallcheck_listfiles = find . -type f | \
|
||||
ACLOCAL_AMFLAGS = -I m4
|
||||
|
||||
# subdirectories in the distribution
|
||||
SUBDIRS = lib src doc po util fuzz tests testenv
|
||||
SUBDIRS = lib src doc po gnulib_po util fuzz tests testenv
|
||||
|
||||
EXTRA_DIST = MAILING-LIST \
|
||||
msdos/config.h msdos/Makefile.DJ \
|
||||
|
@ -20,7 +20,7 @@
|
||||
source_base=lib
|
||||
tests_base=lib/tests
|
||||
gnulib_name=libgnu
|
||||
gnulib_tool_option_extras="--makefile-name=gnulib.mk"
|
||||
gnulib_tool_option_extras="--makefile-name=gnulib.mk --po-base=gnulib_po --po-domain=wget"
|
||||
use_libtool=0
|
||||
checkout_only_file=
|
||||
|
||||
|
@ -996,8 +996,8 @@ dnl
|
||||
dnl Create output
|
||||
dnl
|
||||
AC_CONFIG_FILES([Makefile src/Makefile doc/Makefile util/Makefile
|
||||
po/Makefile.in tests/Makefile fuzz/Makefile
|
||||
lib/Makefile testenv/Makefile
|
||||
po/Makefile.in gnulib_po/Makefile.in tests/Makefile
|
||||
fuzz/Makefile lib/Makefile testenv/Makefile
|
||||
tests/certs/interca.conf tests/certs/rootca.conf])
|
||||
AC_CONFIG_HEADERS([src/config.h])
|
||||
AC_OUTPUT
|
||||
|
@ -9,5 +9,6 @@ noinst_LIBRARIES =
|
||||
MAINTAINERCLEANFILES =
|
||||
|
||||
AM_CFLAGS = $(GNULIB_WARN_CFLAGS) $(WERROR_CFLAGS)
|
||||
AM_CPPFLAGS =
|
||||
|
||||
include gnulib.mk
|
||||
|
@ -153,6 +153,7 @@ i18n_initialize (void)
|
||||
setlocale (LC_ALL, "");
|
||||
/* Set the text message domain. */
|
||||
bindtextdomain ("wget", LOCALEDIR);
|
||||
bindtextdomain ("wget-gnulib", LOCALEDIR);
|
||||
textdomain ("wget");
|
||||
#elif defined WINDOWS
|
||||
char MBCP[16] = "";
|
||||
|
Loading…
Reference in New Issue
Block a user