public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/musl:master commit in: sys-apps/groff/
@ 2021-04-29 18:43 Dave Hughes
  0 siblings, 0 replies; only message in thread
From: Dave Hughes @ 2021-04-29 18:43 UTC (permalink / raw
  To: gentoo-commits

commit:     0c804b717e08ad88119724f87b62669cc34e8b92
Author:     Dave Hughes <davidhughes205 <AT> gmail <DOT> com>
AuthorDate: Thu Apr 29 18:43:36 2021 +0000
Commit:     Dave Hughes <davidhughes205 <AT> gmail <DOT> com>
CommitDate: Thu Apr 29 18:43:36 2021 +0000
URL:        https://gitweb.gentoo.org/proj/musl.git/commit/?id=0c804b71

sys-apps/groff: sync with ::gentoo

Package-Manager: Portage-3.0.18, Repoman-3.0.3
Signed-off-by: Dave Hughes <davidhughes205 <AT> gmail.com>

 sys-apps/groff/groff-1.22.4.ebuild | 55 ++++++++++++++++++++------------------
 sys-apps/groff/metadata.xml        |  3 +++
 2 files changed, 32 insertions(+), 26 deletions(-)

diff --git a/sys-apps/groff/groff-1.22.4.ebuild b/sys-apps/groff/groff-1.22.4.ebuild
index 0363bf1..195f215 100644
--- a/sys-apps/groff/groff-1.22.4.ebuild
+++ b/sys-apps/groff/groff-1.22.4.ebuild
@@ -1,7 +1,7 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
+EAPI=7
 
 inherit toolchain-funcs
 
@@ -10,24 +10,26 @@ MY_P="${P/_/.}"
 DESCRIPTION="Text formatter used for man pages"
 HOMEPAGE="https://www.gnu.org/software/groff/groff.html"
 SRC_URI="mirror://gnu/groff/${MY_P}.tar.gz
-	mirror://gnu-alpha/groff/${MY_P}.tar.gz"
+	https://alpha.gnu.org/gnu/groff/${MY_P}.tar.gz"
 
 LICENSE="GPL-2"
 SLOT="0"
 [[ "${PV}" == *_rc* ]] || \
-KEYWORDS="~amd64 ~arm ~arm64 ~mips ~ppc ~ppc64 ~x86"
-IUSE="examples X"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="examples uchardet X"
 
 RDEPEND="
+	uchardet? ( app-i18n/uchardet )
 	X? (
+		x11-libs/libICE
+		x11-libs/libSM
 		x11-libs/libX11
-		x11-libs/libXt
-		x11-libs/libXmu
 		x11-libs/libXaw
-		x11-libs/libSM
-		x11-libs/libICE
+		x11-libs/libXmu
+		x11-libs/libXt
 	)"
-DEPEND="${RDEPEND}
+DEPEND="${RDEPEND}"
+BDEPEND="
 	dev-lang/perl
 	sys-apps/texinfo"
 
@@ -37,14 +39,17 @@ S="${WORKDIR}/${MY_P}"
 
 PATCHES=(
 	"${FILESDIR}"/${PN}-1.19.2-man-unicode-dashes.patch #16108 #17580 #121502
-	"${FILESDIR}"/${PN}-1.22.4-musl.patch
 )
 
 src_prepare() {
 	default
 
+	if use elibc_musl ; then
+		eapply "${FILESDIR}"/${PN}-1.22.4-musl.patch
+	fi
+
 	# honor Gentoo's docdir
-	sed -i -e "s|^docdir =.*|docdir = \"${EPREFIX%/}/usr/share/doc/${PF}\"|g" \
+	sed -i -e "s|^docdir =.*|docdir = \"${EPREFIX}/usr/share/doc/${PF}\"|g" \
 		Makefile.in \
 		|| die "failed to modify Makefile.in"
 
@@ -62,23 +67,21 @@ src_prepare() {
 
 src_configure() {
 	local myeconfargs=(
-		--with-appresdir="${EPREFIX%/}"/usr/share/X11/app-defaults
+		--with-appresdir="${EPREFIX}"/usr/share/X11/app-defaults
+		$(use_with uchardet)
 		$(use_with X x)
 	)
 	econf "${myeconfargs[@]}"
 }
 
 src_compile() {
-	if tc-is-cross-compiler ; then
-		local CROSS_ARGS=(
-			GROFFBIN="$(type -P groff)"
-			TROFFBIN="$(type -P troff)"
-			GROFF_BIN_DIR=
-			GROFF_BIN_PATH=
-		)
-	else
-		unset CROSS_ARGS
-	fi
+	local -a CROSS_ARGS
+	tc-is-cross-compiler && CROSS_ARGS+=(
+		GROFFBIN="$(type -P groff)"
+		TROFFBIN="$(type -P troff)"
+		GROFF_BIN_DIR=
+		GROFF_BIN_PATH=
+	)
 
 	emake AR="$(tc-getAR)" "${CROSS_ARGS[@]}"
 }
@@ -92,11 +95,11 @@ src_install() {
 
 	if ! use examples ; then
 		# The pdf files might not be generated if ghostscript is unavailable. #602020
-		local pdf="${ED%/}/usr/share/doc/${PF}/examples/mom/mom-pdf.pdf"
+		local pdf="${ED}/usr/share/doc/${PF}/examples/mom/mom-pdf.pdf"
 		if [[ -e ${pdf} ]] ; then
 			# Keep mom-pdf.pdf since it's more of a manual than an example. #454196 #516732
-			mv "${pdf}" "${ED%/}"/usr/share/doc/${PF}/pdf/ || die
+			mv "${pdf}" "${ED}/usr/share/doc/${PF}/pdf/" || die
 		fi
-		rm -rf "${ED%/}"/usr/share/doc/${PF}/examples
+		rm -rf "${ED}/usr/share/doc/${PF}/examples"
 	fi
 }

diff --git a/sys-apps/groff/metadata.xml b/sys-apps/groff/metadata.xml
index 56c1244..b96055e 100644
--- a/sys-apps/groff/metadata.xml
+++ b/sys-apps/groff/metadata.xml
@@ -5,4 +5,7 @@
 	<email>base-system@gentoo.org</email>
 	<name>Gentoo Base System</name>
 </maintainer>
+<use>
+	<flag name="uchardet">Enable automatic encoding detection via <pkg>app-i18n/uchardet</pkg></flag>
+</use>
 </pkgmetadata>


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-29 18:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-29 18:43 [gentoo-commits] proj/musl:master commit in: sys-apps/groff/ Dave Hughes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox