--- /dev/null
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit eutils autotools
+
+DESCRIPTION="Log rotation software"
+HOMEPAGE="https://github.com/fordmason/cronolog"
+SRC_URI="http://cronolog.org/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~x86"
+
+PATCHES=(
+ "${FILESDIR}/${PV}-patches"/*.txt
+ "${FILESDIR}/${P}-umask.patch"
+)
+
+DOCS=( AUTHORS ChangeLog INSTALL NEWS README TODO )
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ einstalldocs
+}
diff -urb cronolog-1.6.2/src/cronoutils.c cronolog-1.6.2-patched/src/cronoutils.c
---- cronolog-1.6.2/src/cronoutils.c 2001-05-03 09:43:21.000000000 -0700
-+++ cronolog-1.6.2/src/cronoutils.c 2008-01-05 22:08:42.000000000 -0800
+--- a/src/cronoutils.c 2001-05-03 09:43:21.000000000 -0700
++++ b/src/cronoutils.c 2008-01-05 22:08:42.000000000 -0800
@@ -69,6 +69,8 @@
*
*/
diff -ur cronolog-1.6.2/doc/cronolog.1m cronolog-1.6.2/doc/cronolog.1m
---- cronolog-1.6.2/doc/cronolog.1m 2001-05-04 01:44:55.000000000 -0700
-+++ cronolog-1.6.2/doc/cronolog.1m 2008-01-06 00:43:33.000000000 -0800
+--- a/doc/cronolog.1m 2001-05-04 01:44:55.000000000 -0700
++++ b/doc/cronolog.1m 2008-01-06 00:43:33.000000000 -0800
@@ -77,7 +77,7 @@
to the current log file.
.\"
diff -urp cronolog-1.6.2/src/cronolog.c cronolog-1.6.2/src/cronolog.c
---- cronolog-1.6.2/src/cronolog.c 2001-05-03 09:42:48.000000000 -0700
-+++ cronolog-1.6.2/src/cronolog.c 2008-01-05 23:54:53.000000000 -0800
+--- a/src/cronolog.c 2001-05-03 09:42:48.000000000 -0700
++++ b/src/cronolog.c 2008-01-05 23:54:53.000000000 -0800
@@ -139,7 +139,8 @@ struct option long_options[] =
{ "delay", required_argument, NULL, 'd' },
{ "once-only", no_argument, NULL, 'o' },
---- tmp/cronolog.c 2003-10-13 12:35:17.000000000 +0000
-+++ src/cronolog.c 2003-10-13 12:36:36.000000000 +0000
+--- a/src/cronolog.c 2003-10-13 12:35:17.000000000 +0000
++++ b/src/cronolog.c 2003-10-13 12:36:36.000000000 +0000
@@ -82,6 +82,8 @@
* written to "file" (e.g. /dev/console) or to stderr if "file" is "-".
*/
---- tmp/cronoutils.c 2003-10-13 12:44:59.000000000 +0000
-+++ src/cronoutils.c 2003-10-13 12:45:08.000000000 +0000
+--- a/src/cronoutils.c 2003-10-13 12:44:59.000000000 +0000
++++ b/src/cronoutils.c 2003-10-13 12:45:08.000000000 +0000
@@ -199,7 +199,7 @@
{
unlink(prevlinkname);
diff -Naur cronolog-1.6.2/configure cronolog-1.6.2-new/configure
---- cronolog-1.6.2/configure Thu May 3 17:44:22 2001
-+++ cronolog-1.6.2-new/configure Mon Jun 3 00:38:32 2002
+--- a/configure Thu May 3 17:44:22 2001
++++ b/configure Mon Jun 3 00:38:32 2002
@@ -1757,15 +1757,49 @@
fi
-*** src/cronolog.c.orig 2001-05-03 17:42:48.000000000 +0100
---- src/cronolog.c 2003-08-15 14:03:17.000000000 +0100
+*** a/src/cronolog.c.orig 2001-05-03 17:42:48.000000000 +0100
+--- b/src/cronolog.c 2003-08-15 14:03:17.000000000 +0100
***************
*** 84,95 ****
--- 84,97 ----
---- cronolog-1.6.1/src/cronoutils.c Mon Dec 20 00:34:44 1999
-+++ cronolog-1.6.1.new/src/cronoutils.c Mon Feb 11 03:19:32 2002
+--- a/src/cronoutils.c Mon Dec 20 00:34:44 1999
++++ b/src/cronoutils.c Mon Feb 11 03:19:32 2002
@@ -204,9 +204,21 @@
{
if (ch == '%')
Patch-by: Mike Doty <kingtaco@gentoo.org>
Signed-off-By: Robin H. Johnson <robbat2@gentoo.org>
---- src/cronolog.c.orig 2010-01-22 16:49:41.000000000 -0800
-+++ src/cronolog.c 2010-01-22 17:31:50.000000000 -0800
+--- a/src/cronolog.c.orig 2010-01-22 16:49:41.000000000 -0800
++++ b/src/cronolog.c 2010-01-22 17:31:50.000000000 -0800
@@ -106,7 +106,8 @@
#ifndef _WIN32