diff --git a/configure.ac b/configure.ac index 2eaab4729..2cef230e8 100644 --- a/configure.ac +++ b/configure.ac @@ -3957,7 +3957,7 @@ then ENABLED_AESKEYWRAP="yes" AM_CFLAGS="$AM_CFLAGS -DHAVE_AES_KEYWRAP -DWOLFSSL_AES_DIRECT" fi - if test "x$ENABLED_X963KDF" = "xno" + if test "x$ENABLED_X963KDF" = "xno" && test "$ENABLED_ECC" = "yes" then ENABLED_X963KDF="yes" AM_CFLAGS="$AM_CFLAGS -DHAVE_X963_KDF" diff --git a/wolfssl/wolfcrypt/settings.h b/wolfssl/wolfcrypt/settings.h index 28ec97093..b847ce334 100644 --- a/wolfssl/wolfcrypt/settings.h +++ b/wolfssl/wolfcrypt/settings.h @@ -1564,7 +1564,7 @@ extern void uITRON4_free(void *p) ; #ifndef HAVE_AES_KEYWRAP #error PKCS7 requires AES key wrap please define HAVE_AES_KEYWRAP #endif - #ifndef HAVE_X963_KDF + #if defined(HAVE_ECC) && !defined(HAVE_X963_KDF) #error PKCS7 requires X963 KDF please define HAVE_X963_KDF #endif #endif