Skip to content

Instantly share code, notes, and snippets.

@tatumroaquin
Created October 12, 2022 10:07
Show Gist options
  • Save tatumroaquin/6e5c8581f43f1cfc86158f661e8cbe09 to your computer and use it in GitHub Desktop.
Save tatumroaquin/6e5c8581f43f1cfc86158f661e8cbe09 to your computer and use it in GitHub Desktop.
Pipewire configuration in Void Linux

Making Pipewire Work In Void Linux

Prerequisites

  1. Install this tool to set $XDG_RUNTIME_DIR automatically
xbps-install -S dumb_runtime_dir

or

  1. Add this line in your .zshenv to set the variable manually
export PIPEWIRE_RUNTIME_DIR=`mktemp -d $(id -u)-runtime-dir.XXX`
  • choose either one of the two procedures shown above (1 or 2)
  • pipewire-pulse requires $XDG_RUNTIME_DIR to be configured
  • which is typically handled automatically by systemd-logind or elogind
  • but since we are using runit as our init system this is necessary

Fix policy warnings

Real-time Policy Kit

xbps-install -S rtkit

pipewire on some systems may spew out warnings and permission issues about RTKit, this package is related to that issue. but I am yet to find the proper solution.

Autostarting

  1. Desktop Applications Autostart Specification
xbps-install -S xdg-desktop-portal
mkdir $XDG_CONFIG_HOME/autostart
ln -s /usr/share/applications/pipewire.desktop $XDG_CONFIG_HOME/autostart/
ln -s /usr/share/applications/pipewire-pulse.desktop $XDG_CONFIG_HOME/autostart/

or

  1. Just use runit to start pipewire as root
ln -s /etc/sv/pipewire /var/service
ln -s /etc/sv/pipewire-pulse /var/service
  • note that the void docs explicitly states that pipewire needs to be started as the current $USER, which means it is recommended to use the first method

sources:

https://docs.voidlinux.org/config/media/pipewire.html
https://wiki.gentoo.org/wiki/PipeWire#Login_without_session_management
https://www.reddit.com/r/voidlinux/comments/o74i76/pipewire_rtkit_warnings/
https://www.reddit.com/r/voidlinux/comments/xs72hz/initializing_pipewire/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment