aboutsummaryrefslogtreecommitdiffstats
path: root/main/fprobe/APKBUILD
blob: 2595e80a7ee48763f867ca4f6a36fb24c08572ef (plain) (blame)
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
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Carlo Landmeter <clandmeter@gmail.com>
pkgname=fprobe
pkgver=1.1
pkgrel=8
pkgdesc="libpcap-based tool that collect network traffic"
url="http://fprobe.sourceforge.net/"
arch="all"
license="GPL"
depends=
makedepends="libpcap-dev"
install=""
subpackages="$pkgname-doc"
source="https://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.bz2
	fprobe-1.1-pidfile-sanity.patch
	fprobe-1.1-setgroups.patch
	$pkgname.initd
	$pkgname.confd"

_builddir="$srcdir"/$pkgname-$pkgver

prepare() {
	cd $_builddir
	update_config_sub || return 1
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	CFLAGS="$CFLAGS -std=gnu89" \
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install

	install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
	install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
}

sha512sums="35fa4bedf2c615093b6637630322115e12f005bc43186b86c55c6bdc76ae5308dd31e1d05632e26e07a30fba88d76b9acc98632bee4f372edcf9df5da3e32210  fprobe-1.1.tar.bz2
429d863547901564abfbd4e9629213f517797a98024c78394f9e89242cf06fba640b3c969e9ef58361a51c2ce0b82e0d79759e92634e31ec51c7016351cb8770  fprobe-1.1-pidfile-sanity.patch
6433b39d6612581b393064385aa206313a2a359d2373fffb64463b748392eb64c69737d4dec55cdfa51a21c1c01f1a123fdddb344cd9faed23c79d64cad00dcb  fprobe-1.1-setgroups.patch
f934b0ffe79e2a9429ff6fe4505e9ee77a4a736765dfba1be29ba79d81535f77c54a01acd360c5ea873fe85ddd7e4fa56cb2db1fc8a48f978d10dc864e4ee14a  fprobe.initd
fd6e7cfc50d3962ab41f0109f87690b50d7b2852d5f613117421747c4451589f625a3a3a4405e20a57c2d56ef8a4c8659942564c02862e8906b5b75f56972bed  fprobe.confd"