summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2017-12-17 18:33:46 -0500
committerMichael Orlitzky <mjo@gentoo.org>2017-12-17 18:33:46 -0500
commitc9aa851c802c02cb922d616ad1b5e32c8efa67af (patch)
treeacb20e5b493e9f2e23feb654518fedaa2c6515c7 /app-admin/cancd/cancd-0.1.0-r4.ebuild
parentgnome-base/dconf-editor: version bump 3.22.3 → 3.24.3 (diff)
downloadgentoo-c9aa851c802c02cb922d616ad1b5e32c8efa67af.tar.gz
gentoo-c9aa851c802c02cb922d616ad1b5e32c8efa67af.tar.bz2
gentoo-c9aa851c802c02cb922d616ad1b5e32c8efa67af.zip
app-admin/cancd: modernize the service script and ebuild.
This commit creates a new revision (-r4) that replaces the earlier unstable -r3. The ebuild itself includes an update to EAPI=6 and the associated simplifications, as well as the addition of a new user named "cancd" that is used by the init script. The service script was completely rewritten and simplified, and now uses more modern features of OpenRC. The original motivation for that was bug 603208. This is a non-maintainer commit, but robbat2 (the maintainer on file) recently made a post to gentoo-dev, "Packages up for grabs: robbat2 edition," stating that this package was up for grabs. Closes: https://bugs.gentoo.org/603208 Package-Manager: Portage-2.3.13, Repoman-2.3.3
Diffstat (limited to 'app-admin/cancd/cancd-0.1.0-r4.ebuild')
-rw-r--r--app-admin/cancd/cancd-0.1.0-r4.ebuild43
1 files changed, 43 insertions, 0 deletions
diff --git a/app-admin/cancd/cancd-0.1.0-r4.ebuild b/app-admin/cancd/cancd-0.1.0-r4.ebuild
new file mode 100644
index 000000000000..d66212991751
--- /dev/null
+++ b/app-admin/cancd/cancd-0.1.0-r4.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit user
+
+DESCRIPTION="CA NetConsole Daemon receives output from the Linux netconsole driver"
+HOMEPAGE="http://oss.oracle.com/projects/cancd/"
+SRC_URI="http://oss.oracle.com/projects/cancd/dist/files/source/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+PATCHES=(
+ "${FILESDIR}/${P}-build-r1.patch"
+ "${FILESDIR}/${P}-c-cleanup.patch"
+)
+
+src_prepare() {
+ default
+
+ # slight makefile cleanup
+ sed -i \
+ -e '/^CFLAGS/s,-g,,' \
+ -e '/^CFLAGS/s,-O2,-Wall -W -Wextra -Wundef -Wendif-labels -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion -Wsign-compare -Waggregate-return -Wstrict-prototypes -Wredundant-decls -Wunreachable-code -Wlong-long,' \
+ -e '/rm cancd cancd.o/s,rm,rm -f,' \
+ Makefile || die
+}
+
+src_install() {
+ dosbin cancd
+ newinitd "${FILESDIR}"/cancd-init.d-r1 cancd
+ newconfd "${FILESDIR}"/cancd-conf.d-r1 cancd
+ newinitd "${FILESDIR}"/netconsole-init.d netconsole
+ newconfd "${FILESDIR}"/netconsole-conf.d netconsole
+}
+
+pkg_preinst() {
+ enewuser cancd
+}