From 191bf464071d7cd21095b9f1d119c05fd8306493 Mon Sep 17 00:00:00 2001 From: Zack Weinberg Date: Fri, 19 Oct 2001 15:17:39 +0000 Subject: aclocal.m4 (AM_WITH_NLS): AC_DEFINE HAVE_LIBINTL_H and USE_INCLUDED_LIBINTL when appropriate. * aclocal.m4 (AM_WITH_NLS): AC_DEFINE HAVE_LIBINTL_H and USE_INCLUDED_LIBINTL when appropriate. * configure, config.in: Regenerate. * Makefile.in (datadir): Set to @datadir@. (intl.o): Also depend on $(CONFIG_H) and system.h. * intl.c: Factor out common gettext initialization sequence. (gcc_init_libintl): New function. * intl.h: Include intl/libgnuintl.h if USE_INCLUDED_LIBINTL; otherwise include libintl.h if HAVE_LIBINTL_H; otherwise turn off NLS. Add multiple include guard. No need to #ifdef-guard an #undef. Prototype gcc_init_libintl here. * collect2.c (main), cppmain.c (general_init), gcc.c (main), gcov.c (main), protoize.c (main), toplev.c (toplev_main): Use gcc_init_libintl. intl: * Makefile.in: Don't copy libgnuintl.h anywhere. From-SVN: r46348 --- gcc/collect2.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'gcc/collect2.c') diff --git a/gcc/collect2.c b/gcc/collect2.c index c8fafc3..c850608 100644 --- a/gcc/collect2.c +++ b/gcc/collect2.c @@ -873,18 +873,7 @@ main (argc, argv) signal (SIGCHLD, SIG_DFL); #endif -/* LC_CTYPE determines the character set used by the terminal so it has be set - to output messages correctly. */ - -#ifdef HAVE_LC_MESSAGES - setlocale (LC_CTYPE, ""); - setlocale (LC_MESSAGES, ""); -#else - setlocale (LC_ALL, ""); -#endif - - (void) bindtextdomain (PACKAGE, localedir); - (void) textdomain (PACKAGE); + gcc_init_libintl (); /* Do not invoke xcalloc before this point, since locale needs to be set first, in case a diagnostic is issued. */ -- cgit v1.1