diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-05-08 15:59:17 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-05-08 15:59:17 +0900 |
commit | 92034a9cd5e71cf686ef66029433bdaba75027b0 (patch) | |
tree | 48a2d6429c993e75dc0f4ab76268509dcc82de5f /gettext.c | |
parent | Merge branch 'ab/simplify-perl-makefile' (diff) | |
parent | Makefile: quote $INSTLIBDIR when passing it to sed (diff) | |
download | tgif-92034a9cd5e71cf686ef66029433bdaba75027b0.tar.xz |
Merge branch 'dj/runtime-prefix'
A build-time option has been added to allow Git to be told to refer
to its associated files relative to the main binary, in the same
way that has been possible on Windows for quite some time, for
Linux, BSDs and Darwin.
* dj/runtime-prefix:
Makefile: quote $INSTLIBDIR when passing it to sed
Makefile: remove unused @@PERLLIBDIR@@ substitution variable
mingw/msvc: use the new-style RUNTIME_PREFIX helper
exec_cmd: provide a new-style RUNTIME_PREFIX helper for Windows
exec_cmd: RUNTIME_PREFIX on some POSIX systems
Makefile: add Perl runtime prefix support
Makefile: generate Perl header from template file
Diffstat (limited to 'gettext.c')
-rw-r--r-- | gettext.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -2,7 +2,8 @@ * Copyright (c) 2010 Ævar Arnfjörð Bjarmason */ -#include "git-compat-util.h" +#include "cache.h" +#include "exec-cmd.h" #include "gettext.h" #include "strbuf.h" #include "utf8.h" @@ -157,10 +158,11 @@ static void init_gettext_charset(const char *domain) void git_setup_gettext(void) { - const char *podir = getenv("GIT_TEXTDOMAINDIR"); + const char *podir = getenv(GIT_TEXT_DOMAIN_DIR_ENVIRONMENT); if (!podir) - podir = GIT_LOCALE_PATH; + podir = system_path(GIT_LOCALE_PATH); + bindtextdomain("git", podir); setlocale(LC_MESSAGES, ""); setlocale(LC_TIME, ""); |