unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Simon Streit <simon@netpanic.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 48027@debbugs.gnu.org
Subject: [bug#48027] [PATCH] gnu: Add volctl.
Date: Thu, 06 May 2021 11:39:27 +0200	[thread overview]
Message-ID: <yguy2cs8als.fsf@netpanic.org> (raw)
In-Reply-To: <87wnsftth9.fsf@gnu.org> ("Ludovic Courtès"'s message of "Mon, 03 May 2021 23:09:22 +0200")

[-- Attachment #1: Type: text/plain, Size: 975 bytes --]

Hi Ludovic,

Ludovic Courtès <ludo@gnu.org> writes:
>> +    (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!

> 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


[-- Attachment #2: 0001-gnu-Add-volctl.patch --]
[-- Type: text/x-patch, Size: 3271 bytes --]

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(+)

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


  reply	other threads:[~2021-05-06  9:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-26  7:00 [bug#48027] [PATCH] gnu: Add volctl Simon Streit
2021-05-03 21:09 ` Ludovic Courtès
2021-05-06  9:39   ` Simon Streit [this message]
2021-05-08 12:48     ` bug#48027: " Ludovic Courtès
2021-05-08 22:30       ` [bug#48027] " Simon Streit
2021-05-10  7:58         ` 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=yguy2cs8als.fsf@netpanic.org \
    --to=simon@netpanic.org \
    --cc=48027@debbugs.gnu.org \
    --cc=ludo@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).