From 7ed43ce85f403553c403b36a7c0767ca53f624e8 Mon Sep 17 00:00:00 2001 From: Lukas Rusak Date: Tue, 17 May 2022 11:25:00 -0700 Subject: [PATCH] kodi: add patch to allow building without alsa --- ...01-CPlatformLinux-ifdef-alsa-support.patch | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 packages/mediacenter/kodi/patches/0001-CPlatformLinux-ifdef-alsa-support.patch diff --git a/packages/mediacenter/kodi/patches/0001-CPlatformLinux-ifdef-alsa-support.patch b/packages/mediacenter/kodi/patches/0001-CPlatformLinux-ifdef-alsa-support.patch new file mode 100644 index 0000000000..dc0d70065a --- /dev/null +++ b/packages/mediacenter/kodi/patches/0001-CPlatformLinux-ifdef-alsa-support.patch @@ -0,0 +1,62 @@ +From 4839aa9e65478bab3a1f61bab06419348daa061c Mon Sep 17 00:00:00 2001 +From: Lukas Rusak +Date: Tue, 17 May 2022 10:43:44 -0700 +Subject: [PATCH] CPlatformLinux: ifdef alsa support + +--- + xbmc/platform/linux/PlatformLinux.cpp | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +diff --git a/xbmc/platform/linux/PlatformLinux.cpp b/xbmc/platform/linux/PlatformLinux.cpp +index dd2e35f2e2..4a1e104eb9 100644 +--- a/xbmc/platform/linux/PlatformLinux.cpp ++++ b/xbmc/platform/linux/PlatformLinux.cpp +@@ -8,11 +8,17 @@ + + #include "PlatformLinux.h" + ++#if defined(HAS_ALSA) + #include "cores/AudioEngine/Sinks/alsa/ALSADeviceMonitor.h" + #include "cores/AudioEngine/Sinks/alsa/ALSAHControlMonitor.h" ++#endif ++ + #include "utils/StringUtils.h" + ++#if defined(HAS_ALSA) + #include "platform/linux/FDEventMonitor.h" ++#endif ++ + #include "platform/linux/powermanagement/LinuxPowerSyscall.h" + + // clang-format off +@@ -122,6 +128,7 @@ bool CPlatformLinux::InitStageOne() + + m_lirc.reset(OPTIONALS::LircRegister()); + ++#if defined(HAS_ALSA) + RegisterService(std::make_shared()); + #if defined(HAVE_LIBUDEV) + RegisterService(std::make_shared()); +@@ -129,11 +136,13 @@ bool CPlatformLinux::InitStageOne() + #if !defined(HAVE_X11) + RegisterService(std::make_shared()); + #endif ++#endif // HAS_ALSA + return true; + } + + void CPlatformLinux::DeinitStageOne() + { ++#if defined(HAS_ALSA) + #if !defined(HAVE_X11) + DeregisterService(typeid(CALSAHControlMonitor)); + #endif +@@ -141,4 +150,5 @@ void CPlatformLinux::DeinitStageOne() + DeregisterService(typeid(CALSADeviceMonitor)); + #endif + DeregisterService(typeid(CFDEventMonitor)); ++#endif // HAS_ALSA + } +-- +2.35.3 +