directory and GNU autotools setup.
Change-Id: I6c59d1297389c9413db0c0b9bdf3b759080bf1b8
Signed-off-by: Ole Troan <ot@cisco.com>
vpp-japi gmod
vlib_configure_args_arm32 = --with-pre-data=128
-vnet_configure_args_arm32 = --with-dpdk --without-vcgn --without-ipsec --without-ipv6sr
-vpp_configure_args_arm32 = --with-dpdk --without-vcgn --without-ipsec --without-ipv6sr
+vnet_configure_args_arm32 = --with-dpdk --without-ipsec --without-ipv6sr
+vpp_configure_args_arm32 = --with-dpdk --without-ipsec --without-ipv6sr
arm32_dpdk_arch = "armv7a"
arm32_dpdk_target = "arm-armv7a-linuxapp-gcc"
endif
endif
-vpp_configure_args_dpaa2 = --with-dpdk --without-ipsec --without-vcgn \
+vpp_configure_args_dpaa2 = --with-dpdk --without-ipsec \
--without-ipv6sr --with-sysroot=$(SYSROOT)
-vnet_configure_args_dpaa2 = --with-dpdk --without-ipsec --without-vcgn \
+vnet_configure_args_dpaa2 = --with-dpdk --without-ipsec \
--without-ipv6sr --with-sysroot=$(SYSROOT)
# Set these parameters carefully. The vlib_buffer_t is 128 bytes, i.e.
vpp vpp-api-test
vnet_configure_args_qppc = \
- --without-ipsec --without-vcgn --without-ipv6sr
+ --without-ipsec --without-ipv6sr
vpp_configure_args_qppc = \
- --without-ipsec --without-vcgn --without-ipv6sr
+ --without-ipsec --without-ipv6sr
vlib_configure_args_qppc = --with-pre-data=128
vpp-cavium-dpdk vpp-api-test-cavium-dpdk
vnet-cavium-dpdk_configure_args_thunder = \
- --with-dpdk --without-ipsec --without-vcgn --without-ipv6sr
+ --with-dpdk --without-ipsec --without-ipv6sr
vpp-cavium-dpdk_configure_args_thunder = \
- --with-dpdk --without-ipsec --without-vcgn --without-ipv6sr
+ --with-dpdk --without-ipsec --without-ipv6sr
cavium-dpdk_configure_args_thunder = --with-headroom=256
vlib_configure_args_vpp_lite = --with-pre-data=128
-vnet_configure_args_vpp_lite = --without-vcgn
-vpp_configure_args_vpp_lite = --without-vcgn
+vnet_configure_args_vpp_lite =
+vpp_configure_args_vpp_lite =
vpp_lite_debug_TAG_CFLAGS = -g -O0 -DCLIB_DEBUG -DFORTIFY_SOURCE=2 -march=$(MARCH) \
-fstack-protector-all -fPIC -Werror
AUTOMAKE_OPTIONS = foreign subdir-objects
-AM_CFLAGS = -Wall -I@TOOLKIT_INCLUDE@
-
-
-########################################
-# SIXRD (RFC5969)
-########################################
-libsixrd_plugin_la_SOURCES = plugins/sixrd/sixrd.c plugins/sixrd/ip4_sixrd.c plugins/sixrd/ip6_sixrd.c
-nobase_include_HEADERS = plugins/sixrd/sixrd.h
-
-libsixrd_plugin_la_LDFLAGS = -module
-#BUILT_SOURCES =
-
-lib_LTLIBRARIES = libsixrd_plugin.la
-
-########################################
-# iOAM Proof of Transit
-########################################
-
-ioam_pot_plugin_la_SOURCES = plugins/ioam/lib-pot/pot_util.c plugins/ioam/encap/ip6_ioam_pot.c \
- plugins/ioam/lib-pot/pot_util.h plugins/ioam/lib-pot/math64.h plugins/ioam/lib-pot/pot_api.c
-ioam_pot_plugin_la_LDFLAGS = -module
-
-BUILT_SOURCES = plugins/ioam/lib-pot/pot.api.h
-SUFFIXES = .api.h .api
-
-%.api.h: %.api
- mkdir -p `dirname $@` ; \
- $(CC) $(CPPFLAGS) -E -P -C -x c $^ \
- | vppapigen --input - --output $@ --show-name $@
-
-nobase_include_HEADERS += \
- plugins/ioam/lib-pot/pot_all_api_h.h \
- plugins/ioam/lib-pot/pot_msg_enum.h \
- plugins/ioam/lib-pot/pot.api.h \
- plugins/ioam/lib-pot/pot_util.h \
- plugins/ioam/lib-pot/math64.h
-
-ioam_pot_test_plugin_la_SOURCES = plugins/ioam/lib-pot/pot_test.c plugins/ioam/lib-pot/pot_plugin.api.h
-ioam_pot_test_plugin_la_LDFLAGS = -module
-
-lib_LTLIBRARIES += ioam_pot_plugin.la ioam_pot_test_plugin.la
-
-########################################
-# Virtual Carrier Grade NAT
-########################################
-
-libvcgn_plugin_la_SOURCES = \
- plugins/vcgn/cnat_bulk_port.c \
- plugins/vcgn/cnat_config.c \
- plugins/vcgn/cnat_db_scanner.c \
- plugins/vcgn/cnat_db_v2.c \
- plugins/vcgn/cnat_debug_msg_handler.c \
- plugins/vcgn/cnat_cli_handler.c \
- plugins/vcgn/cnat_global.c \
- plugins/vcgn/cnat_ipv4_udp_inside_input.c \
- plugins/vcgn/cnat_ipv4_udp_inside_input_exceptions.c \
- plugins/vcgn/cnat_ipv4_udp_outside_input.c \
- plugins/vcgn/cnat_ipv4_tcp_inside_input.c \
- plugins/vcgn/cnat_ipv4_tcp_inside_input_exceptions.c \
- plugins/vcgn/cnat_ipv4_tcp_outside_input.c \
- plugins/vcgn/cnat_ipv4_icmp_query_inside_input.c \
- plugins/vcgn/cnat_ipv4_icmp_query_inside_input_exception.c \
- plugins/vcgn/cnat_ipv4_icmp_query_outside_input.c \
- plugins/vcgn/cnat_ipv4_icmp_error_inside_input.c \
- plugins/vcgn/cnat_ipv4_icmp_error_outside_input.c \
- plugins/vcgn/cnat_logging.c \
- plugins/vcgn/cnat_ports.c \
- plugins/vcgn/cnat_util.c \
- plugins/vcgn/cnat_show.c \
- plugins/vcgn/cnat_syslog.c \
- plugins/vcgn/cnat_v4_functions.c \
- plugins/vcgn/index_list.c \
- plugins/vcgn/spp_platform_trace_log.c \
- plugins/vcgn/vcgn_classify.c
-
-nobase_include_HEADERS += plugins/vcgn/cgn_bitmap.h \
- plugins/vcgn/cgse_defs.h \
- plugins/vcgn/cnat_bulk_port_defs.h \
- plugins/vcgn/cnat_bulk_port.h \
- plugins/vcgn/cnat_cli.h \
- plugins/vcgn/cnat_common_api.h \
- plugins/vcgn/cnat_config_api.h \
- plugins/vcgn/cnat_config.h \
- plugins/vcgn/cnat_db.h \
- plugins/vcgn/cnat_global.h \
- plugins/vcgn/cnat_ipv4_icmp.h \
- plugins/vcgn/cnat_ipv4_udp.h \
- plugins/vcgn/cnat_log_api.h \
- plugins/vcgn/cnat_log_common.h \
- plugins/vcgn/cnat_logging.h \
- plugins/vcgn/cnat_pcp_server.h \
- plugins/vcgn/cnat_ports.h \
- plugins/vcgn/cnat_show_api.h \
- plugins/vcgn/cnat_show_response.h \
- plugins/vcgn/cnat_syslog.h \
- plugins/vcgn/cnat_v4_ftp_alg.h \
- plugins/vcgn/cnat_v4_functions.h \
- plugins/vcgn/cnat_v4_pptp_alg.h \
- plugins/vcgn/cnat_va_db.h \
- plugins/vcgn/dslite_db.h \
- plugins/vcgn/dslite_defs.h \
- plugins/vcgn/index_list.h \
- plugins/vcgn/nat64_db.h \
- plugins/vcgn/nat64_defs.h \
- plugins/vcgn/nat64_tcp_sm.h \
- plugins/vcgn/platform_common.h \
- plugins/vcgn/platform_common_override.h \
- plugins/vcgn/spp_ctx.h \
- plugins/vcgn/spp_platform_trace_log.h \
- plugins/vcgn/spp_timers.h \
- plugins/vcgn/tcp_header_definitions.h \
- plugins/vcgn/vcgn_db.h
-
-libvcgn_plugin_la_LDFLAGS = -module
+SUBDIRS =
+if ENABLE_SAMPLE_PLUGIN
+SUBDIRS += sample-plugin
+endif
-lib_LTLIBRARIES += libvcgn_plugin.la
+if ENABLE_SIXRD_PLUGIN
+SUBDIRS += sixrd-plugin
+endif
-if WITH_PLUGIN_TOOLKIT
-install-data-hook:
- mkdir /usr/lib/vpp_plugins || true
- mkdir /usr/lib/vpp_api_test_plugins || true
- cp $(prefix)/lib/libsixrd_plugin.so.*.*.* /usr/lib/vpp_plugins
- cp $(prefix)/lib/libvcgn_plugin.so.*.*.* /usr/lib/vpp_plugins
- cp $(prefix)/lib/ioam_pot_plugin.so.*.*.* /usr/lib/vpp_plugins
- cp $(prefix)/lib/ioam_pot_test_plugin.so.*.*.* \
- /usr/lib/vpp_api_test_plugins
+if ENABLE_IOAM_PLUGIN
+SUBDIRS += ioam-plugin
endif
+if ENABLE_VCGN_PLUGIN
+SUBDIRS += vcgn-plugin
+endif
--- /dev/null
+ioam-plugin_configure_depend = \
+ vppinfra-install \
+ svm-install \
+ vlib-api-install \
+ vlib-install \
+ vnet-install \
+ vpp-install \
+ vpp-api-test-install
+
+ioam-plugin_CPPFLAGS = $(call installed_includes_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+ioam-plugin_LDFLAGS = $(call installed_libs_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+ioam-plugin_post_install = \
+ mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins ; \
+ cp $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/*.so \
+ $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins
+
+ioam-plugin_image_include = echo $(arch_lib_dir)/vlib_plugins
+
+ifneq ($($(PLATFORM)_uses_dpdk),no)
+ioam-plugin_configure_args = --with-dpdk
+ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
+ioam-plugin_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
+ioam-plugin_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
+else
+ioam-plugin_configure_depend += dpdk-install
+ioam-plugin_CPPFLAGS += $(call installed_includes_fn, dpdk)
+ioam-plugin_LDFLAGS += $(call installed_libs_fn, dpdk)
+endif
+endif
--- /dev/null
+sixrd-plugin_configure_depend = \
+ vppinfra-install \
+ svm-install \
+ vlib-api-install \
+ vlib-install \
+ vnet-install \
+ vpp-install \
+ vpp-api-test-install
+
+sixrd-plugin_CPPFLAGS = $(call installed_includes_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+sixrd-plugin_LDFLAGS = $(call installed_libs_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+sixrd-plugin_post_install = \
+ mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins ; \
+ cp $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/*.so \
+ $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins
+
+sixrd-plugin_image_include = echo $(arch_lib_dir)/vlib_plugins
+
+ifneq ($($(PLATFORM)_uses_dpdk),no)
+sixrd-plugin_configure_args = --with-dpdk
+ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
+sixrd-plugin_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
+sixrd-plugin_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
+else
+sixrd-plugin_configure_depend += dpdk-install
+sixrd-plugin_CPPFLAGS += $(call installed_includes_fn, dpdk)
+sixrd-plugin_LDFLAGS += $(call installed_libs_fn, dpdk)
+endif
+endif
--- /dev/null
+vcgn-plugin_configure_depend = \
+ vppinfra-install \
+ svm-install \
+ vlib-api-install \
+ vlib-install \
+ vnet-install \
+ vpp-install \
+ vpp-api-test-install
+
+vcgn-plugin_CPPFLAGS = $(call installed_includes_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+vcgn-plugin_LDFLAGS = $(call installed_libs_fn, \
+ vppinfra \
+ openssl \
+ svm \
+ vlib \
+ vlib-api \
+ vnet \
+ vpp \
+ vpp-api-test)
+
+vcgn-plugin_post_install = \
+ mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins ; \
+ cp $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/*.so \
+ $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins
+
+vcgn-plugin_image_include = echo $(arch_lib_dir)/vlib_plugins
+
+ifneq ($($(PLATFORM)_uses_dpdk),no)
+vcgn-plugin_configure_args = --with-dpdk
+ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
+vcgn-plugin_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
+vcgn-plugin_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
+else
+vcgn-plugin_configure_depend += dpdk-install
+vcgn-plugin_CPPFLAGS += $(call installed_includes_fn, dpdk)
+vcgn-plugin_LDFLAGS += $(call installed_libs_fn, dpdk)
+endif
+endif
AC_SUBST(TOOLKIT_INCLUDE,[${with_plugin_toolkit}])
AM_CONDITIONAL(WITH_PLUGIN_TOOLKIT, test "$with_plugin_toolkit" != ".")
AM_CONDITIONAL(ENABLE_TESTS, test "$enable_tests" = "1")
+
+#
+# Sample plugin
+#
+AC_ARG_ENABLE(sample_plugin,
+ AC_HELP_STRING([--enable-sample-plugin], [Build sample plugin]),
+ [enable_sample_plugin=1],
+ [enable_sample_plugin=0])
+
+if test "x$enable_sample_plugin" = x1; then
+ AC_CONFIG_SUBDIRS([sample-plugin])
+fi
+
+AM_CONDITIONAL(ENABLE_SAMPLE_PLUGIN, test "$enable_sample_plugin" = "1")
+
+#
+# SIXRD plugin
+#
+AC_ARG_ENABLE(sixrd_plugin,
+ AC_HELP_STRING([--enable-sixrd-plugin], [Build sixrd plugin]),
+ [],
+ [enable_sixrd_plugin=1])
+
+if test "x$enable_sixrd_plugin" = x1; then
+ AC_CONFIG_SUBDIRS([sixrd-plugin])
+fi
+
+AM_CONDITIONAL(ENABLE_SIXRD_PLUGIN, test "$enable_sixrd_plugin" = "1")
+
+#
+# IOAM plugin
+#
+AC_ARG_ENABLE(ioam_plugin,
+ AC_HELP_STRING([--enable-ioam-plugin], [Build ioam plugin]),
+ [],
+ [enable_ioam_plugin=1])
+
+if test "x$enable_ioam_plugin" = x1; then
+ AC_CONFIG_SUBDIRS([ioam-plugin])
+fi
+
+AM_CONDITIONAL(ENABLE_IOAM_PLUGIN, test "$enable_ioam_plugin" = "1")
+
+#
+# VCGN plugin
+#
+AC_ARG_ENABLE(vcgn_plugin,
+ AC_HELP_STRING([--enable-vcgn-plugin], [Build vcgn plugin]),
+ [enable_vcgn_plugin=1],
+ [enable_vcgn_plugin=0])
+
+if test "x$enable_vcgn_plugin" = x1; then
+ AC_CONFIG_SUBDIRS([vcgn-plugin])
+fi
+
+AM_CONDITIONAL(ENABLE_VCGN_PLUGIN, test "$enable_vcgn_plugin" = "1")
+
AC_OUTPUT([Makefile])
--- /dev/null
+# Copyright (c) 2015 Cisco and/or its affiliates.
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at:
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+AUTOMAKE_OPTIONS = foreign subdir-objects
+
+AM_CFLAGS = -Wall -I@TOOLKIT_INCLUDE@
+
+########################################
+# iOAM Proof of Transit
+########################################
+
+ioam_pot_plugin_la_SOURCES = \
+ ioam/lib-pot/pot_util.c \
+ ioam/encap/ip6_ioam_pot.c \
+ ioam/lib-pot/pot_util.h \
+ ioam/lib-pot/math64.h \
+ ioam/lib-pot/pot_api.c
+
+ioam_pot_plugin_la_LDFLAGS = -module
+
+BUILT_SOURCES = \
+ ioam/lib-pot/pot.api.h
+
+SUFFIXES = .api.h .api
+
+%.api.h: %.api
+ mkdir -p `dirname $@` ; \
+ $(CC) $(CPPFLAGS) -E -P -C -x c $^ \
+ | vppapigen --input - --output $@ --show-name $@
+
+nobase_include_HEADERS = \
+ ioam/lib-pot/pot_all_api_h.h \
+ ioam/lib-pot/pot_msg_enum.h \
+ ioam/lib-pot/pot.api.h \
+ ioam/lib-pot/pot_util.h \
+ ioam/lib-pot/math64.h
+
+ioam_pot_test_plugin_la_SOURCES = \
+ ioam/lib-pot/pot_test.c \
+ ioam/lib-pot/pot_plugin.api.h
+
+ioam_pot_test_plugin_la_LDFLAGS = -module
+
+lib_LTLIBRARIES = ioam_pot_plugin.la ioam_pot_test_plugin.la
+
+if WITH_PLUGIN_TOOLKIT
+install-data-hook:
+ mkdir /usr/lib/vpp_plugins || true
+ mkdir /usr/lib/vpp_api_test_plugins || true
+ cp -L $(prefix)/lib/ioam_pot_plugin.so /usr/lib/vpp_plugins
+ cp -L $(prefix)/lib/ioam_pot_test_plugin.so /usr/lib/vpp_api_test_plugins
+endif
--- /dev/null
+AC_INIT(ioam_plugin, 1.0)
+LT_INIT
+AM_INIT_AUTOMAKE
+
+AM_PROG_AS
+AC_PROG_CC
+AM_PROG_CC_C_O
+
+AC_ARG_WITH(plugin-toolkit,
+ AC_HELP_STRING([--with-plugin-toolkit],
+ [build using the vpp toolkit]),
+ [with_plugin_toolkit=${prefix}/include],
+ [with_plugin_toolkit=.])
+
+AC_SUBST(TOOLKIT_INCLUDE,[${with_plugin_toolkit}])
+AM_CONDITIONAL(WITH_PLUGIN_TOOLKIT, test "$with_plugin_toolkit" != ".")
+AC_OUTPUT([Makefile])
#include <vppinfra/error.h>
#include <vppinfra/elog.h>
-#include <plugins/ioam/lib-pot/pot_util.h>
+#include <ioam/lib-pot/pot_util.h>
typedef CLIB_PACKED(struct {
ip6_hop_by_hop_option_t hdr;
* limitations under the License.
*/
/* Include the generated file, see BUILT_SOURCES in Makefile.am */
-#include <plugins/ioam/lib-pot/pot.api.h>
+#include <ioam/lib-pot/pot.api.h>
#include <vnet/vnet.h>
#include <vnet/plugin/plugin.h>
-#include <plugins/ioam/lib-pot/pot_util.h>
+#include <ioam/lib-pot/pot_util.h>
#include <vlibapi/api.h>
#include <vlibmemory/api.h>
#include <vlibsocket/api.h>
/* define message IDs */
-#include <plugins/ioam/lib-pot/pot_msg_enum.h>
+#include <ioam/lib-pot/pot_msg_enum.h>
/* define message structures */
#define vl_typedefs
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_typedefs
/* define generated endian-swappers */
#define vl_endianfun
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_endianfun
/* instantiate all the print functions we know about */
#define vl_print(handle, ...) vlib_cli_output (handle, __VA_ARGS__)
#define vl_printfun
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_printfun
/* Get the API version number */
#define vl_api_version(n,v) static u32 api_version=(v);
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_api_version
/*
#define vl_msg_id(n,h) n,
typedef enum {
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
/* We'll want to know how many messages IDs we need... */
VL_MSG_FIRST_AVAILABLE,
} vl_msg_id_t;
#include <vppinfra/error.h>
/* Declare message IDs */
-#include <plugins/ioam/lib-pot/pot_msg_enum.h>
+#include <ioam/lib-pot/pot_msg_enum.h>
/* define message structures */
#define vl_typedefs
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_typedefs
/* declare message handlers for each api */
#define vl_endianfun /* define message structures */
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_endianfun
/* instantiate all the print functions we know about */
#define vl_print(handle, ...)
#define vl_printfun
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_printfun
/* Get the API version number. */
#define vl_api_version(n,v) static u32 api_version=(v);
-#include <plugins/ioam/lib-pot/pot_all_api_h.h>
+#include <ioam/lib-pot/pot_all_api_h.h>
#undef vl_api_version
install-data-hook:
mkdir /usr/lib/vpp_plugins || true
mkdir /usr/lib/vpp_api_test_plugins || true
- cp $(prefix)/lib/sample_plugin.so.*.*.* /usr/lib/vpp_plugins
- cp $(prefix)/lib/sample_test_plugin.so.*.*.* \
- /usr/lib/vpp_api_test_plugins
+ cp -L $(prefix)/lib/sample_plugin.so /usr/lib/vpp_plugins
+ cp -L $(prefix)/lib/sample_test_plugin.so /usr/lib/vpp_api_test_plugins
endif
--- /dev/null
+# Copyright (c) 2015 Cisco and/or its affiliates.
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at:
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+AUTOMAKE_OPTIONS = foreign subdir-objects
+
+AM_CFLAGS = -Wall -I@TOOLKIT_INCLUDE@
+
+libsixrd_plugin_la_SOURCES = \
+ sixrd/sixrd.c \
+ sixrd/ip4_sixrd.c \
+ sixrd/ip6_sixrd.c
+
+nobase_include_HEADERS = \
+ sixrd/sixrd.h
+
+libsixrd_plugin_la_LDFLAGS = -module
+
+BUILT_SOURCES =
+
+lib_LTLIBRARIES = libsixrd_plugin.la
+
+if WITH_PLUGIN_TOOLKIT
+install-data-hook:
+ mkdir /usr/lib/vpp_plugins || true
+ mkdir /usr/lib/vpp_api_test_plugins || true
+ cp -L $(prefix)/lib/libsixrd_plugin.so /usr/lib/vpp_plugins
+endif
--- /dev/null
+AC_INIT(sixrd_plugin, 1.0)
+LT_INIT
+AM_INIT_AUTOMAKE
+
+AM_PROG_AS
+AC_PROG_CC
+AM_PROG_CC_C_O
+
+AC_ARG_WITH(plugin-toolkit,
+ AC_HELP_STRING([--with-plugin-toolkit],
+ [build using the vpp toolkit]),
+ [with_plugin_toolkit=${prefix}/include],
+ [with_plugin_toolkit=.])
+
+AC_SUBST(TOOLKIT_INCLUDE,[${with_plugin_toolkit}])
+AM_CONDITIONAL(WITH_PLUGIN_TOOLKIT, test "$with_plugin_toolkit" != ".")
+AC_OUTPUT([Makefile])
--- /dev/null
+# Copyright (c) 2015 Cisco and/or its affiliates.
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at:
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+AUTOMAKE_OPTIONS = foreign subdir-objects
+
+AM_CFLAGS = -Wall -I@TOOLKIT_INCLUDE@
+
+########################################
+# Virtual Carrier Grade NAT
+########################################
+
+libvcgn_plugin_la_SOURCES = \
+ vcgn/cnat_bulk_port.c \
+ vcgn/cnat_config.c \
+ vcgn/cnat_db_scanner.c \
+ vcgn/cnat_db_v2.c \
+ vcgn/cnat_debug_msg_handler.c \
+ vcgn/cnat_cli_handler.c \
+ vcgn/cnat_global.c \
+ vcgn/cnat_ipv4_udp_inside_input.c \
+ vcgn/cnat_ipv4_udp_inside_input_exceptions.c \
+ vcgn/cnat_ipv4_udp_outside_input.c \
+ vcgn/cnat_ipv4_tcp_inside_input.c \
+ vcgn/cnat_ipv4_tcp_inside_input_exceptions.c \
+ vcgn/cnat_ipv4_tcp_outside_input.c \
+ vcgn/cnat_ipv4_icmp_query_inside_input.c \
+ vcgn/cnat_ipv4_icmp_query_inside_input_exception.c \
+ vcgn/cnat_ipv4_icmp_query_outside_input.c \
+ vcgn/cnat_ipv4_icmp_error_inside_input.c \
+ vcgn/cnat_ipv4_icmp_error_outside_input.c \
+ vcgn/cnat_logging.c \
+ vcgn/cnat_ports.c \
+ vcgn/cnat_util.c \
+ vcgn/cnat_show.c \
+ vcgn/cnat_syslog.c \
+ vcgn/cnat_v4_functions.c \
+ vcgn/index_list.c \
+ vcgn/spp_platform_trace_log.c \
+ vcgn/vcgn_classify.c
+
+nobase_include_HEADERS = \
+ vcgn/cgn_bitmap.h \
+ vcgn/cgse_defs.h \
+ vcgn/cnat_bulk_port_defs.h \
+ vcgn/cnat_bulk_port.h \
+ vcgn/cnat_cli.h \
+ vcgn/cnat_common_api.h \
+ vcgn/cnat_config_api.h \
+ vcgn/cnat_config.h \
+ vcgn/cnat_db.h \
+ vcgn/cnat_global.h \
+ vcgn/cnat_ipv4_icmp.h \
+ vcgn/cnat_ipv4_udp.h \
+ vcgn/cnat_log_api.h \
+ vcgn/cnat_log_common.h \
+ vcgn/cnat_logging.h \
+ vcgn/cnat_pcp_server.h \
+ vcgn/cnat_ports.h \
+ vcgn/cnat_show_api.h \
+ vcgn/cnat_show_response.h \
+ vcgn/cnat_syslog.h \
+ vcgn/cnat_v4_ftp_alg.h \
+ vcgn/cnat_v4_functions.h \
+ vcgn/cnat_v4_pptp_alg.h \
+ vcgn/cnat_va_db.h \
+ vcgn/dslite_db.h \
+ vcgn/dslite_defs.h \
+ vcgn/index_list.h \
+ vcgn/nat64_db.h \
+ vcgn/nat64_defs.h \
+ vcgn/nat64_tcp_sm.h \
+ vcgn/platform_common.h \
+ vcgn/platform_common_override.h \
+ vcgn/spp_ctx.h \
+ vcgn/spp_platform_trace_log.h \
+ vcgn/spp_timers.h \
+ vcgn/tcp_header_definitions.h \
+ vcgn/vcgn_db.h
+
+libvcgn_plugin_la_LDFLAGS = -module
+
+lib_LTLIBRARIES = libvcgn_plugin.la
+
+if WITH_PLUGIN_TOOLKIT
+install-data-hook:
+ mkdir /usr/lib/vpp_plugins || true
+ mkdir /usr/lib/vpp_api_test_plugins || true
+ cp -L $(prefix)/lib/libvcgn_plugin.so /usr/lib/vpp_plugins
+endif
--- /dev/null
+AC_INIT(vcgn_plugin, 1.0)
+LT_INIT
+AM_INIT_AUTOMAKE
+
+AM_PROG_AS
+AC_PROG_CC
+AM_PROG_CC_C_O
+
+AC_ARG_WITH(plugin-toolkit,
+ AC_HELP_STRING([--with-plugin-toolkit],
+ [build using the vpp toolkit]),
+ [with_plugin_toolkit=${prefix}/include],
+ [with_plugin_toolkit=.])
+
+AC_SUBST(TOOLKIT_INCLUDE,[${with_plugin_toolkit}])
+AM_CONDITIONAL(WITH_PLUGIN_TOOLKIT, test "$with_plugin_toolkit" != ".")
+AC_OUTPUT([Makefile])