# Template file for 'khtml'
pkgname=khtml
version=5.55.0
revision=1
build_style=cmake
configure_args="-DBUILD_TESTING=OFF"
hostmakedepends="extra-cmake-modules gperf"
makedepends="kjs-devel kparts-devel jasper-devel giflib-devel libpng-devel"
short_desc="KDE HTML rendering engine"
maintainer="John <johnz@posteo.net>"
license="LGPL-2.0-or-later"
homepage="https://projects.kde.org/projects/frameworks/khtml"
distfiles="${KDE_SITE}/frameworks/${version%.*}/portingAids/${pkgname}-${version}.tar.xz"
checksum=7885169137cd2bb0b6e616a08e4a1b687b27873907b3a3050b4e3d507bf90972

if [ "$CROSS_BUILD" ]; then
	hostmakedepends+=" qt5-host-tools qt5-qmake python perl kcoreaddons"
	configure_args+=" -DDESKTOPTOJSON_EXECUTABLE=/usr/bin/desktoptojson"
fi

khtml-devel_package() {
	short_desc+=" - development"
	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"
	pkg_install() {
		vmove usr/include
		vmove usr/lib/qt5/mkspecs
		vmove usr/lib/cmake
		vmove "usr/lib/*.so"
	}
}