aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStanislaw Kardach <skardach@marvell.com>2020-04-23 15:21:39 +0200
committerMatias Elo <matias.elo@nokia.com>2020-09-07 13:38:00 +0300
commit4394b1b1f33159bad4f71bc46fd405a6a948c96a (patch)
treeb62dd32a26c185c8611fa36183d6e03aa534d686
parent0243d8866e06a7c10112f40862646f2183b11948 (diff)
build: prevent AM_CONDITIONAL checks on plat flags
AM_CONDITIONALS are expected by automake to be global. However we do have platform-specific conditionals. One way of working around that is to move all AM_CONDITIONAL statements to AC_CONFIG_COMMANDS_PRE phase. That preserves the confidional logic while eliminating the global check. Signed-off-by: Stanislaw Kardach <skardach@marvell.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
-rw-r--r--platform/linux-generic/m4/configure.m42
-rw-r--r--platform/linux-generic/m4/odp_dpdk.m42
-rw-r--r--platform/linux-generic/m4/odp_pcapng.m42
3 files changed, 6 insertions, 0 deletions
diff --git a/platform/linux-generic/m4/configure.m4 b/platform/linux-generic/m4/configure.m4
index 5c9c2ec98..76ef62c6e 100644
--- a/platform/linux-generic/m4/configure.m4
+++ b/platform/linux-generic/m4/configure.m4
@@ -17,7 +17,9 @@ AC_ARG_WITH([pcap],
have_pcap=no
AS_IF([test "x$with_pcap" != xno],
[ODP_PCAP([with_pcap=yes]‚[with_pcap=no])])
+AC_CONFIG_COMMANDS_PRE([dnl
AM_CONDITIONAL([ODP_PKTIO_PCAP], [test x$have_pcap = xyes])
+])
m4_include([platform/linux-generic/m4/odp_libconfig.m4])
m4_include([platform/linux-generic/m4/odp_pcapng.m4])
diff --git a/platform/linux-generic/m4/odp_dpdk.m4 b/platform/linux-generic/m4/odp_dpdk.m4
index 93b419bc4..a7c775418 100644
--- a/platform/linux-generic/m4/odp_dpdk.m4
+++ b/platform/linux-generic/m4/odp_dpdk.m4
@@ -49,4 +49,6 @@ else
pktio_dpdk_support=no
fi
+AC_CONFIG_COMMANDS_PRE([dnl
AM_CONDITIONAL([PKTIO_DPDK], [test x$pktio_dpdk_support = xyes ])
+])
diff --git a/platform/linux-generic/m4/odp_pcapng.m4 b/platform/linux-generic/m4/odp_pcapng.m4
index 44274c267..f0a5d56da 100644
--- a/platform/linux-generic/m4/odp_pcapng.m4
+++ b/platform/linux-generic/m4/odp_pcapng.m4
@@ -15,4 +15,6 @@ AC_ARG_ENABLE([pcapng-support],
AC_DEFINE_UNQUOTED([_ODP_PCAPNG], [$pcapng_support],
[Define to 1 to enable pcapng support])
+AC_CONFIG_COMMANDS_PRE([dnl
AM_CONDITIONAL([have_pcapng], [test x$have_pcapng = xyes])
+])