updated on Thu Jan 12 08:01:00 UTC 2012
[aur-mirror.git] / gplanarity-svn / PKGBUILD
blob57d3880c4630ca0705dbba92e7af836343debb5c
1 # Contributor: Geoffroy Carrier <geoffroy.carrier@koon.fr>
2 # Contributor: Sebastien Duthil <duthils@free.fr>
3 pkgname=gplanarity-svn
4 pkgver=17906
5 pkgrel=1
6 pkgdesc="A simple puzzle game involving untangling planar graphs for fun and prizes"
7 arch=('i686' 'x86_64')
8 url="http://web.mit.edu/xiphmont/Public/gPlanarity.html"
9 license=('GPL')
10 depends=(gtk2)
11 makedepends=(subversion)
12 provides=(gplanarity)
13 conflicts=(gplanarity)
14 replaces=(gplanarity)
15 source=(gplanarity.desktop)
16 md5sums=('b9ab28c98c15f6898e6f9fbd7d6c1c20')
18 _svntrunk=http://svn.xiph.org/trunk/planarity/
19 _svnmod=planarity
21 build() {
22     cd "$srcdir"
24     if [ -d "$_svnmod/.svn" ]; then
25         (cd "$_svnmod" && svn up -r "$pkgver")
26     else
27         svn co "$_svntrunk" --config-dir ./ -r "$pkgver" "$_svnmod"
28     fi
30     msg "SVN checkout done or server timeout"
32     # Create build directory
33     if [ -d "$srcdir/$_svnmod-build" ] ; then
35         # Need 'force' option to delete .svn directory (has read-only files)
36         rm -rf "$srcdir/$_svnmod-build"
37     fi
38     cp -r "$_svnmod" "$_svnmod-build"
39     cd "$_svnmod-build"
41     msg "Starting make..."
43     # Disable NLS, or it won't compile
44     if test "$CARCH" == x86_64; then
45         make DISABLE_NLS=true LIBS=-lm
46     else
47         make DISABLE_NLS=true
48     fi
51 package() {
52     install -Dm755 "$srcdir/gplanarity.desktop" "$pkgdir/usr/share/applications/gplanarity.desktop"
53     install -Dm755 "$_svnmod-build/gPlanarity" "$pkgdir/usr/bin/gplanarity"
54     install -Dm755 "$_svnmod-build/gPicon.png" "$pkgdir/usr/share/pixmaps/gplanarity.png"