Skip to content

Commit

Permalink
allow cmake to use imported library in addition to found one
Browse files Browse the repository at this point in the history
  • Loading branch information
dmllr committed Apr 8, 2024
1 parent e53e106 commit 4ec6dbc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,9 @@ if(ENABLE_MBEDTLS)
if(ENABLE_OPENSSL OR ENABLE_NSS)
message(FATAL_ERROR "ssl conflict. can not enable mbedtls and openssl or nss simultaneously.")
endif()
find_package(MbedTLS REQUIRED)
if(NOT TARGET MbedTLS::MbedTLS)
find_package(MbedTLS REQUIRED)
endif()
set(MBEDTLS ${ENABLE_MBEDTLS} CACHE BOOL INTERNAL)
set(GCM ${ENABLE_MBEDTLS} CACHE BOOL INTERNAL)
endif()
Expand Down

0 comments on commit 4ec6dbc

Please sign in to comment.