summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: aa089bf2a8d59be5cc7ffb8d8f45a58afaa24b2c (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
# Maintainer: Adrian Perez de Castro <aperez@igalia.com>
pkgname=wltrunk-git
pkgdesc='High-level Wayland compositor library based on wlroots'
pkgver=r51.a9a5fee
pkgrel=1
url='https://git.sr.ht/~bl4ckb0ne/wltrunk'
license=(custom:as-is)
arch=(x86_64)
makedepends=(meson ninja git wayland-protocols)
conflicts=(wltrunk)
provides=(wltrunk)
depends=(wlroots)
source=("${pkgname}::git+${url}")
sha512sums=(SKIP)

pkgver () {
	cd "${pkgname}"
	(
		set -o pipefail
		git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' | sed 's/^version\.//' ||
		printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
	)
}

build () {
	rm -rf build
	arch-meson -Dtrunkston=false "${pkgname}" build
	ninja -C build
}

package () {
	DESTDIR="${pkgdir}" ninja -C build install
}