updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / leisure-suit-larry / PKGBUILD
blob8a91adcc83cb9929f54f7f7d573ece501b68d8fc
1 # Contributor: Jens Staal <staal1978@gmail.com>
3 pkgname="leisure-suit-larry"
4 pkgver="1.0"
5 pkgrel=4
6 pkgdesc="A classic adventure game from Abandonia, played in DosBox."
7 url='http://www.abandonia.com/en/games/120/Leisure+Suit+Larry+1+-+in+the+Land+of+the+Lounge+Lizards.html'
8 arch=('any')
9 license=('custom-freeware' 'Abandonware')
10 install='larry1.install'
11 depends=('dosbox')
12 optdepends=('abandonia-menu')
13 source=('http://files.abandonia.com/download.php?game=Leisure+Suit+Larry+1+-+in+the+Land+of+the+Lounge+Lizards&secure=413c4e541e1210e8be652772446dc02f&td=1297708983' 'Larry1.gif')
14 md5sums=('73161dc388fdcbb9c4ff2155d840a0db' '8b6793a1fd133ec004a7d22e5919b51d')
15 _pkgabbrev="Larry1"
16 _exe="LL.COM"
17 _icon="Larry1.gif"
19 build() {
20         mkdir -p -m755 "$pkgdir/opt/" 
21         mkdir -p -m755 "$pkgdir/opt/abandonia" 
22         mkdir -p -m755 "$pkgdir/opt/abandonia/$_pkgabbrev" 
23         rm -f $srcdir/download* 
24         cp -ar $srcdir/Leisure\ Suit\ Larry\ 1.1987/* "$pkgdir/opt/abandonia/$_pkgabbrev"
25         cp -ar $srcdir/$_icon $pkgdir/opt/abandonia/$_pkgabbrev/
27         #ok, let's use a script to start the game
29         mkdir -p -m755 /$pkgdir/usr/bin/
31         printf "#!${SHELL}
33 mkdir -p ~/.abandonia/$_pkgabbrev
35 if whereis dosbox>/dev/null 2>&1;
36         then
37                 dosbox /opt/abandonia/$_pkgabbrev/$_exe mount c ~/.abandonia/$_pkgabbrev
38         else
39                 echo '==> Please get sure to have dosbox installed and have it in your PATH array.'
41 return \$?" >> /$pkgdir/usr/bin/$_pkgabbrev.sh
42         chmod +x /$pkgdir/usr/bin/$_pkgabbrev.sh
43         ln -s $_pkgabbrev.sh /$pkgdir/usr/bin/$_pkgabbrev
45         # Automatic generation of a .desktop file
47         mkdir -p -m644 "$pkgdir/usr/share/" 
48         mkdir -p -m644 "$pkgdir/usr/share/applications/" 
50         printf "[Desktop Entry]
51 Version=$pkgver
52 Type=Application
53 Name=$pkgname
54 Comment=$pkgdesc
55 Exec=/usr/bin/$_pkgabbrev
56 Icon=/opt/abandonia/$_pkgabbrev/$_icon
57 Categories=Game;Abandonia;
58 Terminal=false
59 StartupNotify=false" >> /$pkgdir/usr/share/applications/$_pkgabbrev.desktop
60