author | Laurent Carlier
<lordheavym@archlinux.org> 2016-05-08 07:02:06 UTC |
committer | Laurent Carlier
<lordheavym@archlinux.org> 2016-05-08 07:02:06 UTC |
parent | 4453d9b1a9dbdbcac8ef1163ece192368fa169cf |
PKGBUILD | +12 | -4 |
openttd-1.5.3-gcc6.patch | +11 | -0 |
openttd.install | +0 | -17 |
diff --git a/PKGBUILD b/PKGBUILD index 315bbc1..cc746e6 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -2,17 +2,25 @@ pkgname=openttd pkgver=1.6.0 -pkgrel=1 +pkgrel=2 pkgdesc='An engine for running Transport Tycoon Deluxe.' arch=('i686' 'x86_64') url='http://www.openttd.org' license=('GPL') depends=('libpng' 'sdl' 'icu' 'fontconfig' 'lzo' '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/${pkgver}/${pkgname}-${pkgver}-source.tar.xz") -sha256sums=('4c12e6b516ffdee20a03ebad80dad85d137130002d6d3e123a568376fe4b4eb2') +source=("http://binaries.openttd.org/releases/${pkgver}/${pkgname}-${pkgver}-source.tar.xz" + openttd-1.5.3-gcc6.patch) +sha256sums=('4c12e6b516ffdee20a03ebad80dad85d137130002d6d3e123a568376fe4b4eb2' + '3e9652e1401150c287b71595afbf268dc4379908519d7939ec4e46548026b7e9') + +prepare() { + cd ${pkgname}-${pkgver} + + # patch from fedora + patch -Np1 -i ../openttd-1.5.3-gcc6.patch +} build() { cd ${pkgname}-${pkgver} diff --git a/openttd-1.5.3-gcc6.patch b/openttd-1.5.3-gcc6.patch new file mode 100644 index 0000000..65d9991 --- /dev/null +++ b/openttd-1.5.3-gcc6.patch @@ -0,0 +1,11 @@ +--- openttd-1.5.3/src/safeguards.h.orig 2016-02-02 16:21:10.378533175 +0000 ++++ openttd-1.5.3/src/safeguards.h 2016-02-02 16:21:15.269555568 +0000 +@@ -21,6 +21,8 @@ + #ifndef SAFEGUARDS_H + #define SAFEGUARDS_H + ++#include <stdlib.h> ++ + /* Use MallocT instead. */ + #define malloc SAFEGUARD_DO_NOT_USE_THIS_METHOD + diff --git a/openttd.install b/openttd.install deleted file mode 100644 index 85b22a1..0000000 --- a/openttd.install +++ /dev/null @@ -1,17 +0,0 @@ -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 -}