As the output of that flag is usually parsed by scripts, having the keys translated is more of a curse than a blessing. This problem seems to have been known for about 15 years now: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14351
This patch simply removes the gettext _() macro invocations. --- gcc/gcc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gcc/gcc.c b/gcc/gcc.c index 4f57765b0..87eba2e98 100644 --- a/gcc/gcc.c +++ b/gcc/gcc.c @@ -7861,12 +7861,12 @@ driver::maybe_print_and_exit () const { if (print_search_dirs) { - printf (_("install: %s%s\n"), + printf ("install: %s%s\n", gcc_exec_prefix ? gcc_exec_prefix : standard_exec_prefix, gcc_exec_prefix ? "" : machine_suffix); - printf (_("programs: %s\n"), + printf ("programs: %s\n", build_search_list (&exec_prefixes, "", false, false)); - printf (_("libraries: %s\n"), + printf ("libraries: %s\n", build_search_list (&startfile_prefixes, "", false, true)); return (0); } -- 2.21.0
>From 396c29fba15dd21de596042eaaf66d1534c71cc7 Mon Sep 17 00:00:00 2001 From: PoroCYon <pcy@national.shitposting.agency> Date: Fri, 17 May 2019 23:34:58 +0200 Subject: [PATCH] Don't use localized strings for -print-search-dirs output As the output of that flag is usually parsed by scripts, having the keys translated is more of a curse than a blessing. This problem seems to have been known for about 15 years now: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14351 This patch simply removes the gettext _() macro invocations. --- gcc/gcc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gcc/gcc.c b/gcc/gcc.c index 4f57765b0..87eba2e98 100644 --- a/gcc/gcc.c +++ b/gcc/gcc.c @@ -7861,12 +7861,12 @@ driver::maybe_print_and_exit () const { if (print_search_dirs) { - printf (_("install: %s%s\n"), + printf ("install: %s%s\n", gcc_exec_prefix ? gcc_exec_prefix : standard_exec_prefix, gcc_exec_prefix ? "" : machine_suffix); - printf (_("programs: %s\n"), + printf ("programs: %s\n", build_search_list (&exec_prefixes, "", false, false)); - printf (_("libraries: %s\n"), + printf ("libraries: %s\n", build_search_list (&startfile_prefixes, "", false, true)); return (0); } -- 2.21.0