summaryrefslogtreecommitdiff
path: root/sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-11-21 01:03:25 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-11-21 01:03:25 +0000
commitd32022e7301aef2b3f52f6b7a3de81c6e03ffcaf (patch)
tree4e64fbab713348c061644255d893ff91f2d8b1e5 /sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild
parent92f98ae772a60a2fa63efbda2f915da957a3b3b8 (diff)
gentoo auto-resync : 21:11:2022 - 01:03:25
Diffstat (limited to 'sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild')
-rw-r--r--sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild59
1 files changed, 59 insertions, 0 deletions
diff --git a/sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild b/sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild
new file mode 100644
index 000000000000..84ffc0148d5d
--- /dev/null
+++ b/sys-apps/opentmpfiles/opentmpfiles-0.2-r1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit prefix
+
+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 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+fi
+
+DESCRIPTION="A standalone utility to process systemd-style tmpfiles.d files"
+HOMEPAGE="https://github.com/openrc/opentmpfiles"
+
+LICENSE="BSD-2"
+SLOT="0"
+IUSE="selinux"
+
+RDEPEND="
+ !<sys-apps/openrc-0.23
+ selinux? ( sec-policy/selinux-base-policy )"
+
+src_prepare() {
+ default
+ hprefixify tmpfiles
+}
+
+src_install() {
+ emake DESTDIR="${ED}" install
+ einstalldocs
+
+ cd openrc || die
+ local f
+ for f in opentmpfiles-dev opentmpfiles-setup; do
+ newconfd ${f}.confd ${f}
+ newinitd ${f}.initd ${f}
+ done
+}
+
+pkg_postinst() {
+ add_service() {
+ local initd=$1
+ local runlevel=$2
+
+ elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
+ mkdir -p "${EROOT}"/etc/runlevels/${runlevel}
+ ln -snf /etc/init.d/${initd} "${EROOT}"/etc/runlevels/${runlevel}/${initd}
+ }
+
+ if [[ -z $REPLACING_VERSIONS ]]; then
+ add_service opentmpfiles-dev sysinit
+ add_service opentmpfiles-setup boot
+ fi
+}