guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

03/03: vm: Build ISOs and VM images in a UTF-8 environment.


From: guix-commits
Subject: 03/03: vm: Build ISOs and VM images in a UTF-8 environment.
Date: Wed, 1 May 2019 15:20:00 -0400 (EDT)

civodul pushed a commit to branch version-1.0.0
in repository guix.

commit 9c941364bfc0120e3ab5c5c4cc71a9a302d59a2b
Author: Ludovic Courtès <address@hidden>
Date:   Wed May 1 21:11:22 2019 +0200

    vm: Build ISOs and VM images in a UTF-8 environment.
    
    Fixes a bug whereby building an image containing non-ASCII file names
    would fail due to improper decoding of file names.
    
    * gnu/system/vm.scm (iso9660-image, qemu-image): Set GUIX_LOCPATH and
    call 'setlocale' in the build environment.
---
 gnu/system/vm.scm | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm
index 92b03b0..124abd0 100644
--- a/gnu/system/vm.scm
+++ b/gnu/system/vm.scm
@@ -283,6 +283,11 @@ INPUTS is a list of inputs (as for packages)."
 
            (sql-schema #$schema)
 
+           ;; Allow non-ASCII file names--e.g., 'nss-certs'--to be decoded.
+           (setenv "GUIX_LOCPATH"
+                   #+(file-append glibc-utf8-locales "/lib/locale"))
+           (setlocale LC_ALL "en_US.utf8")
+
            (let ((inputs
                   '#$(append (list qemu parted e2fsprogs dosfstools xorriso)
                              (map canonical-package
@@ -379,6 +384,11 @@ the image."
 
            (sql-schema #$schema)
 
+           ;; Allow non-ASCII file names--e.g., 'nss-certs'--to be decoded.
+           (setenv "GUIX_LOCPATH"
+                   #+(file-append glibc-utf8-locales "/lib/locale"))
+           (setlocale LC_ALL "en_US.utf8")
+
            (let ((inputs
                   '#$(append (list qemu parted e2fsprogs dosfstools)
                              (map canonical-package



reply via email to

[Prev in Thread] Current Thread [Next in Thread]