summaryrefslogtreecommitdiff
path: root/community/xmoto/PKGBUILD
blob: ad1c581a8951c1b7a15fdb2135bba74a98128c29 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# $Id: PKGBUILD 77670 2012-10-13 11:46:18Z allan $
# Maintainer: Ronald van Haren <ronald.archlinux.org>
# Contributor: Travis Willard <travisw@wmpub.ca> 
# Contributor: Denis (dtonator@gmail.com)

pkgname=xmoto
pkgver=0.5.10
pkgrel=2
pkgdesc="A challenging 2D motocross platform game, where physics play an important role."
arch=('i686' 'x86_64')
url="http://xmoto.tuxfamily.org"
license=('GPL')
depends=('libjpeg' 'libpng' 'lua' 'sdl_mixer' 'ode' 'curl' 
	 'sqlite3' 'sdl_ttf' 'desktop-file-utils' 'sdl_net' 'glu'
         'libxdg-basedir' 'libxml++')
makedepends=('mesa')
install=xmoto.install
source=("http://download.tuxfamily.org/${pkgname}/${pkgname}/${pkgver}/${pkgname}-${pkgver}-src.tar.gz"
        'xmoto-0.5.10-libpng15.patch'
        'system.cpp.patch')
sha1sums=('692d50a9c91791cd06ee84846632651b44544fcc'
          '9d13fa09f1c558a0fc504f7e7b1ceac6b4b7b20d'
          'e741f769d1fc5779a6688970ee97e2a61a50c7ae')

build() {
  cd ${srcdir}/${pkgname}-${pkgver}

  patch -Np1 -i "${srcdir}/xmoto-0.5.10-libpng15.patch"
  patch -Np1 -i "${srcdir}/system.cpp.patch"

  # build and install 
  ./configure LDFLAGS="-L/usr/lib" --prefix=/usr --disable-sdltest

  make
}

package() {
  cd ${srcdir}/${pkgname}-${pkgver}
  make DESTDIR=${pkgdir} mangdir=/usr/share/man/man6 install

  # install desktop file
  install -Dm0644 ${srcdir}/${pkgname}-${pkgver}/extra/xmoto.desktop \
        ${pkgdir}/usr/share/applications/xmoto.desktop

  # install icon for desktop file
  install -Dm0644 ${srcdir}/${pkgname}-${pkgver}/extra/xmoto.xpm \
        ${pkgdir}/usr/share/pixmaps/xmoto.xpm
}