unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Marius Bakke <mbakke@fastmail.com>
To: "Gábor Boskovits" <boskovits@gmail.com>, 29537@debbugs.gnu.org
Subject: bug#29537: Core updates broken
Date: Sun, 03 Dec 2017 15:13:02 +0100	[thread overview]
Message-ID: <87vahnzyq9.fsf@fastmail.com> (raw)
In-Reply-To: <CAE4v=phkRUpa5NnZ12Tp0nCBkwXieYN4oXW+FT8rA=q0bOL+kw@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 394 bytes --]

Gábor Boskovits <boskovits@gmail.com> writes:

> It seems, that we have a breakage in current core-updates. m4, gettext, and
> at least a few other packages fail to build.

Hello!

The problem is that the glibc version string is used a couple of places
to determine where locales are found.

The attached patch fixes it, though I'm not sure if it's the best
approach.  Thoughts?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-gnu-glibc-Don-t-use-full-version-string-in-locale-pa.patch --]
[-- Type: text/x-patch, Size: 4636 bytes --]

From 41677631be815d58c36052de7b54d297ad496ec1 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mbakke@fastmail.com>
Date: Sun, 3 Dec 2017 02:32:16 +0100
Subject: [PATCH] gnu: glibc: Don't use full version string in locale path.

This is a follow-up to commit ee3ebf1a357bd4eb36a2fa1790a7b549cffb305a.
Fixes <https://bugs.gnu.org/29537>.

* gnu/packages/base.scm (glibc/linux)[version]: Change to 2.26.91-gaaa2eb83b8.
[source](uri): Adjust accordingly.
[arguments]: Use VERSION-MAJOR+MINOR for locales path.
(glibc-locales, glibc-utf8-locales): Likewise.
* guix/profiles.scm (ca-certificate-bundle, profile-derivation): Likewise.
---
 gnu/packages/base.scm | 15 ++++++++++-----
 guix/profiles.scm     |  6 ++++--
 2 files changed, 14 insertions(+), 7 deletions(-)

diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm
index c8fd8624a..8190a38ed 100644
--- a/gnu/packages/base.scm
+++ b/gnu/packages/base.scm
@@ -523,11 +523,15 @@ store.")
    ;; archive can be generated by checking out the commit ID and running:
    ;; git archive --prefix=$(git describe)/ HEAD | xz -9 > $(git describe).tar.xz
    ;; See <https://bugs.gnu.org/29406> for details.
-   (version "2.26-91-gaaa2eb83b8")
+   ;;
+   ;; Note: Always use a dot after the minor version since various places rely
+   ;; on "version-major+minor" to determine where locales are found.
+   (version "2.26.91-gaaa2eb83b8")
    (source (origin
             (method url-fetch)
             (uri (string-append "https://alpha.gnu.org/gnu/guix/mirror/"
-                                "glibc-" version ".tar.xz"))
+                                "glibc-" (version-major+minor version) "-"
+                                (caddr (string-split version #\.)) ".tar.xz"))
             (sha256
              (base32
               "1zwz6d0x3ndd0hgqp17fx71miyjvn4dgkl1nzhaz3mbcqxzrprhk"))
@@ -585,7 +589,7 @@ store.")
             ;; `--localedir' is not honored, so work around it.
             ;; See <http://sourceware.org/ml/libc-alpha/2013-03/msg00093.html>.
             (string-append "libc_cv_complocaledir=/run/current-system/locale/"
-                           ,version)
+                           ,(version-major+minor version))
 
             (string-append "--with-headers="
                            (assoc-ref ,(if (%current-target-system)
@@ -955,7 +959,8 @@ the 'share/locale' sub-directory of this package.")
                    (list (string-append "libc_cv_complocaledir="
                                         (assoc-ref %outputs "out")
                                         "/lib/locale/"
-                                        ,(package-version glibc))))))))))
+                                        ,(version-major+minor
+                                          (package-version glibc)))))))))))
 
 (define-public glibc-utf8-locales
   (package
@@ -973,7 +978,7 @@ the 'share/locale' sub-directory of this package.")
                           (gzip      (assoc-ref %build-inputs "gzip"))
                           (out       (assoc-ref %outputs "out"))
                           (localedir (string-append out "/lib/locale/"
-                                                    ,version)))
+                                                    ,(version-major+minor version))))
                      ;; 'localedef' needs 'gzip'.
                      (setenv "PATH" (string-append libc "/bin:" gzip "/bin"))
 
diff --git a/guix/profiles.scm b/guix/profiles.scm
index 0eb99f40d..51c330b32 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -812,7 +812,8 @@ MANIFEST.  Single-file bundles are required by programs such as Git and Lynx."
           ;; install a UTF-8 locale.
           (setenv "LOCPATH"
                   (string-append #+glibc-utf8-locales "/lib/locale/"
-                                 #+(package-version glibc-utf8-locales)))
+                                 #+(version-major+minor
+                                    (package-version glibc-utf8-locales))))
           (setlocale LC_ALL "en_US.utf8")
 
           (match (append-map ca-files '#$(manifest-inputs manifest))
@@ -1256,7 +1257,8 @@ are cross-built for TARGET."
       #~(begin
           (setenv "LOCPATH"
                   #$(file-append glibc-utf8-locales "/lib/locale/"
-                                 (package-version glibc-utf8-locales)))
+                                 (version-major+minor
+                                  (package-version glibc-utf8-locales))))
           (setlocale LC_ALL "en_US.utf8")))
 
     (define builder
-- 
2.15.1


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

  parent reply	other threads:[~2017-12-03 14:14 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-02 20:12 bug#29537: Core updates broken Gábor Boskovits
     [not found] ` <handler.29537.B.151224558627462.ack@debbugs.gnu.org>
2017-12-02 21:32   ` bug#29537: Acknowledgement (Core updates broken) Gábor Boskovits
2017-12-03  5:53     ` Gábor Boskovits
2017-12-03  8:41 ` bug#29537: Core updates broken Gábor Boskovits
2017-12-03  8:45   ` Gábor Boskovits
2017-12-03  8:57     ` Gábor Boskovits
2017-12-03 14:13 ` Marius Bakke [this message]
2017-12-03 14:51   ` Marius Bakke
2017-12-03 15:23     ` Marius Bakke
2017-12-03 15:32   ` Gábor Boskovits
2017-12-03 18:15   ` Ricardo Wurmus
2017-12-03 18:43     ` Marius Bakke
2017-12-03 19:04       ` Gábor Boskovits
2017-12-04  9:28       ` Ludovic Courtès
2017-12-04  9:29   ` Ludovic Courtès
2017-12-04 12:54     ` Marius Bakke
2017-12-05 17:05       ` Ludovic Courtès
2017-12-05 22:59         ` Marius Bakke
2017-12-06  8:01           ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87vahnzyq9.fsf@fastmail.com \
    --to=mbakke@fastmail.com \
    --cc=29537@debbugs.gnu.org \
    --cc=boskovits@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).