* [bug#75002] [PATCH] gnu: pulseaudio: Split outputs.
@ 2024-12-20 23:44 Homo via Guix-patches via
2024-12-21 21:45 ` [bug#75002] [PATCH v2] " Homo via Guix-patches via
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Homo via Guix-patches via @ 2024-12-20 23:44 UTC (permalink / raw)
To: 75002; +Cc: Homo
* gnu/packages/pulseaudio.scm (pulseaudio)[outputs]: New field.
[arguments]: Add phase to split outputs.
* gnu/services/sound.scm (pulseaudio-service-type): Use daemon output.
Change-Id: Idb9f32b1ebb4d19d3f63ef56e0e1f08cb1424006
---
Should /etc/xdg/autostart/pulseaudio.desktop be removed?
gnu/packages/pulseaudio.scm | 57 ++++++++++++++++++++++++++++++++++++-
gnu/services/sound.scm | 3 +-
2 files changed, 58 insertions(+), 2 deletions(-)
diff --git a/gnu/packages/pulseaudio.scm b/gnu/packages/pulseaudio.scm
index dd0d3985c0..77b0330a54 100644
--- a/gnu/packages/pulseaudio.scm
+++ b/gnu/packages/pulseaudio.scm
@@ -190,6 +190,9 @@ (define-public pulseaudio
"pulseaudio-fix-mult-test.patch"
"pulseaudio-longer-test-timeout.patch"))))
(build-system meson-build-system)
+ (outputs '("out" ;library
+ "daemon" ;pulseaudio and start-pulseaudio-x11
+ "utils")) ;utilities
(arguments
(list
#:configure-flags
@@ -211,7 +214,59 @@ (define-public pulseaudio
(setenv "HOME" (getcwd))
;; 'thread-test' needs more time on hydra and on slower
;; machines, so we set the default timeout to 120 seconds.
- (setenv "CK_DEFAULT_TIMEOUT" "120"))))))
+ (setenv "CK_DEFAULT_TIMEOUT" "120")))
+ (add-after 'install 'split
+ (lambda _
+ (let* ((out #$output)
+ (daemon #$output:daemon)
+ (utils #$output:utils)
+ (autostart "etc/xdg/autostart")
+ (bin "bin")
+ (bash "/share/bash-completion/completions")
+ (etc "/etc/pulse")
+ (man1 "/share/man/man1")
+ (man5 "/share/man/man5")
+ (xwayland "/etc/xdg/Xwayland-session.d")
+ (zsh "/share/zsh/site-functions")
+ (rename-recursively
+ (lambda (prefix dir files)
+ (mkdir-p (string-append prefix "/" dir))
+ (for-each (lambda (file)
+ (rename-file
+ (string-append
+ out "/" dir "/" file)
+ (string-append
+ prefix "/" dir "/" file)))
+ files))))
+ (rename-recursively daemon autostart
+ (list "pulseaudio.desktop"))
+ (rename-recursively daemon bin
+ (list "pulseaudio" "start-pulseaudio-x11"))
+ (rename-recursively daemon bash
+ (list "pulseaudio"))
+ (rename-recursively daemon etc
+ (list "daemon.conf" "default.pa" "system.pa"))
+ (rename-recursively daemon man1
+ (list "pulseaudio.1" "start-pulseaudio-x11.1"))
+ (rename-recursively daemon man5
+ (list "default.pa.5" "pulse-daemon.conf.5"))
+ (rename-recursively daemon xwayland
+ (list "00-pulseaudio-x11"))
+ (rename-recursively utils bin
+ (list "pa-info" "pacat" "pacmd" "pactl" "pamon"
+ "paplay" "parec" "parecord" "pasuspender"
+ "qpaeq"))
+ (rename-recursively utils bash
+ (list "pacat" "pacmd" "pactl" "padsp" "paplay"
+ "parec" "parecord" "pasuspender"))
+ (rename-recursively utils man1
+ (list "pacat.1" "pacmd.1" "pactl.1" "pamon.1"
+ "paplay.1" "parec.1" "parecord.1"
+ "pasuspender.1" "pax11publish.1"))
+ (rename-recursively utils man5
+ (list "pulse-cli-syntax.5"))
+ (rename-recursively utils zsh
+ (list "_pulseaudio"))))))))
(inputs
(list alsa-lib
bluez
diff --git a/gnu/services/sound.scm b/gnu/services/sound.scm
index 8ca7acd737..d29bb4bbd0 100644
--- a/gnu/services/sound.scm
+++ b/gnu/services/sound.scm
@@ -231,7 +231,8 @@ (define pulseaudio-service-type
(list (service-extension session-environment-service-type
pulseaudio-environment)
(service-extension etc-service-type pulseaudio-etc)
- (service-extension udev-service-type (const (list pulseaudio)))))
+ (service-extension udev-service-type
+ (const (list `(,pulseaudio "daemon"))))))
(default-value (pulseaudio-configuration))
(description "Configure PulseAudio sound support.")))
--
2.46.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [bug#75002] [PATCH v2] gnu: pulseaudio: Split outputs.
2024-12-20 23:44 [bug#75002] [PATCH] gnu: pulseaudio: Split outputs Homo via Guix-patches via
@ 2024-12-21 21:45 ` Homo via Guix-patches via
2024-12-21 22:49 ` [bug#75002] [PATCH v3] " Homo via Guix-patches via
2024-12-21 23:57 ` gay--- via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: Homo via Guix-patches via @ 2024-12-21 21:45 UTC (permalink / raw)
To: 75002; +Cc: Homo
* gnu/packages/pulseaudio.scm (pulseaudio)[outputs]: New field.
[arguments]: Add phase to split outputs.
* gnu/services/sound.scm (pulseaudio-service-type): Use daemon output.
(pulseaudio-configuration): Use daemon output.
Change-Id: Id919d7a4cb7ef5ac5861904f4e44f9f6f2939eff
---
Didn't notice immediately that pulseaudio-configuration also needs to use daemon output.
gnu/packages/pulseaudio.scm | 57 ++++++++++++++++++++++++++++++++++++-
gnu/services/sound.scm | 7 +++--
2 files changed, 60 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/pulseaudio.scm b/gnu/packages/pulseaudio.scm
index dd0d3985c0..77b0330a54 100644
--- a/gnu/packages/pulseaudio.scm
+++ b/gnu/packages/pulseaudio.scm
@@ -190,6 +190,9 @@ (define-public pulseaudio
"pulseaudio-fix-mult-test.patch"
"pulseaudio-longer-test-timeout.patch"))))
(build-system meson-build-system)
+ (outputs '("out" ;library
+ "daemon" ;pulseaudio and start-pulseaudio-x11
+ "utils")) ;utilities
(arguments
(list
#:configure-flags
@@ -211,7 +214,59 @@ (define-public pulseaudio
(setenv "HOME" (getcwd))
;; 'thread-test' needs more time on hydra and on slower
;; machines, so we set the default timeout to 120 seconds.
- (setenv "CK_DEFAULT_TIMEOUT" "120"))))))
+ (setenv "CK_DEFAULT_TIMEOUT" "120")))
+ (add-after 'install 'split
+ (lambda _
+ (let* ((out #$output)
+ (daemon #$output:daemon)
+ (utils #$output:utils)
+ (autostart "etc/xdg/autostart")
+ (bin "bin")
+ (bash "/share/bash-completion/completions")
+ (etc "/etc/pulse")
+ (man1 "/share/man/man1")
+ (man5 "/share/man/man5")
+ (xwayland "/etc/xdg/Xwayland-session.d")
+ (zsh "/share/zsh/site-functions")
+ (rename-recursively
+ (lambda (prefix dir files)
+ (mkdir-p (string-append prefix "/" dir))
+ (for-each (lambda (file)
+ (rename-file
+ (string-append
+ out "/" dir "/" file)
+ (string-append
+ prefix "/" dir "/" file)))
+ files))))
+ (rename-recursively daemon autostart
+ (list "pulseaudio.desktop"))
+ (rename-recursively daemon bin
+ (list "pulseaudio" "start-pulseaudio-x11"))
+ (rename-recursively daemon bash
+ (list "pulseaudio"))
+ (rename-recursively daemon etc
+ (list "daemon.conf" "default.pa" "system.pa"))
+ (rename-recursively daemon man1
+ (list "pulseaudio.1" "start-pulseaudio-x11.1"))
+ (rename-recursively daemon man5
+ (list "default.pa.5" "pulse-daemon.conf.5"))
+ (rename-recursively daemon xwayland
+ (list "00-pulseaudio-x11"))
+ (rename-recursively utils bin
+ (list "pa-info" "pacat" "pacmd" "pactl" "pamon"
+ "paplay" "parec" "parecord" "pasuspender"
+ "qpaeq"))
+ (rename-recursively utils bash
+ (list "pacat" "pacmd" "pactl" "padsp" "paplay"
+ "parec" "parecord" "pasuspender"))
+ (rename-recursively utils man1
+ (list "pacat.1" "pacmd.1" "pactl.1" "pamon.1"
+ "paplay.1" "parec.1" "parecord.1"
+ "pasuspender.1" "pax11publish.1"))
+ (rename-recursively utils man5
+ (list "pulse-cli-syntax.5"))
+ (rename-recursively utils zsh
+ (list "_pulseaudio"))))))))
(inputs
(list alsa-lib
bluez
diff --git a/gnu/services/sound.scm b/gnu/services/sound.scm
index 8ca7acd737..5a19859302 100644
--- a/gnu/services/sound.scm
+++ b/gnu/services/sound.scm
@@ -139,12 +139,12 @@ (define-record-type* <pulseaudio-configuration>
;; (see e.g. <https://bugs.gnu.org/38172>).
(default '((flat-volumes . no))))
(script-file pulseaudio-configuration-script-file
- (default (file-append pulseaudio "/etc/pulse/default.pa")))
+ (default (file-append `(,pulseaudio "daemon") "/etc/pulse/default.pa")))
(extra-script-files pulseaudio-configuration-extra-script-files
(default '()))
(system-script-file pulseaudio-configuration-system-script-file
(default
- (file-append pulseaudio "/etc/pulse/system.pa"))))
+ (file-append `(,pulseaudio "daemon") "/etc/pulse/system.pa"))))
(define (pulseaudio-conf-entry arg)
(match arg
@@ -231,7 +231,8 @@ (define pulseaudio-service-type
(list (service-extension session-environment-service-type
pulseaudio-environment)
(service-extension etc-service-type pulseaudio-etc)
- (service-extension udev-service-type (const (list pulseaudio)))))
+ (service-extension udev-service-type
+ (const (list `(,pulseaudio "daemon"))))))
(default-value (pulseaudio-configuration))
(description "Configure PulseAudio sound support.")))
--
2.46.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [bug#75002] [PATCH v3] gnu: pulseaudio: Split outputs.
2024-12-20 23:44 [bug#75002] [PATCH] gnu: pulseaudio: Split outputs Homo via Guix-patches via
2024-12-21 21:45 ` [bug#75002] [PATCH v2] " Homo via Guix-patches via
@ 2024-12-21 22:49 ` Homo via Guix-patches via
2024-12-21 23:57 ` gay--- via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: Homo via Guix-patches via @ 2024-12-21 22:49 UTC (permalink / raw)
To: 75002; +Cc: Homo
* gnu/packages/pulseaudio.scm (pulseaudio)[outputs]: New field.
[arguments]: Add phase to split outputs.
* gnu/services/sound.scm (pulseaudio-service-type): Use daemon output.
(pulseaudio-configuration): Use daemon output.
Change-Id: Id4f4f6ce562796fdd03a41303b182bcf1f2a9990
---
Sorry, didn't notice type mismatch errors in services before system was done building.
gnu/packages/pulseaudio.scm | 57 ++++++++++++++++++++++++++++++++++++-
gnu/services/sound.scm | 7 +++--
2 files changed, 60 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/pulseaudio.scm b/gnu/packages/pulseaudio.scm
index dd0d3985c0..77b0330a54 100644
--- a/gnu/packages/pulseaudio.scm
+++ b/gnu/packages/pulseaudio.scm
@@ -190,6 +190,9 @@ (define-public pulseaudio
"pulseaudio-fix-mult-test.patch"
"pulseaudio-longer-test-timeout.patch"))))
(build-system meson-build-system)
+ (outputs '("out" ;library
+ "daemon" ;pulseaudio and start-pulseaudio-x11
+ "utils")) ;utilities
(arguments
(list
#:configure-flags
@@ -211,7 +214,59 @@ (define-public pulseaudio
(setenv "HOME" (getcwd))
;; 'thread-test' needs more time on hydra and on slower
;; machines, so we set the default timeout to 120 seconds.
- (setenv "CK_DEFAULT_TIMEOUT" "120"))))))
+ (setenv "CK_DEFAULT_TIMEOUT" "120")))
+ (add-after 'install 'split
+ (lambda _
+ (let* ((out #$output)
+ (daemon #$output:daemon)
+ (utils #$output:utils)
+ (autostart "etc/xdg/autostart")
+ (bin "bin")
+ (bash "/share/bash-completion/completions")
+ (etc "/etc/pulse")
+ (man1 "/share/man/man1")
+ (man5 "/share/man/man5")
+ (xwayland "/etc/xdg/Xwayland-session.d")
+ (zsh "/share/zsh/site-functions")
+ (rename-recursively
+ (lambda (prefix dir files)
+ (mkdir-p (string-append prefix "/" dir))
+ (for-each (lambda (file)
+ (rename-file
+ (string-append
+ out "/" dir "/" file)
+ (string-append
+ prefix "/" dir "/" file)))
+ files))))
+ (rename-recursively daemon autostart
+ (list "pulseaudio.desktop"))
+ (rename-recursively daemon bin
+ (list "pulseaudio" "start-pulseaudio-x11"))
+ (rename-recursively daemon bash
+ (list "pulseaudio"))
+ (rename-recursively daemon etc
+ (list "daemon.conf" "default.pa" "system.pa"))
+ (rename-recursively daemon man1
+ (list "pulseaudio.1" "start-pulseaudio-x11.1"))
+ (rename-recursively daemon man5
+ (list "default.pa.5" "pulse-daemon.conf.5"))
+ (rename-recursively daemon xwayland
+ (list "00-pulseaudio-x11"))
+ (rename-recursively utils bin
+ (list "pa-info" "pacat" "pacmd" "pactl" "pamon"
+ "paplay" "parec" "parecord" "pasuspender"
+ "qpaeq"))
+ (rename-recursively utils bash
+ (list "pacat" "pacmd" "pactl" "padsp" "paplay"
+ "parec" "parecord" "pasuspender"))
+ (rename-recursively utils man1
+ (list "pacat.1" "pacmd.1" "pactl.1" "pamon.1"
+ "paplay.1" "parec.1" "parecord.1"
+ "pasuspender.1" "pax11publish.1"))
+ (rename-recursively utils man5
+ (list "pulse-cli-syntax.5"))
+ (rename-recursively utils zsh
+ (list "_pulseaudio"))))))))
(inputs
(list alsa-lib
bluez
diff --git a/gnu/services/sound.scm b/gnu/services/sound.scm
index 8ca7acd737..e6560629ff 100644
--- a/gnu/services/sound.scm
+++ b/gnu/services/sound.scm
@@ -139,12 +139,12 @@ (define-record-type* <pulseaudio-configuration>
;; (see e.g. <https://bugs.gnu.org/38172>).
(default '((flat-volumes . no))))
(script-file pulseaudio-configuration-script-file
- (default (file-append pulseaudio "/etc/pulse/default.pa")))
+ (default #~(string-append #$pulseaudio:daemon "/etc/pulse/default.pa")))
(extra-script-files pulseaudio-configuration-extra-script-files
(default '()))
(system-script-file pulseaudio-configuration-system-script-file
(default
- (file-append pulseaudio "/etc/pulse/system.pa"))))
+ #~(string-append #$pulseaudio:daemon "/etc/pulse/system.pa"))))
(define (pulseaudio-conf-entry arg)
(match arg
@@ -231,7 +231,8 @@ (define pulseaudio-service-type
(list (service-extension session-environment-service-type
pulseaudio-environment)
(service-extension etc-service-type pulseaudio-etc)
- (service-extension udev-service-type (const (list pulseaudio)))))
+ (service-extension udev-service-type
+ (const `(,pulseaudio "daemon")))))
(default-value (pulseaudio-configuration))
(description "Configure PulseAudio sound support.")))
--
2.46.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [bug#75002] [PATCH v3] gnu: pulseaudio: Split outputs.
2024-12-20 23:44 [bug#75002] [PATCH] gnu: pulseaudio: Split outputs Homo via Guix-patches via
2024-12-21 21:45 ` [bug#75002] [PATCH v2] " Homo via Guix-patches via
2024-12-21 22:49 ` [bug#75002] [PATCH v3] " Homo via Guix-patches via
@ 2024-12-21 23:57 ` gay--- via Guix-patches via
2 siblings, 0 replies; 4+ messages in thread
From: gay--- via Guix-patches via @ 2024-12-21 23:57 UTC (permalink / raw)
To: 75002
Hm, pulseaudio-service-type doesn't install pulseaudio:daemon, this
needs fix.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-12-21 23:58 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-20 23:44 [bug#75002] [PATCH] gnu: pulseaudio: Split outputs Homo via Guix-patches via
2024-12-21 21:45 ` [bug#75002] [PATCH v2] " Homo via Guix-patches via
2024-12-21 22:49 ` [bug#75002] [PATCH v3] " Homo via Guix-patches via
2024-12-21 23:57 ` gay--- via Guix-patches via
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).