updated on Thu Jan 12 08:01:00 UTC 2012
[aur-mirror.git] / poldi / PKGBUILD
blob8c14704fd256b668b2b551681be1e384ce1125f3
1 # $Id: PKGBUILD 262 2010-11-03 23:24:17Z shtrom $
2 # Contributro: Peter Lewis <prlewis@letterboxes.org>
3 # Maintainer: Olivier Mehani <shtrom-arch@ssji.net>
5 pkgname=poldi
6 pkgver=0.4.1
7 pkgrel=1
8 pkgdesc="PAM module for authentication using a smartcard"
9 arch=('i686' 'x86_64')
10 url="http://http://www.g10code.com/p-poldi.html"
11 license="GPL"
12 depends=('libgcrypt' 'libgpg-error' 'libksba' 'pam')
13 makedepends=()
14 options=()
15 backup=()
16 install=('poldi.install')
17 source=("ftp://ftp.gnupg.org/gcrypt/alpha/poldi/$pkgname-$pkgver.tar.bz2" "poldi-arch.patch")
19 build() {
21   cd "$srcdir/$pkgname-$pkgver"
22   patch -p1 < ../poldi-arch.patch
24   ./configure --prefix=/usr --with-pam-module-directory=/lib/security --sysconfdir=/etc
25   make
28 package() {
29   cd "$srcdir/$pkgname-$pkgver"
31   make DESTDIR="$pkgdir" install
32   make DESTDIR="$pkgdir" install-conf-skeleton
34   mkdir -p "$pkgdir/usr/share/poldi"
35   mv "$pkgdir/etc" "$pkgdir/usr/share/poldi"
36   sed -i "s#^log-file.*#log-file /var/log/poldi.log#" "$pkgdir/usr/share/poldi/etc/poldi/poldi.conf"
38   mkdir -p "$pkgdir/lib/security"
39   cp src/pam/pam_poldi.so "$pkgdir/lib/security/"
40   cp tests/pam-test "$pkgdir/usr/bin/pam-test-poldi"
42   mkdir -p "$pkgdir/etc/pam.d"
43   echo -e "auth\tsufficient\tpam_poldi.so" > $pkgdir/etc/pam.d/poldi
45   rm "$pkgdir/usr/share/info/dir"
47 md5sums=('197986f9ba6aec9a91ee4610f4c6be8b'
48          '3533f7b428e2c9a4bbfff2271ba24e5d')