Update e-mail for Kei Kebreau.
[jackhill/guix/guix.git] / gnu / packages / patches / glibc-locales.patch
CommitLineData
aee6180c
LC
1This patch allows us to use glibc's build system to build locales
2in a package separate from glibc.
3
4 1. Use 'localedef' from $PATH since we are not rebuilding it.
5 2. Use '--no-archive' to avoid building the big locale archive, and
6 because the already-built 'localedef' would want to write it
7 to '/run/current-system/locale', which is not possible.
85860fdf
SB
8 3. Pass $(inst_complocaledir)/$$locale to install files in the right
9 place, and because otherwise, 'localedef' fails with:
aee6180c
LC
10 "cannot write output files to `(null)'".
11
e2aace76
LC
12--- glibc-2.22/localedata/Makefile 1970-01-01 01:00:00.000000000 +0100
13+++ glibc-2.22/localedata/Makefile 2015-09-25 14:18:34.698941752 +0200
14@@ -195,7 +195,7 @@ INSTALL-SUPPORTED-LOCALES=$(addprefix in
aee6180c
LC
15
16 # Sometimes the whole collection of locale files should be installed.
17 LOCALEDEF=I18NPATH=. GCONV_PATH=$(common-objpfx)iconvdata LC_ALL=C \
18-$(rtld-prefix) $(common-objpfx)locale/localedef
19+ localedef --no-archive
20 install-locales: $(INSTALL-SUPPORTED-LOCALES)
21
22 install-locales-dir:
e2aace76 23@@ -212,7 +212,7 @@ $(INSTALL-SUPPORTED-LOCALES): install-lo
aee6180c
LC
24 input=`echo $$locale | sed 's/\([^.]*\)[^@]*\(.*\)/\1\2/'`; \
25 $(LOCALEDEF) --alias-file=../intl/locale.alias \
26 -i locales/$$input -c -f charmaps/$$charset \
e2aace76 27- $(addprefix --prefix=,$(install_root)) $$locale \
85860fdf 28+ $(addprefix --prefix=,$(install_root)) $(inst_complocaledir)/$$locale \
e2aace76 29 && echo ' done'; \
aee6180c
LC
30
31 tst-setlocale-ENV = LC_ALL=ja_JP.EUC-JP