summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD51
-rw-r--r--knyttstories26
-rw-r--r--knyttstories.desktop12
-rw-r--r--knyttstories.install17
-rw-r--r--knyttstories.pngbin0 -> 3871 bytes
-rw-r--r--msvcp60.zipbin0 -> 114818 bytes
7 files changed, 129 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..051dc9a3c431
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = knyttstories
+ pkgdesc = In Knytt Stories, each level is its own little adventure. One level is included with the game, where you have to stop a machine that draws the life out of the planet. An official expansion pack is also featured at the website with four original levels.
+ pkgver = 1.2.1
+ pkgrel = 5
+ url = http://nifflas.ni2.se/
+ install = knyttstories.install
+ arch = i686
+ arch = x86_64
+ license = freeware
+ makedepends = unzip
+ source = knyttstories
+ source = msvcp60.zip
+ source = http://nifflas.ni2.se/content/Knytt%20Stories/Knytt%20Stories%20121.zip
+ source = knyttstories.desktop
+ source = knyttstories.png
+ md5sums = b34bc8c1f391c9a5efb9e984606a6c16
+ md5sums = e27d1c3b981aff789500e0ba2cd05616
+ md5sums = 05458d098a8c65edff607f2bbb9c93e1
+ md5sums = f41b9e383744e08ac5de5fe7330a3735
+ md5sums = d997338aae63d77ce4bedcd218dcb5d2
+
+pkgname = knyttstories
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..5e72176b20c8
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,51 @@
+# Maintainer: Daniel Escoz <darkhogg+aur@gmail.com>
+# Contributor: Sven-Hendrik Haase <sh@lutzhaase.com>
+pkgname=knyttstories
+pkgver=1.2.1
+pkgrel=5
+pkgdesc="In Knytt Stories, each level is its own little adventure. One level is included with the game, where you have to stop a machine that draws the life out of the planet. An official expansion pack is also featured at the website with four original levels."
+url="http://nifflas.ni2.se/"
+arch=('i686' 'x86_64')
+depends=()
+[ "$CARCH" = i686 ] && depends=('wine')
+[ "$CARCH" = x86_64 ] && depends=('bin32-wine')
+makedepends=('unzip')
+source=(knyttstories
+ msvcp60.zip
+ "http://nifflas.ni2.se/content/Knytt%20Stories/Knytt%20Stories%20121.zip"
+ knyttstories.desktop \
+ knyttstories.png)
+license=('freeware')
+install=knyttstories.install
+md5sums=('b34bc8c1f391c9a5efb9e984606a6c16'
+ 'e27d1c3b981aff789500e0ba2cd05616'
+ '05458d098a8c65edff607f2bbb9c93e1'
+ 'f41b9e383744e08ac5de5fe7330a3735'
+ 'd997338aae63d77ce4bedcd218dcb5d2')
+
+package() {
+ # Initial directories for game files
+ install -d -m755 $pkgdir/usr/share/knyttstories
+ mv $srcdir/"Knytt Stories"/* $pkgdir/usr/share/knyttstories/
+ install -d -m775 -o root -g games $pkgdir/var/games/knyttstories
+ mv $pkgdir/usr/share/knyttstories/Worlds $pkgdir/var/games/knyttstories/
+
+ # We need this DLL for the override else knyttstories won't work
+ mv $srcdir/msvcp60.dll $pkgdir/usr/share/knyttstories/msvcp60.dll
+
+ # Now lets manually change all the permissions since its a Windows game
+ find $pkgdir/usr/share/knyttstories -type d -exec chmod 755 "{}" \;
+ find $pkgdir/usr/share/knyttstories -type f -exec chmod 644 "{}" \;
+ find $pkgdir/var/games/knyttstories -type d -exec chmod 775 "{}" \;
+ find $pkgdir/var/games/knyttstories -type f -exec chmod 644 "{}" \;
+ find $pkgdir/var/games/knyttstories -type d -exec chown root:games "{}" \;
+ find $pkgdir/var/games/knyttstories -type f -exec chown root:games "{}" \;
+
+ # Install scripts for the user to run
+ install -d -m755 $pkgdir/usr/bin
+ install -m755 knyttstories $pkgdir/usr/bin
+
+ # Install icon
+ install -Dm644 ${srcdir}/knyttstories.desktop ${pkgdir}/usr/share/applications/knyttstories.desktop
+ install -Dm644 ${srcdir}/knyttstories.png ${pkgdir}/usr/share/pixmaps/knyttstories.png
+}
diff --git a/knyttstories b/knyttstories
new file mode 100644
index 000000000000..0ce11851aa06
--- /dev/null
+++ b/knyttstories
@@ -0,0 +1,26 @@
+#!/bin/bash
+export WINEPREFIX="$HOME/.knyttstories/wine"
+
+# Before running the game for the first time, some stuff needs to be done.
+
+# Set some symlinks and prepare the game environment.
+if [ ! -d "$HOME"/.knyttstories ] ; then
+ mkdir -p "$HOME"/.knyttstories/{wine,Saves} || exit 1
+ ln -s /usr/share/knyttstories/"Knytt Stories".exe "$HOME"/.knyttstories/knyttstories || exit 1
+ ln -s /var/games/knyttstories/Worlds "$HOME"/.knyttstories/Worlds || exit 1
+ cp -r /usr/share/knyttstories/Data "$HOME"/.knyttstories/ || exit 1
+fi
+
+# We need the system32 directory to exist prior to attempting to copy the requireddll file.
+if [ ! -d "$HOME"/.knyttstories/wine/drive_c/windows/system32 ]; then
+ mkdir -p "$HOME"/.knyttstories/wine/drive_c/windows/system32 || exit 1
+fi
+
+# Copy the msvcp60.dll file to the system32 directory or the game won't run
+if [ ! -f "$HOME"/.knyttstories/wine/drive_c/windows/system32/msvcp60.dll ]; then
+ ln -s /usr/share/knyttstories/msvcp60.dll "$HOME"/.knyttstories/wine/drive_c/windows/system32/msvcp60.dll || exit 1
+fi
+
+# Run the game
+wine "$HOME"/.knyttstories/knyttstories "$@"
+
diff --git a/knyttstories.desktop b/knyttstories.desktop
new file mode 100644
index 000000000000..c0bb08451d6e
--- /dev/null
+++ b/knyttstories.desktop
@@ -0,0 +1,12 @@
+[Desktop Entry]
+Type=Application
+Version=1.2.1
+Encoding=UTF-8
+Name=Knytt Stories
+Comment=Jump 'n' run and adventure game
+Icon=/usr/share/pixmaps/knyttstories.png
+Exec=/usr/bin/knyttstories
+Terminal=false
+StartupNotify=false
+Categories=Game;
+
diff --git a/knyttstories.install b/knyttstories.install
new file mode 100644
index 000000000000..9d43a162f014
--- /dev/null
+++ b/knyttstories.install
@@ -0,0 +1,17 @@
+post_install () {
+ echo "Knytt Stories is now installed."
+ echo "Enter 'knyttstories' and enjoy :)"
+ echo "NOTE 1: In order for this to work properly, you need to be"
+ echo "a member of the 'games' group."
+ echo "NOTE 2: If you're upgrading from an earlier version of this"
+ echo "package and there are problems, delete Data in"
+ echo "~/.knyttstories/ and try starting the game again."
+# echo "Please also drop me a note if anything bad happens."
+}
+
+pre_upgrade () {
+ echo "NOTE: If you're upgrading from an earlier version of this"
+ echo "package and there are problems, delete Data in"
+ echo "~/.knyttstories/ and try starting the game again."
+# echo "Please also drop me a note if anything bad happens."
+}
diff --git a/knyttstories.png b/knyttstories.png
new file mode 100644
index 000000000000..9d47a967e9c3
--- /dev/null
+++ b/knyttstories.png
Binary files differ
diff --git a/msvcp60.zip b/msvcp60.zip
new file mode 100644
index 000000000000..d4892435fb40
--- /dev/null
+++ b/msvcp60.zip
Binary files differ