From: Bruno Haible Date: Mon, 23 Jun 2025 19:20:13 +0000 (+0200) Subject: gettext-runtime: Fix --help output in relocatable installations. X-Git-Tag: v0.26~70 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d1d57e158949fcfc4105d15b1e65518d46463e2;p=thirdparty%2Fgettext.git gettext-runtime: Fix --help output in relocatable installations. * gettext-runtime/src/gettext.c (usage): Show the relocated LOCALEDIR. * gettext-runtime/src/ngettext.c (usage): Likewise. --- diff --git a/gettext-runtime/src/gettext.c b/gettext-runtime/src/gettext.c index 51fce993b..6ae28c8ea 100644 --- a/gettext-runtime/src/gettext.c +++ b/gettext-runtime/src/gettext.c @@ -290,7 +290,7 @@ When used with the -s option the program behaves like the 'echo' command.\n\ But it does not simply copy its arguments to stdout. Instead those messages\n\ found in the selected catalog are translated.\n\ Standard search directory: %s\n"), - getenv ("IN_HELP2MAN") == NULL ? LOCALEDIR : "@localedir@"); + getenv ("IN_HELP2MAN") == NULL ? relocate (LOCALEDIR) : "@localedir@"); printf ("\n"); /* TRANSLATORS: The first placeholder is the web address of the Savannah project of this package. The second placeholder is the bug-reporting diff --git a/gettext-runtime/src/ngettext.c b/gettext-runtime/src/ngettext.c index 4b6b25bee..737495e62 100644 --- a/gettext-runtime/src/ngettext.c +++ b/gettext-runtime/src/ngettext.c @@ -256,7 +256,7 @@ environment variable TEXTDOMAIN. If the message catalog is not found in the\n\ regular directory, another location can be specified with the environment\n\ variable TEXTDOMAINDIR.\n\ Standard search directory: %s\n"), - getenv ("IN_HELP2MAN") == NULL ? LOCALEDIR : "@localedir@"); + getenv ("IN_HELP2MAN") == NULL ? relocate (LOCALEDIR) : "@localedir@"); printf ("\n"); /* TRANSLATORS: The first placeholder is the web address of the Savannah project of this package. The second placeholder is the bug-reporting