blob: be8e37318b90e9f98fdc27728caa43c5f35956a7 (
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
|
# Contributor: Stefan Wagner <stw@bit-strickerei.de>
# Maintainer: Stefan Wagner <stw@bit-strickerei.de>
pkgname=influxdb
pkgver=1.5.4
pkgrel=0
pkgdesc="Scalable datastore for metrics, events, and real-time analytics"
url="https://www.influxdata.com/time-series-platform/influxdb/"
arch="all !aarch64"
license="MIT"
makedepends="go go-gdm python2 asciidoc xmlto"
pkgusers="influxdb"
pkggroups="influxdb"
install="$pkgname.pre-install"
options="!check" # has not tests
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/influxdata/$pkgname/archive/v$pkgver.tar.gz
influxdb.initd
influxdb.logrotate
"
builddir="$srcdir/src/github.com/influxdata/$pkgname"
prepare() {
mkdir -p ${builddir%/*}
mv "$srcdir"/$pkgname-$pkgver "$builddir"/ || return 1
export GOPATH="$srcdir"
cd "$builddir"
gdm restore
default_prepare
}
build() {
export GOPATH="$srcdir"
cd "$builddir"
local path
for path in $(find ./cmd/* -maxdepth 0 -type d); do
go build -v -work -x -ldflags="-X main.version=$pkgver" \
-o ./bin/${path##*/} $path
done
make -C man
}
package() {
cd "$builddir"
local path bindir
for path in $(find ./cmd/* -maxdepth 0 -type d); do
case "${path##*/}" in
influxd) bindir=sbin ;;
*) bindir=bin ;;
esac
install -Dm755 ./bin/"${path##*/}" "$pkgdir"/usr/$bindir/"${path##*/}"
done
install -d "$pkgdir/usr/share/man/man1/"
install -Dm644 man/*.1 "$pkgdir/usr/share/man/man1/"
install -Dm644 "etc/config.sample.toml" "$pkgdir/etc/influxdb/influxdb.conf"
install -Dm755 "$srcdir/$pkgname.initd" "$pkgdir/etc/init.d/$pkgname"
install -Dm644 "$srcdir/$pkgname.logrotate" "$pkgdir/etc/logrotate.d/$pkgname"
}
sha512sums="b4dc1985d88cb3fb16babbb3d71ca7c4087d2add8f9b0a74c99b9e4543b63718595b1d5a0a39451ed81c3e5e51e70d06e2be00468acb7f32cbb321f4e9337f1f influxdb-1.5.4.tar.gz
55d5776fde330001f254fed4b01163d576d1995c23b08ef64c3c33b7a53fa49c71092867a17149d3148af7a8e17dc4779481afe9dd54a86eeee16168dbb964e0 influxdb.initd
5d754e3aeec912bae8f5bf2f84153d4ccc82918d9c728631e8b9ad6737fab3352af0ab63f46ac80aab6384d779bae5d321da0465f26fd8798a9694f7d79f879d influxdb.logrotate"
|