diff options
author | Damjan Marion <damarion@cisco.com> | 2016-07-07 20:27:49 +0200 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2016-07-08 10:43:38 +0000 |
commit | 905a7f5520a64aad545c8dd02796b56f88ed2d38 (patch) | |
tree | fb2da8de6ac2bbf1a35bcf2b87251c9a94a23fc8 /plugins/configure.ac | |
parent | 370e9e38e8e0b35810734125e2b6eeac65fefa5d (diff) |
Multiple changes in the plugin build infra
- configure.ac - some plugins are enabled by default
- Plugin .so files are placed into corresponding subdirs
- WITH_PLUGIN_TOOLKIT macro is retired - not needed anymore
- plugins/build-data is removed
- plugin makefiles are not building static libs anymore
- plugin makefiles are not installing header files to /usr/include
anymore
Change-Id: I55681bd9ce34811f7eb1b2b24d9f0ca42df1cf04
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'plugins/configure.ac')
-rw-r--r-- | plugins/configure.ac | 36 |
1 files changed, 21 insertions, 15 deletions
diff --git a/plugins/configure.ac b/plugins/configure.ac index 7aff9875edf..f10d180324d 100644 --- a/plugins/configure.ac +++ b/plugins/configure.ac @@ -11,25 +11,29 @@ AC_ARG_ENABLE(tests, [enable_tests=1], [enable_tests=0]) -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_ARG_WITH(dpdk, AC_HELP_STRING([--with-dpdk],[Use the Intel dpdk]), [with_dpdk=1], [with_dpdk=0]) -AC_SUBST(TOOLKIT_INCLUDE,[${with_plugin_toolkit}]) -AM_CONDITIONAL(WITH_PLUGIN_TOOLKIT, test "$with_plugin_toolkit" != ".") AM_CONDITIONAL(ENABLE_TESTS, test "$enable_tests" = "1") AM_CONDITIONAL(WITH_DPDK, test "$with_dpdk" = "1") AC_SUBST(DPDK,["-DDPDK=${with_dpdk}"]) -AC_DEFUN([PLUGIN], +AC_DEFUN([PLUGIN_ENABLED], +[ + AC_ARG_ENABLE($1_plugin, + AC_HELP_STRING([--disable-$1-plugin], [Do not build $1 plugin]), + [enable_the_plugin=0], + [enable_the_plugin=1]) +if test "x$enable_the_plugin" = x1; then + AC_CONFIG_SUBDIRS($1-plugin) +fi +AM_CONDITIONAL(ENABLE_$1_PLUGIN, test "$enable_the_plugin" = "1") +]) + +AC_DEFUN([PLUGIN_DISABLED], [ AC_ARG_ENABLE($1_plugin, AC_HELP_STRING([--enable-$1-plugin], [Build $1 plugin]), @@ -42,7 +46,7 @@ AM_CONDITIONAL(ENABLE_$1_PLUGIN, test "$enable_the_plugin" = "1") ]) # To add a new plugin subdirectory: -# +# # add PLUGIN(new) below, and # add the following to Makefile.am: # @@ -50,10 +54,12 @@ AM_CONDITIONAL(ENABLE_$1_PLUGIN, test "$enable_the_plugin" = "1") # SUBDIRS += new-plugin # endif -PLUGIN(sample) -PLUGIN(sixrd) -PLUGIN(ioam) -PLUGIN(vcgn) -PLUGIN(snat) +PLUGIN_ENABLED(sixrd) +PLUGIN_ENABLED(ioam) +PLUGIN_ENABLED(snat) + +# Disabled plugins, require --enable-XXX-plugin +PLUGIN_DISABLED(vcgn) +PLUGIN_DISABLED(sample) AC_OUTPUT([Makefile]) |