summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan McCurry2016-11-03 23:04:53 -0400
committerDan McCurry2016-11-03 23:04:53 -0400
commit5a7aa614a4fb721ceb1f0292834e9f05b4f002a2 (patch)
treeeadc9f8f97aa166cb4dd4809f929fab94618e81e
parentd1ec763a26b4fa901128968270e62eb4a6f73093 (diff)
downloadaur-5a7aa614a4fb721ceb1f0292834e9f05b4f002a2.tar.gz
Fixing commit issue
-rw-r--r--.SRCINFO11
-rw-r--r--PKGBUILD73
-rw-r--r--gog-beneath-a-steel-sky8
3 files changed, 67 insertions, 25 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 039e1eff85d..038c99769a7 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,17 +1,18 @@
pkgbase = gog-beneath-a-steel-sky
pkgdesc = All man's social problems are coming to a boil. Under the claustrophobic lid of a steel sky.
- pkgver = 1.0.0.2
+ pkgver = 2.1.0.4
pkgrel = 1
url = http://www.gog.com/game/beneath_a_steel_sky
arch = i686
arch = x86_64
groups = games
- license = custom
+ license = custom:EULA custom:scummvm
depends = freetype2
depends = unionfs-fuse
- source = local://gog_beneath_a_steel_sky_1.0.0.2.tar.gz
- source = gog-beneath-a-steel-sky
- sha256sums = bc309545a368e94abeb48a58d322f2ae578d23943dd027e90dd5057b32af317f
+ optdepends = gendesk
+ source = local://gog_beneath_a_steel_sky_2.1.0.4.sh
+ source = local://beneath-a-steel-sky
+ sha256sums = 1cd6c487b1f2f151874183aabb49026cb652faf33c1b326ea0edb1878eabadfb
sha256sums = 71c9b6d850c92c637cd44a502de8db01498e88af9829125f7fb9097b4575d60b
pkgname = gog-beneath-a-steel-sky
diff --git a/PKGBUILD b/PKGBUILD
index 1ccacfa9958..8f5e466155a 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,25 +1,74 @@
-# Maintainer : André Fettouhi <a.fettouhi@gmail.com>
+# Maintainer : Dan McCurry <dan.mccurry at linux dot com>
+# Contributor : André Fettouhi <a.fettouhi@gmail.com>
pkgname=gog-beneath-a-steel-sky
-pkgver=1.0.0.2
+# Trim gog- prefix from launcher
+_appname=$(echo ${pkgname} | sed -e 's/gog-//')
+pkgver=2.1.0.4
pkgrel=1
pkgdesc="All man's social problems are coming to a boil. Under the claustrophobic lid of a steel sky. "
arch=("i686" "x86_64")
url="http://www.gog.com/game/beneath_a_steel_sky"
-license=("custom")
+license=("custom:EULA custom:scummvm")
groups=("games")
-source=("local://gog_beneath_a_steel_sky_${pkgver}.tar.gz" "gog-beneath-a-steel-sky")
-sha256sums=('bc309545a368e94abeb48a58d322f2ae578d23943dd027e90dd5057b32af317f'
+source=("local://gog_beneath_a_steel_sky_${pkgver}.sh"
+ "local://${_appname}")
+sha256sums=('1cd6c487b1f2f151874183aabb49026cb652faf33c1b326ea0edb1878eabadfb'
'71c9b6d850c92c637cd44a502de8db01498e88af9829125f7fb9097b4575d60b')
depends=(freetype2 unionfs-fuse)
-#options=('!strip')
+optdepends=('gendesk')
PKGEXT=.pkg.tar
+# Exclude unneeded architecture
+case $CARCH in
+ x86_64) _xarch=i686;
+ ;;
+ i686) _xarch=x86_64;
+ ;;
+ *) warning "Unsupported architecture: ${CARCH}"
+ ;;
+esac
+
+prepare() {
+ cd ${srcdir}
+
+ # Create menu icons
+ if which gendesk &>/dev/null; then
+ gendesk -f -n --pkgname "${_appname}" \
+ --pkgdesc "${pkgdesc}" \
+ --name='Beneath a Steel Sky' \
+ --exec="/usr/bin/${_appname}" \
+ --categories "Application;Game;"
+ else
+ warning "gendesk not found!"
+ warning "Menu icons not generated."
+ fi
+
+ # extract mojo installer and suppress header warning for unzip
+ unzip "$(echo ${pkgname} | sed -e 's/-/_/g')_${pkgver}.sh" \
+ "data/noarch/*" -x "*${_xarch}*" || if [ $? -eq 1 ]; then
+ msg "Data extraction successful.";
+ fi
+}
+
package() {
- mkdir -p "${pkgdir}"/opt/gog/beneath-a-steel-sky
- cp -r "${srcdir}"/Beneath\ A\ Steel\ Sky/* "${pkgdir}"/opt/gog/beneath-a-steel-sky
- install -Dm644 "${srcdir}"/Beneath\ A\ Steel\ Sky/support/gog-beneath-a-steel-sky-primary.desktop "${pkgdir}"/usr/share/applications/gog-beneath-a-steel-sky.desktop
- install -Dm644 "${srcdir}"/Beneath\ A\ Steel\ Sky/support/gog-beneath-a-steel-sky.png "${pkgdir}"/usr/share/pixmaps/gog-beneath-a-steel-sky.png
- install -Dm644 "${srcdir}"/Beneath\ A\ Steel\ Sky/docs/End\ User\ License\ Agreement.txt "${pkgdir}"/usr/share/licenses/$pkgname/LICENSE
- install -Dm755 "${srcdir}/gog-beneath-a-steel-sky" "${pkgdir}/usr/bin/gog-beneath-a-steel-sky"
+ mkdir -p "${pkgdir}/opt/gog/${_appname}"
+ mkdir -p "${pkgdir}/usr/share/pixmaps"
+ mkdir -p "${pkgdir}/usr/share/licenses/${pkgname}"
+
+ cd ${srcdir}
+ cp -r ./data/noarch/* "${pkgdir}"/opt/gog/${_appname}
+ install -Dm644 "./${_appname}.desktop" \
+ "${pkgdir}/usr/share/applications/${_appname}.desktop"
+
+ cd ${srcdir}/data/noarch
+ ln -s "/opt/gog/${_appname}/support/icon.png" \
+ "${pkgdir}/usr/share/pixmaps/${_appname}.png"
+ ln -s "/opt/gog/${_appname}/docs/End User License Agreement.txt" \
+ "${pkgdir}/usr/share/licenses/${pkgname}/EULA"
+ ln -s "/opt/gog/${_appname}/docs/scummvm" \
+ "${pkgdir}/usr/share/licenses/${pkgname}/scummvm"
+
+ install -Dm755 "${srcdir}/${_appname}" \
+ "${pkgdir}/usr/bin/${_appname}"
}
diff --git a/gog-beneath-a-steel-sky b/gog-beneath-a-steel-sky
deleted file mode 100644
index d9c7e59753d..00000000000
--- a/gog-beneath-a-steel-sky
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/usr/bin/bash
-gogdir="/opt/gog/beneath-a-steel-sky"
-homedir="$HOME/.gog/beneath-a-steel-sky"
-mkdir -p "$homedir"/{game,config/data}
-
-unionfs "$homedir/config=RW:$gogdir=RO" "$homedir/game"
-"$homedir"/game/start.sh
-fusermount -u "$homedir/game"