From 53194292b0e4d0a0b0a7a6defe59e6e77548bc55 Mon Sep 17 00:00:00 2001 From: Peter Ginchev Date: Fri, 14 Oct 2016 10:23:37 +0300 Subject: [PATCH] Fix test target build Change-Id: Ib06b40292858f32df9c62e747808e0ef140bd9dd Signed-off-by: Peter Ginchev --- Makefile | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 4b7170d27ff..93277beca11 100644 --- a/Makefile +++ b/Makefile @@ -196,18 +196,22 @@ define test V=$(V) TEST=$(TEST) endef -test: +test: bootstrap ifeq ($(OS_ID),ubuntu) - @sudo -E apt-get $(CONFIRM) $(FORCE) install python-dev python-scapy + @if ! (dpkg -l python-dev python-scapy &> /dev/null); then \ + sudo -E apt-get $(CONFIRM) $(FORCE) install python-dev python-scapy; \ + fi endif - @make -C $(BR) PLATFORM=vpp_lite TAG=vpp_lite plugins-install vpp-install vpp-api-test-install + @make -C $(BR) PLATFORM=vpp_lite TAG=vpp_lite vpp-api-install plugins-install vpp-install vpp-api-test-install $(call test,vpp_lite) -test-debug: +test-debug: bootstrap ifeq ($(OS_ID),ubuntu) - @sudo -E apt-get $(CONFIRM) $(FORCE) install python-dev python-scapy + @if ! (dpkg -l python-dev python-scapy &> /dev/null); then \ + sudo -E apt-get $(CONFIRM) $(FORCE) install python-dev python-scapy; \ + fi endif - @make -C $(BR) PLATFORM=vpp_lite TAG=vpp_lite_debug plugins-install vpp-install vpp-api-test-install + @make -C $(BR) PLATFORM=vpp_lite TAG=vpp_lite_debug vpp-api-install plugins-install vpp-install vpp-api-test-install $(call test,vpp_lite_debug) retest: