updated on Fri Jan 6 08:01:17 UTC 2012
[aur-mirror.git] / smw-svn / PKGBUILD
blob27ed7f8352a431238a2eb5a2ee46bf400f3976d9
1 # Contributor: Evangelos Foutras <foutrelis@gmail.com>
2 # Contributer: Matthew Bauer <mjbauer95@gmail.com>
4 pkgname=smw-svn
5 _pkgname=smw
6 pkgver=357
7 pkgrel=1
8 pkgdesc="A Super Mario multiplayer game"
9 arch=('i686' 'x86_64')
10 url="http://smw.72dpiarmy.com/"
11 license=('GPL2')
12 depends=('gcc-libs' 'sdl_mixer' 'sdl_image' 'desktop-file-utils')
13 makedepends=('bin86')
14 install=smw.install
15 source=($_pkgname.desktop
16         $_pkgname.png
17         gcc.patch)
18 md5sums=('78b87b9c99c232ecc9f659a4994da12b'
19         'b7f5ef181e41eb0339be746ea03ff628'
20         '67a5549b9812427feb541ce8d5fb384d')
21 provides=("smw")
22 conflicts=("smw")
24 _svntrunk=svn://svn.72dpiarmy.com/smw
25 _svnmod=smw
27 build() {
28         cd "$srcdir"
30         if [ -d $_svnmod/.svn ]; then
31                 (cd $_svnmod && svn up -r $pkgver)
32         else
33                 svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod
34         fi
36         msg "SVN checkout done or server timeout"
37         msg "Starting make..."
39 #       rm -rf "$srcdir/$_svnmod-build"
40 #       cp -r "$srcdir/$_svnmod" "$srcdir/$_svnmod-build"
41         cd "$srcdir/$_svnmod"
43         patch -p1 -i ../gcc.patch
45         ./configure
46         make || return 1
47         make DESTDIR="$pkgdir" install
49         # Set sane permissions
50         find "$pkgdir/usr/share/games/$_pkgname" -type d -exec chmod 755 {} \;
51         find "$pkgdir/usr/share/games/$_pkgname" -type f -exec chmod 644 {} \;
53         # Install application shortcut and icon
54         install -D -m644 "$srcdir/$_pkgname.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
55         install -D -m644 "$srcdir/$_pkgname.png" "$pkgdir/usr/share/pixmaps/$pkgname.png"
57         mkdir -p $pkgdir/usr/bin
58         ln -s /usr/games/smw $pkgdir/usr/bin
59         ln -s /usr/games/smw-leveledit $pkgdir/usr/bin
60         ln -s /usr/games/smw-worldedit $pkgdir/usr/bin