summaryrefslogtreecommitdiff
path: root/media-sound/snapcast
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-12-27 06:30:35 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-12-27 06:30:35 +0000
commit721e451ec418e1712f6962404e111f0ebd487389 (patch)
treeaab5b35236af464349c2522312c63b664273465c /media-sound/snapcast
parente80134587e8d959a88dba7dd3784895372e205c8 (diff)
gentoo auto-resync : 27:12:2024 - 06:30:34
Diffstat (limited to 'media-sound/snapcast')
-rw-r--r--media-sound/snapcast/Manifest5
-rw-r--r--media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0-make_address.patch96
-rw-r--r--media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0.patch51
-rw-r--r--media-sound/snapcast/files/snapcast-0.29.0-resampler-include.patch25
-rw-r--r--media-sound/snapcast/snapcast-0.29.0.ebuild77
5 files changed, 254 insertions, 0 deletions
diff --git a/media-sound/snapcast/Manifest b/media-sound/snapcast/Manifest
index c2f1a0b41356..39888f5d7fe2 100644
--- a/media-sound/snapcast/Manifest
+++ b/media-sound/snapcast/Manifest
@@ -1,8 +1,13 @@
AUX snapcast-0.27.0-gcc13.patch 638 BLAKE2B f21507bc9cc751e90674e0680f4a095615f5f861d259e6fa51ffa9d1a9b26e91768d1a37b4b7503e497cfa82b820585506bc3224f597de12e8e95a0d55aa1694 SHA512 7d686fbf4290ed5848555c5fe1fe708d3a70dc175aed67677dc84325680e44ff2182cce1c2512e07e6af8b6d2af57906a55c61394b72dc88a409b69cb04b45e9
+AUX snapcast-0.29.0-boost-1.87.0-make_address.patch 6570 BLAKE2B 566440623f85ebf64714b56ea4ef5045e62be3d084c8e32f4c60acac1f72a1f6229ea7661de223b00f6a8c4211746ef90028a802423831a483680fd7779b6310 SHA512 6f524fd521e79245c0824cc8beb65ee107d8137cf8a18b1fec3e43ee9562f4543102b5b4cbec6107b5fa981d4c57ee9331759633d72defc8bd375689ee12ff71
+AUX snapcast-0.29.0-boost-1.87.0.patch 2398 BLAKE2B acd6a600c038a5eae8be230b38242e615508ff27bb59ba83a78afa30db9617ec23521d103c77578778e4376c11977527d7adf6430417e73276839a0f06481083 SHA512 19bbdd6803f006a32ed0c5a12a8f7c8e71b806ecff03529a7feb4234fa26fc6814319a8822b7d2ba7153ad1dfe8d945cf58fb52eadd776e2dc9e5a3464e6a6af
+AUX snapcast-0.29.0-resampler-include.patch 673 BLAKE2B 90af06d258d67b36631915aafd0324ff19fb8074d902ce083d80f9da98d06f39d1d5079d49e66cd6cbc79cfc28c10533fea57883aea54d82e9b578a2ffa86f89 SHA512 435fdde37075e79fd0d66e5f98ec7cb3de310034cf3a2d577581e86cbac6288fb58174e0b98bb1241f788c5f412c3dc9bcaf33cb651961512d40e820147695e3
AUX snapclient.confd 641 BLAKE2B 74bae4c2c11fb7c1a7d4f2bd0f199c92a5ee11f68efb71da00026816f9dd7ba3555cc96c1e68be04dce26ea190a8e353c71817b5655ad2d9b43e3e510345c97b SHA512 f0adfca9354a4f5acb2def99585409e39229053e2b9be36309a67ac0b6935b1aeb061380a9e8a61d70bd902930536ec3afa98a6a708b08008eea1eb080fd1a5c
AUX snapclient.initd 381 BLAKE2B defa09df346dac279f1ed903adaf88842b060b34d774cfd987fa51e9885f4968b0144106883a1a48e502c3e3558ca408babd38c46663b13ee56215caa108c3be SHA512 f429dfef7abd5705a8afc38f68125a7a6e5a812cd68733c8f47a65c7fb6aa22fc665c91e557726b8f35edbaced7b2e72ffad0ba123a6ed33bf8a6d333e8c1bae
AUX snapserver.confd 1010 BLAKE2B 9d29348f1618dd399c5a9c500d1ec89fd6719243f472dbb666cfa16e6128411a83c9ac9401a1754b79ae4b560643d1f38c3f00f6f6d0a2301ad6e3fa2168c884 SHA512 98818d75e965d54082b33fa36769b74810b3137f07693eac00d10313c3716e72170e9148faa0ac25fefc7868bb7a206ac5ca6d18396fa71d1a74efcc14485548
AUX snapserver.initd 386 BLAKE2B a88d150fd5dc0e11b20fad8d07111ca9ef0074bd79d66179fc952b636296ee1b1d151a90d8774ad419cd7ec982305da3da3ddda43d55f5ad47c45d98adb72649 SHA512 d8f6b72d1a5be5f2ddd9266fac33b6d24b046993c532f204e68824919ed09f41988923a59ba722c3c9c748b87c1fdda1c91026f8e591993f34188ef3c488f379
DIST snapcast-0.27.0.tar.gz 1566337 BLAKE2B 77183cd2496beaf6808f8c1ff030cdb1e483c86ebafd57d0c75daa2dfe31030f0dd9704db40e2c0780b85c2b346e121ccd16c1cb75dea1f80e9834d3ae100fb8 SHA512 fd86f5b0d38bf308eb9cc1f3024676471176355a8cc91ee8c8d2dfe1aa0cde99fc7636133071b50304fe66ea42dee996e0088e013be7fa703f21c5bc2a35cfdd
+DIST snapcast-0.29.0.tar.gz 1202943 BLAKE2B 0fb3c4b54dfd5fb16f7a17134a03288390c6d1b06c2c93bd7b495f0ff2f650d6caffab8b369703f38ca5764038470c3066794955259d419ea7ac4eff41e177d5 SHA512 4c88c20514e81f0ec861716a81047cb441669c0c23821acd959938cf00d85c37eec28a689a3c192f78fcb21accdbd6ef4520ef3f9995ff48ff07cb33e00b6904
EBUILD snapcast-0.27.0.ebuild 1633 BLAKE2B 939937c162344b844f7e6037f8a223d353ebb47eb2afffb57b16e4a876df4e31bd4569ae7e676a5f933f4e24e5871ad9d039a57cb07ed824604644b59b6c393d SHA512 8792ed10a920b3c5b96bdeceb741392ee01224cae02862e47b037ea8f799df3ef975db421614275c323c7409b0036bd905b4a4b4e8713381a4ed855a7fcef7e7
+EBUILD snapcast-0.29.0.ebuild 1794 BLAKE2B d0528a661ca5fdad8bd4eb619cf42dc07108df7e773f6217fc6fc4e64dbc817c9f17634381d6f106f8191fc1916bfc1ff25ed5b507bd5d0d3cc93da8b8c56d8e SHA512 9e5b7af911464743b9734ba666ef8d8cfd83cc8b7020276670d322c8044b67b3b094f8823900dc11ed4fbab728b97c0d69b2adb28e647515966d4eddeb5b50db
MISC metadata.xml 960 BLAKE2B 120e81e040fd816ad8c036e42afd0edbe9e8cc801487fc0c62db4a6c1b4d48de15f23054aa7c46100e8f7f86e5aef0c6c207254c1a51578f1420bd53b5e89762 SHA512 b32393abd7fe8084445b1ba56c66a6e5d959f259c2e31b6899f522c8238d7ac0025bbd19d4e583c581c152004fbec6b593f80e9211cc76362339fc875c6a8c77
diff --git a/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0-make_address.patch b/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0-make_address.patch
new file mode 100644
index 000000000000..03190a4e20e3
--- /dev/null
+++ b/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0-make_address.patch
@@ -0,0 +1,96 @@
+https://github.com/badaix/snapcast/commit/b2fd2bf9ef835104a813c40c190d71e3644125d7
+
+From b2fd2bf9ef835104a813c40c190d71e3644125d7 Mon Sep 17 00:00:00 2001
+From: Rudi Heitbaum <rudi@heitbaum.com>
+Date: Thu, 19 Dec 2024 02:23:11 +1100
+Subject: [PATCH] use make_address from boost as from_string is deprecated
+ (#1308)
+
+Since boost 1.87.0 boost::asio::ip::address::from_string is no longer available
+
+ref: https://github.com/boostorg/asio/commit/c0d1cfce7767599c4cf00df36f8017a1073339ae
+
+fixes:
+ ../server/control_server.cpp: In member function 'void ControlServer::start()':
+ ../server/control_server.cpp:164:111: error: 'from_string' is not a member of 'boost::asio::ip::address'
+ 164 | tcp::endpoint(boost::asio::ip::address::from_string(address), tcp_settings_.port)));
+ | ^~~~~~~~~~~
+ ../server/control_server.cpp:180:112: error: 'from_string' is not a member of 'boost::asio::ip::address'
+ 180 | tcp::endpoint(boost::asio::ip::address::from_string(address), http_settings_.port)));
+ | ^~~~~~~~~~~
+ ../server/streamreader/tcp_stream.cpp: In constructor 'streamreader::TcpStream::TcpStream(streamreader::PcmStream::Listener*, boost::asio::io_context&, const ServerSettings&, const streamreader::StreamUri&)':
+ ../server/streamreader/tcp_stream.cpp:67:97: error: 'from_string' is not a member of 'boost::asio::ip::address'
+ 67 | acceptor_ = make_unique<tcp::acceptor>(strand_, tcp::endpoint(boost::asio::ip::address::from_string(host_), port_));
+ | ^~~~~~~~~~~
+ ../server/streamreader/tcp_stream.cpp: In member function 'virtual void streamreader::TcpStream::connect()':
+ ../server/streamreader/tcp_stream.cpp:96:75: error: 'from_string' is not a member of 'boost::asio::ip::address'
+ 96 | boost::asio::ip::tcp::endpoint endpoint(boost::asio::ip::address::from_string(host_), port_);
+ | ^~~~~~~~~~~
+ ../server/stream_server.cpp: In member function 'void StreamServer::start()':
+ ../server/stream_server.cpp:234:103: error: 'from_string' is not a member of 'boost::asio::ip::address'
+ 234 | tcp::endpoint(boost::asio::ip::address::from_string(address), settings_.stream.port)));
+ |
+---
+ server/control_server.cpp | 4 ++--
+ server/stream_server.cpp | 2 +-
+ server/streamreader/tcp_stream.cpp | 4 ++--
+ 3 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/server/control_server.cpp b/server/control_server.cpp
+index 03b2db76..7945855b 100644
+--- a/server/control_server.cpp
++++ b/server/control_server.cpp
+@@ -161,7 +161,7 @@ void ControlServer::start()
+ {
+ LOG(INFO, LOG_TAG) << "Creating TCP acceptor for address: " << address << ", port: " << tcp_settings_.port << "\n";
+ acceptor_tcp_.emplace_back(make_unique<tcp::acceptor>(boost::asio::make_strand(io_context_.get_executor()),
+- tcp::endpoint(boost::asio::ip::address::from_string(address), tcp_settings_.port)));
++ tcp::endpoint(boost::asio::ip::make_address(address), tcp_settings_.port)));
+ }
+ catch (const boost::system::system_error& e)
+ {
+@@ -177,7 +177,7 @@ void ControlServer::start()
+ {
+ LOG(INFO, LOG_TAG) << "Creating HTTP acceptor for address: " << address << ", port: " << http_settings_.port << "\n";
+ acceptor_http_.emplace_back(make_unique<tcp::acceptor>(boost::asio::make_strand(io_context_.get_executor()),
+- tcp::endpoint(boost::asio::ip::address::from_string(address), http_settings_.port)));
++ tcp::endpoint(boost::asio::ip::make_address(address), http_settings_.port)));
+ }
+ catch (const boost::system::system_error& e)
+ {
+diff --git a/server/stream_server.cpp b/server/stream_server.cpp
+index 718e744f..ad2fec2c 100644
+--- a/server/stream_server.cpp
++++ b/server/stream_server.cpp
+@@ -231,7 +231,7 @@ void StreamServer::start()
+ {
+ LOG(INFO, LOG_TAG) << "Creating stream acceptor for address: " << address << ", port: " << settings_.stream.port << "\n";
+ acceptor_.emplace_back(make_unique<tcp::acceptor>(boost::asio::make_strand(io_context_.get_executor()),
+- tcp::endpoint(boost::asio::ip::address::from_string(address), settings_.stream.port)));
++ tcp::endpoint(boost::asio::ip::make_address(address), settings_.stream.port)));
+ }
+ catch (const boost::system::system_error& e)
+ {
+diff --git a/server/streamreader/tcp_stream.cpp b/server/streamreader/tcp_stream.cpp
+index 1ec68d6b..ed3fd75e 100644
+--- a/server/streamreader/tcp_stream.cpp
++++ b/server/streamreader/tcp_stream.cpp
+@@ -64,7 +64,7 @@ TcpStream::TcpStream(PcmStream::Listener* pcmListener, boost::asio::io_context&
+
+ LOG(INFO, LOG_TAG) << "TcpStream host: " << host_ << ", port: " << port_ << ", is server: " << is_server_ << "\n";
+ if (is_server_)
+- acceptor_ = make_unique<tcp::acceptor>(strand_, tcp::endpoint(boost::asio::ip::address::from_string(host_), port_));
++ acceptor_ = make_unique<tcp::acceptor>(strand_, tcp::endpoint(boost::asio::ip::make_address(host_), port_));
+ }
+
+
+@@ -93,7 +93,7 @@ void TcpStream::connect()
+ else
+ {
+ stream_ = make_unique<tcp::socket>(strand_);
+- boost::asio::ip::tcp::endpoint endpoint(boost::asio::ip::address::from_string(host_), port_);
++ boost::asio::ip::tcp::endpoint endpoint(boost::asio::ip::make_address(host_), port_);
+ stream_->async_connect(endpoint,
+ [this](const boost::system::error_code& ec)
+ {
+
diff --git a/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0.patch b/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0.patch
new file mode 100644
index 000000000000..d1be4b4072db
--- /dev/null
+++ b/media-sound/snapcast/files/snapcast-0.29.0-boost-1.87.0.patch
@@ -0,0 +1,51 @@
+https://github.com/badaix/snapcast/commit/6190041e863968d76b6d16140bba90be6dff848f
+
+From 6190041e863968d76b6d16140bba90be6dff848f Mon Sep 17 00:00:00 2001
+From: badaix <johannes.pohl@badaix.de>
+Date: Thu, 19 Dec 2024 21:36:08 +0100
+Subject: [PATCH] Fix compilation with boost v1.87.0
+
+---
+ client/client_connection.cpp | 5 ++---
+ server/stream_session_ws.cpp | 2 +-
+ 2 files changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/client/client_connection.cpp b/client/client_connection.cpp
+index 53825864..6f34a018 100644
+--- a/client/client_connection.cpp
++++ b/client/client_connection.cpp
+@@ -124,10 +124,9 @@ std::string ClientConnection::getMacAddress()
+
+ void ClientConnection::connect(const ResultHandler& handler)
+ {
+- tcp::resolver::query query(server_.host, cpt::to_string(server_.port), boost::asio::ip::resolver_query_base::numeric_service);
+ boost::system::error_code ec;
+ LOG(INFO, LOG_TAG) << "Resolving host IP for: " << server_.host << "\n";
+- auto iterator = resolver_.resolve(query, ec);
++ auto iterator = resolver_.resolve(server_.host, cpt::to_string(server_.port), boost::asio::ip::resolver_query_base::numeric_service, ec);
+ if (ec)
+ {
+ LOG(ERROR, LOG_TAG) << "Failed to resolve host '" << server_.host << "', error: " << ec.message() << "\n";
+@@ -141,7 +140,7 @@ void ClientConnection::connect(const ResultHandler& handler)
+ for (const auto& iter : iterator)
+ {
+ LOG(INFO, LOG_TAG) << "Connecting to " << iter.endpoint() << "\n";
+- socket_.connect(*iterator, ec);
++ socket_.connect(iter, ec);
+ if (!ec || (ec == boost::system::errc::interrupted))
+ {
+ // We were successful or interrupted, e.g. by sig int
+diff --git a/server/stream_session_ws.cpp b/server/stream_session_ws.cpp
+index 5f666618..117603f6 100644
+--- a/server/stream_session_ws.cpp
++++ b/server/stream_session_ws.cpp
+@@ -114,7 +114,7 @@ void StreamSessionWebsocket::on_read_ws(beast::error_code ec, std::size_t bytes_
+ return;
+ }
+
+- auto* data = boost::asio::buffer_cast<char*>(buffer_.data());
++ auto* data = static_cast<char*>(buffer_.data().data());
+ baseMessage_.deserialize(data);
+ LOG(DEBUG, LOG_TAG) << "getNextMessage: " << baseMessage_.type << ", size: " << baseMessage_.size << ", id: " << baseMessage_.id
+ << ", refers: " << baseMessage_.refersTo << "\n";
+
diff --git a/media-sound/snapcast/files/snapcast-0.29.0-resampler-include.patch b/media-sound/snapcast/files/snapcast-0.29.0-resampler-include.patch
new file mode 100644
index 000000000000..296a5d61db86
--- /dev/null
+++ b/media-sound/snapcast/files/snapcast-0.29.0-resampler-include.patch
@@ -0,0 +1,25 @@
+https://github.com/badaix/snapcast/commit/f6ce4f3fbb3c797f5d92578d7bc8df547ad4cd64
+
+From f6ce4f3fbb3c797f5d92578d7bc8df547ad4cd64 Mon Sep 17 00:00:00 2001
+From: Johannes Pohl <johannes.pohl@badaix.de>
+Date: Wed, 11 Dec 2024 15:50:11 +0100
+Subject: [PATCH] Add missing include in resampler.cpp
+
+This fixes issue #1295
+---
+ common/resampler.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/common/resampler.cpp b/common/resampler.cpp
+index 1d5d698a..9548c957 100644
+--- a/common/resampler.cpp
++++ b/common/resampler.cpp
+@@ -21,6 +21,7 @@
+
+ // local headers
+ #include "common/aixlog.hpp"
++#include "common/snap_exception.hpp"
+
+ // standard headers
+ #include <cmath>
+
diff --git a/media-sound/snapcast/snapcast-0.29.0.ebuild b/media-sound/snapcast/snapcast-0.29.0.ebuild
new file mode 100644
index 000000000000..cb0c73fe0d29
--- /dev/null
+++ b/media-sound/snapcast/snapcast-0.29.0.ebuild
@@ -0,0 +1,77 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Synchronous multi-room audio player"
+HOMEPAGE="https://github.com/badaix/snapcast"
+SRC_URI="https://github.com/badaix/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~riscv ~x86"
+IUSE="+client +expat +flac jack +opus +server tremor +vorbis +zeroconf"
+REQUIRED_USE="|| ( server client )"
+
+RDEPEND="
+ dev-libs/boost:=
+ media-libs/alsa-lib
+ client? ( acct-user/snapclient )
+ expat? ( dev-libs/expat )
+ flac? ( media-libs/flac:= )
+ jack? ( virtual/jack )
+ opus? ( media-libs/opus )
+ server? (
+ acct-group/snapserver
+ acct-user/snapserver
+ )
+ tremor? ( media-libs/tremor )
+ vorbis? ( media-libs/libvorbis )
+ zeroconf? ( net-dns/avahi[dbus] )
+"
+DEPEND="
+ ${RDEPEND}
+ >=dev-cpp/aixlog-1.2.1
+ >=dev-cpp/asio-1.12.1
+ >=dev-cpp/popl-1.2.0
+"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-resampler-include.patch
+ "${FILESDIR}"/${P}-boost-1.87.0-make_address.patch
+ "${FILESDIR}"/${P}-boost-1.87.0.patch
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_CLIENT=$(usex client)
+ -DBUILD_WITH_EXPAT=$(usex expat)
+ -DBUILD_WITH_FLAC=$(usex flac)
+ -DBUILD_WITH_JACK=$(usex jack)
+ -DBUILD_WITH_OPUS=$(usex opus)
+ -DBUILD_SERVER=$(usex server)
+ -DBUILD_STATIC_LIBS=no
+ -DBUILD_TESTS=no
+ -DBUILD_WITH_TREMOR=$(usex tremor)
+ -DBUILD_WITH_VORBIS=$(usex vorbis)
+ -DBUILD_WITH_AVAHI=$(usex zeroconf)
+ -DCMAKE_INSTALL_SYSCONFDIR="${EPREFIX}/etc"
+ )
+
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ for bin in server client ; do
+ if use ${bin} ; then
+ doman "${bin}/snap${bin}.1"
+
+ newconfd "${FILESDIR}/snap${bin}.confd" "snap${bin}"
+ newinitd "${FILESDIR}/snap${bin}.initd" "snap${bin}"
+ fi
+ done
+}