updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / batman-adv-git / PKGBUILD
blob80704024ada890990ac14478a9f611510b4cb1b1
1 # Maintainer: Splex
2 pkgname=batman-adv-git
3 pkgver=20111004
4 pkgrel=1
5 pkgdesc="An implementation of the B.A.T.M.A.N. routing protocol in form of a linux kernel module operating on layer 2."
6 arch=('i686' 'x86_64')
7 url="http://http://www.open-mesh.org"
8 license=('GPL')
9 depends=('kernel26')
10 makedepends=('kernel26-headers' 'git')
11 optdepends=('batctl: CLI tool to control batman devices')
12 provides=('batman-adv')
13 conflicts=('batman-adv')
14 replaces=('batman-adv')
15 backup=()
16 install=batman-adv-git.install
17 source=()
18 noextract=()
19 md5sums=()
21 _gitroot=http://git.open-mesh.org/batman-adv.git
22 _gitname=batman-adv
24 build() {
25   cd "$srcdir"
26   msg "Connecting to GIT server...."
28   if [[ -d "$_gitname" ]]; then
29     cd "$_gitname" && git pull origin
30     msg "The local files are updated."
31   else
32     git clone "$_gitroot" "$_gitname"
33   fi
35   msg "GIT checkout done or server timeout"
36   msg "Starting build..."
38   rm -rf "$srcdir/$_gitname-build"
39   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
40   cd "$srcdir/$_gitname-build"
42   make
45 package() {
46   cd "$srcdir/$_gitname-build"
47   install -D -m644 batman-adv.ko ${pkgdir}/lib/modules/$(uname -r)/updates/net/batman-adv/batman_adv.ko
48   install -D -m644 README ${pkgdir}/usr/share/doc/batman-adv/README
51 # vim:set ts=2 sw=2 et: