summaryrefslogtreecommitdiff
path: root/app-admin/logrotate
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-05-31 20:59:14 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-05-31 20:59:14 +0100
commite748ba9741f6540f4675c23e3e37b73e822c13a4 (patch)
tree23dece8beabb3a3d7c6c0273b0eb40b21c62a889 /app-admin/logrotate
parent908778078736bd36f7a60a2d576d415cb8e000fa (diff)
gentoo resync : 31.05.2021
Diffstat (limited to 'app-admin/logrotate')
-rw-r--r--app-admin/logrotate/Manifest2
-rw-r--r--app-admin/logrotate/logrotate-3.18.1.ebuild99
2 files changed, 101 insertions, 0 deletions
diff --git a/app-admin/logrotate/Manifest b/app-admin/logrotate/Manifest
index 0d5b30544140..0614f598ce56 100644
--- a/app-admin/logrotate/Manifest
+++ b/app-admin/logrotate/Manifest
@@ -2,5 +2,7 @@ AUX logrotate-3.15.0-ignore-hidden.patch 566 BLAKE2B 1739e0d175311eb2a3692826830
AUX logrotate.conf 740 BLAKE2B ade43681e1929aa8b7e167a2be0c8569f3842680687381c202ac04b5cf97cd85481f6ca7fbf6f0dffa64caa3b1d9cb0f1e2154af8882a3ce7008337f2a5ede6f SHA512 6411acd842fac1a8af72142cddfa76b567f6ba859bed91dab56f1d26b48f3dcaa3ffee6c8094860fe9c43f9b6bc398199c8f4047856b91d6d12333d0fc7aef96
AUX logrotate.tmpfiles 16 BLAKE2B 1f7925d6d2d4bc120d5202f49887b23e2eb633f5c369fe8d0bd1703e5075671dd1e13a030ec06fa269214bff9552670d3e0932e3dbde2e3673d59b7a50a2458b SHA512 f51852b1d5708a8fc48c6fcfd2fc4f34f3cd88d9119c607c0cb47f0cc0dc7370bd3399a9ebf781943cdd16a25bb4db0d81337140fc179faa72e18a848f3d8c36
DIST logrotate-3.18.0.tar.gz 224873 BLAKE2B f73ffa2d58a5125393e6c96e158e39e0b4cadef01e6eebd172220227a7e1363e6731bc2ac511fa028078054b55d42b131cdc30232ac5762ce4c6cbff79c19681 SHA512 d1bca267fbec4acbb83ffba4d3ac4c864f4269d8513e5614e7dbe6f3b1f176685218bffdb5d62f559ee73f84cf9a8a257c9f63e30af058d12d0034240f247586
+DIST logrotate-3.18.1.tar.gz 225226 BLAKE2B 6f40dfe89f9c6202263f16204a9cff07b921abc9a298b58649bb4968c9f498626741be334c47d4092da564ed75642b687ff6ef8781f69f5e25364f8635646d9d SHA512 c40f920686aee014c652f087c64f2a85e9e866a8717d1bd3f32a9dd7959a02962e6174de28ae685428b442e12079d0c8d91485611ca34a873ffae872a54ec9fe
EBUILD logrotate-3.18.0.ebuild 2485 BLAKE2B def8bc9ca3114392f84c537ad44d06b44503fddce3600464e3e5645251f9f25753458eaa86ed59ad9470be7c3df25df089cd2749933cf8bebf8da6533803cc72 SHA512 7f74ae31c32d858036c998ab0f7eefe0c56dc34d19fb35fd0133a0e618e073b940c4e007b710f76a626890f084492de1de4cfbd988e61ce935a63162a8475766
+EBUILD logrotate-3.18.1.ebuild 2435 BLAKE2B e123c58fc13c28cf2dd1c12a25a60935785021d42cba32eb435d784997d33263a47a07d5530717ab22ceb4b41ec04aefa8c8cf301b8fbdbd88880a804f8d73d5 SHA512 4087f14f7b2676e1f7182efb9189a50b6b14b3fa8871b3e70b533c1c001970c499ca61b18fe1f4a6ea6d31cffacd75cd9973917b7c410b7738692b3ccdec53b3
MISC metadata.xml 1206 BLAKE2B c52b227a223e5d7db50f2009b3766d6af0f2c0ca51bdf3f6098d56d16c6586c08826b795f50a6f3f2e50f29ed4f9def8c53268a533eac985e3ab22042c418f7a SHA512 9d184f5b4c025416b7a2f6019f982a12e65e39da3532d7d024759e1e73d2b55d0e949e38c4cd0926e552059b600c114daa5beb135433d71e8f85d0f732d0b791
diff --git a/app-admin/logrotate/logrotate-3.18.1.ebuild b/app-admin/logrotate/logrotate-3.18.1.ebuild
new file mode 100644
index 000000000000..d49a3017aaba
--- /dev/null
+++ b/app-admin/logrotate/logrotate-3.18.1.ebuild
@@ -0,0 +1,99 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit systemd tmpfiles
+
+DESCRIPTION="Rotates, compresses, and mails system logs"
+HOMEPAGE="https://github.com/logrotate/logrotate"
+SRC_URI="https://github.com/${PN}/${PN}/releases/download/${PV}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="acl +cron selinux"
+
+DEPEND="
+ >=dev-libs/popt-1.5
+ selinux? ( sys-libs/libselinux )
+ acl? ( virtual/acl )"
+RDEPEND="${DEPEND}
+ selinux? ( sec-policy/selinux-logrotate )
+ cron? ( virtual/cron )"
+
+STATEFILE="${EPREFIX}/var/lib/misc/logrotate.status"
+OLDSTATEFILE="${EPREFIX}/var/lib/logrotate.status"
+
+move_old_state_file() {
+ elog "logrotate state file is now located at ${STATEFILE}"
+ elog "See bug #357275"
+ if [[ -e "${OLDSTATEFILE}" ]] ; then
+ elog "Moving your current state file to new location: ${STATEFILE}"
+ mv -n "${OLDSTATEFILE}" "${STATEFILE}" || die
+ fi
+}
+
+install_cron_file() {
+ exeinto /etc/cron.daily
+ newexe "${S}"/examples/logrotate.cron "${PN}"
+}
+
+PATCHES=(
+ "${FILESDIR}/${PN}-3.15.0-ignore-hidden.patch"
+)
+
+src_prepare() {
+ sed -i -e 's#/usr/sbin/logrotate#/usr/bin/logrotate#' examples/logrotate.{cron,service} || die
+ default
+}
+
+src_configure() {
+ econf \
+ $(use_with acl) \
+ $(use_with selinux) \
+ --with-state-file-path="${STATEFILE}"
+}
+
+src_test() {
+ emake test
+}
+
+src_install() {
+ dobin logrotate
+ doman logrotate.8
+ dodoc ChangeLog.md
+
+ insinto /etc
+ doins "${FILESDIR}"/logrotate.conf
+
+ use cron && install_cron_file
+
+ systemd_dounit examples/logrotate.{service,timer}
+ newtmpfiles "${FILESDIR}"/${PN}.tmpfiles ${PN}.conf
+
+ keepdir /etc/logrotate.d
+}
+
+pkg_postinst() {
+ elog
+ elog "The ${PN} binary is now installed under /usr/bin. Please"
+ elog "update your links"
+ elog
+
+ move_old_state_file
+
+ elog "If you are running systemd you might need to run:"
+ elog "systemd-tmpfiles --create /usr/lib/tmpfiles.d/logrotate.conf"
+ elog "in order to create the new location of the logrotate state file"
+ elog
+
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ elog "If you wish to have logrotate e-mail you updates, please"
+ elog "emerge virtual/mailx and configure logrotate in"
+ elog "/etc/logrotate.conf appropriately"
+ elog
+ elog "Additionally, /etc/logrotate.conf may need to be modified"
+ elog "for your particular needs. See man logrotate for details."
+ fi
+}