desktop/corsix-th/PKGBUILD
Adrian Chaves Fernandez (Gallaecio) f688e90021 corsix-th 0.30
2014-12-20 06:13:12 +00:00

47 lines
1.4 KiB
Bash

#
# Games Packages for Chakra, part of chakra-project.org
#
# Maintainer: Adrián Chaves Fernández (Gallaecio) <adriyetichaves gmail.com>
pkgname=corsix-th
_pkgname=CorsixTH
pkgver=0.30
_pkgver=$pkgver
pkgrel=1
pkgdesc='Reimplementation of the game engine of Theme Hospital.'
arch=('i686' 'x86_64')
url='http://corsix-th.googlecode.com'
license=('MIT')
depends=('ffmpeg' 'lua' 'sdl_mixer' 'timidity++' 'x264')
categories=('games')
makedepends=('cmake')
install=$pkgname.install
source=("https://github.com/CorsixTH/CorsixTH/archive/v${pkgver}.tar.gz"
"$pkgname.sh")
sha1sums=('033644d2115888093f65c683022fb5ad9ea0d74b'
'7fd6ae8db366b7f9c4671708e8ea7beb48f1bea3')
# The code below has been strongly based on
# https://gist.github.com/Rayman2200/8118205
# for version 0.30.
build() {
cd "${srcdir}/CorsixTH-${pkgver}"
# CMake config is broke for corsix-th v0.30, so the LICENSE need to be moved to the right location
mv LICENSE CorsixTH/LICENSE.txt
cmake \
-D CMAKE_INSTALL_PREFIX=/usr/share/ \
-D CMAKE_BUILD_TYPE=Release \
-Wno-dev \
.
cd CorsixTH
make
}
package() {
cd "${srcdir}/CorsixTH-${pkgver}/CorsixTH"
make DESTDIR="${pkgdir}" install
install -Dm755 CorsixTH "${pkgdir}/usr/bin/CorsixTH"
install -Dm644 ../DebianPackage/usr/share/applications/CorsixTH.desktop "${pkgdir}/usr/share/applications/CorsixTH.desktop"
sed -e 's/games/share/g' -i "${pkgdir}/usr/share/applications/CorsixTH.desktop"
}