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 | c988f6425acbd9765c55490c45d61f7531d5d83b (diff) | |
parent | 64f982b8a791a8e9e612a103d05e5f01a08fce0f (diff) | |
download | git-92034a9cd5e71cf686ef66029433bdaba75027b0.tar.gz |
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, ""); |