updated on Thu Jan 19 12:17:07 UTC 2012
[aur-mirror.git] / shairport-git / PKGBUILD
blob0e6c9628faa097bca5f6bfcb79237d8e1150a758
1 # See http://wiki.archlinux.org/index.php/VCS_PKGBUILD_Guidelines
2 # for more information on packaging from GIT sources.
4 # Maintainer: Falk Stern <falk@fourecks.de>
5 pkgname=shairport-git
6 pkgver=20110529
7 pkgrel=1
8 pkgdesc="an AirTunes/raop server"
9 arch=(i686 x86_64)
10 url="https://github.com/albertz/shairport"
11 license=('shairport')
12 depends=(avahi libao openssl perl-libwww perl-crypt-openssl-rsa)
13 optdepends=('perl-io-socket-inet6: to work with iTunes')
14 makedepends=('git' libao openssl)
15 provides=(shairport)
16 source=('shairport.confd'
17         'shairport.init')
18 md5sums=('f53311177bffbac70611d7e33bebe827'
19          'c3145311b03ca709700e0846e7f8452d')
21 _gitroot="https://github.com/albertz/shairport.git"
22 _gitname="shairport"
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 make..."
38   rm -rf "$srcdir/$_gitname-build"
39   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
40   cd "$srcdir/$_gitname-build"
42   #
43   # BUILD HERE
44   #
46   make
49 package() {
50   install -Dm644 ../shairport.confd "${pkgdir}"/etc/conf.d/shairport
51   install -Dm755 ../shairport.init "${pkgdir}"/etc/rc.d/shairport
52   cd "$srcdir/$_gitname-build"
53   make DESTDIR="$pkgdir/" prefix=/usr install
54   install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
55   install -Dm644 README.md "${pkgdir}"/usr/share/doc/${pkgname}/README.md
56   
57