From adb282242792cbad88b3401929e8e3a2f4167d1a Mon Sep 17 00:00:00 2001 From: Markus Volk Date: Sun, 22 May 2022 10:48:51 +0200 Subject: pipewire: reduce native/nativesdk dependencies; add backport patch - pipewire is by default built with lots of dependencies. Reduce them for native/nativesdk - add a backport patch to fix pipewire support in libsdl2 - allow native/nativesdk build Signed-off-by: Markus Volk Signed-off-by: Khem Raj --- .../pipewire/0001-spa-fix-c90-header-include.patch | 47 ++++++++++++++++++++++ .../recipes-multimedia/pipewire/pipewire_0.3.50.bb | 9 ++++- 2 files changed, 54 insertions(+), 2 deletions(-) create mode 100644 meta-multimedia/recipes-multimedia/pipewire/pipewire/0001-spa-fix-c90-header-include.patch (limited to 'meta-multimedia') diff --git a/meta-multimedia/recipes-multimedia/pipewire/pipewire/0001-spa-fix-c90-header-include.patch b/meta-multimedia/recipes-multimedia/pipewire/pipewire/0001-spa-fix-c90-header-include.patch new file mode 100644 index 0000000000..ad6448a10a --- /dev/null +++ b/meta-multimedia/recipes-multimedia/pipewire/pipewire/0001-spa-fix-c90-header-include.patch @@ -0,0 +1,47 @@ +From d3ea3142e1a4de206e616bc18f63a529e6b4986a Mon Sep 17 00:00:00 2001 +From: psykose +Date: Wed, 13 Apr 2022 21:57:49 +0000 +Subject: [PATCH 001/154] spa: fix c90 header include + +placing declarations after code is invalid under ISO c90 + +Fixes !1211 + +Patch-Status: Backport +--- + spa/include/spa/utils/string.h | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/spa/include/spa/utils/string.h b/spa/include/spa/utils/string.h +index e80434537..43d19616c 100644 +--- a/spa/include/spa/utils/string.h ++++ b/spa/include/spa/utils/string.h +@@ -276,10 +276,11 @@ static inline int spa_scnprintf(char *buffer, size_t size, const char *format, . + static inline float spa_strtof(const char *str, char **endptr) + { + static locale_t locale = NULL; ++ locale_t prev; + float v; + if (SPA_UNLIKELY(locale == NULL)) + locale = newlocale(LC_ALL_MASK, "C", NULL); +- locale_t prev = uselocale(locale); ++ prev = uselocale(locale); + v = strtof(str, endptr); + uselocale(prev); + return v; +@@ -319,10 +320,11 @@ static inline bool spa_atof(const char *str, float *val) + static inline double spa_strtod(const char *str, char **endptr) + { + static locale_t locale = NULL; ++ locale_t prev; + double v; + if (SPA_UNLIKELY(locale == NULL)) + locale = newlocale(LC_ALL_MASK, "C", NULL); +- locale_t prev = uselocale(locale); ++ prev = uselocale(locale); + v = strtod(str, endptr); + uselocale(prev); + return v; +-- +2.25.1 + diff --git a/meta-multimedia/recipes-multimedia/pipewire/pipewire_0.3.50.bb b/meta-multimedia/recipes-multimedia/pipewire/pipewire_0.3.50.bb index 0d725b9ee2..0f527c0a59 100644 --- a/meta-multimedia/recipes-multimedia/pipewire/pipewire_0.3.50.bb +++ b/meta-multimedia/recipes-multimedia/pipewire/pipewire_0.3.50.bb @@ -14,7 +14,10 @@ LIC_FILES_CHKSUM = " \ DEPENDS = "dbus ncurses" SRCREV = "64cf5e80e6240284e6b757907b900507fe56f1b5" -SRC_URI = "git://gitlab.freedesktop.org/pipewire/pipewire.git;branch=master;protocol=https" +SRC_URI = " \ + git://gitlab.freedesktop.org/pipewire/pipewire.git;branch=master;protocol=https \ + file://0001-spa-fix-c90-header-include.patch \ +" S = "${WORKDIR}/git" @@ -69,7 +72,7 @@ EXTRA_OEMESON += " \ -Dlegacy-rtkit=false \ " -PACKAGECONFIG ??= "\ +PACKAGECONFIG:class-target ??= "\ ${@bb.utils.contains('DISTRO_FEATURES', 'zeroconf', 'avahi', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd systemd-system-service', '', d)} \ @@ -335,3 +338,5 @@ FILES:${PN}-v4l2 += " \ FILES:gstreamer1.0-pipewire = " \ ${libdir}/gstreamer-1.0/* \ " + +BBCLASSEXTEND = "native nativesdk" -- cgit v1.2.3-54-g00ecf