# The group tag is just to easily find this APKBUILD by some scripts for automation
# group=kde-frameworks
maintainer="team/kde <bribbers@disroot.org>"
pkgname=kdbusaddons
pkgver=6.13.0
pkgrel=0
pkgdesc="Addons to QtDBus"
# armhf blocked qt6-qtdeclarative
arch="all !armhf"
url="https://community.kde.org/Frameworks"
license="LGPL-2.1-only OR LGPL-3.0-only"
makedepends="
	doxygen
	extra-cmake-modules
	graphviz
	qt6-qtdeclarative-dev
	qt6-qtdeclarative-private-dev
	qt6-qttools-dev
	shared-mime-info
	samurai
	"
checkdepends="dbus"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang"
_repo_url="https://invent.kde.org/frameworks/kdbusaddons.git"
source="https://download.kde.org/stable/frameworks/${pkgver%.*}/kdbusaddons-$pkgver.tar.xz"

build() {
	cmake -B build -G Ninja \
		-DCMAKE_BUILD_TYPE=RelWithDebInfo \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_QCH=ON
	cmake --build build
}

check() {
	dbus-run-session -- ctest --test-dir build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
dd229022d3a9c4f03562d739b2770ca844ea4dafd416a60185cf0f9248131cc8666cc2f45a29e91f810b09852949866223bcec2d1d86f3bc904a32167704095e  kdbusaddons-6.13.0.tar.xz
"
