summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorrh9952015-07-14 14:00:24 -0800
committerrh9952015-07-14 14:00:24 -0800
commit0d499acc8d098d5d6efde578e2119882b5a9fe97 (patch)
tree032c961deb59696c240d34b50fccb0fded347b93 /PKGBUILD
downloadaur-0d499acc8d098d5d6efde578e2119882b5a9fe97.tar.gz
Create slashem package.
The PKGBUILD for this package was created referencing the PKGBUILDS from both the previous version of the package, as well as the PKGBUILD from nethack, but in the end I wrote the whole thing from scratch. namcap generates some errors and warnings, but these are the same as for the nethack package, so I think they should stay.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD40
1 files changed, 40 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..21133f455054
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,40 @@
+# Maintainer: Raymond E. Hogenson <rayhogenson@gmail.com>
+
+pkgname=slashem
+pkgver=0.0.7E7F3
+pkgrel=3
+pkgdesc='Nethack variant Super Lotsa Added Stuff Hack - Extended Magic'
+arch=('i686' 'x86_64')
+url="http://www.slashem.org/"
+license=('custom')
+depends=('bash')
+source=("http://prdownloads.sourceforge.net/$pkgname/se007e7f3.tar.gz"
+ "$pkgname-$pkgver.patch")
+md5sums=('54b4534fe85f08722e8b6b38d52c2e9a'
+ '81e685f77734d1a39a85d4d5d77add7c')
+
+prepare() {
+ cd "$pkgname-$pkgver"
+ sh sys/unix/setup.sh
+ patch -p0 -i "$srcdir/$pkgname-$pkgver.patch"
+ sed -e "/^# define COMPRESS /s|/usr/bin/compress|$(which gzip)|" \
+ -i include/config.h
+}
+
+build() {
+ cd "$pkgname-$pkgver"
+ make all
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+ make PREFIX="$pkgdir" install manpages
+ sed -e "s|HACKDIR=$pkgdir/|HACKDIR=|" \
+ -e 's|HACK=$HACKDIR|HACK=/usr/lib/slashem|' \
+ -i $pkgdir/usr/bin/slashem
+ install -Dm644 dat/license "$pkgdir/usr/share/licenses/$pkgname/license"
+ install -dm755 "$pkgdir/usr/lib/$pkgname"
+ mv "$pkgdir"/var/games/slashem/{slashem,recover} \
+ "$pkgdir/usr/lib/$pkgname"
+}
+