updated on Fri Jan 13 04:01:25 UTC 2012
[aur-mirror.git] / srw-hg / PKGBUILD
blobe1685322ec62c8844f762a12156c25333b448a11
1 # Maintainer: tjwoosta <tjwoosta@gmail.com>
2 pkgname=srw-hg
3 pkgver=86
4 pkgrel=1
5 pkgdesc="A simple read wrapper."
6 arch=('i686' 'x86_64')
7 url="http://deepcube.net/code/srw/"
8 license=('MIT')
9 depends=()
10 makedepends=('mercurial')
11 provides=(srw)
12 conflicts=(srw)
14 _hgroot="https://bitbucket.org/emg"
15 _hgrepo="srw"
17 build() {
18   cd "$srcdir"
19   msg "Connecting to Mercurial server...."
21   if [ -d $_hgrepo ] ; then
22     cd $_hgrepo
23     hg pull -u
24     msg "The local files are updated."
25   else
26     hg clone $_hgroot $_hgrepo
27   fi
29   msg "Mercurial checkout done or server timeout"
30   msg "Starting make..."
32   rm -rf "$srcdir/$_hgrepo-build"
33   cp -r "$srcdir/$_hgrepo" "$srcdir/$_hgrepo-build"
34   cd "$srcdir/$_hgrepo-build"
36   make
39 package() {
40   cd "$srcdir/$_hgrepo-build"
41   make PREFIX="/usr" DESTDIR="$pkgdir/" install
42   install -D -m644 LICENSE \
43         "$pkgdir/usr/share/licenses/$pkgname/license.txt"
44