summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e32cd6123793e1b079158561043dae1d20a847d7 (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
# Maintainer: Clément Vicart <clem.vicart@gmail.com>
pkgname=gameoflife-git
pkgver=r9.ec3b15f
pkgrel=3
pkgdesc="Simple Game of Life written in C"
arch=('x86_64')
url="https://github.com/xolider/game-of-life"
license=('GPL-1.0-or-later')
depends=(sdl3 glibc sdl3_ttf ttf-roboto)
makedepends=(cmake ninja git)
source=("${pkgname}::git+https://github.com/xolider/game-of-life.git")
sha256sums=('SKIP')

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

build() {
	cmake -S "$pkgname" -B build -G Ninja -DROBOTO_TTF_PATH=/usr/share/fonts/TTF/Roboto-Regular.ttf
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build --prefix=/usr
}