The cronie project includes anacron, but this isn't supplied by the existing sys-process/cronie package. It would be nice to be able to have cronie's anacron, either as a seperate package or installed by the existing sys-process/cronie package.
Created attachment 208488 [details] cronie-1.4.1.ebuild with anacron use flag I've implemented this as a use flag on the existing cronie package. Tested on amd64 both with and without the new use flag enabled. Appears to work as expected. Changes summary: --- /mnt/portage/sys-process/cronie/cronie-1.4.1.ebuild 2009-08-23 21:12:43.000000000 +0100 +++ cronie-1.4.1-r1.ebuild 2009-10-28 08:43:15.000000000 +0000 @@ -11,10 +11,11 @@ HOMEPAGE="https://fedorahosted.org/cronie/wiki" LICENSE="ISC BSD BSD-2" -KEYWORDS="~x86" -IUSE="inotify pam" +KEYWORDS="~amd64 ~x86" +IUSE="anacron inotify pam" -DEPEND="pam? ( virtual/pam )" +DEPEND="anacron? ( !sys-process/anacron ) + pam? ( virtual/pam )" RDEPEND="${DEPEND}" #cronie supports /etc/crontab @@ -24,6 +25,7 @@ SPOOL_DIR="/var/spool/cron/crontabs" econf \ $(use_with inotify ) \ $(use_with pam ) \ + $(use_enable anacron ) \ --with-daemon_username=cron \ --with-daemon_groupname=cron \ || die "econf failed"
Created attachment 208489 [details] cronie-1.4.1.ebuild with anacron use flag - install examples and cron.d script Install the contrib/0anacron script to cron.d/0anacron so anacron now works "out of the box" and install the other contrib files as documentation/examples @@ -40,6 +42,14 @@ newins "${FILESDIR}/${PN}-1.2-crontab" crontab newins "${FILESDIR}/${PN}-1.2-cron.deny" cron.deny + if use anacron; then + insinto /etc/cron.d + newins "${S}/contrib/0anacron" 0anacron + fperms 755 /etc/cron.d/0anacron + + dodoc contrib/0hourly contrib/anacrontab + fi + keepdir /etc/cron.d newinitd "${FILESDIR}/${PN}-1.2-initd" cronie dodoc NEWS AUTHORS README
The setup of cronie in this ebuild is incorrect. I'm currently looking at this and will upload a new ebuild when done.
Created attachment 208557 [details] cronie-1.4.1.ebuild with correct setup of anacron (added init script, spool dir setup) I'm pretty sure this one should be correct now. I've added an init script for anacron and setup the spool directory correctly.
Created attachment 208558 [details] files/anacron-1.4.1-initd (anacron init script)
Can you elaborate in short what anacron exactly is and what's the difference to the "normal" crond from cronie?
anacron can now be installed with latest cronie ebuilds.