blob: 469031575723a990aa12bde542aa9b9fd13587ba (
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
|
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=nfdump
pkgver=1.6.18
pkgrel=0
pkgdesc="Tools to collect and process netflow data"
url="https://github.com/phaag/nfdump"
arch="all"
license="BSD-3-Clause"
makedepends="autoconf automake bison bzip2-dev flex libtool rrdtool-dev"
subpackages="
$pkgname-doc
$pkgname-dbg
$pkgname-openrc
$pkgname-static
nfprofile
sfcapd
sfcapd-openrc
"
source="$pkgname-$pkgver.tar.gz::https://github.com/phaag/nfdump/archive/v$pkgver.tar.gz
nfcapd.confd
nfcapd.initd
sfcapd.confd
sfcapd.initd
"
prepare() {
default_prepare
./autogen.sh
}
build() {
cd "$builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--enable-nfprofile \
--enable-sflow \
--enable-shared
make
}
package() {
cd "$builddir"
make DESTDIR="$pkgdir" install
install -D -m755 "$srcdir"/nfcapd.initd \
"$pkgdir"/etc/init.d/nfcapd
install -D -m644 "$srcdir"/nfcapd.confd \
"$pkgdir"/etc/conf.d/nfcapd
}
nfprofile() {
pkgdesc="Create views of the data with NFdump filters"
depends="nfdump"
cd "$builddir"
mkdir -p "$subpkgdir"/usr/bin
mv "$pkgdir"/usr/bin/nfprofile "$subpkgdir"/usr/bin
}
sfcapd() {
pkgdesc="sFlow collector"
cd "$builddir"
mkdir -p "$subpkgdir"/usr/bin
mv "$pkgdir"/usr/bin/sfcapd "$subpkgdir"/usr/bin
# Install to pkgdir so it is later caught by sfcapd-openrc
install -D -m644 "$srcdir"/sfcapd.confd \
"$pkgdir"/etc/conf.d/sfcapd
install -D -m755 "$srcdir"/sfcapd.initd \
"$pkgdir"/etc/init.d/sfcapd
}
sha512sums="b975c84f8b304db771ed6106ae1ab27cf23f88aff2d78f2da7e4ff1dc263da3a287bf0cd315ba26b2dd47aaaed9ea0acc3245413153e26546786aa0178d3fee6 nfdump-1.6.18.tar.gz
fcb467f819f2b73ac0e13de6de4d6c94cafd3866a7a56685d5d4a048fa975135299655e896ff8370c8c5061d03ab38644623f8be455c08dfe5f630f152820148 nfcapd.confd
97e432e884dd1cc8f27c2d7398bb0320164d46dea06c64ad72fa385d190998b3d62356634962f42652daf6e31f237baa2f3f3efad47c3fc38cc6bea799db61cc nfcapd.initd
abe594a95a9320bec1d6ee6af6b75cd4d176526d4b10d07aa7ed79fc292b51c341339ba8e1e468df9ec2aae138b1dd66e3a291921938217835ac33819da9d153 sfcapd.confd
7a65c80186a8708a27e90a7239d1b44ee919c3bbf8cd1ca07ef5d35a623d0dce5eac516b65ba7a98c5fcfab5bad6c15e1f03af38a06eb6280afd1c1f0f52cee4 sfcapd.initd"
|