# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Jan De Groot <jgc@archlinux.org>

pkgname=gucharmap
pkgver=12.0.1
pkgrel=1
pkgdesc="Gnome Unicode Charmap"
url="https://wiki.gnome.org/Apps/Gucharmap"
arch=(x86_64)
license=(GPL)
depends=(dconf gtk3)
makedepends=(gtk-doc intltool gobject-introspection yelp-tools docbook-xsl
             python2 appdata-tools unicode-character-database unzip gnome-common git)
_commit=f832495aeeeb6b20a598b895261a9d1853005147  # tags/12.0.1^0
source=("git+https://gitlab.gnome.org/GNOME/gucharmap.git#commit=$_commit")
sha256sums=('SKIP')

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

prepare() {
  cd $pkgname
  NOCONFIGURE=1 ./autogen.sh
}

build() {
  cd $pkgname
  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --disable-static \
    --disable-schemas-compile --enable-introspection --with-unicode-data=/usr/share/unicode
  make
}

package() {
  cd $pkgname
  make DESTDIR="$pkgdir" install
}
