diff options
author | David Seifert <soap@gentoo.org> | 2020-01-21 22:50:54 +0100 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2020-01-21 22:50:54 +0100 |
commit | 5cea0fd1a495aac3d76cb33f7c3ed594bd4a3cd7 (patch) | |
tree | 51a31e3e0628f2cda8d37588ce6316c355daf537 /app-text | |
parent | app-text/o3read: Port to EAPI 7 (diff) | |
download | gentoo-5cea0fd1a495aac3d76cb33f7c3ed594bd4a3cd7.tar.gz gentoo-5cea0fd1a495aac3d76cb33f7c3ed594bd4a3cd7.tar.bz2 gentoo-5cea0fd1a495aac3d76cb33f7c3ed594bd4a3cd7.zip |
app-text/mpage: Port to EAPI 7
Package-Manager: Portage-2.3.84, Repoman-2.3.20
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'app-text')
-rw-r--r-- | app-text/mpage/files/mpage-2.5.6-fix-buildsystem.patch | 43 | ||||
-rw-r--r-- | app-text/mpage/mpage-2.5.6-r1.ebuild | 47 |
2 files changed, 69 insertions, 21 deletions
diff --git a/app-text/mpage/files/mpage-2.5.6-fix-buildsystem.patch b/app-text/mpage/files/mpage-2.5.6-fix-buildsystem.patch new file mode 100644 index 000000000000..790d49880649 --- /dev/null +++ b/app-text/mpage/files/mpage-2.5.6-fix-buildsystem.patch @@ -0,0 +1,43 @@ +--- a/Makefile ++++ b/Makefile +@@ -24,7 +24,6 @@ + # Set this to an ANSI compatible C compiler (preferably gcc) + # See also system specific settings below + #CC=cc +-CC=gcc + + ############################################################################ + # +@@ -107,7 +106,7 @@ + # If you are using gcc, you probably don't need to change anything here. + + # Linux: +-CFLAGS = -O2 -s $(DEFS) -Wall ++CPPFLAGS += $(DEFS) + + # AIX (xlC on aix 4): + #CFLAGS = -O2 -s $(DEFS) +@@ -134,10 +133,6 @@ + # END OF CONFIGURATION OPTIONS + # + +-# pattern rules. Should we define these? +-%$(O): %.c +- $(CC) $(CFLAGS) -c -o $@ $< +- + + HEAD = mpage.h + DENC = encoding.h +@@ -150,10 +145,10 @@ + @echo Done! + + mpage$(E): $(MOBJ) +- $(CC) $(CFLAGS) -o mpage$(E) $(MOBJ) $(LIBS) ++ $(CC) $(LDFLAGS) $(CFLAGS) -o mpage$(E) $(MOBJ) $(LIBS) + + msample$(E): $(SOBJ) +- $(CC) $(CFLAGS) -o msample$(E) $(SOBJ) $(LIBS) ++ $(CC) $(LDFLAGS) $(CFLAGS) -o msample$(E) $(SOBJ) $(LIBS) + + mpage.1: mpage.1.in + sed 's:PREFIX:${PREFIX}:' < mpage.1.in > mpage.1 diff --git a/app-text/mpage/mpage-2.5.6-r1.ebuild b/app-text/mpage/mpage-2.5.6-r1.ebuild index 0b6a0146109e..6ab60421dd8f 100644 --- a/app-text/mpage/mpage-2.5.6-r1.ebuild +++ b/app-text/mpage/mpage-2.5.6-r1.ebuild @@ -1,39 +1,44 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=4 -inherit eutils toolchain-funcs +EAPI=7 + +inherit toolchain-funcs DESCRIPTION="Many to one page printing utility" HOMEPAGE="http://www.mesa.nl/" -SRC_URI="http://www.mesa.nl/pub/${PN}/${P}.tgz +SRC_URI=" + http://www.mesa.nl/pub/${PN}/${P}.tgz https://dev.gentoo.org/~mgorny/dist/${P}-gentoo-patchset.tar.bz2" -KEYWORDS="amd64 ppc x86" LICENSE="freedist" SLOT="0" -IUSE="" - -src_prepare() { - sed -i Makefile \ - -e '/^CFLAGS/s|=.*| += $(DEFS)|g' \ - -e 's|$(CFLAGS) -o|$(LDFLAGS) &|g' \ - || die "sed Makefile" - EPATCH_SOURCE="${WORKDIR}/${P}-gentoo-patchset" epatch \ - 01_previous_changes.patch 10_bts354935_fix_fontdefs.patch \ - 20_bts416573_manpage_fixes.patch 30_bts443280_libdir_manpage.patch +KEYWORDS="amd64 ppc x86" + +PATCHES=( + "${FILESDIR}"/${P}-fix-buildsystem.patch + "${WORKDIR}"/${P}-gentoo-patchset/01_previous_changes.patch + "${WORKDIR}"/${P}-gentoo-patchset/10_bts354935_fix_fontdefs.patch + "${WORKDIR}"/${P}-gentoo-patchset/20_bts416573_manpage_fixes.patch + "${WORKDIR}"/${P}-gentoo-patchset/30_bts443280_libdir_manpage.patch +) + +src_configure() { + tc-export CC } src_compile() { emake \ - CC="$(tc-getCC)" \ - PREFIX=/usr \ - MANDIR=/usr/share/man/man1 + PREFIX="${EPREFIX}"/usr \ + MANDIR="${EPREFIX}"/usr/share/man/man1 } src_install () { emake \ - PREFIX="${D}/usr" \ - MANDIR="${D}/usr/share/man/man1" install - dodoc CHANGES Encoding.format FAQ NEWS README TODO + PREFIX="${ED}"/usr \ + MANDIR="${ED}"/usr/share/man/man1 install + + rm README.{amiga,OS2} || die + einstalldocs + dodoc Encoding.format } |