Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Maintainer: Tiago Pierezan Camargo <tcamargo@gmail.com
- # Contributor: Paul Bredbury <brebs@sent.com>
- # Contributor: Benjamin Dirks <asaru[at]wtnet[dot]de>
- pkgname=worldofpadman
- pkgver=1.5.1
- pkgrel=0
- pkgdesc="Cartoon-style multiplayer first-person shooter"
- arch=(i686 x86_64)
- url="http://www.worldofpadman.com/"
- license=('GPL' 'custom')
- depends=('curl' 'libogg' 'libvorbis' 'mesa' 'openal' 'sdl')
- makedepends=('unzip')
- source=(
- wop-1.5-unified.zip::http://sourceforge.net/projects/wop-engine/files/v1.5/wop-1.5-unified.zip/download
- wop-1.5.1-hotfix.zip::http://sourceforge.net/projects/wop-engine/files/v1.5/wop-1.5.1-hotfix.zip/download
- worldofpadman.desktop
- wop.png
- )
- md5sums=(
- '8871affc2a36f23aa22044454c834923'
- 'e7e300a6229a167573ccc370a8cc478e'
- '0115c41ec5cb5b7e098edcb3df7db4d9'
- 'db6877696be70a278c27223c35f43188'
- )
- _gamedir="/usr/share/$pkgname"
- build() {
- cd "$srcdir"
- ## Binaries
- if [ "$CARCH" == i686 ] ; then
- install -D -m755 wop.i386 "$pkgdir/$_gamedir/wop.bin" || return 1
- install -D -m755 wopded.i386 "$pkgdir/$_gamedir/wopded.bin" || return 1
- fi
- if [ "$CARCH" == x86_64 ] ; then
- install -D -m755 wop.x86_64 "$pkgdir/$_gamedir/wop.bin" || return 1
- install -D -m755 wopded.x86_64 "$pkgdir/$_gamedir/wopded.bin" || return 1
- fi
- cat >wop.sh <<EOF
- #!/bin/bash
- cd $_gamedir && exec ./wop.bin "\$@"
- EOF
- cat >wopded.sh <<EOF
- #!/bin/bash
- cd $_gamedir && exec ./wopded.bin "\$@"
- EOF
- install -D -m755 wop.sh "$pkgdir/usr/bin/wop" || return 1
- install -D -m755 wopded.sh "$pkgdir/usr/bin/wopded" || return 1
- # Data
- # Using "read", so can handle filenames containing spaces
- find wop -type f | while read _f ; do
- install -D -m644 "$_f" "${pkgdir}/$_gamedir/$_f" || return 1
- done
- # Return from the function, since install's return just exits the loop
- # See http://fvue.nl/wiki/Bash:_Error_handling
- [ $? -gt 0 ] && return 1
- # Desktop
- install -D -m644 ${srcdir}/wop.png ${pkgdir}/usr/share/pixmaps/$pkgname.png || return 1
- install -D -m644 ${srcdir}/$pkgname.desktop ${pkgdir}/usr/share/applications/$pkgname.desktop || return 1
- # Docs
- cd "$srcdir/XTRAS" || return 1
- # Using "read", so can handle filenames containing spaces
- find . -type f | while read _f ; do
- install -D -m644 "$_f" "${pkgdir}/usr/share/doc/$pkgname/$_f" || return 1
- done
- # Return from the function, since install's return just exits the loop
- # See http://fvue.nl/wiki/Bash:_Error_handling
- [ $? -gt 0 ] && return 1
- # License
- install -D -m644 copyright_en.txt "${pkgdir}/usr/share/licenses/$pkgname/COPYING" || return 1
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement