summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authoremanuele-f2020-11-01 12:23:38 +0100
committeremanuele-f2020-11-01 12:23:38 +0100
commit13cd8dc91e6245051b52cbcda5778448b4fed33f (patch)
treeb6215d90f0a49bc056518b7ce7d0f0924b4bd7b3
downloadaur-13cd8dc91e6245051b52cbcda5778448b4fed33f.tar.gz
Initial commit for syncthingtray-lite
The syncthingtray-lite package provides a convenient way to install syncthingtray without pulling the KDE dependencies. The javascript scripting is also disabled to further reduce the package size.
-rw-r--r--.SRCINFO29
-rw-r--r--PKGBUILD58
2 files changed, 87 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..aaa16852b9c
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,29 @@
+pkgbase = syncthingtray-lite
+ pkgdesc = Tray application for Syncthing
+ pkgver = 1.0.0
+ pkgrel = 1
+ url = https://github.com/Martchus/syncthingtray
+ arch = i686
+ arch = x86_64
+ arch = armv6h
+ arch = armv7h
+ arch = aarch64
+ license = GPL
+ checkdepends = cppunit
+ checkdepends = syncthing
+ checkdepends = iproute2
+ makedepends = cmake
+ makedepends = ninja
+ makedepends = qt5-tools
+ makedepends = mesa
+ depends = qtutilities
+ depends = qt5-svg
+ depends = openssl
+ depends = desktop-file-utils
+ depends = xdg-utils
+ depends = qt5-webengine
+ source = syncthingtray-lite-1.0.0.tar.gz::https://github.com/Martchus/syncthingtray/archive/v1.0.0.tar.gz
+ sha256sums = fe8358c74862511046466d1cbfe216a255ba8d390b464369514e4404e3747b83
+
+pkgname = syncthingtray-lite
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..d5043b51bba
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,58 @@
+# Maintainer: Emanuele Faranda <black.silver@hotmail.it>
+
+# Based on https://aur.archlinux.org/packages/syncthingtray by
+# Martchus <martchus@gmx.net>.
+
+# if tests fail due to timeout, you can try to increase the timeout
+# by setting SYNCTHING_TEST_TIMEOUT_FACTOR
+
+# set the web view provider: either webkit, webengine, auto or none
+_webview_provider=${SYNCTHING_TRAY_WEBVIEW_PROVIDER:-webengine}
+
+_reponame=syncthingtray
+pkgname=syncthingtray-lite
+pkgver=1.0.0
+pkgrel=1
+arch=('i686' 'x86_64' 'armv6h' 'armv7h' 'aarch64')
+pkgdesc='Tray application for Syncthing'
+license=('GPL')
+depends=('qtutilities' 'qt5-svg' 'openssl' 'desktop-file-utils' 'xdg-utils')
+[[ $_webview_provider == none ]] && depends+=('qt5-base')
+[[ $_webview_provider == webkit ]] && depends+=('qt5-webkit')
+[[ $_webview_provider == webengine ]] && depends+=('qt5-webengine')
+makedepends=('cmake' 'ninja' 'qt5-tools' 'mesa')
+checkdepends=('cppunit' 'syncthing' 'iproute2')
+url="https://github.com/Martchus/${_reponame}"
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/Martchus/${_reponame}/archive/v${pkgver}.tar.gz")
+sha256sums=('fe8358c74862511046466d1cbfe216a255ba8d390b464369514e4404e3747b83')
+
+ephemeral_port() {
+ comm -23 <(seq 49152 65535) <(ss -tan | awk '{print $4}' | cut -d':' -f2 | grep "[0-9]\{1,5\}" | sort | uniq) | shuf | head -n 1
+}
+
+build() {
+ cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
+
+ cmake \
+ -G Ninja \
+ -DCMAKE_BUILD_TYPE:STRING='Release' \
+ -DCMAKE_INSTALL_PREFIX:PATH='/usr' \
+ -DBUILD_SHARED_LIBS:BOOL=ON \
+ -DWEBVIEW_PROVIDER="${_webview_provider}" \
+ -DJS_PROVIDER="none" \
+ -DSYSTEMD_SUPPORT=ON \
+ -DNO_FILE_ITEM_ACTION_PLUGIN=ON \
+ -DNO_PLASMOID=ON \
+ .
+ ninja
+}
+
+check() {
+ cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
+ SYNCTHING_PORT=$(ephemeral_port) SYNCTHING_TEST_TIMEOUT_FACTOR=3 ninja check
+}
+
+package() {
+ cd "$srcdir/${PROJECT_DIR_NAME:-$_reponame-$pkgver}"
+ DESTDIR="${pkgdir}" ninja install
+}