Changeset 797:36821971d47b in freeDiameter for cmake
- Timestamp:
- Aug 21, 2012, 5:16:21 AM (12 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cmake/Modules/FindGnuTLS.cmake
r747 r797 5 5 # GNUTLS_INCLUDE_DIR - where to find gnutls.h, etc. 6 6 # GNUTLS_LIBRARIES - List of libraries when using gnutls. 7 # GNUTLS_NEW_VERSION - true if GnuTLS version is >= 2.10.0 (does not require additional separate gcrypt initialization) 7 # GNUTLS_VERSION_210 - true if GnuTLS version is >= 2.10.0 (does not require additional separate gcrypt initialization) 8 # GNUTLS_VERSION_300 - true if GnuTLS version is >= 3.00.0 (x509 verification functions changed) 8 9 9 10 if (GNUTLS_INCLUDE_DIR AND GNUTLS_LIBRARIES) … … 39 40 40 41 # Now check if the library is recent. gnutls_hash was added in 2.10.0. 42 # Also test library is even more recent. gnutls_x509_trust_list_verify_crt was added in 3.00.0. 41 43 IF( NOT( "${GNUTLS_VERSION_TEST_FOR}" STREQUAL "${GNUTLS_LIBRARY}" )) 42 44 INCLUDE (CheckLibraryExists) 43 MESSAGE(STATUS "Rechecking GNUTLS_NEW_VERSION") 44 UNSET(GNUTLS_NEW_VERSION) 45 UNSET(GNUTLS_NEW_VERSION CACHE) 45 MESSAGE(STATUS "Rechecking GNUTLS_VERSION_210 and GNUTLS_VERSION_300") 46 UNSET(GNUTLS_VERSION_210) 47 UNSET(GNUTLS_VERSION_210 CACHE) 48 UNSET(GNUTLS_VERSION_300) 49 UNSET(GNUTLS_VERSION_300 CACHE) 46 50 GET_FILENAME_COMPONENT(GNUTLS_PATH ${GNUTLS_LIBRARY} PATH) 47 CHECK_LIBRARY_EXISTS(gnutls gnutls_hash ${GNUTLS_PATH} GNUTLS_NEW_VERSION) 51 CHECK_LIBRARY_EXISTS(gnutls gnutls_hash ${GNUTLS_PATH} GNUTLS_VERSION_210) 52 CHECK_LIBRARY_EXISTS(gnutls gnutls_x509_trust_list_verify_crt ${GNUTLS_PATH} GNUTLS_VERSION_300) 48 53 SET( GNUTLS_VERSION_TEST_FOR ${GNUTLS_LIBRARY} CACHE INTERNAL "Version the test was made against" ) 49 54 ENDIF (NOT( "${GNUTLS_VERSION_TEST_FOR}" STREQUAL "${GNUTLS_LIBRARY}" ))
Note: See TracChangeset
for help on using the changeset viewer.