summaryrefslogtreecommitdiff
path: root/extra/tcpdump/PKGBUILD
blob: 3e9865440bda2318e05041d1d354dede3f67ac44 (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
# $Id: PKGBUILD 144370 2011-12-05 12:08:20Z giovanni $
# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
# Contributor: dorphell <dorphell@archlinux.org>

pkgname=tcpdump
pkgver=4.2.0
pkgrel=1
pkgdesc="A tool for network monitoring and data acquisition"
arch=('i686' 'x86_64')
url="http://www.tcpdump.org"
license=('BSD')
depends=('libpcap' 'openssl')
source=("http://www.tcpdump.org/release/${pkgname}-${pkgver}.tar.gz"
        'tcpdump_duplicate_executable.patch'
        'ppi.h')
md5sums=('0296d4c487c3a156879783643704bd39'
         'b45c978dff8193ff5529d3566e7dbfa3'
         'd898c868bb730e14dbd2afd1ad883b87')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  
  # Add missing header file
  cp ${srcdir}/ppi.h .

  # do not install tcpdump-4.1.1 executable (FS#23346)
  patch -Np1 -i "${srcdir}/tcpdump_duplicate_executable.patch"

  ./configure --prefix=/usr \
              --enable-ipv6
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  make DESTDIR="${pkgdir}" install

  #install the license
  install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}