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 608F4158020 for ; Sun, 6 Nov 2022 03:12:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9267AE0769; Sun, 6 Nov 2022 03:12:22 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.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 71E29E075F for ; Sun, 6 Nov 2022 03:12:22 +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)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 4583934109E for ; Sun, 6 Nov 2022 03:12:21 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id CA3FE609 for ; Sun, 6 Nov 2022 03:12:19 +0000 (UTC) From: "Mike Gilbert" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Mike Gilbert" Message-ID: <1667703471.55054c304dbdfbdce6cfa5555fa26bfd0066a1df.floppym@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/ncurses/ X-VCS-Repository: repo/gentoo X-VCS-Files: sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild sys-libs/ncurses/ncurses-6.3_p20220924.ebuild X-VCS-Directories: sys-libs/ncurses/ X-VCS-Committer: floppym X-VCS-Committer-Name: Mike Gilbert X-VCS-Revision: 55054c304dbdfbdce6cfa5555fa26bfd0066a1df X-VCS-Branch: master Date: Sun, 6 Nov 2022 03:12:19 +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: f4224890-2ae4-44a8-81d6-1868b8c484f5 X-Archives-Hash: 6268a99343ea5d28e54a596c933676be commit: 55054c304dbdfbdce6cfa5555fa26bfd0066a1df Author: Matt Whitlock mattwhitlock name> AuthorDate: Thu Oct 27 12:53:05 2022 +0000 Commit: Mike Gilbert gentoo org> CommitDate: Sun Nov 6 02:57:51 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55054c30 sys-libs/ncurses: don't populate /etc/terminfo/ when USE="-split-usr" The rationale for moving the terminfo files for some common terminals into /etc/terminfo/ was stated in bug #37026: "ncurses, unlike termcap, stores its terminfo database in '/usr/share'... which may not be available until all file systems are mounted." With merged-/usr this is no longer a concern, and, moreover, moving some terminfo files out into /etc undermines a core motivation of merged-/usr, which is to situate a complete system image within /usr. This commit preserves the existing behavior when USE="split-usr" but eliminates the move of common terminfo files into /etc/terminfo/ when USE="-split-usr". Signed-off-by: Matt Whitlock mattwhitlock.name> Closes: https://github.com/gentoo/gentoo/pull/27988 Signed-off-by: Mike Gilbert gentoo.org> sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild | 47 ++++++++++++++---------- sys-libs/ncurses/ncurses-6.3_p20220924.ebuild | 47 ++++++++++++++---------- 2 files changed, 54 insertions(+), 40 deletions(-) diff --git a/sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild b/sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild index f9e5093a7eb1..d7f85fe0f003 100644 --- a/sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild +++ b/sys-libs/ncurses/ncurses-6.3_p20220924-r1.ebuild @@ -415,8 +415,6 @@ multilib_src_install() { } multilib_src_install_all() { - # We need the basic terminfo files in /etc for embedded/recovery, bug #37026 - einfo "Installing basic terminfo files in /etc..." local terms=( # Dumb/simple values that show up when using the in-kernel VT. ansi console dumb linux @@ -430,25 +428,34 @@ multilib_src_install_all() { screen{,-256color} screen.xterm-256color ) - local x - for x in "${terms[@]}"; do - local termfile=$(find "${ED}"/usr/share/terminfo/ -name "${x}" 2>/dev/null) - local basedir=$(basename "$(dirname "${termfile}")") - - if [[ -n ${termfile} ]] ; then - dodir "/etc/terminfo/${basedir}" - mv "${termfile}" "${ED}/etc/terminfo/${basedir}/" || die - dosym "../../../../etc/terminfo/${basedir}/${x}" \ - "/usr/share/terminfo/${basedir}/${x}" - fi - done - - echo "CONFIG_PROTECT_MASK=\"/etc/terminfo\"" | newenvd - 50ncurses + if use split-usr ; then + local x + # We need the basic terminfo files in /etc for embedded/recovery, bug #37026 + einfo "Installing basic terminfo files in /etc..." + for x in "${terms[@]}"; do + local termfile=$(find "${ED}"/usr/share/terminfo/ -name "${x}" 2>/dev/null) + local basedir=$(basename "$(dirname "${termfile}")") + + if [[ -n ${termfile} ]] ; then + dodir "/etc/terminfo/${basedir}" + mv "${termfile}" "${ED}/etc/terminfo/${basedir}/" || die + dosym "../../../../etc/terminfo/${basedir}/${x}" \ + "/usr/share/terminfo/${basedir}/${x}" + fi + done - use minimal && rm -r "${ED}"/usr/share/terminfo* - # Because ncurses5-config --terminfo returns the directory we keep it - # bug #245374 - keepdir /usr/share/terminfo + echo "CONFIG_PROTECT_MASK=\"/etc/terminfo\"" | newenvd - 50ncurses + + use minimal && rm -r "${ED}"/usr/share/terminfo* + # Because ncurses5-config --terminfo returns the directory we keep it + # bug #245374 + keepdir /usr/share/terminfo + elif use minimal ; then + # Keep only the basic terminfo files + find "${ED}"/usr/share/terminfo/ \ + -type f ${terms[*]/#/! -name } -delete , \ + -type d -empty -delete || die + fi cd "${S}" || die dodoc ANNOUNCE MANIFEST NEWS README* TO-DO doc/*.doc diff --git a/sys-libs/ncurses/ncurses-6.3_p20220924.ebuild b/sys-libs/ncurses/ncurses-6.3_p20220924.ebuild index 9a7f05e0fcb6..9ff5fd9601d3 100644 --- a/sys-libs/ncurses/ncurses-6.3_p20220924.ebuild +++ b/sys-libs/ncurses/ncurses-6.3_p20220924.ebuild @@ -413,8 +413,6 @@ multilib_src_install() { } multilib_src_install_all() { - # We need the basic terminfo files in /etc for embedded/recovery, bug #37026 - einfo "Installing basic terminfo files in /etc..." local terms=( # Dumb/simple values that show up when using the in-kernel VT. ansi console dumb linux @@ -428,25 +426,34 @@ multilib_src_install_all() { screen{,-256color} screen.xterm-256color ) - local x - for x in "${terms[@]}"; do - local termfile=$(find "${ED}"/usr/share/terminfo/ -name "${x}" 2>/dev/null) - local basedir=$(basename "$(dirname "${termfile}")") - - if [[ -n ${termfile} ]] ; then - dodir "/etc/terminfo/${basedir}" - mv "${termfile}" "${ED}/etc/terminfo/${basedir}/" || die - dosym "../../../../etc/terminfo/${basedir}/${x}" \ - "/usr/share/terminfo/${basedir}/${x}" - fi - done - - echo "CONFIG_PROTECT_MASK=\"/etc/terminfo\"" | newenvd - 50ncurses + if use split-usr ; then + local x + # We need the basic terminfo files in /etc for embedded/recovery, bug #37026 + einfo "Installing basic terminfo files in /etc..." + for x in "${terms[@]}"; do + local termfile=$(find "${ED}"/usr/share/terminfo/ -name "${x}" 2>/dev/null) + local basedir=$(basename "$(dirname "${termfile}")") + + if [[ -n ${termfile} ]] ; then + dodir "/etc/terminfo/${basedir}" + mv "${termfile}" "${ED}/etc/terminfo/${basedir}/" || die + dosym "../../../../etc/terminfo/${basedir}/${x}" \ + "/usr/share/terminfo/${basedir}/${x}" + fi + done - use minimal && rm -r "${ED}"/usr/share/terminfo* - # Because ncurses5-config --terminfo returns the directory we keep it - # bug #245374 - keepdir /usr/share/terminfo + echo "CONFIG_PROTECT_MASK=\"/etc/terminfo\"" | newenvd - 50ncurses + + use minimal && rm -r "${ED}"/usr/share/terminfo* + # Because ncurses5-config --terminfo returns the directory we keep it + # bug #245374 + keepdir /usr/share/terminfo + elif use minimal ; then + # Keep only the basic terminfo files + find "${ED}"/usr/share/terminfo/ \ + -type f ${terms[*]/#/! -name } -delete , \ + -type d -empty -delete || die + fi cd "${S}" || die dodoc ANNOUNCE MANIFEST NEWS README* TO-DO doc/*.doc