guix_mirror_bot pushed a commit to branch core-packages-team
in repository guix.

commit 4ba48c5ba7e3531a88e516df6d7e657ecee2c561
Author: Nicolas Graves <[email protected]>
AuthorDate: Thu Feb 19 08:03:15 2026 +0100

    gnu: gnu-make: Improve style.
    
    * gnu/packages/base.scm (gnu-make)[arguments]: Improve style.
    <#:phases>: Use search-input-file instead of labels, use
    G-expressions.
    
    * gnu/packages/base.scm (gnu-make-4.2)[arguments]: Improve style.
    <#:phases>: Use search-input-file instead of labels, use
    G-expressions.
    
    * gnu/packages/commencement.scm (gnu-make-boot0)
    [arguments]: Improve style, migrate to G-expressions.
    [inputs]: Drop input labels.
    
    * guix/tests.scm (gnu-make-for-tests)[arguments]: Improve style,
    migrate to G-expressions.
    
    Change-Id: Ic2cacf099888d59fecee5278d6e59cb749602636
    Signed-off-by: Ludovic Courtès <[email protected]>
---
 gnu/packages/base.scm         | 45 +++++++++++++++++----------------
 gnu/packages/commencement.scm | 58 +++++++++++++++++++++----------------------
 guix/tests.scm                | 35 ++++++++++++--------------
 3 files changed, 68 insertions(+), 70 deletions(-)

diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm
index cdb08d33225..e87c3ffa945 100644
--- a/gnu/packages/base.scm
+++ b/gnu/packages/base.scm
@@ -616,20 +616,21 @@ standard.")
    (inputs (list guile-3.0))
    (outputs '("out" "debug"))
    (arguments
-    `(,@(if (target-hurd?)
-            '(#:configure-flags '("CFLAGS=-D__alloca=alloca"
-                                  "ac_cv_func_posix_spawn=no"))
-            '())
+    (append
+     (if (target-hurd?)
+         (list #:configure-flags '("CFLAGS=-D__alloca=alloca"
+                                   "ac_cv_func_posix_spawn=no"))
+         (list))
+     (list
       #:phases
-      (modify-phases %standard-phases
-        (add-before 'build 'set-default-shell
-          (lambda* (#:key inputs #:allow-other-keys)
-            ;; Change the default shell from /bin/sh.
-            (let ((bash (assoc-ref inputs "bash")))
+      #~(modify-phases %standard-phases
+          (add-before 'build 'set-default-shell
+            (lambda* (#:key inputs #:allow-other-keys)
+              ;; Change the default shell from /bin/sh.
               (substitute* "src/job.c"
                 (("default_shell =.*$")
-                 (format #f "default_shell = \"~a/bin/sh\";\n"
-                         bash)))))))))
+                 (format #f "default_shell = \"~a\";\n"
+                         (search-input-file inputs "/bin/sh"))))))))))
    (synopsis "Remake files automatically")
    (description
     "Make is a program that is used to control the production of
@@ -653,17 +654,17 @@ change.  GNU make offers many powerful extensions over 
the standard utility.")
                (base32
                 "12f5zzyq2w56g95nni65hc0g5p7154033y2f3qmjvd016szn5qnn"))))
     (arguments
-     `(#:configure-flags '("CFLAGS=-D__alloca=alloca -D__stat=stat")
-       #:phases
-       (modify-phases %standard-phases
-         (add-before 'build 'set-default-shell
-           (lambda* (#:key inputs #:allow-other-keys)
-             ;; Change the default shell from /bin/sh.
-             (let ((bash (assoc-ref inputs "bash")))
-               (substitute* "job.c"
-                 (("default_shell =.*$")
-                  (format #f "default_shell = \"~a/bin/sh\";\n"
-                          bash)))))))))))
+     (list
+      #:configure-flags #~(list "CFLAGS=-D__alloca=alloca -D__stat=stat")
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-before 'build 'set-default-shell
+            (lambda* (#:key inputs #:allow-other-keys)
+              ;; Change the default shell from /bin/sh.
+              (substitute* "job.c"
+                (("default_shell =.*$")
+                 (format #f "default_shell = \"~a\";\n"
+                         (search-input-file inputs "/bin/sh")))))))))))
 
 (define-public binutils
   (package
diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index 1bcd9d088d4..5c8ef6ba057 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -2020,36 +2020,36 @@ exec " gcc-bin "/" program
     (source (bootstrap-origin (package-source gnu-make)))
     (name "make-boot0")
     (arguments
-     `(#:guile ,%bootstrap-guile
-       #:implicit-inputs? #f
-       #:tests? #f                                ; cannot run "make check"
-       ,@(substitute-keyword-arguments arguments
-           ((#:configure-flags flags ''())
-            ;; The generated config.status has some problems due to the
-            ;; bootstrap environment.  Disable dependency tracking to work
-            ;; around it.
-            `(cons "--disable-dependency-tracking"
-
-                   ;; 'glibc-bootstrap' on non-x86 platforms has a buggy
-                   ;; 'posix_spawn'.  Thus, disable it.  See
-                   ;; <https://bugs.gnu.org/49367>.
-                   ,(match (%current-system)
-                      ((or "i686-linux" "x86_64-linux")
-                       flags)
-                      (_
-                       `(cons "--disable-posix-spawn" ,flags)))))
-           ((#:phases phases)
-            `(modify-phases ,phases
-               (replace 'build
-                 (lambda _
-                   (invoke "./build.sh")))
-               (replace 'install
-                 (lambda* (#:key outputs #:allow-other-keys)
-                   (let* ((out (assoc-ref outputs "out"))
-                          (bin (string-append out "/bin")))
-                     (install-file "make" bin)))))))))
+     (append
+      (list #:guile %bootstrap-guile
+            #:implicit-inputs? #f
+            #:tests? #f)                ; cannot run "make check"
+      (substitute-keyword-arguments arguments
+        ((#:configure-flags flags #~(list))
+         ;; The generated config.status has some problems due to the
+         ;; bootstrap environment.  Disable dependency tracking to work
+         ;; around it.
+         #~(cons "--disable-dependency-tracking"
+
+                 ;; 'glibc-bootstrap' on non-x86 platforms has a buggy
+                 ;; 'posix_spawn'.  Thus, disable it.  See
+                 ;; <https://bugs.gnu.org/49367>.
+                 #$(match (%current-system)
+                     ((or "i686-linux" "x86_64-linux")
+                      flags)
+                     (_
+                      #~(cons "--disable-posix-spawn" #$flags)))))
+        ((#:phases phases)
+         #~(modify-phases #$phases
+             (replace 'build
+               (lambda _
+                 (invoke "./build.sh")))
+             (replace 'install
+               (lambda _
+                 (install-file "make"
+                               (string-append #$output "/bin")))))))))
     (native-inputs '())                           ; no need for 'pkg-config'
-    (inputs (%bootstrap-inputs+toolchain))))
+    (inputs (map cadr (%bootstrap-inputs+toolchain)))))
 
 (define bzip2-boot0
   (package
diff --git a/guix/tests.scm b/guix/tests.scm
index 4be360a7798..05c78db827c 100644
--- a/guix/tests.scm
+++ b/guix/tests.scm
@@ -442,25 +442,22 @@ default values, and with EXTRA-FIELDS set as specified."
      (inherit gnu-make)
      (name "make-test-boot0")
      (arguments
-      `(#:guile ,%bootstrap-guile
-        #:implicit-inputs? #f
-        #:tests? #f                               ;cannot run "make check"
-        ,@(substitute-keyword-arguments (package-arguments gnu-make)
-            ((#:configure-flags flags ''())
-             ;; As in 'gnu-make-boot0', work around a 'config.status' defect.
-             `(cons "--disable-dependency-tracking" ,flags))
-            ((#:phases phases)
-             `(modify-phases ,phases
-                (replace 'build
-                  (lambda _
-                    (invoke "./build.sh")
-                    #t))
-                (replace 'install
-                  (lambda* (#:key outputs #:allow-other-keys)
-                    (let* ((out (assoc-ref outputs "out"))
-                           (bin (string-append out "/bin")))
-                      (install-file "make" bin)
-                      #t))))))))
+      (cons*
+       #:guile %bootstrap-guile
+       #:implicit-inputs? #f
+       #:tests? #f                               ;cannot run "make check"
+       (substitute-keyword-arguments (package-arguments gnu-make)
+         ((#:configure-flags flags ''())
+          ;; As in 'gnu-make-boot0', work around a 'config.status' defect.
+          #~(cons "--disable-dependency-tracking" #$flags))
+         ((#:phases phases)
+          #~(modify-phases #$phases
+              (replace 'build
+                (lambda _
+                  (invoke "./build.sh")))
+              (replace 'install
+                (lambda _
+                  (install-file "make" (string-append #$output "/bin")))))))))
      (native-inputs '())                          ;no need for 'pkg-config'
      (inputs %bootstrap-inputs-for-tests))))
 

Reply via email to