From 8f792117606bd118fd904e50f6d49bddc140a38a Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 28 Mar 2009 18:49:46 +0100 Subject: [PATCH] util-linux-ng: add an hourly cron job for hwclock --adjtime. --HG-- extra : convert_revision : 71220f4abc2512b3e63f71a4bca0ec863290206f --- templates/util-linux-ng/files/adjtime.cron-hourly | 5 +++++ templates/util-linux-ng/template | 5 +++++ 2 files changed, 10 insertions(+) create mode 100644 templates/util-linux-ng/files/adjtime.cron-hourly diff --git a/templates/util-linux-ng/files/adjtime.cron-hourly b/templates/util-linux-ng/files/adjtime.cron-hourly new file mode 100644 index 00000000000..9d69c176bf8 --- /dev/null +++ b/templates/util-linux-ng/files/adjtime.cron-hourly @@ -0,0 +1,5 @@ +#!/bin/sh +# +# Update our hwclock for system drift + +/sbin/hwclock --adjtime diff --git a/templates/util-linux-ng/template b/templates/util-linux-ng/template index 36940909693..82b443ae90f 100644 --- a/templates/util-linux-ng/template +++ b/templates/util-linux-ng/template @@ -1,6 +1,7 @@ # Template file for 'util-linux-ng' pkgname=util-linux-ng version=2.14.2 +revision=1 distfiles="http://www.kernel.org/pub/linux/utils/$pkgname/v2.14/$pkgname-$version.tar.bz2" build_style=gnu_configure configure_args="--enable-partx --enable-write" @@ -33,4 +34,8 @@ post_install() install -d -m 755 ${DESTDIR}/bin mv ${DESTDIR}/usr/bin/logger ${DESTDIR}/bin mkdir -p ${DESTDIR}/var/lib/hwclock + + # Install the cron daily job. + install -D -m755 ${FILESDIR}/adjtime.cron-hourly \ + ${DESTDIR}/etc/cron.hourly/adjtime }