diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2019-05-01 21:11:22 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2019-05-01 21:11:22 +0200 |
| commit | 9c941364bfc0120e3ab5c5c4cc71a9a302d59a2b (patch) | |
| tree | 577c20dc468cd1dee43c626d690a7471445ba7ea /gnu/system | |
| parent | 17acc215bfee2d5ee487add8fc8917fbf9d61132 (diff) | |
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.
Diffstat (limited to 'gnu/system')
| -rw-r--r-- | gnu/system/vm.scm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm index 92b03b01ad2..124abd0fc9e 100644 --- a/gnu/system/vm.scm +++ b/gnu/system/vm.scm | |||
| @@ -283,6 +283,11 @@ INPUTS is a list of inputs (as for packages)." | |||
| 283 | 283 | ||
| 284 | (sql-schema #$schema) | 284 | (sql-schema #$schema) |
| 285 | 285 | ||
| 286 | ;; Allow non-ASCII file names--e.g., 'nss-certs'--to be decoded. | ||
| 287 | (setenv "GUIX_LOCPATH" | ||
| 288 | #+(file-append glibc-utf8-locales "/lib/locale")) | ||
| 289 | (setlocale LC_ALL "en_US.utf8") | ||
| 290 | |||
| 286 | (let ((inputs | 291 | (let ((inputs |
| 287 | '#$(append (list qemu parted e2fsprogs dosfstools xorriso) | 292 | '#$(append (list qemu parted e2fsprogs dosfstools xorriso) |
| 288 | (map canonical-package | 293 | (map canonical-package |
| @@ -379,6 +384,11 @@ the image." | |||
| 379 | 384 | ||
| 380 | (sql-schema #$schema) | 385 | (sql-schema #$schema) |
| 381 | 386 | ||
| 387 | ;; Allow non-ASCII file names--e.g., 'nss-certs'--to be decoded. | ||
| 388 | (setenv "GUIX_LOCPATH" | ||
| 389 | #+(file-append glibc-utf8-locales "/lib/locale")) | ||
| 390 | (setlocale LC_ALL "en_US.utf8") | ||
| 391 | |||
| 382 | (let ((inputs | 392 | (let ((inputs |
| 383 | '#$(append (list qemu parted e2fsprogs dosfstools) | 393 | '#$(append (list qemu parted e2fsprogs dosfstools) |
| 384 | (map canonical-package | 394 | (map canonical-package |
