# Contributor: Kiyoshi Aman # Maintainer: Kiyoshi Aman pkgname=nheko pkgver=0.4.3 pkgrel=0 pkgdesc="Qt5-based client for Matrix protocol" url="https://github.com/mujx/nheko" arch="" # Current version is deprecated, needs to be transferred to nheko reborn license="GPL-3.0+" options="!check" # no test suite makedepends="clang cmake qt5-qtbase-dev qt5-qttools-dev qt5-qtmultimedia-dev qt5-qtsvg-dev libsodium-dev lmdb-dev" source="$pkgname-$pkgver.tar.gz::https://github.com/mujx/nheko/archive/v$pkgver.tar.gz" builddir="$srcdir/$pkgname-$pkgver" build() { cd "$builddir" if [ "$CBUILD" != "$CHOST" ]; then CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux" fi mkdir -p build cd "$builddir"/build cmake \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DBUILD_SHARED_LIBS=True \ -DCMAKE_SKIP_RPATH=True \ -DCMAKE_BUILD_TYPE=RelWithDebugInfo \ -DCMAKE_CXX_FLAGS="$CXXFLAGS -stdlib=libstdc++" \ -DCMAKE_C_FLAGS="$CFLAGS" \ -DCMAKE_CXX_COMPILER=clang++ \ -DCMAKE_C_COMPILER=clang \ ${CMAKE_CROSSOPTS} .. make } check() { cd "$builddir"/build CTEST_OUTPUT_ON_FAILURE=TRUE ctest } package() { cd "$builddir"/build install -D -m755 nheko "$pkgdir"/usr/bin/nheko install -D -m644 ../resources/nheko-256.png "$pkgdir"/usr/share/pixmaps/nheko-256.png install -D -m644 ../resources/nheko.desktop "$pkgdir"/usr/share/applications/nheko.desktop local size dir for size in 16 32 48 64 128 256 512; do dir="$pkgdir"/usr/share/icons/hicolor/${size}x${size}/apps install -D -m644 ../resources/nheko-${size}.png "$dir"/nheko.png; done } sha512sums="b9ad4131b75af7ee3b79cb89d63313e94f76a6a6672c5c02b264ebec75a2a2525de266d6e4d07482736b714188a5a1eba721802ff951ee4d77f8cbf571758777 nheko-0.4.3.tar.gz"