updated on Sun Jan 15 16:02:00 UTC 2012
[aur-mirror.git] / tripwire / PKGBUILD
blob2a4fefd8cec9d29c88ce7e47ef3bc93fb58a8be8
1 # Contributor: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
2 # Contributor: Jaroslaw Swierczynski <swiergot@juvepoland.com>
3 # Contributor: eliott <eliott@cactuswax.net>
5 pkgname=tripwire
6 pkgver=2.4.2
7 pkgrel=1
8 pkgdesc="An intrusion detection system"
9 arch=('i686' 'x86_64')
10 url="http://sourceforge.net/projects/tripwire/"
11 license=('GPL')
12 depends=('openssl')
13 backup=('etc/tripwire/twpol.txt' 'etc/tripwire/twcfg.txt')
14 install=$pkgname.install
15 #options=('!makeflags')
16 source=(http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver-src.tar.bz2 \
17         twpol.txt twcfg.txt)
18 sha256sums=('af89a368ed25a0edd7283fffa05a3b659e06f693626b947644dec60d0dc482b7'
19             '4da49a185fee570e0a7bdc7acaadc0d2bf7f4c488057e93e60b2a2819807cd9d'
20             '3aaa567f7a0a4efce3ac127344a9b795c5494c9d011e27a7d454d632ba3d533d')
22 build() {
23   cd ${srcdir}/$pkgname-$pkgver-src
25 #build package
26 #  CFLAGS="$CFLAGS -fno-strict-aliasing" CXXFLAGS="$CXXFLAGS -fno-strict-aliasing" \
27     ./configure --prefix=/usr --sysconfdir=/etc/tripwire
28   make
31 package () {
32   cd ${srcdir}/$pkgname-$pkgver-src
34   # This package doesn't have a typical make install, so we do it by hand.
35   #make DESTDIR=${pkgdir} install
37 #create var/lib directories
38   install -d ${pkgdir}/var/lib
39   install -d -m700 ${pkgdir}/var/lib/tripwire
40   install -d -m700 ${pkgdir}/var/lib/tripwire/report
42 #install binaries
43   install -d ${pkgdir}/usr/sbin
44   install -m755 bin/siggen ${pkgdir}/usr/sbin/
45   install -m755 bin/tripwire ${pkgdir}/usr/sbin/
46   install -m755 bin/twadmin ${pkgdir}/usr/sbin/
47   install -m755 bin/twprint ${pkgdir}/usr/sbin/
49 #copy install files for use by user after install, and fix a path
50   install -d ${pkgdir}/usr/share/$pkgname
51   install -m755 install/install.sh ${pkgdir}/usr/share/$pkgname/
52   install -m644 install/install.cfg ${pkgdir}/usr/share/$pkgname/
53   sed -i 's#./install/install.cfg#./install.cfg#' ${pkgdir}/usr/share/$pkgname/install.sh
55 #install man pages - FS#13766 fixed
56   install -d ${pkgdir}/usr/share/man/{man4,man5,man8}
57   install -m644 man/man4/*.4 ${pkgdir}/usr/share/man/man4/
58   install -m644 man/man5/*.5 ${pkgdir}/usr/share/man/man5/
59   install -m644 man/man8/*.8 ${pkgdir}/usr/share/man/man8/
61 #install configuration files
62   install -d ${pkgdir}/etc/$pkgname
63   install -m644 ${srcdir}/twpol.txt ${pkgdir}/etc/tripwire/twpol.txt
64   install -m644 ${srcdir}/twcfg.txt ${pkgdir}/etc/tripwire/twcfg.txt