From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1544221-garchives=archives.gentoo.org@lists.gentoo.org>
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 663BF15800A
	for <garchives@archives.gentoo.org>; Tue,  8 Aug 2023 05:45:11 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 76B642BC018;
	Tue,  8 Aug 2023 05:45:10 +0000 (UTC)
Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 5BFB32BC018
	for <gentoo-commits@lists.gentoo.org>; Tue,  8 Aug 2023 05:45:10 +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 443A2335D60
	for <gentoo-commits@lists.gentoo.org>; Tue,  8 Aug 2023 05:45:09 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id A4EE1F2D
	for <gentoo-commits@lists.gentoo.org>; Tue,  8 Aug 2023 05:45:07 +0000 (UTC)
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" <sam@gentoo.org>
Message-ID: <1691473393.639d4a4dc311f12ab961e1d048f2e3e86ffc8413.sam@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: app-misc/detachtty/files/, app-misc/detachtty/
X-VCS-Repository: repo/gentoo
X-VCS-Files: app-misc/detachtty/detachtty-11.0.0-r1.ebuild app-misc/detachtty/files/detachtty-11.0.0-clang16-build-fix.patch
X-VCS-Directories: app-misc/detachtty/files/ app-misc/detachtty/
X-VCS-Committer: sam
X-VCS-Committer-Name: Sam James
X-VCS-Revision: 639d4a4dc311f12ab961e1d048f2e3e86ffc8413
X-VCS-Branch: master
Date: Tue,  8 Aug 2023 05:45:07 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 5aa22ae9-4c4c-40d2-b359-e8b2ef0caa21
X-Archives-Hash: 4cabcaade7b6f3049318dfea3edc7a7b

commit:     639d4a4dc311f12ab961e1d048f2e3e86ffc8413
Author:     Brahmajit Das <brahmajit.xyz <AT> gmail <DOT> com>
AuthorDate: Tue Aug  8 05:40:13 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Aug  8 05:43:13 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=639d4a4d

app-misc/detachtty: Fix call to undeclared library function strerror

And EAPI update from 7 to 8

Closes: https://bugs.gentoo.org/894544
Signed-off-by: Brahmajit Das <brahmajit.xyz <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/32159
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-misc/detachtty/detachtty-11.0.0-r1.ebuild      | 30 +++++++++++++++
 .../files/detachtty-11.0.0-clang16-build-fix.patch | 43 ++++++++++++++++++++++
 2 files changed, 73 insertions(+)

diff --git a/app-misc/detachtty/detachtty-11.0.0-r1.ebuild b/app-misc/detachtty/detachtty-11.0.0-r1.ebuild
new file mode 100644
index 000000000000..48a44f103550
--- /dev/null
+++ b/app-misc/detachtty/detachtty-11.0.0-r1.ebuild
@@ -0,0 +1,30 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit toolchain-funcs
+
+DESCRIPTION="Attach/detach from interactive processes across the network"
+HOMEPAGE="https://github.com/cosmos72/detachtty"
+SRC_URI="https://github.com/cosmos72/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+
+PATCHES=(
+	"${FILESDIR}/${P}-sparc.patch"
+	"${FILESDIR}/${P}-clang16-build-fix.patch"
+)
+
+src_compile() {
+	emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}"
+}
+
+src_install() {
+	dobin attachtty detachtty
+	doman "${PN}.1"
+	dosym detachtty.1 /usr/share/man/man1/attachtty.1
+	einstalldocs
+}

diff --git a/app-misc/detachtty/files/detachtty-11.0.0-clang16-build-fix.patch b/app-misc/detachtty/files/detachtty-11.0.0-clang16-build-fix.patch
new file mode 100644
index 000000000000..62a3cc1c3eb1
--- /dev/null
+++ b/app-misc/detachtty/files/detachtty-11.0.0-clang16-build-fix.patch
@@ -0,0 +1,43 @@
+Bug: https://bugs.gentoo.org/894544
+Upstream PR: https://github.com/cosmos72/detachtty/pull/6
+--- a/attachtty.c
++++ b/attachtty.c
+@@ -22,6 +22,7 @@
+ 
+ #include <errno.h>
+ #include <time.h>
++#include <string.h>
+ 
+ #include "config.h"
+ 
+--- a/config.h
++++ b/config.h
+@@ -24,7 +24,7 @@
+ #define DETACHTTY_CONFIG_H
+ 
+ #include <netdb.h>
+-#include <sys/poll.h>
++#include <poll.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>
+ #include <sys/un.h>
+--- a/copy-stream.c
++++ b/copy-stream.c
+@@ -23,6 +23,7 @@
+ #include <errno.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>
++#include <string.h>
+ 
+ #include "config.h"
+ 
+--- a/detachtty.c
++++ b/detachtty.c
+@@ -26,6 +26,7 @@
+ #include <sys/stat.h>
+ #include <pty.h>
+ #include <fcntl.h>
++#include <string.h>
+ 
+ #ifndef UNIX_PATH_MAX
+ # define UNIX_PATH_MAX    108