summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 81b5ffdd41645a54c9d5e76d75839d9a8a7c7ada (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Maintainer: Chih-Hsuan Yen <yan12125@archlinux.org>
# Contributor: xduugu
# Contributor: MrSerenity
# Contributor: derlafff (aur@2-47.ru)
# Contributor: Doron Behar <doron.behar@gmail.com>

pkgname=qsyncthingtray-lite
_pkgname=QSyncthingTray
pkgver=0.5.8.r17.g11936bc
_commit=11936bc01b849cec3d0dfc82ad83521c20f3686f
pkgrel=3
pkgdesc="tray app for syncthing - without the default embedded web interface"
arch=('i686' 'x86_64')
url="https://github.com/sieren/QSyncthingTray"
license=('LGPL3')
depends=('qt5-base' 'syncthing')
provides=("qsyncthingtray=$pkgver")
conflicts=('qsyncthingtray')
makedepends=('cmake' 'git')
source=("git+https://github.com/sieren/$_pkgname#commit=$_commit"
        "$pkgname.desktop")
sha256sums=('SKIP'
            '36227ff042cd290c5a5165e63aefa759b08524d508fb5d81558ea2e88f7c731d')

pkgver() {
  cd $_pkgname
  ( set -o pipefail
    git describe --long --tag 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/^v//'
  )
}

prepare() {
  cd $_pkgname
  mkdir build
}

build() {
  cd $_pkgname/build
  cmake -DQST_BUILD_NATIVEBROWSER=1 ..
  make
}

package() {
  cd $_pkgname
  install -Dm755 "build/$_pkgname" "$pkgdir/usr/bin/$_pkgname"

  # install .desktop file
  install -Dm644 "$srcdir/$pkgname.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
  install -Dm644 "resources/images/Icon1024.png" "$pkgdir/usr/share/pixmaps/qsyncthingtray.png"
}