summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 9203532337a07580843b891d1b313d9a8d4b4997 (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
42
43
44
45
46
47
48
49
50
51
# Maintainer: Nicola Revelant <nicolarevelant@outlook.com>

pkgname=italian-draughts-git
pkgver=1.3.4.r28.g74eb7da
pkgrel=2
pkgdesc="Italian Draughts, a strategy board game"
arch=("x86_64")
license=('GPL-3.0-or-later')
depends=(
	"wxwidgets-gtk3"
	"hicolor-icon-theme"
)
makedepends=(
	"git"
	"cmake"
	"ninja"
	"scdoc"
)
url="https://github.com/nicolarevelant/italian-draughts"
source=(
	"$pkgname"::"git+$url.git"
	'italian-draughts.desktop'
)
sha256sums=(
	'SKIP'
	'99625c7024e47343e9e838abdbc8d30613841afef84afb1fab54f7e024535d00'
)

build() {
	cd "$pkgname"
	cmake \
		-B build \
		-G Ninja \
		-D CMAKE_INSTALL_PREFIX="/usr" \
		-D DOCS=1 \
		-Wno-dev

	cmake --build build
}

package() {
	install -Dm 644 italian-draughts.desktop -t "$pkgdir/usr/share/applications"
	cd "$pkgname"
	cmake --install build --prefix "$pkgdir/usr"
	install -Dm 644 logo/italian-draughts.svg -t "$pkgdir/usr/share/icons/hicolor/scalable/apps"
}

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