aboutsummaryrefslogtreecommitdiffstats
path: root/main/libpcap/APKBUILD
blob: 135019a7e059f024d3ba7995dd87a22d0e709ec1 (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libpcap
pkgver=1.3.0
_sover=1.0.0
pkgrel=0
pkgdesc="A system-independent interface for user-level packet capture"
url="http://www.tcpdump.org/"
arch="all"
license="BSD"
depends=
makedepends="bison flex autoconf"
source="http://www.tcpdump.org/release/$pkgname-$pkgver.tar.gz
	"
subpackages="$pkgname-doc $pkgname-dev"

_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
	cd "$_builddir"
	for i in "$srcdir"/*.patch; do
		[ -r "$i" ] || continue
		msg "Applying $i..."
		patch -p1 -i $i || return 1
	done
}

build() {
	cd "$_builddir"
	./configure --prefix=/usr --enable-ipv6 || return 1
	# seems to be problem with timestamps
	sleep 1
	./config.status
	make all shared || return 1
}

package() {
	cd "$_builddir"
	mkdir -p "$pkgdir/usr/bin"
	make -j1 DESTDIR="$pkgdir" install install-shared
}
md5sums="f78455a92622b7a3c05c58b6ad1cec7e  libpcap-1.3.0.tar.gz"