summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-block/spindown/spindown-0.4.0-r5.ebuild')
-rw-r--r--sys-block/spindown/spindown-0.4.0-r5.ebuild26
1 files changed, 14 insertions, 12 deletions
diff --git a/sys-block/spindown/spindown-0.4.0-r5.ebuild b/sys-block/spindown/spindown-0.4.0-r5.ebuild
index ecc1c975e4cc..8d80fdb10e54 100644
--- a/sys-block/spindown/spindown-0.4.0-r5.ebuild
+++ b/sys-block/spindown/spindown-0.4.0-r5.ebuild
@@ -1,7 +1,9 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=8
+
+inherit toolchain-funcs
DESCRIPTION="Spindown is a daemon that can spin down idle disks"
HOMEPAGE="https://code.google.com/p/spindown"
@@ -10,33 +12,33 @@ SRC_URI="https://spindown.googlecode.com/files/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE=""
-DEPEND=""
-RDEPEND="${DEPEND}
- sys-apps/sg3_utils"
+RDEPEND="sys-apps/sg3_utils"
-src_prepare() {
- eapply "${FILESDIR}"/${P}-CFLAGS-LDFLAGS.patch
- eapply_user
-}
+PATCHES=(
+ "${FILESDIR}"/${P}-CFLAGS-LDFLAGS.patch
+ "${FILESDIR}"/${P}-Makefile.patch
+ "${FILESDIR}"/${P}-musl-time-include.patch
+)
src_compile() {
- emake
+ emake CXX="$(tc-getCXX)"
}
src_install() {
insinto /etc
newins spindown.conf.example spindown.conf
+
newinitd "${FILESDIR}"/spindownd.initd-r1 spindownd
newconfd "${FILESDIR}"/spindownd.confd-r1 spindownd
+
dosbin spindownd
dodoc CHANGELOG README TODO spindown.conf.example
}
pkg_postinst() {
elog "Before starting spindownd the first time"
- elog "you should modify /etc/spindown.conf"
+ elog "you should modify ${EROOT}/etc/spindown.conf"
elog
elog "To start spindownd by default"
elog "you should add it to the default runlevel:"