updated on Thu Jan 19 00:16:31 UTC 2012
[aur-mirror.git] / smw-svn / PKGBUILD
blobc445bdd01edb32c6b379f53244e0a2b18a12f1e8
1 # Contributor: Evangelos Foutras <foutrelis@gmail.com>
2 # Contributer: Matthew Bauer <mjbauer95@gmail.com>
4 pkgname=smw-svn
5 _pkgname=smw
6 pkgver=6
7 pkgrel=1
8 pkgdesc="A Super Mario multiplayer game"
9 arch=('i686' 'x86_64')
10 url="http://smw.supersanctuary.net/"
11 license=('GPL2')
12 depends=('gcc-libs' 'sdl_mixer' 'sdl_image' 'desktop-file-utils')
13 makedepends=('bin86' 'hd2u')
14 install=smw.install
15 source=($_pkgname.desktop
16         $_pkgname.png
17         gcc.patch)
18 md5sums=('78b87b9c99c232ecc9f659a4994da12b'
19         'b7f5ef181e41eb0339be746ea03ff628'
20         '586cf917af0a81912d8c5c0fcfddb64b')
21 provides=("smw")
22 conflicts=("smw")
24 _svntrunk=https://supermariowar.googlecode.com/svn/trunk/
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         dos2unix -U configure
44         chmod +x configure
46         patch --forward -p0 -i ../gcc.patch
48         ./configure
49         make || return 1
50         make DESTDIR="$pkgdir" install
52         # Set sane permissions
53         find "$pkgdir/usr/share/games/$_pkgname" -type d -exec chmod 755 {} \;
54         find "$pkgdir/usr/share/games/$_pkgname" -type f -exec chmod 644 {} \;
56         # Install application shortcut and icon
57         install -D -m644 "$srcdir/$_pkgname.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
58         install -D -m644 "$srcdir/$_pkgname.png" "$pkgdir/usr/share/pixmaps/$pkgname.png"
60         mkdir -p $pkgdir/usr/bin
61         ln -s /usr/games/smw $pkgdir/usr/bin
62         ln -s /usr/games/smw-leveledit $pkgdir/usr/bin
63         ln -s /usr/games/smw-worldedit $pkgdir/usr/bin