package/pipewire: install systemd services when using systemd
authorJames Hilliard <james.hilliard1@gmail.com>
Thu, 9 Sep 2021 22:41:21 +0000 (16:41 -0600)
committerArnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Tue, 21 Sep 2021 19:06:25 +0000 (21:06 +0200)
Also create a pipewire user, which is used for systemd service. There is
no sysvinit start script at the moment, but if there were, it should
also take care of changing the uid to pipewire before starting the
daemon.

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
package/pipewire/pipewire.mk

index e4ea60c39c7ed5c4d423c6ac7655a8c63b7ce00d..d0887108272fe479a4ae3d99fb3677f1362f7866 100644 (file)
@@ -49,10 +49,16 @@ PIPEWIRE_CONF_OPTS += -Dgstreamer=disabled
 endif
 
 ifeq ($(BR2_PACKAGE_SYSTEMD),y)
-PIPEWIRE_CONF_OPTS += -Dsystemd=enabled
+PIPEWIRE_CONF_OPTS += \
+       -Dsystemd=enabled \
+       -Dsystemd-system-service=enabled \
+       -Dsystemd-user-service=enabled
 PIPEWIRE_DEPENDENCIES += systemd
 else
-PIPEWIRE_CONF_OPTS += -Dsystemd=disabled
+PIPEWIRE_CONF_OPTS += \
+       -Dsystemd=disabled \
+       -Dsystemd-system-service=disabled \
+       -Dsystemd-user-service=disabled
 endif
 
 ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
@@ -150,4 +156,8 @@ else
 PIPEWIRE_CONF_OPTS += -Decho-cancel-webrtc=disabled
 endif
 
+define PIPEWIRE_USERS
+       pipewire -1 pipewire -1 * - - - PipeWire System Daemon
+endef
+
 $(eval $(meson-package))