summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 54d57ea4b6a02f51b1487bf5c5df651f0d33534c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
pkgname=corsix-th-git
pkgver=0.64.r10.gb7abdd01
pkgrel=1
pkgdesc='Reimplementation of the game engine of Theme Hospital, git version'
url='https://github.com/CorsixTH/CorsixTH'
arch=('i686' 'x86_64' 'armv7h')
license=('MIT')
makedepends=('cmake')
provides=('corsix-th')
conflicts=('corsix-th')
depends=('lua' 'lua-lpeg' 'lua-filesystem' 'sdl2_mixer' 'ffmpeg' 'freepats-general-midi')
install=corsix-th.install
source=("git+https://github.com/CorsixTH/CorsixTH.git")

sha256sums=('SKIP')

pkgver() {
  cd "CorsixTH"
  git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

build() {
  cd CorsixTH

  cmake -DCMAKE_BUILD_TYPE=Release -Wno-dev \
        -DLUA_PROGRAM_PATH=/usr/bin/lua -DLUA_INCLUDE_DIR=/usr/include -DLUA_LIBRARY=/usr/lib/liblua.so \
        -DCMAKE_INSTALL_PREFIX=/usr .
  cd CorsixTH
  make
}

package() {
  make -C CorsixTH/CorsixTH DESTDIR="$pkgdir/" install
}