From 2c6de483746255cc27d6c2149de04eb9dbe32a98 Mon Sep 17 00:00:00 2001 From: Ravi kumar Veeramally Date: Wed, 16 Mar 2016 13:47:24 +0200 Subject: [PATCH] net: apps: Provide pcap support for echo apps Provide pcap support for echo-apps with PCAP= option. For pcap support: make server NET_IFACE=qemu PCAP=sample.pcap. without pcap support: make server NET_IFACE=qemu Change-Id: Iad90064e0c32134f9c2fda7b28e2cbca1e4e931c Signed-off-by: Ravi kumar Veeramally --- samples/net/common/Makefile.ipstack | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/samples/net/common/Makefile.ipstack b/samples/net/common/Makefile.ipstack index 02f7de4c61b..0e3ce6c297b 100644 --- a/samples/net/common/Makefile.ipstack +++ b/samples/net/common/Makefile.ipstack @@ -83,13 +83,22 @@ ${ZEPHYR_BASE}/net/ip/tools/monitor_15_4: .PHONY: start_monitor start_monitor: ${ZEPHYR_BASE}/net/ip/tools/monitor_15_4 ${ZEPHYR_BASE}/net/ip/tools/monitor_15_4 \ - server-client-monitor.pcap \ + ${PCAP} \ ${PIPE_BASE}-server ${PIPE_BASE}-client > /dev/null & \ echo "$$!" > ${PID_FILE} +ifeq ($(PCAP),) server: remove_pipes setup_pipes $(DOTCONFIG) $(Q)$(call zephyrmake,$(O),qemu); true $(Q)stty sane +else +server: remove_pipes setup_pipes_dual_monitor start_monitor $(DOTCONFIG) + $(Q)$(call zephyrmake,$(O),qemu); true + $(Q)kill `cat ${PID_FILE}` + $(Q)rm -f ${PID_FILE} + -@killall monitor_15_4 > /dev/null 2>&1 ; true + $(Q)stty sane +endif client: $(DOTCONFIG) $(Q)$(call zephyrmake,$(O),qemu); true