text: # Contributor: Bart Ribbers <bribbers@disroot.org>
  # Maintainer: Bart Ribbers <bribbers@disroot.org>
  pkgname=libksane
  pkgver=20.08.1
  pkgrel=0
  arch="all !armhf" # armhf blocked by extra-cmake-modules
  url="https://www.kde.org/applications/graphics/"
  pkgdesc="An image scanning library"
  license="LGPL-2.1-only OR LGPL-3.0-only"
  makedepends="extra-cmake-modules qt5-qtbase-dev ki18n-dev kwidgetsaddons-dev ktextwidgets-dev kwallet-dev sane-dev"
  source="https://download.kde.org/stable/release-service/$pkgver/src/libksane-$pkgver.tar.xz"
  subpackages="$pkgname-dev $pkgname-lang"
  
  build() {
  	cmake -B build \
  		-DCMAKE_BUILD_TYPE=None \
  		-DCMAKE_INSTALL_PREFIX=/usr \
  		-DCMAKE_INSTALL_LIBDIR=lib
  	cmake --build build
  }
  
  check() {
  	cd build
  	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
  }
  
  package() {
  	DESTDIR="$pkgdir" cmake --build build --target install
  }
  
  sha512sums="7ee4c83a28194f964b2b15f6d7a00d1b8f301e46a32522e9df99ded1ded8e47e11ca574f8199473060668dfd5e4208fdc80d028e0d413e25ffd98c439fb383f7  libksane-20.08.1.tar.xz"
  