From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6056E1580CF for ; Mon, 24 Jun 2024 02:54:57 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A6D34E2B1A; Mon, 24 Jun 2024 02:54:56 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8EE59E2B1A for ; Mon, 24 Jun 2024 02:54:56 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 5A778343010 for ; Mon, 24 Jun 2024 02:54:55 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id B23B21D36 for ; Mon, 24 Jun 2024 02:54:53 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1719197616.e04ca13b79c8da0b16bf8f181224141979bf9d64.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/logrotate/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-admin/logrotate/Manifest app-admin/logrotate/logrotate-3.22.0.ebuild X-VCS-Directories: app-admin/logrotate/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: e04ca13b79c8da0b16bf8f181224141979bf9d64 X-VCS-Branch: master Date: Mon, 24 Jun 2024 02:54:53 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 058d418d-7332-4aec-a96d-6103e1bd2b91 X-Archives-Hash: 29be966c3e2fae2620192d96a12c3fcb commit: e04ca13b79c8da0b16bf8f181224141979bf9d64 Author: Sam James gentoo org> AuthorDate: Mon Jun 24 02:35:50 2024 +0000 Commit: Sam James gentoo org> CommitDate: Mon Jun 24 02:53:36 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e04ca13b app-admin/logrotate: add 3.22.0 Bug: https://github.com/logrotate/logrotate/issues/576 Bug: https://github.com/logrotate/logrotate/issues/611 Signed-off-by: Sam James gentoo.org> app-admin/logrotate/Manifest | 2 + app-admin/logrotate/logrotate-3.22.0.ebuild | 99 +++++++++++++++++++++++++++++ 2 files changed, 101 insertions(+) diff --git a/app-admin/logrotate/Manifest b/app-admin/logrotate/Manifest index 82484df4b0c6..889283fbcb4e 100644 --- a/app-admin/logrotate/Manifest +++ b/app-admin/logrotate/Manifest @@ -1,2 +1,4 @@ DIST logrotate-3.21.0.tar.xz 168532 BLAKE2B f7fa0050bde51e2517eac8456ecf87648bc8423621830894ceb2a3ff6b9dfe32c5b53df6a4ee59aa91bd563ed94376a635159535f4fdc170fbc673354bcef508 SHA512 c576df7d2bc1a1db2f99befdd0ea627aef2d97bdcd4a7cdea76870623ba92fb1f04f1af6d15b75e4a9085f4aef2ae5e9843c4094cdd01e24d89872ccaf9c0d4a DIST logrotate-3.21.0.tar.xz.asc 833 BLAKE2B b2099a0b8c15d1ea7f7325884027dff08dcc8305113411448797b8089d17026242a3f10bd6d7f3d865e3e339ec6fb5faf4ff48f8fd65bca3af4da8b335c3b5f1 SHA512 8f4c1853cd84f85c796b72b43048f4cf04e3409703e7669ee91e1d1aa5e9e5c04261fac1cdf85ec303508d5b6dbf126a44eb9ec819bcc772c664830d39e1068c +DIST logrotate-3.22.0.tar.xz 172108 BLAKE2B c1c9f1ff792905d2917e9ba3cee360c50259e1520e04073cb69abe475499adcf01aeb3cb4c6933af61255fbb5978577c4fdf9d6ab6ebf9568358d2446791c7f3 SHA512 16fd95b4daef779212008c4a968c7a7130be8d550f58531d24fc04599cb9adff6323a745725b3b14d7312ad36cb6646fe33a3defdb5b70cda2cec9646aab066a +DIST logrotate-3.22.0.tar.xz.asc 833 BLAKE2B 379d4fd71c6161211234903560770cf14a7ddf769b83e76ef27ad96d1204e2f4dc73d1e44aa69401db87c252c4471d5bdbace0555dfbb66c8751c20131a7751f SHA512 93664c45bfe9ea20aedc54fe216825db38eaf81d43b238cd7bf8ea3e03f7d282f53743fb6d914766a9ed0cb5b33376435d253db5b9ec7039facd66e25d349dd4 diff --git a/app-admin/logrotate/logrotate-3.22.0.ebuild b/app-admin/logrotate/logrotate-3.22.0.ebuild new file mode 100644 index 000000000000..9426d975db21 --- /dev/null +++ b/app-admin/logrotate/logrotate-3.22.0.ebuild @@ -0,0 +1,99 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/cgzones.asc +inherit systemd tmpfiles verify-sig + +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.xz" +SRC_URI+=" verify-sig? ( https://github.com/${PN}/${PN}/releases/download/${PV}/${P}.tar.xz.asc )" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~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 ) +" +BDEPEND="verify-sig? ( sec-keys/openpgp-keys-cgzones )" + +STATEFILE="${EPREFIX}/var/lib/misc/logrotate.status" +OLDSTATEFILE="${EPREFIX}/var/lib/logrotate.status" + +PATCHES=( + "${FILESDIR}"/${PN}-3.15.0-ignore-hidden.patch +) + +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}" +} + +src_prepare() { + default + + sed -i -e 's#/usr/sbin/logrotate#/usr/bin/logrotate#' examples/logrotate.{cron,service} || die +} + +src_configure() { + econf \ + $(use_with acl) \ + $(use_with selinux) \ + --with-state-file-path="${STATEFILE}" +} + +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 + + tmpfiles_process ${PN}.conf + + 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 +}