summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Beste2017-01-27 20:26:18 -0600
committerDan Beste2017-01-27 20:28:07 -0600
commitfe54a438d7ef7ffebb67345f0772f27485591ce7 (patch)
tree6b06740d8bb9461f0e0aa0696fcc81b2bc8980b7
parentd8f5ec5208f415f5713b88713e060dffebc690d4 (diff)
downloadaur-fe54a438d7ef7ffebb67345f0772f27485591ce7.tar.gz
Init
-rw-r--r--.SRCINFO11
-rw-r--r--PKGBUILD61
-rw-r--r--gog-stardew-valley13
-rw-r--r--gog-stardew-valley.desktop10
4 files changed, 55 insertions, 40 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 93040894598..aa884396129 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,17 +1,18 @@
-# Generated by mksrcinfo v8
-# Sat Nov 5 03:18:29 UTC 2016
pkgbase = gog-stardew-valley
- pkgdesc = An open-ended country-life RPG
+ pkgdesc = You’ve inherited your grandfather’s old farm plot in Stardew Valley. Armed with hand-me-down tools and a few coins, you set out to begin your new life.
pkgver = 2.3.0.4
pkgrel = 1
- url = http://stardewvalley.net
+ url = http://stardewvalley.net/
arch = i686
arch = x86_64
license = custom
+ optdepends = firejail: Automatically sandbox this application from your OS
source = gog://gog_stardew_valley_2.3.0.4.sh
source = gog-stardew-valley.desktop
+ source = gog-stardew-valley
sha256sums = 88e1fae7226c7bfa91cb28c137c24867e12b1a0b6e824e6ffe73e1eefc166aac
- sha256sums = eb5f427f4698ac99a0b2c05f08530ef2cc0d7f90090ae93b3efa29f27b8f431b
+ sha256sums = 1dc48ca70b7274c065ee65e285102b07962096b650a34a898d10d6749039d3ca
+ sha256sums = fe0d3cedb10ed9cd4ea5c9c44ce8fc5c7c3f152a51d7e4aef85b7fcbfceac10e
pkgname = gog-stardew-valley
diff --git a/PKGBUILD b/PKGBUILD
index ee70501c104..edbff3c66e6 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,55 +1,56 @@
-# Maintainer: Ainola
+# Maintainer: Krakn - Dan.Ray.Beste@gmail.com
+# Thanks to: Ainola for the base PKGBUILD (gog-undertale)
pkgname=gog-stardew-valley
pkgver=2.3.0.4
pkgrel=1
-pkgdesc="An open-ended country-life RPG"
-url="http://stardewvalley.net"
+pkgdesc="You’ve inherited your grandfather’s old farm plot in Stardew Valley. Armed with hand-me-down tools and a few coins, you set out to begin your new life."
+url="http://stardewvalley.net/"
license=('custom')
arch=('i686' 'x86_64')
-source=("gog://${pkgname//-/_}_${pkgver}.sh"
- "${pkgname}.desktop")
-sha256sums=('88e1fae7226c7bfa91cb28c137c24867e12b1a0b6e824e6ffe73e1eefc166aac'
- 'eb5f427f4698ac99a0b2c05f08530ef2cc0d7f90090ae93b3efa29f27b8f431b')
+depends_x86_64=("sdl2" "openal")
+depends_i686=("lib32-openal" "lib32-sdl2")
+# If Firejail is installed, this application will be sandboxed automatically.
+optdepends=('firejail: Automatically sandbox this application from your OS')
+source=(
+ "gog://${pkgname//-/_}_${pkgver}.sh"
+ "${pkgname}.desktop"
+ "$pkgname"
+)
+sha256sums=(
+ "88e1fae7226c7bfa91cb28c137c24867e12b1a0b6e824e6ffe73e1eefc166aac"
+ "1dc48ca70b7274c065ee65e285102b07962096b650a34a898d10d6749039d3ca"
+ "c17ec2da9bc6df0c15611877033553275bc775ea318c0be4f745efcdfb9b22d1"
+)
# You need to download the gog.com installer file manually or with lgogdownloader.
-DLAGENTS+=("gog::/usr/bin/echo %u - This is is not a real URL, you need to download the GOG file manually to \"$PWD\" or setup a gog:// DLAGENT. Read this PKGBUILD for more information.")
+DLAGENTS+=("gog::/usr/bin/echo %u Download the GOG file to \"$PWD\" or set up a gog:// DLAGENT.")
# Prevent compressing final package
-PKGEXT='.pkg.tar'
-
-prepare(){
- # Unzip will produce an error code because it is unable to unzip the Installer.
- # Therefore, a conditional into a no-op command will keep the PKGBUILD from failing
- # Of course, if you have any real problems unzipping the PKGBUILD will not abort.
- unzip -d "${srcdir}/stardew-valley" "${pkgname//-/_}_${pkgver}.sh" || :
- cd "${srcdir}/stardew-valley/data/noarch"
-
- sed -r -i \
- 's/(CURRENT_DIR="\$\( cd "\$\( dirname )'`
- `'"\$\{BASH_SOURCE\[0\]\}"(.*$)'`
- `'/\1$( readlink -nf "${BASH_SOURCE[0]}" )\2/' \
- "start.sh"
-}
+PKGEXT=".pkg.tar"
package(){
- cd "${srcdir}/stardew-valley/data/noarch"
+ cd "${srcdir}"
+
# Install game
install -d "${pkgdir}/opt/${pkgname}/"
install -d "${pkgdir}/opt/${pkgname}/support"
install -d "${pkgdir}/usr/bin/"
- cp -r "game/" "${pkgdir}/opt/${pkgname}/"
- install -Dm755 "start.sh" \
+ cp -r "data/noarch/game/" "${pkgdir}/opt/${pkgname}/"
+
+
+ find "${pkgdir}/opt/${pkgname}" -type d -exec chmod 755 {} \;
+ install -Dm755 "data/noarch/start.sh" \
"${pkgdir}/opt/${pkgname}/"
- install -Dm755 support/*.{sh,shlib} -t \
+ install -Dm755 data/noarch/support/*.{sh,shlib} -t \
"${pkgdir}/opt/${pkgname}/support"
# Desktop integration
- install -Dm 644 "support/icon.png" \
+ install -Dm 644 "data/noarch/support/icon.png" \
"${pkgdir}/usr/share/pixmaps/${pkgname}.png"
- install -Dm644 "docs/End User License Agreement.txt" \
+ install -Dm644 "data/noarch/docs/End User License Agreement.txt" \
"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
install -Dm 644 "${srcdir}/${pkgname}.desktop" \
"${pkgdir}/usr/share/applications/${pkgname}.desktop"
- ln -s "/opt/${pkgname}/start.sh" "${pkgdir}/usr/bin/${pkgname}"
+ install -Dm755 "$srcdir/$pkgname" "$pkgdir/usr/bin/$pkgname"
}
diff --git a/gog-stardew-valley b/gog-stardew-valley
new file mode 100644
index 00000000000..6efc13cb345
--- /dev/null
+++ b/gog-stardew-valley
@@ -0,0 +1,13 @@
+#! /bin/sh
+
+run="/opt/gog-stardew-valley/start.sh"
+# The launcher fails unless in its dir.
+cd "/opt/gog-stardew-valley/" || exit 1
+
+if which firejail >/dev/null 2>&1 && [ -z "$FIREJAIL_IGNORE" ]; then
+ echo "Firejail detected. Enforcing a sandbox"
+ echo "To bypass Firejail enforcement, run FIREJAIL_IGNORE=1 $run."
+ firejail --caps.drop=all "$run"
+else
+ "${run}"
+fi
diff --git a/gog-stardew-valley.desktop b/gog-stardew-valley.desktop
index 310b83ed289..0e1b17ac894 100644
--- a/gog-stardew-valley.desktop
+++ b/gog-stardew-valley.desktop
@@ -1,10 +1,10 @@
[Desktop Entry]
-Encoding=UTF-8
Name=Stardew Valley
-Comment=An open-ended country-life RPG
+Comment=You’ve inherited your grandfather’s old farm plot in Stardew Valley. Armed with hand-me-down tools and a few coins, you set out to begin your new life.
Exec=gog-stardew-valley
Icon=gog-stardew-valley
-StartupNotify=true
-Terminal=false
Type=Application
-Categories=Application;Game;AudioVideo;
+Terminal=false
+StartupNotify=true
+Categories=Game;AudioVideo;
+Encoding=UTF-8