2 # Contributor: Nicolas Barbey <nicolas.a.barbey@gmail.com>
7 pkgdesc="A classic sci-fi strategy game from Abandonia, played in DosBox."
8 url='http://www.abandonia.com/en/games/150/Reunion.html'
10 license=('custom-freeware' 'Abandonware')
11 install='reunion.install'
12 depends=('dosbox' 'unionfs-fuse')
13 optdepends=('abandonia-menu')
14 source=('http://files.abandonia.com/download.php?game=Reunion&secure=07cdba8f0450ca77c4c85be721ac5d80&td=1298304936')
15 md5sums=('f1f3c2734d3eff59b6d47dd64f70d66c')
18 _icon="/ICON/ICONMAIN.PIC"
21 mkdir -p -m755 "$pkgdir/opt/"
22 mkdir -p -m755 "$pkgdir/opt/abandonia"
23 mkdir -p -m755 "$pkgdir/opt/abandonia/$_pkgabbrev"
24 rm -f $srcdir/download*
25 cp -ar $srcdir/* "$pkgdir/opt/abandonia/$_pkgabbrev"
27 #ok, let's use a script to start the game
29 mkdir -p -m755 /$pkgdir/usr/bin/
32 if whereis unionfs-fuse>/dev/null 2>&1;
34 if whereis dosbox>/dev/null 2>&1;
36 mkdir -p ~/.abandonia/$_pkgabbrev/persistent
37 mkdir ~/.abandonia/$_pkgabbrev/temp
38 unionfs -o cow -o umask=000 ~/.abandonia/$_pkgabbrev/persistent=RW:/opt/abandonia/$_pkgabbrev=RO ~/.abandonia/$_pkgabbrev/temp
39 dosbox ~/.abandonia/$_pkgabbrev/temp/$_exe
40 fusermount -u ~/.abandonia/$_pkgabbrev/temp
42 echo '==> Please get sure to have dosbox installed and have it in your PATH array.'
45 echo '==> Please get sure to have unionfs-fuse installed and have it in your PATH array.'
47 return \$?" >> /$pkgdir/usr/bin/$_pkgabbrev.sh
49 chmod +x /$pkgdir/usr/bin/$_pkgabbrev.sh
50 ln -s $_pkgabbrev.sh /$pkgdir/usr/bin/$_pkgabbrev
52 # Automatic generation of a .desktop file
54 mkdir -p -m644 "$pkgdir/usr/share/"
55 mkdir -p -m644 "$pkgdir/usr/share/applications/"
57 printf "[Desktop Entry]
62 Exec=/usr/bin/$_pkgabbrev
63 Icon=/opt/abandonia/$_pkgabbrev/$_icon
64 Categories=Game;Abandonia;
66 StartupNotify=false" >> /$pkgdir/usr/share/applications/$_pkgabbrev.desktop