Hi

I am using:  VPP 18.01

I compiled sample plugin with:
make build  SAMPLE_PLUGIN=yes

it failed so I added

[root@vbbubng12-shashi10 vpp]# git diff 
src/examples/sample-plugin/sample/sample.c
diff --git a/src/examples/sample-plugin/sample/sample.c 
b/src/examples/sample-plugin/sample/sample.c
index 703e604..91e8939 100644
--- a/src/examples/sample-plugin/sample/sample.c
+++ b/src/examples/sample-plugin/sample/sample.c
@@ -63,6 +63,8 @@ VLIB_PLUGIN_REGISTER () = {
};
/* *INDENT-ON* */

+sample_main_t sample_main;
+
/**
  * @brief Enable/disable the macswap plugin.
  *
[root@vbbubng12-shashi10 vpp]#


After this compilation goes through, but when I try to run as
make run

It still gives me this error:

load_one_plugin:142: 
/bng5/vpp-2.9-trial/vpp/build-root/install-vpp_debug-native/sample-plugin/lib64/vpp_plugins/sample_plugin.so:
 undefined symbol: sample_main
load_one_plugin:143: Failed to load plugin 'sample_plugin.so'
/bin/sh: line 1: 20197 Aborted                 sudo 
/bng5/vpp-2.9-trial/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp " unix 
{ interactive cli-listen /run/vpp/cli.sock gid 0


Any solution for this:

Regards
Shashi

Reply via email to