updated on Wed Jan 11 12:00:27 UTC 2012
[aur-mirror.git] / btrl / PKGBUILD
blobb44722116b8f644c493b25ab07a9fd7679fabe90
1 # Contributor: Slash <demodevil5 [at] yahoo [dot] com>
3 pkgname=btrl
4 pkgver=demo
5 pkgrel=2
6 pkgdesc="Beyond the Red Line is a completely free stand-alone conversion of Freespace 2 based on the TV show Battlestar Galactica"
7 url='http://www.beyondtheredline.net/'
8 arch=('i686' 'x86_64')
9 license=('custom')
10 depends=('libgl' 'libtheora' 'libvorbis' 'mesa' 'openal' 'sdl')
11 source=('btrl.desktop' 'btrl.launcher'
12 'ftp://ftp.unreal.ie/unreal.ie/non-unreal/BtRLDemoInstaller.run'
13 'http://www.fsoinstaller.com/files/btrl/btrlpatch_linux.tar.gz'
14 'http://www.fsoinstaller.com/files/btrl/w_patch2.vp'
15 'http://www.fsoinstaller.com/files/btrl/x_patch1.vp'
16 'http://www.fsoinstaller.com/files/btrl/y_patch1.vp')
17 md5sums=('3acd39a97465576bbb28855c025b987a'
18          'b4988100342221dacdc9e011db07a57e'
19          'f11b425f3aeb9acba9a180cfc4dafcf0'
20          '048d91174c0ede75cf428406a444db56'
21          'b656b65b3832e5cbb6f87afb7280f1d5'
22          '3c6f15f5e21da5fa89a656993f919ac7'
23          '22602aa184842d80812aba04ca51cbaa')
25 build () {
26     cd $srcdir
28     # Create Destination Directory
29     install -d $pkgdir/opt/btrl
31     # Extract Data from the Installer
32     chmod +x $srcdir/BtRLDemoInstaller.run
33     ./BtRLDemoInstaller.run --noexec --tar xvf
35     # Extract Game Data into Destination Directory
36     bsdtar -x -o -C $pkgdir/opt/btrl -f $srcdir/game_data.tar
38     # Extract Game Libaries into Destination Directory
39     bsdtar -x -o -C $pkgdir/opt/btrl -f $srcdir/libs.tar
41     # Remove Bad Files
42     rm $pkgdir/opt/btrl/data/freddocs/Thumbs.db
44     # Copy README File
45     install -D -m 644 $srcdir/README \
46         $pkgdir/opt/btrl/README
48     # Install Binaries based on Archetecture
49     if [ "$CARCH" = "x86_64" ]; then
50         #
51         # x86_64 Systems (Use unpatched binaries)
52         #
53         install -D -m 755 $srcdir/bin/Linux/x86_64/glibc-2.1/btrl_demo \
54             $pkgdir/opt/btrl/btrl_demo
55         install -D -m 755 $srcdir/bin/Linux/x86_64/glibc-2.1/btrl_demo.bin \
56             $pkgdir/opt/btrl/btrl_demo.bin
57     else
58         #
59         # i686 Systems (Use patched binaries)
60         #
61         install -D -m 755 $srcdir/btrl_demo \
62             $pkgdir/opt/btrl/btrl_demo
63         install -D -m 755 $srcdir/btrl_demo.bin \
64             $pkgdir/opt/btrl/btrl_demo.bin
66         # Install Patch Data
67         install -D -m 644 $srcdir/w_patch2.vp \
68           $pkgdir/opt/btrl/w_patch2.vp
70         install -D -m 644 $srcdir/x_patch1.vp \
71           $pkgdir/opt/btrl/x_patch1.vp
73         install -D -m 644 $srcdir/y_patch1.vp \
74           $pkgdir/opt/btrl/y_patch1.vp
75     fi
77     # Install Launcher
78     install -D -m 755 $srcdir/btrl.launcher \
79         $pkgdir/usr/bin/btrl
81     # Install Desktop File
82     install -D -m 644 $srcdir/btrl.desktop \
83         $pkgdir/usr/share/applications/btrl.desktop
85     # Install Icon File
86     install -D -m 644 $srcdir/btrl.png \
87         $pkgdir/usr/share/pixmaps/btrl.png