public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-sound/snapcast/files/, media-sound/snapcast/
Date: Thu, 29 Dec 2022 23:25:13 +0000 (UTC)	[thread overview]
Message-ID: <1672356198.08c2a7b554707f11b129914ff64c78256a782ffd.sam@gentoo> (raw)

commit:     08c2a7b554707f11b129914ff64c78256a782ffd
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 29 23:23:18 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Dec 29 23:23:18 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=08c2a7b5

media-sound/snapcast: fix build w/ boost-1.81

Closes: https://bugs.gentoo.org/886585
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/snapcast-0.26.0-boost-1.81.patch         | 51 +++++++++++++++
 media-sound/snapcast/snapcast-0.26.0-r2.ebuild     | 73 ++++++++++++++++++++++
 2 files changed, 124 insertions(+)

diff --git a/media-sound/snapcast/files/snapcast-0.26.0-boost-1.81.patch b/media-sound/snapcast/files/snapcast-0.26.0-boost-1.81.patch
new file mode 100644
index 000000000000..d9d691060b42
--- /dev/null
+++ b/media-sound/snapcast/files/snapcast-0.26.0-boost-1.81.patch
@@ -0,0 +1,51 @@
+https://bugs.gentoo.org/886585
+https://github.com/badaix/snapcast/commit/853c3f622ff2262b56681ee04dd20b4266c72493
+https://github.com/badaix/snapcast/issues/1082
+
+From 853c3f622ff2262b56681ee04dd20b4266c72493 Mon Sep 17 00:00:00 2001
+From: Rudi Heitbaum <rudi@heitbaum.com>
+Date: Wed, 21 Dec 2022 11:31:29 +0000
+Subject: [PATCH] server/control_session_http: update for boost 1.81.0
+
+Signed-off-by: Rudi Heitbaum <rudi@heitbaum.com>
+--- a/server/control_session_http.cpp
++++ b/server/control_session_http.cpp
+@@ -127,8 +127,8 @@ boost::beast::string_view mime_type(boost::beast::string_view path)
+ std::string path_cat(boost::beast::string_view base, boost::beast::string_view path)
+ {
+     if (base.empty())
+-        return path.to_string();
+-    std::string result = base.to_string();
++        return static_cast<std::string>(path);
++    std::string result = static_cast<std::string>(base);
+     char constexpr path_separator = '/';
+     if (result.back() == path_separator)
+         result.resize(result.size() - 1);
+@@ -171,7 +171,7 @@ void ControlSessionHttp::handle_request(http::request<Body, http::basic_fields<A
+         res.set(http::field::server, HTTP_SERVER_NAME);
+         res.set(http::field::content_type, "text/html");
+         res.keep_alive(req.keep_alive());
+-        res.body() = why.to_string();
++        res.body() = static_cast<std::string>(why);
+         res.prepare_payload();
+         return res;
+     };
+@@ -182,7 +182,7 @@ void ControlSessionHttp::handle_request(http::request<Body, http::basic_fields<A
+         res.set(http::field::server, HTTP_SERVER_NAME);
+         res.set(http::field::content_type, "text/html");
+         res.keep_alive(req.keep_alive());
+-        res.body() = "The resource '" + target.to_string() + "' was not found.";
++        res.body() = "The resource '" + static_cast<std::string>(target) + "' was not found.";
+         res.prepare_payload();
+         return res;
+     };
+@@ -204,7 +204,7 @@ void ControlSessionHttp::handle_request(http::request<Body, http::basic_fields<A
+         res.set(http::field::server, HTTP_SERVER_NAME);
+         res.set(http::field::content_type, "text/html");
+         res.keep_alive(req.keep_alive());
+-        res.body() = "An error occurred: '" + what.to_string() + "'";
++        res.body() = "An error occurred: '" + static_cast<std::string>(what) + "'";
+         res.prepare_payload();
+         return res;
+     };
+

diff --git a/media-sound/snapcast/snapcast-0.26.0-r2.ebuild b/media-sound/snapcast/snapcast-0.26.0-r2.ebuild
new file mode 100644
index 000000000000..cd5cede0e1b4
--- /dev/null
+++ b/media-sound/snapcast/snapcast-0.26.0-r2.ebuild
@@ -0,0 +1,73 @@
+# Copyright 1999-2022 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 +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:= )
+	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}-boost-1.81.patch
+)
+
+src_configure() {
+	local mycmakeargs=(
+		-DBUILD_CLIENT=$(usex client)
+		-DBUILD_WITH_EXPAT=$(usex expat)
+		-DBUILD_WITH_FLAC=$(usex flac)
+		-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
+}


             reply	other threads:[~2022-12-29 23:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-29 23:25 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-12-26  7:09 [gentoo-commits] repo/gentoo:master commit in: media-sound/snapcast/files/, media-sound/snapcast/ Sam James
2023-04-03  7:33 Jakov Smolić
2021-04-29 11:46 Michał Górny

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1672356198.08c2a7b554707f11b129914ff64c78256a782ffd.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox