all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Pierre Langlois <pierre.langlois@gmx.com>
To: 59913@debbugs.gnu.org
Subject: bug#59913: [tentative PATCH] Failure to guix pull on aarch64 since recent make-linux-libre*
Date: Thu, 08 Dec 2022 23:59:11 +0000	[thread overview]
Message-ID: <877cz1xx59.fsf@gmx.com> (raw)
In-Reply-To: <87k031xxss.fsf@gmx.com>

[-- Attachment #1: Type: text/plain, Size: 2565 bytes --]


Pierre Langlois <pierre.langlois@gmx.com> writes:

(snip)

> What seems to happen is that the `kernel-config' function now receive an
> `arch' argument for an architecture that isn't actually supported by
> that kernel, as is the case for linux-libre@4.14.300.  And, correctly,
> the function should not expect to ever get such arch value to begin
> with, so we get a `(local-file #f)'.
>
> (define* (kernel-config arch #:key variant)
>   "Return a file-like object of the Linux-Libre build configuration file for
> ARCH and optionally VARIANT, or #f if there is no such configuration."

I pasted this bit of code but didn't read it properly, it specificaly
says that it should return #f if the config doesn't exist. I guess
that's now a bug? We could either fix the docstring and apply the fix I
proposed, or returning #f probably works.

>   (let* ((name (string-append (if variant (string-append variant "-") "")
>                               (if (string=? "i386" arch) "i686" arch) ".conf"))
>          (file (string-append "linux-libre/" name)))
>     (local-file (search-auxiliary-file file))))
>
> I think it's fair for that function expect the arch to be valid (why
> would you ask the config for an unsupported arch?).
>
> I think it should be possible to fix this by checking the arch is
> supported at the call site:
>
> [[End of PGP Signed Part]]
> From 77829140f14928e30cbe4e53c625be3ba2f5895f Mon Sep 17 00:00:00 2001
> From: Pierre Langlois <pierre.langlois@gmx.com>
> Date: Thu, 8 Dec 2022 23:41:40 +0000
> Subject: [PATCH] gnu: make-linux-libre*: Do not get config for unsupported
>  systems.
>
> * gnu/packages/linux.scm (make-linux-libre*)[phases] <configure>: Check
> arch is in supported-systems before calling configuration-file.
> ---
>  gnu/packages/linux.scm | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
> index 5ae6366593..87fc9fe94c 100644
> --- a/gnu/packages/linux.scm
> +++ b/gnu/packages/linux.scm
> @@ -983,6 +983,7 @@ (define* (make-linux-libre* version gnu-revision source supported-systems
>                                              (or (%current-target-system)
>                                                  (%current-system))))))
>                                  (and configuration-file arch
> +                                     (member arch supported-systems)
>                                       (configuration-file
>                                        arch
>                                        #:variant (version-major+minor version))))


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

  reply	other threads:[~2022-12-09  0:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-08 23:31 bug#59913: [tentative PATCH] Failure to guix pull on aarch64 since recent make-linux-libre* Pierre Langlois
2022-12-08 23:59 ` Pierre Langlois [this message]
2022-12-09  0:36 ` Pierre Langlois
2023-01-13 15:39 ` Maxim Cournoyer
     [not found] <167059225344.15591.17976801315617510996@vcs2.savannah.gnu.org>
2022-12-09 19:18 ` bug#59913: branch master updated: Revert "gnu: make-linux-libre*: Remove input labels." Pierre Langlois
2022-12-09 20:06   ` Maxim Cournoyer
2022-12-09 21:33     ` Pierre Langlois
2022-12-13  9:52       ` bug#59913: [tentative PATCH] Failure to guix pull on aarch64 since recent make-linux-libre* Ludovic Courtès
2023-01-13 21:04         ` Maxim Cournoyer

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

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

  git send-email \
    --in-reply-to=877cz1xx59.fsf@gmx.com \
    --to=pierre.langlois@gmx.com \
    --cc=59913@debbugs.gnu.org \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.