# Contributor: Marian Buschsieweke <marian.buschsieweke@posteo.net>
# Maintainer: Marian Buschsieweke <marian.buschsieweke@posteo.net>
pkgname=qwt
pkgver=6.2.0
pkgrel=0
pkgdesc="Qt Widgets for Technical Applications"
url="https://qwt.sourceforge.io/"
arch="all"
license="custom" # Based on LGPL but more liberal
makedepends="qt5-qtbase-dev qt5-qtsvg-dev qt5-qttools-dev"
subpackages="$pkgname-dev $pkgname-doc"
source="https://downloads.sourceforge.net/qwt/qwt-$pkgver.tar.bz2
	10_install_paths.patch
	20_fix_rpath.patch
	"
options="!check" # no unit tests

build() {
	qmake-qt5 qwt.pro
	make
}

package() {
	make INSTALL_ROOT="$pkgdir" install

	mv "$pkgdir/usr/share/doc/qwt/man" "$pkgdir/usr/share"
	install -Dm 644 COPYING -t "$pkgdir/usr/share/licenses/$pkgname"
}

sha512sums="
d992f9dddb09ad0e1d09e23a24a9331c950ca19a413d2627cf423e1ddc2a4ad4eb951646f789e8c7a9ab42668c30d7108071f3f8bbd8e1f4118cadb67c34939d  qwt-6.2.0.tar.bz2
70fd01facc2f5e5fa91131f6fb2278d01cd73e0d0982837125d20e732616680d548834ee8a0a2e049437bb64f389b2bc95c8c366bcafc91f09a5181d86cd938d  10_install_paths.patch
f0ebdc2e90c318f8c9a2aa925234b85e328611d3713939066e71494b912dde5bd99c328ef2ae0de606603da461377ea43da960c617d064c85c4488e2934eb4e5  20_fix_rpath.patch
"
