summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a8b50aecd79152a850b88564a8425c94656f3f83 (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
51
52
53
54
55
56
57
58
59
60
# Maintainer:

_pkgname="pamac-tray-plasma"
pkgname="$_pkgname-git"
pkgver=r21.58353a1
pkgrel=1
pkgdesc="Pamac tray icon for Plasma"
url="https://gitlab.com/LordTermor/pamac-tray-icon-plasma"
license=('Unknown')
arch=('x86_64')

depends=(
  'knotifications'
  'kstatusnotifieritem'
  'libpamac'
  'qt6-base'
)
makedepends=(
  'cmake'
  'ninja'
)

provides=(
  "$_pkgname"
  'pamac-tray-icon-plasma'
)
conflicts=(
  "$_pkgname"
  'pamac-tray-icon-plasma'
)

_pkgsrc="$_pkgname"
source=("$_pkgsrc"::"git+$url.git")
sha256sums=('SKIP')

pkgver() {
  cd "$_pkgsrc"
  printf "r%s.%s" \
    "$(git rev-list --count HEAD)" \
    "$(git rev-parse --short=7 HEAD)"
}

build() {
  local _cmake_options=(
    -B build
    -S "$_pkgsrc"
    -G Ninja
    -DCMAKE_BUILD_TYPE=None
    -DCMAKE_INSTALL_PREFIX='/usr'
    -DBUILD_TESTING=OFF
    -Wno-dev
  )

  cmake "${_cmake_options[@]}"
  cmake --build build
}

package() {
  DESTDIR="$pkgdir" cmake --install build
}