diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-01-09 04:39:32 -0200 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-01-09 04:39:32 -0200 |
commit | f6fc3d982a13389b2e9937258542828e6a9d54fa (patch) | |
tree | 438a6527c3331c6682829d739953000f21a1821e /libre/abuse-libre | |
parent | 15eae1c0628fb12c17af2d78080b0553253fca21 (diff) | |
download | abslibre-f6fc3d982a13389b2e9937258542828e6a9d54fa.tar.gz abslibre-f6fc3d982a13389b2e9937258542828e6a9d54fa.tar.bz2 abslibre-f6fc3d982a13389b2e9937258542828e6a9d54fa.zip |
abuse-libre-0.8-4: updating revision, add mksource and fix syntax on provides, replaces and conflicts lines
* add desktop shortcut and made it X-friendly
* add missing .install file
* fix default settings so they also work if running the game in a virtual installation of Parabola
Diffstat (limited to 'libre/abuse-libre')
-rw-r--r-- | libre/abuse-libre/PKGBUILD | 80 | ||||
-rw-r--r-- | libre/abuse-libre/abuse.install | 16 | ||||
-rw-r--r-- | libre/abuse-libre/abuse.sh | 15 | ||||
-rw-r--r-- | libre/abuse-libre/default.abuserc | 37 | ||||
-rw-r--r-- | libre/abuse-libre/default.gamma.lsp | 1 | ||||
-rw-r--r-- | libre/abuse-libre/rePKGBUILD | 33 |
6 files changed, 119 insertions, 63 deletions
diff --git a/libre/abuse-libre/PKGBUILD b/libre/abuse-libre/PKGBUILD index 7c99acf76..caa9fd167 100644 --- a/libre/abuse-libre/PKGBUILD +++ b/libre/abuse-libre/PKGBUILD @@ -1,5 +1,6 @@ -# $Id$ -# Maintainer: Lukas Fleischer <archlinux at cryptocrack dot de> +# $Id: PKGBUILD 101370 2013-11-23 19:00:48Z arodseth $ +# Maintainer: Alexander Rødseth <rodseth@gmail.com> +# Contributor: Lukas Fleischer <archlinux at cryptocrack dot de> # Contributor: jlvsimoes <jlvsimoes@oninet.pt> # Contributor: kevin <kevin@archlinux.org> # Contributor (Parabola): André Silva <emulatorman@parabola.nu> @@ -7,37 +8,72 @@ _pkgname=abuse pkgname=abuse-libre pkgver=0.8 -pkgrel=2 -pkgdesc='A side-scroller action game that pits you against ruthless alien killers, without nonfree claudio support' -arch=('i686' 'x86_64') +pkgrel=4 +pkgdesc='Side-scroller action game that pits you against ruthless alien killers, without nonfree claudio support' +arch=('x86_64' 'i686' 'mips64l') url='http://abuse.zoy.org/' license=('GPL' 'custom') -depends=('gcc-libs' 'glu' 'sdl' 'sdl_mixer') -provides=('$_pkgname=$pkgver') -replaces=('$_pkgname') -conflicts=('$_pkgname') -install='abuse.install' -source=("http://abuse.zoy.org/raw-attachment/wiki/download/${_pkgname}-${pkgver}.tar.gz" - non-claudio.patch) -md5sums=('ec678b8dc8d00e0382d8c805c6438489' - '4808c8be42f551bb3c611629a7833f09') +provides=$_pkgname=$pkgver +replaces=$_pkgname +conflicts=$_pkgname +depends=('gcc-libs' 'libgl' 'sdl_mixer' 'glu' 'desktop-file-utils') +makedepends=('gendesk' 'mesa-libgl' 'glu') +install="$_pkgname.install" +mksource=("http://abuse.zoy.org/raw-attachment/wiki/download/$_pkgname-$pkgver.tar.gz" + 'non-claudio.patch') +source=("https://repo.parabolagnulinux.org/sources/$pkgname-$pkgver.tar.gz" + 'abuse.sh' + 'default.abuserc' + 'default.gamma.lsp') +mksha256sums=('0104db5fd2695c9518583783f7aaa7e5c0355e27c5a803840a05aef97f9d3488' + '017cb58acf5ba8cdb889f97a758318cb66ab4947b860a77ab16b932c3f21b98f') +sha256sums=('ff7018b3ddcc6d2e702bc14eb2884622677ac5141c36e1fc0cdd127df3017f7d' + 'a5ddac71ca9b8c4bb42bdf91393a5fbe3d839ab9a9e9a6362a75dafc2aab122e' + '6ea2fa9e65c10bbcab4432f40d0c7284cb3970835c40c5c00ced14b39ce1b00f' + '13df83fea60918d29d5141cdfbd8d56147c053e88d3701209ae676f46447c2f6') -build() { - cd "${srcdir}/${_pkgname}-${pkgver}" +mksource() { + cd "abuse-$pkgver" -# Remove the nonfree claudio addon + # Remove the nonfree claudio addon rm -rvf ./data/addon/claudio patch -Np1 -i "$srcdir/non-claudio.patch" +} + +prepare() { + cd "abuse-$pkgver" + + gendesk -n -f --_pkgname "$_pkgname" --pkgdesc "$pkgdesc" +} - ./configure --prefix=/usr --with-assetdir=/usr/share/abuse/orig --with-x +build() { + cd "abuse-$pkgver" + + ./configure --prefix=/usr --with-assetdir="/usr/share/$_pkgname/orig" --with-x make } package() { - cd "${srcdir}/${_pkgname}-${pkgver}" + cd "abuse-$pkgver" + + make DESTDIR="$pkgdir" install - make DESTDIR="${pkgdir}" install + # Desktop shortcut and icon + install -Dm644 "$_pkgname.desktop" \ + "$pkgdir/usr/share/applications/$_pkgname.desktop" + install -Dm644 "doc/$_pkgname.png" "$pkgdir/usr/share/pixmaps/$_pkgname.png" - install -d "${pkgdir}/usr/share/licenses/abuse" - sed -n '1,/^$/p' src/view.cpp > "${pkgdir}/usr/share/licenses/abuse/orig.code.license" + # Sane defaults + mv "$pkgdir/usr/bin/$_pkgname" "$pkgdir/usr/bin/$_pkgname.elf" + install -Dm755 "$srcdir/$_pkgname.sh" "$pkgdir/usr/bin/$_pkgname" + install -Dm644 "$srcdir/default.${_pkgname}rc" \ + "$pkgdir/usr/share/$_pkgname/default.${_pkgname}rc" + install -Dm644 "$srcdir/default.gamma.lsp" \ + "$pkgdir/usr/share/$_pkgname/default.gamma.lsp" + + # License (for the original source code) + install -d "$pkgdir/usr/share/licenses/abuse" + sed -n '1,/^$/p' src/view.cpp > "$pkgdir/usr/share/licenses/abuse/original" } + +# vim:set ts=2 sw=2 et: diff --git a/libre/abuse-libre/abuse.install b/libre/abuse-libre/abuse.install index 4d28ebacd..ad97d7bab 100644 --- a/libre/abuse-libre/abuse.install +++ b/libre/abuse-libre/abuse.install @@ -1,13 +1,13 @@ -# arg 1: the new package version +post_upgrade() { + update-desktop-database -q +} + post_install() { -# echo "If you get a BOSS_ANT error trying to run abuse, copy /usr/share/games/abuse/gamma.lsp to ~/.abuse" - echo "Abuse uses the original game levels by default. To use the frabs levels" - echo "use '-datadir' or set 'datadir' in the abuserc to /usr/share/abuse/frabs" + post_upgrade } -# arg 1: the new package version -# arg 2: the old package version -post_upgrade() { - post_install +post_remove() { + post_upgrade } +# vim:set ts=2 sw=2 et: diff --git a/libre/abuse-libre/abuse.sh b/libre/abuse-libre/abuse.sh new file mode 100644 index 000000000..228bb6f7b --- /dev/null +++ b/libre/abuse-libre/abuse.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +# Use sane configuration files, unless they already exists + +if [ ! -d $HOME/.abuse ]; then + mkdir -p $HOME/.abuse +fi +if [ ! -f $HOME/.abuse/abuserc ]; then + cp /usr/share/abuse/default.abuserc $HOME/.abuse/abuserc +fi +if [ ! -f $HOME/.abuse/gamma.lsp ]; then + cp /usr/share/abuse/default.gamma.lsp $HOME/.abuse/gamma.lsp +fi + +exec /usr/bin/abuse.elf diff --git a/libre/abuse-libre/default.abuserc b/libre/abuse-libre/default.abuserc new file mode 100644 index 000000000..ff116819f --- /dev/null +++ b/libre/abuse-libre/default.abuserc @@ -0,0 +1,37 @@ +; Abuse-SDL Configuration file + +; Startup fullscreen +fullscreen=0 + +; Use DoubleBuffering +doublebuf=1 + +; Use OpenGL +gl=1 + +; Location of the datafiles +datadir=/usr/share/abuse/orig + +; Use mono audio only +mono=0 + +; Grab the mouse to the window +grabmouse=0 + +; Set the scale factor +scale=2 + +; Use anti-aliasing (with gl=1 only) +antialias=0 + +; Disable the SDL parachute in the case of a crash +nosdlparachute=0 + +; Key mappings +left=a +right=d +up=w +down=s +fire=Space +weapprev=q +weapnext=e diff --git a/libre/abuse-libre/default.gamma.lsp b/libre/abuse-libre/default.gamma.lsp new file mode 100644 index 000000000..9a77afa27 --- /dev/null +++ b/libre/abuse-libre/default.gamma.lsp @@ -0,0 +1 @@ +(setq darkest_gray 20) diff --git a/libre/abuse-libre/rePKGBUILD b/libre/abuse-libre/rePKGBUILD deleted file mode 100644 index 3c9a0082d..000000000 --- a/libre/abuse-libre/rePKGBUILD +++ /dev/null @@ -1,33 +0,0 @@ -# This is an example rePKGBUILD file. Use this as a start to creating your own, -# and remove these comments. For more information, see 'man PKGBUILD'. -# NOTE: Please fill out the license field for your package! If it is unknown, -# then please put 'unknown'. - -# Maintainer: Nicolas Reynolds <fauno@kiwwwi.com.ar> -source PKGBUILD -CARCH=x86_64 -unset build package md5sums source -_repo=community -options=(!strip) -source=(PKGBUILD - http://mirrors.kernel.org/archlinux/${_repo}/os/$CARCH/${pkgname%-libre}-$pkgver-$pkgrel-$CARCH$PKGEXT - # files for pkg modifications - ) - -build() { - cd "${srcdir}/" - rm -v .{INSTALL,PKGINFO} ${pkgname%-libre}-$pkgver-$pkgrel-$CARCH.pkg.tar.xz - # actions for package modifications - # be sure to remove source files - - msg "Removing unfree 'Claudio' addon" - rm -rvf usr/share/abuse/orig/addon/claudio/ -} - -package() { - cd ${srcdir} - cp -a ./* ${pkgdir} -} - - -# vim:set ts=2 sw=2 et: |