blob: 3287325e358b43041a9f365fcd70ca2cf23ce95f (
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: buckket <felix@buckket.org>
_pkgname=zigbee2mqtt
pkgname=zigbee2mqtt-git
pkgver=1.17.1.r0.g99274c72
pkgrel=1
pkgdesc='A Zigbee to MQTT bridge'
arch=('x86_64' 'arm' 'armv6h' 'armv7h' 'aarch64')
url='https://www.zigbee2mqtt.io'
license=('GPL3')
depends=('nodejs>=10.0')
conflicts=('zigbee2mqtt')
provides=('zigbee2mqtt')
makedepends=('git' 'npm')
optdepends=(
'cc-tool: To flash Texas Instruments CC2531 debugger'
'mosquitto: MQTT broker')
source=(
'zigbee2mqtt::git+https://github.com/Koenkk/zigbee2mqtt.git'
'zigbee2mqtt.service'
'zigbee2mqtt.sysusers'
'zigbee2mqtt.tmpfiles')
sha256sums=('SKIP'
'36fdca9c274fc143a85cc57d70a36e0ec9455cf86b85d0690ccf0090ee8d682d'
'3a86716e9036e97d885e9b5f37c7f87d9c2872435e4acf9fc4c9157264cf387b'
'8f0fbe06c8d6e8fdf37feb31f244930025d76785451f9049fd90fe6e23c259f6')
backup=('etc/zigbee2mqtt/configuration.yaml')
install='zigbee2mqtt.install'
options=('!strip')
pkgver() {
cd "${_pkgname}"
git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/v//'
}
package() {
cd "${_pkgname}"
npm install -g --user root --prefix "${pkgdir}/usr" --cache "${srcdir}/npm-cache"
find "${pkgdir}/usr" -type d -exec chmod 755 {} +
chown -R root:root "${pkgdir}"
find "${pkgdir}" -name package.json -print0 | xargs -r -0 sed -i '/_where/d'
install -Dm644 data/configuration.yaml "${pkgdir}/etc/${_pkgname}/configuration.yaml"
install -Dm644 "${srcdir}/${_pkgname}.service" "${pkgdir}/usr/lib/systemd/system/${_pkgname}.service"
install -Dm644 "${srcdir}/${_pkgname}.sysusers" "${pkgdir}/usr/lib/sysusers.d/${_pkgname}.conf"
install -Dm644 "${srcdir}/${_pkgname}.tmpfiles" "${pkgdir}/usr/lib/tmpfiles.d/${_pkgname}.conf"
}
|