diff --git a/multimedia/pipewire/Makefile b/multimedia/pipewire/Makefile index d312ca863..2440638bd 100644 --- a/multimedia/pipewire/Makefile +++ b/multimedia/pipewire/Makefile @@ -1,5 +1,6 @@ PORTNAME= pipewire DISTVERSION= 0.3.25 +PORTREVISION= 1 CATEGORIES= multimedia MAINTAINER= arrowd@FreeBSD.org @@ -18,12 +19,16 @@ LIB_DEPENDS= libasound.so:audio/alsa-lib \ USES= compiler:c11 gnome meson pkgconfig -OPTIONS_DEFINE= GSTREAMER VULKAN +OPTIONS_DEFINE= GSTREAMER MEDIASESSION VULKAN GSTREAMER_MESON_ENABLED=gstreamer GSTREAMER_LIB_DEPENDS= libgstreamer-1.0.so:multimedia/gstreamer1 \ libgstaudio-1.0.so:multimedia/gstreamer1-plugins +MEDIASESSION_DESC= Session manager support +MEDIASESSION_MESON_ENABLED= alsa pipewire-alsa media-session pw-cat +MEDIASESSION_LIB_DEPENDS= libsndfile.so:audio/libsndfile + VULKAN_DESC= Enable Vulkan integration VULKAN_MESON_ENABLED= vulkan VULKAN_BUILD_DEPENDS= ${LOCALBASE}/include/vulkan/vulkan.h:graphics/vulkan-headers @@ -35,10 +40,11 @@ USE_LDCONFIG= yes USE_GITHUB= yes GH_ACCOUNT= PipeWire -MESON_ARGS= -Dalsa=disabled -Dpipewire-alsa=disabled \ - -D bluez5=disabled \ +MESON_ARGS= -D bluez5=disabled \ -D jack=disabled -D pipewire-jack=disabled \ - -D systemd=disabled + -D systemd=disabled \ + -D sdl2=disabled \ + -D udevrulesdir="${LOCALBASE}/lib/udev/rules.d" OPTIONS_SUB= yes diff --git a/multimedia/pipewire/files/patch-spa_plugins_alsa_meson.build b/multimedia/pipewire/files/patch-spa_plugins_alsa_meson.build new file mode 100644 index 000000000..f816afa54 --- /dev/null +++ b/multimedia/pipewire/files/patch-spa_plugins_alsa_meson.build @@ -0,0 +1,20 @@ +--- spa/plugins/alsa/meson.build.orig 2021-04-06 13:51:02 UTC ++++ spa/plugins/alsa/meson.build +@@ -16,7 +16,7 @@ spa_alsa = shared_library( + [ spa_alsa_sources ], + c_args : acp_c_args, + include_directories : [spa_inc, configinc], +- dependencies : [ alsa_dep, libudev_dep, mathlib ], ++ dependencies : [ alsa_dep, libudev_dep, mathlib, epoll_shim_dep, libinotify_dep ], + link_with : [ acp_lib ], + install : true, + install_dir : join_paths(spa_plugindir, 'alsa') +@@ -38,7 +38,7 @@ executable('spa-acp-tool', + + executable('test-timer', + [ 'test-timer.c' ], +- dependencies : [ alsa_dep, mathlib ], ++ dependencies : [ alsa_dep, mathlib, epoll_shim_dep ], + install : false, + ) + diff --git a/multimedia/pipewire/files/patch-src_examples_meson.build b/multimedia/pipewire/files/patch-src_examples_meson.build new file mode 100644 index 000000000..0f553c506 --- /dev/null +++ b/multimedia/pipewire/files/patch-src_examples_meson.build @@ -0,0 +1,11 @@ +--- src/examples/meson.build.orig 2021-04-06 13:51:02 UTC ++++ src/examples/meson.build +@@ -92,7 +92,7 @@ if not get_option('media-session').disabled() and alsa + 'media-session/suspend-node.c', + c_args : [ '-D_GNU_SOURCE' ], + install: true, +- dependencies : [dbus_dep, pipewire_dep, alsa_dep, mathlib], ++ dependencies : [dbus_dep, pipewire_dep, alsa_dep, mathlib, libinotify_dep], + ) + endif + diff --git a/multimedia/pipewire/pkg-plist b/multimedia/pipewire/pkg-plist index 155f184cd..fdccec22b 100644 --- a/multimedia/pipewire/pkg-plist +++ b/multimedia/pipewire/pkg-plist @@ -1,26 +1,34 @@ bin/pipewire +%%MEDIASESSION%%bin/pipewire-media-session bin/pipewire-pulse +%%MEDIASESSION%%bin/pw-cat bin/pw-cli bin/pw-dot bin/pw-dump bin/pw-loopback bin/pw-metadata bin/pw-mididump +%%MEDIASESSION%%bin/pw-midiplay +%%MEDIASESSION%%bin/pw-midirecord bin/pw-mon +%%MEDIASESSION%%bin/pw-play bin/pw-profiler +%%MEDIASESSION%%bin/pw-record bin/pw-reserve +%%MEDIASESSION%%bin/spa-acp-tool bin/spa-inspect bin/spa-json-dump bin/spa-monitor +%%MEDIASESSION%%bin/spa-resample %%ETCDIR%%/client-rt.conf %%ETCDIR%%/client.conf %%ETCDIR%%/jack.conf -%%ETCDIR%%/media-session.d/alsa-monitor.conf -%%ETCDIR%%/media-session.d/bluez-monitor.conf -%%ETCDIR%%/media-session.d/media-session.conf -%%ETCDIR%%/media-session.d/v4l2-monitor.conf -%%ETCDIR%%/media-session.d/with-jack -%%ETCDIR%%/media-session.d/with-pulseaudio +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/alsa-monitor.conf +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/bluez-monitor.conf +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/media-session.conf +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/v4l2-monitor.conf +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/with-jack +%%MEDIASESSION%%%%ETCDIR%%/media-session.d/with-pulseaudio %%ETCDIR%%/pipewire-pulse.conf @sample %%ETCDIR%%/pipewire.conf.sample include/pipewire-0.3/pipewire/array.h @@ -149,6 +157,8 @@ include/spa-0.2/spa/utils/result.h include/spa-0.2/spa/utils/ringbuffer.h include/spa-0.2/spa/utils/type-info.h include/spa-0.2/spa/utils/type.h +%%MEDIASESSION%%lib/alsa-lib/libasound_module_ctl_pipewire.so +%%MEDIASESSION%%lib/alsa-lib/libasound_module_pcm_pipewire.so %%GSTREAMER%%lib/gstreamer-1.0/libgstpipewire.so lib/libpipewire-0.3.so lib/libpipewire-0.3.so.0 @@ -169,6 +179,7 @@ lib/pipewire-0.3/libpipewire-module-spa-device-factory.so lib/pipewire-0.3/libpipewire-module-spa-device.so lib/pipewire-0.3/libpipewire-module-spa-node-factory.so lib/pipewire-0.3/libpipewire-module-spa-node.so +%%MEDIASESSION%%lib/spa-0.2/alsa/libspa-alsa.so lib/spa-0.2/audioconvert/libspa-audioconvert.so lib/spa-0.2/audiomixer/libspa-audiomixer.so lib/spa-0.2/audiotestsrc/libspa-audiotestsrc.so @@ -180,5 +191,76 @@ lib/spa-0.2/videoconvert/libspa-videoconvert.so lib/spa-0.2/videotestsrc/libspa-videotestsrc.so lib/spa-0.2/volume/libspa-volume.so %%VULKAN%%lib/spa-0.2/vulkan/libspa-vulkan.so +%%MEDIASESSION%%lib/udev/rules.d/90-pipewire-alsa.rules libdata/pkgconfig/libpipewire-0.3.pc libdata/pkgconfig/libspa-0.2.pc +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-aux.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-dock-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-fm.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-front-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-headphone-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-headset-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-internal-mic-always.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-internal-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-linein.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-mic-line.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-mic.conf.common +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-rear-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-tvtuner.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input-video.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-input.conf.common +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-chat.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-headphones-2.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-headphones.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-lineout.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-mono.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-speaker-always.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output-speaker.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/analog-output.conf.common +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-0.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-1.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-10.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-2.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-3.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-4.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-5.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-6.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-7.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-8.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/hdmi-output-9.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/iec958-stereo-input.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/iec958-stereo-output.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/steelseries-arctis-output-chat-common.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/steelseries-arctis-output-game-common.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/usb-gaming-headset-input.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/usb-gaming-headset-output-mono.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/usb-gaming-headset-output-stereo.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/paths/virtual-surround-7.1.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/audigy.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/behringer-umc22.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/cmedia-high-speed-true-hdaudio.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/default.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/dell-dock-tb16-usb-audio.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/force-speaker-and-int-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/force-speaker.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/hp-tbt-dock-120w-g2.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/hp-tbt-dock-audio-module.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/kinect-audio.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/maudio-fasttrack-pro.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-audio4dj.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-audio8dj.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-korecontroller.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-traktor-audio10.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-traktor-audio2.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-traktor-audio6.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/native-instruments-traktorkontrol-s4.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/sb-omni-surround-5.1.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/sennheiser-gsx.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/simple-headphones-mic.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/steelseries-arctis-common-usb-audio.conf +%%MEDIASESSION%%share/alsa-card-profile/mixer/profile-sets/usb-gaming-headset.conf +%%MEDIASESSION%%share/alsa/alsa.conf.d/50-pipewire.conf +%%MEDIASESSION%%share/alsa/alsa.conf.d/99-pipewire-default.conf