summaryrefslogtreecommitdiff
path: root/testing/libpcap/PKGBUILD
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2011-11-04 23:14:51 +0000
committerroot <root@rshg054.dnsready.net>2011-11-04 23:14:51 +0000
commit3026bb55941e3b04b56f5fb41b88941c6c2ce0cd (patch)
tree576b183074d925e58c2e37ae2b641e712bceacb1 /testing/libpcap/PKGBUILD
parentb625511a28fd8401f524474b5339e75328595150 (diff)
Fri Nov 4 23:14:51 UTC 2011
Diffstat (limited to 'testing/libpcap/PKGBUILD')
-rw-r--r--testing/libpcap/PKGBUILD41
1 files changed, 41 insertions, 0 deletions
diff --git a/testing/libpcap/PKGBUILD b/testing/libpcap/PKGBUILD
new file mode 100644
index 000000000..ee36e3354
--- /dev/null
+++ b/testing/libpcap/PKGBUILD
@@ -0,0 +1,41 @@
+# $Id: PKGBUILD 141970 2011-11-03 18:57:47Z thomas $
+# Maintainer: Thomas Bächler <thomas@archlinux.org>
+
+pkgname=libpcap
+pkgver=1.1.1
+pkgrel=4
+pkgdesc="A system-independent interface for user-level packet capture"
+arch=('i686' 'x86_64')
+url="http://www.tcpdump.org/"
+license=('BSD')
+depends=('glibc' 'libnl' 'sh')
+makedepends=('flex')
+source=(http://www.tcpdump.org/release/libpcap-${pkgver}.tar.gz)
+ #Add-support-for-libnl-2.x-adapted-from-a-newer-versi.patch
+ #Libnl-2.x-returns-its-own-error-codes-not-errnos-han.patch)
+sha256sums=('508cca15547e55d1318498b838456a21770c450beb2dc7d7d4a96d90816e5a85')
+ #'194aa268a3397be3ba406b7102dbdbc14fc16c6e4b535d0a0fab6b04d414563a'
+ #'f1f31c3e2b064f4c9d0e643e8ed1874a65ec17f770362f8ffa3b3f9ee9dc71bb')
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ #patch -p1 -i "${srcdir}"/Add-support-for-libnl-2.x-adapted-from-a-newer-versi.patch
+ #patch -p1 -i "${srcdir}"/Libnl-2.x-returns-its-own-error-codes-not-errnos-han.patch
+ ./configure --prefix=/usr --enable-ipv6
+ make
+}
+
+package() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+ install -d -m755 ${pkgdir}/usr/bin
+ make DESTDIR=${pkgdir} install
+ # remove static library
+ rm -rf ${pkgdir}/usr/lib/libpcap.a
+
+ # backwards compatibility, programs often look for net/bpf.h
+ mkdir -p ${pkgdir}/usr/include/net
+ cd ${pkgdir}/usr/include/net
+ ln -s ../pcap-bpf.h bpf.h
+
+ #install the license
+ install -D -m644 ${srcdir}/$pkgname-$pkgver/LICENSE ${pkgdir}/usr/share/licenses/$pkgname/LICENSE
+}