From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id AITLGcNqzGOajwAAbAwnHQ (envelope-from ) for ; Sat, 21 Jan 2023 23:44:19 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id 2K3ZGMNqzGMLsgAAG6o9tA (envelope-from ) for ; Sat, 21 Jan 2023 23:44:19 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B6D6C3AEA3 for ; Sat, 21 Jan 2023 23:44:18 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pJMaj-0008Eq-6c; Sat, 21 Jan 2023 17:44:05 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pJMah-0008Eh-Qg for guix-patches@gnu.org; Sat, 21 Jan 2023 17:44:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pJMah-0003BT-2P for guix-patches@gnu.org; Sat, 21 Jan 2023 17:44:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pJMag-00063q-Fj for guix-patches@gnu.org; Sat, 21 Jan 2023 17:44:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#60840] [PATCH 0/3] gnu: volctl: Update to 0.9.3. Resent-From: Sergiu Ivanov Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 21 Jan 2023 22:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60840 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 60840@debbugs.gnu.org Received: via spool by 60840-submit@debbugs.gnu.org id=B60840.167434100723246 (code B ref 60840); Sat, 21 Jan 2023 22:44:02 +0000 Received: (at 60840) by debbugs.gnu.org; 21 Jan 2023 22:43:27 +0000 Received: from localhost ([127.0.0.1]:50052 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pJMa6-00062s-3R for submit@debbugs.gnu.org; Sat, 21 Jan 2023 17:43:26 -0500 Received: from marvid.fr ([163.172.81.107]:48996 helo=courriel.marvid.fr) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pJMa3-00062e-Ve for 60840@debbugs.gnu.org; Sat, 21 Jan 2023 17:43:25 -0500 Received: from localhost (schwifty.marvid.fr [51.159.4.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by sahkopoika (Postfix) with ESMTPSA id 2A23C7D048FC; Sat, 21 Jan 2023 23:43:17 +0100 (CET) References: <87k01na0gm.fsf@colimite.fr> <87h6wr8lah.fsf@colimite.fr> <87wn5m5rzo.fsf_-_@gmail.com> User-agent: mu4e 1.8.13; emacs 28.2 From: Sergiu Ivanov Date: Sat, 21 Jan 2023 23:30:50 +0100 In-reply-to: <87wn5m5rzo.fsf_-_@gmail.com> Message-ID: <878rhvfr0b.fsf@colimite.fr> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1674341059; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post; bh=CM2oQxYhz/2PbDMZw9IV1qhMLG5ESDYWSfrqON7PU28=; b=TzpLNia+oTS9UtJsTmflXV1H2RhK8HeJTo0yI/bm7R2nTJvXpO/AuzrEUjunXokMbsCXdM j5eWdPF7zXc1VdL0clPP+bJ0Envw0lje0zKP9tv0kouektlLV0i21GJamKlmIpzN02yXeE M2WpwZi5jjz3ppGyIshSf2DBAkVIeUc8HaDKEqg+jT9Q9XNMw46MImhLyYJFZyKwoxg/4W BAEfsvZpNdCBL9g/ZU9I6a83mEPTBeFXt+qZYOORAtqpNhY75jHsxHS+Qo4egM2QFhfz9N znlNvft3Uz8lk2fnfYVezsXueqVGD9fp/5B0BxVw/KQoNsXQ9R44TUi3cyX0pQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1674341059; a=rsa-sha256; cv=none; b=ljh65Y0Tt+JH4f5MocjYPZdHqT56hZXCDqqzOieDSf00qF0P407QGjGW5Bq5qLOSSjy24N kPtkB450bmb7f2CCJFVEYsEp5G8AoA9M8QLe2mRa+AH0rRzQo+sN3TWAx6ZZ0S42ER5Hjs sxdJ5Wz407bJyLNPbTuC6YwA55b3KcUxcvgm6+Bxc/L05itMIwGkpX7K1DfjMiyQH2YfHv CgtM18IJknU6wJWOoIiTWXZikUaY84uWz4vq/9IvlgyWD2lTJtc+AWssrQrfIYBbACLewW maK3wGyj76CCVeJpPiOq29e+nizyNuSHJc5EE+fSx3ki+hL/5S8Ri1K1CP332A== X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: -1.60 X-Spam-Score: -1.60 X-Migadu-Queue-Id: B6D6C3AEA3 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-TUID: fy3+BjXKJ1I8 --=-=-= Content-Type: text/plain Hi, Maxim Cournoyer [2023-01-16T18:01:59+0100]: > Sergiu Ivanov writes: > >>>>From b92cdb4ce99bc7ad45e0caba7f863db5931741db Mon Sep 17 00:00:00 2001 >> >> +(define-public python-pulsectl >> + (package >> + (name "python-pulsectl") >> + (version "22.3.2") >> + (source (origin >> + (method url-fetch) >> + (uri (pypi-uri "pulsectl" version)) >> + (sha256 >> + (base32 >> + "115ha1cwpd2r84ssnxdbr59hgs0jbx0lz3xpqli64kmxxqf4w5yc")))) >> + (build-system python-build-system) >> + (inputs (list pulseaudio)) >> + (arguments >> + `(#:tests? #f > > Tests are typically stripped from the pypi source archive (sdist). If > you look into the source repository, there are tests under > pulsectl/tests, so it'd be better to fetch the source from git. In fact, pulsectl's tests fail because they seem to want to start a dummy PulseAudio instance, which I expect to fail because of the restrictions of the build environment. Here's my post on the mailing list with some more details: https://lists.gnu.org/archive/html/help-guix/2023-01/msg00038.html I added a comment briefly explaining this, but maybe there is a better way. > Also note that for the cases where using #:tests? #f is actually needed > (when there really are no test suite), a short explanatory comment is > expected (;no test suite). > >> + #:phases >> + (modify-phases %standard-phases >> + (add-after 'unpack 'patch-path >> + (lambda* (#:key inputs #:allow-other-keys) >> + (let ((pulse (assoc-ref inputs "pulseaudio"))) >> + (substitute* "pulsectl/_pulsectl.py" >> + (("libpulse.so.0") >> + (string-append pulse "/lib/libpulse.so.0"))) >> + #t)))))) > > Please do not include trailing #t in phases or snippets anymore; they > are not needed. Fixed, thank you. > Also prefer using a plain list for arguments and g-expressions > (gexps). I spent some time squinting at this remark and reading the manuals, but I can't figure out what you mean. Could you please give some more hints about the parts I should change and how? >> + (home-page "https://github.com/mk-fg/python-pulse-control") >> + (synopsis >> + "Python bindings for mixer-like controls in PulseAudio") >> + (description >> + "Python high-level interface and ctypes-based bindings for >> +PulseAudio (libpulse), to use in simple synchronous code. This wrapper is >> +mostly for mixer-like controls and introspection-related operations, as >> +opposed to e.g. submitting sound samples to play and player-like >> client.") > > I'd start the description with "This package provides a Python > high-level interface [...]", to make it a complete sentence. > > I'd use plural for the last word (player-like clientS), as there could > be more than one client available. Done, thank you. > Don't forget to CC my email when sending a revised v2 version with the > above :-). Done as well :D Maxim Cournoyer [2023-01-16T18:06:19+0100]: > Hi again, > > Sergiu Ivanov writes: [...] >> + (arguments >> + `(#:tests? #f >> + #:phases >> + (modify-phases %standard-phases >> + (add-after 'unpack 'patch-path >> + (lambda* (#:key inputs #:allow-other-keys) >> + (let ((pulse (assoc-ref inputs "pulseaudio"))) >> + (substitute* "pulsectl/_pulsectl.py" >> + (("libpulse.so.0") >> + (string-append pulse "/lib/libpulse.so.0"))) > > Sorry, I forgot to mention in my previous reply: here, you could use > (search-input-file inputs "lib/libpulse.so.0"), which has the added > benefit of failing if the file cannot be found in the inputs arguments. Oh, good to know, thank you for the suggestion! search-input-file actually simplified the code and allowed me to drop the let (which I copied from the previous version of volctl in fact). I updated patches 2 and 3 to use search-input-file and attach both to these E-mails. By the way, I'd be happy to know whether with debbugs it is better to attach the updated patches to E-mails with comments, or rather sending the patches as separate E-mails. - Sergiu --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=0002-gnu-packages-Add-python-pulsectl.patch Content-Transfer-Encoding: quoted-printable >From cc34fdad77158fd98c1233d8d877f2d730c41fac Mon Sep 17 00:00:00 2001 From: Sergiu Ivanov Date: Sun, 15 Jan 2023 23:16:02 +0100 Subject: [PATCH 2/3] gnu: packages: Add python-pulsectl. * gnu/packages/audio.scm (python-pulsectl): New variable. --- gnu/packages/audio.scm | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index d72cf0ca87..990e46ee38 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -40,6 +40,7 @@ ;;; Copyright =C2=A9 2022 Juliana Sims ;;; Copyright =C2=A9 2022 Simon Streit ;;; Copyright =C2=A9 2022 Andy Tai +;;; Copyright =C2=A9 2023 Sergiu Ivanov ;;; ;;; This file is part of GNU Guix. ;;; @@ -2779,6 +2780,38 @@ (define-public python-pyaudio cross-platform audio input/output stream library.") (license license:expat))) =20 +(define-public python-pulsectl + (package + (name "python-pulsectl") + (version "22.3.2") + (source (origin + (method url-fetch) + (uri (pypi-uri "pulsectl" version)) + (sha256 + (base32 + "115ha1cwpd2r84ssnxdbr59hgs0jbx0lz3xpqli64kmxxqf4w5yc")))) + (build-system python-build-system) + (inputs (list pulseaudio)) + (arguments + `(#:tests? #f ; tests try to communicate with Pu= lseAudio + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-path + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "pulsectl/_pulsectl.py" + (("libpulse.so.0") + (string-append (search-input-file inputs "/lib/libpulse.so= .0"))))))))) + (home-page "https://github.com/mk-fg/python-pulse-control") + (synopsis + "Python bindings for mixer-like controls in PulseAudio") + (description + "This package provides a Python high-level interface and ctypes-based +bindings for PulseAudio (libpulse), to use in simple synchronous code. +This wrapper is mostly for mixer-like controls and introspection-related +operations, as opposed to e.g. submitting sound samples to play and +player-like clients.") + (license license:expat))) + (define-public python-pyliblo (package (name "python-pyliblo") --=20 2.38.1 --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=0003-gnu-volctl-Update-to-0.9.3.patch Content-Transfer-Encoding: quoted-printable >From f98307b017c0cfb1a4a46f9a882ec558cec294b1 Mon Sep 17 00:00:00 2001 From: Sergiu Ivanov Date: Sun, 15 Jan 2023 23:23:44 +0100 Subject: [PATCH 3/3] gnu: volctl: Update to 0.9.3. * gnu/packages/gtk.scm (volctl): Update to 0.9.3. --- gnu/packages/gtk.scm | 23 ++++++++++------------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index ea22d0e930..2e6a546308 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -33,6 +33,7 @@ ;;; Copyright =C2=A9 2022 Benjamin Slade ;;; Copyright =C2=A9 2022 Denis 'GNUtoo' Carikli ;;; Copyright =C2=A9 2022 Petr Hodina +;;; Copyright =C2=A9 2023 Sergiu Ivanov ;;; ;;; This file is part of GNU Guix. ;;; @@ -67,6 +68,7 @@ (define-module (gnu packages gtk) #:use-module (guix build-system waf) #:use-module (gnu packages) #:use-module (gnu packages algebra) + #:use-module (gnu packages audio) #:use-module (gnu packages autotools) #:use-module (gnu packages base) #:use-module (gnu packages bash) @@ -2949,7 +2951,7 @@ (define-public gtkdatabox (define-public volctl (package (name "volctl") - (version "0.8.2") + (version "0.9.3") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/buzz/volctl") @@ -2957,26 +2959,21 @@ (define-public volctl (file-name (git-file-name name version)) (sha256 (base32 - "1cx27j83pz2qffnzb85fbl1x6pp3irv1kbw7g1hri7kaw6ky4xiz")))) + "0fz80w3ywq54jn4v31frfdj01s5g9lz6v9cd7hpg3kirca0zisln")))) (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)))))) + (substitute* "volctl/xwrappers.py" + (("libXfixes.so") + (string-append (search-input-file inputs "/lib/libXfixes.s= o"))))))))) (inputs - (list gtk+ libxfixes pulseaudio)) + (list libxfixes)) (propagated-inputs - (list python-click python-pycairo python-pygobject python-pyyaml)) + (list python-click python-pycairo python-pygobject python-pyyaml + python-pulsectl gtk+)) (home-page "https://buzz.github.io/volctl/") (synopsis "Per-application volume control and on-screen display") (description "Volctl is a PulseAudio-enabled tray icon volume control = and --=20 2.38.1 --=-=-=--