# Maintainer: Jan de Groot <jan@archlinux.org>

pkgname=gnome-menus
pkgver=3.36.0
pkgrel=1
pkgdesc="GNOME menu specifications"
url="https://gitlab.gnome.org/GNOME/gnome-menus"
arch=(x86_64)
license=(GPL LGPL)
groups=(gnome)
depends=(glib2)
makedepends=(intltool gobject-introspection git gnome-common)
provides=(libgnome-menu-3.so)
_commit=66ac7579856968d3f4b76c04d55327c60b37f2fb  # tags/3.36.0^0
source=("git+https://gitlab.gnome.org/GNOME/gnome-menus.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
  make
}

check() {
  cd $pkgname
  make check
}

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