summaryrefslogtreecommitdiffstats
path: root/main/arpwatch/APKBUILD
blob: 662d958059f2a4a0baba42cb1ece9b53fea84f32 (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
# Contributor: Michael Mason <ms13sp@gmail.com> 
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=arpwatch
pkgver=2.1a15
pkgrel=5
pkgdesc="Ethernet monitoring program"
url="http://www-nrg.ee.lbl.gov/"
arch="all"
license="GPL"
depends=
makedepends="libpcap-dev"
install=
subpackages=""
source="ftp://ftp.ee.lbl.gov/$pkgname.tar.gz
	arpwatch.confd
	arpwatch.initd"

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

build() {
	cd "$srcdir/$pkgname-$pkgver"

	./configure --prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info
	make -j1 || return 1
}

package() {
	cd "$srcdir/$pkgname-$pkgver"
	#install command wouldn't create directory ? 
	mkdir -p "$pkgdir"/usr/sbin/
	make -j1 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

}

md5sums="cebfeb99c4a7c2a6cee2564770415fe7  arpwatch.tar.gz
dc8300ce5f02d6be95899a2982397064  arpwatch.confd
51ecada198c4f954ac4d5f5903198ebb  arpwatch.initd"