[PATCH] gnu: Add volctl.

  • Done
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Simon Streit
Owner
unassigned
Submitted by
Simon Streit
Severity
normal

Debbugs page

Simon Streit wrote 4 years ago
(address . guix-patches@gnu.org)
yguv989mptv.fsf@netpanic.org
* gnu/packages/gtk.scm: New Variable.
---
gnu/packages/gtk.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+)

Toggle diff (70 lines)
diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm
index 542e274ce3..b4b7dbb785 100644
--- a/gnu/packages/gtk.scm
+++ b/gnu/packages/gtk.scm
@@ -26,6 +26,7 @@
;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net>
;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2021 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2021 Simon Streit <simon@netpanic.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -90,6 +91,7 @@
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg)
#:use-module (gnu packages xdisorg)
+ #:use-module (gnu packages pulseaudio)
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-26)
#:use-module (ice-9 match))
@@ -2371,3 +2373,47 @@ linear or logarithmic scales, as dots or lines, with markers/labels) as well as
user interaction (e.g. measuring distances).")
(home-page "https://sourceforge.net/projects/gtkdatabox/")
(license license:lgpl2.1+)))
+
+(define-public volctl
+ (package
+ (name "volctl")
+ (version "0.8.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/buzz/" name
+ "/archive/v" version ".tar.gz"))
+ (sha256
+ (base32
+ "1xanqn6s2i6s2n6wysvgz6l58lsdkl3zmzz4hccla01gx7h4yx4f"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:tests? #t
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-path
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((pulse (assoc-ref inputs "pulseaudio"))
+ (xfixes (assoc-ref inputs "libxfixes")))
+ (substitute* "volctl/lib/xwrappers.py"
+ (("libXfixes.so")
+ (string-append xfixes "/lib/libXfixes.so")))
+ (substitute* "volctl/lib/pulseaudio.py"
+ (("libpulse.so.0")
+ (string-append pulse "/lib/libpulse.so.0")))
+ #t))))))
+ (inputs
+ `(("gtk+" ,gtk+)
+ ("libxfixes" ,libxfixes)
+ ("pulseaudio" ,pulseaudio)))
+ (propagated-inputs
+ `(("python-click" ,python-click)
+ ("python-pycairo" ,python-pycairo)
+ ("python-pygobject" ,python-pygobject)
+ ("python-pyyaml" ,python-pyyaml)))
+ (home-page "https://buzz.github.io/volctl/")
+ (synopsis "Per-application volume control and OSD for Linux desktops")
+ (description "Volctl is a PulseAudio-enabled tray icon volume control and
+OSD applet for Linux desktops. It's not meant to be an replacement for a
+full-featured mixer application. If you're looking for that check out the
+excellent pavucontrol.")
+ (license license:gpl2)))
--
2.31.1
Ludovic Courtès wrote 4 years ago
(name . Simon Streit)(address . simon@netpanic.org)(address . 48027@debbugs.gnu.org)
87wnsftth9.fsf@gnu.org
Hi Simon,

Simon Streit <simon@netpanic.org> skribis:

Toggle quote (2 lines)
> * gnu/packages/gtk.scm: New Variable.

[...]

Toggle quote (8 lines)
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/buzz/" name
> + "/archive/v" version ".tar.gz"))
> + (sha256
> + (base32
> + "1xanqn6s2i6s2n6wysvgz6l58lsdkl3zmzz4hccla01gx7h4yx4f"))))

To placate ‘guix lint’, could you (1) use ‘git-fetch’ instead of
referring to an autogenerated tarball, and (2) add a ‘file-name’ field
as done elsewhere?

Toggle quote (3 lines)
> + (arguments
> + `(#:tests? #t

You can remove this line, it’s the default.

Toggle quote (4 lines)
> + (synopsis "Per-application volume control and OSD for Linux desktops")
> + (description "Volctl is a PulseAudio-enabled tray icon volume control and
> +OSD applet for Linux desktops. It's not meant to be an replacement for a

I’d suggest:

s/OSD/on-screen display (OSD)/
s/Linux desktops/graphical desktops/

Could you send an updated patch?

Thank you,
Ludo’.
Simon Streit wrote 4 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 48027@debbugs.gnu.org)
yguy2cs8als.fsf@netpanic.org
Hi Ludovic,

Ludovic Courtès <ludo@gnu.org> writes:
Toggle quote (12 lines)
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "https://github.com/buzz/" name
>> + "/archive/v" version ".tar.gz"))
>> + (sha256
>> + (base32
>> + "1xanqn6s2i6s2n6wysvgz6l58lsdkl3zmzz4hccla01gx7h4yx4f"))))
>
> To placate ‘guix lint’, could you (1) use ‘git-fetch’ instead of
> referring to an autogenerated tarball, and (2) add a ‘file-name’ field
> as done elsewhere?

Thanks for your reply. I was using guix lint, but there I wasn't quite sure
how to it the correct way. Yes, looking at other definitions I simply
copied it from there. The linter is quiet now. Thanks for your tip!

Toggle quote (2 lines)
> Could you send an updated patch?

Applied the suggestions. Please find the updated patch as attachment.
I'm well chuffed having this posted now.


Cheers,
Simon
From 64730108ee4900836637fe2b37619652e2252606 Mon Sep 17 00:00:00 2001
From: Simon Streit <simon@netpanic.org>
Date: Thu, 6 May 2021 11:22:08 +0200
Subject: [PATCH] gnu: Add volctl.

* gnu/packages/gtk.scm (volctl): New Variable.
---
gnu/packages/gtk.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+)

Toggle diff (70 lines)
diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm
index 542e274ce3..6d32b70458 100644
--- a/gnu/packages/gtk.scm
+++ b/gnu/packages/gtk.scm
@@ -26,6 +26,7 @@
;;; Copyright © 2020 Guillaume Le Vaillant <glv@posteo.net>
;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2021 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2021 Simon Streit <simon@netpanic.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -90,6 +91,7 @@
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg)
#:use-module (gnu packages xdisorg)
+ #:use-module (gnu packages pulseaudio)
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-26)
#:use-module (ice-9 match))
@@ -2371,3 +2373,47 @@ linear or logarithmic scales, as dots or lines, with markers/labels) as well as
user interaction (e.g. measuring distances).")
(home-page "https://sourceforge.net/projects/gtkdatabox/")
(license license:lgpl2.1+)))
+
+(define-public volctl
+ (package
+ (name "volctl")
+ (version "0.8.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference (url "https://github.com/buzz/volctl")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1cx27j83pz2qffnzb85fbl1x6pp3irv1kbw7g1hri7kaw6ky4xiz"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-path
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((pulse (assoc-ref inputs "pulseaudio"))
+ (xfixes (assoc-ref inputs "libxfixes")))
+ (substitute* "volctl/lib/xwrappers.py"
+ (("libXfixes.so")
+ (string-append xfixes "/lib/libXfixes.so")))
+ (substitute* "volctl/lib/pulseaudio.py"
+ (("libpulse.so.0")
+ (string-append pulse "/lib/libpulse.so.0")))
+ #t))))))
+ (inputs
+ `(("gtk+" ,gtk+)
+ ("libxfixes" ,libxfixes)
+ ("pulseaudio" ,pulseaudio)))
+ (propagated-inputs
+ `(("python-click" ,python-click)
+ ("python-pycairo" ,python-pycairo)
+ ("python-pygobject" ,python-pygobject)
+ ("python-pyyaml" ,python-pyyaml)))
+ (home-page "https://buzz.github.io/volctl/")
+ (synopsis "Per-application volume control and on-screen display (OSD) for graphical desktops")
+ (description "Volctl is a PulseAudio-enabled tray icon volume control and
+OSD applet for graphical desktops. It's not meant to be an replacement for a
+full-featured mixer application. If you're looking for that check out the
+excellent pavucontrol.")
+ (license license:gpl2)))
--
2.31.1
Ludovic Courtès wrote 4 years ago
(name . Simon Streit)(address . simon@netpanic.org)(address . 48027-done@debbugs.gnu.org)
87r1ih8k8b.fsf@gnu.org
Hi Simon,

Simon Streit <simon@netpanic.org> skribis:

Toggle quote (7 lines)
> From 64730108ee4900836637fe2b37619652e2252606 Mon Sep 17 00:00:00 2001
> From: Simon Streit <simon@netpanic.org>
> Date: Thu, 6 May 2021 11:22:08 +0200
> Subject: [PATCH] gnu: Add volctl.
>
> * gnu/packages/gtk.scm (volctl): New Variable.

Applied, thanks!

I followed up with a comment: it’s not clear to me whether it’s
GPLv2-only or GPLv2-or-any-later-version, given that ‘setup.py’ just
says GPLv2. Thoughts?

Ludo’.
Closed
Simon Streit wrote 4 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 48027@debbugs.gnu.org)
ygutuncsvsp.fsf@netpanic.org
Ludovic Courtès <ludo@gnu.org> writes:
Toggle quote (2 lines)
> Applied, thanks!

Thanks as well!

Toggle quote (4 lines)
> I followed up with a comment: it’s not clear to me whether it’s
> GPLv2-only or GPLv2-or-any-later-version, given that ‘setup.py’ just
> says GPLv2. Thoughts?

I was wondering this as well, and concluded that the auther is simply
using v2 [1]. Nothing else is stated.

We might just leave it as it is for the time being?


Cheers!

Ludovic Courtès wrote 4 years ago
(name . Simon Streit)(address . simon@netpanic.org)(address . 48027@debbugs.gnu.org)
87h7jb58c5.fsf@gnu.org
Hi,

Simon Streit <simon@netpanic.org> skribis:

Toggle quote (14 lines)
> Ludovic Courtès <ludo@gnu.org> writes:
>> Applied, thanks!
>
> Thanks as well!
>
>> I followed up with a comment: it’s not clear to me whether it’s
>> GPLv2-only or GPLv2-or-any-later-version, given that ‘setup.py’ just
>> says GPLv2. Thoughts?
>
> I was wondering this as well, and concluded that the auther is simply
> using v2 [1]. Nothing else is stated.
>
> We might just leave it as it is for the time being?

Yes, sounds good.

Thanks,
Ludo’.
?
Your comment

This issue is archived.

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

To respond to this issue using the mumi CLI, first switch to it
mumi current 48027
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