"pulseaudio? #f" setting does not prevent pulseaudio from autostarting

  • Done
  • quality assurance status badge
Details
3 participants
  • Leo Prikler
  • Maxim Cournoyer
  • Nathan Dehnel
Owner
unassigned
Submitted by
Nathan Dehnel
Severity
normal
N
N
Nathan Dehnel wrote on 3 Jul 2020 11:00
(address . bug-guix@gnu.org)
CAEEhgEuSe6ZSS=sbegbt8Afve7EcQikg93oVULOt6YbV8AdVPw@mail.gmail.com

(define %my-services
;; My very own list of services.
(modify-services %desktop-services
(alsa-service-type config =>
(alsa-configuration
(inherit config)
(pulseaudio? #f)))))

reconfigure, reboot, login to gnome, then

bash-5.0$ pgrep pulseaudio
517
1261
L
L
Leo Prikler wrote on 3 Jul 2020 12:20
(address . ncdehnel@gmail.com)(address . 42175@debbugs.gnu.org)
336cacb31035e43c01b8a8a23b470970351e4116.camel@student.tugraz.at
I don't think pulseaudio autostarting is governed by alsa. There are
two options you can try.

1. disable autospawning through configuration. For that, try setting
the client-conf field of the pulseaudio-configuration to
'((autospawn . no))
2. Removing the pulseaudio package from gnome and anywhere else it
might be propagated. (I don't think it is propagated in other
services).

Regards, Leo
M
M
Maxim Cournoyer wrote on 1 Feb 2022 03:27
(name . Leo Prikler)(address . leo.prikler@student.tugraz.at)
878ruvl3rk.fsf@gmail.com
Hello,

Leo Prikler <leo.prikler@student.tugraz.at> writes:

Toggle quote (10 lines)
> I don't think pulseaudio autostarting is governed by alsa. There are
> two options you can try.
>
> 1. disable autospawning through configuration. For that, try setting
> the client-conf field of the pulseaudio-configuration to
> '((autospawn . no))
> 2. Removing the pulseaudio package from gnome and anywhere else it
> might be propagated. (I don't think it is propagated in other
> services).

Indeed, if you look at (gnu services sound), you'll see that what
pulseaudio? #t does (the default) is to add this to ALSA's asound.conf
file:

Toggle snippet (26 lines)
`("# Use PulseAudio by default
pcm_type.pulse {
lib \"" ,#~(string-append #$alsa-plugins:pulseaudio
"/lib/alsa-lib/libasound_module_pcm_pulse.so") "\"
}

ctl_type.pulse {
lib \"" ,#~(string-append #$alsa-plugins:pulseaudio
"/lib/alsa-lib/libasound_module_ctl_pulse.so") "\"
}

pcm.!default {
type pulse
fallback \"sysdefault\"
hint {
show on
description \"Default ALSA Output (currently PulseAudio Sound Server)\"
}
}

ctl.!default {
type pulse
fallback \"sysdefault\"
}\n\n"

This configures ALSA applications to use pulseaudio as its default
output. Many non-ALSA applications will attempt to use pulseaudio and
the configuration of it being allowed to autostart or not is to be made
at the level of pulseaudio-service-type, as pointed out in Liliana's
reply (thanks!).

Closing,

Maxim
Closed
?