summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 1797ed7b891b026dc9887605f6c160a0ebd87fec (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
# Maintainer: robertfoster

pkgname=xash3d-hlsdk
pkgver=r639.8f5c36dc
pkgrel=1
pkgdesc="Half-Life SDK from original Xash3D engine"
arch=('x86_64')
url="http://xash.su/"
license=('GPL3')
makedepends=('cmake' 'git')
source=("${pkgname}::git+https://github.com/FWGS/hlsdk-portable")

pkgver() {
  cd "${srcdir}/${pkgname}"
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

prepare() {
  cd "${srcdir}/${pkgname}"
  git submodule update --init --recursive
}

build() {
  cmake -B build -S "${srcdir}/${pkgname}" \
    -DCMAKE_INSTALL_PREFIX=/usr/lib \
    -D64BIT=1

  cmake --build build
}

package() {
  DESTDIR="${pkgdir}" \
    cmake --install build
}

sha256sums=('SKIP')