summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 47448813cd3d8529baeb681e3798bcb0b252a0f8 (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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
# Maintainer: rilian-la-te <ria.freelander@gmail.com>

_pkgbase=vala-panel-extras
pkgbase=vala-panel-extras-git
pkgname=('vala-panel-extras-battery-git' 'vala-panel-extras-volume-git' 'vala-panel-extras-xkb-git' 'vala-panel-extras-gtop-git' 'vala-panel-extras-weather-git' 'vala-panel-extras-common-git' 'vala-panel-extras-xkb-flags-git')
pkgver=0.1.9
pkgrel=1
pkgdesc="Simple StatusNotifierItems for Indicator plugins"
url="https://gitlab.com/vala-panel-project/vala-panel-extras"
arch=('i686' 'x86_64')
license=('GPL3')
replaces=('vala-panel-extras-meta-git')
makedepends=('meson' 'vala' 'gtk3>=3.12.0' 'libxkbcommon-x11>=0.5.0' 'libxcb>=1.10' 'alsa-lib>=1.0.26' 'libcanberra' 'libgweather>=3.12.0' 'libx11' 'libgtop')
source=("git+https://gitlab.com/vala-panel-project/${_pkgbase}.git")
sha256sums=('SKIP')

pkgver() {
  cd "${srcdir}/${_pkgbase}"
  ( set -o pipefail
    git describe --long --tags 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
  )
}

build() {
  meson build "${srcdir}/${_pkgbase}" --prefix=/usr -Dauto_features=enabled
  meson compile -C build
}

package_vala-panel-extras-volume-git() {
  pkgdesc="Simple volume indicator"
  depends=('gtk3' 'alsa-lib>=1.0.26' 'libcanberra' 'vala-panel-extras-common-git')
  optdepends=('xfce4-sntray-plugin: for showing in Xfce'
            'vala-panel-sntray: for showing in vala-panel'
            'xfce4-snw-plugin: for showing in Xfce, alternate way'
            'enlightenment: for showing in E19'
            'indicator-application: for showing in Indicator Environment, like Pantheon or Unity'
            'plasma-desktop: for showing in KDE Frameworks'
            'kdebase-plasma: for showing in KDE4')
            
  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/"
  rm -fr "$pkgdir/usr/share/locale/"
  rm -rf $pkgdir/usr/bin/vala-panel-extras-{xkb,gtop,weather,battery}
  rm -rf $pkgdir/usr/share/applications/org.valapanel.{xkb,gtop,weather,battery}.desktop
  rm -rf $pkgdir/usr/share/glib-2.0/schemas/org.valapanel.{xkb,gtop,weather,battery}.gschema.xml
}
package_vala-panel-extras-xkb-git() {
  pkgdesc="Simple keyboard layout indicator/switcher"
  depends=('gtk3' 'libxkbcommon-x11>=0.5' 'libxcb>=1.10' 'libx11' 'vala-panel-extras-common-git')
  optdepends=('xfce4-sntray-plugin: for showing in Xfce'
            'vala-panel-sntray: for showing in vala-panel'
            'xfce4-snw-plugin: for showing in Xfce, alternate way'
            'enlightenment: for showing in E19'
            'indicator-application: for showing in Indicator Environment, like Pantheon or Unity'
            'plasma-desktop: for showing in KDE Frameworks'
            'kdebase-plasma: for showing in KDE4'
            'vala-panel-extras-xkb-flags: builtin flags')

  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/"
  rm -fr "$pkgdir/usr/share/locale/"
  rm -rf $pkgdir/usr/bin/vala-panel-extras-{volume,gtop,weather,battery}
  rm -rf $pkgdir/usr/share/applications/org.valapanel.{volume,gtop,weather,battery}.desktop
  rm -rf $pkgdir/usr/share/glib-2.0/schemas/org.valapanel.{volume,gtop,weather,battery}.gschema.xml
}
package_vala-panel-extras-gtop-git() {
  pkgdesc="Simple network speed indicator"
  depends=('gtk3' 'libgtop' 'vala-panel-extras-common-git')
  optdepends=('xfce4-sntray-plugin: for showing in Xfce'
            'vala-panel-sntray: for showing in vala-panel'
            'xfce4-snw-plugin: for showing in Xfce, alternate way'
            'enlightenment: for showing in E19'
            'indicator-application: for showing in Indicator Environment, like Pantheon or Unity'
            'plasma-desktop: for showing in KDE Frameworks'
            'kdebase-plasma: for showing in KDE4')

  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/"
  rm -fr "$pkgdir/usr/share/locale/"
  rm -rf $pkgdir/usr/bin/vala-panel-extras-{xkb,volume,weather,battery}
  rm -rf $pkgdir/usr/share/applications/org.valapanel.{xkb,volume,weather,battery}.desktop
  rm -rf $pkgdir/usr/share/glib-2.0/schemas/org.valapanel.{xkb,volume,weather,battery}.gschema.xml
}
package_vala-panel-extras-weather-git() {
  pkgdesc="Simple weather indicator"
  depends=('gtk3' 'libgweather>=3.12.0' 'vala-panel-extras-common-git')
  optdepends=('xfce4-sntray-plugin: for showing in Xfce'
            'vala-panel-sntray: for showing in vala-panel'
            'xfce4-snw-plugin: for showing in Xfce, alternate way'
            'enlightenment: for showing in E19'
            'indicator-application: for showing in Indicator Environment, like Pantheon or Unity'
            'plasma-desktop: for showing in KDE Frameworks'
            'kdebase-plasma: for showing in KDE4')
  
  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/"
  rm -fr "$pkgdir/usr/share/locale/"
  rm -rf $pkgdir/usr/bin/vala-panel-extras-{xkb,gtop,volume,battery}
  rm -rf $pkgdir/usr/share/applications/org.valapanel.{xkb,gtop,volume,battery}.desktop
  rm -rf $pkgdir/usr/share/glib-2.0/schemas/org.valapanel.{xkb,gtop,volume,battery}.gschema.xml
}
package_vala-panel-extras-xkb-flags-git() {
  arch=('any')
  pkgdesc="Flags for XKB plugin"
  optdepends=('vala-panel-extras-xkb-git')
  
  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/locale/"
  rm -fr "$pkgdir/usr/share/applications/"
  rm -fr "$pkgdir/usr/share/glib-2.0/"
  rm -fr "$pkgdir/usr/bin/"
  rm -fr "$pkgdir/usr/share/vala-panel-extras/doc"
}
package_vala-panel-extras-battery-git() {
  pkgdesc="Simple battery indicator"
  depends=('gtk3' 'upower>=0.99' 'vala-panel-extras-common-git')
  optdepends=('xfce4-sntray-plugin: for showing in Xfce'
            'vala-panel-sntray: for showing in vala-panel'
            'xfce4-snw-plugin: for showing in Xfce, alternate way'
            'enlightenment: for showing in E19'
            'indicator-application: for showing in Indicator Environment, like Pantheon or Unity'
            'plasma-desktop: for showing in KDE Frameworks'
            'kdebase-plasma: for showing in KDE4')
  
  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/"
  rm -fr "$pkgdir/usr/share/locale/"
  rm -rf $pkgdir/usr/bin/vala-panel-extras-{xkb,gtop,weather,volume}
  rm -rf $pkgdir/usr/share/applications/org.valapanel.{xkb,gtop,weather,volume}.desktop
  rm -rf $pkgdir/usr/share/glib-2.0/schemas/org.valapanel.{xkb,gtop,weather,volume}.gschema.xml
}

package_vala-panel-extras-common-git() {
  arch=('any')
  pkgdesc="Common files for vala-panel-extras"
  replaces=('vala-panel-extras-translations-git')
  
  DESTDIR="${pkgdir}" meson install -C build
  rm -fr "$pkgdir/usr/share/vala-panel-extras/xkb"
  rm -fr "$pkgdir/usr/share/applications/"
  rm -fr "$pkgdir/usr/share/glib-2.0/"
  rm -fr "$pkgdir/usr/bin/"
}