initial import
This commit is contained in:
57
openttd-legacy/PKGBUILD
Normal file
57
openttd-legacy/PKGBUILD
Normal file
@@ -0,0 +1,57 @@
|
||||
# Maintainer: Jesus E. <heckyel@riseup.net>
|
||||
|
||||
_realpkgname=openttd
|
||||
pkgname=$_realpkgname-legacy
|
||||
pkgver=13.4
|
||||
_debver=$pkgver
|
||||
_debrel=1
|
||||
pkgrel=1
|
||||
pkgdesc="A free and libre transport-simulation game (legacy version)"
|
||||
arch=('i686' 'x86_64')
|
||||
url='https://github.com/OpenTTD/OpenTTD'
|
||||
license=('GPL-2')
|
||||
provides=('openttd')
|
||||
conflicts=('openttd')
|
||||
depends=('libpng' 'sdl2' 'icu' 'fontconfig' 'lzo'
|
||||
'hicolor-icon-theme' 'desktop-file-utils' 'xz' 'fluidsynth'
|
||||
'openttd-opengfx' 'openttd-opensfx' 'openttd-openmsx')
|
||||
makedepends=('quilt' 'cmake' 'ninja')
|
||||
groups=('games')
|
||||
source=("${pkgname}-${pkgver}.tar.xz::https://deb.debian.org/debian/pool/main/o/openttd/openttd_${pkgver}.orig.tar.xz"
|
||||
"https://deb.debian.org/debian/pool/main/o/openttd/openttd_${_debver}-${_debrel}.debian.tar.xz"
|
||||
"remove-online-content.patch")
|
||||
sha512sums=('84f57a39c0dade44f0e6153dff7a40eec0da8e2f892ce870d5f9e037f80daa5c7c46ff786fa51c3671366dd5056504cd7ccbc1c4e5bce8b2c5575533b454c001'
|
||||
'05918ada5220187783e5d9cfc0b4dfba049acbd45cc0420c1b09c8274b685c989886f84a950e1f5689e67aa0fa3f46da63f1a2b91f1f48943ef3af346a26f404'
|
||||
'93b25dae84f04253da81e01b11de513244e794a8d102b1546d48bcb277be53f9b070039df0da4dd82c48bb1c3800d94447a20497261a59a2f79196013d022a0f')
|
||||
|
||||
prepare() {
|
||||
cd ${_realpkgname}-${pkgver}
|
||||
if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
|
||||
# Debian patches
|
||||
export QUILT_PATCHES=debian/patches
|
||||
export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
|
||||
export QUILT_DIFF_ARGS='--no-timestamps'
|
||||
|
||||
mv "$srcdir"/debian .
|
||||
|
||||
quilt push -av
|
||||
fi
|
||||
patch -Np1 -i ${srcdir}/remove-online-content.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
cmake \
|
||||
-B build \
|
||||
-S $_realpkgname-$pkgver \
|
||||
-D CMAKE_BUILD_TYPE=Release \
|
||||
-D CMAKE_INSTALL_PREFIX=/usr \
|
||||
-D CMAKE_INSTALL_BINDIR=games \
|
||||
-D CMAKE_INSTALL_DATADIR=/usr/share/games \
|
||||
-G Ninja
|
||||
ninja -C build
|
||||
}
|
||||
|
||||
package() {
|
||||
DESTDIR="$pkgdir" ninja -C build install
|
||||
install -Dm644 $srcdir/$_realpkgname-$pkgver/COPYING.md -t "${pkgdir}/usr/share/licenses/$pkgname"
|
||||
}
|
||||
Reference in New Issue
Block a user