SHA256
1
0
forked from pool/logrotate

Accepting request 78660 from home:jengelh:dev

- Change compression scheme to xz. This should give smaller resulting filesizes.

OBS-URL: https://build.opensuse.org/request/show/78660
OBS-URL: https://build.opensuse.org/package/show/Base:System/logrotate?expand=0&rev=14
This commit is contained in:
Cristian Rodríguez 2011-08-12 19:00:30 +00:00 committed by Git OBS Bridge
parent 6691855738
commit ded26fb957
4 changed files with 11 additions and 5 deletions

View File

@ -34,7 +34,7 @@ Index: logrotate.c
=================================================================== ===================================================================
--- logrotate.c.orig 2008-10-15 15:07:43.000000000 +0200 --- logrotate.c.orig 2008-10-15 15:07:43.000000000 +0200
+++ logrotate.c 2009-03-06 14:21:45.000000000 +0100 +++ logrotate.c 2009-03-06 14:21:45.000000000 +0100
@@ -54,6 +54,15 @@ @@ -54,6 +54,16 @@
int numLogs = 0; int numLogs = 0;
int debug = 0; int debug = 0;
char *mailCommand = DEFAULT_MAIL_COMMAND; char *mailCommand = DEFAULT_MAIL_COMMAND;
@ -42,6 +42,7 @@ Index: logrotate.c
+const char * compress_cmd_list[][2] = { +const char * compress_cmd_list[][2] = {
+ {"gzip", ".gz"}, + {"gzip", ".gz"},
+ {"bzip2", ".bz2"}, + {"bzip2", ".bz2"},
+ {"xz", ".xz"},
+ {"compress", ".Z"}, + {"compress", ".Z"},
+ {"zip", "zip"}, + {"zip", "zip"},
+ {"EOLIST", "EOLIST"} /* end-marker */ + {"EOLIST", "EOLIST"} /* end-marker */

View File

@ -18,8 +18,8 @@ Index: examples/logrotate-default
-} -}
+# comment these to switch compression to use gzip or another +# comment these to switch compression to use gzip or another
+# compression scheme +# compression scheme
+compresscmd /usr/bin/bzip2 +compresscmd /usr/bin/xz
+uncompresscmd /usr/bin/bunzip2 +uncompresscmd /usr/bin/xzdec
-/var/log/btmp { -/var/log/btmp {
- missingok - missingok
@ -28,7 +28,7 @@ Index: examples/logrotate-default
- rotate 1 - rotate 1
-} -}
+# former versions had to have the compressext set accordingly +# former versions had to have the compressext set accordingly
+#compressext .bz2 +#compressext .xz
-# system-specific logs may be also be configured here. -# system-specific logs may be also be configured here.
+# RPM packages drop log rotation information into this directory +# RPM packages drop log rotation information into this directory

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Mon Jul 25 10:25:56 UTC 2011 - jengelh@medozas.de
- Change compression scheme to xz
------------------------------------------------------------------- -------------------------------------------------------------------
Tue May 10 14:23:08 UTC 2011 - puzel@novell.com Tue May 10 14:23:08 UTC 2011 - puzel@novell.com

View File

@ -39,7 +39,7 @@ BuildRequires: popt-devel
PreReq: %fillup_prereq PreReq: %fillup_prereq
PreReq: /bin/mv PreReq: /bin/mv
PreReq: /bin/rm PreReq: /bin/rm
Requires: bzip2 Requires: xz
Requires: cron Requires: cron
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build