# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=kwallet
pkgver=5.48.0
pkgrel=0
pkgdesc="Secure and unified container for user passwords"
arch="all"
url="https://community.kde.org/Frameworks"
license="LGPL-2.1"
depends=""
depends_dev="kservice-dev kwindowsystem-dev kconfig-dev kconfigwidgets-dev kauth-dev kcodecs-dev
			kdbusaddons-dev kiconthemes-dev knotifications-dev kcoreaddons-dev ki18n-dev kwidgetsaddons-dev"
makedepends="$depends_dev extra-cmake-modules kdoctools-dev boost doxygen qt5-qttools-dev libgcrypt-dev"
source="https://download.kde.org/stable/frameworks/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang"

build() {
	cmake "$srcdir"/${pkgname}-${pkgver} \
		-DCMAKE_BUILD_TYPE=Release \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DKDE_INSTALL_LIBDIR=lib \
		-DBUILD_QCH=ON
	make
}

check() {
	cd "$builddir"
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	cd "$builddir"
	make DESTDIR="${pkgdir}" install
}
sha512sums="465c6839f5a47126f785381f0a8b01c03aa6952c606ff1beb639f48f0f57baecff89a48590cebde1b731e8a931f96ccc0ec9e4df786aa947962cc1999c188db4  kwallet-5.48.0.tar.xz"
