diff options
Diffstat (limited to 'community/uptimed')
-rw-r--r-- | community/uptimed/PKGBUILD | 18 | ||||
-rw-r--r-- | community/uptimed/rc.d | 39 | ||||
-rw-r--r-- | community/uptimed/service | 4 | ||||
-rw-r--r-- | community/uptimed/uptimed.install | 6 |
4 files changed, 11 insertions, 56 deletions
diff --git a/community/uptimed/PKGBUILD b/community/uptimed/PKGBUILD index 3f6ae3fa8..e3dbdc641 100644 --- a/community/uptimed/PKGBUILD +++ b/community/uptimed/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 72798 2012-06-22 12:52:28Z dreisner $ +# $Id: PKGBUILD 91504 2013-05-23 10:15:34Z spupykin $ # Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> # Maintainer: Bartłomiej Piotrowski <nospam@bpiotrowski.pl> # Contributor: Tom Killian <tomk@runbox.com> @@ -6,7 +6,7 @@ pkgname=uptimed pkgver=0.3.17 -pkgrel=2 +pkgrel=4 pkgdesc="A system uptime record daemon" arch=(i686 x86_64 'mips64el') url="http://podgorny.cz/uptimed/" @@ -16,33 +16,31 @@ backup=(etc/uptimed.conf) options=('!libtool') install=$pkgname.install source=(http://podgorny.cz/$pkgname/releases/$pkgname-$pkgver.tar.bz2 - rc.d service) md5sums=('528b62c33454b33537c3bf2366977bdb' - '4ae90bee9fc78014a889a5072effb735' - '657102b06613ddb9811427bee1973c6b') + '6d1e97b9c54d622edc0bd607acbf3c10') build() { cd $srcdir/$pkgname-$pkgver - + # Change log path to Arch standard for M in `ls M*`; do - sed -i "s|/var/spool/uptimed|$pkgdir/var/log/uptimed|" $M + sed -i "s|/var/spool/uptimed|/var/log/uptimed|" $M done sed -i 's|spool|log|' libuptimed/urec.h + sed -i 's|AM_CONFIG_HEADER|AC_CONFIG_HEADER|g' configure.ac autoreconf libtoolize --force - ./configure --prefix=/usr --sysconfdir=/etc + ./configure --prefix=/usr --sysconfdir=/etc --sbindir=/usr/bin make } package() { cd $srcdir/$pkgname-$pkgver - make prefix=$pkgdir/usr sysconfdir=$pkgdir/etc install + make install DESTDIR=$pkgdir mv $pkgdir/etc/uptimed.conf-dist $pkgdir/etc/uptimed.conf - install -Dm755 $srcdir/rc.d $pkgdir/etc/rc.d/uptimed install -Dm644 $srcdir/service $pkgdir/usr/lib/systemd/system/uptimed.service } diff --git a/community/uptimed/rc.d b/community/uptimed/rc.d deleted file mode 100644 index 6fe9ec3e3..000000000 --- a/community/uptimed/rc.d +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash - -. /etc/rc.conf -. /etc/rc.d/functions - -PID=`pidof -o %PPID /usr/sbin/uptimed` -case "$1" in - start) - stat_busy "Starting Uptimed Daemon" - [ -z "$PID" ] && /usr/sbin/uptimed -b # create the boot record - if [ $? -gt 0 ] ; then - stat_fail - else - add_daemon uptimed # create the 'state' dir - /usr/sbin/uptimed # fire up the daemon - if [ $? -gt 0 ]; then - stat_fail - fi - stat_done - fi - ;; - stop) - stat_busy "Stopping Uptimed Daemon" - [ "$PID" ] && kill $PID &> /dev/null - if [ $? -gt 0 ]; then - stat_fail - else - rm_daemon uptimed # remove the 'state' dir - stat_done - fi - ;; - restart) - $0 stop - $0 start - ;; - *) - echo "usage: $0 {start|stop|restart}" -esac -exit 0 diff --git a/community/uptimed/service b/community/uptimed/service index 2fd785318..36e074d04 100644 --- a/community/uptimed/service +++ b/community/uptimed/service @@ -4,8 +4,8 @@ Description=System uptime record daemon [Service] Type=forking PIDFile=/var/run/uptimed -ExecStartPre=/usr/sbin/uptimed -b -ExecStart=/usr/sbin/uptimed +ExecStartPre=/usr/bin/uptimed -b +ExecStart=/usr/bin/uptimed [Install] WantedBy=multi-user.target diff --git a/community/uptimed/uptimed.install b/community/uptimed/uptimed.install index 178061706..7edd1f66c 100644 --- a/community/uptimed/uptimed.install +++ b/community/uptimed/uptimed.install @@ -1,7 +1,3 @@ -# arg 1: the old package version pre_remove() { - # clean up after ourselves - # - /bin/rm -rf /var/log/uptimed + rm -rf var/log/uptimed } - |