summaryrefslogtreecommitdiff
path: root/community/sarg/PKGBUILD
blob: 4a5b15381e8c9ca0ecb65bfc6ca4abedb92217ad (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
# $Id: PKGBUILD 32752 2010-11-17 21:07:25Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: JJDaNiMoTh <jjdanimoth.aur@gmail.com>
# Contributor: Tino Reichardt <milky-archlinux@mcmilk.de>

pkgname=sarg
pkgver=2.3.1
pkgrel=3
pkgdesc="Squid Analysis Report Generator"
arch=('i686' 'x86_64' 'mips64el')
url="http://sarg.sourceforge.net"
license=('GPL')
depends=('gd' 'libldap')
backup=('etc/sarg/css.tpl'
	'etc/sarg/exclude_codes'
	'etc/sarg/sarg.conf'
	'etc/sarg/user_limit_block')
source=(http://downloads.sourceforge.net/sourceforge/sarg/$pkgname-$pkgver.tar.gz)
md5sums=('bf637b8a820b81e2c55e815934151b4d')

build() {
  cd ${srcdir}/$pkgname-$pkgver
#  ./configure --prefix="/usr" \
#    --enable-sargphp="/usr/share/sarg/sarg-php" \
#    --sysconfdir="/etc/sarg" \
#    --mandir="/usr/share/man/man1"
  cmake -DCMAKE_INSTALL_PREFIX=/usr -DSYSCONFDIR=/etc/sarg -DMANDIR=/usr/share/man/man1 .
  make
}

package() {
  cd ${srcdir}/$pkgname-$pkgver
  mkdir -p $pkgdir/usr/share/sarg $pkgdir/etc
  make DESTDIR="$pkgdir" install
  cp -a sarg-php ${pkgdir}/usr/share/sarg/
  # silence namcap warnings
  chmod -R o+r ${pkgdir}{/etc,/usr/share/sarg}
  chmod o+x ${pkgdir}/usr/share/sarg/sarg-php
  chmod -R o+x ${pkgdir}/usr/share/sarg/sarg-php/locale
}