# Maintainer: Balló György <ballogyor+arch at gmail dot com>
# Contributor: Lukas Jirkovsky <l.jirkovsky@gmail.com>

pkgname=libiptcdata
pkgver=1.0.5
pkgrel=4
pkgdesc='Library for manipulating the IPTC metadata'
arch=(x86_64 aarch64)
url='https://libiptcdata.sourceforge.net/'
license=(LGPL-2.0-or-later)
depends=(glibc)
makedepends=(
  git
  gtk-doc
  python-setuptools
)
optdepends=('python: Python bindings')
source=("git+https://github.com/ianw/libiptcdata.git#tag=release_${pkgver//./_}")
b2sums=(def76cf757f9c4b8f0d4f2e406e14fe3bb98364bcc8d4307609e0cf3927e0befe514389795401a83a867ca4b5f0407d097b22dc0ecb82166aa4f8a3c88241db9)

prepare() {
  cd $pkgname
  autoreconf -fi
}

build() {
  cd $pkgname
  ./configure \
    --prefix=/usr \
    --sysconfdir=/etc \
    --localstatedir=/var \
    --enable-gtk-doc \
    --enable-python
  make
}

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