aboutsummaryrefslogtreecommitdiff
path: root/net/ndpi
diff options
context:
space:
mode:
authorGuido Falsi <madpilot@FreeBSD.org>2017-12-09 17:11:09 +0000
committerGuido Falsi <madpilot@FreeBSD.org>2017-12-09 17:11:09 +0000
commit13bb6f87c0029521142150baf5a28b3cd58fea6a (patch)
treed11ada346efd08ad51f5e6b3d9ef8c37dea4d105 /net/ndpi
parent881aa7cedb1684f35387f9835abd961ebb417b01 (diff)
downloadports-13bb6f87c0029521142150baf5a28b3cd58fea6a.tar.gz
ports-13bb6f87c0029521142150baf5a28b3cd58fea6a.zip
Notes
Diffstat (limited to 'net/ndpi')
-rw-r--r--net/ndpi/Makefile9
-rw-r--r--net/ndpi/distinfo6
-rw-r--r--net/ndpi/files/patch-autogen.sh37
-rw-r--r--net/ndpi/files/patch-fix-libcache.h50
-rw-r--r--net/ndpi/files/patch-libndpi.sym10
-rw-r--r--net/ndpi/pkg-plist1
6 files changed, 107 insertions, 6 deletions
diff --git a/net/ndpi/Makefile b/net/ndpi/Makefile
index fb2bd034113e..3632e93740df 100644
--- a/net/ndpi/Makefile
+++ b/net/ndpi/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= ndpi
-PORTVERSION= 2.0.2017.09.13
+PORTVERSION= 2.2.2017.12.05
CATEGORIES= net
MAINTAINER= madpilot@FreeBSD.org
@@ -13,20 +13,23 @@ LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libjson-c.so:devel/json-c
+USES= autoreconf compiler:c++11-lang libtool pathfix pkgconfig
CONFIGURE_ARGS= --with-pic
CPPFLAGS+= -I${LOCALBASE}/include/json-c
LDFLAGS+= -L${LOCALBASE}/lib
LIBS+= -ljson-c
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
-USES= autoreconf compiler:c++11-lang libtool pathfix pkgconfig
INSTALL_TARGET= install-strip
USE_GITHUB= yes
GH_ACCOUNT= ntop
GH_PROJECT= nDPI
-GH_TAGNAME= 6607c33
+GH_TAGNAME= 56dcf65
PLIST_SUB= MAJOR_VER=${PORTVERSION:C/([[:digit:]])+\.([[:digit:]])+.*/\1.\2/}.0
+post-patch:
+ cd ${WRKSRC} && ${SH} autogen.sh
+
.include <bsd.port.mk>
diff --git a/net/ndpi/distinfo b/net/ndpi/distinfo
index b8b74a7f5c0f..9dbc51ca5729 100644
--- a/net/ndpi/distinfo
+++ b/net/ndpi/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1507108385
-SHA256 (ntop-nDPI-2.0.2017.09.13-6607c33_GH0.tar.gz) = 3a71b7b8e20e387afdfca36052e553a98826a0bb345d9cff58b9bffb5649db11
-SIZE (ntop-nDPI-2.0.2017.09.13-6607c33_GH0.tar.gz) = 19281054
+TIMESTAMP = 1512577740
+SHA256 (ntop-nDPI-2.2.2017.12.05-56dcf65_GH0.tar.gz) = 8accd15275879465210cd9e706562918f0b0c4c65b5659037ae28e48e46a858f
+SIZE (ntop-nDPI-2.2.2017.12.05-56dcf65_GH0.tar.gz) = 19937661
diff --git a/net/ndpi/files/patch-autogen.sh b/net/ndpi/files/patch-autogen.sh
new file mode 100644
index 000000000000..8de12e2b9764
--- /dev/null
+++ b/net/ndpi/files/patch-autogen.sh
@@ -0,0 +1,37 @@
+--- autogen.sh.orig 2017-12-03 18:07:29 UTC
++++ autogen.sh
+@@ -5,34 +5,4 @@ NDPI_MINOR="2"
+ NDPI_PATCH="0"
+ NDPI_VERSION_SHORT="$NDPI_MAJOR.$NDPI_MINOR.$NDPI_PATCH"
+
+-/bin/rm -f configure config.h config.h.in src/lib/Makefile.in
+-
+-AUTOCONF=$(which autoconf)
+-AUTOMAKE=$(which automake)
+-LIBTOOL=$(which libtool)
+-LIBTOOLIZE=$(which libtoolize)
+-AUTORECONF=$(which autoreconf)
+-
+-if test -z $AUTOCONF; then
+- echo "autoconf is missing: please install it and try again"
+- exit
+-fi
+-
+-if test -z $AUTOMAKE; then
+- echo "automake is missing: please install it and try again"
+- exit
+-fi
+-
+-if test -z $LIBTOOL && test -z $LIBTOOLIZE ; then
+- echo "libtool and libtoolize is missing: please install it and try again"
+- exit
+-fi
+-
+-if test -z $AUTORECONF; then
+- echo "autoreconf is missing: please install it and try again"
+- exit
+-fi
+-
+ cat configure.seed | sed "s/@NDPI_MAJOR@/$NDPI_MAJOR/g" | sed "s/@NDPI_MINOR@/$NDPI_MINOR/g" | sed "s/@NDPI_PATCH@/$NDPI_PATCH/g" | sed "s/@NDPI_VERSION_SHORT@/$NDPI_VERSION_SHORT/g" > configure.ac
+-autoreconf -ivf
+-./configure $*
diff --git a/net/ndpi/files/patch-fix-libcache.h b/net/ndpi/files/patch-fix-libcache.h
new file mode 100644
index 000000000000..b20bb618ff91
--- /dev/null
+++ b/net/ndpi/files/patch-fix-libcache.h
@@ -0,0 +1,50 @@
+From 2155dd9153457886c4f5dac58dcf269eeb2a8122 Mon Sep 17 00:00:00 2001
+From: Hidde van der Heide <hvanderheide@nexuz.net>
+Date: Thu, 19 Oct 2017 16:10:56 +0200
+Subject: [PATCH] Add libcache to installed headers and removed relative import
+
+---
+ example/Makefile.am | 2 +-
+ src/include/ndpi_typedefs.h | 2 +-
+ src/lib/Makefile.am | 3 ++-
+ 3 files changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/example/Makefile.am b/example/Makefile.am
+index 7fc29402..6cc6a14c 100644
+--- example/Makefile.am
++++ example/Makefile.am
+@@ -1,6 +1,6 @@
+ bin_PROGRAMS = ndpiReader
+
+-AM_CPPFLAGS = -I$(top_srcdir)/src/include @PCAP_INC@
++AM_CPPFLAGS = -I$(top_srcdir)/src/include -I$(top_srcdir)/src/lib/third_party/include @PCAP_INC@
+ AM_CFLAGS = @PTHREAD_CFLAGS@ # --coverage
+
+ LDADD = $(top_builddir)/src/lib/libndpi.la @JSON_C_LIB@ @PTHREAD_LIBS@ @PCAP_LIB@ @DL_LIB@ -lm
+diff --git a/src/include/ndpi_typedefs.h b/src/include/ndpi_typedefs.h
+index 33043fde..0587503f 100644
+--- src/include/ndpi_typedefs.h
++++ src/include/ndpi_typedefs.h
+@@ -25,7 +25,7 @@
+ #define __NDPI_TYPEDEFS_H__
+
+ #include "ndpi_define.h"
+-#include "../lib/third_party/include/libcache.h"
++#include "libcache.h"
+
+ #define BT_ANNOUNCE
+ #define SNAP_EXT
+diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am
+index c2b4e4b1..39823d37 100644
+--- src/lib/Makefile.am
++++ src/lib/Makefile.am
+@@ -12,7 +12,8 @@ libndpi_la_include_HEADERS = ../include/ndpi_api.h \
+ ../include/ndpi_includes.h \
+ ../include/ndpi_protocol_ids.h \
+ ../include/ndpi_protocols.h \
+- ../include/ndpi_typedefs.h
++ ../include/ndpi_typedefs.h \
++ third_party/include/libcache.h
+
+ libndpi_la_SOURCES = ndpi_content_match.c.inc \
+ ndpi_main.c \
diff --git a/net/ndpi/files/patch-libndpi.sym b/net/ndpi/files/patch-libndpi.sym
new file mode 100644
index 000000000000..2de245e03934
--- /dev/null
+++ b/net/ndpi/files/patch-libndpi.sym
@@ -0,0 +1,10 @@
+--- libndpi.sym.orig 2017-12-03 18:07:29 UTC
++++ libndpi.sym
+@@ -58,4 +58,5 @@ ndpi_netbios_name_interpret
+ ndpi_category_set_name
+ ndpi_category_get_name
+ ndpi_is_custom_category
+-ndpi_is_subprotocol_informative
+\ No newline at end of file
++ndpi_is_subprotocol_informative
++ndpi_set_proto_category
diff --git a/net/ndpi/pkg-plist b/net/ndpi/pkg-plist
index 8c77ef70621c..7a97d130f1e3 100644
--- a/net/ndpi/pkg-plist
+++ b/net/ndpi/pkg-plist
@@ -1,4 +1,5 @@
bin/ndpiReader
+include/libndpi-%%MAJOR_VER%%/libndpi/libcache.h
include/libndpi-%%MAJOR_VER%%/libndpi/ndpi_api.h
include/libndpi-%%MAJOR_VER%%/libndpi/ndpi_define.h
include/libndpi-%%MAJOR_VER%%/libndpi/ndpi_includes.h