GNU bug report logs

#48314 [PATCH] Install guix system on Raspberry Pi

PackageSource(s)Maintainer(s)
guix-patches PTS Buildd Popcon
Full log

Message #221 received at 48314@debbugs.gnu.org (full text, mbox, reply):

Received: (at 48314) by debbugs.gnu.org; 1 Dec 2022 18:01:48 +0000
From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 01 13:01:48 2022
Received: from localhost ([127.0.0.1]:41107 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces@debbugs.gnu.org>)
	id 1p0nsZ-0000An-GL
	for submit@debbugs.gnu.org; Thu, 01 Dec 2022 13:01:47 -0500
Received: from mail-qv1-f51.google.com ([209.85.219.51]:41567)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maxim.cournoyer@gmail.com>) id 1p0nsW-0000Ae-RR
 for 48314@debbugs.gnu.org; Thu, 01 Dec 2022 13:01:45 -0500
Received: by mail-qv1-f51.google.com with SMTP id d13so1847417qvj.8
 for <48314@debbugs.gnu.org>; Thu, 01 Dec 2022 10:01:44 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=content-transfer-encoding:mime-version:user-agent:message-id
 :in-reply-to:date:references:subject:cc:to:from:from:to:cc:subject
 :date:message-id:reply-to;
 bh=wCf3/Lkjz2SrBOnIe03NATRnl2NkNtvOep2TnJ1WuaM=;
 b=U4f9aOoqTzCVJEF/41nv7/u4IMdJAQ8D0NPHAlA3I9p//35LkY9UqDCM3dtBGbuMAc
 fh/obwdgRLGnNve2fK5DWcKePE9Hg0ipwO3sUwu46TeTqxWB6XEb2AdHqUA/CEECQN8m
 PGqfBSC5TWacHY/XBnNid+YtvszcR0nHfOyncA76oiWIwq2vGZOE22TVARTXxmDd8mDG
 kq4KArVDbpefq0jLTUqHE2q6p0pAjA/WeKlkUaygbryc2+iD0gEhpXP2dLyaYAz6v/sM
 Od+3KDuB1F2Y2tdk3hQUSXNGcEjH7CjJZgAE1oEFGEri7s1Nlf92SOw2HpsxKloUUevx
 hWPw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=content-transfer-encoding:mime-version:user-agent:message-id
 :in-reply-to:date:references:subject:cc:to:from:x-gm-message-state
 :from:to:cc:subject:date:message-id:reply-to;
 bh=wCf3/Lkjz2SrBOnIe03NATRnl2NkNtvOep2TnJ1WuaM=;
 b=fhQ+IQbbpx5kqxmjfk13BUXXdvhbG1tbqzE4a36p6UQsRCG+517hw52jokUS+KbdlS
 Jzh52V6i0XM4hOZXyu/HbCHDtC9mYFN3AfIjGSB3uzpoFpZUWmZ/go7qHcOt794XCMH7
 p8T+iK4qpCfztNT0lOlr6J2WmHrjpYE6NZiBBH3dMyJ5wu5WSAjMfGiTwfnlSgTGIgfX
 279GYrb0bTG5bZ8Mfp5vXuhZeAw2yN72CJqvwZAFzRN3C93dGQoAb0c64tVzImm40Zv9
 q2hTkPJiy4LXXeAHqCHv7FiFvwalf3cIUBPjVYgAZheedwhVTxmJrI1tl3pn8GZZMmxc
 CGeg==
X-Gm-Message-State: ANoB5pn4gyj9d4t0x+KKPk0b/CQkDgmzh25VoO59pQVmh03JTUqGQKS1
 R0R8d6DeCWEhkiM0MGdBPds=
X-Google-Smtp-Source: AA0mqf40pRJIj0aUJ9l9Hz6dwVyJmPHIrsL55B40Pd91u/Xux86Ezie6DZXQYB4aypqPC0Oy+7nhzA==
X-Received: by 2002:a05:6214:3513:b0:4bb:ddaf:b9e5 with SMTP id
 nk19-20020a056214351300b004bbddafb9e5mr43366907qvb.52.1669917698801; 
 Thu, 01 Dec 2022 10:01:38 -0800 (PST)
Received: from hurd ([2607:fad8:4:3::1001]) by smtp.gmail.com with ESMTPSA id
 bs42-20020a05620a472a00b006b61b2cb1d2sm3918893qkb.46.2022.12.01.10.01.36
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Thu, 01 Dec 2022 10:01:37 -0800 (PST)
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
To: Stefan <stefan-guix@vodafonemail.de>
Subject: Re: bug#48314: [PATCH] Install guix system on Raspberry Pi
References: <xjr0W3rUn2GueNJb8lTEyJfyt5ECWhhz6FymZT-rQmOFC_H7woQjM_l9TFaza-5Sruwkn8XgBv5LTcR-gyKkSzwC5VU078zVqqDkSP7Sn2U=@protonmail.com>
 <CA07C169-EBA6-46B5-8EE1-FE7BDB9F00EE@vodafonemail.de>
 <EEFB37EE-F9AC-44BE-B5BB-77D34A160757@vodafonemail.de>
 <2IN6BsQe0_wSC9iwf7LHT5LUk7wXLVXytkDtcg7RIYByyYFTsuC9BZPR_wdv4eDMncsZfy17h7z9jIRRSC6kfV2odXkt0hp4Lilq5sGYdVo=@protonmail.com>
 <CA1AEB2D-9941-4E53-A4D5-273E17626AD9@vodafonemail.de>
 <204332DD-AA02-4A31-9B48-FB3FAB9BD8F3@vodafonemail.de>
Date: Thu, 01 Dec 2022 13:01:36 -0500
In-Reply-To: <204332DD-AA02-4A31-9B48-FB3FAB9BD8F3@vodafonemail.de> (Stefan's
 message of "Thu, 22 Sep 2022 18:18:59 +0200")
Message-ID: <87edtjhukf.fsf_-_@gmail.com>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 48314
Cc: Vagrant Cascadian <vagrant@debian.org>,
 Danny Milosavljevic <dannym@scratchpost.org>,
 Ludovic Courtès <ludo@gnu.org>,
 phodina <phodina@protonmail.com>, 48314@debbugs.gnu.org
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit@debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request@debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org>
X-Spam-Score: -1.0 (-)
Hi,

> gnu: linux: New function to modify the configuration of a Linux kernel.
>
> From: Stefan <stefan-guix@vodafonemail.de>
>
> * gnu/packages/linux.scm (system->linux-srcarch): New function to return the
> relevent folder name below arch/ in the Linux source code.
> (modify-linux): New function to make a customized Linux package inherited
> from another Linux package, which will be build with an own defconfig or
> configuration changes.
> (make-defconfig): Function to get a defconfig from an uri.

I've renamed it to customize-linux, and streamlined the commit message
like so:

--8<---------------cut here---------------start------------->8---
gnu: linux: Add a 'customize-linux' procedure.

* gnu/packages/linux.scm (linux-srcarch): New procedure.
(customize-linux): Likewise.
(make-defconfig): Procedure to retrieve a defconfig from an URI.

Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Modified-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
--8<---------------cut here---------------end--------------->8---

Otherwise, I've made the following changes (exporting procedures
explicitly from the modules):

--8<---------------cut here---------------start------------->8---
1 file changed, 25 insertions(+), 25 deletions(-)
gnu/packages/linux.scm | 50 +++++++++++++++++++++++++-------------------------

modified   gnu/packages/linux.scm
@@ -190,19 +190,19 @@ (define-module (gnu packages linux)
   #:use-module (srfi srfi-2)
   #:use-module (srfi srfi-26)
   #:use-module (ice-9 match)
-  #:use-module (ice-9 optargs)
-  #:use-module (ice-9 regex))
+  #:use-module (ice-9 regex)
+  #:export (customize-linux))
 
-(define-public (linux-srcarch)
+(define (linux-srcarch)
   "Return the linux SRCARCH name, which is set in the toplevel Makefile of
-Linux and denotes the architecture specific directory name below arch/ in its
+Linux and denotes the architecture-specific directory name below arch/ in its
 source code.  Some few architectures share a common folder.  It resembles the
 definition of SRCARCH based on ARCH in the Makefile and may be used to place a
 defconfig file in the proper path."
   (let ((linux-arch (platform-linux-architecture
-                      (lookup-platform-by-target-or-system
-                        (or (%current-target-system)
-                            (%current-system))))))
+                     (lookup-platform-by-target-or-system
+                      (or (%current-target-system)
+                          (%current-system))))))
     (match linux-arch
       ("i386"    "x86")
       ("x86_64"  "x86")
@@ -213,7 +213,7 @@ (define-public (linux-srcarch)
 
 (define-public (system->defconfig system)
   "Some systems (notably powerpc-linux) require a special target for kernel
-defconfig.  Return the appropriate make target if applicable, otherwise return
+defconfig.  Return the appropriate Make target if applicable, otherwise return
 \"defconfig\"."
   (cond ((string-prefix? "powerpc-" system) "pmac32_defconfig")
         ((string-prefix? "powerpc64-" system) "ppc64_defconfig")
@@ -1271,19 +1271,19 @@ (define-public linux-libre-with-bpf
 ;;; Linux kernel customization functions.
 ;;;
 
-(define*-public (modify-linux #:key name
-                                    (linux linux-libre)
-                                    source
-                                    defconfig
-                                    (configs "")
-                                    extra-version)
-  "Make a Linux package NAME as a modification of another LINUX package.
+(define* (customize-linux #:key name
+                          (linux linux-libre)
+                          source
+                          defconfig
+                          (configs "")
+                          extra-version)
+  "Make a customized Linux package NAME derived from the LINUX package.
 
 If NAME is not given, then it defaults to the same name as the LINUX package.
 
 Unless SOURCE is given the source of LINUX is used.
 
-A DEFCONFIG file to be used can be given as an origin, as a file like object
+A DEFCONFIG file to be used can be given as an origin, as a file-like object
 (file-append, local-file etc.), or as a string with the name of a defconfig file
 available in the Linux sources.  If DEFCONFIG is not given, then a defconfig
 file will be saved from the LINUX package configuration.
@@ -1295,11 +1295,11 @@ (define*-public (modify-linux #:key name
 defconfig syntax has to be used, but there is a special extension to ease the
 removal of configurations.  Comment lines are supported as well.
 
-Here is an explaining usage example:
+Here is an example:
 
   '(;; This string defines the version tail in 'uname -r'.
     \"CONFIG_LOCALVERSION=\\\"-handcrafted\\\"
-    ;; This '# CONFIG_… is not set' syntax has to match exactly!
+    ;; This '# CONFIG_... is not set' syntax has to match exactly!
     \"# CONFIG_BOOT_CONFIG is not set\"
     \"CONFIG_NFS_SWAP=y\"
     ;; This is a multiline configuration:
@@ -1339,13 +1339,13 @@ (define*-public (modify-linux #:key name
                   #$(cond
                      ((not defconfig)
                       #~(begin
-                         ;; Call the original 'configure phase.
-                         (apply (assoc-ref #$phases 'configure) arguments)
-                         ;; Save a defconfig file.
-                         (invoke "make" "savedefconfig")
-                         ;; Move the saved defconfig to the proper location.
-                         (rename-file "defconfig"
-                                      guix_defconfig)))
+                          ;; Call the original 'configure phase.
+                          (apply (assoc-ref #$phases 'configure) arguments)
+                          ;; Save a defconfig file.
+                          (invoke "make" "savedefconfig")
+                          ;; Move the saved defconfig to the proper location.
+                          (rename-file "defconfig"
+                                       guix_defconfig)))
                      ((string? defconfig)
                       ;; Use another existing defconfig from the Linux sources.
                       #~(rename-file (string-append configs #$defconfig)
--8<---------------cut here---------------end--------------->8---

I'll push it shortly.

-- 
Thanks,
Maxim




Send a report that this bug log contains spam.


debbugs.gnu.org maintainers <help-debbugs@gnu.org>. Last modified: Sun Dec 22 14:45:06 2024; Machine Name: wallace-server

GNU bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.