netmap: Reinstate and update netmap plugin
[vpp.git] / src / plugins / netmap / CMakeLists.txt
diff --git a/src/plugins/netmap/CMakeLists.txt b/src/plugins/netmap/CMakeLists.txt
new file mode 100644 (file)
index 0000000..d53a9e0
--- /dev/null
@@ -0,0 +1,32 @@
+# SPDX-License-Identifier: Apache-2.0
+# Copyright (c) 2024 Tom Jones <thj@freebsd.org>
+#
+# This software was developed by Tom Jones <thj@freebsd.org> under sponsorship
+# from the FreeBSD Foundation.
+#
+
+if (NOT "${CMAKE_SYSTEM_NAME}" STREQUAL "FreeBSD")
+  message(WARNING "Netmap is only currently support on FreeBSD  - netmap plugin disabled")
+  return()
+endif()
+
+add_vpp_plugin(netmap
+  SOURCES
+  plugin.c
+  netmap.c
+  node.c
+  device.c
+  cli.c
+  netmap_api.c
+
+  MULTIARCH_SOURCES
+  node.c
+  device.c
+
+  INSTALL_HEADERS
+  netmap.h
+  net_netmap.h
+
+  API_FILES
+  netmap.api
+)