Hello Dave,

I noticed that you are maintainer of VPP API TEST (VAT),  could you help me 
about this issue ?

Best Regards
Yulong Pei

From: vpp-dev@lists.fd.io <vpp-dev@lists.fd.io> On Behalf Of Pei, Yulong
Sent: Tuesday, December 31, 2019 5:47 PM
To: vpp-dev@lists.fd.io
Subject: [vpp-dev] why VAT can not link libvnet.so library ?

Dear VPP-dev,

I  bumped into an issue as below  since I called  ip_address_encode() function 
in  src/plugins/lb/lb_test.c

./vpp_api_test: symbol lookup error: 
/root/vpp/build-root/build-vpp-native/vpp/lib/vpp_api_test_plugins/lb_test_plugin.so:
 undefined symbol: ip_address_encode

But actually   ip_address_encode() was compiled in libvnet.so,

vpp/build-root/install-vpp-native/vpp/lib# nm libvnet.so |grep ip_address_encode
0000000000623d30 T ip_address_encode

So I do below changes in order to let VAT can link with libvnet.so,   but it 
did not take effect.

diff --git a/src/vat/CMakeLists.txt b/src/vat/CMakeLists.txt
index d512d9c17..81b99bd3d 100644
--- a/src/vat/CMakeLists.txt
+++ b/src/vat/CMakeLists.txt
@@ -16,7 +16,7 @@
##############################################################################
add_vpp_library(vatplugin
   SOURCES plugin_api.c
-  LINK_LIBRARIES vppinfra
+  LINK_LIBRARIES vnet vppinfra
)

##############################################################################
@@ -33,6 +33,7 @@ add_vpp_executable(vpp_api_test ENABLE_EXPORTS
   DEPENDS api_headers

   LINK_LIBRARIES
+  vnet
   vlibmemoryclient
   svm
   vatplugin


Could you guys help me about this issue ?


Best Regards
Yulong Pei
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#15043): https://lists.fd.io/g/vpp-dev/message/15043
Mute This Topic: https://lists.fd.io/mt/69345918/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to