summaryrefslogtreecommitdiff
path: root/community/abuse
diff options
context:
space:
mode:
authorParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
committerParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
commit415856bdd4f48ab4f2732996f0bae58595092bbe (patch)
treeede2018b591f6dfb477fe9341ba17b9bc000fab9 /community/abuse
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'community/abuse')
-rw-r--r--community/abuse/PKGBUILD55
-rw-r--r--community/abuse/abuse.install13
-rw-r--r--community/abuse/abuse.patch36
3 files changed, 104 insertions, 0 deletions
diff --git a/community/abuse/PKGBUILD b/community/abuse/PKGBUILD
new file mode 100644
index 000000000..22fb9d7ff
--- /dev/null
+++ b/community/abuse/PKGBUILD
@@ -0,0 +1,55 @@
+# $Id: PKGBUILD 8618 2008-08-14 04:01:43Z kevin $
+# Committer: jlvsimoes <jlvsimoes@oninet.pt>
+# Maintainer: kevin <kevin@archlinux.org>
+
+pkgname=abuse
+pkgver=0.7.1
+pkgrel=1
+pkgdesc="A side-scroller action game that pits you against ruthless alien killers"
+url="http://abuse.zoy.org/"
+depends=('gcc-libs' 'libgl' 'sdl')
+# abuse-data below is the original commercial levels and sound effects.
+# abuse-frabs contains community created levels.
+# abuse-lib is the original demo levels.
+# abuse-sfx is the original sound effects, included in abuse-data.
+source=(http://abuse.zoy.org/raw-attachment/wiki/Downloads/${pkgname}-${pkgver}.tar.gz
+http://abuse.zoy.org/raw-attachment/wiki/Downloads/${pkgname}-data-2.00.tar.gz
+http://abuse.zoy.org/raw-attachment/wiki/Downloads/${pkgname}-frabs-2.11.tar.gz
+abuse.patch)
+noextract=(abuse-data-2.00.tar.gz)
+license=('GPL' 'custom')
+arch=('i686' 'x86_64')
+install=abuse.install
+md5sums=('439b607f291560a8f9698a2f09cffa63'
+ '2b857668849b2dc7cd29cdd84a33c19e'
+ '0686f951289fe514846903bab36a2079'
+ '86b5256f066e994db9d57dbe1ec2a58e')
+
+build() {
+ cd ${srcdir}/abuse-${pkgver}
+ patch -p1 -i ${srcdir}/abuse.patch
+ ./configure --prefix=/usr --datadir=/usr/share/abuse/orig --with-x
+ make || return 1
+ make DESTDIR=${pkgdir} install
+
+ mkdir -p ${pkgdir}/usr/share/abuse/{frabs,orig}
+ mkdir -p ${pkgdir}/usr/share/licenses/abuse
+
+ # original code license. sdlport is gpl.
+ sed -n '1,/^$/ p' src/view.cpp > \
+ ${pkgdir}/usr/share/licenses/abuse/orig.code.license
+
+ # original game data.
+ cd ${pkgdir}/usr/share/abuse/orig
+ tar -xzf ${srcdir}/abuse-data-2.00.tar.gz
+ mv README.datafiles ${pkgdir}/usr/share/licenses/abuse/orig.data.license
+
+ # frabs data, link to sound in orignal game data.
+ cd ${pkgdir}/usr/share/abuse/frabs
+ mv ${srcdir}/abuse-frabs-2.11/* .
+ rm -f abuse.exe setup.exe art/dos4gw.exe art/spaint.exe
+ ln -s ../orig/sfx sfx
+ cp docs/index.html ${pkgdir}/usr/share/licenses/abuse/frabs.license
+
+ chown -R root:root ${pkgdir}/usr/share
+}
diff --git a/community/abuse/abuse.install b/community/abuse/abuse.install
new file mode 100644
index 000000000..4d28ebacd
--- /dev/null
+++ b/community/abuse/abuse.install
@@ -0,0 +1,13 @@
+# arg 1: the new package version
+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"
+}
+
+# arg 1: the new package version
+# arg 2: the old package version
+post_upgrade() {
+ post_install
+}
+
diff --git a/community/abuse/abuse.patch b/community/abuse/abuse.patch
new file mode 100644
index 000000000..e06896cef
--- /dev/null
+++ b/community/abuse/abuse.patch
@@ -0,0 +1,36 @@
+diff -Naur abuse-0.7.1.orig/Makefile.in abuse-0.7.1/Makefile.in
+--- abuse-0.7.1.orig/Makefile.in 2008-03-02 15:25:05.000000000 -0500
++++ abuse-0.7.1/Makefile.in 2008-08-11 23:34:21.000000000 -0400
+@@ -201,7 +201,7 @@
+ top_srcdir = @top_srcdir@
+ SUBDIRS = src
+ man_MANS = abuse.6
+-datafiledir = $(datadir)/games/abuse
++datafiledir = $(datadir)
+ datafile_DATA = abuse.bmp abuse.lsp abuse.png
+ EXTRA_DIST = bootstrap abuse.6 abuse.bmp abuse.lsp abuse.png
+ all: config.h
+diff -Naur abuse-0.7.1.orig/configure abuse-0.7.1/configure
+--- abuse-0.7.1.orig/configure 2008-03-02 15:25:03.000000000 -0500
++++ abuse-0.7.1/configure 2008-08-11 23:33:49.000000000 -0400
+@@ -21887,7 +21887,7 @@
+
+ X_LIBS=-L$x_libraries
+
+-EXPDATADIR="-DEXPDATADIR=\\\"$datadir/games/abuse\\\""
++EXPDATADIR="-DEXPDATADIR=\\\"$datadir\\\""
+
+
+ { echo "$as_me:$LINENO: checking for XShmAttach in -lXext" >&5
+diff -Naur abuse-0.7.1.orig/src/sdlport/setup.cpp abuse-0.7.1/src/sdlport/setup.cpp
+--- abuse-0.7.1.orig/src/sdlport/setup.cpp 2008-03-02 14:42:24.000000000 -0500
++++ abuse-0.7.1/src/sdlport/setup.cpp 2008-08-11 23:33:49.000000000 -0400
+@@ -89,7 +89,7 @@
+ if( (fd = fopen( rcfile, "w" )) != NULL )
+ {
+ fputs( "; Abuse-SDL Configuration file\n\n", fd );
+- fputs( "; Location of the datafiles\ndatadir=/var/games/abuse\n\n", fd );
++ fputs( "; Location of the datafiles\ndatadir=/usr/share/abuse/orig\n\n", fd );
+ fputs( "; Startup fullscreen\nfullscreen=0\n\n", fd );
+ fputs( "; Use DoubleBuffering\ndoublebuf=0\n\n", fd );
+ fputs( "; Use mono audio only\nmono=0\n\n", fd );