From 54259e50a5241d8cc82824fa0f0711eef36ec9f5 Mon Sep 17 00:00:00 2001 From: Brent Cook Date: Wed, 22 Oct 2014 12:37:06 -0500 Subject: include a proper check for memmem when configuring unit tests This allows the proper compatibility header definition to be exposed. --- configure.ac | 5 +++++ update.sh | 2 ++ 2 files changed, 7 insertions(+) diff --git a/configure.ac b/configure.ac index 06ecda5..961cf18 100644 --- a/configure.ac +++ b/configure.ac @@ -117,6 +117,11 @@ AC_CHECK_FUNC(strtonum, AC_DEFINE(NO_STRTONUM) AM_CONDITIONAL(NO_STRTONUM, true)) +AC_CHECK_FUNC(memmem, + AM_CONDITIONAL(NO_MEMMEM, false), + AC_DEFINE(NO_MEMMEM) + AM_CONDITIONAL(NO_MEMMEM, true)) + AC_CHECK_FUNC(explicit_bzero, AM_CONDITIONAL(NO_EXPLICIT_BZERO, false), AC_DEFINE(NO_EXPLICIT_BZERO) diff --git a/update.sh b/update.sh index 269b670..a087a4c 100755 --- a/update.sh +++ b/update.sh @@ -321,7 +321,9 @@ $CP $libc_src/string/memmem.c tests/ echo "${TEST}_LDADD = \$(top_builddir)/ssl/libssl.la" >> Makefile.am echo "${TEST}_LDADD += \$(top_builddir)/crypto/libcrypto.la" >> Makefile.am done + echo "if NO_MEMMEM" >> Makefile.am echo "explicit_bzero_SOURCES += memmem.c" >> Makefile.am + echo "endif" >> Makefile.am ) $CP $libcrypto_regress/evp/evptests.txt tests $CP $libcrypto_regress/aead/aeadtests.txt tests -- cgit v1.2.3-55-g6feb