cmake/FindMbedTLS: drop lib duplicates early
When de-duplicating the list of raw libs, make sure to drop duplicates from the beginning of the list. Reported-by: Kai Pastor Ref: https://github.com/curl/curl/pull/15273#pullrequestreview-2417191841 Closes #15495
This commit is contained in:
parent
9294ca8916
commit
f7cd713d38
@ -59,7 +59,9 @@ endif()
|
||||
|
||||
if(MBEDTLS_FOUND AND MBEDX509_FOUND AND MBEDCRYPTO_FOUND)
|
||||
list(APPEND MBEDTLS_LIBRARIES ${MBEDX509_LIBRARIES} ${MBEDCRYPTO_LIBRARIES})
|
||||
list(REVERSE MBEDTLS_LIBRARIES)
|
||||
list(REMOVE_DUPLICATES MBEDTLS_LIBRARIES)
|
||||
list(REVERSE MBEDTLS_LIBRARIES)
|
||||
set(MBEDTLS_PC_REQUIRES "mbedtls")
|
||||
string(REPLACE ";" " " MBEDTLS_CFLAGS "${MBEDTLS_CFLAGS}")
|
||||
message(STATUS "Found MbedTLS (via pkg-config): ${MBEDTLS_INCLUDE_DIRS} (found version \"${MBEDTLS_VERSION}\")")
|
||||
|
||||
Loading…
Reference in New Issue
Block a user