summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorSunny2015-06-15 14:28:50 -0500
committerSunny2015-06-15 14:28:50 -0500
commit57c99973863ccc7c33c4ab86f8dbad81371e608e (patch)
tree629053ec62bbd8f8a797df7963b2ae6bffdda4e4
downloadaur-strife.tar.gz
initial import
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD91
-rw-r--r--strife.install12
3 files changed, 126 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..b047a56d3b8
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = strife
+ pkgdesc = Strife
+ pkgver = 0.9.4.3
+ pkgrel = 1
+ url = https://strife.com
+ install = strife.install
+ arch = i686
+ arch = x86_64
+ license = custom:strife
+ makedepends = tar
+ makedepends = gzip
+ depends = alsa-lib
+ depends = gconf
+ depends = gtk2
+ depends = nss
+ depends = libxss
+ depends = libxtst
+ depends = libtxc_dxtn
+ options = !strip
+ source = http://dl.strife.com/af1dfc2754268375727a3eec1749b27e/StrifeLinux-0.9.4.3.tar.gz
+
+pkgname = strife
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..fb04cb4190c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,91 @@
+# Maintainer: Sunny <sunnyiez@hotmail.com>
+# I cloned some codes from package hon. Thanks to the maintainer.
+
+# To speed up package creation. If you are planning to distribute
+# This on some custon repo, you might want to use the defaut slow but
+# much better xz compression.
+PKGEXT=.tar.gz
+
+pkgname=strife
+pkgver=0.9.4.3
+pkgrel=1
+pkgdesc="Strife"
+arch=('i686' 'x86_64')
+url="https://strife.com"
+license=('custom:strife')
+depends=('alsa-lib' 'gconf' 'gtk2' 'nss' 'libxss' 'libxtst' 'libtxc_dxtn')
+makedepends=('tar' 'gzip')
+options=(!strip)
+install=strife.install
+
+platform=""
+if test "$CARCH" == x86_64; then
+ platform=64
+fi
+
+source=("http://dl.strife.com/af1dfc2754268375727a3eec1749b27e/StrifeLinux${platform}-${pkgver}.tar.gz")
+[[ "$CARCH" = 'x86_64' ]] && md5sums=('e19909d82a6df83ee7a069f24db30a13')
+[[ "$CARCH" = 'i686' ]] && md5sums=('71151bead16afa31a0913b7ef5389e44')
+
+package() {
+ ## Thx to messo8080 for reminding us about the /tmp dir,
+ ## on new installs this dir is in ram by default.
+
+ if `pwd | grep -q "/tmp"`; then
+ echo \
+"You are trying to build this pkg in /tmp dir.
+This is not so good idea as /tmp dir is in ram
+by default. If you know that you have lots of
+ram (>4G) and swap and want to continue building in
+the current directory write yes and press ENTER.
+Otherwise write no and press ENTER.
+Continue?"
+ read answer
+ if [ "${answer}" == "no" ]; then
+ false
+ fi
+ fi
+ # Create Destination Directory
+ mkdir -p "${pkgdir}/opt/"
+ mkdir -p "${pkgdir}/usr/share/licenses/${pkgname}"
+
+ # Extract Files
+ cp -r "${srcdir}/Strife" "${pkgdir}/opt/strife"
+
+ # Install License
+ cp "${srcdir}/Strife/license.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+ cp "${srcdir}/Strife/tos_en.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+ cp "${srcdir}/Strife/tos_ru.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+ cp "${srcdir}/Strife/tos_th.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+ cp "${srcdir}/Strife/tos_zh.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+ cp "${srcdir}/Strife/tos.txt" "${pkgdir}/usr/share/licenses/${pkgname}/"
+
+ # Fixed a problem preventing strife to start on Arch Linux
+ mv "${pkgdir}/opt/strife/bin/libgpg-error.so.0" "${pkgdir}/opt/strife/bin/libgpg-error.so.0.bk"
+
+ # Install Desktop Shortcut
+ touch "${srcdir}/strife.desktop"
+ echo "[Desktop Entry]" > "${srcdir}/strife.desktop"
+ echo "Encoding=UTF-8" >> "${srcdir}/strife.desktop"
+ echo "Name=Strife" >> "${srcdir}/strife.desktop"
+ echo "GenericName=Strife" >> "${srcdir}/strife.desktop"
+ echo "Comment=Second generation MOBA created by S2 Games" >> "${srcdir}/strife.desktop"
+ echo "Exec=/usr/bin/strife" >> "${srcdir}/strife.desktop"
+ echo "Icon=/opt/strife/icon.png" >> "${srcdir}/strife.desktop"
+ echo "StartupNotify=true" >> "${srcdir}/strife.desktop"
+ echo "Terminal=false" >> "${srcdir}/strife.desktop"
+ echo "Type=Application" >> "${srcdir}/strife.desktop"
+ echo "Categories=Application;Game;" >> "${srcdir}/strife.desktop"
+
+ install -D -m 0644 "${srcdir}/strife.desktop" \
+ "${pkgdir}/usr/share/applications/strife.desktop"
+
+
+ # Install Client Launcher
+ mkdir -p "${pkgdir}/usr/bin"
+ ln -s /opt/strife/bin/strife "${pkgdir}/usr/bin/strife"
+
+ # Set Ownership to root:games
+ chown -R root:games "${pkgdir}/opt/strife"
+ chmod -R g+w "${pkgdir}/opt/strife"
+}
diff --git a/strife.install b/strife.install
new file mode 100644
index 00000000000..76c922b9ea4
--- /dev/null
+++ b/strife.install
@@ -0,0 +1,12 @@
+
+post_install() {
+ echo ">>> You must read and agree to the terms in the TOSs found"
+ echo ">>> in /usr/share/licenses/strife/ before using this software!"
+ echo ">>>"
+ echo ">>> In order to play Strife, add your user to the 'games' group."
+ echo ">>> # gpasswd -a USERNAME games"
+}
+
+post_upgrade() {
+ post_install $1
+}