1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
|
Index: b/build/common.cmake
===================================================================
--- a/build/common.cmake
+++ b/build/common.cmake
@@ -225,8 +225,7 @@ function( AddExecutableTest test_name so
endfunction()
include(CheckIncludeFileCXX)
-#check_include_file_cxx(mbedtls/md.h HAVE_MBEDTLS_H)
-set(HAVE_MBEDTLS_H 0) # TODO: disabling system mbedtls since it may be outdated
+check_include_file_cxx(mbedtls/md.h HAVE_MBEDTLS_H)
set( MBEDTLS_LIBS mbedx509 mbedtls mbedcrypto ) # need to link against mbedtls in any case: system or local mbedtls
set(CMAKE_REQUIRED_LIBRARIES ${MBEDTLS_LIBS})
if ( HAVE_MBEDTLS_H )
@@ -239,7 +238,7 @@ int main(int argc, char *argv[]) {
mbedtls_md_context_t ctx;
mbedtls_md_type_t md_type = MBEDTLS_MD_SHA256;
mbedtls_md_init(&ctx);
- printf(\"test p: %p\", ctx.md_ctx);
+ printf(\"test p: %p\", mbedtls_md_info_from_ctx(&ctx));
}
" HAVE_MBEDTLS_F)
else()
|