[PATCH] gnu: Add headsetcontrol.

  • Done
  • quality assurance status badge
Details
3 participants
  • John Kehayias
  • John Kehayias
  • Nicolas Goaziou
Owner
unassigned
Submitted by
John Kehayias
Severity
normal

Debbugs page

John Kehayias wrote 3 years ago
(name . Guix-patches)(address . guix-patches@gnu.org)
mE2m1wq0LOmOGyU2iOSj_ylyFw8fo7yU49_zkxwdGIMDntUp4EY_Y6EGZDF6ta8XPG8QEQBXf7i_zW8KkfNjDWvUrIbMsyK2Qx_eoxUrakE=@protonmail.com
Attached is a patch to add the program headsetcontrol, which allows getting/setting properties for USB headsets. I've been using a previous version (2.4) locally for quite some time and it works well.

The package also builds udev rules, should a note be added to the description that it includes udev rules or anything about that?

Thanks!

John
From 1a22f60566e10b3ce391aa95f3b8b520556cb590 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Sun, 26 Dec 2021 11:13:29 -0500
Subject: [PATCH] gnu: Add headsetcontrol.

* gnu/packages/hardware.scm (headsetcontrol): New variable.
---
gnu/packages/hardware.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)

Toggle diff (37 lines)
diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm
index ddd0f5acc1..129ea7c20e 100644
--- a/gnu/packages/hardware.scm
+++ b/gnu/packages/hardware.scm
@@ -316,6 +316,30 @@ (define-public h-client
(home-page "https://savannah.nongnu.org/projects/h-client/")
(license license:gpl3+))))
+(define-public headsetcontrol
+ (package
+ (name "headsetcontrol")
+ (version "2.6")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/Sapd/HeadsetControl")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0a7zimzi71416pmn6z0l1dn1c2x8p702hkd0k6da9rsznff85a88"))))
+ (build-system cmake-build-system)
+ (inputs
+ (list hidapi))
+ (synopsis "Sidetone and Battery status for USB headsets")
+ (description
+ "A tool to control certain aspects of USB-connected headsets on Linux.
+Currently, support is provided for adjusting sidetone, getting battery state,
+controlling LEDs, and setting the inactive time.")
+ (home-page "https://github.com/Sapd/HeadsetControl")
+ (license license:gpl3)))
+
(define-public i7z
(let ((revision "0")
(commit "1a41ff13db747e962456ddbb5ccb2b7fc43ca0cb"))
--
2.34.1
John Kehayias wrote 3 years ago
[PATCH v2] gnu: Add headsetcontrol.
(name . 52803@debbugs.gnu.org)(address . 52803@debbugs.gnu.org)
2_c_qvqxrYLkzqE6Wi-swccI8XaI8F5g_J3nkn7XQ0WzTLUezJLbflel0dROLPJGoOHkShwG63WMQBGTiloR9XVKFSALj8cB9LNxtKZzt2M=@pm.me
Forgot the copyright line, added in this version.
From 6ffd909e7609856111b2164067cac59fbcb2b025 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Sun, 26 Dec 2021 11:13:29 -0500
Subject: [PATCH] gnu: Add headsetcontrol.

* gnu/packages/hardware.scm (headsetcontrol): New variable.
---
gnu/packages/hardware.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm
index ddd0f5acc1..c7ebb9b7f2 100644
--- a/gnu/packages/hardware.scm
+++ b/gnu/packages/hardware.scm
@@ -8,6 +8,7 @@
;;; Copyright © 2021 Petr Hodina <phodina@protonmail.com>
;;; Copyright © 2021 Raghav Gururajan <rg@raghavgururajan.name>
;;; Copyright © 2021 Vinicius Monego <monego@posteo.net>
+;;; Copyright © 2021 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -316,6 +317,30 @@ (define-public h-client
(home-page "https://savannah.nongnu.org/projects/h-client/")
(license license:gpl3+))))
+(define-public headsetcontrol
+ (package
+ (name "headsetcontrol")
+ (version "2.6")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/Sapd/HeadsetControl")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0a7zimzi71416pmn6z0l1dn1c2x8p702hkd0k6da9rsznff85a88"))))
+ (build-system cmake-build-system)
+ (inputs
+ (list hidapi))
+ (synopsis "Sidetone and Battery status for USB headsets")
+ (description
+ "A tool to control certain aspects of USB-connected headsets on Linux.
+Currently, support is provided for adjusting sidetone, getting battery state,
+controlling LEDs, and setting the inactive time.")
+ (home-page "https://github.com/Sapd/HeadsetControl")
+ (license license:gpl3)))
+
(define-public i7z
(let ((revision "0")
(commit "1a41ff13db747e962456ddbb5ccb2b7fc43ca0cb"))
--
2.34.1
Nicolas Goaziou wrote 3 years ago
(name . John Kehayias via Guix-patches via)(address . guix-patches@gnu.org)(name . John Kehayias)(address . john.kehayias@pm.me)(name . 52803@debbugs.gnu.org)(address . 52803-done@debbugs.gnu.org)
87h7au9y2i.fsf@nicolasgoaziou.fr
Hello,

John Kehayias via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (4 lines)
> Subject: [PATCH] gnu: Add headsetcontrol.
>
> * gnu/packages/hardware.scm (headsetcontrol): New variable.

Thank you. I pushed it with the changes detailed below.

Toggle quote (7 lines)
> +(define-public headsetcontrol
> + (package
> + (name "headsetcontrol")
> + (version "2.6")
> + (source (origin
> + (method git-fetch)

I moved `origin' below `source' and adjusted indentation.

Toggle quote (8 lines)
> + (uri (git-reference
> + (url "https://github.com/Sapd/HeadsetControl")
> + (commit version)))
> + (file-name (git-file-name name version))
> + (sha256
> + (base32
> + "0a7zimzi71416pmn6z0l1dn1c2x8p702hkd0k6da9rsznff85a88"))))

I moved hash on the same line as `base32'

Toggle quote (7 lines)
> + (build-system cmake-build-system)
> + (inputs
> + (list hidapi))
> + (synopsis "Sidetone and Battery status for USB headsets")
> + (description
> + "A tool to control certain aspects of USB-connected headsets on Linux.

I started the description with the name of the package (guix lint
should warn you about this), and removed reference to Linux, since it is
not useful in Guix.

Toggle quote (5 lines)
> +Currently, support is provided for adjusting sidetone, getting battery state,
> +controlling LEDs, and setting the inactive time.")
> + (home-page "https://github.com/Sapd/HeadsetControl")
> + (license license:gpl3)))

I used gpl3+ as "main.c" includes "or (at your option) any later
version" in its header.

Regards,
--
Nicolas Goaziou
John Kehayias wrote 3 years ago
(name . Nicolas Goaziou)(address . mail@nicolasgoaziou.fr)(name . 52803@debbugs.gnu.org)(address . 52803-done@debbugs.gnu.org)(name . John Kehayias via Guix-patches via)(address . guix-patches@gnu.org)
PDUcA7YYFnmsFsAfFh5qb7P6kTtEaiZ9a8pgQ4ah1h1T6B5ZmDW0fDMlach6U1WxeW7HYktMz4of0HbhdKyivnmqaulFrcOODdLvBzLwcUo=@pm.me
Hi Nicolas,

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐

On Monday, December 27th, 2021 at 4:49 AM, Nicolas Goaziou wrote:

Toggle quote (11 lines)
> Hello,
>
> John Kehayias via Guix-patches via guix-patches@gnu.org writes:
>
> > Subject: [PATCH] gnu: Add headsetcontrol.
> >
> > - gnu/packages/hardware.scm (headsetcontrol): New variable.
>
> Thank you. I pushed it with the changes detailed below.
>

Thanks! Not sure how I missed that guix lint suggestion (I did run it), will keep a look out for that in case it did miss it for some reason.

John
?
Your comment

This issue is archived.

To comment on this conversation send an email to 52803@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 52803
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help