void-packages/srcpkgs/qtutilities/template
2025-02-04 12:21:04 -05:00

39 lines
1.3 KiB
Bash

# Template file for 'qtutilities'
pkgname=qtutilities
version=6.14.6
revision=1
build_style=cmake
configure_args="-DBUILD_SHARED_LIBS=ON -DQT_PACKAGE_PREFIX=Qt6"
hostmakedepends="qt6-base qt6-tools"
makedepends="qt6-base-devel cpp-utilities-devel"
checkdepends="xvfb-run"
short_desc="Qt helper routines, including dialogs, widgets, and models"
maintainer="Andrew J. Hesford <ajh@sideband.org>"
license="GPL-2.0-only"
homepage="https://github.com/Martchus/qtutilities"
distfiles="https://github.com/Martchus/qtutilities/archive/v${version}.tar.gz"
checksum=cfa243a8b60beb7298cee44ca38e0e4af25ea76f33fc4aca2456fb902029f370
pre_check() {
ninja -C build tests
}
qtutilities-devel_package() {
short_desc+=" - development files"
depends="${sourcepkg}>=${version}_${revision} cpp-utilities-devel"
pkg_install() {
vmove usr/include
vmove "usr/lib/*.so"
vmove usr/lib/pkgconfig
# Rename cmake modules to fit with the rest of the system
vmkdir usr/lib/cmake
cmake_source="${DESTDIR}/usr/share/${sourcepkg}/cmake"
cmake_dest="${PKGDESTDIR}/usr/lib/cmake/${sourcepkg}"
mv "$cmake_source" "$cmake_dest"
# Update cmake configuration to point to new location
vsed -i "${cmake_dest}/${sourcepkg}Config.cmake" \
-e "s@share/${sourcepkg}/cmake@lib/cmake/${sourcepkg}@g"
}
}