Gentoo Archives: gentoo-commits

From: Aaron Bauman <bman@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-text/pdf2html/files/, app-text/pdf2html/
Date: Sun, 30 Aug 2020 00:59:42
Message-Id: 1598749174.dc1bf48271799c32439727e29fd2738ebfdfaa8e.bman@gentoo
1 commit: dc1bf48271799c32439727e29fd2738ebfdfaa8e
2 Author: Aaron Bauman <bman <AT> gentoo <DOT> org>
3 AuthorDate: Sun Aug 30 00:58:54 2020 +0000
4 Commit: Aaron Bauman <bman <AT> gentoo <DOT> org>
5 CommitDate: Sun Aug 30 00:59:34 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dc1bf482
7
8 app-text/pdf2html: port to EAPI7
9
10 * Fix QA issues on echo calls
11 * Fix patches
12 * Use PATCHES=( )
13
14 Signed-off-by: Aaron Bauman <bman <AT> gentoo.org>
15
16 app-text/pdf2html/files/pdf2html-1.4-gentoo.patch | 4 ++--
17 .../pdf2html/files/pdf2html-1.4-libpng15.patch | 4 ++--
18 app-text/pdf2html/pdf2html-1.4.ebuild | 22 +++++++++++-----------
19 3 files changed, 15 insertions(+), 15 deletions(-)
20
21 diff --git a/app-text/pdf2html/files/pdf2html-1.4-gentoo.patch b/app-text/pdf2html/files/pdf2html-1.4-gentoo.patch
22 index 715b829b1c2..de1b4b4f379 100644
23 --- a/app-text/pdf2html/files/pdf2html-1.4-gentoo.patch
24 +++ b/app-text/pdf2html/files/pdf2html-1.4-gentoo.patch
25 @@ -1,5 +1,5 @@
26 ---- pbm2png.c.orig 2003-09-16 20:12:55.000000000 +0900
27 -+++ pbm2png.c 2004-02-21 22:09:57.415786664 +0900
28 +--- a/pbm2png.c
29 ++++ b/pbm2png.c
30 @@ -145,15 +145,13 @@
31 sprintf(string,"%s%d.html",basename,index);
32 f=fopen(string,"w");
33
34 diff --git a/app-text/pdf2html/files/pdf2html-1.4-libpng15.patch b/app-text/pdf2html/files/pdf2html-1.4-libpng15.patch
35 index 72a0e1b65af..7e5635332df 100644
36 --- a/app-text/pdf2html/files/pdf2html-1.4-libpng15.patch
37 +++ b/app-text/pdf2html/files/pdf2html-1.4-libpng15.patch
38 @@ -1,5 +1,5 @@
39 ---- pbm2png.c
40 -+++ pbm2png.c
41 +--- a/pbm2png.c
42 ++++ b/pbm2png.c
43 @@ -23,6 +23,7 @@
44 #include <stdlib.h>
45 #include <string.h>
46
47 diff --git a/app-text/pdf2html/pdf2html-1.4.ebuild b/app-text/pdf2html/pdf2html-1.4.ebuild
48 index 745c0256343..3dfc5cf3542 100644
49 --- a/app-text/pdf2html/pdf2html-1.4.ebuild
50 +++ b/app-text/pdf2html/pdf2html-1.4.ebuild
51 @@ -1,8 +1,9 @@
52 # Copyright 1999-2020 Gentoo Authors
53 # Distributed under the terms of the GNU General Public License v2
54
55 -EAPI=4
56 -inherit eutils toolchain-funcs
57 +EAPI=7
58 +
59 +inherit toolchain-funcs
60
61 DESCRIPTION="Converts pdf files to html files"
62 HOMEPAGE="http://atrey.karlin.mff.cuni.cz/~clock/twibright/pdf2html/"
63 @@ -19,22 +20,21 @@ RDEPEND="${DEPEND}
64 app-text/ghostscript-gpl
65 >=media-gfx/imagemagick-6"
66
67 -src_prepare() {
68 - epatch \
69 - "${FILESDIR}"/${P}-gentoo.patch \
70 - "${FILESDIR}"/${P}-libpng15.patch
71 -}
72 +PATCHES=(
73 + "${FILESDIR}"/${P}-gentoo.patch
74 + "${FILESDIR}"/${P}-libpng15.patch
75 +)
76
77 src_compile() {
78 tc-export CC
79 # Rewrite the Makefile as that's simpler
80 - echo "LDLIBS=-lpng" > Makefile
81 - echo "all: pbm2png" >> Makefile
82 + echo "LDLIBS=-lpng" > Makefile || die "echo failed"
83 + echo "all: pbm2png" >> Makefile || die "echo #2 failed"
84 emake
85 - echo "pbm2eps9: pbm2eps9.o printer.o" > Makefile
86 + echo "pbm2eps9: pbm2eps9.o printer.o" > Makefile || die "echo #3 failed"
87 emake pbm2eps9
88
89 - echo "cp \"${EPREFIX}\"/usr/share/${P}/*.png ." >> pdf2html
90 + echo "cp \"${EPREFIX}\"/usr/share/${P}/*.png ." >> pdf2html || die "echo #4 failed"
91 }
92
93 src_install() {