[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
21/155: profiles: Build profiles in a UTF-8 locale.
From: |
John Darrington |
Subject: |
21/155: profiles: Build profiles in a UTF-8 locale. |
Date: |
Wed, 21 Dec 2016 20:48:30 +0000 (UTC) |
jmd pushed a commit to branch wip-installer
in repository guix.
commit 827a84a75872831dcef07cd2cdfb51da34bc3627
Author: Ludovic Courtès <address@hidden>
Date: Fri Dec 16 18:01:08 2016 +0100
profiles: Build profiles in a UTF-8 locale.
Fixes <http://bugs.gnu.org/25213>.
Reported by Christopher Baines <address@hidden>.
* guix/profiles.scm (profile-derivation)[glibc-utf8-locales]: New
variable.
[builder]: Use it to set 'LOCPATH'.
---
guix/profiles.scm | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/guix/profiles.scm b/guix/profiles.scm
index 0b317ef..82d8b33 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -939,6 +939,10 @@ the monadic procedures listed in HOOKS--such as an Info
'dir' file, etc."
extras)
(manifest-inputs manifest)))
+ (define glibc-utf8-locales ;lazy reference
+ (module-ref (resolve-interface '(gnu packages base))
+ 'glibc-utf8-locales))
+
(define builder
(with-imported-modules '((guix build profiles)
(guix build union)
@@ -953,6 +957,13 @@ the monadic procedures listed in HOOKS--such as an Info
'dir' file, etc."
(setvbuf (current-output-port) _IOLBF)
(setvbuf (current-error-port) _IOLBF)
+ ;; Some file names (e.g., in 'nss-certs') are UTF-8 encoded so
+ ;; install a UTF-8 locale.
+ (setenv "LOCPATH"
+ (string-append #+glibc-utf8-locales "/lib/locale/"
+ #+(package-version glibc-utf8-locales)))
+ (setlocale LC_ALL "en_US.utf8")
+
(define search-paths
;; Search paths of MANIFEST's packages, converted back to their
;; record form.
- 03/155: installer: Remove obsolete procedures/variables, (continued)
- 03/155: installer: Remove obsolete procedures/variables, John Darrington, 2016/12/21
- 04/155: installer: Fix broken timezone menu., John Darrington, 2016/12/21
- 05/155: installer: fix warning in usage of "format"., John Darrington, 2016/12/21
- 08/155: installer: Add IETF contraints for hostname in entry form., John Darrington, 2016/12/21
- 07/155: installer: Use ice-9 match., John Darrington, 2016/12/21
- 06/155: installer: use ice-9 format everywhere., John Darrington, 2016/12/21
- 19/155: refresh: Make dependency on (guix import crates) weak., John Darrington, 2016/12/21
- 16/155: gnu: grub: Add dependency on efibootmgr., John Darrington, 2016/12/21
- 20/155: download: Protect against dangling symlinks in $SSL_CERT_DIR., John Darrington, 2016/12/21
- 11/155: installer: Change "interfaces" from a variable to a procedure., John Darrington, 2016/12/21
- 21/155: profiles: Build profiles in a UTF-8 locale.,
John Darrington <=
- 09/155: installer: Use a record instead of a list to contain tasks., John Darrington, 2016/12/21
- 13/155: installer: Use call-with-temporary-output-file., John Darrington, 2016/12/21
- 29/155: gnu: Add fatfsck-static., John Darrington, 2016/12/21
- 24/155: build: assert-no-store-file-names: Ignore ChangeLog., John Darrington, 2016/12/21
- 18/155: install: Add dosfstools., John Darrington, 2016/12/21
- 23/155: gnu: libupnp: Fix CVE-2016-8863., John Darrington, 2016/12/21
- 25/155: gnu: acme-client: Provide path to certificates., John Darrington, 2016/12/21
- 34/155: import cran: Do not use "or later" licenses by default., John Darrington, 2016/12/21
- 36/155: import cran: Handle BSD licenses with LICENSE file., John Darrington, 2016/12/21
- 15/155: doc: "Nar" now means "normalized archive"., John Darrington, 2016/12/21