From 873be06145283fe4d9dad0742364531c74f6816b879758d411b4a6fd69814a1f Mon Sep 17 00:00:00 2001 From: Dominique Leuenberger Date: Thu, 26 Mar 2020 22:31:09 +0000 Subject: [PATCH] Accepting request 787534 from GNOME:Factory OBS-URL: https://build.opensuse.org/request/show/787534 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/pipewire?expand=0&rev=7 --- _service | 18 +++ fix-memfd_create-call.patch | 59 +++++++++ pipewire-0.2.7.tar.gz | 3 - pipewire-0.3.1+48.obscpio | 3 + pipewire.changes | 117 +++++++++++++++++ pipewire.obsinfo | 5 + pipewire.spec | 245 +++++++++++++++++++++++++++++------- 7 files changed, 400 insertions(+), 50 deletions(-) create mode 100644 _service create mode 100644 fix-memfd_create-call.patch delete mode 100644 pipewire-0.2.7.tar.gz create mode 100644 pipewire-0.3.1+48.obscpio create mode 100644 pipewire.obsinfo diff --git a/_service b/_service new file mode 100644 index 0000000..a373e01 --- /dev/null +++ b/_service @@ -0,0 +1,18 @@ + + + + git + https://gitlab.freedesktop.org/pipewire/pipewire.git + b8a1ea1d + @PARENT_TAG@+@TAG_OFFSET@ + (.*)\+0 + \1 + + + + *.tar + xz + + + + diff --git a/fix-memfd_create-call.patch b/fix-memfd_create-call.patch new file mode 100644 index 0000000..44be8b7 --- /dev/null +++ b/fix-memfd_create-call.patch @@ -0,0 +1,59 @@ +Index: pipewire-0.3.0/src/examples/video-src-alloc.c +=================================================================== +--- pipewire-0.3.0.orig/src/examples/video-src-alloc.c ++++ pipewire-0.3.0/src/examples/video-src-alloc.c +@@ -29,6 +29,7 @@ + #include + #include + #include ++#include + + #include + #include +@@ -45,6 +46,46 @@ + + #define M_PI_M2 ( M_PI + M_PI ) + ++#if !defined(HAVE_MEMFD_CREATE) ++/* ++ * No glibc wrappers exist for memfd_create(2), so provide our own. ++ * ++ * Also define memfd fcntl sealing macros. While they are already ++ * defined in the kernel header file , that file as ++ * a whole conflicts with the original glibc header . ++ */ ++ ++static inline int memfd_create(const char *name, unsigned int flags) ++{ ++ return syscall(SYS_memfd_create, name, flags); ++} ++#endif ++ ++#ifndef MFD_CLOEXEC ++#define MFD_CLOEXEC 0x0001U ++#endif ++ ++#ifndef MFD_ALLOW_SEALING ++#define MFD_ALLOW_SEALING 0x0002U ++#endif ++ ++/* fcntl() seals-related flags */ ++ ++#ifndef F_LINUX_SPECIFIC_BASE ++#define F_LINUX_SPECIFIC_BASE 1024 ++#endif ++ ++#ifndef F_ADD_SEALS ++#define F_ADD_SEALS (F_LINUX_SPECIFIC_BASE + 9) ++#define F_GET_SEALS (F_LINUX_SPECIFIC_BASE + 10) ++ ++#define F_SEAL_SEAL 0x0001 /* prevent further seals from being set */ ++#define F_SEAL_SHRINK 0x0002 /* prevent file from shrinking */ ++#define F_SEAL_GROW 0x0004 /* prevent file from growing */ ++#define F_SEAL_WRITE 0x0008 /* prevent writes */ ++#endif ++ ++ + struct data { + struct pw_main_loop *loop; + struct spa_source *timer; diff --git a/pipewire-0.2.7.tar.gz b/pipewire-0.2.7.tar.gz deleted file mode 100644 index d731ede..0000000 --- a/pipewire-0.2.7.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:bfaa0f6ae6c0791e2e0b59234d399753bf24f1b33dbf587682363a8463dd8df1 -size 421644 diff --git a/pipewire-0.3.1+48.obscpio b/pipewire-0.3.1+48.obscpio new file mode 100644 index 0000000..a2ba2de --- /dev/null +++ b/pipewire-0.3.1+48.obscpio @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d2ca8ce3bd42aeb36d705ec9558ab7340839956750241c36feb8f3e9206d3c62 +size 5142029 diff --git a/pipewire.changes b/pipewire.changes index 5f6a0bc..36001f2 100644 --- a/pipewire.changes +++ b/pipewire.changes @@ -1,3 +1,120 @@ +------------------------------------------------------------------- +Mon Mar 23 13:56:45 UTC 2020 - Bjørn Lie + +- Update to version 0.3.1+48: + + Fix 32bit build. + +------------------------------------------------------------------- +Wed Mar 18 16:33:21 UTC 2020 - Bjørn Lie + +- Switch to source service, update to explicit head, file with + non-compliant license replaced. + +------------------------------------------------------------------- +Tue Mar 17 10:58:42 UTC 2020 - Bjørn Lie + +- Switch license to MIT and actually package it. +- Add doxygen, graphviz and xmltoman BuildRequires and pass docs + and man = true to meson, build documentation. Package docs in a + new docs sub-package. +- Add check section and run meson_test macro, run tests during + build. +- Add fdupes BuildRequires and pass fdupes macro, remove duplicate + files. + +------------------------------------------------------------------- +Mon Mar 9 16:11:08 UTC 2020 - Antonio Larrosa + +- Update to version 0.3.1: + + This is a bugfix release that is API and ABI compatible + with previous 0.3.x releases. + + Don't load the rtkit module by default. It can cause a + sigkill, which is not desirable for mutter, for example. + Only enable this for the jack library for now. + + Don't use pthread cancel by default because it uses a + signal that might crash some apps. Only use it for + the jack library because jack clients really expect this. + + Build fixes for -Werror=suggest-attribute=format + + improve error messages, don't report harmless errors and + warnings. Try to send error messages to the proxy that + started the operation or is the owner of the object. + + pw-cat: midi improvement, add midi recording and dump + in verbose mode + + fix properties when loading spa-nodes from the config + + Fix and update some examples + + jack: check arguments and don't crash when invalid + + Fix buffer memory upload. + + jack: fix compatibility with zrythm. Fix timemaster + install, improve sample_rate callback. Fix reposition + handling. + + fix crash in port after buffer negotiation error. + + add support for control ports in pw_filter + + fix cleanup of the metadata module + + improve param enumeration. + + Clear stream buffers when the format is cleared. + + Add create-object command in the config file to create + object from a factory. + + Fix crash after the driver was not removed from unassigned + nodes. Also properly pause inactive nodes. + + Use "true" and "false" in properties when we are talking + about a boolean. + + pulseaudio: improve compatibility + +------------------------------------------------------------------- +Fri Feb 21 15:13:15 UTC 2020 - Antonio Larrosa + +- Add patch to build correctly with glibc < 2.27 (like in SLE/Leap): + * fix-memfd_create-call.patch + +------------------------------------------------------------------- +Fri Feb 21 12:32:01 UTC 2020 - Antonio Larrosa + +- Add BuildRequires for pkgconfig(sndfile) and pkgconfig(vulkan) + so the vulkan plugin is built. +- Version the spa-plugins subpackage so different versions of + the plugins can be co-installed in the future. + +------------------------------------------------------------------- +Thu Feb 20 18:54:53 UTC 2020 - Bjørn Lie + +- Update to version 0.3.0: + + The 0.3 release is a major milestone in the developement of + PipeWire. It features a complete redesign of the scheduling + mechanisms that make it possible to run a JACK compatibility + layer with comparable performance to JACK2. + + The API has been reworked and is declared stable now. All + developement files and runtime paths are versioned so that + future incompatible changes can be done without breaking + exising applications. + + PipeWire 0.3 also includes a (now mandatory) session manager + that populates and controls the PipeWire graph. This example + session manager is very simple and not configurable. It is + expected that future version will either switch to a more + flexible session manager (like WirePlumber) or improve the + configuration options of the example session manager. + + PipeWire 0.3 includes both PulseAudio, JACK and ALSA + compatibility libraries that are known to support a wide range + of applications. The ALSA library is pretty complete at this + point. The JACK and mostly the PulseAudio compatibility + libraries need more work. See the Wiki pages for the current + compatibility problems. We do not yet encourage people to + switch away from their existing audio solutions (PulseAudio + or JACK) but we would love to hear from people who try it + anyways. Future versions will mostly focus on improving + compatibility further to make PipeWire a drop-in replacement. + PipeWire comes with some GStreamer plugins to consume and + produce data for PipeWire. The consumer (pipewiresrc) is + working well in most cases. The sink (pipewiresink) is known + to be somewhat problematic for now. +- Add pkgconfig(bluez) and pkgconfig(libpulse) BuildRequires: New + dependencies. +- Bump libpipewire, apiver and spa_ver define following upstreams + changes. Also add a new sover define. +- Package new subpackages: libjack-pw0_3_0, + libpulse-mainloop-glib-pw0_3_0, libpulse-pw0_3_0 and + libpulse-simple-pw0_3_0, as well as handle them in post(un). +- Adjust options passed to meson following upstreams changes. + ------------------------------------------------------------------- Wed Nov 6 12:29:43 UTC 2019 - Fabian Vogt diff --git a/pipewire.obsinfo b/pipewire.obsinfo new file mode 100644 index 0000000..41cef5a --- /dev/null +++ b/pipewire.obsinfo @@ -0,0 +1,5 @@ +name: pipewire +version: 0.3.1+48 +mtime: 1584969490 +commit: b8a1ea1d3a4fc18b202cc625da3a496294e9ab58 + diff --git a/pipewire.spec b/pipewire.spec index 448578f..cb8f38f 100644 --- a/pipewire.spec +++ b/pipewire.spec @@ -1,7 +1,7 @@ # # spec file for package pipewire # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # Copyright (c) 2018 Luciano Santos, luc14n0@linuxmail.org. # # All modifications and additions to the file contributed by third parties @@ -13,26 +13,34 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # -%define libpipewire libpipewire-0_2-1 -%define apiver 0.2 -%define spa_ver 0.1 +%define libpipewire libpipewire-0_3-0 +%define sover 0_3_1 +%define apiver 0.3 +%define spa_ver 0.2 +%define spa_ver_str 0_2 Name: pipewire -Version: 0.2.7 +Version: 0.3.1+48 Release: 0 Summary: A Multimedia Framework designed to be an audio and video server and more -License: LGPL-2.1-or-later +License: MIT Group: Development/Libraries/C and C++ URL: https://pipewire.org/ -Source0: https://github.com/PipeWire/pipewire/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz +Source0: %{name}-%{version}.tar.xz +Patch0: fix-memfd_create-call.patch +BuildRequires: doxygen +BuildRequires: fdupes +BuildRequires: graphviz BuildRequires: meson BuildRequires: pkgconfig +BuildRequires: xmltoman BuildRequires: pkgconfig(alsa) +BuildRequires: pkgconfig(bluez) BuildRequires: pkgconfig(dbus-1) BuildRequires: pkgconfig(gio-2.0) BuildRequires: pkgconfig(gio-unix-2.0) @@ -48,18 +56,21 @@ BuildRequires: pkgconfig(jack) >= 1.9.10 BuildRequires: pkgconfig(libavcodec) BuildRequires: pkgconfig(libavfilter) BuildRequires: pkgconfig(libavformat) +BuildRequires: pkgconfig(libpulse) BuildRequires: pkgconfig(libsystemd) BuildRequires: pkgconfig(libudev) BuildRequires: pkgconfig(libva) BuildRequires: pkgconfig(sbc) BuildRequires: pkgconfig(sdl2) +BuildRequires: pkgconfig(sndfile) BuildRequires: pkgconfig(systemd) +BuildRequires: pkgconfig(vulkan) BuildRequires: pkgconfig(x11) Requires: %{libpipewire} = %{version} Requires: %{name}-modules = %{version} Requires: %{name}-spa-tools = %{version} Requires: %{name}-tools = %{version} -Recommends: %{name}-spa-plugins = %{version} +Recommends: %{name}-spa-plugins-%{spa_ver_str} = %{version} %description PipeWire is a server and user space API to deal with multimedia pipelines. @@ -89,6 +100,75 @@ Some of its features include: This package provides the PipeWire shared library. +%package -n libjack-pw%{sover} +Summary: A Multimedia Framework designed to be an audio and video server and more +Group: Development/Libraries/C and C++ + +%description -n libjack-pw%{sover} +PipeWire is a server and user space API to deal with multimedia pipelines. + +Some of its features include: + + * Capture and playback of audio and video with minimal latency; + * Real-time Multimedia processing on audio and video; + * Multiprocess architecture to let applications share multimedia content; + * GStreamer plugins for easy use and integration in current applications; + * Sandboxed applications support. + +This package provides the PipeWire shared library. + + +%package -n libpulse-mainloop-glib-pw%{sover} +Summary: A Multimedia Framework designed to be an audio and video server and more +Group: Development/Libraries/C and C++ + +%description -n libpulse-mainloop-glib-pw%{sover} +PipeWire is a server and user space API to deal with multimedia pipelines. + +Some of its features include: + + * Capture and playback of audio and video with minimal latency; + * Real-time Multimedia processing on audio and video; + * Multiprocess architecture to let applications share multimedia content; + * GStreamer plugins for easy use and integration in current applications; + * Sandboxed applications support. + +This package provides the PipeWire shared library. + +%package -n libpulse-pw%{sover} +Summary: A Multimedia Framework designed to be an audio and video server and more +Group: Development/Libraries/C and C++ + +%description -n libpulse-pw%{sover} +PipeWire is a server and user space API to deal with multimedia pipelines. + +Some of its features include: + + * Capture and playback of audio and video with minimal latency; + * Real-time Multimedia processing on audio and video; + * Multiprocess architecture to let applications share multimedia content; + * GStreamer plugins for easy use and integration in current applications; + * Sandboxed applications support. + +This package provides the PipeWire shared library. + +%package -n libpulse-simple-pw%{sover} +Summary: A Multimedia Framework designed to be an audio and video server and more +Group: Development/Libraries/C and C++ + +%description -n libpulse-simple-pw%{sover} +PipeWire is a server and user space API to deal with multimedia pipelines. + +Some of its features include: + + * Capture and playback of audio and video with minimal latency; + * Real-time Multimedia processing on audio and video; + * Multiprocess architecture to let applications share multimedia content; + * GStreamer plugins for easy use and integration in current applications; + * Sandboxed applications support. + +This package provides the PipeWire shared library. + %package -n gstreamer-plugin-pipewire Summary: Gstreamer Plugin for PipeWire Group: System/Libraries @@ -132,12 +212,12 @@ The framework is used to build a modular daemon that can be configured to: * A central hub where video can be made available for other applications such as the gnome-shell screencast API. -%package spa-plugins +%package spa-plugins-%{spa_ver_str} Summary: Plugins For PipeWire SPA Group: Productivity/Multimedia/Other Requires: pipewire -%description spa-plugins +%description spa-plugins-%{spa_ver_str} PipeWire is a server and user space API to deal with multimedia pipelines. Some of its features include: @@ -166,38 +246,96 @@ PipeWire is a server and user space API to deal with multimedia pipelines. This package provides all the necessary files for development with PipeWire +%package doc +Summary: PipeWire media server documentation +Group: Development/Libraries/C and C++ + +%description doc +This package contains documentation for the PipeWire media server. + %prep -%autosetup -p1 +%setup +%if %{pkg_vcmp glibc < 2.27} +%patch0 -p1 +%endif %build %meson \ - -Dgstreamer=enabled \ + -Ddocs=true \ + -Dman=true \ + -Dgstreamer=true \ + -Dffmpeg=true \ -Dsystemd=true \ + -Dvulkan=true \ %{nil} %meson_build %install %meson_install +%fdupes -s %{buildroot}/%{_datadir}/doc/pipewire/html + +%check +%meson_test %post -n %{libpipewire} -p /sbin/ldconfig %postun -n %{libpipewire} -p /sbin/ldconfig +%post -n libjack-pw%{sover} -p /sbin/ldconfig +%postun -n libjack-pw%{sover} -p /sbin/ldconfig + +%post -n libpulse-mainloop-glib-pw%{sover} -p /sbin/ldconfig +%postun -n libpulse-mainloop-glib-pw%{sover} -p /sbin/ldconfig + +%post -n libpulse-pw%{sover} -p /sbin/ldconfig +%postun -n libpulse-pw%{sover} -p /sbin/ldconfig + +%post -n libpulse-simple-pw%{sover} -p /sbin/ldconfig +%postun -n libpulse-simple-pw%{sover} -p /sbin/ldconfig + %files %{_bindir}/pipewire +%{_bindir}/pipewire-media-session %{_userunitdir}/pipewire.service %{_userunitdir}/pipewire.socket -%config %{_sysconfdir}/pipewire/pipewire.conf +%{_mandir}/man1/pipewire.1%{ext_man} +%{_mandir}/man5/pipewire.conf.5%{ext_man} + %dir %{_sysconfdir}/pipewire +%config %{_sysconfdir}/pipewire/pipewire.conf + +%dir %{_libdir}/alsa-lib +%{_libdir}/alsa-lib/libasound_module_pcm_pipewire.so %files -n %{libpipewire} +%license LICENSE COPYING +%doc README.md %{_libdir}/libpipewire-%{apiver}.so.* +%files -n libjack-pw%{sover} +%{_libdir}/libjack-pw.so.* + +%files -n libpulse-mainloop-glib-pw%{sover} +%{_libdir}/libpulse-mainloop-glib-pw.so.* + +%files -n libpulse-pw%{sover} +%{_libdir}/libpulse-pw.so.* + +%files -n libpulse-simple-pw%{sover} +%{_libdir}/libpulse-simple-pw.so.* + %files -n gstreamer-plugin-pipewire %{_libdir}/gstreamer-1.0/libgstpipewire.so %files tools -%{_bindir}/pipewire-cli -%{_bindir}/pipewire-monitor +%{_bindir}/pw-cli +%{_bindir}/pw-dot +%{_bindir}/pw-mon +%{_bindir}/pw-profiler +%{_bindir}/pw-cat +%{_bindir}/pw-play +%{_bindir}/pw-record +%{_mandir}/man1/pw-cli.1%{ext_man} +%{_mandir}/man1/pw-mon.1%{ext_man} %files spa-tools %{_bindir}/spa-inspect @@ -205,48 +343,61 @@ This package provides all the necessary files for development with PipeWire %files modules %dir %{_libdir}/pipewire-%{apiver} -%{_libdir}/pipewire-%{apiver}/libpipewire-module-audio-dsp.so -%{_libdir}/pipewire-%{apiver}/libpipewire-module-autolink.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-access.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-adapter.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-client-device.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-client-node.so -%{_libdir}/pipewire-%{apiver}/libpipewire-module-portal.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-link-factory.so -%{_libdir}/pipewire-%{apiver}/libpipewire-module-mixer.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-metadata.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-profiler.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-protocol-native.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-rtkit.so -%{_libdir}/pipewire-%{apiver}/libpipewire-module-suspend-on-idle.so -%{_libdir}/pipewire-%{apiver}/libpipewire-module-spa-monitor.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-session-manager.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-spa-device-factory.so +%{_libdir}/pipewire-%{apiver}/libpipewire-module-spa-device.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-spa-node-factory.so %{_libdir}/pipewire-%{apiver}/libpipewire-module-spa-node.so -%files spa-plugins -%{_libdir}/spa/alsa/libspa-alsa.so -%{_libdir}/spa/audiomixer/libspa-audiomixer.so -%{_libdir}/spa/audiotestsrc/libspa-audiotestsrc.so -%{_libdir}/spa/bluez5/libspa-bluez5.so -%{_libdir}/spa/ffmpeg/libspa-ffmpeg.so -%{_libdir}/spa/support/libspa-dbus.so -%{_libdir}/spa/support/libspa-support.so -%{_libdir}/spa/test/libspa-test.so -%{_libdir}/spa/v4l2/libspa-v4l2.so -%{_libdir}/spa/videotestsrc/libspa-videotestsrc.so -%{_libdir}/spa/volume/libspa-volume.so -%dir %{_libdir}/spa -%dir %{_libdir}/spa/alsa -%dir %{_libdir}/spa/audiomixer -%dir %{_libdir}/spa/audiotestsrc -%dir %{_libdir}/spa/bluez5 -%dir %{_libdir}/spa/ffmpeg -%dir %{_libdir}/spa/support -%dir %{_libdir}/spa/test -%dir %{_libdir}/spa/v4l2 -%dir %{_libdir}/spa/videotestsrc -%dir %{_libdir}/spa/volume +%files spa-plugins-%{spa_ver_str} +%{_libdir}/spa-%{spa_ver}/alsa/libspa-alsa.so +%{_libdir}/spa-%{spa_ver}/audioconvert/libspa-audioconvert.so +%{_libdir}/spa-%{spa_ver}/audiomixer/libspa-audiomixer.so +%{_libdir}/spa-%{spa_ver}/bluez5/libspa-bluez5.so +%{_libdir}/spa-%{spa_ver}/control/libspa-control.so +%{_libdir}/spa-%{spa_ver}/ffmpeg/libspa-ffmpeg.so +%{_libdir}/spa-%{spa_ver}/jack/libspa-jack.so +%{_libdir}/spa-%{spa_ver}/support/libspa-dbus.so +%{_libdir}/spa-%{spa_ver}/support/libspa-support.so +%{_libdir}/spa-%{spa_ver}/v4l2/libspa-v4l2.so +%{_libdir}/spa-%{spa_ver}/videoconvert/libspa-videoconvert.so +%{_libdir}/spa-%{spa_ver}/vulkan/libspa-vulkan.so + +%dir %{_libdir}/spa-%{spa_ver} +%dir %{_libdir}/spa-%{spa_ver}/alsa +%dir %{_libdir}/spa-%{spa_ver}/audioconvert +%dir %{_libdir}/spa-%{spa_ver}/audiomixer +%dir %{_libdir}/spa-%{spa_ver}/bluez5 +%dir %{_libdir}/spa-%{spa_ver}/control +%dir %{_libdir}/spa-%{spa_ver}/ffmpeg +%dir %{_libdir}/spa-%{spa_ver}/jack +%dir %{_libdir}/spa-%{spa_ver}/support +%dir %{_libdir}/spa-%{spa_ver}/v4l2 +%dir %{_libdir}/spa-%{spa_ver}/videoconvert +%dir %{_libdir}/spa-%{spa_ver}/vulkan %files devel %{_libdir}/libpipewire-%{apiver}.so +%{_libdir}/libjack-pw.so +%{_libdir}/libpulse-mainloop-glib-pw.so +%{_libdir}/libpulse-pw.so +%{_libdir}/libpulse-simple-pw.so %{_libdir}/pkgconfig/libpipewire-%{apiver}.pc %{_libdir}/pkgconfig/libspa-%{spa_ver}.pc -%{_includedir}/pipewire -%{_includedir}/spa +%{_includedir}/pipewire-%{apiver}/ +%{_includedir}/spa-%{spa_ver}/ + +%files doc +%dir %{_datadir}/doc/pipewire +%{_datadir}/doc/pipewire/html %changelog