From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 0C649158009 for ; Fri, 23 Jun 2023 05:41:33 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 32F99E0805; Fri, 23 Jun 2023 05:41:32 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 180C9E0805 for ; Fri, 23 Jun 2023 05:41:32 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 24541340CC8 for ; Fri, 23 Jun 2023 05:41:31 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 7E87FA66 for ; Fri, 23 Jun 2023 05:41:29 +0000 (UTC) From: "Miroslav Šulc" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Miroslav Šulc" Message-ID: <1687498882.6b7f492e66ba9685d3b2634d2b3374f9c0d41c06.fordfrog@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: media-sound/orpheus/, media-sound/orpheus/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: media-sound/orpheus/files/orpheus-1.6-fix-build-w-clang-16.patch media-sound/orpheus/orpheus-1.6-r4.ebuild X-VCS-Directories: media-sound/orpheus/ media-sound/orpheus/files/ X-VCS-Committer: fordfrog X-VCS-Committer-Name: Miroslav Šulc X-VCS-Revision: 6b7f492e66ba9685d3b2634d2b3374f9c0d41c06 X-VCS-Branch: master Date: Fri, 23 Jun 2023 05:41:29 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 9301449a-ad9b-4879-bcaa-8932be9b5344 X-Archives-Hash: cfc047e949d60d324f6adbdac033a42a commit: 6b7f492e66ba9685d3b2634d2b3374f9c0d41c06 Author: Brahmajit Das gmail com> AuthorDate: Tue Jun 20 05:55:27 2023 +0000 Commit: Miroslav Šulc gentoo org> CommitDate: Fri Jun 23 05:41:22 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6b7f492e media-sound/orpheus: Fix build \w clang-16 Mainly dropping register storage class and replacing some functions which are removed in C++17. Signed-off-by: Brahmajit Das gmail.com> Closes: https://bugs.gentoo.org/897794 Closes: https://bugs.gentoo.org/740478 Closes: https://github.com/gentoo/gentoo/pull/31549 Signed-off-by: Miroslav Šulc gentoo.org> .../files/orpheus-1.6-fix-build-w-clang-16.patch | 87 ++++++++++++++++++++++ media-sound/orpheus/orpheus-1.6-r4.ebuild | 44 +++++++++++ 2 files changed, 131 insertions(+) diff --git a/media-sound/orpheus/files/orpheus-1.6-fix-build-w-clang-16.patch b/media-sound/orpheus/files/orpheus-1.6-fix-build-w-clang-16.patch new file mode 100644 index 000000000000..603b6767f250 --- /dev/null +++ b/media-sound/orpheus/files/orpheus-1.6-fix-build-w-clang-16.patch @@ -0,0 +1,87 @@ +Bug: https://bugs.gentoo.org/897794 +Some replacements for making it possible to be built with clang-16 +Some of the functions (for eample binary_function and bind1st) are removed in C++17 +--- a/kkconsui-0.1/src/texteditor.cc ++++ b/kkconsui-0.1/src/texteditor.cc +@@ -791,7 +791,8 @@ void texteditor::showline(int ln, int startx, int distance, int extrax) { + const char *p; + + if(!(cs = (char *) curfile->lines->at(ln))) return; +- char cp[i = (strlen(cs)+1)*4]; ++ i = (strlen(cs)+1)*4; ++ char cp[i]; + char buf[i]; + + eolstart = i; +--- a/kkstrtext-0.1/kkstrtext.cc ++++ b/kkstrtext-0.1/kkstrtext.cc +@@ -167,7 +167,7 @@ string toutf8(const string &text) { + } + + char *unmime(char *text) { +- register int s, d; ++ int s, d; + int htm; + + for(s = 0, d = 0; text[s] != 0; s++) { +@@ -185,7 +185,7 @@ char *unmime(char *text) { + } + + char *mime(char *dst, const char *src) { +- register int s, d; ++ int s, d; + char c; + + for(s = 0, d = 0; src[s]; s++) { +--- a/src/cdtrack.cc ++++ b/src/cdtrack.cc +@@ -45,8 +45,12 @@ int cdfd = -1, numtracks; + string cddbquery, cdid, cdtitle; + bool ejected = false; + +-struct istracknumber: public binary_function { +- public: bool operator()(int n, const track *c) const { ++struct istracknumber { ++ public: ++ using first_argument_type = int; ++ using second_argument_type = const track*; ++ using result_type = bool; ++ bool operator()(int n, const track *c) const { + const cdtrack *cdt = static_cast(c); + + if(cdt) { +@@ -104,7 +108,7 @@ vector cdtrack::getstatus() const { + + r.push_back("CD: " + cdtitle + "; " + buf); + +- it = find_if(plist.begin(), plist.end(), bind1st(istracknumber(), subc.cdsc_trk)); ++ it = find_if(plist.begin(), plist.end(), bind(istracknumber(), subc.cdsc_trk, std::placeholders::_1)); + + if(it != plist.end()) { + cdtrack *ct = static_cast(*it); +@@ -332,7 +336,7 @@ bool cdtrack::loadtracks(const string &fname) { + + } else if(param.substr(0, 6) == "TTITLE") { + ntrack = strtoul(param.substr(6).c_str(), 0, 0); +- it = find_if(plist.begin(), plist.end(), bind1st(istracknumber(), ntrack+1)); ++ it = find_if(plist.begin(), plist.end(), bind(istracknumber(), ntrack+1, std::placeholders::_1)); + + if(it != plist.end()) { + cdtrack *ct = static_cast(*it); +--- a/src/streamtrack.cc ++++ b/src/streamtrack.cc +@@ -283,8 +283,12 @@ string streamtrack::makerequest(const string &url) { + return reply; + } + +-struct equals_url: public binary_function { +- public: bool operator()(const char *aurl, const track *c) const { ++struct equals_url { ++ public: ++ using first_argument_type = const char*; ++ using second_argument_type = const track*; ++ using result_type = bool; ++ bool operator()(const char *aurl, const track *c) const { + const streamtrack *st = static_cast(c); + + if(st) { diff --git a/media-sound/orpheus/orpheus-1.6-r4.ebuild b/media-sound/orpheus/orpheus-1.6-r4.ebuild new file mode 100644 index 000000000000..493d42db27f7 --- /dev/null +++ b/media-sound/orpheus/orpheus-1.6-r4.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools + +DESCRIPTION="Command line MP3 player" +HOMEPAGE="http://konst.org.ua/en/orpheus" +SRC_URI="http://konst.org.ua/download/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" + +RDEPEND="sys-libs/ncurses:0= + media-libs/libvorbis + media-sound/mpg123 + media-sound/vorbis-tools[ogg123]" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}"/1.5-amd64.patch + "${FILESDIR}"/101_fix-buffer-overflow.diff + "${FILESDIR}"/${P}-fix-buildsystem.patch + "${FILESDIR}"/${P}-cppflags.patch + "${FILESDIR}"/${P}-bufsize.patch + "${FILESDIR}"/${P}-gcc47.patch + "${FILESDIR}"/${P}-constify.patch + "${FILESDIR}"/${P}-musl-stdint.patch + "${FILESDIR}"/${P}-fix-build-w-clang-16.patch +) + +src_prepare() { + default + + cp config.rpath kkstrtext-0.1/ || die + + mv configure.{in,ac} || die + mv kkstrtext-0.1/configure.{in,ac} || die + mv kkconsui-0.1/configure.{in,ac} || die + + eautoreconf +}