aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorNicolas Morey-Chaisemartin <nmorey@kalray.eu>2015-10-09 15:22:33 +0200
committerMaxim Uvarov <maxim.uvarov@linaro.org>2015-10-13 14:28:13 +0300
commit4aee3d1bc03144d6133fee3c14637457e9c793c4 (patch)
treebf4dcbe18f0ddcdb33bb26f6af5746bd4ad4d201 /configure.ac
parent28e8c3a5a55627ca56b24fe6d82308f88563a932 (diff)
configure: move all AM_CONDITIONAL to configure.ac
Platform specific m4 files cannot define AM_CONDITIONAL. Even if not used outside of the platform specific file, configure will exit with an error if another platform does not set this conditional: configure: error: conditional "netmap_support" was never defined. Usually this means the macro was only invoked conditionally. Solve this by setting a default status do disabled/no at the top configure, which can be overridden by the platform m4 files. And then set the AM_CONDITIONAl in the top configure.ac for every platform to see. Signed-off-by: Nicolas Morey-Chaisemartin <nmorey@kalray.eu> Reviewed-and-tested-by: Matias Elo <matias.elo@nokia.com> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac14
1 files changed, 14 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 92f9d39..5d84f92 100644
--- a/configure.ac
+++ b/configure.ac
@@ -80,6 +80,14 @@ AC_SUBST([with_platform])
AC_SUBST([platform_with_platform], ["platform/${with_platform}"])
AC_SUBST([platform_with_platform_test], ["platform/${with_platform}/test"])
+##########################################################################
+# Prepare default values for platform specific optional features
+##########################################################################
+netmap_support=no
+
+##########################################################################
+# Run platform specific checks and settings
+##########################################################################
if test "${with_platform}" == "linux-generic";
then
m4_include([./platform/linux-generic/m4/configure.m4])
@@ -88,6 +96,12 @@ else
exit 1
fi
+##########################################################################
+# Set conditionals as computed within platform specific files
+##########################################################################
+AM_CONDITIONAL([netmap_support], [test x$netmap_support = xyes ])
+
+
AC_ARG_WITH([sdk-install-path],
AC_HELP_STRING([--with-sdk-install-path=DIR path to external libs and headers],
[(or in the default path if not specified).]),