updated on Tue Jan 17 16:10:12 UTC 2012
[aur-mirror.git] / dcron-maint / PKGBUILD
blob05113e20bf2ff3302d67d77df320ddd72c2327d0
1 _basepkgname=dcron
2 pkgname=${_basepkgname}-maint
3 pkgver=4.4
4 pkgrel=1
5 pkgdesc="dillon's lightweight cron daemon, with maintenance patches"
6 arch=(i686 x86_64)
7 license=('GPL')
8 url="http://www.jimpryor.net/linux/dcron"
9 backup=(var/spool/cron/root etc/conf.d/crond)
10 depends=('glibc')
11 provides=('cron')
12 conflicts=('dcron')
13 source=("http://www.jimpryor.net/linux/releases/${_basepkgname}-${pkgver}.tar.gz"
14         'dcron-logname.patch'
15         'dcron.rc.d'
16         'dcron.conf.d'
17         '0001-Fixing-bug-that-causes-monthly-jobs-to-be-skipped.patch'
18         '0002-Only-resynchronize-if-there-are-no-running-jobs-to-a.patch')
19 md5sums=('02d848ba043a9df5bf2102a9f4bc04bd'
20          'c6054421b48100f7a2a7a36e2d33c92a'
21          '73693cdd59df526e729cdec99c5ed8fb'
22          '5bfa07beb54d0beaf3f38225e4d5a9fa'
23          'd877903363dfcb174d0fa4630344bea8'
24          'f0dfa5f38c386cd97143878cb63d7e8e')
25 optdepends=('smtp-server: sending cron job output via email')
26 install=$_basepkgname.install
28 build() {
29   cd "$srcdir/${_basepkgname}-${pkgver}"
31   for patch in $srcdir/*.patch; do
32     msg2 "Patch: $(basename $patch)"
33     patch -p1 -i $patch
34   done
36   # by default, any member of group "users" can edit their own crontab
37   make PREFIX=/usr \
38        CRONTAB_GROUP=users \
39        CRONTABS=/var/spool/cron \
40        CRONSTAMPS=/var/spool/cronstamps
41   make DESTDIR="$pkgdir" install
43   # install standard configuration and scripts
44   install -d -m755 "$pkgdir/etc/cron."{hourly,daily,weekly,monthly}
45   install -D -m755 extra/run-cron "$pkgdir/usr/sbin/run-cron"
46   install -D -m0600 extra/root.crontab "$pkgdir/var/spool/cron/root"
48   # install Arch configuration and launch scripts
49   install -D -m755 "$srcdir/dcron.rc.d" "$pkgdir/etc/rc.d/crond"
50   install -D -m0644 "$srcdir/dcron.conf.d" "$pkgdir/etc/conf.d/crond"