# $Id: $
# Maintainer: Jan de Groot <jgc@archlinux.org>

pkgname=libutempter
pkgver=1.1.6
pkgrel=3
pkgdesc="Interface for terminal emulators such as screen and xterm to record user sessions to utmp and wtmp files"
arch=('x86_64')
url="ftp://ftp.altlinux.org/pub/people/ldv/utempter"
license=('LGPL')
depends=('glibc')
source=(ftp://ftp.altlinux.org/pub/people/ldv/utempter/$pkgname-$pkgver.tar.bz2)
sha512sums=('6ada410b981d157ae20b578de8ce20997ec0446ec6de6859549b080aa65976fc9900d211600dab09dc3d0d109daabad0994a648b093b8781b442ff26ca17fede')

build() {
  cd "$srcdir/$pkgname-$pkgver"
  RPM_OPT_FLAGS="$CFLAGS" make
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver"
  make DESTDIR="$pkgdir" install
  chown root:utmp "$pkgdir/usr/lib/utempter/utempter"
  chmod 2755 "$pkgdir/usr/lib/utempter/utempter"
}
