# Maintainer: Maxime Gauduin <alucryd@archlinux.org>
# Contributor: Alexander Baldeck <alexander@archlinux.org>
# Contributor: dorphell <dorphell@archlinux.org>

pkgname=zvbi
pkgver=0.2.42
pkgrel=1
pkgdesc='VBI capture and decoding library'
url=http://zapping.sourceforge.net/cgi-bin/view/ZVBI/WebHome
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
depends=(
  libpng
  libx11
)
makedepends=(git)
license=(
  BSD
  GPL2
  LGPL2.1
  MIT
)
_tag=3785481f51f41a49e28f2b7f6fd5bd9187d24ae1
#source=(git+https://github.com/zapping-vbi/zvbi.git?signed#tag=${_tag})
source=(git+https://github.com/zapping-vbi/zvbi.git#tag=${_tag})
b2sums=(SKIP)
validpgpkeys=(FA26CA784BE188927F22B99F6570EA01146F7354) # Ileana Dumitrescu <ileanadumitrescu95@gmail.com>

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

pkgver() {
  cd zvbi
  git describe --tags | sed 's/^v//'
}

build() {
  cd zvbi
  ./configure \
    --prefix=/usr \
    --sbindir=/usr/bin
  make
}

package() {
  cd zvbi
  make DESTDIR="${pkgdir}" install
  install -Dm 644 COPYING.md -t "${pkgdir}"/usr/share/licenses/zvbi
}

# vim: ts=2 sw=2 et:
