aboutsummaryrefslogtreecommitdiffstats
path: root/main/fstrm/APKBUILD
blob: ae5dcc251bbd1dddf1d426bc1711c9317e012313 (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
# Contributor: tcely <tcely@users.noreply.github.com>
# Maintainer:
pkgname="fstrm"
pkgver="0.6.0"
pkgrel=0
pkgdesc="Frame Streams implementation in C"
url="https://github.com/farsightsec/fstrm"
arch="all"
# check failure on s390x reported upstream:
#    https://github.com/farsightsec/fstrm/issues/58
license="MIT"
checkdepends="findutils"
makedepends="libevent-dev"
subpackages="$pkgname-static $pkgname-dev $pkgname-doc $pkgname-utils"
source="https://dl.farsightsecurity.com/dist/fstrm/fstrm-$pkgver.tar.gz
	reduce-testruns.patch"

build() {
	cd "$builddir"

	./configure \
		--build="$CBUILD" \
		--host="$CHOST" \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man
	make
}

_cat_found_file() {
	local _rc="$?"
	find -name "$1" -type f -ls -printf '%P {{{\n' -exec cat -v -n '{}' ';' -printf '}}} %P\n'
	return "$_rc"
}

check() {
	cd "$builddir"

	make check || _cat_found_file 'test-suite.log'
}

package() {
	cd "$builddir"

	make -j1 DESTDIR="$pkgdir" install
}

utils() {
	pkgdesc="$pkgname utilities"
	mkdir -p "$subpkgdir"/usr/bin
	mv "$pkgdir"/usr/bin/* "$subpkgdir"/usr/bin/
}

sha512sums="d1b754caadb1bd8b4b4ce3e7394168dd0a20353e0b7ac65f28d016d840aefe6fa1ab1aa778564e775152164855b38a47ab5817866f8bfb0b2d70520b2881225d  fstrm-0.6.0.tar.gz
1c687ee7741fb20a571c3d7d3fb9a1cf09709d83d66d788eb09835750ee2313aa565f74d35a9cdece2154e1b8c41c68b268ca8f5bc33f8d14550ebe46880d550  reduce-testruns.patch"