* [gentoo-commits] repo/gentoo:master commit in: sys-block/spindown/files/, sys-block/spindown/
@ 2016-04-29 17:38 Austin English
0 siblings, 0 replies; 2+ messages in thread
From: Austin English @ 2016-04-29 17:38 UTC (permalink / raw
To: gentoo-commits
commit: 3b9b96be4fb14e9510861752387d94ce9d0a8345
Author: Austin English <wizardedit <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 29 17:35:58 2016 +0000
Commit: Austin English <wizardedit <AT> gentoo <DOT> org>
CommitDate: Fri Apr 29 17:35:58 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3b9b96be
sys-block/spindown: use #!/sbin/openrc-run instead of #!/sbin/runscript
Gentoo-Bug: https://bugs.gentoo.org/573846
Package-Manager: portage-2.2.26
sys-block/spindown/files/spindownd.initd-r1 | 4 +--
sys-block/spindown/spindown-0.4.0-r5.ebuild | 45 +++++++++++++++++++++++++++++
2 files changed, 47 insertions(+), 2 deletions(-)
diff --git a/sys-block/spindown/files/spindownd.initd-r1 b/sys-block/spindown/files/spindownd.initd-r1
index f35908f..64a6ec5 100644
--- a/sys-block/spindown/files/spindownd.initd-r1
+++ b/sys-block/spindown/files/spindownd.initd-r1
@@ -1,5 +1,5 @@
-#!/sbin/runscript
-# Copyright 1999-2012 Gentoo Foundation
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
SPINDOWND_BIN="/usr/sbin/spindownd"
diff --git a/sys-block/spindown/spindown-0.4.0-r5.ebuild b/sys-block/spindown/spindown-0.4.0-r5.ebuild
new file mode 100644
index 0000000..8eced94
--- /dev/null
+++ b/sys-block/spindown/spindown-0.4.0-r5.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+DESCRIPTION="Spindown is a daemon that can spin down idle disks"
+HOMEPAGE="https://code.google.com/p/spindown"
+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"
+
+src_prepare() {
+ eapply "${FILESDIR}"/${P}-CFLAGS-LDFLAGS.patch
+ eapply_user
+}
+
+src_compile() {
+ emake
+}
+
+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
+ elog "To start spindownd by default"
+ elog "you should add it to the default runlevel:"
+ elog " rc-update add spindownd default"
+}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-block/spindown/files/, sys-block/spindown/
@ 2023-01-23 2:40 Sam James
0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2023-01-23 2:40 UTC (permalink / raw
To: gentoo-commits
commit: 787c9cc8064dcb021a01a51e2fc0217b927a9111
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Jan 23 02:20:59 2023 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jan 23 02:32:54 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=787c9cc8
sys-block/spindown: EAPI 8, respect CXX, fix musl build
Closes: https://bugs.gentoo.org/863074
Closes: https://bugs.gentoo.org/725760
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../spindown/files/spindown-0.4.0-Makefile.patch | 55 ++++++++++++++++++++++
.../files/spindown-0.4.0-musl-time-include.patch | 11 +++++
sys-block/spindown/spindown-0.4.0-r5.ebuild | 26 +++++-----
3 files changed, 80 insertions(+), 12 deletions(-)
diff --git a/sys-block/spindown/files/spindown-0.4.0-Makefile.patch b/sys-block/spindown/files/spindown-0.4.0-Makefile.patch
new file mode 100644
index 000000000000..60bfdb25616f
--- /dev/null
+++ b/sys-block/spindown/files/spindown-0.4.0-Makefile.patch
@@ -0,0 +1,55 @@
+--- a/Makefile
++++ b/Makefile
+@@ -3,8 +3,8 @@ ETCDIR = $(DESTDIR)/etc
+ VERSION = 0.4.0
+ OBJS = main.o diskset.o disk.o spindown.o iniparser.o dictionary.o log.o spindownd.o\
+ exceptions.o
+-CC = g++
+-CFLAGS +=
++CXX ?= c++
++CXXFLAGS +=
+ LDFLAGS +=
+ SRC = src/
+ INPARSER = $(SRC)ininiparser3.0b/
+@@ -61,31 +61,31 @@ dist:
+ rm -d -r -f $(SRCDIR)
+
+ spindownd: $(OBJS)
+- g++ $(CFLAGS) $(LDFLAGS) -o spindownd $(OBJS)
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o spindownd $(OBJS)
+
+ main.o: $(SRC)main.cpp $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)main.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)main.cpp
+
+ diskset.o: $(SRC)diskset.cpp $(SRC)diskset.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)diskset.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)diskset.cpp
+
+ disk.o: $(SRC)disk.cpp $(SRC)disk.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)disk.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)disk.cpp
+
+ spindown.o: $(SRC)spindown.cpp $(SRC)spindown.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)spindown.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)spindown.cpp
+
+ spindownd.o: $(SRC)spindownd.cpp $(SRC)spindownd.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)spindownd.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)spindownd.cpp
+
+ log.o: $(SRC)log.cpp $(SRC)log.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)log.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)log.cpp
+
+ exceptions.o: $(SRC)exceptions.cpp $(SRC)exceptions.h $(SRC)general.h
+- g++ $(CFLAGS) $(LDFLAGS) -c $(SRC)exceptions.cpp
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SRC)exceptions.cpp
+
+ iniparser.o: $(INPARSER)iniparser.c
+- g++ $(CFLAGS) $(LDFLAGS) -c $(INPARSER)iniparser.c
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(INPARSER)iniparser.c
+
+ dictionary.o: $(INPARSER)dictionary.c
+- g++ $(CFLAGS) $(LDFLAGS) -c $(INPARSER)dictionary.c
++ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(INPARSER)dictionary.c
diff --git a/sys-block/spindown/files/spindown-0.4.0-musl-time-include.patch b/sys-block/spindown/files/spindown-0.4.0-musl-time-include.patch
new file mode 100644
index 000000000000..8b42b5e41c9d
--- /dev/null
+++ b/sys-block/spindown/files/spindown-0.4.0-musl-time-include.patch
@@ -0,0 +1,11 @@
+https://bugs.gentoo.org/863074
+--- a/src/disk.h
++++ b/src/disk.h
+@@ -30,6 +30,7 @@
+
+ #include "ininiparser3.0b/iniparser.h"
+
++#include <ctime>
+ #include <string>
+ using std::string;
+
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:"
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-01-23 2:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-23 2:40 [gentoo-commits] repo/gentoo:master commit in: sys-block/spindown/files/, sys-block/spindown/ Sam James
-- strict thread matches above, loose matches on Subject: below --
2016-04-29 17:38 Austin English
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox