summaryrefslogtreecommitdiff
path: root/community/uptimed/PKGBUILD
blob: 87ec6b8218ec57687ecf08bef0f5644f3c332e70 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# $Id: PKGBUILD 17435 2010-05-24 10:30:22Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: Tom Killian <tomk@runbox.com>
# Contributor: Tom Newsom <Jeepster@gmx.co.uk>

pkgname=uptimed
pkgver=0.3.16
pkgrel=3
pkgdesc="A system uptime record daemon"
arch=(i686 x86_64 'mips64el')
install=$pkgname.install
url="http://podgorny.cz/uptimed/"
license=('GPL')
depends=('glibc')
backup=(etc/uptimed.conf)
source=(http://podgorny.cz/$pkgname/releases/$pkgname-$pkgver.tar.bz2
	uptimed)
md5sums=('f87ec2cc39039239004afa542cf99c59'
         '4ae90bee9fc78014a889a5072effb735')

build() {
  cd $startdir/src/$pkgname-$pkgver
  
  # Change log path to Arch standard
  for M in `ls M*`; do
    sed -i "s|/var/spool/uptimed|$startdir/pkg/var/log/uptimed|" $M
  done
  sed -i 's|spool|log|' libuptimed/urec.h

  autoreconf
  libtoolize --force

  ./configure --prefix=/usr --sysconfdir=/etc

  make || return 1
  make prefix=$startdir/pkg/usr sysconfdir=$startdir/pkg/etc install

  mv $startdir/pkg/etc/uptimed.conf-dist \
    $startdir/pkg/etc/uptimed.conf
  install -D ../uptimed $startdir/pkg/etc/rc.d/uptimed
  find $startdir/pkg -name '*.la' -exec rm {} \;
}