Debian Codegraph @

lib/freeDiameter-1.2.1/cmake/Modules/FindGcrypt.cmake

raw
1 # - Find gnutls
2 # Find the native GCRYPT includes and library
3 #
4 # GCRYPT_FOUND - True if gnutls found.
5 # GCRYPT_INCLUDE_DIR - where to find gnutls.h, etc.
6 # GCRYPT_LIBRARIES - List of libraries when using gnutls.
7
8 if (GCRYPT_INCLUDE_DIR AND GCRYPT_LIBRARIES)
9 set(GCRYPT_FIND_QUIETLY TRUE)
10 endif (GCRYPT_INCLUDE_DIR AND GCRYPT_LIBRARIES)
11
12 # Include dir
13 find_path(GCRYPT_INCLUDE_DIR
14 NAMES
15 gcrypt.h
16 )
17
18 # Library
19 find_library(GCRYPT_LIBRARY
20 NAMES gcrypt
21 )
22
23 # handle the QUIETLY and REQUIRED arguments and set GCRYPT_FOUND to TRUE if
24 # all listed variables are TRUE
25 INCLUDE(FindPackageHandleStandardArgs)
26 FIND_PACKAGE_HANDLE_STANDARD_ARGS(GCRYPT DEFAULT_MSG GCRYPT_LIBRARY GCRYPT_INCLUDE_DIR)
27
28 IF(GCRYPT_FOUND)
29 SET( GCRYPT_LIBRARIES ${GCRYPT_LIBRARY} )
30 ELSE(GCRYPT_FOUND)
31 SET( GCRYPT_LIBRARIES )
32 ENDIF(GCRYPT_FOUND)
33
34 # Lastly make it so that the GCRYPT_LIBRARY and GCRYPT_INCLUDE_DIR variables
35 # only show up under the advanced options in the gui cmake applications.
36 MARK_AS_ADVANCED( GCRYPT_LIBRARY GCRYPT_INCLUDE_DIR )