updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / perl-digest-ed2k / PKGBUILD
bloba0f63cd6ffb5943bf5da5b77712d7642014fa8d8
1 # Maintainer: kevku <kevku@msn.com>
2 pkgname=perl-digest-ed2k
3 pkgver=0.1.0
4 pkgrel=1
5 pkgdesc="Perl implementation of the ED2k hash used in ED2K URIs."
6 arch=('any')
7 url="https://github.com/Kulag/Digest-ED2K"
8 license=('GPL' 'PerlArtistic')
9 depends=('perl>=5.10.0' 'perl-exporter-tidy' 'perl-common-sense' 'perl-digest-md4')
10 makedepends=('git')
11 options=(!emptydirs)
13 _gitroot="https://github.com/Kulag/Digest-ED2K.git"
14 _gitname="Digest-ED2K"
16 build() {
17   cd "$srcdir"
18   msg "Connecting to GIT server...."
20   if [ -d $_gitname ] ; then
21     cd $_gitname && git pull origin
22     msg "The local files are updated."
23   else
24     git clone $_gitroot $_gitname
25   fi
27   msg "GIT checkout done or server timeout"
28   msg "Starting make..."
30   rm -rf "$srcdir/$_gitname-build"
31   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
32   cd "$srcdir/$_gitname-build"
34   perl Build.PL installdirs=vendor destdir="$pkgdir/"
35   perl Build
38 package() {
39   cd "$srcdir/$_gitname-build"
40   perl Build install
41