51 lines
1.7 KiB
Bash
51 lines
1.7 KiB
Bash
# Maintainer: Martchus <martchus@gmx.net>
|
|
|
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
|
# you also find the URL of a binary repository.
|
|
|
|
_reponame=qtutilities
|
|
pkgname=static-compat-qtutilities
|
|
_name=${pkgname#static-compat-}
|
|
pkgver=6.6.1
|
|
pkgrel=1
|
|
arch=('i686' 'x86_64' 'armv6h' 'armv7h' 'aarch64')
|
|
pkgdesc='Common Qt related C++ classes and routines used by my applications such as dialogs, widgets and models'
|
|
license=('GPL')
|
|
depends=('static-compat-c++utilities' 'static-compat-qt6-base')
|
|
makedepends=('static-compat-cmake' 'ninja' 'static-compat-qt6-tools' 'clang')
|
|
optdepends=("$_name-doc: API documentation")
|
|
url="https://github.com/Martchus/${_reponame}"
|
|
source=("${_name}-${pkgver}.tar.gz::https://github.com/Martchus/${_reponame}/archive/v${pkgver}.tar.gz")
|
|
sha256sums=('118df63a255a181c14cf1588c6abddda73bc545125a8406aa8e0e4f9fa98a13d')
|
|
|
|
build() {
|
|
check_buildoption ccache y && ccache_args='
|
|
-DCMAKE_C_COMPILER_LAUNCHER=ccache
|
|
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache'
|
|
export CXXFLAGS+=' -static-libgcc -static-libstdc++'
|
|
source static-compat-environment
|
|
export PATH=$PWD:$PATH
|
|
printf '#!/usr/bin/bash\nexec /usr/bin/pkg-config --static "$@"\n' > pkg-config
|
|
chmod +x pkg-config
|
|
cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
|
|
static-compat-cmake -G Ninja \
|
|
-DQT_PACKAGE_PREFIX:STRING='Qt6' \
|
|
-DBUILTIN_TRANSLATIONS:BOOL=ON \
|
|
-DSVG_SUPPORT:BOOL=OFF \
|
|
-DSVG_ICON_SUPPORT:BOOL=OFF \
|
|
.
|
|
ninja
|
|
}
|
|
|
|
check() {
|
|
source static-compat-environment
|
|
cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
|
|
QT_QPA_PLATFORM=offscreen ninja check
|
|
}
|
|
|
|
package() {
|
|
source static-compat-environment
|
|
cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
|
|
DESTDIR="${pkgdir}" ninja install
|
|
}
|