Fix undefined symbol: fformat_append_cr in vat plugins loading 95/13695/4
authorYi He <yi.he@arm.com>
Mon, 16 Jul 2018 05:52:00 +0000 (13:52 +0800)
committerDave Barach <openvpp@barachs.net>
Tue, 31 Jul 2018 14:07:19 +0000 (14:07 +0000)
Several test plugins report undefined symbol while being loaded
by load_one_vat_plugin. Fix this by adding VPP_API_TEST_BUILTIN
into CFLAGS for building these plugins.

Change-Id: I908720fd0d01da1ead30ba17027ba10358f6bdf1
Signed-off-by: Yi He <yi.he@arm.com>
src/vat/main.c
src/vppinfra/format.c

index c34ec94..1287be9 100644 (file)
@@ -26,17 +26,6 @@ vat_suspend (vlib_main_t * vm, f64 interval)
   /* do nothing in the standalone version, just return */
 }
 
-void
-fformat_append_cr (FILE * ofp, const char *fmt, ...)
-{
-  va_list va;
-
-  va_start (va, fmt);
-  (void) va_fformat (ofp, (char *) fmt, &va);
-  va_end (va);
-  fformat (ofp, "\n");
-}
-
 int
 connect_to_vpe (char *name)
 {
index 70292c0..e2fd84b 100644 (file)
@@ -463,6 +463,17 @@ fformat (FILE * f, char *fmt, ...)
 }
 
 #ifdef CLIB_UNIX
+void
+fformat_append_cr (FILE * ofp, const char *fmt, ...)
+{
+  va_list va;
+
+  va_start (va, fmt);
+  (void) va_fformat (ofp, (char *) fmt, &va);
+  va_end (va);
+  fformat (ofp, "\n");
+}
+
 word
 fdformat (int fd, char *fmt, ...)
 {