updated on Tue Jan 17 12:00:36 UTC 2012
[aur-mirror.git] / dionaea-git / PKGBUILD
blobbf4d959c6dfe84890394f0e013ff6a0d57f9e365
1 # Maintainer: Gagou <gagou@rez-gif.supelec.fr>
2 pkgname=dionaea-git
3 pkgver=20111202
4 pkgrel=1
5 pkgdesc="A nepenthes successor"
6 url="http://dionaea.carnivore.it"
7 license=(GPL)
8 arch=('i686' 'x86_64')
9 depends=('libev' 'cython' 'libpcap' 'libxml2' 'libxslt' 'python3-lxml' 'curl' 'udns' 'glib2' 'gc' 'libemu' 'liblcfg')
10 makedepends=('git')
11 source=(dionaea.confd
12         dionaea.rc
13         makefiles.patch)
14 install=$pkgname.install
15 md5sums=('aa126938ca73b869b3e7db224525bf5b'
16          '4290db0c5dd52063a9a27ee5a8a15d1c'
17                   'e821ffdd91d995c0577e08ccba502cf3')
19 _gitroot="git://git.carnivore.it/dionaea.git"
20 _gitname="dionaea"
22 build() {  
24   msg "Connecting to GIT server...."
26   if [ -d $_gitname ] ; then
27     cd $_gitname && git pull origin
28     msg "The local files are updated."
29   else
30     git clone $_gitroot $_gitname
31   fi
33   msg "GIT checkout done or server timeout"
34   msg "Starting make..."
36   rm -rf "$srcdir/$_gitname-build"
37   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
38   cd "$srcdir/$_gitname-build"
40   # Correct python modules install paths
41   patch -p1 < $srcdir/makefiles.patch
42   # patch -p1 < $srcdir/configure.ac.patch
43   autoreconf -vi
44   unset CFLAGS
45   unset CXXFLAGS
46   ./configure --with-python=/usr/bin/python3 --with-lcfg-lib=/usr/lib/liblcfg/ --with-lcfg-include=/usr/include/ --with-emu-include=/usr/include/ --with-emu-lib=/usr/lib/libemu/ --disable-werror || return 1
47   make || return 1
50 package() {
51   cd "$srcdir/$_gitname-build"
52   make DESTDIR=$pkgdir install
53   install -D -m755 $startdir/dionaea.rc $pkgdir/etc/rc.d/dionaea
54   install -D -m755 $startdir/dionaea.confd $pkgdir/etc/conf.d/dionaea