From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
To: Evgeny Pisemsky <evgeny@pisemsky.com>
Cc: 63211-done@debbugs.gnu.org
Subject: bug#63211: [PATCH] gnu: Add usbrelay.
Date: Fri, 01 Sep 2023 10:10:07 -0400 [thread overview]
Message-ID: <87zg262dds.fsf@gmail.com> (raw)
In-Reply-To: <87pm7j6h91.fsf@pisemsky.com> (Evgeny Pisemsky's message of "Mon, 01 May 2023 21:25:46 +0300")
Hi!
Evgeny Pisemsky <evgeny@pisemsky.com> writes:
>>From dacf7010defa351fae323786a5112904215b5478 Mon Sep 17 00:00:00 2001
> From: Evgeny Pisemsky <evgeny@pisemsky.com>
> Date: Mon, 1 May 2023 21:09:42 +0300
> Subject: [PATCH] gnu: Add usbrelay.
>
> * gnu/packages/hardware.scm (usbrelay): New variable.
> ---
> gnu/packages/hardware.scm | 36 +++++++++++++++++++++++++++++++++++-
> 1 file changed, 35 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm
> index 5b85ad9b2e..365fb88ae0 100644
> --- a/gnu/packages/hardware.scm
> +++ b/gnu/packages/hardware.scm
> @@ -2,7 +2,7 @@
> ;;; Copyright © 2018–2022 Tobias Geerinckx-Rice <me@tobias.gr>
> ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
> ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
> -;;; Copyright © 2021 Evgeny Pisemsky <evgeny@pisemsky.com>
> +;;; Copyright © 2021, 2023 Evgeny Pisemsky <evgeny@pisemsky.com>
> ;;; Copyright © 2021 Léo Le Bouter <lle-bout@zaclys.net>
> ;;; Copyright © 2021 Denis Carikli <GNUtoo@cyberdimension.org>
> ;;; Copyright © 2021, 2022 Petr Hodina <phodina@protonmail.com>
> @@ -1438,3 +1438,37 @@ (define-public lxi-tools
> on the LXI Consortium standard which defines the communication protocols for
> modern instrumentation and data acquision systems using Ethernet.")
> (license license:bsd-3)))
> +
> +(define-public usbrelay
> + (package
> + (name "usbrelay")
> + (version "1.2")
> + (source (origin
> + (method git-fetch)
> + (uri (git-reference
> + (url "https://github.com/darrylb123/usbrelay")
> + (commit version)))
> + (file-name (git-file-name name version))
> + (sha256
> + (base32
> + "0fr3wglr2c6myg4k6ai2p5z38prclcnk2ngik15sq16fnp6qg750"))))
> + (build-system gnu-build-system)
> + (arguments
> + `(#:phases (modify-phases %standard-phases
> + (delete 'configure))
> + #:make-flags (let* ((out (assoc-ref %outputs "out"))
> + (lib (string-append out "/lib")))
> + (list (string-append "CC=" ,(cc-for-target))
> + (string-append "PREFIX=" out)
> + (string-append "LDFLAGS=-Wl,-rpath=" lib)
> + "LDCONFIG=true"
> + "USBMAJOR=$(USBLIBVER)"))
> + #:tests? #f))
> + (inputs (list hidapi))
> + (home-page "https://github.com/darrylb123/usbrelay")
> + (synopsis "Control USB relay modules")
> + (description
> + "This is a Linux driver based on hidapi for a variety of inexpensive
> +HID compatible USB relay modules available with different number of
> +output relays.")
> + (license license:gpl2+)))
I've made the following changes, to use the more modern gexp approach,
and added comments next to the configure phase deletion and disabling of
tests:
--8<---------------cut here---------------start------------->8---
modified gnu/packages/hardware.scm
@@ -1475,16 +1475,16 @@ (define-public usbrelay
"0fr3wglr2c6myg4k6ai2p5z38prclcnk2ngik15sq16fnp6qg750"))))
(build-system gnu-build-system)
(arguments
- `(#:phases (modify-phases %standard-phases
- (delete 'configure))
- #:make-flags (let* ((out (assoc-ref %outputs "out"))
- (lib (string-append out "/lib")))
- (list (string-append "CC=" ,(cc-for-target))
- (string-append "PREFIX=" out)
- (string-append "LDFLAGS=-Wl,-rpath=" lib)
- "LDCONFIG=true"
- "USBMAJOR=$(USBLIBVER)"))
- #:tests? #f))
+ (list
+ #:phases #~(modify-phases %standard-phases
+ (delete 'configure)) ;no configure script
+ #:make-flags #~(list (string-append "CC=" #$(cc-for-target))
+ (string-append "PREFIX=" #$output)
+ (string-append "LDFLAGS=-Wl,-rpath="
+ (string-append #$output "/lib"))
+ "LDCONFIG=true"
+ "USBMAJOR=$(USBLIBVER)")
+ #:tests? #f)) ;no test suite
(inputs (list hidapi))
(home-page "https://github.com/darrylb123/usbrelay")
(synopsis "Control USB relay modules")
--8<---------------cut here---------------end--------------->8---
Will install shortly, thank you.
--
Thanks,
Maxim
prev parent reply other threads:[~2023-09-01 14:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-01 18:25 [bug#63211] [PATCH] gnu: Add usbrelay Evgeny Pisemsky
2023-06-01 9:00 ` [bug#63211] Reminder Evgeny Pisemsky
2023-09-01 14:10 ` Maxim Cournoyer [this message]
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=87zg262dds.fsf@gmail.com \
--to=maxim.cournoyer@gmail.com \
--cc=63211-done@debbugs.gnu.org \
--cc=evgeny@pisemsky.com \
/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).