diff options
author | Ted Alff | 2019-01-31 22:58:10 -0500 |
---|---|---|
committer | Ted Alff | 2019-01-31 22:58:10 -0500 |
commit | 0067d92e6b63f61bc7d454df8090bd845e315be0 (patch) | |
tree | 82044e56e46fe8e53220ebafee8a2ebb9db5e406 /PKGBUILD | |
download | aur-0067d92e6b63f61bc7d454df8090bd845e315be0.tar.gz |
Initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..ec349094fc4f --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,58 @@ +# Maintainer: twa022 <twa022 at gmail dot com> + +pkgname="midnight-rescue" +pkgver=1.0 +pkgrel=1 +pkgdesc="A classic educational game from Abandonia, played in DosBox." +url='https://www.myabandonware.com/game/super-solvers-midnight-rescue-1r5' +arch=('any') +license=('custom-freeware' 'Abandonware') +depends=('dosbox' 'unionfs-fuse') +optdepends=('abandonia-menu') +source=('Midnight_Rescue.zip::https://dl.myabandonware.com/t/jAmB1g825w03TW72687692W782YyoaZQu2NdYhm2XiDsI3lRwM/Super-Solvers-Midnight-Rescue_DOS_EN.zip') +sha256sums=('51a095a8093f549a653a67fc810d9cb385b0f81b8d1c2e0c8cf7fca0adc363c6') +_icon="midnight_rescue.png" + +package() { + + install -d -m755 "$pkgdir/opt/abandonia/$pkgname" + cp -ar "$srcdir"/SSR/* "$pkgdir/opt/abandonia/$pkgname" + + #ok, let's use a script to start the game + + install -d -m755 $pkgdir/usr/bin/ + cat <<- __EOF__ > "$pkgdir/usr/bin/$pkgname" + #!/bin/sh + if whereis unionfs-fuse>/dev/null 2>&1; then + if whereis dosbox>/dev/null 2>&1; then + mkdir -p ~/.abandonia/$pkgname/temp + mkdir -p ~/.abandonia/$pkgname/persistent + unionfs -o cow -o umask=000 ~/.abandonia/$pkgname/persistent=RW:/opt/abandonia/$pkgname=RO ~/.abandonia/$pkgname/temp + dosbox ~/.abandonia/$pkgname/temp/SSR.EXE + fusermount -u ~/.abandonia/$pkgname/temp + else + echo '==> Please be sure to have dosbox installed and in your PATH.' + fi + else + echo '==> Please be sure to have unionfs-fuse installed and in your PATH.' + fi + __EOF__ + chmod +x "$pkgdir/usr/bin/$pkgname" + + # Automatic generation of a .desktop file + + install -d -m755 "$pkgdir/usr/share/applications/" + + cat <<- __EOF__ > "$pkgdir/usr/share/applications/$pkgname.desktop" + [Desktop Entry] + Version=Midnight Rescue + Type=Application + Name=$pkgname + Comment=$pkgdesc + Exec=/usr/bin/$pkgname + # Icon=/opt/abandonia/$pkgname/$_icon + Categories=Game;Abandonia; + Terminal=false + StartupNotify=false + __EOF__ +} |