updated on Thu Jan 5 13:17:10 UTC 2012
[aur-mirror.git] / emacs-chess-git / PKGBUILD
blobbd8cdc97958b995a26173132df587874a234959a
1 # Maintainer: Stefan Husmann <stefan-husmann@t-online.de>
2 pkgname=emacs-chess-git  
3 pkgver=20111122
4 pkgrel=1
5 pkgdesc="Chess client written entirely in Emacs Lisp"
6 arch=('any')
7 url="http://www.newartisans.com/2008/05/emacs-chess-now-hosted-at-github.html"
8 license=('GPL')
9 depends=('emacs')
10 makedepends=('git')
11 optdepends=('crafty: as chess engine' 'gnuchess: as chess engine')
12 install=emacs-chess.install
13 md5sums=()
15 _gitroot="git://github.com/jwiegley/emacs-chess.git"
16 _gitname="emacs-chess"
18 build() {
19   cd "$srcdir"
20   msg "Connecting to GIT server...."
22   if [ -d $_gitname ] ; then
23     cd $_gitname && git pull origin
24     msg "The local files are updated."
25   else
26     git clone $_gitroot $_gitname
27   fi
29   msg "GIT checkout done or server timeout"
31   [ -d "$srcdir/$_gitname-build" ] && rm -rf "$srcdir/$_gitname-build"
32   cd "$srcdir/$_gitname"
33   git submodule init
34   git submodule update    
35   cp -r "$srcdir/$_gitname" "$srcdir/$_gitname-build"
36   cd "$srcdir/$_gitname-build"
38   #
39   # BUILD HERE
40   #
41   ./autogen.sh
42   ./configure --prefix=/usr
43   make
46 package() {
47   cd "$srcdir/$_gitname-build"
48   make DESTDIR="$pkgdir/" install
49   cp -r {pieces,sounds} $pkgdir/usr/share/emacs/site-lisp/
50