# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Contributor: Balló György <ballogyor+arch at gmail dot com>

pkgname=hitori
pkgver=3.38.2
pkgrel=1
pkgdesc="GTK+ application to generate and let you play games of Hitori"
arch=(x86_64)
url="https://wiki.gnome.org/Apps/Hitori"
license=(GPL)
depends=(gtk3)
makedepends=(yelp-tools appstream-glib git meson)
groups=(gnome-extra)
_commit=ef5bb7591b7b6dafe9354107fd4a0ca10eeb6a78  # tags/3.38.2^0
source=("git+https://gitlab.gnome.org/GNOME/hitori.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/-/+/g'
}

prepare() {
  cd $pkgname
}

build() {
  arch-meson $pkgname build
  meson compile -C build
}

check() {
  meson test -C build --print-errorlogs
}

package() {
  meson install -C build --destdir "$pkgdir"
}
