unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Bruno Victal <mirai@makinata.eu>
To: 62347@debbugs.gnu.org
Cc: Bruno Victal <mirai@makinata.eu>
Subject: [bug#62347] [PATCH 2/2] gnu: usbutils: Use G-Expressions.
Date: Tue, 21 Mar 2023 16:05:23 +0000	[thread overview]
Message-ID: <e51915c372259b35266ea6e276fd5bdabde47d7f.1679414688.git.mirai@makinata.eu> (raw)
In-Reply-To: <cover.1679414158.git.mirai@makinata.eu>

* gnu/packages/linux.scm (usbutils): Use G-Expressions.
---
 gnu/packages/linux.scm | 33 ++++++++++++++++-----------------
 1 file changed, 16 insertions(+), 17 deletions(-)

diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index f0a590104b..240c62bb14 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -2377,23 +2377,22 @@ (define-public usbutils
     (build-system gnu-build-system)
     (outputs (list "out" "python"))
     (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (add-before 'bootstrap 'patch-bootstrap-scripts
-           (lambda _
-             (substitute* "usbhid-dump/bootstrap"
-               (("/bin/sh") (which "sh")))))
-         (add-after 'install 'separate-python-output
-           ;; Separating one Python script shaves more than 106 MiB from :out.
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let ((out        (assoc-ref outputs "out"))
-                   (out:python (assoc-ref outputs "python")))
-               (for-each (lambda (file)
-                           (let ((old (string-append out "/" file))
-                                 (new (string-append out:python "/" file)))
-                             (mkdir-p (dirname new))
-                             (rename-file old new)))
-                         (list "bin/lsusb.py"))))))))
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-before 'bootstrap 'patch-bootstrap-scripts
+            (lambda _
+              (substitute* "usbhid-dump/bootstrap"
+                (("/bin/sh") (which "sh")))))
+          (add-after 'install 'separate-python-output
+            ;; Separating one Python script shaves more than 106 MiB from :out.
+            (lambda _
+              (for-each (lambda (file)
+                          (let ((old (string-append #$output "/" file))
+                                (new (string-append #$output:python "/" file)))
+                            (mkdir-p (dirname new))
+                            (rename-file old new)))
+                        (list "bin/lsusb.py")))))))
     (inputs
      (list eudev libusb python))
     (native-inputs
-- 
2.39.1





  parent reply	other threads:[~2023-03-21 16:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-21 16:02 [bug#62347] [PATCH 0/2] Update usbutils description & use G-Expression Bruno Victal
2023-03-21 16:05 ` [bug#62347] [PATCH 1/2] gnu: usbutils: Make package description different from synopsis Bruno Victal
2023-03-21 16:05 ` Bruno Victal [this message]
2023-04-17 21:34 ` bug#62347: [PATCH 0/2] Update usbutils description & use G-Expression 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=e51915c372259b35266ea6e276fd5bdabde47d7f.1679414688.git.mirai@makinata.eu \
    --to=mirai@makinata.eu \
    --cc=62347@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 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).