updated on Fri Jan 13 20:02:10 UTC 2012
[aur-mirror.git] / airgraph-ng-svn / PKGBUILD
blob0ba36cd1f73bd822a12cf8ba23038e12c949e013
1 # Maintainer: Jens Pranaitis <jens@jenux.homelinux.org>
2 # Contributor: Techlive Zheng <techlivezheng [at] gmail [dot] com>
4 pkgname=airgraph-ng-svn
5 pkgdesc="Graphing tool for the aircrack-ng suite"
6 pkgver=1854
7 pkgrel=1
8 arch=('i686' 'x86_64')
9 url="http://www.aircrack-ng.org"
10 license=('GPLv2')
11 depends=('python2' 'graphviz')
12 optdepends=("psyco: JIT compiler for python")
13 makedepends=('subversion')
14 conflicts=('airgraph-ng' 'aircrack-ng-scripts')
15 source=()
16 install=airgraph-ng-svn.install
18 _svnmod=airgraph-ng
19 _svntrunk="http://trac.aircrack-ng.org/svn/trunk/scripts/airgraph-ng"
21 build() {
22   cd ${srcdir}
24   msg "Connecting to SVN server...."
25   if [ -d ${_svnmod}/.svn ]; then
26     msg "Updating airdrop-ng SVN..."
27     svn up ${_svnmod} -r ${pkgver}
28   else
29     msg "Checking out airdrop-ng SVN..."
30     svn co ${_svntrunk} -r ${pkgver} ${_svnmod}
31   fi
32   msg "SVN checkout done or server timeout."
34   msg "Starting make..."
36   if [ -d ${_svnmod}-build/ ]; then
37     msg "Build exists, cleaning it up... "
38     rm -rf ${_svnmod}-build || return 1
39   fi
41   msg "Creating build folder... "
42   svn export ${_svnmod} ${_svnmod}-build
44   grep -rl python ${_svnmod}-build | xargs sed -i 's|python|python2|g' || return 1
47 package() {
48   cd ${srcdir}
50   install -D -m755 ${_svnmod}-build/dump-join               ${pkgdir}/usr/bin/dump-join                      || return 1
51   install -D -m755 ${_svnmod}-build/airgraph-ng             ${pkgdir}/usr/bin/airgraph-ng                    || return 1
52   install -D -m644 ${_svnmod}-build/lib/lib_Airgraphviz.py  ${pkgdir}/usr/lib/airgraph-ng/lib_Airgraphviz.py || return 1
53   install -D -m644 ${_svnmod}-build/man/dump-join.1         ${pkgdir}/usr/share/man/man1/dump-join.1         || return 1
54   install -D -m644 ${_svnmod}-build/man/airgraph-ng.1       ${pkgdir}/usr/share/man/man1/airgraph-ng.1       || return 1
55   install -D -m644 ${_svnmod}-build/README                  ${pkgdir}/usr/share/doc/airgraph-ng/README       || return 1
57   #Remove build directory
58   rm -rf ${_svnmod}-build || return 1
61 md5sums=()