summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 0b381b76fd1a90a7a1b0bc6697842e7a63f2b209 (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
# Maintainer: robertfoster

pkgname=ndpi-git
pkgver=1057.6e62367
pkgrel=1
pkgdesc="Open and Extensible GPLv3 Deep Packet Inspection Library"
arch=('i686' 'x86_64')
url="http://www.ntop.org/products/ndpi/"
license=('GPL3')
provides=('ndpi')
conflicts=('ndpi')
source=('ndpi::git+https://github.com/ntop/nDPI.git')
makedepends=('git')

pkgver() {
  cd ndpi
  echo $(git rev-list --count dev).$(git rev-parse --short dev)
}

build() {                                                                                                                                                                    
   cd ndpi
   ./autogen.sh
   ./configure --prefix=/usr --with-pic --includedir=/usr/include --libdir=/usr/lib
   make
}
 package() {
   cd ndpi
   make DESTDIR="${pkgdir}/" install
   mv $pkgdir/usr/include/libndpi-*/libndpi $pkgdir/usr/include
   rm -r $pkgdir/usr/include/libndpi-*
   sed -i 's|\/libndpi-2.*.*||g' $pkgdir/usr/lib/pkgconfig/libndpi.pc
   sed -i 's=#include "../lib/third_party/include/libcache.h"=#include "libcache.h"=' $pkgdir/usr/include/libndpi/ndpi_typedefs.h
   cp -p src/lib/third_party/include/libcache.h $pkgdir/usr/include/libndpi
}

md5sums=('SKIP')