app-text/code2html: port to EAPI 7

Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James 2021-04-19 12:22:04 +01:00
parent 198244e0d5
commit 7bc6857c8b
No known key found for this signature in database
GPG Key ID: F4922810EEA0483B
3 changed files with 18 additions and 15 deletions

View File

@ -1,9 +1,9 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=5
EAPI=7
inherit epatch prefix
inherit prefix
DESCRIPTION="Converts source files to colored HTML output"
HOMEPAGE="http://www.palfrader.org/code2html/"
@ -13,27 +13,30 @@ SRC_URI="http://www.palfrader.org/code2html/all/${P}.tar.gz
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 ~hppa ppc ppc64 x86 ~amd64-linux ~x86-linux ~ppc-macos"
IUSE=""
DEPEND=""
RDEPEND=">=dev-lang/perl-5"
src_prepare() {
PATCHES=(
# Be consistent in color codes (bug #119406)
epatch "${WORKDIR}"/${P}-lowercase_color_codes.patch
"${WORKDIR}"/${P}-lowercase_color_codes.patch
# Improved C++ support (bug #133159)
epatch "${WORKDIR}"/${P}-cpp_keywords.patch
"${WORKDIR}"/${P}-cpp_keywords.patch
# Improved Ada support (bug #133176)
epatch "${WORKDIR}"/${P}-ada_identifiers.patch
"${WORKDIR}"/${P}-ada_identifiers.patch
# For prefix paths
epatch "${FILESDIR}"/${P}-prefix.patch
eprefixify code2html
"${FILESDIR}"/${P}-prefix.patch
# For newer Perl, bug 523610
epatch "${FILESDIR}"/${P}-scalar.patch
"${FILESDIR}"/${P}-scalar.patch
)
src_prepare() {
default
eprefixify code2html
}
src_install() {

View File

@ -1,5 +1,5 @@
--- code2html
+++ code2html
--- a/code2html
+++ b/code2html
@@ -1,4 +1,4 @@
-#!/usr/bin/perl -w
+#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl -w

View File

@ -1,5 +1,5 @@
--- code2html.orig 2002-01-12 22:17:02.000000000 +0100
+++ code2html 2014-09-24 13:52:52.000000000 +0200
--- a/code2html
+++ b/code2html
@@ -1357,7 +1357,7 @@
my @lines = split ( /\n/, $_[0] );