updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / geneticinvasion / PKGBUILD
blob4a400e6d91b31d9f6943ba264a50d4e98e2f74e3
1 # Contributor: MCMic <come.bernigaud@laposte.net>
3 pkgname=geneticinvasion
4 pkgver=0.5.2
5 pkgrel=1
6 pkgdesc="A Tower Defence game that uses evolutionary algorithm"
7 arch=('i686' 'x86_64')
8 url="http://projects.haxx.es/p/genetic-invasion"
9 license=('GPL')
10 depends=('libeo' 'mesa')
11 makedepends=('make' 'cmake')
12 conflicts=()
13 if test "$CARCH" == 'i686'; then
14     sfml_arch=32
15 else
16     sfml_arch=64
18 source=("http://projects.haxx.es/media/upload/genetic-invasion/files/genetic-invasion-v$pkgver.zip" "http://downloads.sourceforge.net/sfml/SFML-1.6-sdk-linux-$sfml_arch.tar.gz" 'FindSFML.cmake')
19 if test "$sfml_arch" == "32"; then
20     md5sums=('a9b3b6e128170afb167a45616d6ea022' 
21              'acc678933c19558587aad8332ea6f459' 
22              'f6358382450150804d773a1d0b0777db')
23 else
24     md5sums=('a9b3b6e128170afb167a45616d6ea022' 
25              '7a9b3a1ef6d14cd25090e440ccdbb3a8'
26              'f6358382450150804d773a1d0b0777db')
29 build() {
30     cd $srcdir/SFML-1.6/
31     sed -i "24i#define NULL 0" include/SFML/System/ResourcePtr.inl
32     make STATIC=yes
33     sed -i "24d" include/SFML/System/ResourcePtr.inl
34     
35     cd $srcdir/genetic-invasion-v$pkgver
36     cp $srcdir/FindSFML.cmake $srcdir/genetic-invasion-v$pkgver/cmake/modules
37         cmake -DCMAKE_BUILD_TYPE=Release -DSFML_STATIC=true -DSFMLDIR=../SFML-1.6 -DCMAKE_INSTALL_PREFIX=/usr .
38         make
39         make install DESTDIR=$pkgdir