Initial commit of vpp code.

Change-Id: Ib246f1fbfce93274020ee93ce461e3d8bd8b9f17
Signed-off-by: Ed Warnicke <eaw@cisco.com>
diff --git a/build-data/packages/dpdk.mk b/build-data/packages/dpdk.mk
new file mode 100644
index 0000000..c7f0434
--- /dev/null
+++ b/build-data/packages/dpdk.mk
@@ -0,0 +1,24 @@
+
+DPDK_MARCH = $(strip $($(PLATFORM)_dpdk_arch))
+ifeq ($(DPDK_MARCH),)
+	DPDK_MARCH="native"
+endif
+
+ifneq (,$(findstring debug,$(TAG)))
+	DPDK_DEBUG=y
+else
+	DPDK_DEBUG=n
+endif
+
+DPDK_MAKE_ARGS = -C $(call find_source_fn,$(PACKAGE_SOURCE)) \
+	DPDK_BUILD_DIR=$(PACKAGE_BUILD_DIR) \
+	DPDK_INSTALL_DIR=$(PACKAGE_INSTALL_DIR) \
+	DPDK_MARCH=$(DPDK_MARCH) \
+	DPDK_DEBUG=$(DPDK_DEBUG)
+
+
+dpdk_configure = echo 
+
+dpdk_make_args = $(DPDK_MAKE_ARGS) config
+
+dpdk_install =  make $(DPDK_MAKE_ARGS) build
diff --git a/build-data/packages/sample-plugin.mk b/build-data/packages/sample-plugin.mk
new file mode 100644
index 0000000..4532817
--- /dev/null
+++ b/build-data/packages/sample-plugin.mk
@@ -0,0 +1,41 @@
+sample-plugin_configure_depend =		\
+	vppinfra-install			\
+	dpdk-install				\
+	svm-install				\
+	vlib-api-install			\
+	vlib-install				\
+	vnet-install				\
+	vpp-install				\
+	vpp-api-test-install
+
+# 
+sample-plugin_configure_args = --with-q-platform=$(PLATFORM) --with-dpdk
+
+sample-plugin_CPPFLAGS = $(call installed_includes_fn,	\
+	vppinfra					\
+	dpdk						\
+	openssl						\
+	svm						\
+	vlib						\
+	vlib-api					\
+	vnet						\
+	vpp						\
+        vpp-api-test)
+
+sample-plugin_LDFLAGS = $(call installed_libs_fn,	\
+	vppinfra					\
+	dpdk						\
+	openssl						\
+	svm						\
+	vlib						\
+	vlib-api					\
+	vnet						\
+	vpp						\
+	vpp-api-test)
+
+sample-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
+
+sample-plugin_image_include = echo $(arch_lib_dir)/vlib_plugins
diff --git a/build-data/packages/svm.mk b/build-data/packages/svm.mk
new file mode 100644
index 0000000..3971fe8
--- /dev/null
+++ b/build-data/packages/svm.mk
@@ -0,0 +1,5 @@
+svm_top_srcdir = $(call find_source_fn,svm)
+svm_configure_depend = vppinfra-install
+
+svm_CPPFLAGS = $(call installed_includes_fn, vppinfra)
+svm_LDFLAGS = $(call installed_libs_fn, vppinfra)
diff --git a/build-data/packages/vlib-api.mk b/build-data/packages/vlib-api.mk
new file mode 100644
index 0000000..f4bd67d
--- /dev/null
+++ b/build-data/packages/vlib-api.mk
@@ -0,0 +1,6 @@
+vlib-api_configure_depend = vppinfra-install svm-install vlib-install
+
+vlib-api_CPPFLAGS = $(call installed_includes_fn, vppinfra svm vlib)
+vlib-api_LDFLAGS = $(call installed_libs_fn, vppinfra svm vlib)
+
+vlib-api_top_srcdir = $(call find_source_fn,vlib-api)
diff --git a/build-data/packages/vlib.mk b/build-data/packages/vlib.mk
new file mode 100644
index 0000000..11bb1c7
--- /dev/null
+++ b/build-data/packages/vlib.mk
@@ -0,0 +1,6 @@
+vlib_configure_depend = vppinfra-install dpdk-install
+
+vlib_configure_args += --with-dpdk
+
+vlib_CPPFLAGS = $(call installed_includes_fn, vppinfra dpdk)
+vlib_LDFLAGS = $(call installed_libs_fn, vppinfra dpdk)
diff --git a/build-data/packages/vnet.mk b/build-data/packages/vnet.mk
new file mode 100644
index 0000000..4aa2961
--- /dev/null
+++ b/build-data/packages/vnet.mk
@@ -0,0 +1,26 @@
+vnet_configure_depend = 			\
+    vppinfra-install 				\
+    dpdk-install				\
+    svm-install					\
+    vlib-api-install 				\
+    vlib-install 
+
+vnet_CPPFLAGS = $(call installed_includes_fn, 	\
+    vppinfra 					\
+    dpdk 					\
+    openssl					\
+    svm						\
+    vlib 					\
+    vlib-api)
+
+vnet_LDFLAGS = $(call installed_libs_fn, 	\
+    vppinfra					\
+    dpdk					\
+    openssl					\
+    svm						\
+    vlib					\
+    vlib-api)
+
+# Platform dependent configure flags
+vnet_configure_args += $(vnet_configure_args_$(PLATFORM))
+
diff --git a/build-data/packages/vpp-api-test.mk b/build-data/packages/vpp-api-test.mk
new file mode 100644
index 0000000..eb7f466
--- /dev/null
+++ b/build-data/packages/vpp-api-test.mk
@@ -0,0 +1,31 @@
+vpp-api-test_configure_depend =			\
+	vppinfra-install			\
+	dpdk-install				\
+	svm-install				\
+	vlib-api-install			\
+	vlib-install				\
+	vnet-install				\
+	vpp-install
+
+# 
+vpp-api-test_configure_args = --with-q-platform=$(PLATFORM) --with-dpdk \
+       --with-q-plugin-prefix=$(MU_BUILD_ROOT_DIR)/packages-$(PLATFORM)
+
+vpp-api-test_CPPFLAGS = $(call installed_includes_fn,	\
+	vppinfra				\
+	dpdk					\
+	svm					\
+	vlib					\
+	vlib-api				\
+	vnet					\
+	vpp)
+
+vpp-api-test_LDFLAGS = $(call installed_libs_fn,	\
+	vppinfra				\
+	dpdk					\
+	svm					\
+	vlib					\
+	vlib-api				\
+	vnet					\
+	vpp)
+
diff --git a/build-data/packages/vpp-japi.mk b/build-data/packages/vpp-japi.mk
new file mode 100644
index 0000000..6f69baa
--- /dev/null
+++ b/build-data/packages/vpp-japi.mk
@@ -0,0 +1,23 @@
+vpp-japi_configure_depend =			\
+	vppinfra-install			\
+	svm-install				\
+	vlib-api-install			\
+	vlib-install				\
+	vnet-install				\
+	vpp-install
+
+vpp-japi_CPPFLAGS = $(call installed_includes_fn,	\
+	vppinfra					\
+	svm						\
+	vlib						\
+	vlib-api					\
+	vnet						\
+	vpp)
+
+vpp-japi_LDFLAGS = $(call installed_libs_fn,	\
+	vppinfra				\
+	svm					\
+	vlib					\
+	vlib-api)
+
+vpp-japi_CPPFLAGS += -I/usr/lib/jvm/java-7-openjdk-amd64/include
diff --git a/build-data/packages/vpp-platform-scripts.mk b/build-data/packages/vpp-platform-scripts.mk
new file mode 100644
index 0000000..792d600
--- /dev/null
+++ b/build-data/packages/vpp-platform-scripts.mk
@@ -0,0 +1 @@
+#
diff --git a/build-data/packages/vpp.mk b/build-data/packages/vpp.mk
new file mode 100644
index 0000000..ff2c551
--- /dev/null
+++ b/build-data/packages/vpp.mk
@@ -0,0 +1,33 @@
+vpp_configure_depend =				\
+	vppinfra-install			\
+	dpdk-install				\
+	svm-install				\
+	vlib-api-install			\
+	vlib-install				\
+	vnet-install				\
+
+# 
+vpp_configure_args = --with-q-platform=$(PLATFORM) \
+       --with-q-plugin-prefix=$(MU_BUILD_ROOT_DIR)/packages-$(PLATFORM)
+
+# Platform dependent configure flags
+vpp_configure_args += $(vpp_configure_args_$(PLATFORM))
+
+
+vpp_CPPFLAGS = $(call installed_includes_fn,	\
+	vppinfra				\
+	dpdk					\
+        openssl					\
+	svm					\
+	vlib					\
+	vlib-api				\
+	vnet)
+
+vpp_LDFLAGS = $(call installed_libs_fn,		\
+	vppinfra				\
+	dpdk					\
+	openssl					\
+	svm					\
+	vlib					\
+	vlib-api				\
+	vnet)
diff --git a/build-data/packages/vppinfra.mk b/build-data/packages/vppinfra.mk
new file mode 100644
index 0000000..9205987
--- /dev/null
+++ b/build-data/packages/vppinfra.mk
@@ -0,0 +1,2 @@
+# nothing
+