updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / dwarffortress-ironhand / PKGBUILD
blob92346fa8310fde6a018fcb55747c5a0acbd09722
1 # Maintainer: Klaas Boesche <aurkagebe _at_ googlemail.com>
2 # Modified from aur package dwarffortress-mayday by
3 # Contributor: Patrick Chilton <chpatrick _at_ gmail _dot_ com>
4 # Original from community by
5 # Contributor: Sven-Hendrik Haase <sh@lutzhaase.com>
6 # Contributor: Daenyth <Daenyth+Arch [AT] gmail [DOT] com>
7 # Contributor: djnm <nmihalich [at} gmail dott com>
8 pkgname=dwarffortress-ironhand
9 pkgver=0.60
10 _pkgver=31_25
11 pkgrel=3
12 pkgdesc="A single-player fantasy game. You control a dwarven outpost or an adventurer in a randomly generated persistent world. Packed with Ironhand's tileset and graphics pack.  Does not replace other dwarffortress packages."
13 arch=(i686 x86_64)
14 url="http://www.bay12forums.com/smf/index.php?topic=53180.0"
15 install="dwarffortress-ih.install"
16 license=('custom:dwarffortress-ih')
17 depends=(gtk2 mesa sdl_image libsndfile openal sdl_ttf)
18 makedepends=(unrar)
19 if [[ $CARCH == 'x86_64' ]]; then
20   depends=(lib32-gtk2 lib32-mesa lib32-sdl_image lib32-libsndfile lib32-openal
21   lib32-libxdamage lib32-ncurses lib32-sdl_ttf)
22   optdepends=('lib32-nvidia-utils: If you have nvidia graphics'
23               'lib32-catalyst-utils: If you have ATI graphics')
25 source=(http://www.bay12games.com/dwarves/df_${_pkgver}_linux.tar.bz2
26         ironhand-${pkgver}.zip::"http://dffd.wimbli.com/download.php?id=2617&f=Ironhand+${pkgver}u.zip"
27         dwarffortress-ih dwarffortress-ih.desktop dwarffortress-ih.png)
28 backup=(opt/df_linux-ih/data/init/init.txt)
29 md5sums=('def0c37560d7165c9065c4a4d8defc7e'
30          '61671ed4cb50c70a3547f99154a8f4be'
31          '8501394572bc800d1217da5119013411'
32          'ebf89a2d8d9457b58b4c16babab529d7'
33          'b1d51f82400073af9bb179e34a9209d0')
35 build() {
36   cd $srcdir/df_linux
37   install -dm755 $pkgdir/opt/
38   cp -r $srcdir/df_linux/ $pkgdir/opt/
39   # copy ironhand files over the regular ones
40   cp -rf $srcdir/update/* $pkgdir/opt/df_linux/
42   # Yay for precompiled stuff with junk permissions! :D
43   find $pkgdir/opt/df_linux -type d -exec chmod 755 {} +
44   find $pkgdir/opt/df_linux -type f -exec chmod 644 {} +
46   install -Dm755 $srcdir/dwarffortress-ih $pkgdir/usr/bin/dwarffortress-ih
48   chmod 755 $pkgdir/opt/df_linux/libs/Dwarf_Fortress
50   install -d -m775 -o root -g games $pkgdir/opt/df_linux/data/save
52   # This probably is overkill, but I don't know what specific files df needs permission for in here.
53   chown -R root:games $pkgdir/opt/df_linux/data
54   find $pkgdir/opt/df_linux/data -type d -exec chmod 775 {} +
55   find $pkgdir/opt/df_linux/data -type f -exec chmod 664 {} +
57   # Desktop launcher with icon
58   install -Dm644 $srcdir/dwarffortress-ih.desktop $pkgdir/usr/share/applications/dwarffortress-ih.desktop
59   install -Dm644 $srcdir/dwarffortress-ih.png     $pkgdir/usr/share/pixmaps/dwarffortress-ih.png
61   install -Dm644 $srcdir/df_linux/readme.txt $pkgdir/usr/share/licenses/dwarffortress-ih/readme.txt
63   # move the whole thing so we're in a different install than the normal dwarf fortress
64   mv $pkgdir/opt/df_linux $pkgdir/opt/df_linux-ih
69 # vim:set ts=2 sw=2 et: