gentoo/dev-util/lockrun/lockrun-20240415.ebuild
Sam James e0eb2b139d
dev-util/lockrun: Stabilize 20240415 x86, #936582
Signed-off-by: Sam James <sam@gentoo.org>
2024-07-24 10:26:55 +01:00

38 lines
939 B
Bash

# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
DESCRIPTION="Run cronjobs with overrun protection"
HOMEPAGE="http://www.unixwiz.net/tools/lockrun.html"
SRC_URI="https://downloads.uls.co.za/gentoo/lockrun/lockrun-${PV}.c.gz"
S="${WORKDIR}"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="amd64 ~hppa x86"
src_prepare() {
default
mv "${P}.c" "${PN}.c" || die
}
src_compile() {
emake CC="$(tc-getCC)" ${PN}
# The below tries to extract the first comment block from the source code
# which represents the official "readme" from the project. Delete first
# three lines, then everything from (including) the first comment close at
# the beginning of a line before removing ' *' from the beginning of the
# remaining lines.
sed '1,3 d; /^[[:space:]]*[*]\//,$ d; s/^ \*//' "${PN}.c" > README || die
}
src_install() {
dobin ${PN}
einstalldocs
}