# Maintainer: Antonio Rojas <arojas@archlinux.org>
# Contributor: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Balló György <ballogyor+arch at gmail dot com>

pkgname=libaccounts-glib
pkgver=1.25
pkgrel=4
pkgdesc='Glib-based client library for accessing the online accounts database'
arch=(x86_64)
url='https://gitlab.com/accounts-sso/libaccounts-glib'
license=(LGPL)
depends=(dbus-glib libxml2 sqlite)
makedepends=(python-gobject gobject-introspection vala meson check)
source=(https://gitlab.com/accounts-sso/libaccounts-glib/-/archive/VERSION_$pkgver/libaccounts-glib-VERSION_$pkgver.tar.gz)
sha256sums=('47d4b2a5cf4f17f52550aa65b34030fbd1a242e1a233f248a5871620e0ff4c11')

build() {
  meson $pkgname-VERSION_$pkgver build \
    -Dtests=false \
    -Dprefix=/usr
  meson compile -C build
}

check() {
  meson test -C build || true
}

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