From: Stefan via Bug reports for GNU Guix <bug-guix@gnu.org>
To: 58008@debbugs.gnu.org, leo@famulari.name
Subject: bug#58008: [PATCH] gnu: linux: Fix the extra-version parameter in make-linux-libre*.
Date: Thu, 22 Sep 2022 18:50:52 +0200 [thread overview]
Message-ID: <F33F62B5-833C-4F8B-BF50-800052A00B6B@vodafonemail.de> (raw)
[-- Attachment #1: Type: text/plain, Size: 468 bytes --]
Hi Leo!
I’m addressing you directly because of the entry in etc/teams.scm.
I found and fixed a bug in make-linux-libre*. The split of the phase 'configure into a separate 'set-environment will be used by another patch.
Actually this is part of a patch series in 48314. But it is an independent fix, which can reduce the size of that other ticket.
If this patch is accepted, I may send another part of that patch series separately.
Bye
Stefan
[-- Attachment #2: 01-gnu-linux-fix-extra-version.patch --]
[-- Type: application/octet-stream, Size: 3312 bytes --]
gnu: linux: Fix the extra-version parameter in make-linux-libre*.
From: Stefan <stefan-guix@vodafonemail.de>
* gnu/packages/linux.scm (make-linux-libre*) ['set-environment]: Make
the Makefile accept EXTRAVERSION from the environment. Fix the usage of
an empty extra-version string. Split this new phase out of and adding
if before …
['configure]: … to make the phases more hackable.
---
gnu/packages/linux.scm | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 306c18e398..1a35e857c3 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -64,6 +64,7 @@
;;; Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
;;; Copyright © 2022 Rene Saavedra <nanuui@protonmail.com>
;;; Copyright © 2022 muradm <mail@muradm.net>
+;;; Copyright © 2022 Stefan <stefan-guix@vodafonemail.de>
;;;
;;; This file is part of GNU Guix.
@@ -824,8 +825,8 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration."
(lambda _
(substitute* (find-files "." "^Makefile(\\.include)?$")
(("/bin/pwd") "pwd"))))
- (replace 'configure
- (lambda* (#:key inputs target #:allow-other-keys)
+ (add-before 'configure 'set-environment
+ (lambda* (#:key target #:allow-other-keys)
;; Avoid introducing timestamps.
(setenv "KCONFIG_NOTIMESTAMP" "1")
(setenv "KBUILD_BUILD_TIMESTAMP"
@@ -847,13 +848,16 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration."
(setenv "CROSS_COMPILE" (string-append target "-"))
(format #t "`CROSS_COMPILE' set to `~a'~%"
(getenv "CROSS_COMPILE"))))
-
+ ;; Allow EXTRAVERSION to be set via the environment.
+ (substitute* "Makefile"
+ (("^ *EXTRAVERSION[[:blank:]]*=") "EXTRAVERSION ?="))
(setenv "EXTRAVERSION"
#$(and extra-version
- (string-append "-" extra-version)))
-
+ (not (string-null? extra-version))
+ (string-append "-" extra-version)))))
+ (replace 'configure
+ (lambda* (#:key inputs #:allow-other-keys)
(let ((config (assoc-ref inputs "kconfig")))
-
;; Use a custom kernel configuration file or a default
;; configuration file.
(if config
@@ -871,7 +875,7 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration."
(invoke "make" "oldconfig"))))
(replace 'install
- (lambda* (#:key inputs native-inputs #:allow-other-keys)
+ (lambda* (#:key inputs #:allow-other-keys)
(let ((moddir (string-append #$output "/lib/modules"))
(dtbdir (string-append #$output "/lib/dtbs")))
;; Install kernel image, kernel configuration and link map.
reply other threads:[~2022-09-22 19:11 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=F33F62B5-833C-4F8B-BF50-800052A00B6B@vodafonemail.de \
--to=bug-guix@gnu.org \
--cc=58008@debbugs.gnu.org \
--cc=leo@famulari.name \
--cc=stefan-guix@vodafonemail.de \
/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.