commit:     e7df428d08545663e21e1a5e8d60c1e1b51cd721
Author:     Filip Kobierski <fkobi <AT> pm <DOT> me>
AuthorDate: Mon Jun 16 12:29:24 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Jun 22 15:37:13 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e7df428d

app-misc/muttprint: minor improvements

- bump EAPI
- remove -e from sed where it's not nescessary
- localize for loop variable
- make for loop one line long
- remove stray space from if clause
- limit concurrency only if USE=doc
- remove src_install

Signed-off-by: Filip Kobierski <fkobi <AT> pm.me>
Part-of: https://github.com/gentoo/gentoo/pull/42624
Closes: https://github.com/gentoo/gentoo/pull/42624
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-misc/muttprint/muttprint-0.73-r6.ebuild | 79 +++++++++++++++++++++++++++++
 1 file changed, 79 insertions(+)

diff --git a/app-misc/muttprint/muttprint-0.73-r6.ebuild 
b/app-misc/muttprint/muttprint-0.73-r6.ebuild
new file mode 100644
index 000000000000..61521c60dd66
--- /dev/null
+++ b/app-misc/muttprint/muttprint-0.73-r6.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="Script for pretty printing of your mails"
+HOMEPAGE="https://muttprint.sourceforge.net";
+SRC_URI="https://downloads.sourceforge.net/muttprint/${P}.tar.gz";
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+IUSE="doc"
+
+BDEPEND="
+       dev-texlive/texlive-fontsextra
+       dev-lang/perl
+       virtual/latex-base
+       doc? (
+               app-text/dvipsk
+               app-text/docbook-sgml-utils[jadetex]
+       )
+"
+RDEPEND="
+       dev-texlive/texlive-latexextra
+       dev-lang/perl
+       dev-perl/TimeDate
+       dev-perl/Text-Iconv
+       virtual/latex-base
+"
+
+PATCHES=(
+       "${FILESDIR}/${P}-warning.patch"
+       "${FILESDIR}/${P}-manuals.patch"
+       "${FILESDIR}/${P}-pod-encoding.patch"
+       "${FILESDIR}/${P}-fix-number-of-pages.patch"
+)
+
+patch_docs() {
+       sed -i 's/db2pdf/docbook2pdf/' "${S}"/configure.ac || die
+       local i
+       for l in de en es it sl; do
+               sed -i -e "/^docdir/s/$/-${PV}/" \
+                       -e 's/db2/docbook2/' -e 's/ -s / -d /' \
+                       -e "s|manual-${l}-sed/||" \
+                       -e "s/mv manual-${l}-sed.dvi/cp manual-${l}-sed.dvi/" \
+                       "${S}"/doc/manual/${l}/Makefile.am || die
+       done
+}
+
+src_prepare() {
+       default
+
+       if use doc; then
+               # Patch docbook and docdir
+               patch_docs
+       else
+               # Don't do manuals
+               sed -i '/db2pdf/d' "${S}"/configure.ac || die
+       fi
+
+       sed -i "/^docdir/s/$/-${PVR}/" "${S}"/Makefile.am || die
+
+       # The distfile does not include the png files, nor penguin.jpg
+       sed -i -e '/.*png /d' -e '/penguin.jpg /d' "${S}"/pics/Makefile.am || 
die
+
+       eautoreconf
+}
+
+src_compile() {
+       # Parallel build does not work when USE="doc"
+       if use doc; then
+               emake
+       else
+               emake -j1
+       fi
+}

Reply via email to