aboutsummaryrefslogtreecommitdiff
path: root/example
diff options
context:
space:
mode:
authorVitaliy Ivanov <vitaliyi@interfacemasters.com>2018-11-28 16:40:34 +0200
committerVitaliy Ivanov <vitaliyi@interfacemasters.com>2018-11-28 16:40:34 +0200
commitea7e7c753b20bfdb4edd97499362a3a331631e04 (patch)
treee057fc5b262d2b169be6ae690f91fc496283e5da /example
parent5429063546fe8a73adc50e2d6eac4e00046c4424 (diff)
build: correct example dpdk linking with pcap.
- take libpcap from configure information. - clean up distclean. Signed-off-by: Vitaliy Ivanov <vitaliyi@interfacemasters.com>
Diffstat (limited to 'example')
-rw-r--r--example/Makefile.dpdk.in4
-rw-r--r--example/Makefile.in6
2 files changed, 7 insertions, 3 deletions
diff --git a/example/Makefile.dpdk.in b/example/Makefile.dpdk.in
index 8519d7d0e..d96975483 100644
--- a/example/Makefile.dpdk.in
+++ b/example/Makefile.dpdk.in
@@ -14,14 +14,14 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
include $(RTE_SDK)/mk/rte.vars.mk
-APP = ndpiReader
+APP = ndpiReader.dpdk
LIBNDPI = $(PWD)/../src/lib/libndpi.a
SRCS-y := ndpi_util.c ndpiReader.c
CFLAGS += -g
CFLAGS += -Wno-strict-prototypes -Wno-missing-prototypes -Wno-missing-declarations -Wno-unused-parameter -I $(PWD)/../src/include @CFLAGS@ -DUSE_DPDK
-LDLIBS = $(LIBNDPI) -lpthread @LDFLAGS@
+LDLIBS = $(LIBNDPI) @PCAP_LIB@ -lpthread @LDFLAGS@
include $(RTE_SDK)/mk/rte.extapp.mk
diff --git a/example/Makefile.in b/example/Makefile.in
index 3e0f25d91..84f3f3623 100644
--- a/example/Makefile.in
+++ b/example/Makefile.in
@@ -1,7 +1,7 @@
CC=@CC@
CFLAGS=-g -I../src/include @CFLAGS@
LIBNDPI=../src/lib/libndpi.a
-LDFLAGS=$(LIBNDPI) -lpcap -lpthread @LDFLAGS@
+LDFLAGS=$(LIBNDPI) @PCAP_LIB@ -lpthread @LDFLAGS@
OBJS=ndpiReader.o ndpi_util.o
PREFIX?=/usr/local
@@ -21,4 +21,8 @@ dpdk:
clean:
/bin/rm -f *.o ndpiReader
+ /bin/rm -rf build
+distclean: clean
+ /bin/rm -f Makefile.dpdk
+ /bin/rm -f Makefile