# Contributor: Bart Ribbers # Maintainer: Bart Ribbers pkgname=qt6-qtwebchannel pkgver=6.5.2 pkgrel=0 pkgdesc="Provides access to QObject or QML objects from HTML clients" url="https://qt.io/" arch="all" license="LGPL-2.1-only AND LGPL-3.0-only AND GPL-3.0-only AND Qt-GPL-exception-1.0" depends_dev=" qt6-qtbase-dev qt6-qtdeclarative-dev qt6-qtwebsockets-dev " makedepends="$depends_dev cmake perl samurai " subpackages="$pkgname-dev" builddir="$srcdir/qtwebchannel-everywhere-src-${pkgver/_/-}" case $pkgver in *_alpha*|*_beta*|*_rc*) _rel=development_releases;; *) _rel=official_releases;; esac source="https://download.qt.io/$_rel/qt/${pkgver%.*}/${pkgver/_/-}/submodules/qtwebchannel-everywhere-src-${pkgver/_/-}.tar.xz" build() { export CFLAGS="$CFLAGS -g1 -flto=auto" export CXXFLAGS="$CXXFLAGS -g1 -flto=auto" cmake -B build -G Ninja \ -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DCMAKE_INSTALL_PREFIX=/usr \ -DINSTALL_BINDIR=lib/qt6/bin \ -DINSTALL_DOCDIR=share/doc/qt6 \ -DINSTALL_ARCHDATADIR=lib/qt6 \ -DINSTALL_DATADIR=share/qt6 \ -DINSTALL_INCLUDEDIR=include/qt6 \ -DINSTALL_MKSPECSDIR=lib/qt6/mkspecs \ -DINSTALL_EXAMPLESDIR=share/doc/qt6/examples cmake --build build --parallel } check() { cd build CTEST_OUTPUT_ON_FAILURE=TRUE ctest } package() { DESTDIR="$pkgdir" cmake --install build } sha512sums=" 405595dfdfed48aafe42969881994472cb08dc4105a63ccf8c5ca059c0c243b654c38356059ea26cda9165a50b306c92d296dd3eca430b29615ec0ac68431c09 qtwebchannel-everywhere-src-6.5.2.tar.xz "