###############################################################################
name = logrotate
-version = 3.7.7
-release = 3
+version = 3.9.1
+release = 1
groups = System/Base
url = https://fedorahosted.org/releases/l/o/logrotate/
summary = Rotates, compresses, removes and mails system log files.
description
- The logrotate utility is designed to simplify the administration of \
- log files on a system which generates a lot of log files. Logrotate \
- allows for the automatic rotation compression, removal and mailing of \
- log files. Logrotate can be set to handle a log file daily, weekly, \
+ The logrotate utility is designed to simplify the administration of
+ log files on a system which generates a lot of log files. Logrotate
+ allows for the automatic rotation compression, removal and mailing of
+ log files. Logrotate can be set to handle a log file daily, weekly,
monthly or when the log file gets to a certain size.
end
-source_dl =
+source_dl = https://fedorahosted.org/releases/l/o/logrotate/
build
requires
coreutils
gzip
- libselinux-devel
popt-devel
which
end
build
- make RPM_OPT_FLAGS="%{CFLAGS}" WITH_SELINUX=yes %{PARALLELISMFLAGS}
- end
-
- test
- make test
+ make RPM_OPT_FLAGS="%{CFLAGS}" %{PARALLELISMFLAGS}
end
install
- make install BASEDIR=/usr PREFIX=%{BUILDROOT} \
- MANDIR=/usr/share/man
+ make install BASEDIR=%{prefix} PREFIX=%{BUILDROOT} \
+ MANDIR=%{mandir}
- mkdir -pv %{BUILDROOT}/var/lib
- touch %{BUILDROOT}/var/lib/logrotate.status
+ mkdir -pv %{BUILDROOT}%{localstatedir}
+ touch %{BUILDROOT}%{localstatedir}/logrotate.status
# Creating directory for config files
- mkdir -pv %{BUILDROOT}/etc/logrotate.d
+ mkdir -pv %{BUILDROOT}%{sysconfdir}/logrotate.d
end
end
+++ /dev/null
-diff -up logrotate-3.7.7/config.c.curdir logrotate-3.7.7/config.c
---- logrotate-3.7.7/config.c.curdir 2008-05-09 09:28:59.000000000 +0200
-+++ logrotate-3.7.7/config.c 2008-11-20 15:35:05.000000000 +0100
-@@ -316,11 +316,6 @@ static int readConfigPath(const char *pa
- DIR *dirp;
-
- here = open(".", O_RDONLY);
-- if (here < 0) {
-- message(MESS_ERROR, "cannot open current directory: %s\n",
-- strerror(errno));
-- return 1;
-- }
-
- if ((dirp = opendir(path)) == NULL) {
- message(MESS_ERROR, "cannot open directory %s: %s\n", path,
+++ /dev/null
-diff -up logrotate-3.7.7/config.c.toolarge logrotate-3.7.7/config.c
---- logrotate-3.7.7/config.c.toolarge 2008-11-21 12:57:25.000000000 +0100
-+++ logrotate-3.7.7/config.c 2008-11-21 12:57:41.000000000 +0100
-@@ -530,6 +530,13 @@ static int readConfigFile(const char *co
-
- length = sb.st_size;
-
-+ if (length > 0xffffff) {
-+ message(MESS_ERROR, "file %s too large, probably not a config file.\n",
-+ configFile);
-+ close(fd);
-+ return 1;
-+ }
-+
- buf = alloca(length + 2);
- if (!buf) {
- message(MESS_ERROR, "alloca() of %d bytes failed\n", (int) length);