# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>

pkgname=gnome-clocks
pkgver=40.0
pkgrel=2
pkgdesc="Clocks applications for GNOME"
url="https://wiki.gnome.org/Apps/Clocks"
arch=(x86_64)
license=(GPL)
depends=(gtk3 libgweather gnome-desktop geoclue2 geocode-glib gsound libhandy)
makedepends=(vala gobject-introspection yelp-tools git meson)
groups=(gnome)
_commit=13a15e8506d90b0300f9549020c66280ee4d3026  # tags/40.0^0
source=("git+https://gitlab.gnome.org/GNOME/gnome-clocks.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() {
  DESTDIR="$pkgdir" meson install -C build
}
