1 # Contributor: Stefan Clarke <fm0nk3y@yahoo.co.uk>
2 # Maintainer: Anton Bazhenov <anton.bazhenov at gmail>
3 # Maintainer: denton <e9203.00 gmail>
7 pkgdesc="An isometric graphical interface for the Slash'EM game"
9 url=http://clivecrous.github.com/vultures
10 license=(custom:NetHack General Public Licence)
11 depends=(hicolor-icon-theme libpng sdl_mixer sdl_ttf)
12 makedepends=(bison flex p7zip)
14 install=$pkgname.install
15 source=(http://cloud.github.com/downloads/clivecrous/vultures/vultures-$pkgver-full.7z)
16 md5sums=(6180d77089c273b026eb1e0ce356ef38)
20 7z x -y vultures-$pkgver-full.7z
22 cd vultures-$pkgver/slashem
24 sed -e 's|^/\* \(#define LINUX\) \*/|\1|' \
25 -e 's|^/\* \(#define TIMED_DELAY\) \*/|\1|' \
26 -e 's|^/\* \(#define VAR_PLAYGROUND.*\) \*/|\1|' \
27 -e "/^#define VAR_PLAYGROUND/ s|/var/lib/games/nethack|/var/games/$pkgname|" -i include/unixconf.h
29 sed -e '/^GAMEDIR/ s|$(PREFIX)/local/slashemdir|$(PREFIX)/share/$(GAME)|' \
30 -e '/^VARDIR/ s|$(GAMEDIR)|$(PREFIX)/../var/games/$(GAME)|' \
31 -e '/^SHELLDIR/ s|$(PREFIX)/local/bin|$(PREFIX)/bin|' \
32 -e '/^GAMEUID/ s|games|root|' \
33 -e '/^GAMEGRP/ s|bin|root|' \
34 -e '/^GAMEPERM/ s|04755|0755|' \
35 -e '/^VARDIRPERM/ s|0755|0775|' \
36 -e '/^VARFILEPERM/ s|0644|0664|' -i sys/unix/Makefile.top
38 sed -e "/^# define HACKDIR/ s|\.|/usr/share/$pkgname|" \
39 -e '/^# define COMPRESS/ s|/usr/bin/compress|/bin/gzip|' \
40 -e '/^# define COMPRESS_EXTENSION/ s|.Z|.gz|' -i include/config.h
42 sed -e "/^HACK/ s|\$HACKDIR/nethack|/usr/bin/$pkgname|" \
43 -e "/^HACKDIR/ s|/usr/games/lib/nethackdir|/usr/share/$pkgname|" -i sys/unix/nethack.sh
47 make PREFIX=$pkgdir/usr install
49 chgrp -R games $pkgdir/var/games
50 chmod 775 $pkgdir/var/games
53 mv bin/$pkgname{,-start}
54 mv share/$pkgname/$pkgname bin/$pkgname
55 mv share/$pkgname/recover bin/$pkgname-recover
57 install -Dm644 share/$pkgname/license share/licenses/$pkgname/LICENSE
58 install -Dm644 $srcdir/vultures-$pkgver/vultures/gamedata/se_icon.png share/icons/hicolor/48x48/apps/$pkgname.png
59 install -Dm644 $srcdir/vultures-$pkgver/dist/linux/$pkgname.desktop share/applications/$pkgname.desktop
61 rm share/$pkgname/{*.{ico,png,nh},license}