diff options
author | smls | 2015-07-10 01:11:15 +0200 |
---|---|---|
committer | smls | 2015-07-10 01:11:15 +0200 |
commit | 8e4adb5c05b1eb1d43ef9dbdcf7ac7163d1b9eeb (patch) | |
tree | e61045bef6958beb06a3a77e180b415c83c61436 | |
parent | 09f91f80ee71af92d0fa1c57586e241a8c46269a (diff) | |
download | aur-8e4adb5c05b1eb1d43ef9dbdcf7ac7163d1b9eeb.tar.gz |
Fix permissions, and remove unneeded files
-rw-r--r-- | .SRCINFO | 7 | ||||
-rw-r--r-- | PKGBUILD | 50 |
2 files changed, 44 insertions, 13 deletions
@@ -5,6 +5,13 @@ pkgbase = atomzombiesmasher-hib url = http://blendogames.com/atomzombiesmasher/ arch = any license = custom:commercial + depends = openal + depends = flac + depends = libpng12 + depends = libjpeg6 + depends = libtiff3 + depends = libgdiplus + depends = csfml-bin conflicts = atomzombiesmasherdemo conflicts = atomzombiesmasher source = atomzombiesmasher_v1_953-er.tar.gz::hib://atomzombiesmasher_v1_953-er.tar.gz @@ -10,8 +10,10 @@ pkgdesc="A 2D tactics/strategy game where you evacuate civilians from zombie-inf arch=('any') url="http://blendogames.com/atomzombiesmasher/" license=("custom:commercial") -depends_x86_64=('libgdiplus' 'mono' 'csfml-bin') +depends=('openal' 'flac' 'libpng12' 'libjpeg6' 'libtiff3' + 'libgdiplus' 'csfml-bin') conflicts=("atomzombiesmasherdemo" "atomzombiesmasher") +PKGEXT='.pkg.tar' _gamepkg="atomzombiesmasher_$_hibver.tar.gz" source=("$_gamepkg::hib://$_gamepkg" @@ -22,32 +24,54 @@ md5sums=("6902c845a21e92c62f5b33b38715c797" "341ce551a8525be96d6c59c1bf9efd2a") _installname=atomzombiesmasher +case $CARCH in + i686) _arch=x86; _other=x86_64; _lib=lib; _libother=lib64 ;; + x86_64) _arch=x86_64; _other=x86; _lib=lib64; _libother=lib ;; +esac + [ $CARCH == "i686" ] && _arch=x86 || _arch=x86_64 prepare() { + # Create custom launcher echo -e "#!/usr/bin/sh\n" \ "export MONO_WINFORMS_XIM_STYLE=disabled\n" \ - "cd /opt/$_installname/game\n" \ - "./AtomZombieSmasher.bin.$_arch" '"$@"' \ + "cd /opt/$_installname\n" \ + "exec ./AtomZombieSmasher.bin.$_arch" '"$@"' \ > "launcher.sh" - mv $_installname/readme.html . + + cd $_installname + + # Fix permissions + find -type f -exec chmod 644 {} \; + chmod +x game/AtomZombieSmasher.bin* + + # Remove unneeded files + rm game/AtomZombieSmasher.bin.$_other + rm -r game/$_libother + ls game/$_lib/ + rm -r game/$_lib/{libcsfml*,libsfml*} + rm -r game/$_lib/{libopenal.so.1,libFLAC.so.8,libgdiplus.so} + rm -r game/$_lib/{libjpeg.so.62,libpng12.so.0,libtiff.so.3} + + # Set apart files to install separately + mv readme.html "$srcdir" } package() { # Game data - install -g games -d $pkgdir/opt/$_installname - cp -rT $_installname "$pkgdir"/opt/$_installname + install -g games -d "$pkgdir"/opt/$_installname + cp -rT $_installname/game "$pkgdir"/opt/$_installname # Readme - install -D readme.html \ - "$pkgdir"/usr/share/doc/$_installname/readme.html + install -Dm644 readme.html \ + "$pkgdir"/usr/share/doc/$_installname/readme.html # Desktop entry - install -D $_installname.desktop \ - "$pkgdir"/usr/share/applications/$_installname.desktop - install -D atom-zombie-smashertCCn9V.png \ - "$pkgdir"/usr/share/pixmaps/$_installname.png - + install -Dm644 $_installname.desktop \ + "$pkgdir"/usr/share/applications/$_installname.desktop + install -Dm644 atom-zombie-smashertCCn9V.png \ + "$pkgdir"/usr/share/pixmaps/$_installname.png + # Launcher install -Dm755 launcher.sh "$pkgdir"/usr/bin/$_installname } |