Added dependency to vpp-plugins package. Fixed indentation in the code 10/8410/1
authorAlberto Compagno <[email protected]>
Wed, 13 Sep 2017 12:03:15 +0000 (14:03 +0200)
committerAlberto Compagno <[email protected]>
Wed, 13 Sep 2017 12:03:15 +0000 (14:03 +0200)
Change-Id: I6c789dbd3d95c7f6341a7a98e9e7ba7f797e53f8
Signed-off-by: Alberto Compagno <[email protected]>
cicn-plugin/CMakeLists.txt
cicn-plugin/cicn/cicn.c
cicn-plugin/cicn/node.c
cicn-plugin/scripts/build-package.sh

index b9bcfd8..2836a04 100755 (executable)
@@ -155,13 +155,13 @@ if (DEB_PACKAGE)
     SET(TYPE "DEBIAN")
     SET(GENERATOR "DEB")
     SET(CPACK_PACKAGE_FILE_NAME "${PACKAGE_NAME}_${PACKAGE_VERSION}_${ARCHITECTURE}")
-    SET(CPACK_${TYPE}_PACKAGE_DEPENDS "vpp (>> 17.01), vpp-lib (>> 17.01)")
+    SET(CPACK_${TYPE}_PACKAGE_DEPENDS "vpp (>= 17.04), vpp (< 17.07), vpp-lib (>= 17.04), vpp-lib (< 17.07), vpp-plugins (>= 17.04), vpp-plugins (< 17.07)")
 elseif (RPM_PACKAGE)
     SET(TYPE "RPM")
     SET(GENERATOR "RPM")
     SET(CPACK_PACKAGE_FILE_NAME "${PACKAGE_NAME}-${PACKAGE_VERSION}.${ARCHITECTURE}")
     SET(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/etc" "/usr/lib/python2.7" "/usr/lib/python2.7/site-packages")
-    SET(CPACK_${TYPE}_PACKAGE_REQUIRES "vpp > 17.01, vpp-lib > 17.01")
+    SET(CPACK_${TYPE}_PACKAGE_REQUIRES "vpp >= 17.04, vpp < 17.07, vpp-lib >= 17.04, vpp-lib < 17.07, vpp-plugins >= 17.04, vpp-plugins < 17.07")
 else ()
     RETURN()
 endif ()
index 9beea5d..c73e7f8 100644 (file)
@@ -430,8 +430,11 @@ icn_process_fn (vlib_main_t * vm, vlib_node_runtime_t * rt, vlib_frame_t * f)
 
 VLIB_REGISTER_NODE (icn_process_node, static) =
 {
-.function = icn_process_fn,.type = VLIB_NODE_TYPE_PROCESS,.name =
-    "icn-process",.process_log2_n_stack_bytes = 16};
+  .function = icn_process_fn,
+  .type = VLIB_NODE_TYPE_PROCESS,
+  .name = "icn-process",
+  .process_log2_n_stack_bytes = 16
+};
 
 /*
  * Init entry-point for the icn plugin
index 0219982..8ef0453 100644 (file)
@@ -1485,17 +1485,19 @@ cicn_trim_cs_lru (vlib_main_t * vm, vlib_node_runtime_t * node,
  */
 VLIB_REGISTER_NODE (icnfwd_node) =
 {
-  .function = icnfwd_node_fn,.name = "icnfwd",.vector_size =
-    sizeof (u32),.runtime_data_bytes =
-    sizeof (icnfwd_runtime_t),.format_trace = icnfwd_format_trace,.type =
-    VLIB_NODE_TYPE_INTERNAL,.n_errors =
-    ARRAY_LEN (icnfwd_error_strings),.error_strings =
-    icnfwd_error_strings,.n_next_nodes = ICNFWD_N_NEXT,
-    /* edit / add dispositions here */
-    .next_nodes =
-  {
-  [ICNFWD_NEXT_LOOKUP] = "ip4-lookup",
-      [ICNFWD_NEXT_ERROR_DROP] = "error-drop",}
+  .function = icnfwd_node_fn,
+  .name = "icnfwd",
+  .vector_size = sizeof (u32),
+  .runtime_data_bytes = sizeof (icnfwd_runtime_t),
+  .format_trace = icnfwd_format_trace,
+  .type = VLIB_NODE_TYPE_INTERNAL,
+  .n_errors = ARRAY_LEN (icnfwd_error_strings),
+  .error_strings = icnfwd_error_strings,
+  .n_next_nodes = ICNFWD_N_NEXT,
+  .next_nodes = {
+    [ICNFWD_NEXT_LOOKUP] = "ip4-lookup",
+    [ICNFWD_NEXT_ERROR_DROP] = "error-drop",
+  }
 ,};
 
 /*
@@ -1948,15 +1950,18 @@ icndist_node_fn (vlib_main_t * vm,
  */
 VLIB_REGISTER_NODE (icndist_node) =
 {
-  .function = icndist_node_fn,.name = "icndist",.vector_size =
-    sizeof (u32),.runtime_data_bytes =
-    sizeof (icndist_runtime_t),.format_trace = icndist_format_trace,.type =
-    VLIB_NODE_TYPE_INTERNAL,.n_errors =
-    ARRAY_LEN (icndist_error_strings),.error_strings =
-    icndist_error_strings,.n_next_nodes = ICNDIST_N_NEXT,
-    /* edit / add dispositions here */
-    .next_nodes =
-  {
-  [ICNDIST_NEXT_FWD] = "icnfwd",[ICNDIST_NEXT_ERROR_DROP] = "error-drop",}
+  .function = icndist_node_fn,
+  .name = "icndist",
+  .vector_size = sizeof (u32),
+  .runtime_data_bytes = sizeof (icndist_runtime_t),
+  .format_trace = icndist_format_trace,
+  .type = VLIB_NODE_TYPE_INTERNAL,
+  .n_errors = ARRAY_LEN (icndist_error_strings),
+  .error_strings = icndist_error_strings,
+  .n_next_nodes = ICNDIST_N_NEXT,
+  .next_nodes = {
+    [ICNDIST_NEXT_FWD] = "icnfwd",
+    [ICNDIST_NEXT_ERROR_DROP] = "error-drop",
+  }
 ,};
 #endif // CICN_FEATURE_MULTITHREAD
index 25c0354..b65cee1 100644 (file)
@@ -9,7 +9,7 @@ apt_get=${APT_PATH:-"/usr/local/bin/apt-get"}
 
 BUILD_TOOLS_UBUNTU="build-essential cmake"
 LIBSSL_LIBEVENT_UBUNTU="libevent-dev libssl-dev"
-DEPS_UBUNTU="vpp-dev vpp-lib"
+DEPS_UBUNTU="vpp-dev vpp-lib vpp-plugins"
 
 BUILD_TOOLS_GROUP_CENTOS="'Development Tools'"
 BUILD_TOOLS_SINGLE_CENTOS="cmake"