# Maintainer: PktSurf <smlinux@pktsurf.in>
app=exiv2
version=0.27.5
build=1sml
homepage="https://exiv2.org/"
download="https://github.com/Exiv2/exiv2/releases/download/v$version/exiv2-$version-Source.tar.gz"
desc="C++ library and a utility to read and write Exif, IPTC and XMP image metadata"
requires="gcc-libs expat zlib curl"

prepbuilddir() {
  mkandenterbuilddir
  rm -rf $app-$version

  tar xf $srcdir/$app-$version.tar.?z*
  cd $app-$version
  fixbuilddirpermissions
}

build() {
  mkdir -p smbuild && cd smbuild
  cmake .. \
    -DCMAKE_INSTALL_PREFIX= \
    -DCMAKE_INSTALL_LIBDIR=lib

  make
  make install DESTDIR=$pkg

  cp ../COPYING* ../doc/COPYING-XMPSDK $pkgdocs/

  mkfinalpkg
}

sha512sums="
b7f882a3f6a77f9c54fe7298f8d73dc9147c8ba03bb8a68e5bb7e73920ca8596983e50168c5b1891a3f71654999cb091c6727cbcdd171a1ba7e1aea682adc65e  exiv2-0.27.5.tar.lz
"
