summaryrefslogtreecommitdiff
path: root/sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild
reinit the tree, so we can have metadata
Diffstat (limited to 'sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild')
-rw-r--r--sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild44
1 files changed, 44 insertions, 0 deletions
diff --git a/sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild b/sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild
new file mode 100644
index 000000000000..12148204094e
--- /dev/null
+++ b/sys-apps/opentmpfiles/opentmpfiles-0.1.1.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+if [[ ${PV} = 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/openrc/${PN}"
+else
+ SRC_URI="https://github.com/openrc/${PN}/archive/${PV}.tar.gz ->
+ ${P}.tar.gz"
+ KEYWORDS="alpha amd64 arm arm64 ~hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86"
+fi
+
+DESCRIPTION="A standalone utility to process systemd-style tmpfiles.d files"
+HOMEPAGE="https://github.com/openrc/opentmpfiles"
+
+LICENSE="BSD-2"
+SLOT="0"
+IUSE=""
+
+RDEPEND="!<sys-apps/openrc-0.23"
+
+src_install() {
+ default
+ cd openrc
+ for f in opentmpfiles-dev opentmpfiles-setup; do
+ newconfd ${f}.confd ${f}
+ newinitd ${f}.initd ${f}
+ done
+}
+
+add_service() {
+ local initd=$1
+ local runlevel=$2
+
+ elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
+ ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
+}
+
+pkg_postinst() {
+ add_service opentmpfiles-dev sysinit
+ add_service opentmpfiles-setup boot
+}