aboutsummaryrefslogtreecommitdiffstats
path: root/main/daq/APKBUILD
blob: a7b625be728b6093953c9c3a41bf309cebf2381e (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
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=daq
pkgver=2.0.6
pkgrel=0
pkgdesc="Data Acquisition library - packet I/O library"
url="http://www.snort.org/"
arch="all"
license="GPL2"
depends=
makedepends="libpcap-dev flex bison"
install=""
subpackages="$pkgname-dev"
source="https://www.snort.org/downloads/snort/daq-$pkgver.tar.gz
	fix-includes.patch
	"

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

build() {
	cd "$_builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--localstatedir=/var \
		|| return 1
	# work around parallel build issue
	make -C sfbpf tokdefs.h
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
}

md5sums="2cd6da422a72c129c685fc4bb848c24c  daq-2.0.6.tar.gz
1811f7de59d1d05937b87e5415174f8d  fix-includes.patch"
sha256sums="b40e1d1273e08aaeaa86e69d4f28d535b7e53bdb3898adf539266b63137be7cb  daq-2.0.6.tar.gz
3a4d835a53561ac07df0c8ad0d2741f4820b159df261fb3c686e01e1a04c4219  fix-includes.patch"
sha512sums="65d779651e6b193309159113f620dc843be4b5e142455a3b530b88ce7ca12c318935affa45f54e56427c9d5eb1239a47dc7a323325ccb394d1a888619c580f9e  daq-2.0.6.tar.gz
ea769608e4b6ebfd186a5e637a1dbf16f300c5c40501655b891fdc0095879f65927d90872d4953a4a4e32ccc40306b19a1a1e7ae4dd8b3f7572db97aea48390e  fix-includes.patch"