aboutsummaryrefslogtreecommitdiffstats
path: root/test/ext/Makefile
diff options
context:
space:
mode:
authorSirshak Das <sirshak.das@arm.com>2018-05-18 13:14:52 -0500
committerDamjan Marion <dmarion.lists@gmail.com>2018-05-27 10:53:49 +0000
commit41141d505ee3706a610c5345bbf1c91ea7ba9900 (patch)
tree07ab470aeb71f1c144cd01268aebc8587201892c /test/ext/Makefile
parent5e5adb310c5ac19209d3d9fb03094c01b2a29610 (diff)
Fixes make test errors with clang compiler on aarch64
(VAPI_*BIN).d targets didnt have fake.api.vapi.h* as dependencies this causes the compilation to proceed before the python script generates the header files. Explicit linking of stdc++ is required for clang as errors like undefined reference to 'new operator' pop up. Change-Id: I3ca0ef048f392c4a032160ce0e4f7ae759f4c79d Signed-off-by: Sirshak Das <sirshak.das@arm.com> Reviewed-by: Brian Brooks <brian.brooks@arm.com> Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Diffstat (limited to 'test/ext/Makefile')
-rw-r--r--test/ext/Makefile6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/ext/Makefile b/test/ext/Makefile
index 631d7ffe811..a66a72c35dc 100644
--- a/test/ext/Makefile
+++ b/test/ext/Makefile
@@ -16,7 +16,7 @@ ifneq ($(filter centos opensuse opensuse-tumbleweed opensuse-leap,$(OS_ID)),$(OS
VAPI_LIBS += -lsubunit
endif
-FLAGS = -g -Wall -pthread -I$(WS_ROOT)/src -I$(VPP_TEST_INSTALL_PATH)/vpp/include -I$(VAPI_BINDIR)
+FLAGS = -g -Wall -lstdc++ -pthread -I$(WS_ROOT)/src -I$(VPP_TEST_INSTALL_PATH)/vpp/include -I$(VAPI_BINDIR)
CFLAGS = -std=gnu99 $(FLAGS)
CPPFLAGS = -std=c++11 $(FLAGS) -I$(WS_ROOT)/extras/vom
@@ -36,7 +36,7 @@ $(VAPI_BINDIR)/fake.api.vapi.hpp: fake.api.json $(WS_ROOT)/src/vpp-api/vapi/vapi
$(VAPI_CBIN): $(CSRC) $(VAPI_BINDIR)/fake.api.vapi.h
$(CC) -o $@ $(CFLAGS) $(CSRC) $(VAPI_LIBS)
-$(VAPI_CBIN).d: $(CSRC) $(VAPI_BINDIR)
+$(VAPI_CBIN).d: $(CSRC) $(VAPI_BINDIR)/fake.api.vapi.h
$(CC) -o $@ $(CFLAGS) -MM -MT '$(VAPI_CBIN)' $(CSRC) > $@
@@ -45,7 +45,7 @@ CPPSRC = vapi_cpp_test.cpp
$(VAPI_CPPBIN): $(CPPSRC) $(VAPI_BINDIR)/fake.api.vapi.hpp
$(CXX) -o $@ $(CPPFLAGS) $(CPPSRC) $(VAPI_LIBS)
-$(VAPI_CPPBIN).d: $(CPPSRC) $(VAPI_BINDIR)
+$(VAPI_CPPBIN).d: $(CPPSRC) $(VAPI_BINDIR)/fake.api.vapi.hpp
$(CXX) -o $@ $(CPPFLAGS) -MM -MT '$(VAPI_CPPBIN)' $(CPPSRC) > $@
VOM_CPPSRC = vom_test.cpp