From 104464050e499e261348381f052afe9ee4d48df8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Buchm=C3=BCller?= Date: Thu, 5 Nov 2015 17:39:06 +0100 Subject: [PATCH] New package: openttd-1.5.2 --- srcpkgs/openttd/template | 64 ++++++++++++++++++++++++++++++++++++++++ srcpkgs/openttd/update | 2 ++ 2 files changed, 66 insertions(+) create mode 100644 srcpkgs/openttd/template create mode 100644 srcpkgs/openttd/update diff --git a/srcpkgs/openttd/template b/srcpkgs/openttd/template new file mode 100644 index 00000000000..3980c03340c --- /dev/null +++ b/srcpkgs/openttd/template @@ -0,0 +1,64 @@ +# Template file for 'openttd' +pkgname=openttd +version=1.5.2 +_gfxver=0.5.3 +_sfxver=0.2.3 +revision=1 +build_style=gnu-configure +configure_args="--menu-name=OpenTTD --personal-dir=.openttd" +hostmakedepends="pkg-config unzip" +makedepends="SDL-devel icu-devel fontconfig-devel libpng-devel lzo-devel liblzma-devel" +depends="openttd-data hicolor-icon-theme" +short_desc="Open Source version of Transport Tycoon Deluxe" +maintainer="Jürgen Buchmüller " +license="GPL-2 Custom" +homepage="https://www.openttd.org/" +distfiles=" + http://binaries.openttd.org/releases/${version}/openttd-${version}-source.tar.xz + http://bundles.openttdcoop.org/opengfx/releases/${_gfxver}/opengfx-${_gfxver}.zip + http://bundles.openttdcoop.org/opensfx/releases/${_sfxver}/opensfx-${_sfxver}.zip +" +checksum=" + 60e68eca552e34268033885e5389ad46b88b692514bf426a6e37cebd8d819f28 + f744e3bafc27ee03703554128f8dd6d187858af486b0dcfe9570832028073220 + 3574745ac0c138bae53b56972591db8d778ad9faffd51deae37a48a563e71662 +" + +post_extract() { + cd ${XBPS_BUILDDIR} + tar xf opengfx-${_gfxver}.tar + rm opengfx-${_gfxver}.tar +} + +do_configure() { + ./configure --prefix-dir=/usr \ + --endian=LE \ + --host=${XBPS_CROSS_TRIPLET} \ + --cc-build=gcc \ + --cxx-build=g++ \ + --binary-dir=bin \ + --data-dir=share/openttd \ + --doc-dir=share/doc/openttd \ + --binary-name=openttd \ + --install-dir=${DESTDIR} \ + --with-zlib=${XBPS_CROSS_BASE}/usr/lib \ + --with-liblzo2=${XBPS_CROSS_BASE}/usr/lib \ + --menu-name=OpenTTD \ + --personal-dir=.openttd +} + +openttd-data_package() { + short_desc=" - data files" + noarch=yes + pkg_install() { + vmove usr/share/openttd + vmkdir usr/share/openttd/data + vcopy ${XBPS_BUILDDIR}/opengfx-${_gfxver}/*.grf usr/share/openttd/data + vcopy ${XBPS_BUILDDIR}/opengfx-${_gfxver}/*.obg usr/share/openttd/data + vcopy ${XBPS_BUILDDIR}/opensfx-${_sfxver}/opensfx.* usr/share/openttd/data + vlicense ${XBPS_BUILDDIR}/opengfx-${_gfxver}/license.txt LICENSE-gfx + vlicense ${XBPS_BUILDDIR}/opensfx-${_sfxver}/license.txt LICENSE-sfx + vdoc ${XBPS_BUILDDIR}/opengfx-${_gfxver}/readme.txt README-gfx + vdoc ${XBPS_BUILDDIR}/opensfx-${_sfxver}/readme.txt README-sfx + } +} diff --git a/srcpkgs/openttd/update b/srcpkgs/openttd/update new file mode 100644 index 00000000000..4303c0c21d1 --- /dev/null +++ b/srcpkgs/openttd/update @@ -0,0 +1,2 @@ +site=http://binaries.openttd.org/releases/ +pattern='href="\K[\d]+\.[\d]+\.[\d]+(?=[^-])'