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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 4412B138330 for ; Thu, 4 Jan 2018 23:18:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6C74DE0A8E; Thu, 4 Jan 2018 23:18:57 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 3F9C0E0A8E for ; Thu, 4 Jan 2018 23:18:57 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B04BE335C39 for ; Thu, 4 Jan 2018 23:18:55 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 38B6117B for ; Thu, 4 Jan 2018 23:18:54 +0000 (UTC) From: "Sven Wegener" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Wegener" Message-ID: <1515107920.2aacf8d5e4052441f9bb791051a30146bf65793e.swegener@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-misc/screen/files/, app-misc/screen/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-misc/screen/files/screen-4.4.0-utmp-musl.patch app-misc/screen/screen-4.4.0.ebuild X-VCS-Directories: app-misc/screen/files/ app-misc/screen/ X-VCS-Committer: swegener X-VCS-Committer-Name: Sven Wegener X-VCS-Revision: 2aacf8d5e4052441f9bb791051a30146bf65793e X-VCS-Branch: master Date: Thu, 4 Jan 2018 23:18:54 +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-Archives-Salt: ce427cec-714d-4397-ae41-e5b43cd1c169 X-Archives-Hash: 92ac381e5fd07e1865aeb588e499f162 commit: 2aacf8d5e4052441f9bb791051a30146bf65793e Author: Sven Wegener gentoo org> AuthorDate: Thu Jan 4 23:15:15 2018 +0000 Commit: Sven Wegener gentoo org> CommitDate: Thu Jan 4 23:18:40 2018 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2aacf8d5 app-misc/screen: Fix building on musl libc, bug #639424 Closes: https://bugs.gentoo.org/639424 Package-Manager: Portage-2.3.14, Repoman-2.3.6 app-misc/screen/files/screen-4.4.0-utmp-musl.patch | 62 ++++++++++++++++++++++ app-misc/screen/screen-4.4.0.ebuild | 3 +- 2 files changed, 64 insertions(+), 1 deletion(-) diff --git a/app-misc/screen/files/screen-4.4.0-utmp-musl.patch b/app-misc/screen/files/screen-4.4.0-utmp-musl.patch new file mode 100644 index 00000000000..990c73042cd --- /dev/null +++ b/app-misc/screen/files/screen-4.4.0-utmp-musl.patch @@ -0,0 +1,62 @@ +From 74fdc8988b55633cd05f8625390cd3f6a8102003 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Amadeusz=20S=C5=82awi=C5=84ski?= +Date: Sat, 13 Jun 2015 17:52:46 +0200 +Subject: [PATCH] change checks for utmp/utmpx in header + +linuxes should've working utmpx, so this check was bit weird +commit 2b1bdf96 mentions some "linux workaround", but nothing specific + +fixes build with musl libc +--- + os.h | 7 ++++--- + utmp.c | 4 ++-- + 2 files changed, 6 insertions(+), 5 deletions(-) + +diff --git a/os.h b/os.h +index 55de249..e827ac9 100644 +--- a/os.h ++++ b/os.h +@@ -250,9 +250,11 @@ extern int errno; + #endif + + #if defined(UTMPOK) || defined(BUGGYGETLOGIN) +-# if defined(SVR4) && !defined(DGUX) && !defined(__hpux) && !defined(linux) ++# if defined(SVR4) && !defined(DGUX) && !defined(__hpux) + # include +-# define UTMPFILE UTMPX_FILE ++# ifdef UTMPX_FILE /* GNU extension */ ++# define UTMPFILE UTMPX_FILE ++# endif + # define utmp utmpx + # define getutent getutxent + # define getutid getutxid +@@ -260,7 +262,6 @@ extern int errno; + # define pututline pututxline + # define setutent setutxent + # define endutent endutxent +-# define ut_time ut_xtime + # else /* SVR4 */ + # include + # endif /* SVR4 */ +diff --git a/utmp.c b/utmp.c +index fa8b87b..f5d7db8 100644 +--- a/utmp.c ++++ b/utmp.c +@@ -631,7 +631,7 @@ int pid; + /* must use temp variable because of NetBSD/sparc64, where + * ut_xtime is long(64) but time_t is int(32) */ + (void)time(&now); +- u->ut_time = now; ++ u->ut_tv.tv_sec = now; + } + + static slot_t +@@ -743,7 +743,7 @@ int pid; + strncpy(u->ut_line, line, sizeof(u->ut_line)); + strncpy(u->ut_name, user, sizeof(u->ut_name)); + (void)time(&now); +- u->ut_time = now; ++ u->ut_tv.tv_sec = now; + } + + static slot_t diff --git a/app-misc/screen/screen-4.4.0.ebuild b/app-misc/screen/screen-4.4.0.ebuild index 0ee4276016c..0dfbfbc066c 100644 --- a/app-misc/screen/screen-4.4.0.ebuild +++ b/app-misc/screen/screen-4.4.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=5 @@ -26,6 +26,7 @@ DEPEND="${CDEPEND} # - Don't use utempter even if it is found on the system. PATCHES=( "${FILESDIR}"/${PN}-4.3.0-no-utempter.patch + "${FILESDIR}"/${P}-utmp-musl.patch ) pkg_setup() {