summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7c202c0b304529074db01f07d180651639caa4f9 (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
35
36
37
38
39
40
41
# Maintainer: Mike Swanson <mikeonthecomputer@gmail.com>

pkgname=tyrquake-git
pkgver=0.61.r1226.0ca7766
pkgrel=1
pkgdesc="A conservative Quake port"
arch=('i686' 'x86_64')
url="http://disenchant.net/tyrquake/"
license=(GPL2)
depends=(sdl2)
makedepends=(git)
conflicts=(tyrquake)
provides=(tyrquake)
install=tyrquake.install
source=("git://disenchant.net/tyrquake")
sha256sums=('SKIP')

pkgver() {
  cd "${pkgname/-git/}"
  local version="$(git describe --long | sed 's/\([^-]*-\)g/r\1/;s/-/./g')"
  printf %s "${version##v}"
}

build() {
  cd "${pkgname/-git/}"

  [ "$CARCH" = "i686" ] && _asm=Y || _asm=N

  make QBASEDIR=/usr/share/games/quake \
       USE_X86_ASM=$_asm               \
       OPTIMIZED_CFLAGS=N              \
       USE_SDL=Y                       \
       STRIP=true
}

package() {
  cd "${pkgname/-git/}"

  install -d "$pkgdir/usr/bin"
  install bin/tyr-* "$pkgdir/usr/bin"
}