pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

logrotate-git: upgrade to latest version/commit



Module Name:	pkgsrc-wip
Committed By:	Nils Ratusznik <nils%NetBSD.org@localhost>
Pushed By:	nils
Date:		Sun Apr 9 21:02:08 2023 +0200
Changeset:	e185b43e3ad7aa1e28e1e4b91c4d4606529e087e

Modified Files:
	logrotate-git/Makefile
	logrotate-git/distinfo
	logrotate-git/patches/patch-config.c
	logrotate-git/patches/patch-examples_logrotate.cron
Added Files:
	logrotate-git/patches/patch-examples_logrotate.conf
Removed Files:
	logrotate-git/patches/patch-examples_logrotate-default

Log Message:
logrotate-git: upgrade to latest version/commit

Also "backported" patches from sysutils/logrotate.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=e185b43e3ad7aa1e28e1e4b91c4d4606529e087e

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 logrotate-git/Makefile                             | 54 +++++++++++-----------
 logrotate-git/distinfo                             | 13 +++---
 logrotate-git/patches/patch-config.c               | 23 +++++----
 .../patches/patch-examples_logrotate-default       | 31 -------------
 .../patches/patch-examples_logrotate.conf          | 14 ++++++
 .../patches/patch-examples_logrotate.cron          |  4 +-
 6 files changed, 63 insertions(+), 76 deletions(-)

diffs:
diff --git a/logrotate-git/Makefile b/logrotate-git/Makefile
index ca42685e17..fefd8e71c9 100644
--- a/logrotate-git/Makefile
+++ b/logrotate-git/Makefile
@@ -1,7 +1,7 @@
 # $NetBSD: Makefile,v 1.15 2017/01/26 20:12:32 nils Exp $
 
 DISTNAME=		${GHCOMMIT}
-PKGNAME=		logrotate-3.11.0.20170123
+PKGNAME=		logrotate-3.21.0.20230401
 CATEGORIES=		sysutils
 MASTER_SITES=		${MASTER_SITE_GITHUB:=logrotate/logrotate/archive/}
 
@@ -10,11 +10,10 @@ HOMEPAGE=		https://github.com/logrotate/logrotate/
 COMMENT=		Daemon to rotate, compress, remove and mail system log files
 LICENSE=		gnu-gpl-v2
 
-GHCOMMIT=		58e33d126e9422ac5271d6bda724c9065564a440
-USE_TOOLS+=		gmake gzip:run gunzip:run mail:run automake autoconf
+GHCOMMIT=		eb94f32dcc585e31c880418d82c38521076e882a
+USE_TOOLS+=		gmake gzip:run gunzip:run mail:run autoreconf autoconf automake
 USE_LIBTOOL=		yes
 GNU_CONFIGURE=		yes
-HAS_CONFIGURE=		yes
 NO_EXPORT_CPP=		yes
 
 WRKSRC=			${WRKDIR}/logrotate-${GHCOMMIT}
@@ -25,37 +24,38 @@ CONFIGURE_ENV+=		UNCOMPRESS_COMMAND=\"${GUNZIP_CMD:[1]:Q}\"
 CONFIGURE_ARGS+=	--with-state-file-path="${VARBASE}/db/logrotate.status"
 
 BUILD_DEFS+=		VARBASE
-EGDIR=			${PREFIX}/share/examples/logrotate
-CONF_FILES=		${EGDIR}/logrotate.conf ${PKG_SYSCONFDIR}/logrotate.conf
-OWN_DIRS=		${PKG_SYSCONFDIR}/logrotate.d
-MESSAGE_SUBST+=		EGDIR=${EGDIR}
-INSTALLATION_DIRS+=	${EGDIR} ${PKG_SYSCONFDIR} ${OWN_DIRS}
-AUTO_MKDIRS=		yes
 
+MESSAGE_SUBST+=		EGDIR=${EGDIR}
 SUBST_CLASSES+=		paths
 SUBST_STAGE.paths=	pre-build
 SUBST_MESSAGE.paths=	Substituting paths variables.
-SUBST_FILES.paths=	examples/logrotate-default
+SUBST_FILES.paths=	examples/logrotate.conf
 SUBST_FILES.paths+=	examples/logrotate.cron
-SUBST_VARS.paths=	PREFIX
-SUBST_VARS.paths+=	VARBASE
-SUBST_VARS.paths+=	PKG_SYSCONFDIR
+SUBST_VARS.paths=	PREFIX PKG_SYSCONFDIR
+
+CONF_FILES=		${EGDIR}/logrotate.conf ${PKG_SYSCONFDIR}/logrotate.conf \
+			${EGDIR}/btmp ${PKG_SYSCONFDIR}/logrotate.d/btmp \
+			${EGDIR}/wtmp \
+			${EGDIR}/logrotate.service
+
+OWN_DIRS=		${PKG_SYSCONFDIR}/logrotate.d
 
-DOCDIR=			share/doc/logrotate
+EGDIR=			share/examples/logrotate
 
+INSTALLATION_DIRS+=	${EGDIR}
 pre-configure:
-	cd ${WRKSRC} && \
-		${SETENV} ${CONFIGURE_ENV} ./autogen.sh
-
-do-install:
-	${INSTALL_PROGRAM} ${WRKSRC}/logrotate ${DESTDIR}${PREFIX}/sbin
-	${INSTALL_DATA} ${WRKSRC}/examples/logrotate-default ${DESTDIR}${EGDIR}/logrotate.conf
-	${INSTALL_DATA} ${WRKSRC}/examples/logrotate.cron ${DESTDIR}/${EGDIR}
-	${INSTALL_DATA} ${WRKSRC}/README.* ${DESTDIR}${PREFIX}/${DOCDIR}
-	${INSTALL_DATA} ${WRKSRC}/ChangeLog.md ${DESTDIR}${PREFIX}/${DOCDIR}
-	${INSTALL_DATA} ${WRKSRC}/COPYING ${DESTDIR}${PREFIX}/${DOCDIR}
-	${INSTALL_MAN} ${WRKSRC}/logrotate.conf.5 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man5
-	${INSTALL_MAN} ${WRKSRC}/logrotate.8 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8
+	cd ${WRKSRC} && autoreconf -fiv
+post-install:
+	${INSTALL_DATA} ${WRKSRC}/examples/logrotate.conf \
+		${DESTDIR}${PREFIX}/${EGDIR}/logrotate.conf
+	${INSTALL_DATA} ${WRKSRC}/examples/btmp \
+		${DESTDIR}${PREFIX}/${EGDIR}/btmp
+	${INSTALL_DATA} ${WRKSRC}/examples/wtmp \
+		${DESTDIR}${PREFIX}/${EGDIR}/wtmp
+	${INSTALL_DATA} ${WRKSRC}/examples/logrotate.cron \
+		${DESTDIR}${PREFIX}/${EGDIR}
+	${INSTALL_DATA} ${WRKSRC}/examples/logrotate.service \
+		${DESTDIR}${PREFIX}/${EGDIR}
 
 .include "../../devel/popt/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff --git a/logrotate-git/distinfo b/logrotate-git/distinfo
index 6261e07cf0..7b65980dd9 100644
--- a/logrotate-git/distinfo
+++ b/logrotate-git/distinfo
@@ -1,9 +1,8 @@
 $NetBSD: distinfo,v 1.13 2017/01/26 20:12:32 nils Exp $
 
-RMD160 (58e33d126e9422ac5271d6bda724c9065564a440.tar.gz) = 4c83ca4c58345fd4da2109f7fdbfc58adacc66bb
-SHA512 (58e33d126e9422ac5271d6bda724c9065564a440.tar.gz) = 66246f052ade1033e78e2e530499868d7bff34b926d31bba50b0ca949117441bf77e834efb5f7658140c5301ad45ddd8a80186c6df767e47b4998b55bafa4227
-Size (58e33d126e9422ac5271d6bda724c9065564a440.tar.gz) = 85348 bytes
-SHA1 (patch-config.c) = a6c775599857f01fa11bb99113795794f46664f5
-SHA1 (patch-examples_logrotate-default) = 6d3f575cc6563dd8c00dad4b1baa4e9d5eadae3b
-SHA1 (patch-examples_logrotate.cron) = e7e7a3f0ff77b3ee5fbf69ee2acecac136b0be8f
-SHA1 (patch-logrotate.8) = 0bf7d9cfbc2f5dfff42a82b523926b9c8d0362a0
+BLAKE2s (eb94f32dcc585e31c880418d82c38521076e882a.tar.gz) = c08bdd2dacb2e8b96935e0db6dde2015473e02776d632106e24b4b767a337291
+SHA512 (eb94f32dcc585e31c880418d82c38521076e882a.tar.gz) = 0e4c4aecec76d3ea2bf0612423f7fac77a6938b70f00db5047f8e2f3de846e802d6ca191bb36aa8ccf0eb7053349a0cfb32af4b8b5921ab249398a5e5fbad4ec
+Size (eb94f32dcc585e31c880418d82c38521076e882a.tar.gz) = 99243 bytes
+SHA1 (patch-config.c) = 5f967ff8479c78628e62e23e200c6373aebd0786
+SHA1 (patch-examples_logrotate.conf) = 69ac4cdc5c5fb118ee5b43ac4f2f500a3f321d2d
+SHA1 (patch-examples_logrotate.cron) = 31a19e1b697e945299bbbe6701674d886379a49c
diff --git a/logrotate-git/patches/patch-config.c b/logrotate-git/patches/patch-config.c
index da4ae74f13..67a45fba54 100644
--- a/logrotate-git/patches/patch-config.c
+++ b/logrotate-git/patches/patch-config.c
@@ -1,16 +1,21 @@
-$NetBSD: patch-config.c,v 1.5 2017/01/26 20:12:32 nils Exp $
+$NetBSD: patch-config.c,v 1.7 2020/10/08 07:50:51 wiz Exp $
 
 Fix NetBSD compilation.
 
---- config.c.orig	2016-12-02 13:12:33.000000000 +0000
+--- config.c.orig	2020-07-10 08:22:39.000000000 +0000
 +++ config.c
-@@ -3,6 +3,9 @@
- #ifndef __NetBSD__
- #include <alloca.h>
- #endif
+@@ -19,7 +19,13 @@
+ #include <wctype.h>
+ #include <fnmatch.h>
+ #include <sys/mman.h>
+-#include <libgen.h>
 +#ifndef _LIBGEN_H_
 +#  include <libgen.h>
 +#endif
- #include <limits.h>
- #include <ctype.h>
- #include <dirent.h>
++
++#ifndef secure_getenv
++#define secure_getenv getenv
++#endif
+ 
+ #if !defined(PATH_MAX) && defined(__FreeBSD__)
+ #include <sys/param.h>
diff --git a/logrotate-git/patches/patch-examples_logrotate-default b/logrotate-git/patches/patch-examples_logrotate-default
deleted file mode 100644
index e1f3e86319..0000000000
--- a/logrotate-git/patches/patch-examples_logrotate-default
+++ /dev/null
@@ -1,31 +0,0 @@
-$NetBSD: patch-examples_logrotate-default,v 1.4 2017/01/26 20:12:32 nils Exp $
-
-Add pkgsrc paths compatibility.
-
---- examples/logrotate-default.orig	2016-12-02 13:12:33.000000000 +0000
-+++ examples/logrotate-default
-@@ -14,22 +14,7 @@ dateext
- # uncomment this if you want your log files compressed
- #compress
- 
--# RPM packages drop log rotation information into this directory
--include /etc/logrotate.d
--
--# no packages own wtmp and btmp -- we'll rotate them here
--/var/log/wtmp {
--    monthly
--    create 0664 root utmp
--    minsize 1M
--    rotate 1
--}
--
--/var/log/btmp {
--    missingok
--    monthly
--    create 0600 root utmp
--    rotate 1
--}
-+# Packages drop log rotation information into this directory
-+include /usr/pkg/etc/logrotate.d
- 
- # system-specific logs may be also be configured here.
diff --git a/logrotate-git/patches/patch-examples_logrotate.conf b/logrotate-git/patches/patch-examples_logrotate.conf
new file mode 100644
index 0000000000..16e0916d6d
--- /dev/null
+++ b/logrotate-git/patches/patch-examples_logrotate.conf
@@ -0,0 +1,14 @@
+$NetBSD: patch-examples_logrotate.conf,v 1.1 2019/03/20 10:34:10 he Exp $
+
+Use pkgsrc config directory.
+
+--- examples/logrotate.conf.orig	2018-05-25 12:31:21.000000000 +0000
++++ examples/logrotate.conf
+@@ -15,6 +15,6 @@ dateext
+ #compress
+ 
+ # packages drop log rotation information into this directory
+-include /etc/logrotate.d
++include @PKG_SYSCONFDIR@/logrotate.d
+ 
+ # system-specific logs may also be configured here.
diff --git a/logrotate-git/patches/patch-examples_logrotate.cron b/logrotate-git/patches/patch-examples_logrotate.cron
index 854d450749..fa12d5820b 100644
--- a/logrotate-git/patches/patch-examples_logrotate.cron
+++ b/logrotate-git/patches/patch-examples_logrotate.cron
@@ -1,4 +1,4 @@
-$NetBSD: patch-examples_logrotate.cron,v 1.2 2017/01/26 20:12:32 nils Exp $
+$NetBSD: patch-examples_logrotate.cron,v 1.3 2017/03/06 12:59:53 fhajny Exp $
 
 Add pkgsrc paths compatibility
 
@@ -8,7 +8,7 @@ Add pkgsrc paths compatibility
  #!/bin/sh
  
 -/usr/sbin/logrotate /etc/logrotate.conf
-+/usr/pkg/sbin/logrotate /usr/pkg/etc/logrotate.conf
++@PREFIX@/sbin/logrotate @PKG_SYSCONFDIR@/logrotate.conf
  EXITVALUE=$?
  if [ $EXITVALUE != 0 ]; then
      /usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]"


Home | Main Index | Thread Index | Old Index