commit:     e69ec3f4edb9233815a3de2a4a42b8e09a926110
Author:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Sat May  8 14:53:55 2021 +0000
Commit:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Sat May  8 18:27:45 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e69ec3f4

media-video/pipewire: clearify postinst messages

Closes: https://bugs.gentoo.org/786546
Package-Manager: Portage-3.0.18, Repoman-3.0.3
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>

 media-video/pipewire/pipewire-9999.ebuild | 56 ++++++++++++++++++-------------
 1 file changed, 33 insertions(+), 23 deletions(-)

diff --git a/media-video/pipewire/pipewire-9999.ebuild 
b/media-video/pipewire/pipewire-9999.ebuild
index 3412a2825be..76a1e91fe19 100644
--- a/media-video/pipewire/pipewire-9999.ebuild
+++ b/media-video/pipewire/pipewire-9999.ebuild
@@ -219,16 +219,12 @@ multilib_src_install_all() {
 }
 
 pkg_postinst() {
-       if ! use pipewire-alsa; then
-               elog "It is recommended to raise RLIMIT_MEMLOCK to 256 for user"
-               elog "using PipeWire. Do it either manually or add yourself"
-               elog "to the 'audio' group:"
-               elog "  usermod -aG audio <youruser>"
-               elog
-               elog "Contrary to what some online resources may suggest, avoid 
setting"
-               elog "PULSE_LATENCY_MSEC environment variable since it may 
break ALSA clients."
-               elog
-       fi
+       elog "It is recommended to raise RLIMIT_MEMLOCK to 256 for users"
+       elog "using PipeWire. Do it either manually or add yourself"
+       elog "to the 'audio' group:"
+       elog
+       elog "  usermod -aG audio <youruser>"
+       elog
 
        if ! use jack-sdk; then
                elog "JACK emulation is incomplete and not all programs will 
work. PipeWire's"
@@ -240,30 +236,44 @@ pkg_postinst() {
        fi
 
        if use systemd; then
-               elog "Per Gentoo policy installed systemd units must be 
manually enabled:"
-               elog "systemctl --user disable pulseaudio.service 
pulseaudio.socket"
-               elog "systemctl --user enable pipewire.socket 
pipewire-pulse.socket"
-               elog "Rebooting is strongly recommended to avoid surprises from"
-               elog "remnant PulseAudio daemon auto-spawning and surviving 
logouts."
+               elog "To use PipeWire for audio, the user units must be 
manually enabled:"
+               elog
+               elog "  systemctl --user enable pipewire.socket 
pipewire-pulse.socket"
+               elog
+               elog "When switching from PulseAudio, do not forget to disable 
PulseAudio:"
+               elog
+               elog "  systemctl --user disable pulseaudio.service 
pulseaudio.socket"
+               elog
+               elog "A reboot is recommended to avoid interferences from still 
running"
+               elog "PulseAudio daemon."
+               elog
+               elog "Both, new users and those upgrading, need to enable 
pipewire-media-session:"
+               elog
+               elog "  systemctl --user enable pipewire-media-session.service"
+               elog
+               elog "NOTE: This is not required when using PipeWire only for 
screencasting."
                elog
-               ewarn "Both new users and those upgrading need to enable 
pipewire-media-session:"
-               ewarn "systemctl --user enable pipewire-media-session.service"
        else
-               elog "This ebuild auto-enables PulseAudio replacement. Because 
of that users"
+               elog "This ebuild auto-enables PulseAudio replacement. Because 
of that, users"
                elog "are recommended to edit: ${EROOT}/etc/pulse/client.conf 
and disable "
                elog "autospawn'ing of the original daemon by setting:"
-               elog "autospawn = no"
+               elog
+               elog "  autospawn = no"
+               elog
                elog "Please note that the semicolon (;) must _NOT_ be at the 
beginning of the line!"
                elog
                elog "Alternatively, if replacing PulseAudio daemon is not 
desired, edit"
-               elog "${EROOT}/etc/pipewire/pipewire.conf"
-               elog "by commenting out the relevant command near the end of 
the file:"
+               elog "${EROOT}/etc/pipewire/pipewire.conf by commenting out the 
relevant"
+               elog "command near the end of the file:"
+               elog
                elog "#\"/usr/bin/pipewire\" = { args = \"-c 
pipewire-pulse.conf\" }"
                elog
-               elog "It is still necessary to manually enable PipeWire 
startup. Setup specific"
-               elog "instructions can be found at: 
https://wiki.gentoo.org/wiki/PipeWire";
        fi
 
+       elog "For latest tips and tricks, troubleshooting information and 
documentation"
+       elog "in general, please refer to https://wiki.gentoo.org/wiki/PipeWire";
+       elog
+
        optfeature_header "The following can be installed for optional runtime 
features:"
        optfeature "restricted realtime capabilities vai D-Bus" sys-auth/rtkit
        # Once hsphfpd lands in tree, both it and ofono will need to be checked 
for presence here!

Reply via email to