summaryrefslogtreecommitdiff
path: root/guix/packages.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2023-12-11 17:29:41 +0100
committerLudovic Courtès <ludo@gnu.org>2024-06-17 22:52:22 +0200
commitb3d4e858a0b2a995bd18deee01d2748c93064046 (patch)
treed3384a58053ca1e730c6dac9565ebddb5c9e3118 /guix/packages.scm
parent4931bb169e285f7ba0b6a1d6ec35b9d0917ea350 (diff)
packages: Remove reference to ‘glibc-utf8-locales’ in ‘patch-and-repack’.
This is a followup to 1cebc334a77030c0c94955981652f4df7608c9e3. * guix/packages.scm (%standard-patch-inputs): Remove “locales” entry. (patch-and-repack): Remove ‘locales’ variable. [build]: Remove reference to ‘locales’. Use “C.UTF-8” unconditionally. Change-Id: I54219b232880e05534599fbba8738cc00fb5d568
Diffstat (limited to 'guix/packages.scm')
-rw-r--r--guix/packages.scm29
1 files changed, 12 insertions, 17 deletions
diff --git a/guix/packages.scm b/guix/packages.scm
index abe89cdb07..db2217af7c 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -899,13 +899,7 @@ identifiers. The result is inferred from the file names of patches."
("gzip" ,(ref '(gnu packages compression) 'gzip))
("lzip" ,(ref '(gnu packages compression) 'lzip))
("unzip" ,(ref '(gnu packages compression) 'unzip))
- ("patch" ,(ref '(gnu packages base) 'patch))
- ("locales"
- ,(parameterize ((%current-target-system #f)
- (%current-system system))
- (canonical
- ((module-ref (resolve-interface '(gnu packages base))
- 'libc-utf8-locales-for-target))))))))
+ ("patch" ,(ref '(gnu packages base) 'patch)))))
(define (default-guile)
"Return the default Guile package used to run the build code of
@@ -988,7 +982,6 @@ specifies modules in scope when evaluating SNIPPET."
(lzip (lookup-input "lzip"))
(xz (lookup-input "xz"))
(patch (lookup-input "patch"))
- (locales (lookup-input "locales"))
(comp (and=> (compressor source-file-name) lookup-input))
(patches (map instantiate-patch patches)))
(define build
@@ -1050,15 +1043,17 @@ specifies modules in scope when evaluating SNIPPET."
;; Encoding/decoding errors shouldn't be silent.
(fluid-set! %default-port-conversion-strategy 'error)
- (when #+locales
- ;; First of all, install a UTF-8 locale so that UTF-8 file names
- ;; are correctly interpreted. During bootstrap, LOCALES is #f.
- (setenv "LOCPATH"
- (string-append #+locales "/lib/locale/"
- #+(and locales
- (version-major+minor
- (package-version locales)))))
- (setlocale LC_ALL "en_US.utf8"))
+ ;; First of all, install a UTF-8 locale so that UTF-8 file names
+ ;; are correctly interpreted. During bootstrap, locales are
+ ;; missing.
+ (let ((locale "C.UTF-8"))
+ (catch 'system-error
+ (lambda ()
+ (setlocale LC_ALL locale))
+ (lambda args
+ (format (current-error-port)
+ "failed to install '~a' locale: ~a~%"
+ locale (system-error-errno args)))))
(setenv "PATH"
(string-append #+xz "/bin"