blob: 06cfa18216d740fad3e184955910d33aaa6e0510 (
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
|
pkgname=netdiscover
pkgver=0.10
pkgrel=0
pkgdesc="ARP Scanner"
arch=('i686' 'x86_64')
url="https://github.com/netdiscover-scanner/netdiscover/"
license=('GPL')
depends=('libnet' 'libpcap')
makedepends=('gcc' 'make' 'wget')
provides=('netdiscover')
conflicts=('netdiscover-debian' 'netdiscover-svn')
source=("https://github.com/netdiscover-scanner/netdiscover/archive/${pkgver}.tar.gz"
"http://standards-oui.ieee.org/oui/oui.txt")
sha256sums=('dc331da2052ef1b0e8de50b8550c63f1e10720101df8f075efe6adeb2dad4afd'
'SKIP')
prepare(){
cd "$srcdir/$pkgname-$pkgver"
cat << EOT > src/oui.h
struct oui {
char *prefix; /* 24 bit global prefix */
char *vendor; /* Vendor id string */
};
struct oui oui_table[] = {
EOT
cat ../oui.txt | sed 's/\r//' | grep "base 16" | tr '\t' ' ' | tr -s " " | sed 's/(base 16) //' | grep '[0-9A-F]' | sort | sed 's/ /", "/' | sed 's/^/ { "/' | sed -z 's/\n/" },#/g' | tr '#' '\n' >> src/oui.h
cat << EOT >> src/oui.h
{ NULL, NULL }
};
EOT
}
build() {
cd "$srcdir/$pkgname-$pkgver"
./autogen.sh
./configure --sbindir=/usr/bin --prefix=/usr --sysconfdir=/etc/
make
}
package() {
cd "$srcdir/$pkgname-$pkgver"
make DESTDIR="$pkgdir" install || return 1
}
|