updated on Fri Jan 20 20:16:25 UTC 2012
[aur-mirror.git] / toribash / PKGBUILD
blobceadcef1084a30930eae4cf6f6a30ced394b898a
1 # Contributor: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
3 pkgname=toribash
4 pkgver=3.50
5 pkgrel=1
6 pkgdesc="A ragdoll-physics, turn-based fighting game from Sweden."
7 arch=('i686' 'x86_64')
8 url="http://www.toribash.com"
9 license=('custom')
10 depends=('freeglut' 'lua' 'sdl_mixer' 'sdl_ttf')
12 if [ "$CARCH" = "x86_64" ]; then
13    source=(http://linux.toribash.com/download/amd64/${pkgname}-${pkgver}-amd64.tar.gz \
14            ${pkgname}.sh)
15    md5sums=('eb94fce80c5b5344c209602d52091fb4'
16             '80db069e676974fa2b5787b7c2933b72')
17  else
18    source=(http://linux.toribash.com/download/i386/${pkgname}-${pkgver}-i386.tar.gz \
19            ${pkgname}.sh)
20    md5sums=('d2bce1f65caf4f012df2da5a8c191591'
21             '80db069e676974fa2b5787b7c2933b72')
25 build() {
26 # ---------------------- i686 architecture ----------------------
27 if [ "$CARCH" = "i686" ]; then
28   cd "${srcdir}/${pkgname}-${pkgver}-i386"
29   install -d "${pkgdir}/opt/toribash" || return 1
30   cp -R * "${pkgdir}/opt/toribash" || return 1
32 # ---------------------- x86_64 architecture --------------------
33 elif [ "$CARCH" = "x86_64" ]; then
34   cd "${srcdir}/${pkgname}-${pkgver}-amd64"
35   install -d "${pkgdir}/opt/toribash" || return 1
36   cp -a * "${pkgdir}/opt/toribash" || return 1
39 # ---------------------- both architectures ---------------------
40   install -D -m755 "${srcdir}/$pkgname.sh" "${pkgdir}/usr/bin/$pkgname"
41   install -d "${pkgdir}/usr/bin" "${pkgdir}/usr/lib" "${pkgdir}/usr/share/licenses/$pkgname" || return 1
42   ln -s "liblua.so.5.1" "${pkgdir}/usr/lib/liblua5.1.so.0" || return 1
43   ln -s "/opt/$pkgname/license.txt" "${pkgdir}/usr/share/licenses/$pkgname/LICENSE" || return 1