aboutsummaryrefslogtreecommitdiff
path: root/platform/linux-generic/m4
diff options
context:
space:
mode:
authorMatias Elo <matias.elo@nokia.com>2021-12-17 14:00:35 +0200
committerGitHub <noreply@github.com>2021-12-17 14:00:35 +0200
commitc3789c8e6ec34faee0b59080c1ab187cff1dc356 (patch)
treeb19561c2fdf7e26201237004b0344d21b0038ef2 /platform/linux-generic/m4
parent2ed1489ccc354300037bad2e718fe63cd6fdd7ba (diff)
parenta4f277eb71029ecf61c6b4dda7894d5e949c4852 (diff)
Merge ODP v1.33.0.0v1.33.0.0_DPDK_19.11
Merge ODP linux-generic v1.33.0.0 into linux-dpdk
Diffstat (limited to 'platform/linux-generic/m4')
-rw-r--r--platform/linux-generic/m4/configure.m43
-rw-r--r--platform/linux-generic/m4/odp_libconfig.m42
-rw-r--r--platform/linux-generic/m4/odp_openssl.m436
3 files changed, 40 insertions, 1 deletions
diff --git a/platform/linux-generic/m4/configure.m4 b/platform/linux-generic/m4/configure.m4
index ffac70414..9481deca1 100644
--- a/platform/linux-generic/m4/configure.m4
+++ b/platform/linux-generic/m4/configure.m4
@@ -21,6 +21,7 @@ AS_IF([test "x$with_pcap" != xno],
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_openssl.m4])
m4_include([platform/linux-generic/m4/odp_pcapng.m4])
m4_include([platform/linux-generic/m4/odp_netmap.m4])
m4_include([platform/linux-generic/m4/odp_dpdk.m4])
@@ -31,6 +32,8 @@ AS_VAR_APPEND([PLAT_DEP_LIBS], ["${ATOMIC_LIBS} ${LIBCONFIG_LIBS} ${OPENSSL_LIBS
# Add text to the end of configure with platform specific settings.
# Make sure it's aligned same as other lines in configure.ac.
AS_VAR_APPEND([PLAT_CFG_TEXT], ["
+ openssl: ${with_openssl}
+ openssl_rand: ${openssl_rand}
pcap: ${have_pcap}
pcapng: ${have_pcapng}
default_config_path: ${default_config_path}"])
diff --git a/platform/linux-generic/m4/odp_libconfig.m4 b/platform/linux-generic/m4/odp_libconfig.m4
index ccbf1d6f5..90b49d155 100644
--- a/platform/linux-generic/m4/odp_libconfig.m4
+++ b/platform/linux-generic/m4/odp_libconfig.m4
@@ -3,7 +3,7 @@
##########################################################################
m4_define([_odp_config_version_generation], [0])
m4_define([_odp_config_version_major], [1])
-m4_define([_odp_config_version_minor], [18])
+m4_define([_odp_config_version_minor], [19])
m4_define([_odp_config_version],
[_odp_config_version_generation._odp_config_version_major._odp_config_version_minor])
diff --git a/platform/linux-generic/m4/odp_openssl.m4 b/platform/linux-generic/m4/odp_openssl.m4
new file mode 100644
index 000000000..c9d584c64
--- /dev/null
+++ b/platform/linux-generic/m4/odp_openssl.m4
@@ -0,0 +1,36 @@
+##########################################################################
+# Enable/disable usage of OpenSSL library
+##########################################################################
+AC_ARG_WITH([openssl],
+ [AS_HELP_STRING([--without-openssl],
+ [compile without OpenSSL (may result in disabled crypto and random support)]
+ [[default=with] (linux-generic)])],
+ [],
+ [with_openssl=yes])
+AS_IF([test "$with_openssl" != "no"],
+ [ODP_OPENSSL
+ have_openssl=1], [have_openssl=0])
+AM_CONDITIONAL([WITH_OPENSSL], [test x$with_openssl != xno])
+AC_DEFINE_UNQUOTED([_ODP_OPENSSL], [$have_openssl],
+ [Define to 1 to enable OpenSSL support])
+
+AS_IF([test "${with_openssl}" = "no"],
+ [AC_MSG_WARN([Strong cryptography is not available without OpenSSL])])
+
+##########################################################################
+# Enable/disable usage of OpenSSL for random data
+##########################################################################
+have_openssl_rand=1
+AC_ARG_ENABLE([openssl-rand],
+ [AS_HELP_STRING([--disable-openssl-rand],
+ [disable OpenSSL random data (use arch-specific instead)]
+ [[default=enabled] (linux-generic)])],
+ [if test "x$enableval" = "xno"; then
+ have_openssl_rand=0
+ fi])
+
+AS_IF([test "$have_openssl" != "1"], [have_openssl_rand=0])
+AS_IF([test "$have_openssl_rand" = "1"], [openssl_rand=yes], [openssl_rand=no])
+
+AC_DEFINE_UNQUOTED([_ODP_OPENSSL_RAND], [$have_openssl_rand],
+ [Define to 1 to enable OpenSSL support])