summaryrefslogtreecommitdiff
path: root/community-testing/openttd
diff options
context:
space:
mode:
Diffstat (limited to 'community-testing/openttd')
-rw-r--r--community-testing/openttd/PKGBUILD39
-rw-r--r--community-testing/openttd/openttd.install17
2 files changed, 56 insertions, 0 deletions
diff --git a/community-testing/openttd/PKGBUILD b/community-testing/openttd/PKGBUILD
new file mode 100644
index 000000000..c546a3db3
--- /dev/null
+++ b/community-testing/openttd/PKGBUILD
@@ -0,0 +1,39 @@
+# $Id: PKGBUILD 69106 2012-04-09 13:50:09Z tdziedzic $
+# Maintainer: Vesa Kaihlavirta <vegai@iki.fi>
+
+pkgname=openttd
+pkgver=1.2.0rc4
+_realpkgver=1.2.0-RC4
+pkgrel=1
+pkgdesc='An engine for running Transport Tycoon Deluxe.'
+arch=('i686' 'x86_64')
+url='http://www.openttd.org'
+license=('GPL')
+depends=('libpng' 'sdl' 'icu' 'fontconfig' 'lzo2' 'hicolor-icon-theme' 'desktop-file-utils' 'xz')
+install=openttd.install
+optdepends=('openttd-opengfx: free graphics'
+ 'openttd-opensfx: free soundset')
+source=("http://binaries.openttd.org/releases/${_realpkgver}/${pkgname}-${_realpkgver}-source.tar.xz")
+md5sums=('b8692deb951dc3a88c321a9e4b254dd2')
+
+build() {
+ cd ${pkgname}-${_realpkgver}
+
+ ./configure \
+ --prefix-dir=/usr \
+ --binary-name=${pkgname} \
+ --binary-dir=bin \
+ --data-dir=share/${pkgname} \
+ --install-dir=${pkgdir} \
+ --doc-dir=share/doc/${pkgname} \
+ --menu-name="OpenTTD" \
+ --personal-dir=.${pkgname}
+
+ make
+}
+
+package() {
+ cd ${pkgname}-${_realpkgver}
+
+ make install
+}
diff --git a/community-testing/openttd/openttd.install b/community-testing/openttd/openttd.install
new file mode 100644
index 000000000..85b22a1c5
--- /dev/null
+++ b/community-testing/openttd/openttd.install
@@ -0,0 +1,17 @@
+post_install() {
+ gtk-update-icon-cache -q -t -f /usr/share/icons/hicolor > /dev/null 2>&1
+ update-desktop-database > /dev/null 2>&1
+}
+
+post_upgrade() {
+ post_install $1
+}
+
+pre_remove() {
+ update-desktop-database > /dev/null 2>&1
+}
+
+post_remove() {
+ gtk-update-icon-cache -q -t -f /usr/share/icons/hicolor > /dev/null 2>&1
+ update-desktop-database > /dev/null 2>&1
+}